1A module for inspecting a Factory workflow as a graph or its source
2definition. Use it after Code Panel when a page needs both the complete
3file-browser walkthrough and a focused Blueprint visualization.
4
5Pass the normalized serializable `blueprint` graph and the source
6`files`. The component resolves `factory.yaml` by default; set
7`definitionPath` only when the workflow source lives elsewhere.
8`blueprintLabel` supplies the data-derived factory name shown in the
9Blueprint breadcrumb.
10
11Blueprint is the default view. The Overview rail is permanent and derives
12its Stages, Transitions, and Workers from the graph. Switching to Definition
13changes only the right pane; the same rail, width, selected stage, and inline
14stage details remain mounted. The complete pane header also remains mounted
15and geometrically unchanged: it keeps the factory-to-Blueprint breadcrumb on
16the left and the Blueprint-first toggle on the right. Only the pressed state
17and the content below the header change.
18
19Stages starts expanded. Transitions and Workers start collapsed, retaining
20native mouse and keyboard disclosure behavior. Any user-chosen disclosure
21state persists while switching between Blueprint and Definition. The rail's
22scrollbar track uses the same raised white surface as the rail, with a
23contrasting thumb; the canvas scrollbar remains hidden.
24
25Definition reuses Code Panel's low-level source renderer, including line
26numbers, indentation guides, and optional authored annotations. It
27intentionally shows one workflow definition rather than duplicating Code
28Panel's complete file tree, file-specific header controls, and navigation
29cards. Selecting a stage highlights its complete authored YAML block with
30the existing active-annotation treatment and scrolls that range into view.
31Changing the selected stage replaces the highlight; synthetic nodes without
32an authored block do not create one.
33
34The graph is a normalized projection of the same authored configuration
35model that emits `files`; do not recover it by parsing rendered code lines.
36In the Factory example, the workflow is nested at
37`factory.yaml.blueprint`; there is no separate `blueprint.yaml`.
38
39Blueprint nodes are real HTML buttons and SVG is used only for connectors.
40The canvas keeps an accessible ordered summary, keyboard-scrolling viewport,
41mouse drag-to-pan, and an instructional hint. On narrow viewports the
42persistent rail becomes a bounded strip above the right pane; the schematic
43keeps readable text in a minimum-width two-axis viewport.