Graph editor

The canvas is Prodigy (Bevy / WebAssembly). HTML around it does not draw the DAG; it only tells Prodigy what to do.

Pointer

InputEffect
Left click empty canvasClear selection and search focus
Shift + left click emptyCreate a node at that world point, select it, open Create Node. Canceling the dialog deletes the node (it was never confirmed). Confirming sets name/role and dirties the graph.
Left click a nodeReplace the selection with that node (see Selection)
⌘ / Ctrl + left click a nodeAdd or remove that node from the selection
Shift + left click another nodeCycle the edge between primary and clicked: none → directed primary → clicked → bidirected → undirected → delete.
Drag a nodeMove it. Dirty. In a live session, move_node is sent on drag end.
Right-dragPan the camera
WheelZoom. Orthographic scale is clamped relative to the fit-to-graph scale.

Shift is also used for create-on-empty, so connect and create do not collide: empty vs node hit.

Keyboard

Ignored while a <dialog open> is up or while focus is in an INPUT / TEXTAREA / SELECT (search and modals).

KeyEffect
EEdit the primary selected node (name, role, flags)
UToggle unobserved (latent) on the primary node
AToggle adjusted on the primary node
SToggle selection node on the primary node
X, Backspace, DeleteDelete the primary selected node and its edges

Additive selection does not change that: E, U, A, S, and X always hit primary (the most recently chosen node). Paths uses the full set.

What “structural” means

Dirty (and live ops) come from the graph, not the view:

  • Node create/delete/rename/role/unobserved/adjusted/selection
  • Edge add/remove (including bidirected and undirected)
  • Node positions (drag)
  • Layout stretch (Scale X/Y) and Layout (spring)

Camera, search ring, node/edge size, and canvas tools do not write the graph.

Load and fit

Loading a snapshot (CBOR) or a live state (JSON) replaces every node and edge, then fits the camera to the bounding box with padding. Search may zoom in further so a node is at least ~16px radius on screen.

Dual bodies

Every node has both a circle mesh and a SEM rectangle mesh. Only one is visible and pickable at a time (see SEM). Edges re-route to the active body.