Cheatsheet(jQuery) Cheatsheet(DOM)

LightBox-style context menu GoJS Sample

This demonstrates the implementation of a custom HTML context menu using HTMLInfo. This sample is also a re-implementation of the built-in ContextMenuTool.defaultTouchContextMenu.

The implementation is contained in the files LightBoxContextMenu.js and LightBoxContextMenu.css. The JavaScript file exposes window.myHTMLLightBox, which is used in this file as the value of myDiagram.contextMenu.

For a more regular HTML context menu implementation, see the Custom Context Menu_yoxview sample.

Right-click or tap-hold (mobile) on a Node to bring up a context menu. If you have a selection copied in the clipboard, you can bring up a context menu anywhere to paste.