Constructors
new Menu()
new Menu(client): Menu
Parameters
Parameter | Type |
---|---|
client | EditorClient |
Returns
Methods
addContentDockMenuItem()
addContentDockMenuItem(item): void
Create an icon tied to an action (required) that appears in the left toolbar in Lucidspark and Teamspaces (not in Lucidchart).
The action must be registered with
EditorClient.registerAction
prior to using it in the menu.
Parameters
Parameter | Type | Description |
---|---|---|
item | CustomContentDockMenu | The definition of the new menu item |
Returns
void
addContextMenuItem()
addContextMenuItem(item): void
Create a menu in the right click context menu. Appears in both Lucidspark and Lucidchart.
The action must be registered with
EditorClient.registerAction
prior to using it in the menu.
Parameters
Parameter | Type | Description |
---|---|---|
item | CustomMenuConfig | The definition of the new menu item |
Returns
void
addDropdownMenuItem()
addDropdownMenuItem(item): void
Create a menu in the basic drop down top menus. In Lucidspark this will just be under the generic menu.
In Lucidchart you can configure this to be in any of the other drop down menus.
The action must be registered with
EditorClient.registerAction
prior to using it in the menu.
Parameters
Parameter | Type | Description |
---|---|---|
item | CustomDropdownMenu | The definition of the new menu item |
Returns
void
addMenuItem()
addMenuItem(item): void
Generic function to create a new menu item to trigger custom code.
You can use addDropdownMenuItem, addContextMenuItem, or addContentDockMenuItem for easier to use entrypoints.
The action must be registered with
EditorClient.registerAction
prior to using it in the menu.
Parameters
Parameter | Type | Description |
---|---|---|
item | CustomMenuItem | The definition of the new menu item |
Returns
void