15 lines
791 B
Markdown
15 lines
791 B
Markdown
# Architecture
|
|
|
|
`core/diagram.ts` parses fixed, bounded flowchart, sequence, class, state, ER,
|
|
mind-map and timeline grammars into nodes, edges and line diagnostics, then lays
|
|
them out deterministically as escaped SVG. ER attribute blocks and sequence
|
|
notes, class member blocks and labelled state transitions/boundaries become
|
|
inert model data; directives, click handlers, remote resources and styling
|
|
commands are rejected rather than interpreted. Layout dimensions are derived
|
|
from the bounded model rather than clipping nodes to a fixed viewport.
|
|
|
|
React retains the last successful SVG after errors, imports/exports source and
|
|
the normalized JSON model, and delegates optional PNG rasterization to a local
|
|
canvas. Generated SVG contains only application-owned geometry and escaped
|
|
text.
|