Navigation

Navigation Menu
v1.0.7
Ready for Production

A collection of links for navigating internal applications with accessible multi-level dropdown support and customizable styling.

Prefer AI-assisted development?

This documentation is available via the Catalyst MCP Server. Learn how to connect →

Catalyst Navigation Menu wraps Radix UI Navigation Menu to provide an accessible, keyboard-navigable menu bar with multi-level dropdowns, smooth animations, active-page tracking, and Catalyst design token styling out of the box.

Installation

npm install @pmi/catalyst-navigation-menu
import {
  NavigationMenuRoot,
  NavigationMenuList,
  NavigationMenuItem,
  NavigationMenuTrigger,
  NavigationMenuContent,
  NavigationMenuLink,
  NavigationMenuSub,
  NavigationMenuViewport,
  NavigationMenuIndicator,
} from '@pmi/catalyst-navigation-menu';

Examples

Default

A complete navigation menu with certification cards and dropdown content:

Preview

Default Opened

A menu with an item opened by default:

Responsive behavior

The examples switch orientation to vertical below 640px. This is suitable for simple menus. For complex mobile navigation (many items, nested dropdowns), collapse the menu into a drawer or a hamburger button that reveals the navigation instead of stretching the dropdown viewport vertically.

API Reference

Navigation Menu is a compound component built on Radix UI primitives. Each part forwards ref and merges className via Catalyst's cn() utility.

Root container that manages which menu is open and provides Radix context to all children.

Prop

Type

Horizontal (or vertical) list of menu items. Renders as <ul> with Radix list semantics.

Prop

Type

Wraps a single trigger + content pair, or a standalone link.

Prop

Type

Button that opens a dropdown. Ships with Catalyst default styles — override via className.

Prop

Type

Dropdown panel shown inside NavigationMenuViewport. Includes slide-in/out animations driven by data-[motion=*] attributes.

Prop

Type

A navigational link — use standalone inside NavigationMenuItem or nested inside dropdown content. Supports asChild for custom link components (e.g. React Router <Link>).

Prop

Type

Animated viewport container that hosts the open NavigationMenuContent. Place it below the list, wrapped in a positioning <div>.

Prop

Type

Optional animated arrow that tracks the active trigger. Typically contains a styled <div> rotated 45°.

Prop

Type

Creates a nested sub-navigation structure within dropdown content.

Accepts all standard Radix NavigationMenu Sub props (value, defaultValue, onValueChange, orientation).

Accessibility

Navigation Menu follows the Disclosure Navigation Menu pattern and is designed to meet WCAG 2.2 AA standards.

Keyboard Interactions

KeyAction
Tab / Shift + TabMoves focus forward or backward through top-level NavigationMenuTrigger and NavigationMenuLink items. When a dropdown is open, moves through its links before continuing to the next top-level item.
Arrow Left / RightMoves focus to the previous or next item in the current focus group (top-level items or links inside an open dropdown). Reversed in RTL. Vertical (below 640px in the examples) with an open trigger: the arrow matching the text direction (Arrow Right in LTR, Arrow Left in RTL) moves focus into NavigationMenuContent.
Arrow Up / DownMoves focus to the previous or next item in the current focus group (top-level items or links inside an open dropdown). Horizontal with an open trigger: Arrow Down moves focus into NavigationMenuContent.
Home / EndMoves focus to the first or last item in the current focus group. Arrow keys do not wrap — use Home / End to jump to either end.
Enter / SpaceWhen focus is on a NavigationMenuTrigger, opens or closes its dropdown.
EnterWhen focus is on a NavigationMenuLink, activates the link. Space does not activate links.
EscapeCloses the open dropdown and returns focus to its trigger.

ARIA

  • NavigationMenuRoot renders a <nav> element. Provide an aria-label to describe the navigation region when needed.
  • NavigationMenuTrigger receives aria-expanded and aria-controls, which are managed automatically by Radix.
  • Use aria-current="page" on the NavigationMenuLink or NavigationMenuTrigger that represents the current page.
  • Decorative chevron icons inside triggers should have aria-hidden="true".
  • NavigationMenuViewport exposes --radix-navigation-menu-viewport-width and --radix-navigation-menu-viewport-height for size-aware animations.
  • All animations respect the prefers-reduced-motion media query.

See the Radix Navigation Menu accessibility docs for full inherited behavior.

Choosing the Right Component

Use NavigationMenu for persistent, multi-level site navigation bars. Reach for a different primitive when:

If you need…Use instead
A dropdown from a single buttonDropdown Menu
A menu triggered by right-clickingContext Menu

On this page