components / navbar
navbar.
fixed top nav with inline desktop links and a hamburger-driven slide-in panel below md. routes are caller-supplied; behavior split into a headless useNavbar hook.
resize narrow for the hamburger
installation
bunx @justin06lee/chrome@latest add navbarprops
| name | type | default | description |
|---|---|---|---|
| brand | ReactNode | - | left-side logo / name. |
| leftLinks | NavLink[] | - | items next to the brand on desktop; listed before links in the mobile panel. |
| links | NavLink[] | - | right-side items; listed after leftLinks in the mobile panel. NavLink = { label: ReactNode, href?, onClick?, id? } — omit href (with onClick) for a <button> item; id keys items when labels are nodes or hrefs repeat. |
| actions | ReactNode | - | right-side desktop extras. |
| menuLabel | string | 'menu' | heading atop the mobile panel. |