@zeyos/zx 5.4.0 → 5.6.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/CHANGELOG.md +136 -0
- package/README.md +23 -16
- package/dist/types/components/agent-thread/agent-thread.d.ts +583 -0
- package/dist/types/components/app-sidebar/app-sidebar.d.ts +33 -0
- package/dist/types/components/approval-card/approval-card.d.ts +596 -0
- package/dist/types/components/avatar/avatar.d.ts +91 -4
- package/dist/types/components/badge/badge.d.ts +5 -4
- package/dist/types/components/block-view/block-view.d.ts +205 -0
- package/dist/types/components/composer/composer.d.ts +736 -0
- package/dist/types/components/datebox/date-range-box.d.ts +15 -2
- package/dist/types/components/datebox/datebox.d.ts +37 -3
- package/dist/types/components/kbd/kbd.d.ts +41 -0
- package/dist/types/components/launcher/launcher.d.ts +4 -2
- package/dist/types/components/prose/prose.d.ts +69 -0
- package/dist/types/components/questionnaire/questionnaire.d.ts +0 -36
- package/dist/types/components/run-status/run-status.d.ts +393 -0
- package/dist/types/components/run-trace/run-trace.d.ts +624 -0
- package/dist/types/components/source-list/source-list.d.ts +177 -0
- package/dist/types/components/stat-tile/stat-tile.d.ts +20 -0
- package/dist/types/components/tag-picker/tag-picker.d.ts +11 -5
- package/dist/types/components/tree/tree.d.ts +44 -3
- package/dist/types/core/icons.d.ts +22 -1
- package/dist/types/core/messages.d.ts +135 -0
- package/dist/types/index.d.ts +12 -2
- package/dist/types/internal/agent-model.d.ts +587 -0
- package/dist/types/internal/app-rail.d.ts +10 -3
- package/dist/types/internal/highlight.d.ts +24 -0
- package/dist/types/internal/presence-loop.d.ts +148 -0
- package/dist/types/internal/row-actions.d.ts +151 -0
- package/dist/zx-zeyos.esm.js +4852 -4535
- package/dist/zx-zeyos.esm.min.js +4 -4
- package/dist/zx.css +3152 -434
- package/dist/zx.esm.js +13730 -6595
- package/dist/zx.esm.min.js +27 -8
- package/dist/zx.global.js +13730 -6595
- package/dist/zx.global.min.js +27 -8
- package/dist/zx.min.css +1 -1
- package/docs/api.json +1474 -205
- package/docs/llms.md +698 -39
- package/docs/llms.txt +12 -1
- package/package.json +1 -1
- package/src/components/account-menu/account-menu.js +2 -2
- package/src/components/agent-thread/agent-thread.css +417 -0
- package/src/components/agent-thread/agent-thread.js +1365 -0
- package/src/components/app-rail/app-rail.css +11 -11
- package/src/components/app-sidebar/app-sidebar.css +90 -17
- package/src/components/app-sidebar/app-sidebar.js +120 -12
- package/src/components/approval-card/approval-card.css +289 -0
- package/src/components/approval-card/approval-card.js +1377 -0
- package/src/components/avatar/avatar.css +56 -1
- package/src/components/avatar/avatar.js +148 -26
- package/src/components/badge/badge.css +33 -20
- package/src/components/badge/badge.js +5 -4
- package/src/components/block-view/block-view.css +300 -0
- package/src/components/block-view/block-view.js +523 -0
- package/src/components/breadcrumb/breadcrumb.css +28 -3
- package/src/components/breadcrumb/breadcrumb.js +2 -2
- package/src/components/button/button.css +24 -13
- package/src/components/button/button.js +20 -2
- package/src/components/calendar/calendar.css +14 -4
- package/src/components/card-view/card-view.js +2 -2
- package/src/components/chart/chart.js +20 -5
- package/src/components/check-button/check-button.css +11 -3
- package/src/components/check-button/check-button.js +3 -3
- package/src/components/composer/composer.css +403 -0
- package/src/components/composer/composer.js +1441 -0
- package/src/components/context-menu/context-menu.css +7 -1
- package/src/components/date-picker/date-picker.css +6 -0
- package/src/components/date-picker/date-picker.js +5 -5
- package/src/components/date-picker/date-range-picker.css +6 -0
- package/src/components/date-picker/date-range-picker.js +3 -3
- package/src/components/date-picker/month-picker.js +3 -3
- package/src/components/date-picker/time-picker.css +6 -0
- package/src/components/datebox/date-range-box.js +30 -6
- package/src/components/datebox/datebox.js +44 -7
- package/src/components/dialog/dialog.css +0 -1
- package/src/components/dialog/dialog.js +2 -1
- package/src/components/dock/dock.js +2 -2
- package/src/components/dropdown/dropdown.css +2 -1
- package/src/components/entity-ref/entity-ref.css +8 -1
- package/src/components/file-item/file-item.css +1 -1
- package/src/components/finder/finder.js +2 -2
- package/src/components/groupbox/groupbox.js +2 -2
- package/src/components/kanban-view/kanban-view.css +8 -4
- package/src/components/kanban-view/kanban-view.js +3 -3
- package/src/components/kbd/kbd.css +64 -0
- package/src/components/kbd/kbd.js +121 -0
- package/src/components/launcher/launcher.css +30 -25
- package/src/components/launcher/launcher.js +15 -21
- package/src/components/list-toolbar/list-toolbar.css +7 -1
- package/src/components/menu-button/menu-button.css +9 -2
- package/src/components/message/message.js +2 -2
- package/src/components/module-bar/module-bar.css +11 -1
- package/src/components/multi-value-editor/multi-value-editor.js +4 -4
- package/src/components/navigation-bar/navigation-bar.css +3 -2
- package/src/components/pagination/pagination.js +2 -2
- package/src/components/panel/panel.js +2 -2
- package/src/components/prose/prose.css +53 -0
- package/src/components/prose/prose.js +152 -0
- package/src/components/questionnaire/questionnaire.css +7 -17
- package/src/components/questionnaire/questionnaire.js +16 -1
- package/src/components/rating/rating.css +3 -1
- package/src/components/run-status/run-status.css +208 -0
- package/src/components/run-status/run-status.js +782 -0
- package/src/components/run-trace/run-trace.css +443 -0
- package/src/components/run-trace/run-trace.js +1209 -0
- package/src/components/search/search.js +2 -2
- package/src/components/select/glyphs.js +3 -3
- package/src/components/select/select.css +35 -7
- package/src/components/select/select.js +4 -4
- package/src/components/source-list/source-list.css +208 -0
- package/src/components/source-list/source-list.js +355 -0
- package/src/components/stat-tile/stat-tile.css +56 -2
- package/src/components/stat-tile/stat-tile.js +25 -2
- package/src/components/stepper/stepper.css +2 -1
- package/src/components/stepper/stepper.js +3 -3
- package/src/components/tabbox/tabbox.css +2 -2
- package/src/components/tabbox/tabbox.js +2 -2
- package/src/components/table/table.css +52 -16
- package/src/components/table/table.js +7 -5
- package/src/components/tag-picker/tag-picker.css +56 -43
- package/src/components/tag-picker/tag-picker.js +21 -16
- package/src/components/tree/tree.css +44 -0
- package/src/components/tree/tree.js +97 -9
- package/src/components/value-list/value-list.css +25 -4
- package/src/components/value-list/value-list.js +2 -1
- package/src/components/view/record-view.js +3 -3
- package/src/components/view-settings/view-settings.css +2 -1
- package/src/components/workspace-switcher/workspace-switcher.js +3 -3
- package/src/core/icons.js +34 -3
- package/src/core/messages.js +143 -0
- package/src/elements/define.js +1 -0
- package/src/index.js +12 -2
- package/src/internal/agent-model.js +488 -0
- package/src/internal/app-rail.js +5 -1
- package/src/internal/highlight.js +104 -0
- package/src/internal/presence-loop.js +343 -0
- package/src/internal/row-actions.js +203 -0
- package/styles/base.css +26 -1
- package/styles/prose.css +306 -0
- package/styles/tokens/dark.css +97 -120
- package/styles/tokens/global.css +24 -9
- package/styles/tokens/semantic.css +464 -184
- package/styles/tokens/themes.css +9 -0
- package/styles/zx.css +10 -0
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { h } from '../../core/dom.js';
|
|
2
|
+
import { copyToClipboard } from '../../core/export.js';
|
|
3
|
+
import { icon } from '../../core/icons.js';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* @typedef {Object} ProseAnchorsOptions
|
|
7
|
+
* @property {string} [selector='h2[id], h3[id], h4[id]'] The headings that get a link, inside a
|
|
8
|
+
* `.zx-prose` under the root. A heading without an `id` has nothing to link to and is skipped.
|
|
9
|
+
* @property {string} [label='Copy link to %1'] The link's accessible name; `%1` is the heading.
|
|
10
|
+
* @property {string} [title='Copy link'] The link's tooltip.
|
|
11
|
+
* @property {string} [feedback='Link copied'] What the live region says after a copy.
|
|
12
|
+
* @property {number} [feedbackDuration=2000] Milliseconds the tick and the message stay.
|
|
13
|
+
* @property {(id: string) => string} [href] The address copied for a heading id. Defaults to the
|
|
14
|
+
* current address with its hash replaced (`sectionHref(location.href, id)`).
|
|
15
|
+
* @property {(url: string, copied: boolean) => void} [oncopy] Called with the address and whether
|
|
16
|
+
* the clipboard took it.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @typedef {Object} ProseAnchors
|
|
21
|
+
* @property {() => void} refresh Links headings added since, re-attaches the live region if the
|
|
22
|
+
* content was replaced, and updates the address of every link. Call it after re-rendering.
|
|
23
|
+
* @property {() => void} destroy Removes every link, the live region, and the listener.
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
/** @type {Readonly<Required<Omit<ProseAnchorsOptions, 'href'|'oncopy'>>>} */
|
|
27
|
+
const defaults = Object.freeze({
|
|
28
|
+
selector: 'h2[id], h3[id], h4[id]',
|
|
29
|
+
label: 'Copy link to %1',
|
|
30
|
+
title: 'Copy link',
|
|
31
|
+
feedback: 'Link copied',
|
|
32
|
+
feedbackDuration: 2000
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* The address of a section: `base` with its hash replaced by the heading's id. The query is kept,
|
|
37
|
+
* and the id is encoded as a fragment.
|
|
38
|
+
* @param {string} base Absolute address, usually `location.href`.
|
|
39
|
+
* @param {string} id Heading id.
|
|
40
|
+
* @returns {string}
|
|
41
|
+
*/
|
|
42
|
+
export function sectionHref(base, id) {
|
|
43
|
+
const url = new URL(String(base));
|
|
44
|
+
url.hash = String(id);
|
|
45
|
+
return url.href;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Gives every section heading of authored content a link to itself. Each `h2`–`h4` with an `id`
|
|
50
|
+
* inside a `.zx-prose` under `root` ends in a small link (`<a class="zx-prose__anchor" href="#id">`)
|
|
51
|
+
* that rests out of sight and shows while the heading is pointed at or the link has focus. A plain
|
|
52
|
+
* click copies the section's address and confirms in place, without moving the page or touching
|
|
53
|
+
* the location, so an application's own routing is left alone; a middle or modified click is left
|
|
54
|
+
* to the browser, which opens the address.
|
|
55
|
+
*
|
|
56
|
+
* The heading becomes the reveal host (`data-zx-reveal-host`), so the link is always visible on a
|
|
57
|
+
* touch screen and under a contrast preference, and it stays in the Tab order.
|
|
58
|
+
*
|
|
59
|
+
* @param {Element|string} root The content, or an element holding it; a selector is resolved in
|
|
60
|
+
* the document.
|
|
61
|
+
* @param {ProseAnchorsOptions} [options={}] Anchor options.
|
|
62
|
+
* @returns {ProseAnchors}
|
|
63
|
+
*/
|
|
64
|
+
export function proseAnchors(root, options = {}) {
|
|
65
|
+
const target = typeof root === 'string' ? document.querySelector(root) : root;
|
|
66
|
+
if (!(target instanceof Element)) throw new TypeError('proseAnchors root could not be resolved');
|
|
67
|
+
const settings = { ...defaults, ...options };
|
|
68
|
+
const abort = new AbortController();
|
|
69
|
+
/** @type {Map<HTMLAnchorElement, HTMLElement>} Link → its heading. */
|
|
70
|
+
const anchors = new Map();
|
|
71
|
+
/** @type {Set<HTMLElement>} Headings this call made reveal hosts. */
|
|
72
|
+
const hosts = new Set();
|
|
73
|
+
const status = h('span', { class: 'zx-prose__status', role: 'status' });
|
|
74
|
+
let timer = 0;
|
|
75
|
+
|
|
76
|
+
const hrefFor = (/** @type {string} */ id) => (typeof settings.href === 'function'
|
|
77
|
+
? String(settings.href(id))
|
|
78
|
+
: sectionHref(globalThis.location?.href ?? 'about:blank', id));
|
|
79
|
+
|
|
80
|
+
const refresh = () => {
|
|
81
|
+
if (abort.signal.aborted) return;
|
|
82
|
+
for (const [anchor, heading] of anchors) {
|
|
83
|
+
if (anchor.isConnected && heading.contains(anchor) && heading.id) {
|
|
84
|
+
anchor.setAttribute('href', `#${heading.id}`);
|
|
85
|
+
continue;
|
|
86
|
+
}
|
|
87
|
+
anchor.remove();
|
|
88
|
+
anchors.delete(anchor);
|
|
89
|
+
}
|
|
90
|
+
const headings = /** @type {HTMLElement[]} */ ([...target.querySelectorAll(String(settings.selector))]);
|
|
91
|
+
for (const heading of headings) {
|
|
92
|
+
if (!heading.id || !heading.closest('.zx-prose')) continue;
|
|
93
|
+
if ([...anchors.values()].includes(heading)) continue;
|
|
94
|
+
const text = (heading.textContent ?? '').trim();
|
|
95
|
+
const anchor = /** @type {HTMLAnchorElement} */ (h('a', {
|
|
96
|
+
class: 'zx-prose__anchor',
|
|
97
|
+
href: `#${heading.id}`,
|
|
98
|
+
ariaLabel: String(settings.label).replace('%1', text),
|
|
99
|
+
title: String(settings.title),
|
|
100
|
+
'data-zx-reveal': ''
|
|
101
|
+
}, icon('link-2')));
|
|
102
|
+
if (!heading.hasAttribute('data-zx-reveal-host')) {
|
|
103
|
+
heading.setAttribute('data-zx-reveal-host', '');
|
|
104
|
+
hosts.add(heading);
|
|
105
|
+
}
|
|
106
|
+
heading.append(anchor);
|
|
107
|
+
anchors.set(anchor, heading);
|
|
108
|
+
}
|
|
109
|
+
// The live region sits beside the content, never inside a heading, whose name it would join.
|
|
110
|
+
if (!status.isConnected) target.append(status);
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
target.addEventListener('click', async (event) => {
|
|
114
|
+
const anchor = /** @type {Element} */ (event.target)?.closest?.('.zx-prose__anchor');
|
|
115
|
+
if (!(anchor instanceof HTMLAnchorElement) || !anchors.has(anchor)) return;
|
|
116
|
+
if (event.button !== 0 || event.metaKey || event.ctrlKey || event.shiftKey || event.altKey) return;
|
|
117
|
+
event.preventDefault();
|
|
118
|
+
const heading = anchors.get(anchor);
|
|
119
|
+
const url = hrefFor(heading?.id ?? '');
|
|
120
|
+
const copied = await copyToClipboard(url);
|
|
121
|
+
if (abort.signal.aborted) return;
|
|
122
|
+
settings.oncopy?.(url, copied);
|
|
123
|
+
if (!copied) return;
|
|
124
|
+
clearTimeout(timer);
|
|
125
|
+
for (const other of anchors.keys()) delete other.dataset.copied;
|
|
126
|
+
anchor.dataset.copied = 'true';
|
|
127
|
+
anchor.replaceChildren(icon('check'));
|
|
128
|
+
if (!status.isConnected) target.append(status);
|
|
129
|
+
status.textContent = String(settings.feedback);
|
|
130
|
+
timer = setTimeout(() => {
|
|
131
|
+
delete anchor.dataset.copied;
|
|
132
|
+
anchor.replaceChildren(icon('link-2'));
|
|
133
|
+
status.textContent = '';
|
|
134
|
+
}, Math.max(0, Number(settings.feedbackDuration) || 0));
|
|
135
|
+
}, { signal: abort.signal });
|
|
136
|
+
|
|
137
|
+
refresh();
|
|
138
|
+
|
|
139
|
+
return {
|
|
140
|
+
refresh,
|
|
141
|
+
destroy() {
|
|
142
|
+
if (abort.signal.aborted) return;
|
|
143
|
+
abort.abort();
|
|
144
|
+
clearTimeout(timer);
|
|
145
|
+
for (const anchor of anchors.keys()) anchor.remove();
|
|
146
|
+
anchors.clear();
|
|
147
|
+
for (const heading of hosts) heading.removeAttribute('data-zx-reveal-host');
|
|
148
|
+
hosts.clear();
|
|
149
|
+
status.remove();
|
|
150
|
+
}
|
|
151
|
+
};
|
|
152
|
+
}
|
|
@@ -223,27 +223,17 @@
|
|
|
223
223
|
line-height: 1.45;
|
|
224
224
|
}
|
|
225
225
|
|
|
226
|
-
/* The
|
|
227
|
-
|
|
226
|
+
/* The keycap advertises the shortcut (`kbd()`, the one key-hint construction); it is
|
|
227
|
+
`aria-hidden`, since a screen-reader user moves through the group with the arrow keys. A chosen
|
|
228
|
+
answer draws its cap in the accent, through the keycap's own hooks. */
|
|
228
229
|
.zx-questionnaire__key {
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
place-items: center;
|
|
232
|
-
border: 1px solid var(--zx-color-border);
|
|
233
|
-
border-radius: var(--zx-radius-sm);
|
|
234
|
-
background: var(--zx-color-bg-muted);
|
|
235
|
-
padding-inline: var(--zx-space-2);
|
|
236
|
-
min-inline-size: 22px;
|
|
237
|
-
block-size: 22px;
|
|
238
|
-
color: var(--zx-color-text-muted);
|
|
239
|
-
font-family: inherit;
|
|
240
|
-
font-size: var(--zx-text-xs);
|
|
241
|
-
text-transform: uppercase;
|
|
230
|
+
/* Centred on the label's first line, as the marker is. */
|
|
231
|
+
margin-block-start: calc((var(--zx-control-font-size) * 1.4 - var(--zx-kbd-size)) / 2);
|
|
242
232
|
}
|
|
243
233
|
|
|
244
234
|
.zx-questionnaire__choice:has(.zx-questionnaire__control:checked) .zx-questionnaire__key {
|
|
245
|
-
|
|
246
|
-
|
|
235
|
+
--zx-kbd-ink: var(--zx-color-accent);
|
|
236
|
+
--zx-kbd-line: var(--zx-color-accent);
|
|
247
237
|
}
|
|
248
238
|
|
|
249
239
|
/* -------------------------------------------------------------- freeform */
|
|
@@ -5,6 +5,7 @@ import { icon as createIcon } from '../../core/icons.js';
|
|
|
5
5
|
import { uid } from '../../core/util.js';
|
|
6
6
|
import { button } from '../button/button.js';
|
|
7
7
|
import { Field } from '../field/field.js';
|
|
8
|
+
import { kbd } from '../kbd/kbd.js';
|
|
8
9
|
import { ProgressBar } from '../loading/progress-bar.js';
|
|
9
10
|
import {
|
|
10
11
|
applyExclusive, isEmptyAnswer, normalizeItems, progressOf, resolveFlow, resolveNext, validateAnswer
|
|
@@ -61,6 +62,20 @@ const AUTO_ADVANCE_DELAY = 260;
|
|
|
61
62
|
/** @typedef {{answers: Record<string, unknown>, path: string[]}} QuestionnaireSubmitDetail */
|
|
62
63
|
/** @typedef {{answers: Record<string, unknown>, path: string[]}} QuestionnaireCompleteDetail */
|
|
63
64
|
|
|
65
|
+
/**
|
|
66
|
+
* The keycap that advertises a choice's shortcut, drawn by `kbd()` like every other key hint. It
|
|
67
|
+
* is `aria-hidden`: a screen-reader user moves through the group with the arrow keys, and hearing
|
|
68
|
+
* the key before every answer would only be noise.
|
|
69
|
+
* @param {string} key The single character that picks the choice.
|
|
70
|
+
* @returns {HTMLElement}
|
|
71
|
+
*/
|
|
72
|
+
function keyHint(key) {
|
|
73
|
+
const hint = kbd([key]);
|
|
74
|
+
hint.classList.add('zx-questionnaire__key');
|
|
75
|
+
hint.setAttribute('aria-hidden', 'true');
|
|
76
|
+
return hint;
|
|
77
|
+
}
|
|
78
|
+
|
|
64
79
|
/**
|
|
65
80
|
* A guided, one-question-at-a-time flow: onboarding intake, a service-call checklist, an audit
|
|
66
81
|
* form, a feedback survey. The questionnaire owns the ordered items, the active one, the answers,
|
|
@@ -741,7 +756,7 @@ export class Questionnaire extends Component {
|
|
|
741
756
|
h('span', { class: 'zx-questionnaire__text' },
|
|
742
757
|
h('span', { class: 'zx-questionnaire__label' }, choice.label),
|
|
743
758
|
choice.description ? h('span', { class: 'zx-questionnaire__hint' }, choice.description) : null),
|
|
744
|
-
choice.key ?
|
|
759
|
+
choice.key ? keyHint(choice.key) : null)));
|
|
745
760
|
|
|
746
761
|
if (item.input) {
|
|
747
762
|
const inputId = `${this._uid}-freeform`;
|
|
@@ -20,9 +20,11 @@
|
|
|
20
20
|
|
|
21
21
|
/* Both glyphs sit in the same grid cell; the "on" copy is clipped to the filled fraction, which
|
|
22
22
|
is what makes half steps work without a second icon. */
|
|
23
|
+
/* An empty star is still a mark the value is read from, so it takes the subtle icon role (3:1)
|
|
24
|
+
rather than a border colour. */
|
|
23
25
|
.zx-rating__glyph {
|
|
24
26
|
grid-area: 1 / 1;
|
|
25
|
-
color: var(--zx-color-
|
|
27
|
+
color: var(--zx-color-text-subtle);
|
|
26
28
|
}
|
|
27
29
|
|
|
28
30
|
.zx-rating__glyph[data-part="on"] {
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* RunStatus — where an agent's run stands. The state is a glyph and a word; the steps and the cost
|
|
3
|
+
* are thin bars whose words sit beside or above them; the facts are a two-column property list
|
|
4
|
+
* with tabular figures. `data-compact` draws the state alone, as a pill for a narrow header, and
|
|
5
|
+
* `data-compact="icon"` as its glyph alone.
|
|
6
|
+
*/
|
|
7
|
+
.zx-run-status {
|
|
8
|
+
display: grid;
|
|
9
|
+
gap: var(--zx-space-2);
|
|
10
|
+
min-inline-size: 0;
|
|
11
|
+
color: var(--zx-color-text);
|
|
12
|
+
font-size: var(--zx-text-sm);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/* The panel holds focus itself only when an update took away the control that had it. */
|
|
16
|
+
.zx-run-status:focus-visible {
|
|
17
|
+
border-radius: var(--zx-radius-md);
|
|
18
|
+
outline-color: transparent;
|
|
19
|
+
box-shadow: var(--zx-focus-ring);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/* ------------------------------------------------------------------ state -- */
|
|
23
|
+
|
|
24
|
+
.zx-run-status__state {
|
|
25
|
+
display: flex;
|
|
26
|
+
align-items: center;
|
|
27
|
+
gap: var(--zx-space-2);
|
|
28
|
+
margin: 0;
|
|
29
|
+
font-size: var(--zx-text-lg);
|
|
30
|
+
font-weight: var(--zx-weight-semibold);
|
|
31
|
+
letter-spacing: var(--zx-tracking-tight);
|
|
32
|
+
line-height: 1.3;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.zx-run-status__summary {
|
|
36
|
+
margin: 0;
|
|
37
|
+
color: var(--zx-color-text-muted);
|
|
38
|
+
overflow-wrap: anywhere;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/* ------------------------------------------------------------------ bars -- */
|
|
42
|
+
|
|
43
|
+
.zx-run-status__steps {
|
|
44
|
+
display: flex;
|
|
45
|
+
align-items: center;
|
|
46
|
+
gap: var(--zx-space-3);
|
|
47
|
+
margin-block: var(--zx-space-1);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.zx-run-status__bar,
|
|
51
|
+
.zx-run-status__meter {
|
|
52
|
+
position: relative;
|
|
53
|
+
display: block;
|
|
54
|
+
overflow: hidden;
|
|
55
|
+
flex: 1 1 auto;
|
|
56
|
+
block-size: 4px;
|
|
57
|
+
border-radius: var(--zx-radius-full);
|
|
58
|
+
background: var(--zx-color-border-subtle);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.zx-run-status__bar-fill,
|
|
62
|
+
.zx-run-status__meter-fill {
|
|
63
|
+
display: block;
|
|
64
|
+
block-size: 100%;
|
|
65
|
+
border-radius: inherit;
|
|
66
|
+
background: var(--zx-color-accent);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.zx-run-status:is([data-state="failed"], [data-state="blocked"]) .zx-run-status__bar-fill {
|
|
70
|
+
background: var(--zx-color-danger);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.zx-run-status:is([data-state="stopped"], [data-state="skipped"], [data-state="paused"]) .zx-run-status__bar-fill {
|
|
74
|
+
background: var(--zx-color-text-muted);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.zx-run-status__steps-text {
|
|
78
|
+
flex: none;
|
|
79
|
+
color: var(--zx-color-text-muted);
|
|
80
|
+
font-size: var(--zx-text-xs);
|
|
81
|
+
font-variant-numeric: tabular-nums;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.zx-run-status__meter[data-level="warning"] .zx-run-status__meter-fill {
|
|
85
|
+
background: var(--zx-color-warning);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.zx-run-status__meter[data-level="danger"] .zx-run-status__meter-fill {
|
|
89
|
+
background: var(--zx-color-danger);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
/* ---------------------------------------------------------------- actions -- */
|
|
93
|
+
|
|
94
|
+
.zx-run-status__actions {
|
|
95
|
+
display: flex;
|
|
96
|
+
flex-wrap: wrap;
|
|
97
|
+
gap: var(--zx-space-2);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/* ------------------------------------------------------------------ facts -- */
|
|
101
|
+
|
|
102
|
+
.zx-run-status__props {
|
|
103
|
+
display: grid;
|
|
104
|
+
grid-template-columns: fit-content(9rem) minmax(0, 1fr);
|
|
105
|
+
gap: var(--zx-space-1) var(--zx-space-3);
|
|
106
|
+
margin: 0;
|
|
107
|
+
margin-block-start: var(--zx-space-1);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.zx-run-status__prop {
|
|
111
|
+
display: grid;
|
|
112
|
+
grid-column: 1 / -1;
|
|
113
|
+
grid-template-columns: subgrid;
|
|
114
|
+
align-items: baseline;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.zx-run-status__label {
|
|
118
|
+
overflow: hidden;
|
|
119
|
+
color: var(--zx-color-text-muted);
|
|
120
|
+
text-overflow: ellipsis;
|
|
121
|
+
white-space: nowrap;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.zx-run-status__value {
|
|
125
|
+
display: grid;
|
|
126
|
+
gap: var(--zx-space-1);
|
|
127
|
+
min-inline-size: 0;
|
|
128
|
+
margin: 0;
|
|
129
|
+
font-variant-numeric: tabular-nums;
|
|
130
|
+
overflow-wrap: anywhere;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.zx-run-status__value > .zx-run-status__meter {
|
|
134
|
+
margin-block-end: var(--zx-space-1);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* ---------------------------------------------------------------- compact -- */
|
|
138
|
+
|
|
139
|
+
.zx-run-status[data-compact] {
|
|
140
|
+
display: inline-flex;
|
|
141
|
+
vertical-align: middle;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.zx-run-status__pill {
|
|
145
|
+
position: relative;
|
|
146
|
+
display: inline-flex;
|
|
147
|
+
align-items: center;
|
|
148
|
+
gap: var(--zx-space-1);
|
|
149
|
+
color: var(--zx-color-text-muted);
|
|
150
|
+
font-size: var(--zx-text-sm);
|
|
151
|
+
white-space: nowrap;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.zx-run-status:is([data-state="waiting"], [data-state="blocked"], [data-state="failed"]) .zx-run-status__pill {
|
|
155
|
+
color: var(--zx-color-text);
|
|
156
|
+
font-weight: var(--zx-weight-medium);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/* The glyph alone: the word stays the accessible text, and the pill's tooltip. */
|
|
160
|
+
.zx-run-status[data-compact="icon"] .zx-run-status__word {
|
|
161
|
+
position: absolute;
|
|
162
|
+
inline-size: 1px;
|
|
163
|
+
block-size: 1px;
|
|
164
|
+
overflow: hidden;
|
|
165
|
+
clip-path: inset(50%);
|
|
166
|
+
white-space: nowrap;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
/* ----------------------------------------------------------------- motion -- */
|
|
170
|
+
|
|
171
|
+
/* While the agent works, a soft shine runs along the steps bar. The state says it in words too. */
|
|
172
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
173
|
+
.zx-run-status[data-state="running"] .zx-run-status__bar::after {
|
|
174
|
+
content: "";
|
|
175
|
+
position: absolute;
|
|
176
|
+
inset: 0;
|
|
177
|
+
background: linear-gradient(90deg, transparent, var(--zx-color-bg-surface), transparent);
|
|
178
|
+
opacity: 0.7;
|
|
179
|
+
translate: -100% 0;
|
|
180
|
+
animation: zx-run-status-sweep 1.6s var(--zx-ease) infinite;
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.zx-run-status[data-state="running"] .zx-run-status__bar:dir(rtl)::after {
|
|
184
|
+
animation-direction: reverse;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.zx-run-status__bar-fill,
|
|
188
|
+
.zx-run-status__meter-fill {
|
|
189
|
+
transition: inline-size var(--zx-dur-base) var(--zx-ease);
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
@keyframes zx-run-status-sweep {
|
|
193
|
+
to {
|
|
194
|
+
translate: 100% 0;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
@media (forced-colors: active) {
|
|
200
|
+
.zx-run-status__bar,
|
|
201
|
+
.zx-run-status__meter {
|
|
202
|
+
border: 1px solid CanvasText;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
.zx-run-status[data-state] :is(.zx-run-status__bar-fill, .zx-run-status__meter-fill) {
|
|
206
|
+
background: CanvasText;
|
|
207
|
+
}
|
|
208
|
+
}
|