Overlays/Dropdown Menu

Dropdown Menu

A click-triggered menu of actions, positioned relative to a trigger element. Dismisses on outside click or Escape key.

import { DropdownMenu } from "@animui/ui"

Basic

Alignment

Disabled items

Props

PropTypeDefaultDescription
triggerReact.ReactNodeThe element that opens the menu on click.
itemsDropdownMenuItem[]The list of menu items to render.
align"start" | "end""start"Aligns the menu panel to the left or right edge of the trigger.
classNamestringAdditional classes for the menu panel.

Accessibility

  • Trigger exposes aria-haspopup and aria-expanded.
  • Menu items are rendered with role="menuitem" inside a role="menu" container.
  • Closes on outside click or the Escape key.
© 2026 Steal Shadow. MIT License.Report an issue