Navigation Menu

A collection of links for navigating websites, with hover-activated content panels.

Installation

CLI

Install the component using the StarUI CLI:

star add navigation-menu

Examples

With Active Link

The active prop on NavigationMenuLink highlights the current page with font-medium. The two panels have different widths — Guides is a narrow single-column list, API is a wider two-column grid — so the shared viewport resizes when switching between them.

API Reference

Component Description
NavigationMenu Root navigation container managing active item state via signal
NavigationMenuList Horizontal list container for navigation items
NavigationMenuItem Individual item wrapper (trigger + content pair or standalone link)
NavigationMenuTrigger Button that reveals content panel on hover/click with animated chevron
NavigationMenuContent Content panel that registers with the shared viewport popover; shown via data_show
NavigationMenuLink Styled anchor for standalone or in-panel links; active prop for current page
NavigationMenuListContent Grid container (ul) for organizing list items within a content panel
NavigationMenuListItem Link with a title heading and child description inside a content panel