ctxmenu.js
ctxmenu.js is a lightweight, simple to use and customizable javascript library for creating custom context
menus.
Go ahead and try it out! Press your secondary mouse button anywhere on this page,
or press and hold when you're on a touch-device.
Download area
Right-click here to download ctxMenu.js or go to the full documentation.
Some of ctxMenu.js' features:
- Create as many context menus as you want. Have specific menus for different elements on your
website.
(The header on this page for example does not have a context menu, but prevents the default browser context menu from appearing) - Use JavaScript functions or HTML Anchors for interactive items
- Infinite nested submenus.
(Try in this page's context menu) - Update the menu before it appears to include event specific items, such as the cursor position or run any arbitrary javascript function
- Fully customizable! Click here to toggle dark mode
- Show a context menu on demand for
- any mouse event
-
any element
Click this Element!
- Mobile support