
Component rendering entire navigation list
Usage
import { Navigation } from '@admin-bro/design-system'
const navigationElements = [{
label: 'Dashboard',
icon: 'Dashboard',
isSelected: true,
href: '/',
onClick: () => {},
id: 'dashboard',
}]
return (
<Navigation
label: "Pages",
elements: navigationElements,
/>
)
Prop types
By default all the data are passed via CurrentUserNavProps - check them out below.
Example
Full-featured example with all the props
- New:
- In version 3.3
- See:
View Source admin-bro-design-system/src/organisms/navigation/navigation.tsx, line 16
Type Definitions
object
# NavigationElementWithChildrenProps
Array of navigation elements. Extending NavigationElementProps
Properties:
Name | Type | Attributes | Description |
---|---|---|---|
elements |
Array.<NavigationElementWithChildrenProps> |
<optional> |
object
# NavigationProps
Props passed to Navigation component
Properties:
Name | Type | Description |
---|---|---|
label |
string | |
elements |
Array.<NavigationElementWithChildrenProps> |