A right-click (or long-press) menu that opens at the pointer position with origin-aware unfurl, proximity highlight, and keyboard-shortcut hints.
Dependencies
Interaction Type
Right-click or long-press to open. The menu unfurls from the cursor position. Arrow keys navigate, Enter selects, Escape closes.
Props
Options you can pass to customize this component.
items*The menu items.
children*The trigger region.
disabledDisable the context menu.
Installation
How to use
<ContextMenu items={[{ label: 'Copy', shortcut: '⌘C' }, { label: 'Delete', destructive: true }]}>
<div>Right-click me</div>
</ContextMenu>Source Code
Click the code icon in the top-right corner to view the source code.
License & Usage
// No code loaded.