Browse the docs

Dropdown Menu

Action menu on a trigger, following the WAI-ARIA menu-button pattern: arrow keys move (skipping disabled items), Home/End jump, typing jumps to a matching item, Enter selects, Escape closes and returns focus to the trigger.

This component needs the menu primitive — two ways to get it:

Props

PropValuesDefaultDescription
triggerelementrequiredA single element — the menu-button behavior merges onto it.
itemsarrayrequired{ label, onSelect, disabled?, danger? }, { type: "separator" }, or { type: "label", label }.
side / alignposition"bottom" / "start"Where the panel opens.
classNamestring""Applied to the panel.

Notes

An item's onSelect(event) may call event.preventDefault() to keep the menu open. For checkbox items, radio groups, or custom item markup, compose the primitive directly: Menu, MenuTrigger, MenuContent, MenuItem, MenuGroup, MenuLabel, MenuSeparator.