ContextMenu
Right-click actions on any region. The menu opens at the cursor and stays inside the viewport.
Example
Right-click (or long-press) this box
<ContextMenu label="File actions">
<div slot="trigger" id="demo-zone" tabindex="0">Right-click this box</div>
<a role="menuitem" href="/guides/theming">Open</a>
<button role="menuitem" type="button">Delete</button>
</ContextMenu>Props
| Prop | Type | Default | Description |
|---|---|---|---|
label | string | - | Menu landmark name. |
Accessibility
- Items are keyboard operable after opening.
- Escape closes; position is clamped to the viewport.
- The trigger region stays a plain element: add your own label for AT if needed.