beforeCollapse
Description
Fires before collapsing an item
Usage
beforeCollapse: (
id: string | number,
dir?: string
) => boolean | void;
Parameters
The callback of the event takes the following parameters:
id
- (required) the id of an itemdir
- (optional) the side the children will be hidden in relation to the parent shape ("left" or "right" for type:"topic", otherwise - undefined)