Skip to main content

ActionDescriptionWithCallback

Interface

Menu action which provides a callback function to be executed. Action is executed when user clicks the item.

Properties

action

Action to be executed when user clicks the menu item.

Type

(a?: ActionDescription) => void

Type declaration

Signature

(a?: ActionDescription) => void
Parameters
NameType
a?ActionDescription
Returns

void


checkable

Optional

Whether menu action represents a checkbox state. Set it to true if you need a checkbox.

Type

boolean


checked

Optional

Value of the checkbox.

Type

boolean


checkedStateSource

Optional

Getter to retrieve the current checkbox value.

Type

() => boolean

Type declaration

Signature

() => boolean
Returns

boolean


enabled

Optional

Whether the action is enabled. Set to false to disabled the action.

Type

boolean


Optional

External link (url) which will be opened upon clicking the menu item.

Type

boolean


icon

Optional

A string of SVG icon for an action. A string should be a string representation of SVG (not a path/URL).

Type

string


separator

Optional

Is a menu separator

Type

boolean


shortcut

Optional

Keyboard shortcut for the action. Displayed as hint text.

Type

string


text

Optional

Displayed text for action

Type

string


tooltip

Optional

Tooltip text to be displayed when hovering over the action item.

Type

string