Skip to content
Elements / Data

flow

binds state

Boxes joined by arrows, laid out automatically from a list of steps and where each leads: an approval process, a customer journey, a decision tree. Never give positions.

Spec · edit me

No problems. The parser accepted every line.

Result · try itOpen in playground
Tweak the props
direction

Props

"text"textThe title above the flow, e.g. Claim approval.optional
itemsexpressionThe list of steps, e.g. items=steps. At most 40.required
idnameThe field that identifies each step.id
labelnameThe field with what each box says.label
nextnameThe field with where a step leads: one id, a list of ids, or ids separated by commas. Leave it empty on the last step.next
kindnameThe field with each step's shape: step (a box), decision (a diamond), start or end (a pill).kind
edgesexpressionLabels for arrows, as a list of {from, to, label}, e.g. the Yes and No out of a decision.—
directiondown · rightWhich way it runs: down or right. When right doesn't fit its space, it runs down instead.down
bindstateState that holds the selected step's id. Pressing a step sets it.—
onactionActions to run after a step is selected, with bind= already set, e.g. emit:changed. Separate several with ;—
ifconditionShow only when this expression is true, e.g. if=done or if={count>0}. Every element takes it.—
tipstringA short explanation shown on hover, keyboard focus or a tap, e.g. tip="Orders not yet shipped": for a term or a number some people won't know, instead of more words on screen. It makes the element a Tab stop if it isn't one. Every element takes it.—

SayShape v0.1 is an early prototype under the MIT License. Status · GitHub