Menus
Context menu
The context menu binds actions to the thing under the cursor rather than to a handle somewhere else on the screen. It opens at the click point and scales out of it, so the link between the target and the actions never has to be explained. It shares its items with the dropdown menu, so an action can live in both places without a second implementation.
npx shadcn@latest add @minflow/context-menuWhere to use it
- Canvases, boards, and file lists, where the content itself is the target.
- As a shortcut over actions that already exist elsewhere, never as their only home: a right-click is undiscoverable on its own and unavailable on touch.
Variations
A whole zone
The default. One surface answers the right-click, and the panel opens wherever the cursor happened to be.
Per row
When each item in a list carries its own actions. Each row gets its own content, so the menu always matches what was clicked.