beforeEditorClose

fires before the inline editor of an item is closed

boolean beforeEditorClose(string|number id,string key,string|undefined subheaderId){ ... };

Parameters

idstring|numberthe id of the item
keystringthe name of the property to be edited
subheaderIdstring|undefinedoptional, the id of the edited subheader of a swimlane

Returns

booleanfalse - to block closing of the inline editor, otherwise true

Example

diagram.events.on("beforeEditorClose", (id, key, subheaderId) => {
    console.log(id, key, subheaderId);
    return true;
});
// For diagram editor
editor.diagram.events.on("beforeEditorClose", (id, key, subheaderId) => {
    console.log(id, key, subheaderId);
    return true;
});

Related samples

Change log

Added in v4.0

Back to top