@polygonschmied/stellar-diagrams
v0.0.13
Published
Stellar DS UML diagrams — use-case diagrams laid out with dagre and rendered through the shared viz-core look and feel.
Maintainers
Readme
@polygonschmied/stellar-diagrams
UML diagrams for Stellar DS, rendered through the shared
@polygonschmied/stellar-viz-core look and feel so they match the charts and
graphs. All take the generic VizGraph input.
UseCaseDiagram— actors (stick figures), use cases (ellipses), a system boundary box, and the standard relationship notation: association (line), «include»/«extend» (dashed open arrows), generalization (hollow triangle).node.group=actor|usecase,edge.kind=association|include|extend|generalization. dagre left-to-right.Flowchart— terminator / process / decision / I/O shapes flowing top-to-bottom.node.groupselects the shape; branch labels inedge.meta.label. dagrerankdir: TB.SequenceDiagram— participants as lifelines, messages stacked in input (time) order.nodes= participants (column order),edge.kind=sync|return|async, message text inedge.meta.label,source === targetis a self-message. Deterministic positional layout (no dagre).ActivityDiagram— UML activity shapes flowing top-to-bottom: initial dot, bullseye final, rounded-rect action, diamond decision/merge, fork/join bar.node.groupselects the shape; guards inedge.meta.label. dagrerankdir: TB.
UseCaseDiagram / Flowchart / ActivityDiagram are graph-laid-out with
@dagrejs/dagre (MIT); all layouts are deterministic so visual snapshots stay
stable. Interaction: pan/zoom everywhere, plus node dragging on the dagre-based
diagrams (the sequence grid is fixed, so it is pan/zoom only).
import { UseCaseDiagram } from "@polygonschmied/stellar-diagrams";
<UseCaseDiagram
systemName="Shop"
data={{
nodes: [
{ id: "customer", label: "Customer", group: "actor" },
{ id: "checkout", label: "Checkout", group: "usecase" },
{ id: "pay", label: "Pay", group: "usecase" },
],
edges: [
{ source: "customer", target: "checkout", kind: "association" },
{ source: "checkout", target: "pay", kind: "include" },
],
}}
/>;