Skip to content

Vizel API / core/src / VizelToolbarAction

Interface: VizelToolbarAction ​

Defined in: packages/core/src/toolbar/actions.ts:10

A single toolbar action definition.

Properties ​

group ​

ts
group: string;

Defined in: packages/core/src/toolbar/actions.ts:18

Group identifier for visual separation


icon ​

ts
icon: VizelIconName;

Defined in: packages/core/src/toolbar/actions.ts:16

Icon name from the Vizel icon system


id ​

ts
id: string;

Defined in: packages/core/src/toolbar/actions.ts:12

Unique action identifier


isActive ​

ts
isActive: (editor) => boolean;

Defined in: packages/core/src/toolbar/actions.ts:20

Check if this action is currently active

Parameters ​

ParameterType
editorEditor

Returns ​

boolean


isEnabled ​

ts
isEnabled: (editor) => boolean;

Defined in: packages/core/src/toolbar/actions.ts:22

Check if this action can be executed

Parameters ​

ParameterType
editorEditor

Returns ​

boolean


label ​

ts
label: string;

Defined in: packages/core/src/toolbar/actions.ts:14

Display label


run ​

ts
run: (editor) => void;

Defined in: packages/core/src/toolbar/actions.ts:24

Execute the action

Parameters ​

ParameterType
editorEditor

Returns ​

void


shortcut? ​

ts
optional shortcut?: string;

Defined in: packages/core/src/toolbar/actions.ts:26

Optional keyboard shortcut label for tooltip

Released under the MIT License.