BeforeCollapse

fires before collapsing a shape

void BeforeCollapse(string|number id){ ... };

Parameters

idstring|numberthe id of a shape

Example

diagram.events.on("BeforeCollapse", function(id) {
    console.log("Collapsing " + diagram.data.getItem(id).text);
    return true;
});

Related samples

Details

Returning false from the handler will block the selection.

See also
Back to top