b00b434c5d
- Gaps between stages are sized from the widest straight-route label, so a chip never reaches into either box; a source's forward routes fan across its side instead of sharing a 20px band. - A label prefers the widest horizontal run that can hold it; when only a stub exists the chip moves onto the edge's longest run and sits beside a vertical one, keeping clear of both the box and the neighbouring label. - Hovering a wire or its chip highlights the route and dims the rest. - System-added routes (the parser's implicit error fallback) draw dotted with a legend entry, distinct from declared routes and executed state. - Lanes are 34px apart, so a dense definition no longer doubles the canvas height. - The graph opens expanded by default and remembers a collapse (graphPrefs.js).
23 lines
788 B
JavaScript
23 lines
788 B
JavaScript
// The workflow graph's expansion preference. The graph is expanded by default;
|
|
// collapsing it is a deliberate choice and is remembered across reloads, so the
|
|
// operator's next visit opens the graph the way they left it.
|
|
|
|
export const GRAPH_EXPANDED_KEY = "pipelines.web.graphExpanded.v1";
|
|
|
|
/** True unless the operator collapsed the graph (a missing value means default). */
|
|
export function readGraphExpanded(storage = globalThis.localStorage) {
|
|
try {
|
|
return storage?.getItem(GRAPH_EXPANDED_KEY) !== "0";
|
|
} catch {
|
|
return true;
|
|
}
|
|
}
|
|
|
|
export function writeGraphExpanded(value, storage = globalThis.localStorage) {
|
|
try {
|
|
storage?.setItem(GRAPH_EXPANDED_KEY, value ? "1" : "0");
|
|
} catch {
|
|
// Storage may be unavailable; the in-memory choice still applies.
|
|
}
|
|
}
|