Trigger must have data-context-menu-trigger. Right-click to open the menu at cursor. Use context-menu__item and context-menu__separator for content.
Add this component
The command below includes <strong>ContextMenu</strong>—run it in your project directory to install this component (and the CSS if needed). No prompts.
Choose your package manager — click a tab to select, then copy the command.
npm pnpm yarn bun
bashbash
npx rizzo-css add ContextMenu
bashbash
pnpm dlx rizzo-css add ContextMenu
bashbash
npx rizzo-css add ContextMenu
bashbash
bunx rizzo-css add ContextMenu
Live Example
Right click here
Usage
Usage
Full example for each framework (Astro, Vanilla, Svelte, Vue, React). Switch framework via View as or by clicking a Usage tab—both stay in sync.