Selectable
configurationDefines the Diagram selection options.
By default, you can select shapes in the Diagram in one of two ways:
- Clicking a single shape to select it and deselect any previously selected shapes.
- Holding the
Ctrlkey while clicking multiple shapes to select them and any other shapes between them.
Using the selectable configuration, you can enable single selection only, enable selection by drawing a rectangular area with the mouse around shapes in the canvas, or disable selection altogether.
selectable
Boolean|ObjectDefault: true
selectable.fill
String|ObjectDefines the fill configuration for the selection rectangle.
selectable.key
StringDefines the meta key when doing a visual selection through drawing a rectangular area around shapes in the canvas. This option does not change the way a single shape is selected when using click or tap. To avoid clashes, verify that the selectable.key and pannable.key are different. The available values are:
- "none" - No activation key, visual selection is disabled.
- "ctrl" - The activation key will be
Ctrl. - "shift" - The activation key will be
Shift. - "alt" - The activation key will be
Alt.
This option is not applicable for mobile devices.
Default: "none"
selectable.multiple
BooleanSpecifies if the multiple selection should be enabled.
Default: true
selectable.offset
NumberDefines the offset (in pixels) of the selection rectangle from the shape bounds.
Default: 3
selectable.stroke
ObjectDefines the selection line configuration.