Navigation
ContextNavigation
Pairs a stable scope selector or identity with horizontally scrollable contextual links.
01
See it and copy it
Framework example
Choose Astro, React, or Elements to compare native usage against the shared visual output. Each example assumes the framework-level setup is already complete.
Framework usage
Switch targets to compare the adapter code. The preview stays visually stable because all three packages share the same tokens andui-* class contract.---
import {
ContextNavigation,
Label,
NativeSelect,
NavigationMenu
} from '@santi020k/lumen-astro'
---
<ContextNavigation>
<div slot="context">
<Label for="context-navigation-example">Documentation for</Label>
<NativeSelect id="context-navigation-example" visualSize="sm">
<option>Web</option>
<option>React Native</option>
<option>Apple</option>
<option>Android</option>
</NativeSelect>
</div>
<NavigationMenu aria-label="Web documentation" variant="unstyled">
<a href="/docs/web" aria-current="page">Overview</a>
<a href="/docs/components">Components</a>
<a href="/docs/web/playground">Playground</a>
<a href="/docs/frameworks/astro">Frameworks</a>
</NavigationMenu>
</ContextNavigation>import { ContextNavigation, Label, NativeSelect, NavigationMenu } from '@santi020k/lumen-react'
export const Example = () => (
<>
<ContextNavigation>
<div slot="context">
<Label htmlFor="context-navigation-example">Documentation for</Label>
<NativeSelect id="context-navigation-example" visualSize="sm">
<option>Web</option>
<option>React Native</option>
<option>Apple</option>
<option>Android</option>
</NativeSelect>
</div>
<NavigationMenu aria-label="Web documentation" variant="unstyled">
<a href="/docs/web" aria-current="page">Overview</a>
<a href="/docs/components">Components</a>
<a href="/docs/web/playground">Playground</a>
<a href="/docs/frameworks/astro">Frameworks</a>
</NavigationMenu>
</ContextNavigation>
</>
)<script type="module">
import { defineLumenElements } from '@santi020k/lumen-elements/define'
defineLumenElements()
</script>
<lumen-context-navigation>
<div slot="context">
<lumen-label for="context-navigation-example">Documentation for</lumen-label>
<lumen-native-select id="context-navigation-example" visualSize="sm">
<option>Web</option>
<option>React Native</option>
<option>Apple</option>
<option>Android</option>
</lumen-native-select>
</div>
<lumen-navigation-menu aria-label="Web documentation" variant="unstyled">
<a href="/docs/web" aria-current="page">Overview</a>
<a href="/docs/components">Components</a>
<a href="/docs/web/playground">Playground</a>
<a href="/docs/frameworks/astro">Frameworks</a>
</lumen-navigation-menu>
</lumen-context-navigation>02
Choose your target
Add this component
Choose the package for your runtime. All adapters share the Lumen stylesheet. Use the matching registry command when you want a local wrapper for that framework.
API reference
Lumen-specific props and runtime attributes for the Astro primitive. React props follow the same names; Elements use equivalent kebab-case attributes where custom elements expose them.
| Attribute | Values | Default | Description |
|---|---|---|---|
| context / slot="context" | rendered content | - | Provides a stable leading region for a scope label, selector, or product identity. |
| variant | "default" | "unstyled" | "default" | Keeps the responsive layout while allowing an application-owned surface to remove the default border, background, and padding. |
| children | NavigationMenu | required | Provides the related links as one independently named navigation group. |
| class, className | string | "" | Merges custom classes with the generated ui-* root classes. |
| ...native attributes | HTML attributes | - | Forwards standard attributes to the root element unless the component consumes them. |