@tangle-network/charts 0.15.1 → 0.17.0
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/README.md +15 -6
- package/dist/{flow-trace-B5dlYNsD.d.ts → flow-trace-Cti_6fZP.d.ts} +25 -1
- package/dist/index.d.ts +56 -2
- package/dist/index.js +234 -1
- package/dist/react/flow-waterfall.css +297 -68
- package/dist/react/index.d.ts +17 -3
- package/dist/react/index.js +1747 -368
- package/package.json +1 -1
|
@@ -1,76 +1,305 @@
|
|
|
1
|
-
/* Standalone surface: consumes Brand
|
|
1
|
+
/* Standalone surface: consumes Brand tokens; no Tailwind build required.
|
|
2
|
+
* Geometry reads three variables the clock writes every frame: --fw-t (clock ms), --fw-v0 (window start ms)
|
|
3
|
+
* and --fw-k (px per ms). A mark carries --s and --e (its start and end ms), so growth, playback and zoom
|
|
4
|
+
* move marks without a React render.
|
|
5
|
+
* Type uses four sizes (11, 13, 14, 20 px); spacing sits on a 4 px grid. */
|
|
2
6
|
.fw-root {
|
|
3
|
-
--
|
|
4
|
-
--
|
|
5
|
-
--
|
|
6
|
-
--
|
|
7
|
-
--fw-
|
|
8
|
-
--fw-
|
|
9
|
-
--fw-
|
|
10
|
-
--fw-
|
|
11
|
-
--fw-well: var(--
|
|
12
|
-
--fw-
|
|
7
|
+
--fw-text: var(--text-primary, light-dark(#23232b, #ececf1));
|
|
8
|
+
--fw-muted: var(--text-muted, light-dark(#5d5d68, #a4a4b0));
|
|
9
|
+
--fw-faint: color-mix(in oklab, var(--fw-muted) 70%, transparent);
|
|
10
|
+
--fw-surface: var(--bg-card, light-dark(#ffffff, #17171d));
|
|
11
|
+
--fw-raised: var(--bg-elevated, light-dark(#ffffff, #1f1f27));
|
|
12
|
+
--fw-border: var(--border-subtle, light-dark(rgb(0 0 0 / .09), rgb(255 255 255 / .09)));
|
|
13
|
+
--fw-grid: color-mix(in oklab, var(--fw-text) 6%, transparent);
|
|
14
|
+
--fw-guide: color-mix(in oklab, var(--fw-text) 13%, transparent);
|
|
15
|
+
--fw-well: color-mix(in oklab, var(--fw-text) 4.5%, var(--fw-surface));
|
|
16
|
+
--fw-hover: color-mix(in oklab, var(--fw-text) 4%, transparent);
|
|
17
|
+
--fw-accent: var(--accent-text, light-dark(#4f46e5, #a5b4fc));
|
|
18
|
+
--fw-failed: light-dark(#d4304a, #ff5c74);
|
|
19
|
+
--fw-ok: var(--status-running, light-dark(#0d8a5f, #34c48c));
|
|
20
|
+
--fw-amber: light-dark(#a35d00, #f2b14c);
|
|
21
|
+
--fw-neutral-bar: color-mix(in oklab, var(--fw-text) 15%, var(--fw-surface));
|
|
22
|
+
--fw-hatch: color-mix(in oklab, var(--fw-text) 22%, transparent);
|
|
23
|
+
/* Root agent neutral, then five agent hues. Each passes 3:1 against both surfaces as a mark. */
|
|
24
|
+
--fw-h0: light-dark(#6c6f84, #a3a6bb);
|
|
25
|
+
--fw-h1: light-dark(#4b55d6, #8f96ff);
|
|
26
|
+
--fw-h2: light-dark(#c3570f, #f2913f);
|
|
27
|
+
--fw-h3: light-dark(#0b87a0, #35c2db);
|
|
28
|
+
--fw-h4: light-dark(#b0418a, #dc72bb);
|
|
29
|
+
--fw-h5: light-dark(#6d44c7, #ab8cf7);
|
|
30
|
+
--fw-ease: cubic-bezier(.2, .8, .2, 1);
|
|
31
|
+
--fw-bar-h: 16px;
|
|
32
|
+
position: relative;
|
|
33
|
+
container-type: inline-size;
|
|
34
|
+
min-width: 0;
|
|
13
35
|
color: var(--fw-text);
|
|
14
36
|
background: var(--fw-surface);
|
|
15
37
|
border: 1px solid var(--fw-border);
|
|
16
|
-
border-radius:
|
|
17
|
-
|
|
18
|
-
font:
|
|
19
|
-
|
|
20
|
-
|
|
38
|
+
border-radius: 12px;
|
|
39
|
+
font-family: var(--font-sans, Inter, ui-sans-serif, system-ui, sans-serif);
|
|
40
|
+
font-size: 13px;
|
|
41
|
+
line-height: 20px;
|
|
42
|
+
font-feature-settings: "tnum" 1, "cv11" 1;
|
|
43
|
+
-webkit-font-smoothing: antialiased;
|
|
21
44
|
}
|
|
45
|
+
.fw-root-agents { --fw-bar-h: 20px; border-radius: 16px; }
|
|
22
46
|
.fw-root *, .fw-root *::before, .fw-root *::after { box-sizing: border-box; }
|
|
23
|
-
.fw-root :is(p, dl, dd) { margin: 0; }
|
|
24
|
-
.fw-root
|
|
25
|
-
.fw-root
|
|
26
|
-
.fw-root
|
|
27
|
-
.fw-root
|
|
28
|
-
.fw-root
|
|
29
|
-
.fw-root
|
|
30
|
-
.fw-root
|
|
31
|
-
.fw-root
|
|
32
|
-
.fw-root
|
|
33
|
-
.fw-root
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
.fw-root .fw-
|
|
42
|
-
.fw-root .fw-
|
|
43
|
-
.fw-root .fw-
|
|
44
|
-
.fw-root .fw-
|
|
45
|
-
.fw-root .fw-
|
|
46
|
-
.fw-root .fw-
|
|
47
|
-
.fw-root .fw-
|
|
48
|
-
.fw-root .fw-
|
|
49
|
-
.fw-root .fw-
|
|
50
|
-
.fw-root .fw-
|
|
51
|
-
.fw-root .fw-
|
|
52
|
-
.fw-root .fw-
|
|
53
|
-
.fw-root .fw-
|
|
54
|
-
.fw-root .fw-
|
|
55
|
-
.fw-root .fw-
|
|
56
|
-
.fw-root .fw-
|
|
57
|
-
.fw-root .fw-
|
|
58
|
-
.fw-root .fw-
|
|
59
|
-
.fw-root .fw-
|
|
60
|
-
.fw-root .fw-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
.fw-root .fw-
|
|
64
|
-
.fw-root .fw-
|
|
65
|
-
.fw-root .fw-
|
|
66
|
-
.fw-root .fw-
|
|
67
|
-
.fw-root .fw-
|
|
68
|
-
.fw-root .fw-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
.fw-root .fw-
|
|
47
|
+
.fw-root :is(p, dl, dd, h3, ul) { margin: 0; padding: 0; }
|
|
48
|
+
.fw-root :is(button, input, select) { font: inherit; color: inherit; }
|
|
49
|
+
.fw-root :is(button, input, select, [tabindex]):focus-visible { outline: 2px solid var(--fw-accent); outline-offset: 1px; }
|
|
50
|
+
.fw-root :is(button, select):disabled { opacity: .45; cursor: default; }
|
|
51
|
+
.fw-root [data-tone="0"] { --tone: var(--fw-h0); }
|
|
52
|
+
.fw-root [data-tone="1"] { --tone: var(--fw-h1); }
|
|
53
|
+
.fw-root [data-tone="2"] { --tone: var(--fw-h2); }
|
|
54
|
+
.fw-root [data-tone="3"] { --tone: var(--fw-h3); }
|
|
55
|
+
.fw-root [data-tone="4"] { --tone: var(--fw-h4); }
|
|
56
|
+
.fw-root [data-tone="5"] { --tone: var(--fw-h5); }
|
|
57
|
+
.fw-root [data-tone] {
|
|
58
|
+
--fill: light-dark(color-mix(in oklab, var(--tone) 24%, #fff), color-mix(in oklab, var(--tone) 86%, #000));
|
|
59
|
+
--line: light-dark(color-mix(in oklab, var(--tone) 62%, #fff), var(--tone));
|
|
60
|
+
--dim: light-dark(color-mix(in oklab, var(--tone) 12%, #fff), color-mix(in oklab, var(--tone) 40%, #17171d));
|
|
61
|
+
--dim-line: light-dark(color-mix(in oklab, var(--tone) 36%, #fff), color-mix(in oklab, var(--tone) 55%, #17171d));
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* Header */
|
|
65
|
+
.fw-root .fw-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--fw-border); flex-wrap: wrap; }
|
|
66
|
+
.fw-root .fw-title-block { min-width: 0; display: grid; gap: 2px; }
|
|
67
|
+
.fw-root .fw-title-line { display: flex; align-items: center; gap: 8px; min-width: 0; }
|
|
68
|
+
.fw-root .fw-title-glyph { display: inline-flex; color: var(--fw-accent); }
|
|
69
|
+
.fw-root .fw-title { font-size: 14px; line-height: 20px; font-weight: 600; letter-spacing: -.005em; white-space: nowrap; }
|
|
70
|
+
.fw-root .fw-state { display: inline-flex; align-items: center; gap: 6px; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 500; color: var(--fw-muted); background: var(--fw-well); flex-shrink: 0; }
|
|
71
|
+
.fw-root .fw-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
|
|
72
|
+
.fw-root .fw-state-live { color: var(--fw-accent); background: color-mix(in oklab, var(--fw-accent) 12%, transparent); }
|
|
73
|
+
.fw-root .fw-state-live::before { animation: fw-pulse 1.6s var(--fw-ease) infinite; }
|
|
74
|
+
.fw-root .fw-headline { color: var(--fw-muted); font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 6px; }
|
|
75
|
+
.fw-root .fw-done-mark { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--fw-ok); color: var(--fw-ok); font-size: 11px; line-height: 1; }
|
|
76
|
+
.fw-root .fw-tools { display: flex; align-items: center; gap: 8px; }
|
|
77
|
+
.fw-root .fw-views { display: inline-flex; padding: 2px; border-radius: 8px; background: var(--fw-well); border: 1px solid var(--fw-border); }
|
|
78
|
+
.fw-root .fw-view-button { appearance: none; border: 0; background: transparent; height: 24px; padding: 0 10px; border-radius: 6px; font-size: 13px; color: var(--fw-muted); cursor: pointer; transition: background-color 120ms var(--fw-ease), color 120ms var(--fw-ease); }
|
|
79
|
+
.fw-root .fw-view-button[aria-checked="true"] { background: var(--fw-surface); color: var(--fw-text); box-shadow: 0 1px 2px rgb(0 0 0 / .12), 0 0 0 1px var(--fw-border); }
|
|
80
|
+
.fw-root .fw-search { position: relative; display: flex; align-items: center; }
|
|
81
|
+
.fw-root .fw-search-glyph { position: absolute; left: 8px; display: inline-flex; color: var(--fw-muted); pointer-events: none; }
|
|
82
|
+
.fw-root .fw-search-input { appearance: none; width: 200px; height: 32px; padding: 0 10px 0 28px; border: 1px solid var(--fw-border); border-radius: 8px; background: var(--fw-well); font-size: 13px; }
|
|
83
|
+
.fw-root .fw-search-input::placeholder { color: var(--fw-muted); }
|
|
84
|
+
.fw-root .fw-search-input::-webkit-search-cancel-button { display: none; }
|
|
85
|
+
|
|
86
|
+
/* KPI row */
|
|
87
|
+
.fw-root .fw-summary { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); border-bottom: 1px solid var(--fw-border); }
|
|
88
|
+
.fw-root .fw-summary > div { padding: 12px 16px; min-width: 0; }
|
|
89
|
+
.fw-root .fw-summary > div + div { border-left: 1px solid var(--fw-border); }
|
|
90
|
+
.fw-root .fw-summary dt { font-size: 11px; line-height: 16px; color: var(--fw-muted); }
|
|
91
|
+
.fw-root .fw-value { margin-top: 4px; font-size: 20px; line-height: 24px; font-weight: 500; letter-spacing: -.01em; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
|
92
|
+
.fw-root .fw-has-errors .fw-value { color: var(--fw-failed); }
|
|
93
|
+
|
|
94
|
+
/* Axis */
|
|
95
|
+
.fw-root .fw-axis { display: grid; grid-template-columns: min(var(--fw-name-w), 42%) minmax(0, 1fr); height: 32px; color: var(--fw-muted); font-size: 11px; }
|
|
96
|
+
.fw-root .fw-axis-top { border-bottom: 1px solid var(--fw-border); }
|
|
97
|
+
.fw-root .fw-axis-bottom { height: 28px; border-top: 1px solid var(--fw-border); }
|
|
98
|
+
.fw-root .fw-axis-label { position: relative; display: flex; align-items: center; gap: 6px; padding: 0 12px 0 16px; border-right: 1px solid var(--fw-border); min-width: 0; }
|
|
99
|
+
.fw-root .fw-axis-bottom .fw-axis-label { border-right-color: transparent; }
|
|
100
|
+
.fw-root .fw-branch-controls { margin-left: auto; display: flex; gap: 2px; }
|
|
101
|
+
.fw-root .fw-text-button { appearance: none; border: 0; background: transparent; height: 24px; padding: 0 6px; border-radius: 6px; font-size: 11px; color: var(--fw-muted); cursor: pointer; white-space: nowrap; }
|
|
102
|
+
.fw-root .fw-text-button:hover { background: var(--fw-hover); color: var(--fw-text); }
|
|
103
|
+
.fw-root .fw-resize { position: absolute; top: 0; right: -4px; width: 8px; height: 100%; cursor: col-resize; z-index: 2; }
|
|
104
|
+
.fw-root .fw-resize:hover, .fw-root .fw-resize:focus-visible { background: linear-gradient(90deg, transparent 3px, var(--fw-accent) 3px 5px, transparent 5px); outline: 0; }
|
|
105
|
+
.fw-root .fw-axis-track { position: relative; overflow: hidden; cursor: ew-resize; touch-action: none; }
|
|
106
|
+
.fw-root .fw-tick { position: absolute; top: 50%; transform: translate(4px, -50%); left: calc(var(--fw-pad) + (var(--s) - var(--fw-v0)) * var(--fw-k) * 1px); font-variant-numeric: tabular-nums; white-space: nowrap; line-height: 16px; }
|
|
107
|
+
.fw-root .fw-cursor-handle { position: absolute; width: 9px; height: 9px; border-radius: 50%; background: var(--fw-text); box-shadow: 0 0 0 2px var(--fw-surface); left: calc(var(--fw-pad) + (var(--fw-t) - var(--fw-v0)) * var(--fw-k) * 1px - 4.5px); bottom: -5px; z-index: 3; }
|
|
108
|
+
.fw-root .fw-axis-bottom .fw-cursor-handle { top: -5px; bottom: auto; }
|
|
109
|
+
|
|
110
|
+
/* Body */
|
|
111
|
+
.fw-root .fw-viewport { position: relative; }
|
|
112
|
+
.fw-root .fw-scroller { position: relative; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; scrollbar-width: thin; outline: 0; }
|
|
113
|
+
.fw-root .fw-canvas { position: relative; }
|
|
114
|
+
.fw-root .fw-gridlayer, .fw-root .fw-cursor-layer { position: absolute; top: 0; bottom: 0; left: min(var(--fw-name-w), 42%); right: 0; overflow: hidden; pointer-events: none; }
|
|
115
|
+
.fw-root .fw-gridline { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--fw-grid); left: calc(var(--fw-pad) + (var(--s) - var(--fw-v0)) * var(--fw-k) * 1px); }
|
|
116
|
+
.fw-root .fw-cursor-layer { z-index: 3; }
|
|
117
|
+
.fw-root .fw-marker-layer { position: absolute; top: 0; bottom: 0; left: min(var(--fw-name-w), 42%); right: 0; overflow: hidden; pointer-events: none; z-index: 2; }
|
|
118
|
+
.fw-root .fw-marker { --fw-marker: var(--fw-muted); position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px dashed var(--fw-marker); left: calc(var(--fw-pad) + (var(--s) - var(--fw-v0)) * var(--fw-k) * 1px); }
|
|
119
|
+
.fw-root .fw-marker[data-tone="ok"] { --fw-marker: var(--fw-ok); }
|
|
120
|
+
.fw-root .fw-marker[data-tone="failed"] { --fw-marker: var(--fw-failed); }
|
|
121
|
+
.fw-root .fw-marker-label { position: absolute; top: 2px; left: 3px; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 5px; border-radius: 4px; font-size: 11px; line-height: 16px; color: var(--fw-marker); background: var(--fw-surface); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-marker) 40%, transparent); }
|
|
122
|
+
.fw-root .fw-cursor { position: absolute; top: 0; bottom: 0; width: 1px; background: color-mix(in oklab, var(--fw-text) 70%, transparent); left: calc(var(--fw-pad) + (var(--fw-t) - var(--fw-v0)) * var(--fw-k) * 1px); }
|
|
123
|
+
.fw-root .fw-empty { padding: 40px 16px; text-align: center; color: var(--fw-muted); }
|
|
124
|
+
.fw-root .fw-sticky { position: absolute; top: 0; left: 0; right: 0; z-index: 2; background: var(--fw-surface); box-shadow: 0 1px 0 var(--fw-border), 0 6px 12px -8px rgb(0 0 0 / .35); }
|
|
125
|
+
|
|
126
|
+
/* Rows */
|
|
127
|
+
.fw-root .fw-row { position: absolute; top: 0; left: 0; right: 0; height: var(--fw-row-h); display: grid; grid-template-columns: min(var(--fw-name-w), 42%) minmax(0, 1fr); outline: 0; contain: layout style; }
|
|
128
|
+
.fw-root .fw-row:hover { background: var(--fw-hover); }
|
|
129
|
+
.fw-root .fw-row.fw-active { background: color-mix(in oklab, var(--fw-accent) 7%, transparent); }
|
|
130
|
+
.fw-root .fw-row[aria-selected="true"] { background: color-mix(in oklab, var(--fw-accent) 11%, transparent); }
|
|
131
|
+
.fw-root .fw-row:focus-visible { box-shadow: inset 2px 0 0 var(--fw-accent); }
|
|
132
|
+
.fw-root .fw-sticky-row { background: var(--fw-surface); }
|
|
133
|
+
.fw-root .fw-label { position: relative; display: flex; align-items: center; gap: 6px; min-width: 0; padding: 0 12px 0 calc(12px + var(--depth) * 16px); border-right: 1px solid var(--fw-border); }
|
|
134
|
+
.fw-root .fw-guides { position: absolute; top: 0; bottom: 0; left: 20px; width: calc(var(--depth) * 16px); background: repeating-linear-gradient(90deg, var(--fw-guide) 0 1px, transparent 1px 16px); }
|
|
135
|
+
.fw-root .fw-toggle, .fw-root .fw-toggle-space { flex: 0 0 16px; width: 16px; height: 16px; }
|
|
136
|
+
.fw-root .fw-toggle { appearance: none; display: grid; place-items: center; padding: 0; border: 0; border-radius: 4px; background: transparent; color: var(--fw-muted); cursor: pointer; }
|
|
137
|
+
.fw-root .fw-toggle svg { width: 12px; height: 12px; transition: transform 160ms var(--fw-ease); }
|
|
138
|
+
.fw-root .fw-toggle.fw-open svg { transform: rotate(90deg); }
|
|
139
|
+
.fw-root .fw-toggle:hover { background: var(--fw-hover); color: var(--fw-text); }
|
|
140
|
+
.fw-root .fw-icon-tile { flex: 0 0 20px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 6px; border: 1px solid var(--fw-border); background: var(--fw-surface); color: var(--line, var(--fw-muted)); }
|
|
141
|
+
.fw-root .fw-icon-tile :is(svg, img) { width: 13px; height: 13px; }
|
|
142
|
+
.fw-root .fw-row .fw-names { font-size: 14px; }
|
|
143
|
+
.fw-root .fw-names { display: flex; align-items: baseline; gap: 6px; min-width: 0; overflow: hidden; white-space: nowrap; }
|
|
144
|
+
.fw-root .fw-span-name { display: inline-flex; align-items: center; gap: 6px; overflow: hidden; flex-shrink: 0; max-width: 100%; min-width: 0; }
|
|
145
|
+
.fw-root .fw-name-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
|
|
146
|
+
.fw-root .fw-strong { font-weight: 600; }
|
|
147
|
+
.fw-root .fw-detail { color: var(--fw-muted); overflow: hidden; min-width: 0; display: inline-flex; align-items: center; gap: 4px; max-width: 100%; }
|
|
148
|
+
.fw-root .fw-detail-icon { display: inline-flex; }
|
|
149
|
+
.fw-root .fw-detail-icon :is(svg, img) { width: 12px; height: 12px; }
|
|
150
|
+
.fw-root .fw-count { flex-shrink: 0; height: 18px; padding: 0 6px; border-radius: 999px; background: var(--fw-well); border: 1px solid var(--fw-border); color: var(--fw-muted); font-size: 11px; line-height: 16px; font-variant-numeric: tabular-nums; }
|
|
151
|
+
.fw-root .fw-alert { display: inline-flex; color: var(--fw-failed); flex-shrink: 0; }
|
|
152
|
+
.fw-root .fw-alert svg { width: 13px; height: 13px; }
|
|
153
|
+
.fw-root .fw-spinner { width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid color-mix(in oklab, var(--fw-accent) 30%, transparent); border-top-color: var(--fw-accent); animation: fw-spin .8s linear infinite; flex-shrink: 0; }
|
|
154
|
+
|
|
155
|
+
/* Agent rows: a dot, the agent and its model on a second line. */
|
|
156
|
+
.fw-root .fw-view-agents .fw-label { padding-left: 16px; gap: 10px; border-right: 0; }
|
|
157
|
+
.fw-root .fw-view-agents .fw-names { flex-direction: column; align-items: flex-start; gap: 0; }
|
|
158
|
+
.fw-root .fw-view-agents .fw-span-name { font-weight: 500; line-height: 18px; }
|
|
159
|
+
.fw-root .fw-view-agents .fw-detail { font-size: 11px; line-height: 16px; }
|
|
160
|
+
.fw-root .fw-agent-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--line, var(--fw-muted)); align-self: flex-start; margin-top: calc((var(--fw-row-h) - 34px) / 2 + 6px); }
|
|
161
|
+
|
|
162
|
+
/* Lanes and marks */
|
|
163
|
+
.fw-root .fw-lane { position: relative; overflow: hidden; min-width: 0; }
|
|
164
|
+
.fw-root .fw-invalid { position: absolute; left: var(--fw-pad); top: 50%; transform: translateY(-50%); color: var(--fw-muted); }
|
|
165
|
+
.fw-root :is(.fw-bar, .fw-seg, .fw-end) {
|
|
166
|
+
--x0: calc(var(--fw-pad) + (var(--s) - var(--fw-v0)) * var(--fw-k) * 1px);
|
|
167
|
+
--w: calc(max(0, min(var(--e), var(--fw-t)) - var(--s)) * var(--fw-k) * 1px);
|
|
168
|
+
--on: clamp(0, (var(--fw-t) - var(--s)) * 1000, 1);
|
|
169
|
+
position: absolute;
|
|
170
|
+
top: 50%;
|
|
171
|
+
left: var(--x0);
|
|
172
|
+
opacity: var(--on);
|
|
173
|
+
}
|
|
174
|
+
.fw-root :is(.fw-bar, .fw-seg) { height: var(--fw-bar-h); margin-top: calc(var(--fw-bar-h) / -2); width: max(var(--w), calc(var(--on) * 3px)); border-radius: 4px; cursor: pointer; display: flex; align-items: center; justify-content: center; overflow: hidden; }
|
|
175
|
+
.fw-root .fw-bar { background: var(--fill); box-shadow: inset 0 0 0 1px var(--line); }
|
|
176
|
+
.fw-root .fw-bar.fw-k-tool { background: var(--dim); box-shadow: inset 0 0 0 1px var(--dim-line); }
|
|
177
|
+
/* A handoff is a moment: a slim pill in the receiving tone, not a block of work. */
|
|
178
|
+
.fw-root .fw-bar.fw-k-handoff { background: var(--line); height: 6px; margin-top: -3px; box-shadow: none; }
|
|
179
|
+
.fw-root .fw-bar.fw-k-waiting { background: repeating-linear-gradient(-45deg, var(--fw-hatch) 0 1px, transparent 1px 5px); box-shadow: inset 0 0 0 1px var(--fw-hatch); }
|
|
180
|
+
.fw-root .fw-bar.fw-k-failed { background: color-mix(in oklab, var(--fw-failed) 22%, var(--fw-surface)); box-shadow: inset 0 0 0 1px var(--fw-failed); color: var(--fw-failed); }
|
|
181
|
+
.fw-root .fw-bar.fw-k-pipeline { background: linear-gradient(90deg, var(--fw-neutral-bar), color-mix(in oklab, var(--fw-neutral-bar) 55%, var(--fw-surface))); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-text) 12%, transparent); }
|
|
182
|
+
.fw-root .fw-bar.fw-k-pipeline.fw-has-marks { background: color-mix(in oklab, var(--tone) 9%, transparent); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--tone) 18%, transparent); }
|
|
183
|
+
.fw-root .fw-bar.fw-k-pipeline.fw-has-agents { background: repeating-linear-gradient(-45deg, var(--fw-hatch) 0 1px, transparent 1px 5px), color-mix(in oklab, var(--fw-text) 4%, transparent); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-text) 12%, transparent); }
|
|
184
|
+
.fw-root .fw-bar.fw-approx { opacity: calc(var(--on) * .7); }
|
|
185
|
+
.fw-root .fw-seg { width: max(calc(var(--w) - 2px), calc(var(--on) * 3px)); pointer-events: none; }
|
|
186
|
+
.fw-root .fw-view-agents .fw-seg { pointer-events: auto; }
|
|
187
|
+
.fw-root .fw-seg-model { background: var(--fill); box-shadow: inset 0 0 0 1px var(--line); }
|
|
188
|
+
.fw-root .fw-seg-tool { background: var(--dim); box-shadow: inset 0 0 0 1px var(--dim-line); }
|
|
189
|
+
.fw-root .fw-seg-failed { background: color-mix(in oklab, var(--fw-failed) 18%, var(--fw-surface)); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-failed) 70%, transparent); color: var(--fw-failed); }
|
|
190
|
+
.fw-root .fw-view-agents .fw-seg-failed { background: var(--dim); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--fw-failed) 60%, var(--dim-line)); }
|
|
191
|
+
.fw-root .fw-glyph { display: inline-flex; color: currentColor; }
|
|
192
|
+
.fw-root .fw-glyph svg { width: 11px; height: 11px; stroke-width: 2; }
|
|
193
|
+
.fw-root .fw-seg-model .fw-glyph, .fw-root .fw-k-model .fw-glyph { color: light-dark(var(--tone), #fff); }
|
|
194
|
+
.fw-root .fw-end { display: inline-flex; align-items: center; gap: 8px; margin-top: -10px; height: 20px; left: calc(var(--x0) + max(var(--w), 3px) + 8px); white-space: nowrap; pointer-events: none; }
|
|
195
|
+
.fw-root .fw-duration { font-size: 11px; color: var(--fw-muted); font-variant-numeric: tabular-nums; }
|
|
196
|
+
.fw-root .fw-k-failed ~ .fw-end .fw-duration { color: var(--fw-failed); }
|
|
197
|
+
.fw-root .fw-badge { height: 18px; padding: 0 6px; border-radius: 999px; font-size: 11px; line-height: 16px; font-weight: 600; color: var(--fw-amber); background: color-mix(in oklab, var(--fw-amber) 13%, transparent); border: 1px solid color-mix(in oklab, var(--fw-amber) 28%, transparent); }
|
|
198
|
+
|
|
199
|
+
/* Handoff elbows: 1.5 px stroke, 6 px radius, a 5 px dot where the handoff leaves its sender. */
|
|
200
|
+
.fw-root .fw-links { position: absolute; top: 0; bottom: 0; left: min(var(--fw-name-w), 42%); right: 0; overflow: hidden; pointer-events: none; z-index: 1; }
|
|
201
|
+
.fw-root .fw-link {
|
|
202
|
+
--x: calc(var(--fw-pad) + (var(--s) - var(--fw-v0)) * var(--fw-k) * 1px);
|
|
203
|
+
position: absolute; width: 8px; border: 0 solid var(--line); border-bottom-width: 1.5px;
|
|
204
|
+
opacity: clamp(0, (var(--fw-t) - var(--s)) * 1000, 1);
|
|
205
|
+
}
|
|
206
|
+
.fw-root .fw-view-spans .fw-link { opacity: calc(clamp(0, (var(--fw-t) - var(--s)) * 1000, 1) * .7); }
|
|
207
|
+
.fw-root .fw-link-down { left: calc(var(--x) - 8px); border-left-width: 1.5px; border-bottom-left-radius: 6px; }
|
|
208
|
+
.fw-root .fw-link-up { left: var(--x); border-right-width: 1.5px; border-bottom-right-radius: 6px; }
|
|
209
|
+
.fw-root .fw-link::before { content: ""; position: absolute; top: -3.5px; width: 5px; height: 5px; border-radius: 50%; background: var(--line); box-shadow: 0 0 0 1.5px var(--fw-surface); }
|
|
210
|
+
.fw-root .fw-link-down::before { left: -3.25px; }
|
|
211
|
+
.fw-root .fw-link-up::before { right: -3.25px; }
|
|
212
|
+
|
|
213
|
+
/* Span card */
|
|
214
|
+
.fw-root .fw-card-anchor { display: contents; }
|
|
215
|
+
.fw-root .fw-card { position: absolute; z-index: 20; width: 320px; padding: 12px; border-radius: 12px; background: var(--fw-raised); border: 1px solid var(--fw-border);
|
|
216
|
+
box-shadow: 0 12px 32px -8px rgb(0 0 0 / .28), 0 2px 6px rgb(0 0 0 / .08); animation: fw-arrive 140ms var(--fw-ease); }
|
|
217
|
+
.fw-root .fw-card-above .fw-card { transform: translateY(-100%); animation-name: fw-arrive-above; }
|
|
218
|
+
.fw-root .fw-card-agent { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; font-size: 11px; font-weight: 600; }
|
|
219
|
+
.fw-root .fw-card-agent .fw-agent-dot { margin-top: 0; align-self: center; }
|
|
220
|
+
.fw-root .fw-card-head { display: flex; align-items: flex-start; gap: 8px; }
|
|
221
|
+
.fw-root .fw-card-head .fw-icon-tile { flex-basis: 28px; width: 28px; height: 28px; border-radius: 8px; }
|
|
222
|
+
.fw-root .fw-card-head .fw-icon-tile :is(svg, img) { width: 16px; height: 16px; }
|
|
223
|
+
.fw-root .fw-card-title { flex: 1; min-width: 0; }
|
|
224
|
+
.fw-root .fw-card-name { font-size: 14px; line-height: 20px; font-weight: 600; overflow-wrap: anywhere; }
|
|
225
|
+
.fw-root .fw-muted { color: var(--fw-muted); }
|
|
226
|
+
.fw-root .fw-pill { flex-shrink: 0; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 11px; line-height: 20px; font-weight: 500; }
|
|
227
|
+
.fw-root .fw-pill-done { color: var(--fw-ok); background: color-mix(in oklab, var(--fw-ok) 13%, transparent); }
|
|
228
|
+
.fw-root .fw-pill-running { color: var(--fw-accent); background: color-mix(in oklab, var(--fw-accent) 13%, transparent); }
|
|
229
|
+
.fw-root .fw-pill-failed { color: var(--fw-failed); background: color-mix(in oklab, var(--fw-failed) 13%, transparent); }
|
|
230
|
+
.fw-root .fw-icon-button { appearance: none; display: inline-grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--fw-muted); cursor: pointer; flex-shrink: 0; }
|
|
231
|
+
.fw-root .fw-icon-button:hover:not(:disabled) { background: var(--fw-hover); color: var(--fw-text); }
|
|
232
|
+
.fw-root .fw-card-head .fw-icon-button { width: 20px; height: 20px; margin: 0 -4px 0 -2px; }
|
|
233
|
+
.fw-root .fw-card-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 8px; margin-top: 12px; padding: 12px; border-radius: 8px; background: var(--fw-well); }
|
|
234
|
+
.fw-root .fw-card-stats dt, .fw-root .fw-card-label { font-size: 11px; line-height: 16px; color: var(--fw-muted); }
|
|
235
|
+
.fw-root .fw-card-stats dd { font-size: 14px; line-height: 20px; font-weight: 600; font-variant-numeric: tabular-nums; }
|
|
236
|
+
.fw-root .fw-unknown { color: var(--fw-muted); font-weight: 400; }
|
|
237
|
+
.fw-root .fw-card-text { margin-top: 12px; }
|
|
238
|
+
.fw-root .fw-card-compact { width: 280px; padding: 10px 12px; }
|
|
239
|
+
.fw-root .fw-card-compact .fw-card-agent { margin-bottom: 4px; }
|
|
240
|
+
.fw-root .fw-card-result { font-size: 14px; line-height: 20px; font-weight: 500; overflow-wrap: anywhere; }
|
|
241
|
+
.fw-root .fw-card-meta { margin-top: 4px; color: var(--fw-muted); font-variant-numeric: tabular-nums; }
|
|
242
|
+
.fw-root .fw-card-message { display: flex; gap: 6px; margin-top: 6px; color: var(--fw-muted); }
|
|
243
|
+
.fw-root .fw-card-message svg { flex-shrink: 0; margin-top: 3px; }
|
|
244
|
+
.fw-root .fw-card-text p { margin-top: 2px; color: var(--fw-text); overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
|
|
245
|
+
|
|
246
|
+
/* Playback */
|
|
247
|
+
.fw-root .fw-playback { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 10px 16px; border-top: 1px solid var(--fw-border); }
|
|
248
|
+
.fw-root .fw-round-button { appearance: none; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border-radius: 50%; border: 1px solid var(--fw-border); background: var(--fw-well); color: var(--fw-text); cursor: pointer; transition: background-color 120ms var(--fw-ease), transform 120ms var(--fw-ease); }
|
|
249
|
+
.fw-root .fw-round-button:hover:not(:disabled) { background: var(--fw-hover); }
|
|
250
|
+
.fw-root .fw-round-button:active:not(:disabled) { transform: scale(.94); }
|
|
251
|
+
.fw-root .fw-speed select { appearance: none; height: 28px; padding: 0 24px 0 10px; border-radius: 8px; border: 1px solid var(--fw-border); background: var(--fw-well) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath d='m2 3.5 3 3 3-3' fill='none' stroke='%23888' stroke-width='1.4' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 8px center; font-size: 13px; font-variant-numeric: tabular-nums; cursor: pointer; }
|
|
252
|
+
.fw-root .fw-overview { position: relative; flex: 1 1 160px; min-width: 120px; height: 28px; }
|
|
253
|
+
.fw-root .fw-overview-marks { position: absolute; left: 0; right: 0; top: 8px; height: 12px; border-radius: 4px; background: var(--fw-well); overflow: hidden; box-shadow: inset 0 0 0 1px var(--fw-border); }
|
|
254
|
+
.fw-root .fw-ov { position: absolute; top: 2px; bottom: 2px; border-radius: 1px; }
|
|
255
|
+
.fw-root .fw-ov.fw-seg-model, .fw-root .fw-ov.fw-seg-tool { background: var(--line); opacity: .75; }
|
|
256
|
+
.fw-root .fw-ov.fw-seg-tool { opacity: .45; }
|
|
257
|
+
.fw-root .fw-ov.fw-seg-failed { background: var(--fw-failed); }
|
|
258
|
+
.fw-root .fw-brush { position: absolute; top: 0; bottom: 0; border-radius: 3px; box-shadow: inset 0 0 0 1.5px var(--fw-accent); background: color-mix(in oklab, var(--fw-accent) 10%, transparent); }
|
|
259
|
+
.fw-root .fw-slider { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; appearance: none; -webkit-appearance: none; background: linear-gradient(90deg, transparent var(--fw-progress), color-mix(in oklab, var(--fw-surface) 55%, transparent) var(--fw-progress)) 0 8px / 100% 12px no-repeat; cursor: pointer; }
|
|
260
|
+
.fw-root .fw-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 4px; height: 22px; border-radius: 2px; background: var(--fw-text); box-shadow: 0 0 0 2px var(--fw-surface); }
|
|
261
|
+
.fw-root .fw-slider::-moz-range-thumb { width: 4px; height: 22px; border: 0; border-radius: 2px; background: var(--fw-text); box-shadow: 0 0 0 2px var(--fw-surface); }
|
|
262
|
+
.fw-root .fw-time { min-width: 48px; font-size: 13px; color: var(--fw-muted); font-variant-numeric: tabular-nums; }
|
|
263
|
+
.fw-root .fw-zoom { display: inline-flex; gap: 0; }
|
|
72
264
|
.fw-root .fw-sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
265
|
+
|
|
266
|
+
@keyframes fw-spin { to { transform: rotate(360deg); } }
|
|
267
|
+
@keyframes fw-pulse { 50% { opacity: .35; } }
|
|
268
|
+
@keyframes fw-arrive { from { opacity: 0; transform: translateY(4px); } }
|
|
269
|
+
@keyframes fw-arrive-above { from { opacity: 0; transform: translateY(calc(-100% - 4px)); } }
|
|
270
|
+
|
|
271
|
+
@media (prefers-reduced-motion: reduce) {
|
|
272
|
+
.fw-root *, .fw-root *::before { animation: none !important; transition: none !important; }
|
|
273
|
+
.fw-root .fw-spinner { border-top-color: color-mix(in oklab, var(--fw-accent) 30%, transparent); border-right-color: var(--fw-accent); }
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
@container (max-width: 820px) {
|
|
277
|
+
.fw-root .fw-zoom, .fw-root .fw-time { display: none; }
|
|
278
|
+
}
|
|
279
|
+
@container (max-width: 560px) {
|
|
280
|
+
.fw-root .fw-row .fw-icon-tile { display: none; }
|
|
281
|
+
.fw-root .fw-label { padding-left: calc(8px + var(--depth) * 12px); gap: 4px; }
|
|
282
|
+
.fw-root .fw-guides { left: 16px; width: calc(var(--depth) * 12px); background-size: 12px 100%; }
|
|
283
|
+
.fw-root .fw-row .fw-detail { display: none; }
|
|
284
|
+
}
|
|
285
|
+
@media (max-width: 640px) {
|
|
286
|
+
.fw-root .fw-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
|
287
|
+
.fw-root .fw-summary > div:nth-child(4) { border-left: 0; }
|
|
288
|
+
.fw-root .fw-summary > div:nth-child(n + 4) { border-top: 1px solid var(--fw-border); }
|
|
289
|
+
.fw-root .fw-search-input { width: 140px; }
|
|
290
|
+
.fw-root .fw-branch-controls, .fw-root .fw-zoom { display: none; }
|
|
291
|
+
.fw-root .fw-heading, .fw-root .fw-playback { padding-left: 12px; padding-right: 12px; }
|
|
76
292
|
}
|
|
293
|
+
|
|
294
|
+
/* The agent timeline is one quiet surface: no inner rules, more air, the axis under the lanes. */
|
|
295
|
+
.fw-root-agents .fw-heading { border-bottom: 0; padding: 20px 24px 12px; }
|
|
296
|
+
.fw-root-agents .fw-axis-bottom { border-top: 0; }
|
|
297
|
+
.fw-root-agents .fw-playback { border-top: 0; padding: 8px 24px 20px; }
|
|
298
|
+
.fw-root-agents .fw-view-agents .fw-label { padding-left: 24px; }
|
|
299
|
+
.fw-root-agents .fw-zoom, .fw-root-agents .fw-time { display: none; }
|
|
300
|
+
/* The agent view keeps scrubbing on a hairline track; the lanes above already show the activity. */
|
|
301
|
+
.fw-root-agents .fw-overview-marks { top: 13px; height: 2px; box-shadow: none; }
|
|
302
|
+
.fw-root-agents .fw-overview-marks > * { display: none; }
|
|
303
|
+
.fw-root .fw-segmented { display: inline-flex; padding: 2px; border-radius: 10px; background: var(--fw-well); border: 1px solid var(--fw-border); }
|
|
304
|
+
.fw-root .fw-segmented button { appearance: none; border: 0; background: transparent; height: 26px; min-width: 36px; padding: 0 10px; border-radius: 8px; font-size: 13px; color: var(--fw-muted); cursor: pointer; font-variant-numeric: tabular-nums; transition: background-color 120ms var(--fw-ease), color 120ms var(--fw-ease); }
|
|
305
|
+
.fw-root .fw-segmented button[aria-checked="true"] { background: var(--fw-surface); color: var(--fw-text); box-shadow: 0 1px 2px rgb(0 0 0 / .14), 0 0 0 1px var(--fw-border); }
|
package/dist/react/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as
|
|
1
|
+
import { C as MarkVerdict, D as YTarget, E as YScale, O as YTick, P as Figure, S as MarkKind, T as XCategory, _ as PointFields, a as TimelineOptions, b as ChartBand, h as TickOutcome, i as TimelineLane, n as FlowSpan, o as TimelineSpan, r as FlowTrace, s as TimelineTick, t as FlowMarker, v as PointGlyph, w as MarkerShape, x as ChartMark, y as BandKind, z as Refusal } from "../flow-trace-Cti_6fZP.js";
|
|
2
2
|
import { CSSProperties, ReactElement, ReactNode } from "react";
|
|
3
3
|
//#region src/react/sparkline.d.ts
|
|
4
4
|
type SparklineDirection = "rising" | "falling" | "flat";
|
|
@@ -347,6 +347,9 @@ interface DotMapProps {
|
|
|
347
347
|
export declare const DOT_MAP_CATEGORIES: readonly string[];
|
|
348
348
|
export declare function DotMap({ positions, radii, colors, palette, extent, rects, labels, dimmed, selected, minPixelRadius, onHover, onSelect, describe, height, ariaLabel }: DotMapProps): import("react").JSX.Element;
|
|
349
349
|
//#endregion
|
|
350
|
+
//#region src/react/flow-waterfall-row.d.ts
|
|
351
|
+
type FlowView = 'spans' | 'agents';
|
|
352
|
+
//#endregion
|
|
350
353
|
//#region src/react/flow-waterfall.d.ts
|
|
351
354
|
interface FlowWaterfallProps {
|
|
352
355
|
trace: FlowTrace;
|
|
@@ -358,8 +361,19 @@ interface FlowWaterfallProps {
|
|
|
358
361
|
label?: string;
|
|
359
362
|
/** Fold all branches on first mount for large traces; search still reveals matches. */
|
|
360
363
|
defaultCollapsed?: boolean;
|
|
364
|
+
/** `agents` shows one row per agent (the agent timeline); expanding a row opens the full span tree. */
|
|
365
|
+
defaultView?: FlowView;
|
|
366
|
+
/** Host brand marks by span; the inspector draws kind glyphs without it. */
|
|
367
|
+
renderIcon?: (span: FlowSpan) => ReactNode;
|
|
368
|
+
/** Scroll height of the rows; the tree is virtualized beyond it. */
|
|
369
|
+
maxHeight?: number;
|
|
370
|
+
/** Called when a row is opened or a bar is pinned, with that row's span; the built-in behavior still runs. */
|
|
371
|
+
onSelect?: (span: FlowSpan) => void;
|
|
372
|
+
/** Labelled instants, such as releases, drawn across the rows on the trace clock. */
|
|
373
|
+
markers?: FlowMarker[];
|
|
361
374
|
}
|
|
362
|
-
/** Shared trace inspector
|
|
363
|
-
|
|
375
|
+
/** Shared trace inspector: the agent timeline and the span waterfall over one clock.
|
|
376
|
+
* Data remains producer-owned; playback, zoom and folding change presentation only. */
|
|
377
|
+
export declare function FlowWaterfall({ trace, live, startedAt, label, defaultCollapsed, defaultView, renderIcon, maxHeight, onSelect, markers }: FlowWaterfallProps): import("react").JSX.Element;
|
|
364
378
|
//#endregion
|
|
365
379
|
export type { BandKind, ChartBand, ChartMark, DotMapLabel, DotMapProps, DotMapRect, Figure, FigureAtWidth, FigureViewProps, FlowWaterfallProps, LineSeries, MarkKind, MarkVerdict, MarkerShape, MeterSegment, PointFields, PointGlyph, Refusal, SparklineDirection, SparklineGeometry, SparklineGeometryOptions, SparklineLabelOptions, SparklinePoint, SparklineProps, SparklineValues, StackedBarBucket, StackedBarChartProps, StackedBarSegment, StackedBarSeries, TickOutcome, TimelineLane, TimelineOptions, TimelineSpan, TimelineTick, TimelineViewProps, WaterfallBarProps, WaterfallHeaderProps, WaterfallRowProps, WaterfallSpanGeometry, WaterfallTimeAxisProps, WaterfallWindow, XCategory, YScale, YTarget, YTick };
|