@burdenoff/fe-libs 2026.912.1 → 2026.912.3

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.
@@ -96,6 +96,9 @@ export * from './preview/context';
96
96
  export * from './preview/previewTransitions';
97
97
  export * from './preview/surfaceState';
98
98
  export * from './preview/runIdentity';
99
+ export * from './preview/entity/entityPreviewState';
100
+ export * from './preview/entity/AssistantStepRail';
101
+ export * from './preview/entity/AssistantEntityPreview';
99
102
  export * from './ui/panelOverlays';
100
103
  export * from './ui/useDropdownEscape';
101
104
  export * from './ui/useOverlayFocus';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/shared/assistant/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAGH,cAAc,gCAAgC,CAAC;AAC/C,cAAc,mCAAmC,CAAC;AAClD,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,OAAO,CAAC;AACtB,cAAc,SAAS,CAAC;AAGxB,cAAc,wBAAwB,CAAC;AAKvC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,+BAA+B,CAAC;AAG9C,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,qBAAqB,CAAC;AACpC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAGlC,cAAc,gBA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mB,CAAC;AAElC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,2BAA2B,CAAC;AAE1C,cAAc,mBAAmB,CAAC;AAClC,cAAc,2BAA2B,CAAC;AAE1C,cAAc,iCAAiC,CAAC;AAGhD,cAAc,OAAO,CAAC;AACtB,cAAc,yBAAyB,CAAC;AACxC,cAAc,iCAAiC,CAAC;AAChD,cAAc,qCAAqC,CAAC;AACpD,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC"}
@@ -0,0 +1,85 @@
1
+ import { FC, ReactNode } from 'react';
2
+ import { AssistantStepRailProps } from './AssistantStepRail';
3
+ import { AssistantPreviewFollow, AssistantPreviewStep } from './entityPreviewState';
4
+ export interface AssistantPreviewTab {
5
+ /**
6
+ * Stable id.
7
+ *
8
+ * ★ Matching a STEP id is what makes the surface follow the run — see
9
+ * `nextActiveTab`. Ids that match nothing are still perfectly valid; such a
10
+ * tab is simply never auto-selected.
11
+ */
12
+ readonly id: string;
13
+ readonly label: string;
14
+ /** Optional count, e.g. how many widgets this tab holds. */
15
+ readonly badge?: string | number;
16
+ /** Rendered only while the tab is active, so an inactive tab costs nothing. */
17
+ readonly render: () => ReactNode;
18
+ }
19
+ export interface AssistantEntityPreviewProps {
20
+ readonly title: string;
21
+ readonly steps?: readonly AssistantPreviewStep[];
22
+ readonly tabs?: readonly AssistantPreviewTab[];
23
+ /**
24
+ * Identifies the current run. A CHANGE releases the viewer's tab choice.
25
+ *
26
+ * ★ Without it a tab pinned during one run silently governs the next, so the
27
+ * surface sat on a stale tab while a new build ran behind it.
28
+ */
29
+ readonly runKey?: string | null;
30
+ /**
31
+ * Which step the surface follows when nothing is pinned. Defaults to
32
+ * `produced` — see `AssistantPreviewFollow`; the intuitive "follow the running
33
+ * step" parks the viewer on a tab whose entity does not exist yet.
34
+ */
35
+ readonly follow?: AssistantPreviewFollow;
36
+ /** What the run says it is doing right now. */
37
+ readonly caption?: string | null;
38
+ /** Set when the run failed, so the surface stops pretending to be live. */
39
+ readonly error?: string | null;
40
+ /**
41
+ * Free-form status line — "updated 2m ago", a live badge, a count.
42
+ *
43
+ * ★ `ReactNode`, not a string: the real consumer's version of this line is a
44
+ * pulsing "Live" pill beside the timestamp. Forcing it to a string would have
45
+ * meant either losing that or pushing the whole header back into the product.
46
+ */
47
+ readonly meta?: ReactNode;
48
+ readonly onClose?: () => void;
49
+ /**
50
+ * Replaces the default close button.
51
+ *
52
+ * ★ A product with its own button vocabulary (an icon-only ghost button, say)
53
+ * should not have to choose between this surface and its own design system.
54
+ * `onClose` remains the simple path for products that have no opinion.
55
+ */
56
+ readonly headerActions?: ReactNode;
57
+ /** Already-translated chrome strings. This component holds no translator. */
58
+ readonly labels?: {
59
+ readonly close?: string;
60
+ readonly steps?: string;
61
+ readonly skipped?: string;
62
+ readonly stepsHeading?: string;
63
+ /**
64
+ * How each step STATUS is said, for people who cannot see the glyph.
65
+ *
66
+ * ★★ Forwarded to the rail. Without this a non-English product could
67
+ * translate every visible string and still have "completed" and "failed"
68
+ * announced in English — the one place where the difference between them
69
+ * is the whole message.
70
+ */
71
+ readonly stepStatus?: AssistantStepRailProps['statusLabels'];
72
+ /**
73
+ * Names the failure above the message — "Build stopped", "Import failed".
74
+ *
75
+ * ★ Optional. A raw transport message ("ECONNRESET") tells a viewer that
76
+ * something broke but not WHAT, and only the product knows what the run was
77
+ * called. Omit it and the message stands alone, as before.
78
+ */
79
+ readonly errorHeading?: string;
80
+ };
81
+ /** Body shown when there are no tabs. */
82
+ readonly children?: ReactNode;
83
+ }
84
+ export declare const AssistantEntityPreview: FC<AssistantEntityPreviewProps>;
85
+ //# sourceMappingURL=AssistantEntityPreview.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AssistantEntityPreview.d.ts","sourceRoot":"","sources":["../../../../../src/shared/assistant/preview/entity/AssistantEntityPreview.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAQL,KAAK,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CAAC,EAAE,MAAM,CAAC;QACxB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;QACxB,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;QAC1B,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;QAC/B;;;;;;;WAOG;QACH,QAAQ,CAAC,UAAU,CAAC,EAAE,sBAAsB,CAAC,cAAc,CAAC,CAAC;QAC7D;;;;;;WAMG;QACH,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;KAChC,CAAC;IACF,yCAAyC;IACzC,QAAQ,CAAC,QAAQ,CAAC,EAAE,SAAS,CAAC;CAC/B;AAgaD,eAAO,MAAM,sBAAsB,EAAE,EAAE,CAAC,2BAA2B,CAqKlE,CAAC"}
@@ -0,0 +1,230 @@
1
+ import { IDLE_ACTIVE_TAB as e, nextActiveTab as t, pinActiveTab as n, shouldPinOnMove as r, shouldPinOnSelect as i, tabForArrowKey as a } from "./entityPreviewState.js";
2
+ import { AssistantStepRail as o } from "./AssistantStepRail.js";
3
+ import { useCallback as s, useEffect as c, useId as l, useMemo as u, useRef as d, useState as f } from "react";
4
+ import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
5
+ //#region src/shared/assistant/preview/entity/AssistantEntityPreview.tsx
6
+ var g = {
7
+ borderColor: "var(--color-border-subtle)",
8
+ backgroundColor: "var(--color-bg-sunken)",
9
+ boxShadow: "var(--shadow-elevation-1)",
10
+ borderRadius: "var(--radius-card)"
11
+ }, _ = { borderColor: "var(--color-border-subtle)" }, v = {
12
+ borderColor: "var(--color-status-error-border)",
13
+ backgroundColor: "var(--color-status-error-bgSubtle)",
14
+ color: "var(--color-status-error-text)"
15
+ }, y = (e) => e.replace(/[^A-Za-z0-9_-]/g, (e) => `-${e.charCodeAt(0).toString(36)}-`), b = [], x = [], S = ({ title: e, meta: t, onClose: n, headerActions: r, closeLabel: i }) => /* @__PURE__ */ h("header", {
16
+ className: "flex items-center justify-between gap-2 border-b px-3 py-2",
17
+ style: _,
18
+ children: [/* @__PURE__ */ h("div", {
19
+ className: "flex min-w-0 items-center gap-2",
20
+ children: [/* @__PURE__ */ m("span", {
21
+ className: "truncate text-sm font-medium",
22
+ style: { color: "var(--color-text-primary)" },
23
+ children: e
24
+ }), t == null ? null : /* @__PURE__ */ m("span", {
25
+ className: "shrink-0 text-xs",
26
+ style: { color: "var(--color-text-muted)" },
27
+ "data-testid": "assistant-entity-preview-meta",
28
+ children: t
29
+ })]
30
+ }), r ?? (n ? /* @__PURE__ */ m("button", {
31
+ type: "button",
32
+ onClick: n,
33
+ className: "shrink-0 rounded-md px-2 py-1 text-xs focus:outline-none focus-visible:ring-2",
34
+ style: { color: "var(--color-text-secondary)" },
35
+ "aria-label": i ?? "Close preview",
36
+ "data-testid": "assistant-entity-preview-close",
37
+ children: i ?? "Close preview"
38
+ }) : null)]
39
+ }), C = ({ error: e, errorHeading: t, caption: n }) => /* @__PURE__ */ h(p, { children: [e ? /* @__PURE__ */ m("div", {
40
+ role: "alert",
41
+ className: "border-b px-3 py-2",
42
+ style: v,
43
+ "data-testid": "assistant-entity-preview-error",
44
+ children: /* @__PURE__ */ h("p", {
45
+ className: "flex items-start gap-1.5 text-xs",
46
+ style: { margin: 0 },
47
+ children: [/* @__PURE__ */ h("svg", {
48
+ "aria-hidden": "true",
49
+ focusable: "false",
50
+ width: "14",
51
+ height: "14",
52
+ viewBox: "0 0 24 24",
53
+ fill: "none",
54
+ stroke: "currentColor",
55
+ strokeWidth: "2",
56
+ strokeLinecap: "round",
57
+ strokeLinejoin: "round",
58
+ className: "mt-px shrink-0",
59
+ children: [
60
+ /* @__PURE__ */ m("path", { d: "M10.29 3.86 1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0Z" }),
61
+ /* @__PURE__ */ m("line", {
62
+ x1: "12",
63
+ y1: "9",
64
+ x2: "12",
65
+ y2: "13"
66
+ }),
67
+ /* @__PURE__ */ m("line", {
68
+ x1: "12",
69
+ y1: "17",
70
+ x2: "12.01",
71
+ y2: "17"
72
+ })
73
+ ]
74
+ }), /* @__PURE__ */ h("span", {
75
+ className: "min-w-0 break-words",
76
+ children: [t ? /* @__PURE__ */ h("span", {
77
+ className: "font-semibold uppercase tracking-wide",
78
+ children: [t, ": "]
79
+ }) : null, e]
80
+ })]
81
+ })
82
+ }) : null, /* @__PURE__ */ m("p", {
83
+ "aria-live": "polite",
84
+ className: e == null && n ? "border-b px-3 py-2 text-xs" : void 0,
85
+ style: n && !e ? {
86
+ ..._,
87
+ color: "var(--color-text-secondary)",
88
+ margin: 0
89
+ } : { margin: 0 },
90
+ "data-testid": "assistant-entity-preview-caption",
91
+ children: e ? "" : n ?? ""
92
+ })] }), w = ({ tabs: e, tabIds: t, title: n, activeId: o, pinnedId: s, onPick: l, tabDomId: u, panelDomId: f }) => {
93
+ let p = d(null), g = d(null);
94
+ return c(() => {
95
+ let e = g.current;
96
+ if (e !== null) {
97
+ if (t.includes(e)) {
98
+ document.activeElement === document.body && (g.current = null);
99
+ return;
100
+ }
101
+ g.current = null, document.activeElement === document.body && o !== null && (g.current = o, document.getElementById(u(o))?.focus());
102
+ }
103
+ }, [
104
+ t,
105
+ o,
106
+ u
107
+ ]), e.length === 0 ? null : /* @__PURE__ */ m("div", {
108
+ ref: p,
109
+ role: "tablist",
110
+ "aria-label": n,
111
+ className: "flex min-w-0 items-center gap-1 overflow-x-auto border-b px-2 py-1",
112
+ style: _,
113
+ children: e.map((e) => {
114
+ let n = e.id === o;
115
+ return /* @__PURE__ */ h("button", {
116
+ type: "button",
117
+ role: "tab",
118
+ id: u(e.id),
119
+ "aria-selected": n,
120
+ "aria-controls": n ? f(e.id) : void 0,
121
+ tabIndex: n ? 0 : -1,
122
+ onClick: () => {
123
+ i(e.id, s) && l(e.id);
124
+ },
125
+ onFocus: () => {
126
+ g.current = e.id;
127
+ },
128
+ onBlur: (t) => {
129
+ let n = t.relatedTarget;
130
+ if (n !== null) {
131
+ if (p.current?.contains(n) === !0) return;
132
+ g.current === e.id && (g.current = null);
133
+ return;
134
+ }
135
+ let r = e.id;
136
+ queueMicrotask(() => {
137
+ g.current === r && document.getElementById(u(r)) !== null && (g.current = null);
138
+ });
139
+ },
140
+ onKeyDown: (n) => {
141
+ let i = getComputedStyle(n.currentTarget).direction === "rtl", c = a(n.key, t, e.id, i);
142
+ c !== null && (n.preventDefault(), r(c, s, o) && l(c), document.getElementById(u(c))?.focus());
143
+ },
144
+ "data-testid": `assistant-entity-tab-${e.id}`,
145
+ "data-selected": n ? "true" : "false",
146
+ className: "shrink-0 rounded-md px-2.5 py-1 text-xs font-medium focus:outline-none focus-visible:ring-2",
147
+ style: {
148
+ backgroundColor: n ? "var(--color-bg-surface)" : "transparent",
149
+ color: n ? "var(--color-text-primary)" : "var(--color-text-muted)"
150
+ },
151
+ children: [e.label, e.badge === void 0 ? null : /* @__PURE__ */ m("span", {
152
+ className: "ml-1.5 text-[10px]",
153
+ children: e.badge
154
+ })]
155
+ }, e.id);
156
+ })
157
+ });
158
+ }, T = ({ title: r, steps: i = b, tabs: a = x, runKey: c = null, follow: d, caption: p, error: v, meta: T, onClose: E, headerActions: D, labels: O, children: k }) => {
159
+ let A = l(), j = s((e) => `assistant-entity-tab-${A}-${y(e)}`, [A]), M = s((e) => `assistant-entity-panel-${A}-${y(e)}`, [A]), [N, P] = f(e), F = u(() => a.map((e) => e.id), [a]), I = t(N, {
160
+ runKey: c,
161
+ tabIds: F,
162
+ steps: i,
163
+ follow: d
164
+ });
165
+ (I.pinnedId !== N.pinnedId || I.runKey !== N.runKey || I.activeId !== N.activeId) && P({
166
+ activeId: I.activeId,
167
+ pinnedId: I.pinnedId,
168
+ runKey: I.runKey
169
+ });
170
+ let L = a.find((e) => e.id === I.activeId) ?? null;
171
+ return /* @__PURE__ */ h("section", {
172
+ className: "flex min-w-0 flex-col overflow-hidden border",
173
+ style: g,
174
+ "data-testid": "assistant-entity-preview",
175
+ "aria-label": r,
176
+ children: [
177
+ /* @__PURE__ */ m(S, {
178
+ title: r,
179
+ meta: T,
180
+ onClose: E,
181
+ headerActions: D,
182
+ closeLabel: O?.close
183
+ }),
184
+ i.length > 0 ? /* @__PURE__ */ h("div", {
185
+ className: "border-b px-3 py-2",
186
+ style: _,
187
+ children: [O?.stepsHeading ? /* @__PURE__ */ m("h3", {
188
+ className: "mb-1 text-[11px] font-semibold uppercase tracking-wide",
189
+ style: { color: "var(--color-text-muted)" },
190
+ children: O.stepsHeading
191
+ }) : null, /* @__PURE__ */ m(o, {
192
+ steps: i,
193
+ label: O?.steps,
194
+ skippedLabel: O?.skipped,
195
+ statusLabels: O?.stepStatus
196
+ })]
197
+ }) : null,
198
+ /* @__PURE__ */ m(C, {
199
+ error: v,
200
+ errorHeading: O?.errorHeading,
201
+ caption: p
202
+ }),
203
+ /* @__PURE__ */ m(w, {
204
+ tabs: a,
205
+ tabIds: F,
206
+ title: r,
207
+ activeId: I.activeId,
208
+ pinnedId: I.pinnedId,
209
+ onPick: (e) => {
210
+ P(n(e, c));
211
+ },
212
+ tabDomId: j,
213
+ panelDomId: M
214
+ }),
215
+ /* @__PURE__ */ m("div", {
216
+ className: "min-w-0 flex-1 overflow-auto",
217
+ children: L ? /* @__PURE__ */ m("div", {
218
+ role: "tabpanel",
219
+ tabIndex: 0,
220
+ id: M(L.id),
221
+ "aria-labelledby": j(L.id),
222
+ "data-testid": "assistant-entity-preview-panel",
223
+ children: L.render()
224
+ }) : k
225
+ })
226
+ ]
227
+ });
228
+ };
229
+ //#endregion
230
+ export { T as AssistantEntityPreview };
@@ -0,0 +1,22 @@
1
+ import { FC } from 'react';
2
+ import { AssistantPreviewStep, AssistantPreviewStepStatus } from './entityPreviewState';
3
+ export interface AssistantStepRailProps {
4
+ readonly steps: readonly AssistantPreviewStep[];
5
+ /** Accessible name for the rail. Supplied by the product, already translated. */
6
+ readonly label?: string;
7
+ /** Suffix shown on a skipped chip. */
8
+ readonly skippedLabel?: string;
9
+ /**
10
+ * How each status is SAID, for people who cannot see the glyph.
11
+ *
12
+ * ★★★ Without this the rail announced the same string whether a step had
13
+ * succeeded or failed: the pip is `aria-hidden` (it is decorative), a
14
+ * `data-status` attribute is not accessibility metadata, and only `running`
15
+ * carried `aria-current`. "Parser" and "Parser" are indistinguishable, so a
16
+ * screen-reader user was told a build had finished with no way to learn that
17
+ * half of it had failed.
18
+ */
19
+ readonly statusLabels?: Partial<Record<AssistantPreviewStepStatus, string>>;
20
+ }
21
+ export declare const AssistantStepRail: FC<AssistantStepRailProps>;
22
+ //# sourceMappingURL=AssistantStepRail.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AssistantStepRail.d.ts","sourceRoot":"","sources":["../../../../../src/shared/assistant/preview/entity/AssistantStepRail.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,OAAO,KAAK,EAAiB,EAAE,EAAE,MAAM,OAAO,CAAC;AAE/C,OAAO,KAAK,EAAE,oBAAoB,EAAE,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAyI7F,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,KAAK,EAAE,SAAS,oBAAoB,EAAE,CAAC;IAChD,iFAAiF;IACjF,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,sCAAsC;IACtC,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B;;;;;;;;;OASG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,0BAA0B,EAAE,MAAM,CAAC,CAAC,CAAC;CAC7E;AAED,eAAO,MAAM,iBAAiB,EAAE,EAAE,CAAC,sBAAsB,CAsGxD,CAAC"}
@@ -0,0 +1,124 @@
1
+ import { jsx as e, jsxs as t } from "react/jsx-runtime";
2
+ //#region src/shared/assistant/preview/entity/AssistantStepRail.tsx
3
+ var n = {
4
+ done: "M20 6 9 17l-5-5",
5
+ failed: "M18 6 6 18M6 6l12 12",
6
+ skipped: "M5 12h14"
7
+ }, r = {
8
+ done: "var(--color-status-success-text)",
9
+ failed: "var(--color-status-error-text)",
10
+ skipped: "var(--color-text-muted)",
11
+ running: "var(--color-action-primary-bg)",
12
+ pending: "var(--color-border-strong)"
13
+ }, i = ({ status: t }) => t === "pending" ? /* @__PURE__ */ e("span", {
14
+ className: "size-1.5 shrink-0 rounded-full",
15
+ style: { backgroundColor: r.pending }
16
+ }) : t === "running" ? /* @__PURE__ */ e("svg", {
17
+ className: "size-3.5 shrink-0 motion-safe:animate-spin",
18
+ viewBox: "0 0 24 24",
19
+ fill: "none",
20
+ stroke: r.running,
21
+ strokeWidth: "2.5",
22
+ strokeLinecap: "round",
23
+ "aria-hidden": "true",
24
+ children: /* @__PURE__ */ e("path", { d: "M21 12a9 9 0 1 1-6.219-8.56" })
25
+ }) : /* @__PURE__ */ e("svg", {
26
+ className: "size-3.5 shrink-0",
27
+ viewBox: "0 0 24 24",
28
+ fill: "none",
29
+ stroke: r[t],
30
+ strokeWidth: "2.5",
31
+ strokeLinecap: "round",
32
+ strokeLinejoin: "round",
33
+ "aria-hidden": "true",
34
+ children: /* @__PURE__ */ e("path", { d: n[t] })
35
+ });
36
+ function a(e) {
37
+ return e === "done" ? {
38
+ borderColor: "var(--color-status-success-border)",
39
+ backgroundColor: "var(--color-status-success-bgSubtle)",
40
+ color: "var(--color-status-success-text)"
41
+ } : e === "failed" ? {
42
+ borderColor: "var(--color-status-error-border)",
43
+ backgroundColor: "var(--color-status-error-bgSubtle)",
44
+ color: "var(--color-status-error-text)"
45
+ } : e === "running" ? {
46
+ borderColor: "var(--color-action-primary-bg)",
47
+ backgroundColor: "var(--color-bg-surface)",
48
+ color: "var(--color-text-primary)",
49
+ boxShadow: "var(--shadow-elevation-1)"
50
+ } : {
51
+ borderColor: "var(--color-border-subtle)",
52
+ color: "var(--color-text-muted)"
53
+ };
54
+ }
55
+ var o = {
56
+ pending: "not started",
57
+ running: "running",
58
+ done: "completed",
59
+ failed: "failed",
60
+ skipped: "skipped"
61
+ }, s = "inline-flex shrink-0 items-center gap-1.5 rounded-full border px-2.5 py-1 text-xs font-medium", c = ({ steps: n, label: r = "Build steps", skippedLabel: c = "skipped", statusLabels: l }) => {
62
+ if (n.length === 0) return null;
63
+ let u = null;
64
+ for (let e = n.length - 1; e >= 0; --e) if (n[e]?.status === "running") {
65
+ u = n[e]?.id ?? null;
66
+ break;
67
+ }
68
+ return /* @__PURE__ */ e("ul", {
69
+ className: "flex min-w-0 items-center gap-1 overflow-x-auto pb-0.5",
70
+ style: {
71
+ listStyle: "none",
72
+ margin: 0,
73
+ padding: 0
74
+ },
75
+ "data-testid": "assistant-preview-step-rail",
76
+ "aria-label": r,
77
+ children: n.map((r, d) => /* @__PURE__ */ t("li", {
78
+ className: "flex shrink-0 items-center gap-1",
79
+ children: [/* @__PURE__ */ t("span", {
80
+ "data-testid": `assistant-preview-step-${r.id}`,
81
+ "data-status": r.status,
82
+ "aria-current": r.id === u ? "step" : void 0,
83
+ className: s,
84
+ style: a(r.status),
85
+ children: [
86
+ /* @__PURE__ */ e(i, { status: r.status }),
87
+ r.label,
88
+ r.status === "skipped" ? /* @__PURE__ */ e("span", {
89
+ className: "text-[10px]",
90
+ "aria-hidden": "true",
91
+ children: c
92
+ }) : null,
93
+ /* @__PURE__ */ e("span", {
94
+ style: {
95
+ position: "absolute",
96
+ width: 1,
97
+ height: 1,
98
+ margin: -1,
99
+ padding: 0,
100
+ overflow: "hidden",
101
+ clip: "rect(0 0 0 0)",
102
+ clipPath: "inset(50%)",
103
+ whiteSpace: "nowrap",
104
+ border: 0
105
+ },
106
+ children: `, ${l?.[r.status] ?? o[r.status]}`
107
+ })
108
+ ]
109
+ }), d < n.length - 1 ? /* @__PURE__ */ e("svg", {
110
+ className: "size-3.5 shrink-0",
111
+ viewBox: "0 0 24 24",
112
+ fill: "none",
113
+ stroke: "var(--color-text-muted)",
114
+ strokeWidth: "2",
115
+ strokeLinecap: "round",
116
+ strokeLinejoin: "round",
117
+ "aria-hidden": "true",
118
+ children: /* @__PURE__ */ e("path", { d: "m9 18 6-6-6-6" })
119
+ }) : null]
120
+ }, r.id))
121
+ });
122
+ };
123
+ //#endregion
124
+ export { c as AssistantStepRail };
@@ -0,0 +1,176 @@
1
+ import { AssistantToolStep } from '../../ui/AssistantToolActivity';
2
+ /**
3
+ * ★★ THE UNION OF BOTH VOCABULARIES IN USE, not either one of them.
4
+ *
5
+ * - this package's tool steps: `queued | running | completed | failed`
6
+ * - BigConsole's build steps: `pending | running | done | skipped`
7
+ *
8
+ * `failed` and `skipped` each exist in exactly one of them, and that asymmetry
9
+ * is not cosmetic: BigConsole's own pip renders four statuses and falls through
10
+ * to the not-started dot for anything else, so feeding it a `failed` tool step
11
+ * would have drawn a FAILED tool as one that never started. Whatever this
12
+ * surface accepts, it must draw — see `AssistantStepRail`, which has a branch
13
+ * for all five.
14
+ */
15
+ export type AssistantPreviewStepStatus = 'pending' | 'running' | 'done' | 'failed' | 'skipped';
16
+ /**
17
+ * Which step the surface follows when the viewer has not pinned a tab.
18
+ *
19
+ * ★★★ THE DEFAULT IS `produced`, AND THAT IS NOT THE OBVIOUS CHOICE.
20
+ * "Follow the running step" is the intuitive rule and it is wrong for this
21
+ * surface: these tabs show the ENTITIES a step produced, and a step that is
22
+ * still running has not produced one yet — so following it parks the viewer on
23
+ * an empty tab for as long as the work takes. The real consumer had already
24
+ * worked this out and written it down (BigConsole's `AiPreviewPanel`: "so the
25
+ * moment the data sink is created you see its rows, not an empty 'waiting for
26
+ * the dashboard' tab"). The rail still shows the spinner on the next step, so
27
+ * nothing about progress is lost.
28
+ *
29
+ * `running` remains available for a surface whose tabs show live output of the
30
+ * step itself rather than its result.
31
+ */
32
+ export type AssistantPreviewFollow = 'produced' | 'running';
33
+ export interface AssistantPreviewStep {
34
+ /** Stable within the run. Matched against tab ids to follow the run. */
35
+ readonly id: string;
36
+ readonly label: string;
37
+ readonly status: AssistantPreviewStepStatus;
38
+ }
39
+ /**
40
+ * Adapts this package's parsed tool activity into the surface's vocabulary, so
41
+ * a product on the `preview` capability can render the same rail as a product
42
+ * driving the surface from its own store.
43
+ *
44
+ * ★ Total by construction: `FROM_TOOL_STATUS` is keyed on the tool status type,
45
+ * so adding a status there is a compile error here rather than a step that
46
+ * silently renders as `pending`.
47
+ */
48
+ export declare function stepsFromToolActivity(steps: readonly AssistantToolStep[]): AssistantPreviewStep[];
49
+ /**
50
+ * Which tab the surface is showing, and whether the viewer chose it.
51
+ *
52
+ * ★★ EXTRACTED AS A PURE REDUCER BECAUSE IT CANNOT BE TESTED ANY OTHER WAY.
53
+ * This package has no DOM in tests — every render test uses
54
+ * `renderToStaticMarkup`, which runs NO effects and cannot click anything. A
55
+ * follow-the-run rule expressed as a `useEffect` would be literally unreachable
56
+ * from the suite, so it lives here and the component is a thin wrapper.
57
+ */
58
+ export interface ActiveTabState {
59
+ /** The tab currently shown. DERIVED every render, and persisted by the caller
60
+ * only so it can survive a moment when the run points nowhere. */
61
+ readonly activeId: string | null;
62
+ /**
63
+ * The tab the viewer CHOSE, kept separately from the one on screen.
64
+ *
65
+ * ★★★ THESE TWO WERE ONE FIELD AND THAT WAS A BUG. When a pinned tab dropped
66
+ * out of `tabIds` for a moment — tabs arrive from props and can blink — the
67
+ * reducer put the run's fallback in `activeId` while leaving the pin set, and
68
+ * the caller persisted the whole thing. The fallback then WAS the pin: the
69
+ * viewer's actual choice was gone even after their tab came back.
70
+ *
71
+ * ★★ Without this, a pin cannot survive its own tab's absence, which is
72
+ * exactly the case a pin is for.
73
+ */
74
+ readonly pinnedId: string | null;
75
+ /**
76
+ * The run ALL of this state belongs to — the shown tab as much as the pin.
77
+ *
78
+ * ★★ One key for both, because carrying either across runs is the same
79
+ * mistake. An earlier revision keyed only the pin, so an UNPINNED surface
80
+ * that finished `r1` on a later tab opened `r2` still showing it.
81
+ */
82
+ readonly runKey: string | null;
83
+ }
84
+ export declare const IDLE_ACTIVE_TAB: ActiveTabState;
85
+ export interface ActiveTabInput {
86
+ /**
87
+ * Identifies the run. A CHANGE releases the viewer's pin.
88
+ *
89
+ * ★ null means "no run" and does NOT release it: a surface sitting idle
90
+ * between runs must not reshuffle itself under a reader.
91
+ */
92
+ readonly runKey: string | null;
93
+ /** Tab ids, in display order. */
94
+ readonly tabIds: readonly string[];
95
+ /** Steps, in pipeline order. Ids are matched against `tabIds`. */
96
+ readonly steps: readonly AssistantPreviewStep[];
97
+ /** Defaults to `produced` — see `AssistantPreviewFollow` for why. */
98
+ readonly follow?: AssistantPreviewFollow;
99
+ }
100
+ /**
101
+ * The surface's only decision, applied on every render.
102
+ *
103
+ * Order matters and each clause earns its place:
104
+ * 1. a new run releases the pin — the viewer's choice was about the last run
105
+ * 2. a live pin wins over the run, but only while its tab still exists
106
+ * 3. otherwise follow the run (running step, else the last settled one)
107
+ * 4. otherwise keep what is showing, if it still exists
108
+ * 5. otherwise the first tab — and null only when there are no tabs at all
109
+ */
110
+ export declare function nextActiveTab(state: ActiveTabState, input: ActiveTabInput): ActiveTabState;
111
+ /**
112
+ * The viewer chose a tab. Pins it to the CURRENT run, so the pin is released
113
+ * by the next one rather than outliving it.
114
+ */
115
+ export declare function pinActiveTab(activeId: string, runKey: string | null): ActiveTabState;
116
+ /**
117
+ * The tab an arrow key moves to, or null when the key is not ours.
118
+ *
119
+ * ★★ A tablist using roving `tabIndex` MUST handle these. With only the
120
+ * selected tab in the tab order and no key handling, every other tab is
121
+ * unreachable by keyboard — strictly worse than leaving them all tabbable.
122
+ *
123
+ * ★ Wraps at both ends, which is what `role="tablist"` implies, and is pure so
124
+ * it can be tested in a package with no DOM.
125
+ */
126
+ export declare function tabForArrowKey(key: string, tabIds: readonly string[], activeId: string | null,
127
+ /**
128
+ * ★★ Arrow keys follow the VISUAL direction, so they swap in RTL: with the
129
+ * tabs laid out right-to-left, ArrowRight moves to the PREVIOUS one. Getting
130
+ * this wrong is not a rough edge for an Arabic or Hebrew reader — every
131
+ * arrow press goes the opposite way from the one they pressed.
132
+ */
133
+ rtl?: boolean): string | null;
134
+ /**
135
+ * Whether SELECTING `tabId` — a click, or Enter/Space on a focused tab — should
136
+ * be recorded as the viewer's choice.
137
+ *
138
+ * ★★★ COMPARED AGAINST THE PIN, NOT AGAINST WHAT IS ON SCREEN.
139
+ *
140
+ * Selecting the tab you are already reading is the commonest way to say "stay
141
+ * here", and it used to do nothing. The guard compared against
142
+ * `pinnedId ?? activeId`, so with nothing pinned a click on the displayed tab
143
+ * was swallowed as "no preference different from what the surface chose". In a
144
+ * real run that is exactly backwards: the surface puts you on the entity that
145
+ * just landed, you start reading it, the next one lands seconds later and takes
146
+ * you away — and the one tab you want to click is the only one that is inert.
147
+ * Reaching a pin meant clicking some other tab and clicking back.
148
+ *
149
+ * Comparing against the pin alone keeps the case the old guard was written for.
150
+ * A pinned tab that disappears KEEPS its pin while a fallback is shown, so
151
+ * clicking that fallback still replaces a pin the viewer can no longer see.
152
+ *
153
+ * The only selection worth ignoring is one that is already the pin.
154
+ */
155
+ export declare function shouldPinOnSelect(tabId: string, pinnedId: string | null): boolean;
156
+ /**
157
+ * Whether MOVING to `nextId` with an arrow/Home/End key should create a pin.
158
+ *
159
+ * ★★★ A DIFFERENT QUESTION FROM `shouldPinOnSelect`, and the difference is the
160
+ * point. A click says "I choose this one" even when it is already displayed. A
161
+ * navigation key says "go there" — and when there is nowhere to go it has said
162
+ * nothing at all.
163
+ *
164
+ * `tabForArrowKey` wraps, so in a ONE-TAB list every arrow resolves back to the
165
+ * tab you are on, and Home/End do the same at their edges. A one-tab list is
166
+ * not exotic here: it is what a run looks like before the second entity lands.
167
+ * Pinning on that keypress would opt the viewer out of follow-the-run for the
168
+ * rest of the build — silently, for a key that moved nothing.
169
+ *
170
+ * So this compares against what is DISPLAYED, falling back through the pin: a
171
+ * key that lands on the tab already on screen pins nothing, while one that
172
+ * lands anywhere else — including on the fallback shown in place of a pin whose
173
+ * tab has disappeared — still records the choice.
174
+ */
175
+ export declare function shouldPinOnMove(nextId: string, pinnedId: string | null, activeId: string | null): boolean;
176
+ //# sourceMappingURL=entityPreviewState.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"entityPreviewState.d.ts","sourceRoot":"","sources":["../../../../../src/shared/assistant/preview/entity/entityPreviewState.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAExE;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,0BAA0B,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE/F;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,sBAAsB,GAAG,UAAU,GAAG,SAAS,CAAC;AAE5D,MAAM,WAAW,oBAAoB;IACnC,wEAAwE;IACxE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,MAAM,EAAE,0BAA0B,CAAC;CAC7C;AAYD;;;;;;;;GAQG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,SAAS,iBAAiB,EAAE,GAAG,oBAAoB,EAAE,CAMjG;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,cAAc;IAC7B;uEACmE;IACnE,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC;;;;;;;;;;;OAWG;IACH,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;IACjC;;;;;;OAMG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;CAChC;AAED,eAAO,MAAM,eAAe,EAAE,cAI7B,CAAC;AAEF,MAAM,WAAW,cAAc;IAC7B;;;;;OAKG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IAC/B,iCAAiC;IACjC,QAAQ,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,kEAAkE;IAClE,QAAQ,CAAC,KAAK,EAAE,SAAS,oBAAoB,EAAE,CAAC;IAChD,qEAAqE;IACrE,QAAQ,CAAC,MAAM,CAAC,EAAE,sBAAsB,CAAC;CAC1C;AA6BD;;;;;;;;;GASG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,cAAc,EAAE,KAAK,EAAE,cAAc,GAAG,cAAc,CA+D1F;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,cAAc,CAEpF;AAED;;;;;;;;;GASG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,SAAS,MAAM,EAAE,EACzB,QAAQ,EAAE,MAAM,GAAG,IAAI;AACvB;;;;;GAKG;AACH,GAAG,UAAQ,GACV,MAAM,GAAG,IAAI,CAef;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAEjF;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,GAAG,IAAI,EACvB,QAAQ,EAAE,MAAM,GAAG,IAAI,GACtB,OAAO,CAET"}
@@ -0,0 +1,69 @@
1
+ //#region src/shared/assistant/preview/entity/entityPreviewState.ts
2
+ var e = new Set([
3
+ "done",
4
+ "failed",
5
+ "skipped"
6
+ ]), t = {
7
+ queued: "pending",
8
+ running: "running",
9
+ completed: "done",
10
+ failed: "failed"
11
+ };
12
+ function n(e) {
13
+ return e.map((e) => ({
14
+ id: e.id,
15
+ label: e.label,
16
+ status: t[e.status]
17
+ }));
18
+ }
19
+ var r = {
20
+ activeId: null,
21
+ pinnedId: null,
22
+ runKey: null
23
+ };
24
+ function i(t, n) {
25
+ let r = null, i = null, a = null;
26
+ for (let o of t.steps) n.has(o.id) && (o.status === "running" ? r = o.id : o.status === "done" ? (i = o.id, a = o.id) : e.has(o.status) && (a = o.id));
27
+ return t.follow === "running" ? r ?? a : i ?? r ?? a;
28
+ }
29
+ function a(e, t) {
30
+ let n = t.runKey !== null && t.runKey !== e.runKey ? {
31
+ activeId: null,
32
+ pinnedId: null,
33
+ runKey: t.runKey
34
+ } : e, r = new Set(t.tabIds);
35
+ if (n.pinnedId !== null && r.has(n.pinnedId)) return n.activeId === n.pinnedId ? n : {
36
+ ...n,
37
+ activeId: n.pinnedId
38
+ };
39
+ let a = n.activeId !== null && r.has(n.activeId) ? n.activeId : null, o = i(t, r) ?? a ?? t.tabIds[0] ?? null;
40
+ return o === n.activeId ? n : {
41
+ ...n,
42
+ activeId: o
43
+ };
44
+ }
45
+ function o(e, t) {
46
+ return {
47
+ activeId: e,
48
+ pinnedId: e,
49
+ runKey: t
50
+ };
51
+ }
52
+ function s(e, t, n, r = !1) {
53
+ if (t.length === 0) return null;
54
+ let i = t[0] ?? null, a = t[t.length - 1] ?? null;
55
+ if (e === "Home") return i;
56
+ if (e === "End") return a;
57
+ let o = e === (r ? "ArrowLeft" : "ArrowRight") ? 1 : e === (r ? "ArrowRight" : "ArrowLeft") ? -1 : 0;
58
+ if (o === 0) return null;
59
+ let s = n === null ? -1 : t.indexOf(n);
60
+ return s < 0 ? i : t[(s + o + t.length) % t.length] ?? null;
61
+ }
62
+ function c(e, t) {
63
+ return e !== t;
64
+ }
65
+ function l(e, t, n) {
66
+ return e !== (t ?? n);
67
+ }
68
+ //#endregion
69
+ export { r as IDLE_ACTIVE_TAB, a as nextActiveTab, o as pinActiveTab, l as shouldPinOnMove, c as shouldPinOnSelect, n as stepsFromToolActivity, s as tabForArrowKey };
@@ -65,41 +65,44 @@ import { AssistantPreviewProvider as gi, useAssistantPreview as _i } from "./sha
65
65
  import { IDLE_PREVIEW_STATE as vi, isRunningStatus as yi, nextPreviewEvents as bi } from "./shared/assistant/preview/previewTransitions.js";
66
66
  import { IDLE_PREVIEW as xi, NO_OWNER as Si, applyPreviewEvent as Ci, createAssistantPreviewSurface as wi, currentPreviewOwner as Ti, runBelongsTo as Ei, sameOwner as Di } from "./shared/assistant/preview/surfaceState.js";
67
67
  import { createRunIdentityCache as Oi, runIdentities as ki } from "./shared/assistant/preview/runIdentity.js";
68
- import { useOverlayFocus as Ai } from "./shared/assistant/ui/useOverlayFocus.js";
69
- import { useAssistantPreviewBridge as ji } from "./shared/assistant/preview/useAssistantPreviewBridge.js";
70
- import { AssistantPreviewOverlay as Mi } from "./shared/assistant/preview/AssistantPreviewOverlay.js";
71
- import { AssistantLanguageSelector as Ni, FOLLOW_APP_LOCALE as Pi } from "./shared/assistant/ui/composer/AssistantLanguageSelector.js";
72
- import { ASSISTANT_MODE_META as Fi, AssistantModeSelector as Ii, nextModeIndex as Li } from "./shared/assistant/ui/composer/AssistantModeSelector.js";
73
- import { AssistantVoiceButton as Ri } from "./shared/assistant/ui/composer/AssistantVoiceButton.js";
74
- import { AUTO_VOICE as zi, AssistantVoiceSelector as Bi } from "./shared/assistant/ui/composer/AssistantVoiceSelector.js";
75
- import { AssistantVoiceOrb as Vi } from "./shared/assistant/ui/voice/AssistantVoiceOrb.js";
76
- import { AssistantVoiceSessionButton as Hi } from "./shared/assistant/ui/voice/AssistantVoiceSessionButton.js";
77
- import { CAPTION_SCROLL_ATTR as Ui, VoiceCaption as Wi } from "./shared/assistant/ui/voice/VoiceCaption.js";
78
- import { VoiceConversationView as Gi } from "./shared/assistant/ui/voice/VoiceConversationView.js";
79
- import { VoiceWaveform as Ki } from "./shared/assistant/ui/voice/VoiceWaveform.js";
80
- import { VoiceMiniController as qi } from "./shared/assistant/ui/voice/VoiceMiniController.js";
81
- import { VoiceStage as Ji } from "./shared/assistant/ui/voice/VoiceStage.js";
82
- import { VoiceTranscriptDrawer as Yi } from "./shared/assistant/ui/voice/VoiceTranscriptDrawer.js";
83
- import { downloadFile as Xi, exportConversation as Zi } from "./shared/assistant/exportConversation.js";
84
- import { AssistantMoreMenu as Qi } from "./shared/assistant/ui/AssistantMoreMenu.js";
85
- import { AssistantHeader as $i } from "./shared/assistant/ui/AssistantHeader.js";
86
- import { AssistantConversationList as ea } from "./shared/assistant/ui/AssistantConversationList.js";
87
- import { AssistantEmptyState as ta } from "./shared/assistant/ui/AssistantEmptyState.js";
88
- import { AssistantMessageItem as na } from "./shared/assistant/ui/AssistantMessageItem.js";
89
- import { AssistantMessageList as ra } from "./shared/assistant/ui/AssistantMessageList.js";
90
- import { AssistantVoiceSession as ia } from "./shared/assistant/ui/voice/AssistantVoiceSession.js";
91
- import { useAssistantApiAccess as aa } from "./shared/assistant/useAssistantApiAccess.js";
92
- import { useConversationTurns as oa } from "./shared/assistant/useConversationTurns.js";
93
- import { isMultimodalBodyRejection as sa, isRecoverableAssistantError as ca } from "./shared/assistant/transportErrors.js";
94
- import { aiCreditsUpdatedEventName as la, dispatchAssistantQuotaExhausted as ua, notifyAiCreditsUpdated as da } from "./shared/assistant/aiCredits.js";
95
- import { useWorkspaceWriteAccess as fa } from "./shared/assistant/useWorkspaceWriteAccess.js";
96
- import { extractDocumentText as pa } from "./shared/assistant/documentExtract.js";
97
- import { useAssistantAttachments as ma } from "./shared/assistant/useAssistantAttachments.js";
98
- import { AssistantComposer as ha } from "./shared/assistant/ui/composer/AssistantComposer.js";
99
- import { isProdRuntime as ga } from "./shared/assistant/env.js";
100
- import { useAssistantHeartbeat as _a } from "./shared/assistant/useAssistantHeartbeat.js";
101
- import { useAssistantKeyboardShortcuts as va } from "./shared/assistant/useAssistantKeyboardShortcuts.js";
102
- import { AssistantApiCallsConsentDialog as ya } from "./shared/assistant/ui/AssistantApiCallsConsentDialog.js";
103
- import { AssistantChatArea as ba } from "./shared/assistant/ui/AssistantChatArea.js";
104
- import { AIAssistantPanel as xa } from "./shared/assistant/ui/AIAssistantPanel.js";
105
- export { xa as AIAssistantPanel, L as ASSISTANT_API_AUTH_STRATEGY, sn as ASSISTANT_LANGUAGES, Fi as ASSISTANT_MODE_META, ii as ASSISTANT_OVERLAY_ATTR, ai as ASSISTANT_PANEL_ATTR, Kn as ATTACHMENT_ACCEPT, Hr as ATTACHMENT_SOURCES, zi as AUTO_VOICE, ya as AssistantApiCallsConsentDialog, mi as AssistantAttachmentButton, hi as AssistantAttachmentChips, Jr as AssistantAutoSpeakToggle, ba as AssistantChatArea, ha as AssistantComposer, ri as AssistantConnectSourceItem, ti as AssistantConnectSourceProvider, ea as AssistantConversationList, ta as AssistantEmptyState, $i as AssistantHeader, s as AssistantI18nProvider, Zr as AssistantLanguageMenu, Ni as AssistantLanguageSelector, f as AssistantMarkdownImage, h as AssistantMarkdownRenderer, Yr as AssistantMessageAttachments, na as AssistantMessageItem, ra as AssistantMessageList, Ii as AssistantModeSelector, Qi as AssistantMoreMenu, g as AssistantNavigateProvider, Xr as AssistantPendingWriteCard, Mi as AssistantPreviewOverlay, gi as AssistantPreviewProvider, t as AssistantProductProvider, Qr as AssistantReplyLanguageSelector, _e as AssistantRuntimeManager, $r as AssistantSpeakButton, Ir as AssistantSpeechProvider, ei as AssistantSpokenTurnsNotice, Pr as AssistantToolActivity, Ri as AssistantVoiceButton, Vi as AssistantVoiceOrb, Bi as AssistantVoiceSelector, ia as AssistantVoiceSession, Hi as AssistantVoiceSessionButton, qn as AttachmentRejectedError, En as BOILERPLATE_PAGE_SHARE, Ui as CAPTION_SCROLL_ATTR, O as CHECK_AI_CREDITS, k as CREATE_SANDBOX, zt as DEFAULT_SPEAKABLE_LABELS, cn as DEFAULT_SPEECH_RATE, ft as ENDPOINT_GRACE_MS, A as EXTEND_SANDBOX_TTL, Pi as FOLLOW_APP_LOCALE, j as GET_ACTIVE_SANDBOXES, M as GET_SANDBOX, He as HOSTED_TTS_MAX_CHARS, Re as HOSTED_TTS_TIER, ze as HOSTED_VOICES, yn as IDLE_PLAYBACK, xi as IDLE_PREVIEW, vi as IDLE_PREVIEW_STATE, pt as INITIAL_SESSION, Jn as INLINE_IMAGE_MAX_DIM, Yn as INLINE_IMAGE_QUALITY, mt as INTERRUPT_MAX_MS, ht as INTERRUPT_MIN_MS, Xn as MAX_ATTACHMENTS, Dn as MAX_BOILERPLATE_LINE_CHARS, On as MAX_EXTRACTED_CHARS, Zn as MAX_FILE_BYTES, Qn as MAX_INLINE_CHARS_PER_FILE, $n as MAX_INLINE_CHARS_TOTAL, wn as MAX_INLINE_IMAGE_BASE64_BYTES, er as MAX_INLINE_IMAGE_BASE64_CHARS, tr as MAX_INLINE_IMAGE_PARTS, nr as MAX_INLINE_TURN_BODY_BYTES, kn as MAX_PDF_PAGES_SCANNED, Tn as MAX_REQUEST_BODY_BYTES, Bt as MAX_SPEAKABLE_CHARS, Vt as MAX_SPOKEN_TABLE_ROWS, rr as MAX_TURN_BODY_BYTES, Zt as MINI_CAPTION_BUDGET, An as MIN_PAGE_TEXT_CHARS, jn as MIN_TEXT_PAGE_SHARE, Si as NO_OWNER, oi as NO_PANEL_OVERLAY, Dr as PHRASE_ROTATE_MS, $t as POLL_FAST_MS, en as POLL_FAST_UNTIL_MS, tn as POLL_SLOW_MS, nn as POLL_STEADY_MS, rn as POLL_STEADY_UNTIL_MS, Yt as PREVIEW_LANGUAGES, ir as PROMPT_ENVELOPE_RESERVE_BYTES, N as PROXY_SANDBOX_REQUEST, P as REPORT_AI_TOKEN_USAGE, Gr as SANDBOX_READY_TTL_MS, gt as SILENCE_SUBMIT_MS, Ue as SPEAKING_RATE_MAX, We as SPEAKING_RATE_MAX_STREAMING, Ge as SPEAKING_RATE_MAX_SYNC, Ke as SPEAKING_RATE_MIN, Ht as SPEECH_CHUNK_CHARS, Ut as SPEECH_CHUNK_CJK_CHARS, wt as SPEECH_LANG, hn as SPOKEN_LABEL_LANGUAGES, Or as STAGE_COPY, F as STOP_ASSISTANT_SANDBOX, kr as THINKING_PHRASES, ar as TURN_BODY_HEADROOM_BYTES, Tt as VOICE_LIST_TIMEOUT_MS, Wi as VoiceCaption, Gi as VoiceConversationView, qi as VoiceMiniController, Ji as VoiceStage, Yi as VoiceTranscriptDrawer, Ki as VoiceWaveform, I as WAIT_FOR_SANDBOX_RUNNING, q as abortAssistantTurn, si as activePanelOverlay, la as aiCreditsUpdatedEventName, Ci as applyPreviewEvent, J as approvePendingWrite, ci as assistantPanelOwnsEscape, _ as assistantRoutePath, c as assistantTranslationKey, v as assistantUrlTransform, Ur as availableAttachmentSources, qe as base64ToBytes, y as browserShouldHandle, Le as browserSpeechEngine, Y as buildAssistantSandboxEnv, or as buildAttachmentPromptBlock, It as buildContinuedFromVoiceNote, ve as buildProgress, sr as buildPromptParts, X as buildPromptRequestBody, cr as buildPromptWithAttachments, Je as buildRequest, E as buildSandboxContextInput, Lt as buildVoiceTranscriptMarkdown, Ae as chatTurns, Z as checkAssistantAiCredits, Wt as chunkForSpeech, b as classifyAssistantHref, lr as classifyAttachment, Ye as classifyHttpFailure, S as classifyQuotaError, Mn as columnLetterToIndex, tt as configureSpeechEngine, Gt as containsCjk, d as copyToClipboard, ur as countInlineImageCandidates, dr as countInlinedImageParts, wi as createAssistantPreviewSurface, Q as createAssistantSandbox, $ as createAssistantSession, $e as createHostedTtsEngine, Kr as createReadinessTracker, et as createRoutingSpeechEngine, Oi as createRunIdentityCache, Oe as createSandboxAssistantTransport, nt as createSpeechEngines, Ti as currentPreviewOwner, Xe as decodeAudioResponse, Nn as decodeXmlEntities, C as describeQuotaError, fr as detectDocumentFormat, _n as detectScriptLocale, Wr as deviceHasCamera, ua as dispatchAssistantQuotaExhausted, Pn as docxXmlToText, ee as downloadAssistantArtifact, Xi as downloadFile, li as escapeDismisses, pr as estimateTurnBodyBytes, D as executeSandboxGraphQL, Zi as exportConversation, te as extendAssistantSandboxTTL, pa as extractDocumentText, ln as findAssistantLanguage, ne as findExistingSandbox, pn as findPendingWrite, Fn as fitPdfPages, ui as focusIsInsidePanel, mr as formatBytes, In as formatPageRanges, zr as getActorId, re as getAssistantArtifacts, ye as getAssistantMedia, ie as getAssistantMessages, ae as getAssistantSession, oe as getAssistantStreamAccess, be as getAssistantText, hr as getAttachmentSendBlocker, U as getCapability, gr as getExtension, R as getImageForMode, z as getImageTagForMode, Br as getOrganizationId, xe as getRawMessageCreatedAt, B as getResourcesForMode, V as getSandboxImageRegistry, _r as getSendableAttachments, rt as getSpeechEngine, Se as getToolProgress, Vr as getWorkspaceId, je as groupBySession, Me as groupConsecutiveBySession, vr as hasAttachmentWorkInFlight, Be as hostedLocaleFor, Ve as hostedSupportsLanguage, p as imageHostLabel, _t as isCapturing, vt as isEcho, Ln as isMostlyImagePages, sa as isMultimodalBodyRejection, ga as isProdRuntime, w as isQuotaExhaustedError, Ce as isReapedSandboxConnectionError, qr as isRecentlyVerified, we as isRecoverable, ca as isRecoverableAssistantError, m as isRemoteImageSrc, yi as isRunningStatus, bn as isSpeakingMessage, Et as isSpeechBlocked, Ar as isStageCopy, yt as isSubmittable, wr as isTurnInFlight, W as isUnknownFieldError, Ne as isVoiceTurn, Rn as joinSheets, Dt as languageDisplayName, Te as mapSessionToHistory, G as markSupported, K as markUnsupported, Ee as mergeMessagesById, ot as micIsInterrupt, se as modeRequiresConfirmWrites, Li as nextModeIndex, di as nextPanelOverlays, bi as nextPreviewEvents, Ot as normalizeLangTag, da as notifyAiCreditsUpdated, bt as orbMode, zn as pageMarker, fi as panelOwnsEscape, mn as parseConfirmationRefusal, yr as parseDataUrl, Bn as parseSharedStrings, Fr as parseToolActivity, Vn as parseWorkbookSheets, Hn as pdfTextItemsToPage, Tr as planAbandonedTurn, xt as planReplyConsumption, Er as planTurnAbort, an as pollDelayMs, kt as primaryLanguageSubtag, xn as publishedChunks, T as quotaExhaustedEventName, it as readSpeechEngineConfig, ce as releaseSupersededAssistantSandboxes, dn as replyFollowsInput, le as reportAssistantAiTokenUsage, Sn as requiresCancel, at as resetSpeechEngine, un as resolveAssistantLanguage, fn as resolveLanguagePair, n as resolveModeConfig, H as resolveSandboxAssistantMode, vn as resolveSpeechLocale, Ei as runBelongsTo, ki as runIdentities, Di as sameOwner, De as sanitize, ue as selectExistingAssistantSandbox, de as selectSupersededAssistantSandboxes, At as selectVoiceForLocale, fe as sendAssistantPromptAsync, pe as sendHeartbeat, Un as sheetXmlToRows, Ze as shouldDisableEngine, Qt as showPreviousChunk, st as showsAssistantCaption, ct as showsUserCaption, Kt as speakableEmail, jt as speechGate, gn as speechLabelsFor, Mt as speechLangForLocale, Cn as speechPlaybackReducer, Qe as splitForVendor, qt as splitTableRow, St as spokenSoFar, jr as stageText, Mr as statusStageCopy, me as stopReapedAssistantSandbox, Wn as summarisePageText, Nr as thinkingPhrase, on as toCaptionText, br as toMessageAttachment, Jt as toSpeakableText, xr as truncateForInline, Gn as truncatePagesForInline, aa as useAssistantApiAccess, ma as useAssistantAttachments, ni as useAssistantConnectSource, _a as useAssistantHeartbeat, l as useAssistantI18nNamespace, va as useAssistantKeyboardShortcuts, x as useAssistantNavigate, r as useAssistantPageLabel, _i as useAssistantPreview, ji as useAssistantPreviewBridge, i as useAssistantProduct, a as useAssistantProductOrNull, Lr as useAssistantSpeech, o as useAssistantStorageFolders, Cr as useAssistantStore, u as useAssistantTr, oa as useConversationTurns, pi as useDropdownEscape, Ai as useOverlayFocus, ke as useSandboxAssistantTransport, e as useVoiceInput, Rr as useVoiceSession, fa as useWorkspaceWriteAccess, Sr as validateFile, Nt as voiceAvailability, Pe as voiceMarker, Xt as voicePreviewText, Pt as voiceQualityRank, Fe as voiceSessionIdOf, Ct as voiceSessionReducer, lt as voiceStageState, Rt as voiceTranscriptFilename, Ie as voiceTurnsOnly, Ft as voicesForLocale, he as waitForAssistantServiceReady, ge as waitForSandboxRunning, ut as waveformIsActive, dt as waveformIsSettled };
68
+ import { IDLE_ACTIVE_TAB as Ai, nextActiveTab as ji, pinActiveTab as Mi, shouldPinOnMove as Ni, shouldPinOnSelect as Pi, stepsFromToolActivity as Fi, tabForArrowKey as Ii } from "./shared/assistant/preview/entity/entityPreviewState.js";
69
+ import { AssistantStepRail as Li } from "./shared/assistant/preview/entity/AssistantStepRail.js";
70
+ import { AssistantEntityPreview as Ri } from "./shared/assistant/preview/entity/AssistantEntityPreview.js";
71
+ import { useOverlayFocus as zi } from "./shared/assistant/ui/useOverlayFocus.js";
72
+ import { useAssistantPreviewBridge as Bi } from "./shared/assistant/preview/useAssistantPreviewBridge.js";
73
+ import { AssistantPreviewOverlay as Vi } from "./shared/assistant/preview/AssistantPreviewOverlay.js";
74
+ import { AssistantLanguageSelector as Hi, FOLLOW_APP_LOCALE as Ui } from "./shared/assistant/ui/composer/AssistantLanguageSelector.js";
75
+ import { ASSISTANT_MODE_META as Wi, AssistantModeSelector as Gi, nextModeIndex as Ki } from "./shared/assistant/ui/composer/AssistantModeSelector.js";
76
+ import { AssistantVoiceButton as qi } from "./shared/assistant/ui/composer/AssistantVoiceButton.js";
77
+ import { AUTO_VOICE as Ji, AssistantVoiceSelector as Yi } from "./shared/assistant/ui/composer/AssistantVoiceSelector.js";
78
+ import { AssistantVoiceOrb as Xi } from "./shared/assistant/ui/voice/AssistantVoiceOrb.js";
79
+ import { AssistantVoiceSessionButton as Zi } from "./shared/assistant/ui/voice/AssistantVoiceSessionButton.js";
80
+ import { CAPTION_SCROLL_ATTR as Qi, VoiceCaption as $i } from "./shared/assistant/ui/voice/VoiceCaption.js";
81
+ import { VoiceConversationView as ea } from "./shared/assistant/ui/voice/VoiceConversationView.js";
82
+ import { VoiceWaveform as ta } from "./shared/assistant/ui/voice/VoiceWaveform.js";
83
+ import { VoiceMiniController as na } from "./shared/assistant/ui/voice/VoiceMiniController.js";
84
+ import { VoiceStage as ra } from "./shared/assistant/ui/voice/VoiceStage.js";
85
+ import { VoiceTranscriptDrawer as ia } from "./shared/assistant/ui/voice/VoiceTranscriptDrawer.js";
86
+ import { downloadFile as aa, exportConversation as oa } from "./shared/assistant/exportConversation.js";
87
+ import { AssistantMoreMenu as sa } from "./shared/assistant/ui/AssistantMoreMenu.js";
88
+ import { AssistantHeader as ca } from "./shared/assistant/ui/AssistantHeader.js";
89
+ import { AssistantConversationList as la } from "./shared/assistant/ui/AssistantConversationList.js";
90
+ import { AssistantEmptyState as ua } from "./shared/assistant/ui/AssistantEmptyState.js";
91
+ import { AssistantMessageItem as da } from "./shared/assistant/ui/AssistantMessageItem.js";
92
+ import { AssistantMessageList as fa } from "./shared/assistant/ui/AssistantMessageList.js";
93
+ import { AssistantVoiceSession as pa } from "./shared/assistant/ui/voice/AssistantVoiceSession.js";
94
+ import { useAssistantApiAccess as ma } from "./shared/assistant/useAssistantApiAccess.js";
95
+ import { useConversationTurns as ha } from "./shared/assistant/useConversationTurns.js";
96
+ import { isMultimodalBodyRejection as ga, isRecoverableAssistantError as _a } from "./shared/assistant/transportErrors.js";
97
+ import { aiCreditsUpdatedEventName as va, dispatchAssistantQuotaExhausted as ya, notifyAiCreditsUpdated as ba } from "./shared/assistant/aiCredits.js";
98
+ import { useWorkspaceWriteAccess as xa } from "./shared/assistant/useWorkspaceWriteAccess.js";
99
+ import { extractDocumentText as Sa } from "./shared/assistant/documentExtract.js";
100
+ import { useAssistantAttachments as Ca } from "./shared/assistant/useAssistantAttachments.js";
101
+ import { AssistantComposer as wa } from "./shared/assistant/ui/composer/AssistantComposer.js";
102
+ import { isProdRuntime as Ta } from "./shared/assistant/env.js";
103
+ import { useAssistantHeartbeat as Ea } from "./shared/assistant/useAssistantHeartbeat.js";
104
+ import { useAssistantKeyboardShortcuts as Da } from "./shared/assistant/useAssistantKeyboardShortcuts.js";
105
+ import { AssistantApiCallsConsentDialog as Oa } from "./shared/assistant/ui/AssistantApiCallsConsentDialog.js";
106
+ import { AssistantChatArea as ka } from "./shared/assistant/ui/AssistantChatArea.js";
107
+ import { AIAssistantPanel as Aa } from "./shared/assistant/ui/AIAssistantPanel.js";
108
+ export { Aa as AIAssistantPanel, L as ASSISTANT_API_AUTH_STRATEGY, sn as ASSISTANT_LANGUAGES, Wi as ASSISTANT_MODE_META, ii as ASSISTANT_OVERLAY_ATTR, ai as ASSISTANT_PANEL_ATTR, Kn as ATTACHMENT_ACCEPT, Hr as ATTACHMENT_SOURCES, Ji as AUTO_VOICE, Oa as AssistantApiCallsConsentDialog, mi as AssistantAttachmentButton, hi as AssistantAttachmentChips, Jr as AssistantAutoSpeakToggle, ka as AssistantChatArea, wa as AssistantComposer, ri as AssistantConnectSourceItem, ti as AssistantConnectSourceProvider, la as AssistantConversationList, ua as AssistantEmptyState, Ri as AssistantEntityPreview, ca as AssistantHeader, s as AssistantI18nProvider, Zr as AssistantLanguageMenu, Hi as AssistantLanguageSelector, f as AssistantMarkdownImage, h as AssistantMarkdownRenderer, Yr as AssistantMessageAttachments, da as AssistantMessageItem, fa as AssistantMessageList, Gi as AssistantModeSelector, sa as AssistantMoreMenu, g as AssistantNavigateProvider, Xr as AssistantPendingWriteCard, Vi as AssistantPreviewOverlay, gi as AssistantPreviewProvider, t as AssistantProductProvider, Qr as AssistantReplyLanguageSelector, _e as AssistantRuntimeManager, $r as AssistantSpeakButton, Ir as AssistantSpeechProvider, ei as AssistantSpokenTurnsNotice, Li as AssistantStepRail, Pr as AssistantToolActivity, qi as AssistantVoiceButton, Xi as AssistantVoiceOrb, Yi as AssistantVoiceSelector, pa as AssistantVoiceSession, Zi as AssistantVoiceSessionButton, qn as AttachmentRejectedError, En as BOILERPLATE_PAGE_SHARE, Qi as CAPTION_SCROLL_ATTR, O as CHECK_AI_CREDITS, k as CREATE_SANDBOX, zt as DEFAULT_SPEAKABLE_LABELS, cn as DEFAULT_SPEECH_RATE, ft as ENDPOINT_GRACE_MS, A as EXTEND_SANDBOX_TTL, Ui as FOLLOW_APP_LOCALE, j as GET_ACTIVE_SANDBOXES, M as GET_SANDBOX, He as HOSTED_TTS_MAX_CHARS, Re as HOSTED_TTS_TIER, ze as HOSTED_VOICES, Ai as IDLE_ACTIVE_TAB, yn as IDLE_PLAYBACK, xi as IDLE_PREVIEW, vi as IDLE_PREVIEW_STATE, pt as INITIAL_SESSION, Jn as INLINE_IMAGE_MAX_DIM, Yn as INLINE_IMAGE_QUALITY, mt as INTERRUPT_MAX_MS, ht as INTERRUPT_MIN_MS, Xn as MAX_ATTACHMENTS, Dn as MAX_BOILERPLATE_LINE_CHARS, On as MAX_EXTRACTED_CHARS, Zn as MAX_FILE_BYTES, Qn as MAX_INLINE_CHARS_PER_FILE, $n as MAX_INLINE_CHARS_TOTAL, wn as MAX_INLINE_IMAGE_BASE64_BYTES, er as MAX_INLINE_IMAGE_BASE64_CHARS, tr as MAX_INLINE_IMAGE_PARTS, nr as MAX_INLINE_TURN_BODY_BYTES, kn as MAX_PDF_PAGES_SCANNED, Tn as MAX_REQUEST_BODY_BYTES, Bt as MAX_SPEAKABLE_CHARS, Vt as MAX_SPOKEN_TABLE_ROWS, rr as MAX_TURN_BODY_BYTES, Zt as MINI_CAPTION_BUDGET, An as MIN_PAGE_TEXT_CHARS, jn as MIN_TEXT_PAGE_SHARE, Si as NO_OWNER, oi as NO_PANEL_OVERLAY, Dr as PHRASE_ROTATE_MS, $t as POLL_FAST_MS, en as POLL_FAST_UNTIL_MS, tn as POLL_SLOW_MS, nn as POLL_STEADY_MS, rn as POLL_STEADY_UNTIL_MS, Yt as PREVIEW_LANGUAGES, ir as PROMPT_ENVELOPE_RESERVE_BYTES, N as PROXY_SANDBOX_REQUEST, P as REPORT_AI_TOKEN_USAGE, Gr as SANDBOX_READY_TTL_MS, gt as SILENCE_SUBMIT_MS, Ue as SPEAKING_RATE_MAX, We as SPEAKING_RATE_MAX_STREAMING, Ge as SPEAKING_RATE_MAX_SYNC, Ke as SPEAKING_RATE_MIN, Ht as SPEECH_CHUNK_CHARS, Ut as SPEECH_CHUNK_CJK_CHARS, wt as SPEECH_LANG, hn as SPOKEN_LABEL_LANGUAGES, Or as STAGE_COPY, F as STOP_ASSISTANT_SANDBOX, kr as THINKING_PHRASES, ar as TURN_BODY_HEADROOM_BYTES, Tt as VOICE_LIST_TIMEOUT_MS, $i as VoiceCaption, ea as VoiceConversationView, na as VoiceMiniController, ra as VoiceStage, ia as VoiceTranscriptDrawer, ta as VoiceWaveform, I as WAIT_FOR_SANDBOX_RUNNING, q as abortAssistantTurn, si as activePanelOverlay, va as aiCreditsUpdatedEventName, Ci as applyPreviewEvent, J as approvePendingWrite, ci as assistantPanelOwnsEscape, _ as assistantRoutePath, c as assistantTranslationKey, v as assistantUrlTransform, Ur as availableAttachmentSources, qe as base64ToBytes, y as browserShouldHandle, Le as browserSpeechEngine, Y as buildAssistantSandboxEnv, or as buildAttachmentPromptBlock, It as buildContinuedFromVoiceNote, ve as buildProgress, sr as buildPromptParts, X as buildPromptRequestBody, cr as buildPromptWithAttachments, Je as buildRequest, E as buildSandboxContextInput, Lt as buildVoiceTranscriptMarkdown, Ae as chatTurns, Z as checkAssistantAiCredits, Wt as chunkForSpeech, b as classifyAssistantHref, lr as classifyAttachment, Ye as classifyHttpFailure, S as classifyQuotaError, Mn as columnLetterToIndex, tt as configureSpeechEngine, Gt as containsCjk, d as copyToClipboard, ur as countInlineImageCandidates, dr as countInlinedImageParts, wi as createAssistantPreviewSurface, Q as createAssistantSandbox, $ as createAssistantSession, $e as createHostedTtsEngine, Kr as createReadinessTracker, et as createRoutingSpeechEngine, Oi as createRunIdentityCache, Oe as createSandboxAssistantTransport, nt as createSpeechEngines, Ti as currentPreviewOwner, Xe as decodeAudioResponse, Nn as decodeXmlEntities, C as describeQuotaError, fr as detectDocumentFormat, _n as detectScriptLocale, Wr as deviceHasCamera, ya as dispatchAssistantQuotaExhausted, Pn as docxXmlToText, ee as downloadAssistantArtifact, aa as downloadFile, li as escapeDismisses, pr as estimateTurnBodyBytes, D as executeSandboxGraphQL, oa as exportConversation, te as extendAssistantSandboxTTL, Sa as extractDocumentText, ln as findAssistantLanguage, ne as findExistingSandbox, pn as findPendingWrite, Fn as fitPdfPages, ui as focusIsInsidePanel, mr as formatBytes, In as formatPageRanges, zr as getActorId, re as getAssistantArtifacts, ye as getAssistantMedia, ie as getAssistantMessages, ae as getAssistantSession, oe as getAssistantStreamAccess, be as getAssistantText, hr as getAttachmentSendBlocker, U as getCapability, gr as getExtension, R as getImageForMode, z as getImageTagForMode, Br as getOrganizationId, xe as getRawMessageCreatedAt, B as getResourcesForMode, V as getSandboxImageRegistry, _r as getSendableAttachments, rt as getSpeechEngine, Se as getToolProgress, Vr as getWorkspaceId, je as groupBySession, Me as groupConsecutiveBySession, vr as hasAttachmentWorkInFlight, Be as hostedLocaleFor, Ve as hostedSupportsLanguage, p as imageHostLabel, _t as isCapturing, vt as isEcho, Ln as isMostlyImagePages, ga as isMultimodalBodyRejection, Ta as isProdRuntime, w as isQuotaExhaustedError, Ce as isReapedSandboxConnectionError, qr as isRecentlyVerified, we as isRecoverable, _a as isRecoverableAssistantError, m as isRemoteImageSrc, yi as isRunningStatus, bn as isSpeakingMessage, Et as isSpeechBlocked, Ar as isStageCopy, yt as isSubmittable, wr as isTurnInFlight, W as isUnknownFieldError, Ne as isVoiceTurn, Rn as joinSheets, Dt as languageDisplayName, Te as mapSessionToHistory, G as markSupported, K as markUnsupported, Ee as mergeMessagesById, ot as micIsInterrupt, se as modeRequiresConfirmWrites, ji as nextActiveTab, Ki as nextModeIndex, di as nextPanelOverlays, bi as nextPreviewEvents, Ot as normalizeLangTag, ba as notifyAiCreditsUpdated, bt as orbMode, zn as pageMarker, fi as panelOwnsEscape, mn as parseConfirmationRefusal, yr as parseDataUrl, Bn as parseSharedStrings, Fr as parseToolActivity, Vn as parseWorkbookSheets, Hn as pdfTextItemsToPage, Mi as pinActiveTab, Tr as planAbandonedTurn, xt as planReplyConsumption, Er as planTurnAbort, an as pollDelayMs, kt as primaryLanguageSubtag, xn as publishedChunks, T as quotaExhaustedEventName, it as readSpeechEngineConfig, ce as releaseSupersededAssistantSandboxes, dn as replyFollowsInput, le as reportAssistantAiTokenUsage, Sn as requiresCancel, at as resetSpeechEngine, un as resolveAssistantLanguage, fn as resolveLanguagePair, n as resolveModeConfig, H as resolveSandboxAssistantMode, vn as resolveSpeechLocale, Ei as runBelongsTo, ki as runIdentities, Di as sameOwner, De as sanitize, ue as selectExistingAssistantSandbox, de as selectSupersededAssistantSandboxes, At as selectVoiceForLocale, fe as sendAssistantPromptAsync, pe as sendHeartbeat, Un as sheetXmlToRows, Ze as shouldDisableEngine, Ni as shouldPinOnMove, Pi as shouldPinOnSelect, Qt as showPreviousChunk, st as showsAssistantCaption, ct as showsUserCaption, Kt as speakableEmail, jt as speechGate, gn as speechLabelsFor, Mt as speechLangForLocale, Cn as speechPlaybackReducer, Qe as splitForVendor, qt as splitTableRow, St as spokenSoFar, jr as stageText, Mr as statusStageCopy, Fi as stepsFromToolActivity, me as stopReapedAssistantSandbox, Wn as summarisePageText, Ii as tabForArrowKey, Nr as thinkingPhrase, on as toCaptionText, br as toMessageAttachment, Jt as toSpeakableText, xr as truncateForInline, Gn as truncatePagesForInline, ma as useAssistantApiAccess, Ca as useAssistantAttachments, ni as useAssistantConnectSource, Ea as useAssistantHeartbeat, l as useAssistantI18nNamespace, Da as useAssistantKeyboardShortcuts, x as useAssistantNavigate, r as useAssistantPageLabel, _i as useAssistantPreview, Bi as useAssistantPreviewBridge, i as useAssistantProduct, a as useAssistantProductOrNull, Lr as useAssistantSpeech, o as useAssistantStorageFolders, Cr as useAssistantStore, u as useAssistantTr, ha as useConversationTurns, pi as useDropdownEscape, zi as useOverlayFocus, ke as useSandboxAssistantTransport, e as useVoiceInput, Rr as useVoiceSession, xa as useWorkspaceWriteAccess, Sr as validateFile, Nt as voiceAvailability, Pe as voiceMarker, Xt as voicePreviewText, Pt as voiceQualityRank, Fe as voiceSessionIdOf, Ct as voiceSessionReducer, lt as voiceStageState, Rt as voiceTranscriptFilename, Ie as voiceTurnsOnly, Ft as voicesForLocale, he as waitForAssistantServiceReady, ge as waitForSandboxRunning, ut as waveformIsActive, dt as waveformIsSettled };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burdenoff/fe-libs",
3
- "version": "2026.912.1",
3
+ "version": "2026.912.3",
4
4
  "description": "Burdenoff frontend primitives and domain libraries",
5
5
  "type": "module",
6
6
  "bin": {