@pipelex/mthds-ui 0.34.1 → 0.36.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 +26 -4
- package/dist/{chunk-TMZ2JR2J.js → chunk-4KLE62AN.js} +13 -1
- package/dist/chunk-4KLE62AN.js.map +1 -0
- package/dist/{chunk-ABUDTHWF.js → chunk-AGFLCOWW.js} +47 -5
- package/dist/chunk-AGFLCOWW.js.map +1 -0
- package/dist/{chunk-K2C5FU4W.js → chunk-ENRYQOCO.js} +2 -2
- package/dist/chunk-ILZJIORT.js +54 -0
- package/dist/chunk-ILZJIORT.js.map +1 -0
- package/dist/chunk-JJG2TO7P.js +473 -0
- package/dist/chunk-JJG2TO7P.js.map +1 -0
- package/dist/form/react/index.d.ts +2 -1
- package/dist/form/react/index.js +2 -2
- package/dist/graph/index.d.ts +3 -2
- package/dist/graph/index.js +7 -3
- package/dist/graph/react/detail/DetailPanel.css +37 -11
- package/dist/graph/react/graph-core.css +39 -0
- package/dist/graph/react/index.d.ts +5 -2
- package/dist/graph/react/index.js +596 -589
- package/dist/graph/react/index.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +7 -3
- package/dist/progressSnapshot-VZ4PLul9.d.ts +191 -0
- package/dist/standalone/graph-standalone.html +191 -126
- package/dist/standalone/graph-viewer.css +77 -12
- package/dist/standalone/graph-viewer.js +114 -114
- package/dist/static-graph/index.d.ts +2 -1
- package/dist/static-graph/index.js +1 -1
- package/dist/timeline/index.d.ts +339 -0
- package/dist/timeline/index.js +70 -0
- package/dist/timeline/index.js.map +1 -0
- package/dist/timeline/react/RunTimeline.css +503 -0
- package/dist/timeline/react/index.d.ts +69 -0
- package/dist/timeline/react/index.js +402 -0
- package/dist/timeline/react/index.js.map +1 -0
- package/dist/{types-MvxsDLCo.d.ts → types-DsrzH6gM.d.ts} +43 -7
- package/package.json +12 -2
- package/dist/chunk-ABUDTHWF.js.map +0 -1
- package/dist/chunk-TMZ2JR2J.js.map +0 -1
- /package/dist/{chunk-K2C5FU4W.js.map → chunk-ENRYQOCO.js.map} +0 -0
|
@@ -0,0 +1,503 @@
|
|
|
1
|
+
/* ─── Run timeline ─────────────────────────────────────────────────────────── */
|
|
2
|
+
/* Token-only: every colour comes from this library's palette, which */
|
|
3
|
+
/* RunTimeline applies inline to its own container as CSS variables (see */
|
|
4
|
+
/* `graphConfig.ts`), so it themes correctly standing alone, with no graph */
|
|
5
|
+
/* viewer in the tree. Being inline, the palette beats a stylesheet rule on */
|
|
6
|
+
/* the container: a host changes a colour through the `paletteColors` prop. */
|
|
7
|
+
/* Its layout hooks are the `--mthds-run-timeline-*` variables set on the */
|
|
8
|
+
/* root below, which a host may override on the container's class. */
|
|
9
|
+
/* `--mthds-run-timeline-axis-span` is no hook: the component sets it on its */
|
|
10
|
+
/* body as the axis grows. */
|
|
11
|
+
|
|
12
|
+
.mthds-run-timeline {
|
|
13
|
+
--mthds-run-timeline-name-width: minmax(8rem, 36%);
|
|
14
|
+
--mthds-run-timeline-meta-width: 10.5rem;
|
|
15
|
+
--mthds-run-timeline-indent: 14px;
|
|
16
|
+
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
gap: 10px;
|
|
20
|
+
/* The `container` declaration at the end of this rule makes the root's width
|
|
21
|
+
ignore its content, so it takes its width from its container rather than
|
|
22
|
+
from what it holds: without this, a row flex parent would shrink it to its
|
|
23
|
+
padding (docs/run-timeline.md, "Styling", says how a host sizes it). */
|
|
24
|
+
width: 100%;
|
|
25
|
+
min-width: 0;
|
|
26
|
+
padding: 14px 16px 16px;
|
|
27
|
+
background: var(--surface-panel);
|
|
28
|
+
border: 1px solid var(--border-default);
|
|
29
|
+
border-radius: 10px;
|
|
30
|
+
font-family: var(--font-sans);
|
|
31
|
+
font-size: 12px;
|
|
32
|
+
line-height: 1.4;
|
|
33
|
+
color: var(--text-default);
|
|
34
|
+
box-sizing: border-box;
|
|
35
|
+
container: mthds-run-timeline / inline-size;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.mthds-run-timeline *,
|
|
39
|
+
.mthds-run-timeline *::before,
|
|
40
|
+
.mthds-run-timeline *::after {
|
|
41
|
+
box-sizing: border-box;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* ─── Header: the run's status and its one-line summary ─────────────────── */
|
|
45
|
+
|
|
46
|
+
.mthds-run-timeline-header {
|
|
47
|
+
display: flex;
|
|
48
|
+
flex-wrap: wrap;
|
|
49
|
+
align-items: center;
|
|
50
|
+
gap: 6px 10px;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.mthds-run-timeline-status,
|
|
54
|
+
.mthds-run-timeline-mode {
|
|
55
|
+
padding: 2px 8px;
|
|
56
|
+
border-radius: 999px;
|
|
57
|
+
font-size: 11px;
|
|
58
|
+
font-weight: 600;
|
|
59
|
+
line-height: 16px;
|
|
60
|
+
white-space: nowrap;
|
|
61
|
+
border: 1px solid var(--border-default);
|
|
62
|
+
color: var(--text-secondary);
|
|
63
|
+
background: var(--surface-pill);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.mthds-run-timeline-status--running {
|
|
67
|
+
color: var(--color-accent);
|
|
68
|
+
border-color: currentColor;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.mthds-run-timeline-status--succeeded {
|
|
72
|
+
color: var(--color-success);
|
|
73
|
+
border-color: currentColor;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.mthds-run-timeline-status--failed {
|
|
77
|
+
color: var(--color-error);
|
|
78
|
+
border-color: currentColor;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.mthds-run-timeline-summary {
|
|
82
|
+
flex: 1 1 16rem;
|
|
83
|
+
min-width: 0;
|
|
84
|
+
margin: 0;
|
|
85
|
+
color: var(--text-primary);
|
|
86
|
+
font-size: 13px;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.mthds-run-timeline-degradation {
|
|
90
|
+
margin: 0;
|
|
91
|
+
padding: 8px 10px;
|
|
92
|
+
border: 1px solid var(--color-warning);
|
|
93
|
+
border-radius: 6px;
|
|
94
|
+
background: var(--surface-sunken);
|
|
95
|
+
color: var(--text-default);
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.mthds-run-timeline-empty {
|
|
99
|
+
margin: 0;
|
|
100
|
+
color: var(--text-muted);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/* ─── Rows: name | track | detail, on one grid per row, aligned by width ─── */
|
|
104
|
+
|
|
105
|
+
.mthds-run-timeline-body {
|
|
106
|
+
display: flex;
|
|
107
|
+
flex-direction: column;
|
|
108
|
+
min-width: 0;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.mthds-run-timeline-rows {
|
|
112
|
+
margin: 0;
|
|
113
|
+
padding: 0;
|
|
114
|
+
list-style: none;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.mthds-run-timeline-axis,
|
|
118
|
+
.mthds-run-timeline-row {
|
|
119
|
+
display: grid;
|
|
120
|
+
grid-template-columns:
|
|
121
|
+
var(--mthds-run-timeline-name-width) minmax(0, 1fr)
|
|
122
|
+
var(--mthds-run-timeline-meta-width);
|
|
123
|
+
column-gap: 10px;
|
|
124
|
+
align-items: center;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.mthds-run-timeline-axis {
|
|
128
|
+
height: 20px;
|
|
129
|
+
border-bottom: 1px solid var(--border-subtle);
|
|
130
|
+
color: var(--text-dim);
|
|
131
|
+
font-size: 10.5px;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.mthds-run-timeline-axis-track {
|
|
135
|
+
position: relative;
|
|
136
|
+
height: 100%;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.mthds-run-timeline-tick {
|
|
140
|
+
position: absolute;
|
|
141
|
+
top: 2px;
|
|
142
|
+
transform: translateX(-50%);
|
|
143
|
+
white-space: nowrap;
|
|
144
|
+
font-variant-numeric: tabular-nums;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.mthds-run-timeline-tick--first {
|
|
148
|
+
transform: none;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.mthds-run-timeline-tick--last {
|
|
152
|
+
transform: translateX(-100%);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.mthds-run-timeline-row {
|
|
156
|
+
min-height: 26px;
|
|
157
|
+
border-bottom: 1px solid var(--border-subtle);
|
|
158
|
+
animation: mthds-run-timeline-appear 0.3s ease-out;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.mthds-run-timeline-row:hover {
|
|
162
|
+
background: var(--surface-sunken);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/* Each row's status colour, which its dot and bar take. */
|
|
166
|
+
.mthds-run-timeline-row,
|
|
167
|
+
.mthds-run-timeline-strip-cell {
|
|
168
|
+
--mthds-run-timeline-status-color: var(--text-dim);
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.mthds-run-timeline-row--running,
|
|
172
|
+
.mthds-run-timeline-strip-cell--running {
|
|
173
|
+
--mthds-run-timeline-status-color: var(--color-accent);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.mthds-run-timeline-row--succeeded,
|
|
177
|
+
.mthds-run-timeline-strip-cell--succeeded {
|
|
178
|
+
--mthds-run-timeline-status-color: var(--color-success);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.mthds-run-timeline-row--failed,
|
|
182
|
+
.mthds-run-timeline-strip-cell--failed {
|
|
183
|
+
--mthds-run-timeline-status-color: var(--color-error);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.mthds-run-timeline-strip-cell--scheduled {
|
|
187
|
+
--mthds-run-timeline-status-color: var(--border-strong);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
/* A running invocation whose work is being tried again. */
|
|
191
|
+
.mthds-run-timeline-row--retrying {
|
|
192
|
+
--mthds-run-timeline-status-color: var(--color-warning);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.mthds-run-timeline-name {
|
|
196
|
+
display: flex;
|
|
197
|
+
align-items: center;
|
|
198
|
+
gap: 6px;
|
|
199
|
+
min-width: 0;
|
|
200
|
+
overflow: hidden;
|
|
201
|
+
white-space: nowrap;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
.mthds-run-timeline-toggle,
|
|
205
|
+
.mthds-run-timeline-toggle-spacer {
|
|
206
|
+
flex: 0 0 16px;
|
|
207
|
+
width: 16px;
|
|
208
|
+
height: 16px;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
.mthds-run-timeline-toggle {
|
|
212
|
+
display: inline-flex;
|
|
213
|
+
align-items: center;
|
|
214
|
+
justify-content: center;
|
|
215
|
+
padding: 0;
|
|
216
|
+
border: none;
|
|
217
|
+
border-radius: 4px;
|
|
218
|
+
background: transparent;
|
|
219
|
+
color: var(--text-secondary);
|
|
220
|
+
font-size: 12px;
|
|
221
|
+
line-height: 1;
|
|
222
|
+
cursor: pointer;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
.mthds-run-timeline-toggle:hover {
|
|
226
|
+
color: var(--text-primary);
|
|
227
|
+
background: var(--surface-elevated-hover);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.mthds-run-timeline-toggle:focus-visible {
|
|
231
|
+
outline: 2px solid var(--focus-ring);
|
|
232
|
+
outline-offset: 1px;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.mthds-run-timeline-dot {
|
|
236
|
+
flex: 0 0 8px;
|
|
237
|
+
width: 8px;
|
|
238
|
+
height: 8px;
|
|
239
|
+
border-radius: 50%;
|
|
240
|
+
background: var(--mthds-run-timeline-status-color);
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.mthds-run-timeline-row--scheduled .mthds-run-timeline-dot,
|
|
244
|
+
.mthds-run-timeline-row--canceled .mthds-run-timeline-dot {
|
|
245
|
+
background: transparent;
|
|
246
|
+
border: 1px solid var(--mthds-run-timeline-status-color);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
.mthds-run-timeline-code {
|
|
250
|
+
flex: 0 1 auto;
|
|
251
|
+
min-width: 0;
|
|
252
|
+
overflow: hidden;
|
|
253
|
+
text-overflow: ellipsis;
|
|
254
|
+
font-family: var(--font-mono);
|
|
255
|
+
color: var(--text-primary);
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
.mthds-run-timeline-row--scheduled .mthds-run-timeline-code,
|
|
259
|
+
.mthds-run-timeline-row--canceled .mthds-run-timeline-code,
|
|
260
|
+
.mthds-run-timeline-row--skipped .mthds-run-timeline-code {
|
|
261
|
+
color: var(--text-muted);
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
.mthds-run-timeline-place {
|
|
265
|
+
flex: 0 2 auto;
|
|
266
|
+
min-width: 0;
|
|
267
|
+
overflow: hidden;
|
|
268
|
+
text-overflow: ellipsis;
|
|
269
|
+
color: var(--text-dim);
|
|
270
|
+
font-size: 11px;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
/* ─── The track and its bars ─────────────────────────────────────────────── */
|
|
274
|
+
/* A bar's `left` and `width` are offsets in milliseconds over */
|
|
275
|
+
/* `--mthds-run-timeline-axis-span`, so a bar that has stopped growing keeps */
|
|
276
|
+
/* its place on the growing axis with no redraw of its row. */
|
|
277
|
+
|
|
278
|
+
.mthds-run-timeline-track {
|
|
279
|
+
position: relative;
|
|
280
|
+
align-self: stretch;
|
|
281
|
+
min-height: 26px;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.mthds-run-timeline-bar {
|
|
285
|
+
position: absolute;
|
|
286
|
+
top: 50%;
|
|
287
|
+
height: 10px;
|
|
288
|
+
min-width: 3px;
|
|
289
|
+
transform: translateY(-50%);
|
|
290
|
+
border-radius: 3px;
|
|
291
|
+
background: var(--mthds-run-timeline-status-color);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/* While the timeline keeps its own clock, it repaints four times a second; the
|
|
295
|
+
bars glide between repaints instead of stepping, and the axis's ticks glide
|
|
296
|
+
with them over the same time, so a tick's label and a bar's end at the same
|
|
297
|
+
moment stay together throughout. A host-driven `now` moves them itself, so
|
|
298
|
+
they follow it with no lag. */
|
|
299
|
+
.mthds-run-timeline--self-clocked .mthds-run-timeline-bar {
|
|
300
|
+
transition:
|
|
301
|
+
left 0.25s linear,
|
|
302
|
+
width 0.25s linear;
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
.mthds-run-timeline--self-clocked .mthds-run-timeline-tick {
|
|
306
|
+
transition: left 0.25s linear;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
.mthds-run-timeline-bar--growing {
|
|
310
|
+
background-image: repeating-linear-gradient(
|
|
311
|
+
-45deg,
|
|
312
|
+
transparent 0 6px,
|
|
313
|
+
var(--surface-elevated-hover) 6px 12px
|
|
314
|
+
);
|
|
315
|
+
background-size: 17px 17px;
|
|
316
|
+
animation: mthds-run-timeline-stripes 1s linear infinite;
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
/* A batch's bar is a tinted frame, so the strip of its items' states inside it reads. */
|
|
320
|
+
.mthds-run-timeline-bar--batch {
|
|
321
|
+
height: 16px;
|
|
322
|
+
border: 1px solid var(--mthds-run-timeline-status-color);
|
|
323
|
+
background-color: var(--surface-sunken);
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
/* A skipped invocation ended without output of its own; a canceled one never
|
|
327
|
+
ended. After the batch's frame, so a canceled batch's frame is dashed too. */
|
|
328
|
+
.mthds-run-timeline-row--skipped .mthds-run-timeline-bar,
|
|
329
|
+
.mthds-run-timeline-bar--open-ended {
|
|
330
|
+
background-color: transparent;
|
|
331
|
+
border: 1px dashed var(--mthds-run-timeline-status-color);
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
.mthds-run-timeline-strip {
|
|
335
|
+
position: absolute;
|
|
336
|
+
left: 2px;
|
|
337
|
+
right: 2px;
|
|
338
|
+
bottom: 2px;
|
|
339
|
+
height: 5px;
|
|
340
|
+
display: flex;
|
|
341
|
+
overflow: hidden;
|
|
342
|
+
border-radius: 2px;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
.mthds-run-timeline-strip-cell {
|
|
346
|
+
flex-basis: 0;
|
|
347
|
+
min-width: 0;
|
|
348
|
+
background: var(--mthds-run-timeline-status-color);
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
/* A failed item stays visible in the strip however many items share the bar. */
|
|
352
|
+
.mthds-run-timeline-strip-cell--failed {
|
|
353
|
+
min-width: 2px;
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
.mthds-run-timeline-strip-cell--canceled,
|
|
357
|
+
.mthds-run-timeline-strip-cell--skipped {
|
|
358
|
+
opacity: 0.6;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
/* Where the last failure of a retried invocation happened. */
|
|
362
|
+
.mthds-run-timeline-failure-tick {
|
|
363
|
+
position: absolute;
|
|
364
|
+
top: -3px;
|
|
365
|
+
bottom: -3px;
|
|
366
|
+
width: 2px;
|
|
367
|
+
margin-left: -1px;
|
|
368
|
+
border-radius: 1px;
|
|
369
|
+
background: var(--color-error);
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
/* The invocation the run is stuck at. */
|
|
373
|
+
.mthds-run-timeline-row--degraded .mthds-run-timeline-bar {
|
|
374
|
+
outline: 1px dashed var(--color-warning);
|
|
375
|
+
outline-offset: 2px;
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
/* ─── Detail column: durations, counts, health ───────────────────────────── */
|
|
379
|
+
|
|
380
|
+
.mthds-run-timeline-meta {
|
|
381
|
+
display: flex;
|
|
382
|
+
align-items: center;
|
|
383
|
+
justify-content: flex-end;
|
|
384
|
+
gap: 6px;
|
|
385
|
+
min-width: 0;
|
|
386
|
+
overflow: hidden;
|
|
387
|
+
white-space: nowrap;
|
|
388
|
+
color: var(--text-muted);
|
|
389
|
+
font-variant-numeric: tabular-nums;
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
.mthds-run-timeline-detail {
|
|
393
|
+
min-width: 0;
|
|
394
|
+
overflow: hidden;
|
|
395
|
+
text-overflow: ellipsis;
|
|
396
|
+
}
|
|
397
|
+
|
|
398
|
+
.mthds-run-timeline-row--failed .mthds-run-timeline-detail {
|
|
399
|
+
color: var(--color-error);
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
.mthds-run-timeline-badge {
|
|
403
|
+
flex: 0 0 auto;
|
|
404
|
+
padding: 0 6px;
|
|
405
|
+
border: 1px solid var(--color-warning);
|
|
406
|
+
border-radius: 999px;
|
|
407
|
+
font-size: 10.5px;
|
|
408
|
+
font-weight: 600;
|
|
409
|
+
line-height: 15px;
|
|
410
|
+
color: var(--color-warning);
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
/* A recovered invocation keeps its attempts in view, quieter than a live retry;
|
|
414
|
+
one that failed after them says so in the failure's colour. */
|
|
415
|
+
.mthds-run-timeline-row--recovered .mthds-run-timeline-badge--retry {
|
|
416
|
+
border-color: var(--border-strong);
|
|
417
|
+
color: var(--text-secondary);
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
.mthds-run-timeline-row--failed .mthds-run-timeline-badge--retry {
|
|
421
|
+
border-color: var(--color-error);
|
|
422
|
+
color: var(--color-error);
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
.mthds-run-timeline-sr {
|
|
426
|
+
position: absolute;
|
|
427
|
+
width: 1px;
|
|
428
|
+
height: 1px;
|
|
429
|
+
margin: -1px;
|
|
430
|
+
padding: 0;
|
|
431
|
+
overflow: hidden;
|
|
432
|
+
clip: rect(0 0 0 0);
|
|
433
|
+
white-space: nowrap;
|
|
434
|
+
border: 0;
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
/* ─── Narrow: each row on two lines, its bar across the whole width ───────── */
|
|
438
|
+
|
|
439
|
+
@container mthds-run-timeline (max-width: 560px) {
|
|
440
|
+
.mthds-run-timeline-row {
|
|
441
|
+
grid-template-columns: minmax(0, 1fr) auto;
|
|
442
|
+
grid-template-areas:
|
|
443
|
+
"name meta"
|
|
444
|
+
"track track";
|
|
445
|
+
padding: 4px 0;
|
|
446
|
+
}
|
|
447
|
+
|
|
448
|
+
.mthds-run-timeline-axis {
|
|
449
|
+
grid-template-columns: minmax(0, 1fr);
|
|
450
|
+
grid-template-areas: "track";
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
.mthds-run-timeline-axis-spacer {
|
|
454
|
+
display: none;
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
.mthds-run-timeline-name {
|
|
458
|
+
grid-area: name;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
.mthds-run-timeline-meta {
|
|
462
|
+
grid-area: meta;
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
.mthds-run-timeline-track,
|
|
466
|
+
.mthds-run-timeline-axis-track {
|
|
467
|
+
grid-area: track;
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
.mthds-run-timeline-track {
|
|
471
|
+
min-height: 18px;
|
|
472
|
+
}
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
@keyframes mthds-run-timeline-appear {
|
|
476
|
+
from {
|
|
477
|
+
opacity: 0;
|
|
478
|
+
}
|
|
479
|
+
to {
|
|
480
|
+
opacity: 1;
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
|
|
484
|
+
@keyframes mthds-run-timeline-stripes {
|
|
485
|
+
from {
|
|
486
|
+
background-position: 0 0;
|
|
487
|
+
}
|
|
488
|
+
to {
|
|
489
|
+
background-position: 17px 0;
|
|
490
|
+
}
|
|
491
|
+
}
|
|
492
|
+
|
|
493
|
+
@media (prefers-reduced-motion: reduce) {
|
|
494
|
+
.mthds-run-timeline-row,
|
|
495
|
+
.mthds-run-timeline-bar--growing {
|
|
496
|
+
animation: none;
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
.mthds-run-timeline--self-clocked .mthds-run-timeline-bar,
|
|
500
|
+
.mthds-run-timeline--self-clocked .mthds-run-timeline-tick {
|
|
501
|
+
transition: none;
|
|
502
|
+
}
|
|
503
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { G as GraphThemeMode, a as GraphTheme } from '../../types-DsrzH6gM.js';
|
|
3
|
+
import { P as ProgressSnapshot, a as ProgressTimestamp } from '../../progressSnapshot-VZ4PLul9.js';
|
|
4
|
+
import 'mthds/errors';
|
|
5
|
+
|
|
6
|
+
interface RunTimelineProps {
|
|
7
|
+
/**
|
|
8
|
+
* The run's progress snapshot, as the hosted progress contract defines it:
|
|
9
|
+
* the component's only source of what ran. Hand it every snapshot you read;
|
|
10
|
+
* the timeline keeps the fresher of the one it holds and the one it is given,
|
|
11
|
+
* so an older read arriving late never rolls it back, and a snapshot showing
|
|
12
|
+
* the run still going never replaces one showing it ended.
|
|
13
|
+
*/
|
|
14
|
+
snapshot: ProgressSnapshot;
|
|
15
|
+
/**
|
|
16
|
+
* `dark`, `light`, or `system` to follow the environment, as `GraphViewer`'s
|
|
17
|
+
* theme mode. Defaults to `system`.
|
|
18
|
+
*/
|
|
19
|
+
theme?: GraphThemeMode;
|
|
20
|
+
/** The environment's theme when the host detects it itself, as on `GraphViewer`. */
|
|
21
|
+
systemTheme?: GraphTheme;
|
|
22
|
+
/**
|
|
23
|
+
* Sparse overrides of the palette, merged per key over the resolved theme's,
|
|
24
|
+
* as `GraphViewer`'s `config.paletteColors`: `{ "--color-success": "#16a34a" }`.
|
|
25
|
+
* The palette is set inline on the timeline's container, so this is how a host
|
|
26
|
+
* changes a colour: a `--color-*` or `--surface-*` declared on the container's
|
|
27
|
+
* class in a stylesheet loses to the inline value.
|
|
28
|
+
*/
|
|
29
|
+
paletteColors?: Record<string, string>;
|
|
30
|
+
/**
|
|
31
|
+
* Pins the reading clock: the moment running bars grow to, as a timestamp or
|
|
32
|
+
* epoch milliseconds. A host that keeps its own trusted clock, or a replay,
|
|
33
|
+
* sets it; the timeline then never ticks on its own.
|
|
34
|
+
*/
|
|
35
|
+
now?: ProgressTimestamp | number;
|
|
36
|
+
/**
|
|
37
|
+
* While the run goes on and `now` is unset, keep running bars growing between
|
|
38
|
+
* snapshots: the timeline advances its reading clock from the snapshot's
|
|
39
|
+
* `assembled_at` by the time elapsed on this page since the snapshot arrived,
|
|
40
|
+
* so it never trusts the page's clock to agree with the server's. `false`
|
|
41
|
+
* draws each snapshot as of its `assembled_at`. Defaults to `true`.
|
|
42
|
+
*/
|
|
43
|
+
live?: boolean;
|
|
44
|
+
/** A batch holding more items than this starts collapsed. Defaults to `DEFAULT_WIDE_BATCH_THRESHOLD`. */
|
|
45
|
+
wideBatchThreshold?: number;
|
|
46
|
+
/** Appended to the container's class list. */
|
|
47
|
+
className?: string;
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* A run's progress as a timeline, drawn from its progress snapshot alone: one
|
|
51
|
+
* row per invocation, nested under its controller by its path and labelled with
|
|
52
|
+
* its pipe code, and a bar on a shared time axis from the invocation's start to
|
|
53
|
+
* its end, which grows while it runs.
|
|
54
|
+
*
|
|
55
|
+
* Nothing is drawn in advance: a row appears when the run reaches its
|
|
56
|
+
* invocation, so there is no method graph behind it and no batch width is ever
|
|
57
|
+
* guessed. A batch is one collapsible row carrying its counts and a strip of its
|
|
58
|
+
* items' states; a wide one starts collapsed and keeps its failed items in view.
|
|
59
|
+
* A condition's branch carries the outcome it took. A retried invocation shows
|
|
60
|
+
* its attempts and where its last failure happened, and the invocation where
|
|
61
|
+
* the run is stuck says so.
|
|
62
|
+
*
|
|
63
|
+
* Rows are keyed by path, so repainting with a newer snapshot keeps each drawn
|
|
64
|
+
* row in place and what the reader expanded expanded. While the clock ticks,
|
|
65
|
+
* only the axis and the rows whose bars follow the clock are drawn again.
|
|
66
|
+
*/
|
|
67
|
+
declare function RunTimeline({ snapshot, theme, systemTheme, paletteColors, now, live, wideBatchThreshold, className, }: RunTimelineProps): react_jsx_runtime.JSX.Element;
|
|
68
|
+
|
|
69
|
+
export { RunTimeline, type RunTimelineProps };
|