add-column
Description
Fires when adding a new column
Usage
"add-column": ({
id?: string | number,
column?: object,
before?: string | number,
skipProvider?: boolean,
}) => void;
Parameters
The callback of the add-column event can take an object with the following parameters:
id
- (optional) the ID of the new columncolumn
- (optional) the data object of the new column. The full list of the column parameters can be found herebefore
- (optional) the ID of the column, before which the new column will be placedskipProvider
- (optional) enables/disables preventing the request from being sent to the server
info
For handling the inner events you can use the Event Bus methods
Example
// create Kanban
const board = new kanban.Kanban("#root", {
columns,
cards
});
// subscribe on the "add-column" event
board.api.on("add-column", (obj) => {
console.log(obj.label);
});
Change log: The id, before and column parameters were added in v1.1