SubNav
- Alpha
- Not reviewed for accessibility
Use the SubNav component for navigation on a dashboard-type interface with another set of navigation components above it. This helps distinguish navigation hierarchy.
To use SubNav with react-router or
react-router-dom, pass
as={NavLink}
and omit the selected
prop.
This ensures that the NavLink gets activeClassName='selected'
Attention: Make sure to properly label your SubNav
with an aria-label
to provide context about the type of navigation contained in SubNav
.
Name | Type | Default | Description |
---|---|---|---|
actions | React.ReactNode | Place another element, such as a button, to the opposite side of the navigation items. | |
align | 'right' | Use | |
full | boolean | Used to make navigation fill the width of the container. | |
aria-label | string | Used to set the | |
sx | SystemStyleObject |
Name | Type | Default | Description |
---|---|---|---|
as | React.ElementType | The underlying element to render — either a HTML element name or a React component. | |
href | string | ||
selected | boolean | ||
sx | SystemStyleObject |
Name | Type | Default | Description |
---|---|---|---|
sx | SystemStyleObject |