Function: useEventTreeContextMenuClick()
useEventTreeContextMenuClick(
id):object
Defined in: app/hooks/eventTree/useEventTreeContextMenuClick.ts:20
Hook for handling context menu click event.
This hook provides a function handleContextMenuClick that can be used to update the state of the event tree based on the selected node type. It utilizes the React Flow library for managing nodes and edges in a flowchart-like UI.
Parameters
id
string
The unique identifier for each node.
Returns
object
handleContextMenuClick()
handleContextMenuClick: (
contextMenuClickEvent) =>void
Parameters
contextMenuClickEvent
MouseEvent
Returns
void
Example
typescript
const { handleContextMenuClick } = useEventTreeContextMenuClick('uniqueNodeId');