Usage guidesInteraction

Brush select

Drag a rectangle to select nodes whose centers fall inside it.

Drag a rectangle to select nodes whose centers fall inside it.

Configuration

Set the activation key with key. In the example, hold Shift and drag from empty space to select, or drag without a modifier to pan.

Example

Loading example…
Hold Shift and drag a selection rectangle.
const behaviors: BehaviorOption[] = ['drag-canvas', { type: 'brush-select', key: 'shift' }];

Options and defaults