Navigation
ContextMenu
A menu that opens where people right-click, long-press, or press Shift+F10.
Ant Design: Dropdown trigger={["contextMenu"]}
import { ContextMenu } from '@alea/ui';
Examples
Right-click menu
Right-click, long-press, or focus the card and press Shift+F10.
palette.json
Last action: nothing yet
Props
Accessibility
- The area is focusable and says it has a menu; Shift+F10 and the Menu key open it.
- Every action must also be reachable another way.
Keyboard
| Key | Does |
|---|---|
| Shift+F10 or Menu key | Opens |
| Arrow keys | Move |
| Enter | Runs |
| Escape | Closes and returns focus |
Do and don't
Do
- Put the same actions somewhere visible too (a toolbar or menu button).
- Show shortcuts next to the actions.
Don't
- Don't hide destructive actions only in a context menu.
- Don't override the browser's context menu on text people may want to copy.