shadcn.io is not affiliated with official shadcn/ui
Navigation Menu examples · Standard
Navigation without Viewport Navigation Menu for React
Products and Company dropdowns that each open their own panel under their trigger.
Products and Company each open a list of four links in a panel under their own trigger, instead of one shared panel under the whole menu. That keeps small dropdowns next to the word that opened them.
Preview
Installation
FAQ
How does each panel open under its own trigger?
Base UI always opens panels in one popup, which moves to the trigger that is open, so the demo passes no prop.
What are the links?
Products lists Product 1 to Product 4, and Company lists About, Team, Careers and Contact, from two sections at the top of the file.
How do the links use my router?
Each link is your router's link rendered through NavigationMenuLink, so it keeps the menu's styles and focus handling.
NavigationMenuLink takes the Next.js Link through render, as in render={<Link href="#" />}.
Related
- Simple Navigation Navigation MenuA navigation menu with Products and
- Mixed Links and Dropdowns Navigation MenuA navigation menu that mixes Products and
- Full Mega Menu Navigation MenuA wide Platform mega menu with feature
- Simple Dropdown with Icons Dropdown MenuA short menu behind a dots button with an
- Navigation with Descriptions Navigation MenuA Resources dropdown whose links pair an
- Navigation with Icons Navigation MenuA Features dropdown whose links each