Basic
The smallest useful flow: a BlowCanvas over a list of nodes and a list of edges, with the background, the control bar and the minimap. Everything here works without a line of event handling - the canvas edits the two lists in place as you drag, connect, select and delete.
Press Tab to move between the nodes and edges of the diagram.
Press Enter or Space to select it, Shift with Enter to add it to the selection, the arrow keys to move the selected nodes, Delete to remove them and Escape to clear the selection. Press C to start a connection from it.
Press Enter or Space to select it, Delete to remove it and Escape to clear the selection. Press C to move its end to another node.
bit BlowTry it
- Drag a node to move it; its edges follow.
- Drag from a handle (the dot on a node's edge) to another node's handle to connect them.
- Click a node or an edge to select it, Shift+click to add to the selection, and Shift+drag the background to box-select.
- Press Backspace or Delete to remove what is selected; a deleted node takes its edges with it.
- Drag the background to pan, scroll to zoom and double-click it to zoom in; the control bar's buttons zoom in, zoom out and fit the whole graph in view.
- Click or drag in the minimap (bottom right) to move the view to that part of the graph.
How it works
NodesandEdgesare plainList<BlowNode>andList<BlowEdge>; the canvas adds, moves and removes items in them directly.- A node's
Typepicks the built-in look:inputhas only a source handle,outputonly a target handle, and the default has both. - An edge joins
SourcetoTargetby node id;Labeldraws text on it,Animatedruns dashes along it, andMarkerEnd(on by default) gives it its arrowhead. FitViewOnInitzooms the graph to fit once the nodes are measured.BlowBackground,BlowControlsandBlowMiniMapare add-ons placed inside the canvas. The control bar's lock button is off by default (ShowInteractive), and the minimap isPannableby default.