IItem Interface

A structure defining common properties of buttons in the Toolbox.

example
"Toolbox": {
    "buttons": [
        {
            "translationKey": "Toolbox.ADD_TEXT",
            "translationKeyTitle": "Toolbox.TITLE_ADD_TEXT",
            "nameDialogEnabled": true,
            "iconClass": "cc-icon-add-text",
            "action": "Text"
        },
        {
            "translationKey": "Toolbox.IMAGE",
            "translationKeyTitle": "Toolbox.TITLE_ADD_IMAGE",
            "nameDialogEnabled": true,
            "iconClass": "cc-icon-add-image",
            "action": "Image"
        }
    ]
}

Properties

Optional iconClass

iconClass: string

The class of the button icon. You can find the complete list of available icon classes in \src\design-editor\Styles\ControlStyles\sp-icons.less.

Optional itemConfig

A structure containing the configuration of new design elements. For an example, you can refer to ILocationDefaultConfig or IBarcodeDefaultConfig.

Optional nameDialogEnabled

nameDialogEnabled: boolean

Enables a dialog box to type in the name of a new design element. The default value is false.

Optional translationKey

translationKey: string

The translation key of the button caption. The corresponding string should be defined in the ~\Configuration\translations.json file.

Optional translationKeyTitle

translationKeyTitle: string

The translation key of the button tooltip. The corresponding string should be defined in the ~\Configuration\translations.json file.