Skip to main content

locale

Description

Optional. An object that defines a custom locale for the Toolbar.

info

The locale object should include all labels for both Kanban and Toolbar along with their translations.

Usage

locale?: object;

Default config

By default, Toolbar is set to the English locale. You can also specify your own custom locale.

tip

To switch the locale on the fly, you can use the Toolbar's setLocale() method.

Example

// create Kanban
const board = new kanban.Kanban("#root", {
locale: cn
});
// create Toolbar
new kanban.Toolbar("#toolbar", {
api: board.api,
locale: cn // apply the "cn" locale to Toolbar
});

Related articles: Localization

Related sample: Kanban. Localization