@caddis/cli 0.4.46 → 0.4.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/antigravity-plugin/plugin.json +1 -1
- package/bundles/antigravity-plugin/skills/flow-studio/SKILL.md +2 -1
- package/bundles/antigravity-plugin/skills/flow-studio/model.schema.json +1 -1
- package/bundles/antigravity-plugin/skills/flow-studio/references/design-language.md +10 -2
- package/bundles/antigravity-plugin/skills/flow-studio/references/model-schema.md +1 -0
- package/bundles/antigravity-plugin/skills/flow-studio/scripts/lib/styles.test.mjs +37 -0
- package/bundles/antigravity-plugin/skills/flow-studio/src/chrome.ts +9 -6
- package/bundles/antigravity-plugin/skills/flow-studio/src/controls.ts +1 -1
- package/bundles/antigravity-plugin/skills/flow-studio/src/model.test.ts +8 -0
- package/bundles/antigravity-plugin/skills/flow-studio/src/model.ts +2 -1
- package/bundles/antigravity-plugin/skills/flow-studio/src/notes.ts +1 -1
- package/bundles/antigravity-plugin/skills/flow-studio/src/rules.test.ts +10 -1
- package/bundles/antigravity-plugin/skills/flow-studio/src/rules.ts +6 -0
- package/bundles/antigravity-plugin/skills/flow-studio/src/styles.css +10 -9
- package/bundles/antigravity-plugin/skills/flow-studio/templates/engine.html +27 -16
- package/bundles/antigravity-plugin/skills/flow-studio/templates/flow-studio.css +10 -9
- package/bundles/antigravity-plugin/skills/flow-studio/templates/flow-studio.lib.mjs +21 -8
- package/bundles/codex/.codex/skills/frontend/flow-studio/SKILL.md +2 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/model.schema.json +1 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/references/design-language.md +10 -2
- package/bundles/codex/.codex/skills/frontend/flow-studio/references/model-schema.md +1 -0
- package/bundles/codex/.codex/skills/frontend/flow-studio/scripts/lib/styles.test.mjs +37 -0
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/chrome.ts +9 -6
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/controls.ts +1 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/model.test.ts +8 -0
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/model.ts +2 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/notes.ts +1 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/rules.test.ts +10 -1
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/rules.ts +6 -0
- package/bundles/codex/.codex/skills/frontend/flow-studio/src/styles.css +10 -9
- package/bundles/codex/.codex/skills/frontend/flow-studio/templates/engine.html +27 -16
- package/bundles/codex/.codex/skills/frontend/flow-studio/templates/flow-studio.css +10 -9
- package/bundles/codex/.codex/skills/frontend/flow-studio/templates/flow-studio.lib.mjs +21 -8
- package/bundles/manifest.json +2 -2
- package/package.json +1 -1
|
@@ -70,12 +70,13 @@ In either route, derive node and link IDs from immutable business keys. Preserve
|
|
|
70
70
|
8. **Short titles**: titles fit one line at column width. Long descriptions belong in subtitles or member lists.
|
|
71
71
|
9. **Fixed node dimensions**: node kinds use fixed box sizes so font rendering does not shift layout.
|
|
72
72
|
10. **Reduced motion**: removes all animations while preserving static borders and status glows.
|
|
73
|
+
11. **Thin links, dotted canvas**: links are hairlines (about 1.1 px) and the canvas background is faint dots, not a grid. Both come from tokens (`--edge-w`, `--dot`, ...), so an app can change them with one CSS line; see `references/design-language.md`.
|
|
73
74
|
|
|
74
75
|
## Model summary
|
|
75
76
|
|
|
76
77
|
```
|
|
77
78
|
version 1, meta {title, help, asOf, source, labels?}, layout "columns-lanes" | "free" | "auto"
|
|
78
|
-
columns [{id, title, short?, width, phase?}] stages, left to right
|
|
79
|
+
columns [{id, title, short?, width, phase?, continues?}] stages, left to right
|
|
79
80
|
lanes [{id, title, badge?, badgeTone?, note?, gap?}] rows; gap true = dashed amber lane
|
|
80
81
|
states {id: {word, tone, border, edge, motion, bucket}} tone: ok|warn|crit|info|muted|accent; bucket: good|neutral|gap
|
|
81
82
|
nodes [{id, kind, lane?, col?, colSpan?, row?, x?, y?, w?, h?, state, title, subtitle?, members?, weight?,
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"type": "object", "required": ["id", "title", "width"], "additionalProperties": false,
|
|
27
27
|
"properties": {
|
|
28
28
|
"id": { "type": "string" }, "title": { "type": "string" }, "short": { "type": "string" },
|
|
29
|
-
"width": { "type": "number", "minimum": 60 }, "phase": { "type": "string" }
|
|
29
|
+
"width": { "type": "number", "minimum": 60 }, "phase": { "type": "string" }, "continues": { "type": "boolean" }
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
},
|
|
@@ -24,7 +24,15 @@ Tokens are defined on `:root` and adapted for dark mode via `@media (prefers-col
|
|
|
24
24
|
| `--down` | `#8250df` | `#d0a0ee` | Downstream relation count and notes marker |
|
|
25
25
|
| `--glow` | `rgba(9,105,218,.22)` | `rgba(68,147,248,.35)` | Accent halo for selection, hover, and canvas focus |
|
|
26
26
|
| `--shadow` | `0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08)` | `0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45)` | Elevated card and modal elevation shadow |
|
|
27
|
-
| `--grid` | `rgba(31,35,40,.035)` | `rgba(255,255,255,.04)` |
|
|
27
|
+
| `--grid` | `rgba(31,35,40,.035)` | `rgba(255,255,255,.04)` | Legacy: no longer drawn. The canvas background is dots now (see `--dot`) |
|
|
28
|
+
| `--dot` | `rgba(31,35,40,.18)` | `rgba(255,255,255,.16)` | Colour of the canvas background dots |
|
|
29
|
+
| `--dot-size` | `1.2px` | Same | Radius of a background dot |
|
|
30
|
+
| `--dot-gap` | `24px` | Same | Spacing of the background dots |
|
|
31
|
+
| `--edge-w` | `1.1px` | Same | Width of a normal link (thin, like a hairline; motion carries the state) |
|
|
32
|
+
| `--edge-w-hot` | `1.5px` | Same | Width of a traced or selected link |
|
|
33
|
+
| `--edge-w-play` | `1.6px` | Same | Width of a link while playback runs along it |
|
|
34
|
+
| `--trail-w` | `1.8px` | Same | Width of the draw-in trail on a selected path (divided by the zoom) |
|
|
35
|
+
| `--ripple-w` | `2px` | Same | Width of the what-if ripple (divided by the zoom) |
|
|
28
36
|
| `--ok-bg` | `rgba(26,127,55,.10)` | `rgba(63,185,80,.12)` | Subtle tinted background for healthy states |
|
|
29
37
|
| `--warn-bg` | `rgba(154,103,0,.10)` | `rgba(210,153,34,.14)` | Subtle tinted background for warning states |
|
|
30
38
|
| `--crit-bg` | `rgba(207,34,46,.08)` | `rgba(248,81,73,.12)` | Subtle tinted background for critical states |
|
|
@@ -65,7 +73,7 @@ Layout elements follow a strict 4px grid rhythm:
|
|
|
65
73
|
| xs | 4px to 7px | Button vertical padding (`4px 11px`), card vertical padding (`5px 10px 7px`), playbar gaps (`7px`) |
|
|
66
74
|
| sm | 8px to 10px | Card horizontal padding (`10px`), toolbar item gaps, summary grid gaps |
|
|
67
75
|
| md | 12px to 16px | Page padding (`12px 14px 20px`), header gaps, inspector body padding |
|
|
68
|
-
| lg | 20px to 28px | Section margins, top header padding,
|
|
76
|
+
| lg | 20px to 28px | Section margins, top header padding, dot pitch (24px canvas dots) |
|
|
69
77
|
| xl | 32px to 44px | Column header heights (44px), tool button dimensions (34px x 32px) |
|
|
70
78
|
|
|
71
79
|
---
|
|
@@ -48,6 +48,7 @@ Columns provide vertical partitioning for time, stages, or architecture tiers.
|
|
|
48
48
|
| `short` | `string` | Optional | - | Compact abbreviated title for tight viewports. |
|
|
49
49
|
| `width` | `number` | Required | - | Column width in pixels (minimum 60). |
|
|
50
50
|
| `phase` | `string` | Optional | - | Super-category phase grouping shown in top banner. |
|
|
51
|
+
| `continues` | `boolean` | Optional | `false` | This column is a wrapped continuation of the column before it (for example one long list laid out in three side-by-side columns). It shows no header label and no strip cell of its own: its nodes count into the cell of the column it continues. Not allowed on the first column. |
|
|
51
52
|
|
|
52
53
|
---
|
|
53
54
|
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
// The canvas look is part of the skill's contract: thin lines and a dotted background, both set by tokens
|
|
2
|
+
// an app can override. These tests pin the defaults so a later edit cannot quietly bring back the grid.
|
|
3
|
+
import test from "node:test";
|
|
4
|
+
import assert from "node:assert/strict";
|
|
5
|
+
import { readFileSync } from "node:fs";
|
|
6
|
+
import { fileURLToPath } from "node:url";
|
|
7
|
+
import { join, dirname } from "node:path";
|
|
8
|
+
|
|
9
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..", "..");
|
|
10
|
+
const css = readFileSync(join(root, "src/styles.css"), "utf8");
|
|
11
|
+
|
|
12
|
+
test("the canvas background is dots, not grid lines", () => {
|
|
13
|
+
assert.match(css, /#viewport[\s\S]*radial-gradient\(circle, var\(--dot\) var\(--dot-size\)/);
|
|
14
|
+
assert.doesNotMatch(css, /linear-gradient\(var\(--grid\)/, "grid lines must not come back");
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
test("dots are set by tokens: size, spacing and a colour for light and dark", () => {
|
|
18
|
+
assert.match(css, /--dot-size:\s*1\.2px/);
|
|
19
|
+
assert.match(css, /--dot-gap:\s*24px/);
|
|
20
|
+
const colours = css.match(/--dot:\s*rgba\([^)]*\)/g) ?? [];
|
|
21
|
+
assert.ok(colours.length >= 3, "a dot colour for light, dark by media query and dark by attribute");
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
test("links are thin by default and every width comes from a token", () => {
|
|
25
|
+
assert.match(css, /--edge-w:\s*1\.1px/);
|
|
26
|
+
assert.match(css, /path\.edge \{ fill:none; stroke-width:var\(--edge-w\)/);
|
|
27
|
+
assert.match(css, /path\.edge\.hot \{[^}]*stroke-width:var\(--edge-w-hot\)/);
|
|
28
|
+
assert.match(css, /path\.trail \{[^}]*stroke-width:calc\(var\(--trail-w\)/);
|
|
29
|
+
assert.match(css, /path\.ripple \{[^}]*stroke-width:calc\(var\(--ripple-w\)/);
|
|
30
|
+
// Thin means at most 1.5 px for a plain link and 2 px for the highlighted one.
|
|
31
|
+
const w = (name) => Number(css.match(new RegExp(`${name}:\s*([0-9.]+)px`))[1]);
|
|
32
|
+
assert.ok(w("--edge-w") <= 1.5 && w("--edge-w-hot") <= 2 && w("--ripple-w") <= 2.5 && w("--trail-w") <= 2.5);
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
test("forced-colours mode drops the dot pattern", () => {
|
|
36
|
+
assert.match(css, /@media \(forced-colors: active\) \{ #viewport \{ background: Canvas; \} \}/);
|
|
37
|
+
});
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
import { el, on, type Ctx } from "./ctx.ts";
|
|
5
5
|
import { esc } from "./model.ts";
|
|
6
6
|
import { DASH, toneVar, cssId } from "./stateCss.ts";
|
|
7
|
-
import { bucketOf, columnTitle, effectiveLinks, nodeStateId, nodeVisible } from "./rules.ts";
|
|
7
|
+
import { bucketOf, columnTitle, effectiveLinks, nodeStateId, nodeVisible, stripHeads } from "./rules.ts";
|
|
8
8
|
import { matches } from "./interact.ts";
|
|
9
9
|
|
|
10
10
|
const DEFAULT_LABELS: Record<string, string> = {
|
|
@@ -34,16 +34,19 @@ export function install(ctx: Ctx): void {
|
|
|
34
34
|
|
|
35
35
|
function buildStrip(): void {
|
|
36
36
|
const box = els.strip;
|
|
37
|
+
// One cell per head column: a column that `continues` another counts into the cell before it.
|
|
38
|
+
const heads = stripHeads(model), cells = model.columns.map((c, i) => ({ c, i })).filter(({ i }) => heads[i] === i);
|
|
37
39
|
box.style.display = model.columns.length ? "" : "none";
|
|
38
|
-
box.style.gridTemplateColumns = `repeat(${Math.max(1,
|
|
40
|
+
box.style.gridTemplateColumns = `repeat(${Math.max(1, cells.length)}, minmax(0, 1fr))`;
|
|
39
41
|
if (!box.firstChild) {
|
|
40
|
-
box.innerHTML =
|
|
42
|
+
box.innerHTML = cells.map(({ c }) => `<div class="lcell"><div class="ln">${esc(c.title)}</div><div class="lb"><i class="good"></i><i class="neutral"></i><i class="gap"></i></div><div class="lv"></div></div>`).join("");
|
|
41
43
|
}
|
|
42
|
-
box.querySelectorAll<HTMLElement>(".lcell").forEach((cell,
|
|
43
|
-
|
|
44
|
+
box.querySelectorAll<HTMLElement>(".lcell").forEach((cell, cellIndex) => {
|
|
45
|
+
const i = cells[cellIndex]?.i ?? cellIndex;
|
|
46
|
+
cell.style.setProperty("--i", String(cellIndex));
|
|
44
47
|
let tot = 0, good = 0, neutral = 0, gap = 0;
|
|
45
48
|
for (const n of model.nodes) {
|
|
46
|
-
if (n.col !== i || n.kind === "chip") continue;
|
|
49
|
+
if (heads[n.col ?? -1] !== i || n.kind === "chip") continue;
|
|
47
50
|
if (!visible(n.id)) continue;
|
|
48
51
|
const w = Math.max(1, n.weight ?? 1);
|
|
49
52
|
tot += w;
|
|
@@ -71,7 +71,7 @@ export function install(ctx: Ctx): void {
|
|
|
71
71
|
const cols = els.cols;
|
|
72
72
|
cols.style.display = model.columns.length ? "" : "none";
|
|
73
73
|
if (!cols.firstChild) {
|
|
74
|
-
model.columns.forEach((c, i) => { const h = el("div", "hd"); h.textContent = (c.short ?? c.title).toUpperCase(); h.title = c.title; h.dataset.i = String(i); cols.appendChild(h); });
|
|
74
|
+
model.columns.forEach((c, i) => { const h = el("div", "hd"); h.textContent = c.continues ? "" : (c.short ?? c.title).toUpperCase(); h.title = c.title; h.dataset.i = String(i); cols.appendChild(h); });
|
|
75
75
|
let i = 0;
|
|
76
76
|
while (i < model.columns.length) {
|
|
77
77
|
const name = model.columns[i]?.phase;
|
|
@@ -165,3 +165,11 @@ test("group containment validates ids, ownership, self-reference, and skips grou
|
|
|
165
165
|
assert.ok(found.includes("contains-undefined"));
|
|
166
166
|
assert.ok(found.includes("contains-duplicate"));
|
|
167
167
|
});
|
|
168
|
+
test("a column may continue the one before it", () => {
|
|
169
|
+
const m = base(); m.columns.push({ id: "c2", title: "B", width: 150, continues: true });
|
|
170
|
+
assert.deepEqual(codes(m), []);
|
|
171
|
+
});
|
|
172
|
+
test("the first column cannot continue a column that does not exist", () => {
|
|
173
|
+
const m = base(); m.columns[0]!.continues = true;
|
|
174
|
+
assert.ok(codes(m).includes("column-continues-first"));
|
|
175
|
+
});
|
|
@@ -16,7 +16,7 @@ export interface StateDef {
|
|
|
16
16
|
motion: Motion;
|
|
17
17
|
bucket: Bucket;
|
|
18
18
|
}
|
|
19
|
-
export interface ColumnDef { id: string; title: string; short?: string; width: number; phase?: string }
|
|
19
|
+
export interface ColumnDef { id: string; title: string; short?: string; width: number; phase?: string; continues?: boolean }
|
|
20
20
|
export interface LaneDef { id: string; title: string; badge?: string; badgeTone?: "ok" | "warn" | "muted"; note?: string; gap?: boolean }
|
|
21
21
|
export interface NodeDef {
|
|
22
22
|
id: string;
|
|
@@ -111,6 +111,7 @@ export function validateModel(input: unknown): Issue[] {
|
|
|
111
111
|
if (!Array.isArray(m.lanes) || (m.layout !== "auto" && m.lanes.length === 0)) add("error", "lanes-missing", "lanes", "At least one lane is required.");
|
|
112
112
|
if (!m.states || typeof m.states !== "object" || Object.keys(m.states).length === 0) add("error", "states-missing", "states", "At least one state is required.");
|
|
113
113
|
const columns = Array.isArray(m.columns) ? m.columns : [];
|
|
114
|
+
if (columns[0]?.continues) add("error", "column-continues-first", "columns[0]", "The first column cannot continue a column before it.");
|
|
114
115
|
const lanes = Array.isArray(m.lanes) ? m.lanes : [];
|
|
115
116
|
const states = m.states && typeof m.states === "object" ? m.states : {};
|
|
116
117
|
if (!m.meta || typeof m.meta !== "object" || typeof m.meta.title !== "string") add("error", "meta-missing", "meta", "meta with a title is required.");
|
|
@@ -70,7 +70,7 @@ export function install(ctx: Ctx): void {
|
|
|
70
70
|
const markdown = (): string => {
|
|
71
71
|
const out = [`# ${model.meta.title}`, "", model.meta.help, "", `As of ${model.meta.asOf}. Source: ${model.meta.source}`, "", "## States"];
|
|
72
72
|
for (const [id, s] of Object.entries(model.states)) out.push(`- **${s.word}** (${id}): tone ${s.tone}, border ${s.border}, link ${s.edge}, motion ${s.motion}, bucket ${s.bucket}`);
|
|
73
|
-
out.push("", "## Columns", ...model.columns.map((c, i) => `${i + 1}. ${c.title}${c.phase ? ` (${c.phase})` : ""}`));
|
|
73
|
+
out.push("", "## Columns", ...model.columns.filter(c => !c.continues).map((c, i) => `${i + 1}. ${c.title}${c.phase ? ` (${c.phase})` : ""}`));
|
|
74
74
|
out.push("", "## Lanes", ...model.lanes.map(l => `- ${l.title}${l.badge ? ` [${l.badge}]` : ""}${l.note ? `: ${l.note}` : ""}`));
|
|
75
75
|
out.push("", `## Size`, `${model.nodes.length} nodes, ${model.links.length} links.`);
|
|
76
76
|
if (notes.length) out.push("", "## Notes", ...notes.map(n => `${n.id}. **${n.title}**: ${n.text}`));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { test } from "node:test";
|
|
2
2
|
import assert from "node:assert/strict";
|
|
3
3
|
import type { Model } from "./model.ts";
|
|
4
|
-
import { baselineView, defaultView, nodeVisible, nodeStateId, linkVisible, linkStateId, isNew, isImproved, bucketOf, canonOf, effectiveLinks, initialCollapsed, columnTitle, toggleGroupState } from "./rules.ts";
|
|
4
|
+
import { baselineView, defaultView, nodeVisible, nodeStateId, linkVisible, linkStateId, isNew, isImproved, bucketOf, canonOf, effectiveLinks, initialCollapsed, columnTitle, toggleGroupState, stripHeads } from "./rules.ts";
|
|
5
5
|
|
|
6
6
|
const m = (): Model => ({
|
|
7
7
|
version: 1,
|
|
@@ -133,3 +133,12 @@ test("toggleGroup selects a visible child on expansion and its group on collapse
|
|
|
133
133
|
assert.equal(folded.collapsed.has("group"), true);
|
|
134
134
|
assert.equal(toggleGroupState(mm, "full", starting, "missing"), null);
|
|
135
135
|
});
|
|
136
|
+
|
|
137
|
+
test("stripHeads: a continuing column joins the one before it", () => {
|
|
138
|
+
const mm = m();
|
|
139
|
+
mm.columns = [{ id: "a", title: "A", width: 100 }, { id: "p", title: "P", width: 100 }, { id: "p2", title: "P", width: 100, continues: true }, { id: "p3", title: "P", width: 100, continues: true }, { id: "z", title: "Z", width: 100 }];
|
|
140
|
+
assert.deepEqual(stripHeads(mm), [0, 1, 1, 1, 4]);
|
|
141
|
+
});
|
|
142
|
+
test("stripHeads: with no continuing column every column is its own head", () => {
|
|
143
|
+
assert.deepEqual(stripHeads(m()), [0, 1]);
|
|
144
|
+
});
|
|
@@ -10,6 +10,12 @@ export const defaultView = (m: Model): string => (m.views?.find(v => v.default)
|
|
|
10
10
|
/** A group that contains nodes starts folded unless it explicitly opts out. */
|
|
11
11
|
export const initialCollapsed = (m: Model): Set<string> => new Set(m.nodes
|
|
12
12
|
.filter(n => n.kind === "group" && n.contains && n.collapsed !== false).map(n => n.id));
|
|
13
|
+
/** For each column, the index of the column whose header and strip cell it shares: itself, or (when it
|
|
14
|
+
* `continues` another) the nearest earlier column that does not. */
|
|
15
|
+
export const stripHeads = (m: Model): number[] => {
|
|
16
|
+
let head = 0;
|
|
17
|
+
return m.columns.map((c, i) => { if (!c.continues || i === 0) head = i; return head; });
|
|
18
|
+
};
|
|
13
19
|
export const columnTitle = (m: Model, n: NodeDef): string => n.col === undefined ? "" : m.columns[n.col]?.title ?? "";
|
|
14
20
|
|
|
15
21
|
export function groupFor(m: Model, nodeId: string): NodeDef | undefined {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
:root {
|
|
2
2
|
--bg:#f6f8fa; --panel:#ffffff; --panel2:#f6f8fa; --edge:#d0d7de; --rule:#d8dee4; --fg:#1f2328; --muted:#59636e;
|
|
3
3
|
--accent:#0969da; --accent-solid:#0969da; --ok:#1a7f37; --warn:#9a6700; --crit:#cf222e; --glow:rgba(9,105,218,.22);
|
|
4
|
-
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035);
|
|
4
|
+
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035); --dot:rgba(31,35,40,.18); --dot-size:1.2px; --dot-gap:24px; --edge-w:1.1px; --edge-w-hot:1.5px; --edge-w-play:1.6px; --trail-w:1.8px; --ripple-w:2px;
|
|
5
5
|
--warn-bg:rgba(154,103,0,.10); --ok-bg:rgba(26,127,55,.10); --crit-bg:rgba(207,34,46,.08); --info-bg:rgba(9,105,218,.10);
|
|
6
6
|
--mono:"IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, Menlo, monospace;
|
|
7
7
|
}
|
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
:root:not([data-theme="light"]) {
|
|
10
10
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
11
11
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
12
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
12
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
13
13
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
:root[data-theme="dark"] {
|
|
17
17
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
18
18
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
19
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
19
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
20
20
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
21
21
|
}
|
|
22
22
|
* { box-sizing:border-box; }
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
.workspace { display:block; height:max(540px, calc(100vh - 232px)); border:1px solid var(--edge); background:var(--panel); border-radius:12px; overflow:hidden; box-shadow:var(--shadow); }
|
|
59
59
|
.canvaswrap { position:relative; display:flex; flex-direction:column; min-width:0; min-height:0; height:100%; }
|
|
60
60
|
#viewport { position:relative; flex:1; min-height:0; overflow:hidden; cursor:grab; touch-action:none; user-select:none;
|
|
61
|
-
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%),
|
|
61
|
+
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%), radial-gradient(circle, var(--dot) var(--dot-size), transparent calc(var(--dot-size) + .5px)) 0 0 / var(--dot-gap) var(--dot-gap), var(--bg); }
|
|
62
62
|
#viewport.panning { cursor:grabbing; } #viewport.hand .node { cursor:grab; }
|
|
63
63
|
#world { position:absolute; left:0; top:0; transform-origin:0 0; will-change:transform; }
|
|
64
64
|
#viewport.anim #world, #viewport.anim .hd, #viewport.anim .ph { transition:transform .28s cubic-bezier(.2,.8,.2,1), left .28s cubic-bezier(.2,.8,.2,1), width .28s cubic-bezier(.2,.8,.2,1); }
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
.cor.up { right:6px; background:var(--info-bg); color:var(--accent); } .cor.meas { right:6px; background:var(--ok-bg); color:var(--ok); } .cor.up + .cor.meas { right:27px; }
|
|
93
93
|
.node.hascor .t { padding-right:24px; } .node.hascor2 .t { padding-right:44px; }
|
|
94
94
|
#viewport.lod1 .node .s, #viewport.lod1 .bandlabel .bn { display:none; } #viewport.lod2 .node .cor, #viewport.lod2 .node.ref .s { display:none; }
|
|
95
|
-
path.edge { fill:none; stroke-width:
|
|
96
|
-
path.edge.hot { stroke:var(--accent); stroke-width:
|
|
95
|
+
path.edge { fill:none; stroke-width:var(--edge-w); transition:opacity .35s; vector-effect:non-scaling-stroke; }
|
|
96
|
+
path.edge.hot { stroke:var(--accent); stroke-width:var(--edge-w-hot); opacity:1; stroke-dasharray:6 8; animation:flowhot .9s linear infinite; filter:drop-shadow(0 0 3px var(--accent)); }
|
|
97
97
|
path.edge.dim { opacity:.07; filter:none; } path.edge.off { opacity:0; }
|
|
98
98
|
.elabel { position:absolute; font-size:11px; padding:0 6px; border-radius:9px; background:var(--panel); border:1px solid var(--edge); color:var(--muted); white-space:nowrap; transform:translate(-50%,-50%); opacity:0; transition:opacity .35s; z-index:4; } .elabel.show { opacity:1; } .elabel.off { display:none; }
|
|
99
99
|
#cols { position:absolute; left:0; right:0; top:0; height:44px; pointer-events:none; z-index:20; background:linear-gradient(var(--bg) 62%, transparent); }
|
|
@@ -146,8 +146,8 @@
|
|
|
146
146
|
.node.lit { border-color:var(--accent); box-shadow:0 0 0 2px var(--glow), 0 0 18px var(--glow), var(--shadow); }
|
|
147
147
|
.node.sel { animation:selpulse 2.4s ease-out infinite; }
|
|
148
148
|
.node.fail { border-color:var(--crit); background:var(--crit-bg); box-shadow:0 0 0 2px var(--crit-bg), 0 0 20px color-mix(in srgb, var(--crit) 45%, transparent); animation:failflash .9s ease-out 1; } .node.fail .s { color:var(--crit); font-weight:600; }
|
|
149
|
-
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(
|
|
150
|
-
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(
|
|
149
|
+
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(var(--trail-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--accent)); opacity:.95; }
|
|
150
|
+
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(var(--ripple-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--crit)); }
|
|
151
151
|
.intro .band { animation:fadein .6s both; } .intro .node { animation:rise .55s both; animation-delay:calc(var(--c, 0) * 60ms + 150ms); } .intro #edges { animation:fadein 1s .5s both; }
|
|
152
152
|
.intro .lcell, .intro .tile { animation:rise .5s both; animation-delay:calc(var(--i, 0) * 55ms); }
|
|
153
153
|
#viewport:focus-visible { outline-offset:-2px; }
|
|
@@ -171,7 +171,7 @@
|
|
|
171
171
|
#pbChoices { display:flex; gap:5px; flex-wrap:wrap; } #pbChoices:empty { display:none; }
|
|
172
172
|
#pbChoices .suggested { border-color:var(--accent); box-shadow:inset 0 -2px 0 var(--accent); }
|
|
173
173
|
circle.token { fill:var(--accent); stroke:var(--panel); stroke-width:2; filter:drop-shadow(0 0 5px var(--accent)); pointer-events:none; }
|
|
174
|
-
path.edge.playing { stroke:var(--accent); stroke-width:
|
|
174
|
+
path.edge.playing { stroke:var(--accent); stroke-width:var(--edge-w-play); filter:drop-shadow(0 0 4px var(--accent)); opacity:1; }
|
|
175
175
|
path.edge.visited { stroke:var(--accent); opacity:.7; }
|
|
176
176
|
.node.playing { outline:2px solid var(--accent); outline-offset:2px; }
|
|
177
177
|
/* The pulse runs only while the player really plays; a paused step keeps the plain outline. */
|
|
@@ -188,3 +188,4 @@
|
|
|
188
188
|
.node.gateway:has(.metric-badge) .gw-title, .node.gateway.has-metrics .gw-title { width:45%; margin-right:42px; }
|
|
189
189
|
.node .spark polyline, .metrics polyline { fill:none; stroke:var(--accent); stroke-width:1.5; }
|
|
190
190
|
.metrics svg { max-width:100%; margin-top:8px; } .metric-range { display:flex; justify-content:space-between; width:300px; max-width:100%; font:10px var(--mono); color:var(--muted); }
|
|
191
|
+
@media (forced-colors: active) { #viewport { background: Canvas; } }
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<style>:root {
|
|
16
16
|
--bg:#f6f8fa; --panel:#ffffff; --panel2:#f6f8fa; --edge:#d0d7de; --rule:#d8dee4; --fg:#1f2328; --muted:#59636e;
|
|
17
17
|
--accent:#0969da; --accent-solid:#0969da; --ok:#1a7f37; --warn:#9a6700; --crit:#cf222e; --glow:rgba(9,105,218,.22);
|
|
18
|
-
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035);
|
|
18
|
+
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035); --dot:rgba(31,35,40,.18); --dot-size:1.2px; --dot-gap:24px; --edge-w:1.1px; --edge-w-hot:1.5px; --edge-w-play:1.6px; --trail-w:1.8px; --ripple-w:2px;
|
|
19
19
|
--warn-bg:rgba(154,103,0,.10); --ok-bg:rgba(26,127,55,.10); --crit-bg:rgba(207,34,46,.08); --info-bg:rgba(9,105,218,.10);
|
|
20
20
|
--mono:"IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, Menlo, monospace;
|
|
21
21
|
}
|
|
@@ -23,14 +23,14 @@
|
|
|
23
23
|
:root:not([data-theme="light"]) {
|
|
24
24
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
25
25
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
26
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
26
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
27
27
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
30
|
:root[data-theme="dark"] {
|
|
31
31
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
32
32
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
33
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
33
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
34
34
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
35
35
|
}
|
|
36
36
|
* { box-sizing:border-box; }
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
.workspace { display:block; height:max(540px, calc(100vh - 232px)); border:1px solid var(--edge); background:var(--panel); border-radius:12px; overflow:hidden; box-shadow:var(--shadow); }
|
|
73
73
|
.canvaswrap { position:relative; display:flex; flex-direction:column; min-width:0; min-height:0; height:100%; }
|
|
74
74
|
#viewport { position:relative; flex:1; min-height:0; overflow:hidden; cursor:grab; touch-action:none; user-select:none;
|
|
75
|
-
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%),
|
|
75
|
+
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%), radial-gradient(circle, var(--dot) var(--dot-size), transparent calc(var(--dot-size) + .5px)) 0 0 / var(--dot-gap) var(--dot-gap), var(--bg); }
|
|
76
76
|
#viewport.panning { cursor:grabbing; } #viewport.hand .node { cursor:grab; }
|
|
77
77
|
#world { position:absolute; left:0; top:0; transform-origin:0 0; will-change:transform; }
|
|
78
78
|
#viewport.anim #world, #viewport.anim .hd, #viewport.anim .ph { transition:transform .28s cubic-bezier(.2,.8,.2,1), left .28s cubic-bezier(.2,.8,.2,1), width .28s cubic-bezier(.2,.8,.2,1); }
|
|
@@ -106,8 +106,8 @@
|
|
|
106
106
|
.cor.up { right:6px; background:var(--info-bg); color:var(--accent); } .cor.meas { right:6px; background:var(--ok-bg); color:var(--ok); } .cor.up + .cor.meas { right:27px; }
|
|
107
107
|
.node.hascor .t { padding-right:24px; } .node.hascor2 .t { padding-right:44px; }
|
|
108
108
|
#viewport.lod1 .node .s, #viewport.lod1 .bandlabel .bn { display:none; } #viewport.lod2 .node .cor, #viewport.lod2 .node.ref .s { display:none; }
|
|
109
|
-
path.edge { fill:none; stroke-width:
|
|
110
|
-
path.edge.hot { stroke:var(--accent); stroke-width:
|
|
109
|
+
path.edge { fill:none; stroke-width:var(--edge-w); transition:opacity .35s; vector-effect:non-scaling-stroke; }
|
|
110
|
+
path.edge.hot { stroke:var(--accent); stroke-width:var(--edge-w-hot); opacity:1; stroke-dasharray:6 8; animation:flowhot .9s linear infinite; filter:drop-shadow(0 0 3px var(--accent)); }
|
|
111
111
|
path.edge.dim { opacity:.07; filter:none; } path.edge.off { opacity:0; }
|
|
112
112
|
.elabel { position:absolute; font-size:11px; padding:0 6px; border-radius:9px; background:var(--panel); border:1px solid var(--edge); color:var(--muted); white-space:nowrap; transform:translate(-50%,-50%); opacity:0; transition:opacity .35s; z-index:4; } .elabel.show { opacity:1; } .elabel.off { display:none; }
|
|
113
113
|
#cols { position:absolute; left:0; right:0; top:0; height:44px; pointer-events:none; z-index:20; background:linear-gradient(var(--bg) 62%, transparent); }
|
|
@@ -160,8 +160,8 @@
|
|
|
160
160
|
.node.lit { border-color:var(--accent); box-shadow:0 0 0 2px var(--glow), 0 0 18px var(--glow), var(--shadow); }
|
|
161
161
|
.node.sel { animation:selpulse 2.4s ease-out infinite; }
|
|
162
162
|
.node.fail { border-color:var(--crit); background:var(--crit-bg); box-shadow:0 0 0 2px var(--crit-bg), 0 0 20px color-mix(in srgb, var(--crit) 45%, transparent); animation:failflash .9s ease-out 1; } .node.fail .s { color:var(--crit); font-weight:600; }
|
|
163
|
-
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(
|
|
164
|
-
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(
|
|
163
|
+
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(var(--trail-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--accent)); opacity:.95; }
|
|
164
|
+
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(var(--ripple-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--crit)); }
|
|
165
165
|
.intro .band { animation:fadein .6s both; } .intro .node { animation:rise .55s both; animation-delay:calc(var(--c, 0) * 60ms + 150ms); } .intro #edges { animation:fadein 1s .5s both; }
|
|
166
166
|
.intro .lcell, .intro .tile { animation:rise .5s both; animation-delay:calc(var(--i, 0) * 55ms); }
|
|
167
167
|
#viewport:focus-visible { outline-offset:-2px; }
|
|
@@ -185,7 +185,7 @@
|
|
|
185
185
|
#pbChoices { display:flex; gap:5px; flex-wrap:wrap; } #pbChoices:empty { display:none; }
|
|
186
186
|
#pbChoices .suggested { border-color:var(--accent); box-shadow:inset 0 -2px 0 var(--accent); }
|
|
187
187
|
circle.token { fill:var(--accent); stroke:var(--panel); stroke-width:2; filter:drop-shadow(0 0 5px var(--accent)); pointer-events:none; }
|
|
188
|
-
path.edge.playing { stroke:var(--accent); stroke-width:
|
|
188
|
+
path.edge.playing { stroke:var(--accent); stroke-width:var(--edge-w-play); filter:drop-shadow(0 0 4px var(--accent)); opacity:1; }
|
|
189
189
|
path.edge.visited { stroke:var(--accent); opacity:.7; }
|
|
190
190
|
.node.playing { outline:2px solid var(--accent); outline-offset:2px; }
|
|
191
191
|
/* The pulse runs only while the player really plays; a paused step keeps the plain outline. */
|
|
@@ -202,6 +202,7 @@
|
|
|
202
202
|
.node.gateway:has(.metric-badge) .gw-title, .node.gateway.has-metrics .gw-title { width:45%; margin-right:42px; }
|
|
203
203
|
.node .spark polyline, .metrics polyline { fill:none; stroke:var(--accent); stroke-width:1.5; }
|
|
204
204
|
.metrics svg { max-width:100%; margin-top:8px; } .metric-range { display:flex; justify-content:space-between; width:300px; max-width:100%; font:10px var(--mono); color:var(--muted); }
|
|
205
|
+
@media (forced-colors: active) { #viewport { background: Canvas; } }
|
|
205
206
|
</style>
|
|
206
207
|
</head>
|
|
207
208
|
<body>
|
|
@@ -285,6 +286,7 @@
|
|
|
285
286
|
if (!Array.isArray(m.lanes) || m.layout !== "auto" && m.lanes.length === 0) add("error", "lanes-missing", "lanes", "At least one lane is required.");
|
|
286
287
|
if (!m.states || typeof m.states !== "object" || Object.keys(m.states).length === 0) add("error", "states-missing", "states", "At least one state is required.");
|
|
287
288
|
const columns = Array.isArray(m.columns) ? m.columns : [];
|
|
289
|
+
if (columns[0]?.continues) add("error", "column-continues-first", "columns[0]", "The first column cannot continue a column before it.");
|
|
288
290
|
const lanes = Array.isArray(m.lanes) ? m.lanes : [];
|
|
289
291
|
const states = m.states && typeof m.states === "object" ? m.states : {};
|
|
290
292
|
if (!m.meta || typeof m.meta !== "object" || typeof m.meta.title !== "string") add("error", "meta-missing", "meta", "meta with a title is required.");
|
|
@@ -590,6 +592,13 @@
|
|
|
590
592
|
var baselineView = (m) => m.views?.[0]?.id ?? "all";
|
|
591
593
|
var defaultView = (m) => (m.views?.find((v) => v.default) ?? m.views?.[0])?.id ?? "all";
|
|
592
594
|
var initialCollapsed = (m) => new Set(m.nodes.filter((n) => n.kind === "group" && n.contains && n.collapsed !== false).map((n) => n.id));
|
|
595
|
+
var stripHeads = (m) => {
|
|
596
|
+
let head = 0;
|
|
597
|
+
return m.columns.map((c, i) => {
|
|
598
|
+
if (!c.continues || i === 0) head = i;
|
|
599
|
+
return head;
|
|
600
|
+
});
|
|
601
|
+
};
|
|
593
602
|
var columnTitle = (m, n) => n.col === void 0 ? "" : m.columns[n.col]?.title ?? "";
|
|
594
603
|
function groupFor(m, nodeId) {
|
|
595
604
|
return m.nodes.find((n) => n.kind === "group" && n.contains?.includes(nodeId));
|
|
@@ -1414,7 +1423,7 @@
|
|
|
1414
1423
|
if (!cols.firstChild) {
|
|
1415
1424
|
model.columns.forEach((c, i2) => {
|
|
1416
1425
|
const h = el("div", "hd");
|
|
1417
|
-
h.textContent = (c.short ?? c.title).toUpperCase();
|
|
1426
|
+
h.textContent = c.continues ? "" : (c.short ?? c.title).toUpperCase();
|
|
1418
1427
|
h.title = c.title;
|
|
1419
1428
|
h.dataset.i = String(i2);
|
|
1420
1429
|
cols.appendChild(h);
|
|
@@ -1800,16 +1809,18 @@
|
|
|
1800
1809
|
}
|
|
1801
1810
|
function buildStrip() {
|
|
1802
1811
|
const box = els.strip;
|
|
1812
|
+
const heads = stripHeads(model), cells = model.columns.map((c, i) => ({ c, i })).filter(({ i }) => heads[i] === i);
|
|
1803
1813
|
box.style.display = model.columns.length ? "" : "none";
|
|
1804
|
-
box.style.gridTemplateColumns = `repeat(${Math.max(1,
|
|
1814
|
+
box.style.gridTemplateColumns = `repeat(${Math.max(1, cells.length)}, minmax(0, 1fr))`;
|
|
1805
1815
|
if (!box.firstChild) {
|
|
1806
|
-
box.innerHTML =
|
|
1816
|
+
box.innerHTML = cells.map(({ c }) => `<div class="lcell"><div class="ln">${esc(c.title)}</div><div class="lb"><i class="good"></i><i class="neutral"></i><i class="gap"></i></div><div class="lv"></div></div>`).join("");
|
|
1807
1817
|
}
|
|
1808
|
-
box.querySelectorAll(".lcell").forEach((cell,
|
|
1809
|
-
|
|
1818
|
+
box.querySelectorAll(".lcell").forEach((cell, cellIndex) => {
|
|
1819
|
+
const i = cells[cellIndex]?.i ?? cellIndex;
|
|
1820
|
+
cell.style.setProperty("--i", String(cellIndex));
|
|
1810
1821
|
let tot = 0, good = 0, neutral = 0, gap = 0;
|
|
1811
1822
|
for (const n of model.nodes) {
|
|
1812
|
-
if (n.col !== i || n.kind === "chip") continue;
|
|
1823
|
+
if (heads[n.col ?? -1] !== i || n.kind === "chip") continue;
|
|
1813
1824
|
if (!visible(n.id)) continue;
|
|
1814
1825
|
const w = Math.max(1, n.weight ?? 1);
|
|
1815
1826
|
tot += w;
|
|
@@ -2028,7 +2039,7 @@
|
|
|
2028
2039
|
const markdown = () => {
|
|
2029
2040
|
const out = [`# ${model.meta.title}`, "", model.meta.help, "", `As of ${model.meta.asOf}. Source: ${model.meta.source}`, "", "## States"];
|
|
2030
2041
|
for (const [id, s] of Object.entries(model.states)) out.push(`- **${s.word}** (${id}): tone ${s.tone}, border ${s.border}, link ${s.edge}, motion ${s.motion}, bucket ${s.bucket}`);
|
|
2031
|
-
out.push("", "## Columns", ...model.columns.map((c, i) => `${i + 1}. ${c.title}${c.phase ? ` (${c.phase})` : ""}`));
|
|
2042
|
+
out.push("", "## Columns", ...model.columns.filter((c) => !c.continues).map((c, i) => `${i + 1}. ${c.title}${c.phase ? ` (${c.phase})` : ""}`));
|
|
2032
2043
|
out.push("", "## Lanes", ...model.lanes.map((l) => `- ${l.title}${l.badge ? ` [${l.badge}]` : ""}${l.note ? `: ${l.note}` : ""}`));
|
|
2033
2044
|
out.push("", `## Size`, `${model.nodes.length} nodes, ${model.links.length} links.`);
|
|
2034
2045
|
if (notes.length) out.push("", "## Notes", ...notes.map((n) => `${n.id}. **${n.title}**: ${n.text}`));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
:root {
|
|
2
2
|
--bg:#f6f8fa; --panel:#ffffff; --panel2:#f6f8fa; --edge:#d0d7de; --rule:#d8dee4; --fg:#1f2328; --muted:#59636e;
|
|
3
3
|
--accent:#0969da; --accent-solid:#0969da; --ok:#1a7f37; --warn:#9a6700; --crit:#cf222e; --glow:rgba(9,105,218,.22);
|
|
4
|
-
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035);
|
|
4
|
+
--up:#0a7ea4; --down:#8250df; --shadow:0 1px 0 rgba(31,35,40,.04), 0 6px 18px rgba(31,35,40,.08); --grid:rgba(31,35,40,.035); --dot:rgba(31,35,40,.18); --dot-size:1.2px; --dot-gap:24px; --edge-w:1.1px; --edge-w-hot:1.5px; --edge-w-play:1.6px; --trail-w:1.8px; --ripple-w:2px;
|
|
5
5
|
--warn-bg:rgba(154,103,0,.10); --ok-bg:rgba(26,127,55,.10); --crit-bg:rgba(207,34,46,.08); --info-bg:rgba(9,105,218,.10);
|
|
6
6
|
--mono:"IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, Menlo, monospace;
|
|
7
7
|
}
|
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
:root:not([data-theme="light"]) {
|
|
10
10
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
11
11
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
12
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
12
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
13
13
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
:root[data-theme="dark"] {
|
|
17
17
|
--bg:#0d1117; --panel:#161b22; --panel2:#0d1117; --edge:#30363d; --rule:#2b323a; --fg:#e6edf3; --muted:#9198a1;
|
|
18
18
|
--accent:#4493f8; --accent-solid:#1f6feb; --ok:#3fb950; --warn:#d29922; --crit:#f85149; --glow:rgba(68,147,248,.35);
|
|
19
|
-
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04);
|
|
19
|
+
--up:#6fcbe6; --down:#d0a0ee; --shadow:0 1px 0 rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.45); --grid:rgba(255,255,255,.04); --dot:rgba(255,255,255,.16);
|
|
20
20
|
--warn-bg:rgba(210,153,34,.14); --ok-bg:rgba(63,185,80,.12); --crit-bg:rgba(248,81,73,.12); --info-bg:rgba(68,147,248,.14);
|
|
21
21
|
}
|
|
22
22
|
* { box-sizing:border-box; }
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
.workspace { display:block; height:max(540px, calc(100vh - 232px)); border:1px solid var(--edge); background:var(--panel); border-radius:12px; overflow:hidden; box-shadow:var(--shadow); }
|
|
59
59
|
.canvaswrap { position:relative; display:flex; flex-direction:column; min-width:0; min-height:0; height:100%; }
|
|
60
60
|
#viewport { position:relative; flex:1; min-height:0; overflow:hidden; cursor:grab; touch-action:none; user-select:none;
|
|
61
|
-
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%),
|
|
61
|
+
background:radial-gradient(760px 380px at 4% 0%, var(--glow), transparent 65%), radial-gradient(640px 320px at 98% 100%, color-mix(in srgb, var(--ok) 16%, transparent), transparent 70%), radial-gradient(circle, var(--dot) var(--dot-size), transparent calc(var(--dot-size) + .5px)) 0 0 / var(--dot-gap) var(--dot-gap), var(--bg); }
|
|
62
62
|
#viewport.panning { cursor:grabbing; } #viewport.hand .node { cursor:grab; }
|
|
63
63
|
#world { position:absolute; left:0; top:0; transform-origin:0 0; will-change:transform; }
|
|
64
64
|
#viewport.anim #world, #viewport.anim .hd, #viewport.anim .ph { transition:transform .28s cubic-bezier(.2,.8,.2,1), left .28s cubic-bezier(.2,.8,.2,1), width .28s cubic-bezier(.2,.8,.2,1); }
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
.cor.up { right:6px; background:var(--info-bg); color:var(--accent); } .cor.meas { right:6px; background:var(--ok-bg); color:var(--ok); } .cor.up + .cor.meas { right:27px; }
|
|
93
93
|
.node.hascor .t { padding-right:24px; } .node.hascor2 .t { padding-right:44px; }
|
|
94
94
|
#viewport.lod1 .node .s, #viewport.lod1 .bandlabel .bn { display:none; } #viewport.lod2 .node .cor, #viewport.lod2 .node.ref .s { display:none; }
|
|
95
|
-
path.edge { fill:none; stroke-width:
|
|
96
|
-
path.edge.hot { stroke:var(--accent); stroke-width:
|
|
95
|
+
path.edge { fill:none; stroke-width:var(--edge-w); transition:opacity .35s; vector-effect:non-scaling-stroke; }
|
|
96
|
+
path.edge.hot { stroke:var(--accent); stroke-width:var(--edge-w-hot); opacity:1; stroke-dasharray:6 8; animation:flowhot .9s linear infinite; filter:drop-shadow(0 0 3px var(--accent)); }
|
|
97
97
|
path.edge.dim { opacity:.07; filter:none; } path.edge.off { opacity:0; }
|
|
98
98
|
.elabel { position:absolute; font-size:11px; padding:0 6px; border-radius:9px; background:var(--panel); border:1px solid var(--edge); color:var(--muted); white-space:nowrap; transform:translate(-50%,-50%); opacity:0; transition:opacity .35s; z-index:4; } .elabel.show { opacity:1; } .elabel.off { display:none; }
|
|
99
99
|
#cols { position:absolute; left:0; right:0; top:0; height:44px; pointer-events:none; z-index:20; background:linear-gradient(var(--bg) 62%, transparent); }
|
|
@@ -146,8 +146,8 @@
|
|
|
146
146
|
.node.lit { border-color:var(--accent); box-shadow:0 0 0 2px var(--glow), 0 0 18px var(--glow), var(--shadow); }
|
|
147
147
|
.node.sel { animation:selpulse 2.4s ease-out infinite; }
|
|
148
148
|
.node.fail { border-color:var(--crit); background:var(--crit-bg); box-shadow:0 0 0 2px var(--crit-bg), 0 0 20px color-mix(in srgb, var(--crit) 45%, transparent); animation:failflash .9s ease-out 1; } .node.fail .s { color:var(--crit); font-weight:600; }
|
|
149
|
-
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(
|
|
150
|
-
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(
|
|
149
|
+
path.trail { fill:none; stroke:var(--accent); vector-effect:none; stroke-width:calc(var(--trail-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--accent)); opacity:.95; }
|
|
150
|
+
path.ripple { fill:none; stroke:var(--crit); vector-effect:none; stroke-width:calc(var(--ripple-w) / var(--k, 1)); stroke-linecap:round; filter:drop-shadow(0 0 4px var(--crit)); }
|
|
151
151
|
.intro .band { animation:fadein .6s both; } .intro .node { animation:rise .55s both; animation-delay:calc(var(--c, 0) * 60ms + 150ms); } .intro #edges { animation:fadein 1s .5s both; }
|
|
152
152
|
.intro .lcell, .intro .tile { animation:rise .5s both; animation-delay:calc(var(--i, 0) * 55ms); }
|
|
153
153
|
#viewport:focus-visible { outline-offset:-2px; }
|
|
@@ -171,7 +171,7 @@
|
|
|
171
171
|
#pbChoices { display:flex; gap:5px; flex-wrap:wrap; } #pbChoices:empty { display:none; }
|
|
172
172
|
#pbChoices .suggested { border-color:var(--accent); box-shadow:inset 0 -2px 0 var(--accent); }
|
|
173
173
|
circle.token { fill:var(--accent); stroke:var(--panel); stroke-width:2; filter:drop-shadow(0 0 5px var(--accent)); pointer-events:none; }
|
|
174
|
-
path.edge.playing { stroke:var(--accent); stroke-width:
|
|
174
|
+
path.edge.playing { stroke:var(--accent); stroke-width:var(--edge-w-play); filter:drop-shadow(0 0 4px var(--accent)); opacity:1; }
|
|
175
175
|
path.edge.visited { stroke:var(--accent); opacity:.7; }
|
|
176
176
|
.node.playing { outline:2px solid var(--accent); outline-offset:2px; }
|
|
177
177
|
/* The pulse runs only while the player really plays; a paused step keeps the plain outline. */
|
|
@@ -188,3 +188,4 @@
|
|
|
188
188
|
.node.gateway:has(.metric-badge) .gw-title, .node.gateway.has-metrics .gw-title { width:45%; margin-right:42px; }
|
|
189
189
|
.node .spark polyline, .metrics polyline { fill:none; stroke:var(--accent); stroke-width:1.5; }
|
|
190
190
|
.metrics svg { max-width:100%; margin-top:8px; } .metric-range { display:flex; justify-content:space-between; width:300px; max-width:100%; font:10px var(--mono); color:var(--muted); }
|
|
191
|
+
@media (forced-colors: active) { #viewport { background: Canvas; } }
|