ContextMenuEntry#
Type alias ContextMenuEntry
Context Menu Entry: {
icon?: string;
isSeparator?: boolean;
isVisible?: ContextMenuVisibleCallback;
label?: string | ContextMenuLabelCallback;
onClick?: ContextMenuClickCallback;
onHover?: ContextMenuHoverCallback;
subEntries?: ContextMenuEntry[] | ContextMenuSubEntryCallback;
}
icon?: string;
isSeparator?: boolean;
isVisible?: ContextMenuVisibleCallback;
label?: string | ContextMenuLabelCallback;
onClick?: ContextMenuClickCallback;
onHover?: ContextMenuHoverCallback;
subEntries?: ContextMenuEntry[] | ContextMenuSubEntryCallback;
}
Type declaration
-
Optional
icon?: stringDefault
undefined
-
Optional
isSeparator?: boolean Specifies if the context menu entry is handled as a simple separation line. In that case all other properties except for the visible-Callback are ignored.
Default
false
-
Optional
isVisible?: ContextMenuVisibleCallback Specifies a callback function which can be used to hide the context menu entry by a user defined logic.
Default
undefined
-
Optional
label?: string | ContextMenuLabelCallbackSpecifies the label of the context menu entry. The label can be set static or dynamic via a ContextMenuLabelCallback.
-
Optional
onClick?: ContextMenuClickCallback Specifies a callback function which is executed when the context menu entry is clicked.
Default
undefined
-
Optional
onHover?: ContextMenuHoverCallback Specifies a callback function which is executed when the context menu entry is hovered.
Default
undefined
-
Optional
subEntries?: ContextMenuEntry[] | ContextMenuSubEntryCallback Specifies a list of sub entries. The sub entries can be set as a static list or as a dynamic list via a ContextMenuSubEntryCallback.
Default
undefined
Specifies the leading icon of the context menu entry. The Icon is specified as a string which references a custom Icon in the form: custom:my-icon-id