This guide shows how to add a selection area to the canvas. Use the Shift key and the mouse to select multiple nodes with a rectangle, which is a baseline interaction for larger node editors and workflow tools.
Selection area becomes important as soon as users need to move, delete, group, or inspect several nodes at once. Without it, a graph interface quickly becomes frustrating on dense canvases.
[example.html] <<< https://raw.githubusercontent.com/Foblex/f-flow/main/libs/f-examples/extensions/selection-area/example.html [example.ts] <<< https://raw.githubusercontent.com/Foblex/f-flow/main/libs/f-examples/extensions/selection-area/example.ts [example.scss] <<< https://raw.githubusercontent.com/Foblex/f-flow/main/libs/f-examples/extensions/selection-area/example.scss
Once your canvas holds more than a handful of nodes, box selection usually becomes a core interaction instead of an optional enhancement.
It also pairs naturally with grouping, alignment helpers, and undo/redo workflows.