Skip to main content

Menu

A menu displays a list of actions or options that a user can choose.

On this page
Props
<Menu>
  <Button>Open Menu</Button>
  <Popover>
    <MenuContent>
      <MenuItem>Edit</MenuItem>
      <MenuItem>Duplicate</MenuItem>
      <MenuItem>Archive</MenuItem>
      <MenuItem>Delete</MenuItem>
    </MenuContent>
  </Popover>
</Menu>

Installation

npx shadcn@latest add @dotui/menu

Usage

Use menus to display a list of actions or options that a user can choose from.

import { Button } from '@/components/ui/button'
import { Menu, MenuContent, MenuItem } from '@/components/ui/menu'
import { Popover } from '@/components/ui/popover'
<Menu>
  <Button>Open Menu</Button>
  <Popover>
    <MenuContent>
      <MenuItem>Edit</MenuItem>
      <MenuItem>Duplicate</MenuItem>
      <MenuItem>Delete</MenuItem>
    </MenuContent>
  </Popover>
</Menu>

Examples

Placement
Type
MobileType

state: closed

API Reference

A menu displays a list of actions or options that a user can choose. It wraps a trigger element and the menu, linking the menu's open state with the trigger's press state.

PropType
MenuTriggerType

A menu displays a list of actions or options that a user can choose.

PropType
ReactNode | function
Iterable<T>
ReactNode | function
readonly any[]
SelectionMode
Iterable<Key> | "all"
Iterable<Key> | "all"
function
Iterable<Key>
boolean
boolean
"clearSelection" | "none"

A MenuItem represents an individual action in a Menu.

PropType
union
ReactNode | function
Key
boolean
string
T

A MenuItemLabel represents the primary text content of a MenuItem.

PropType

A MenuItemDescription represents secondary text content within a MenuItem.

PropType

A MenuSection represents a section within a Menu.

PropType
Key
T
union
Iterable<T>
readonly any[]
SelectionMode
Iterable<Key> | "all"
Iterable<Key> | "all"
function
boolean

A MenuSectionHeader represents the header of a MenuSection, usually containing the section title.

PropType

A submenu trigger is used to wrap a submenu's trigger item and the submenu itself.

PropType
union
number

Last updated on 6/16/2026