Displays a menu of actions or options triggered by a button. Supports items, labels, separators, keyboard shortcuts, checkbox/radio items, nested submenus, and a destructive variant. Built on Radix UI for full keyboard navigation and accessibility.
Each sub-component forwards className and all native attributes for its underlying Radix primitive. The most useful consumer-facing props are listed below.
Prop
Type
Default
Description
DropdownMenu
Radix Root
—
The root container. Forwards all props to Radix's DropdownMenu.Root.
DropdownMenuTrigger
Radix Trigger
—
The button or element that opens the menu. Supports asChild to compose with a Button.
DropdownMenuContent
Radix Content
—
The floating panel. Renders into a portal at the end of body. Supports align, side, sideOffset props from Radix.
DropdownMenuItem
Radix Item
—
A clickable item. Accepts variant="default" | "destructive" for destructive actions, and inset for icon alignment.
DropdownMenuCheckboxItem
Radix CheckboxItem
—
A toggleable item. Controlled via checked and onCheckedChange.
DropdownMenuRadioItem
Radix RadioItem
—
A single choice in a DropdownMenuRadioGroup. Pass value; the group's value selects one.
DropdownMenuRadioGroup
Radix RadioGroup
—
Wraps multiple DropdownMenuRadioItems. Controlled via value and onValueChange.
DropdownMenuLabel
Radix Label
—
Section heading inside the menu. Not selectable. Supports inset for icon alignment.
DropdownMenuSeparator
Radix Separator
—
A thin horizontal divider between sections.
DropdownMenuShortcut
span
—
Displays a keyboard shortcut hint right-aligned in an item (e.g., ⌘C).
DropdownMenuGroup
Radix Group
—
Wraps related items so screen readers announce them as a group.
DropdownMenuSub
Radix Sub
—
Wraps a nested submenu (DropdownMenuSubTrigger + Content).
DropdownMenuSubTrigger
Radix SubTrigger
—
The item that opens a submenu. Automatically renders a chevron icon on the right.
DropdownMenuSubContent
Radix SubContent
—
The floating panel for a submenu.
Accessibility
Built on Radix UI primitives. Full keyboard support: Enter or Space opens the menu, Arrow keys move between items, Esc closes, Tab moves focus out of the menu.
The trigger and content are linked via aria-controls and aria-expanded automatically. Screen readers announce the menu state and item count.
Use DropdownMenuLabel as a section heading. Labels are not focusable, but screen readers announce them when entering a group.
For icon-only triggers, set aria-label on the trigger Button so the menu's purpose is announced.
Checkbox and radio items expose their checked state via aria-checked; the indicator is aria-hidden so the announcement comes from the item itself.