More components in Pro
Galleries, cards and interactive pieces for pages that need more than the basics.
items | { label: string; description?: string; bgColor?: string; textColor?: string; links: { label: string; href?: string; ariaLabel?: string }[] }[] | The cards in the menu. Give a card a bgColor to tint it, and links without an href render as buttons. | |
logo | string | ReactNode | Image URL or element shown in the middle of the bar. | |
logoAlt | 'Logo' | Accessible label for the logo link. | |
logoHref | '#' | Where the logo links to. | |
cta | { label: string; href?: string; onClick?: (event) => void } | Button on the right of the bar. On narrow screens it moves to the bottom of the menu. | |
theme | 'dark' | 'light' | 'dark' | Color scheme of the bar, cards and button. |
surface | 'glass' | 'solid' | 'glass' | Frosted glass that blurs what is behind the bar, or an opaque fill. |
openOn | 'click' | 'hover' | 'click' | Opens the menu from the button, or as soon as the pointer moves over the bar. |
cardEffect | 'rise' | 'unfold' | 'fade' | 'rise' | How the cards arrive: rising into place, folding down from the bar, or fading in from a soft blur. |
stagger | 0.12 | How far each card trails the one before it, from 0 to 0.3. | |
bounce | 0.2 | How much the menu overshoots as it opens, from 0 to 1. | |
speed | Speed of the open and close animation. | ||
cardHeight | 176 | Minimum height of the cards in px. | |
maxWidth | 800 | Maximum width of the bar in px. | |
accentColor | Color of the button. Its label picks black or white for contrast. | ||
menuLabel | Shows Menu and Close next to the menu icon, rolling between them. | ||
| Unrolls the bar from its center on mount. | |||
defaultOpen | Starts with the menu open. | ||
open | Controls the menu from outside. Pair it with onOpenChange. | ||
onOpenChange | (open: boolean) => void | Called when the menu opens or closes. | |
linkComponent | ElementType | 'a' | Renders the links, so you can pass your router's link. It receives href, className and children. |
onLinkClick | (link, item, event) => void | Called when a link is clicked. The menu closes afterwards. | |
ariaLabel | 'Main' | Accessible name of the nav landmark. | |
| Extra class names for the root. | |||
| Inline styles for the root. |
items{ label: string; description?: string; bgColor?: string; textColor?: string; links: { label: string; href?: string; ariaLabel?: string }[] }[]The cards in the menu. Give a card a bgColor to tint it, and links without an href render as buttons.
logostring | ReactNodeImage URL or element shown in the middle of the bar.
logoAltstringAccessible label for the logo link.
'Logo'logoHrefstringWhere the logo links to.
'#'cta{ label: string; href?: string; onClick?: (event) => void }Button on the right of the bar. On narrow screens it moves to the bottom of the menu.
theme'dark' | 'light'Color scheme of the bar, cards and button.
'dark'surface'glass' | 'solid'Frosted glass that blurs what is behind the bar, or an opaque fill.
'glass'openOn'click' | 'hover'Opens the menu from the button, or as soon as the pointer moves over the bar.
'click'cardEffect'rise' | 'unfold' | 'fade'How the cards arrive: rising into place, folding down from the bar, or fading in from a soft blur.
'rise'staggernumberHow far each card trails the one before it, from 0 to 0.3.
0.12bouncenumberHow much the menu overshoots as it opens, from 0 to 1.
0.2speednumberSpeed of the open and close animation.
cardHeightnumberMinimum height of the cards in px.
176maxWidthnumberMaximum width of the bar in px.
800accentColorstringColor of the button. Its label picks black or white for contrast.
menuLabelbooleanShows Menu and Close next to the menu icon, rolling between them.
introbooleanUnrolls the bar from its center on mount.
defaultOpenbooleanStarts with the menu open.
openbooleanControls the menu from outside. Pair it with onOpenChange.
onOpenChange(open: boolean) => voidCalled when the menu opens or closes.
linkComponentElementTypeRenders the links, so you can pass your router's link. It receives href, className and children.
'a'onLinkClick(link, item, event) => voidCalled when a link is clicked. The menu closes afterwards.
ariaLabelstringAccessible name of the nav landmark.
'Main'Extra class names for the root.
Inline styles for the root.
Dependencies
2 required packages
npm install @hugeicons/react @hugeicons/core-free-icons


