@burdenoff/fe-libs 2026.913.2 → 2026.914.2

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.
Files changed (62) hide show
  1. package/dist/shared/assistant/conversation.d.ts +29 -0
  2. package/dist/shared/assistant/conversation.d.ts.map +1 -1
  3. package/dist/shared/assistant/displayContent.d.ts +57 -0
  4. package/dist/shared/assistant/displayContent.d.ts.map +1 -0
  5. package/dist/shared/assistant/displayContent.js +26 -0
  6. package/dist/shared/assistant/exportConversation.d.ts +12 -2
  7. package/dist/shared/assistant/exportConversation.d.ts.map +1 -1
  8. package/dist/shared/assistant/exportConversation.js +24 -22
  9. package/dist/shared/assistant/index.d.ts +7 -0
  10. package/dist/shared/assistant/index.d.ts.map +1 -1
  11. package/dist/shared/assistant/legacyFiller.d.ts +60 -0
  12. package/dist/shared/assistant/legacyFiller.d.ts.map +1 -0
  13. package/dist/shared/assistant/legacyFiller.js +35 -0
  14. package/dist/shared/assistant/preview/previewTransitions.d.ts +15 -1
  15. package/dist/shared/assistant/preview/previewTransitions.d.ts.map +1 -1
  16. package/dist/shared/assistant/preview/previewTransitions.js +5 -2
  17. package/dist/shared/assistant/preview/useAssistantPreviewBridge.d.ts.map +1 -1
  18. package/dist/shared/assistant/preview/useAssistantPreviewBridge.js +51 -52
  19. package/dist/shared/assistant/spokenTurns.d.ts +25 -0
  20. package/dist/shared/assistant/spokenTurns.d.ts.map +1 -0
  21. package/dist/shared/assistant/spokenTurns.js +12 -0
  22. package/dist/shared/assistant/stageCopy.d.ts +23 -34
  23. package/dist/shared/assistant/stageCopy.d.ts.map +1 -1
  24. package/dist/shared/assistant/stageCopy.js +7 -16
  25. package/dist/shared/assistant/store.d.ts +10 -2
  26. package/dist/shared/assistant/store.d.ts.map +1 -1
  27. package/dist/shared/assistant/store.js +16 -9
  28. package/dist/shared/assistant/turnActivity.d.ts +70 -0
  29. package/dist/shared/assistant/turnActivity.d.ts.map +1 -0
  30. package/dist/shared/assistant/turnActivity.js +41 -0
  31. package/dist/shared/assistant/turnProgress.d.ts +51 -0
  32. package/dist/shared/assistant/turnProgress.d.ts.map +1 -0
  33. package/dist/shared/assistant/turnProgress.js +27 -0
  34. package/dist/shared/assistant/ui/AssistantChatArea.d.ts.map +1 -1
  35. package/dist/shared/assistant/ui/AssistantChatArea.js +285 -302
  36. package/dist/shared/assistant/ui/AssistantConversationList.d.ts.map +1 -1
  37. package/dist/shared/assistant/ui/AssistantConversationList.js +81 -80
  38. package/dist/shared/assistant/ui/AssistantMessageItem.d.ts +12 -1
  39. package/dist/shared/assistant/ui/AssistantMessageItem.d.ts.map +1 -1
  40. package/dist/shared/assistant/ui/AssistantMessageItem.js +103 -83
  41. package/dist/shared/assistant/ui/AssistantMessageList.d.ts +7 -1
  42. package/dist/shared/assistant/ui/AssistantMessageList.d.ts.map +1 -1
  43. package/dist/shared/assistant/ui/AssistantMessageList.js +28 -26
  44. package/dist/shared/assistant/ui/AssistantMoreMenu.d.ts.map +1 -1
  45. package/dist/shared/assistant/ui/AssistantMoreMenu.js +23 -20
  46. package/dist/shared/assistant/ui/AssistantTurnActivity.d.ts +40 -0
  47. package/dist/shared/assistant/ui/AssistantTurnActivity.d.ts.map +1 -0
  48. package/dist/shared/assistant/ui/AssistantTurnActivity.js +33 -0
  49. package/dist/shared/assistant/ui/usePrefersReducedMotion.d.ts +55 -0
  50. package/dist/shared/assistant/ui/usePrefersReducedMotion.d.ts.map +1 -0
  51. package/dist/shared/assistant/ui/usePrefersReducedMotion.js +28 -0
  52. package/dist/shared/assistant/ui/voice/VoiceMiniController.d.ts +4 -2
  53. package/dist/shared/assistant/ui/voice/VoiceMiniController.d.ts.map +1 -1
  54. package/dist/shared/assistant/ui/voice/VoiceStage.d.ts +4 -2
  55. package/dist/shared/assistant/ui/voice/VoiceStage.d.ts.map +1 -1
  56. package/dist/shared/assistant/ui/voice/VoiceStatusText.d.ts +12 -1
  57. package/dist/shared/assistant/ui/voice/VoiceStatusText.d.ts.map +1 -1
  58. package/dist/shared/assistant/ui/voice/VoiceStatusText.js +19 -18
  59. package/dist/shared/assistant/voice/voiceStatus.d.ts +8 -2
  60. package/dist/shared/assistant/voice/voiceStatus.d.ts.map +1 -1
  61. package/dist/shared-assistant.js +74 -67
  62. package/package.json +1 -1
@@ -5,20 +5,21 @@ import { useAssistantProduct as n } from "../product.js";
5
5
  import { useAssistantTr as r } from "../i18n.js";
6
6
  import { describeQuotaError as i } from "../quota.js";
7
7
  import { abortAssistantTurn as a, approvePendingWrite as o, createAssistantSandbox as s, createAssistantSession as c, extendAssistantSandboxTTL as l, findExistingSandbox as u, getAssistantArtifacts as ee, getAssistantMessages as te, getAssistantSession as d, releaseSupersededAssistantSandboxes as f, sendAssistantPromptAsync as ne, waitForAssistantServiceReady as p, waitForSandboxRunning as m } from "../api.js";
8
- import { getAssistantMedia as h, sanitize as re } from "../progress.js";
9
- import { streamBudgetMs as ie, withIncompleteTurnNotice as ae } from "../streamBudget.js";
10
- import { isVoiceTurn as g, voiceMarker as _, voiceSessionIdOf as v } from "../voice/turnVisibility.js";
11
- import { STAGE_COPY as y, isStageCopy as oe, stageText as b, statusStageCopy as se, thinkingPhrase as ce } from "../stageCopy.js";
12
- import { buildContinuedFromVoiceNote as x, buildVoiceTranscriptMarkdown as le, voiceTranscriptFilename as ue } from "../voice/voiceTranscript.js";
13
- import { pollDelayMs as de } from "../voice/assistantPollSchedule.js";
14
- import { toCaptionText as fe } from "../voice/captionText.js";
15
- import { resolveAssistantLanguage as pe } from "../voice/languages.js";
16
- import { resolveLanguagePair as me } from "../voice/languagePair.js";
17
- import { findPendingWrite as he } from "../pendingWrite.js";
18
- import { buildPromptParts as ge, buildPromptWithAttachments as _e, countInlineImageCandidates as ve, countInlinedImageParts as ye, getSendableAttachments as be, toMessageAttachment as xe } from "../attachments.js";
19
- import { useAssistantStore as S } from "../store.js";
20
- import { isTurnInFlight as Se, planAbandonedTurn as Ce, planTurnAbort as we } from "../turnState.js";
21
- import { parseToolActivity as Te } from "./AssistantToolActivity.js";
8
+ import { getRawMessageCreatedAt as re, sanitize as ie } from "../progress.js";
9
+ import { streamBudgetMs as ae, withIncompleteTurnNotice as oe } from "../streamBudget.js";
10
+ import { isVoiceTurn as se, voiceMarker as h, voiceSessionIdOf as g } from "../voice/turnVisibility.js";
11
+ import { buildContinuedFromVoiceNote as _, buildVoiceTranscriptMarkdown as ce, voiceTranscriptFilename as v } from "../voice/voiceTranscript.js";
12
+ import { pollDelayMs as le } from "../voice/assistantPollSchedule.js";
13
+ import { toCaptionText as ue } from "../voice/captionText.js";
14
+ import { resolveAssistantLanguage as de } from "../voice/languages.js";
15
+ import { resolveLanguagePair as fe } from "../voice/languagePair.js";
16
+ import { buildPromptParts as pe, buildPromptWithAttachments as me, countInlineImageCandidates as he, countInlinedImageParts as ge, getSendableAttachments as _e, toMessageAttachment as ve } from "../attachments.js";
17
+ import { useAssistantStore as y } from "../store.js";
18
+ import { isTurnInFlight as b, planAbandonedTurn as ye, planTurnAbort as be } from "../turnState.js";
19
+ import { getAssistantDisplayContent as xe } from "../displayContent.js";
20
+ import { buildAssistantProgress as Se } from "../turnProgress.js";
21
+ import { parseToolActivity as Ce } from "./AssistantToolActivity.js";
22
+ import { countSpokenTurns as we, spokenTurnText as Te } from "../spokenTurns.js";
22
23
  import { useVoiceSession as Ee } from "./useVoiceSession.js";
23
24
  import { getOrganizationId as De, getWorkspaceId as Oe } from "../context.js";
24
25
  import { createReadinessTracker as ke } from "../sandboxReadiness.js";
@@ -36,109 +37,72 @@ import { useAssistantAttachments as He } from "../useAssistantAttachments.js";
36
37
  import { AssistantComposer as Ue } from "./composer/AssistantComposer.js";
37
38
  import { isProdRuntime as We } from "../env.js";
38
39
  import { AssistantApiCallsConsentDialog as Ge } from "./AssistantApiCallsConsentDialog.js";
39
- import { useCallback as C, useEffect as w, useMemo as T, useRef as E, useState as Ke } from "react";
40
- import { jsx as D, jsxs as qe } from "react/jsx-runtime";
40
+ import { useCallback as x, useEffect as S, useMemo as C, useRef as w, useState as Ke } from "react";
41
+ import { jsx as T, jsxs as qe } from "react/jsx-runtime";
41
42
  //#region src/shared/assistant/ui/AssistantChatArea.tsx
42
43
  var Je = 600, Ye = 2e4;
43
44
  function Xe() {
44
45
  return `${Date.now()}-${Math.random().toString(36).slice(2, 9)}`;
45
46
  }
46
- function Ze(e) {
47
- return e.info?.time?.created ?? 0;
48
- }
49
- function O(e) {
50
- return (e ?? []).filter((e) => e.type === "text" && typeof e.text == "string").map((e) => e.text?.trim() ?? "").filter(Boolean).join("\n");
51
- }
52
- function k(e) {
53
- return (e ?? []).filter((e) => e.type === "tool" && e.tool).map((e) => {
54
- let t = e.state?.status ?? "running", n = e.tool ?? "tool";
55
- return t === "completed" ? `Completed: ${n}` : t === "failed" ? `Failed: ${n}` : `Running: ${n}`;
56
- });
57
- }
58
- function Qe(e, t) {
59
- let n = e.filter((e) => e.info?.role === "assistant" && Ze(e) > t).sort((e, t) => Ze(e) - Ze(t));
60
- if (n.length === 0) return {
61
- content: y.thinking.fallback,
62
- done: !1
63
- };
64
- let r = n[n.length - 1], i = O(r.parts), a = h(r.parts), o = k(r.parts), s = he(r.parts), c = [
65
- i,
66
- ...a,
67
- ...o
68
- ].filter(Boolean).join("\n\n") || y.thinking.fallback, l = r.info?.providerID, u = r.info?.modelID;
69
- return {
70
- content: c,
71
- done: !!r.info?.time?.completed && (!!i || a.length > 0 || o.length > 0),
72
- tokens: r.info?.tokens,
73
- messageId: r.info?.id,
74
- ...l && u ? { model: `${l}/${u}` } : {},
75
- ...s ? { pendingWrite: s } : {}
76
- };
77
- }
78
- var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
79
- let O = r(), { product: k, modes: A, gatherPageContext: $e, buildPrompt: et, reportTokenUsage: tt } = n(), { getAccessToken: j, getWorkspaceToken: M, userId: N } = t(), { locale: nt } = e(), rt = S((e) => e.assistantLanguage), it = S((e) => e.replyLanguage), at = T(() => me(rt, it, nt), [
47
+ var Ze = ({ visible: Ze = !0, writeAccess: Qe = "unknown" }) => {
48
+ let E = r(), { product: D, modes: O, gatherPageContext: $e, buildPrompt: et, reportTokenUsage: tt } = n(), { getAccessToken: k, getWorkspaceToken: A, userId: j } = t(), { locale: nt } = e(), rt = y((e) => e.assistantLanguage), it = y((e) => e.replyLanguage), at = C(() => fe(rt, it, nt), [
80
49
  rt,
81
50
  it,
82
51
  nt
83
- ]), ot = at.reply.english, st = at.replyIsExplicit, ct = at.reply.code, { conversations: lt, activeConversationId: P, mode: F, processingByConversationId: ut, setMode: I, setConversationMode: dt, setActiveConversation: ft, createConversation: L, addMessage: R, updateMessage: z, patchMessage: B, mergeMessageMetadata: pt, setConversationProcessing: V, clearConversationProcessing: mt, setBackendSessionId: ht, clearBackendSessionId: gt, setSandbox: H, clearSandbox: _t, acknowledgeApiCalls: vt } = S(), yt = lt.find((e) => e.id === P), U = Le(yt), bt = U.all, xt = P ? ut[P] : void 0, St = Se(xt?.status), Ct = St ? xt?.messageId ?? null : null, wt = xt?.status === "error" ? xt.messageId : null, { canUseApiCalls: Tt, loading: Et } = Ie(De()), Dt = T(() => A.filter((e) => !e.requiresAdmin || Tt), [A, Tt]), [Ot, kt] = Ke(null), [At, jt] = Ke(!1), Mt = E({}), Nt = E(ke()), Pt = E(/* @__PURE__ */ new Set()), Ft = T(() => A.find((e) => e.id === F), [A, F]);
84
- w(() => {
85
- Et || (!Ft || Ft.requiresAdmin && !Tt) && F !== "assistant" && I("assistant");
52
+ ]), ot = at.reply.english, st = at.replyIsExplicit, ct = at.reply.code, { conversations: lt, activeConversationId: M, mode: N, processingByConversationId: ut, setMode: dt, setConversationMode: ft, setActiveConversation: pt, createConversation: P, addMessage: F, updateMessage: mt, patchMessage: I, mergeMessageMetadata: ht, setConversationProcessing: L, clearConversationProcessing: gt, setBackendSessionId: _t, clearBackendSessionId: vt, setSandbox: R, clearSandbox: yt, acknowledgeApiCalls: bt } = y(), xt = lt.find((e) => e.id === M), z = Le(xt), St = z.all, B = M ? ut[M] : void 0, Ct = b(B?.status), wt = Ct ? B?.messageId ?? null : null, Tt = B?.status === "error" ? B.messageId : null, { canUseApiCalls: Et, loading: Dt } = Ie(De()), Ot = C(() => O.filter((e) => !e.requiresAdmin || Et), [O, Et]), [kt, At] = Ke(null), [jt, V] = Ke(!1), Mt = w({}), H = w(ke()), Nt = w(/* @__PURE__ */ new Set()), U = C(() => O.find((e) => e.id === N), [O, N]);
53
+ S(() => {
54
+ Dt || (!U || U.requiresAdmin && !Et) && N !== "assistant" && dt("assistant");
86
55
  }, [
87
- F,
88
- Ft,
89
- Tt,
56
+ N,
57
+ U,
90
58
  Et,
91
- I
59
+ Dt,
60
+ dt
92
61
  ]);
93
- let W = C((e, t, n, r) => {
94
- V(e, n, t, null), r ? z(e, t, r) : z(e, t, se(O, n));
95
- }, [
96
- V,
97
- z,
98
- O
99
- ]), It = C(async (e, t, n, r, i) => {
100
- let a = S.getState().sandboxesByMode[n]?.sandboxId ?? null, o = async (e) => {
101
- if (Nt.current.isFresh(e)) return !0;
62
+ let W = x((e, t, n, r) => {
63
+ L(e, n, t, null, r);
64
+ }, [L]), Pt = x(async (e, t, n, r, i) => {
65
+ let a = y.getState().sandboxesByMode[n]?.sandboxId ?? null, o = async (e) => {
66
+ if (H.current.isFresh(e)) return !0;
102
67
  try {
103
- return await m(e, r, i, 3e5), await p(e, r, i, 9e4), Nt.current.markVerified(e), !0;
68
+ return await m(e, r, i, 3e5), await p(e, r, i, 9e4), H.current.markVerified(e), !0;
104
69
  } catch {
105
- return Nt.current.invalidate(e), !1;
70
+ return H.current.invalidate(e), !1;
106
71
  }
107
72
  };
108
- if (a && (H(n, a, "provisioning"), W(e, t, "provisioning", b(O, y.reusingEnvironment)), await o(a) || (H(n, null, "provisioning"), a = null)), !a) {
109
- W(e, t, "provisioning", b(O, y.lookingForEnvironment));
110
- let s = await u(r, k, n, We(), i);
111
- s && (H(n, s, "provisioning"), W(e, t, "provisioning", b(O, y.reusingEnvironment)), await o(s) ? a = s : H(n, null, "provisioning"));
73
+ if (a && (R(n, a, "provisioning"), W(e, t, "provisioning", "reusingEnvironment"), await o(a) || (R(n, null, "provisioning"), a = null)), !a) {
74
+ W(e, t, "provisioning", "lookingForEnvironment");
75
+ let s = await u(r, D, n, We(), i);
76
+ s && (R(n, s, "provisioning"), W(e, t, "provisioning", "reusingEnvironment"), await o(s) ? a = s : R(n, null, "provisioning"));
112
77
  }
113
78
  if (!a) {
114
- if (n === "api-calls" && !j()) throw Error("API Calls mode requires an authenticated session. Please sign in again.");
115
- W(e, t, "provisioning", b(O, y.startingEnvironment)), H(n, null, "provisioning"), await f(r, k, n, We(), i), a = await s(k, n, r, We(), Je, i), H(n, a, "provisioning"), await m(a, r, i, 3e5), await p(a, r, i, 9e4);
79
+ if (n === "api-calls" && !k()) throw Error("API Calls mode requires an authenticated session. Please sign in again.");
80
+ W(e, t, "provisioning", "startingEnvironment"), R(n, null, "provisioning"), await f(r, D, n, We(), i), a = await s(D, n, r, We(), Je, i), R(n, a, "provisioning"), await m(a, r, i, 3e5), await p(a, r, i, 9e4);
116
81
  }
117
- H(n, a, "running");
118
- let l = S.getState().conversations.find((t) => t.id === e)?.backendSessionId ?? null;
82
+ R(n, a, "running");
83
+ let l = y.getState().conversations.find((t) => t.id === e)?.backendSessionId ?? null;
119
84
  if (l) try {
120
85
  let e = await d(a, r, l, i);
121
86
  if (e.mode !== n) throw Error(`Session mode mismatch: expected ${n}, received ${e.mode}`);
122
87
  } catch {
123
- gt(e), l = null;
88
+ vt(e), l = null;
124
89
  }
125
- return l || (W(e, t, "connecting", b(O, y.preparingSession)), l = (await c(a, r, n, i)).sessionId, ht(e, l)), {
90
+ return l || (W(e, t, "connecting", "preparingSession"), l = (await c(a, r, n, i)).sessionId, _t(e, l)), {
126
91
  sandboxId: a,
127
92
  sessionId: l
128
93
  };
129
94
  }, [
130
- gt,
131
- j,
95
+ vt,
132
96
  k,
133
- ht,
134
- H,
135
- O,
97
+ D,
98
+ _t,
99
+ R,
136
100
  W
137
- ]), [Lt, Rt] = Ke(null), G = E(/* @__PURE__ */ new Set()), zt = E(null), Bt = C(() => {
138
- let e = S.getState(), t = e.activeConversationId;
101
+ ]), [Ft, It] = Ke(null), G = w(/* @__PURE__ */ new Set()), Lt = w(null), Rt = x(() => {
102
+ let e = y.getState(), t = e.activeConversationId;
139
103
  if (!t) return;
140
- let n = e.processingByConversationId[t], r = Se(n?.status) ? n?.messageId ?? null : null;
141
- if (!we({
104
+ let n = e.processingByConversationId[t], r = b(n?.status) ? n?.messageId ?? null : null;
105
+ if (!be({
142
106
  interruptedTurnId: r,
143
107
  activeTurnId: r,
144
108
  alreadyRequested: r ? G.current.has(r) : !1
@@ -146,28 +110,28 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
146
110
  G.current.add(r);
147
111
  let i = e.sandboxesByMode[e.mode]?.sandboxId, o = Oe(), s = e.conversations.find((e) => e.id === t)?.backendSessionId;
148
112
  !i || !o || !s || a(i, o, s, {
149
- accessToken: j(),
150
- workspaceToken: M(),
151
- userId: N,
113
+ accessToken: k(),
114
+ workspaceToken: A(),
115
+ userId: j,
152
116
  organizationId: De()
153
117
  });
154
118
  }, [
155
- N,
156
119
  j,
157
- M
158
- ]), Vt = C(async (e) => {
159
- let t = S.getState(), n = t.sandboxesByMode[t.mode]?.sandboxId, r = Oe(), i = t.activeConversationId;
120
+ k,
121
+ A
122
+ ]), zt = x(async (e) => {
123
+ let t = y.getState(), n = t.sandboxesByMode[t.mode]?.sandboxId, r = Oe(), i = t.activeConversationId;
160
124
  if (!(!n || !r || !i)) {
161
- Rt(e);
125
+ It(e);
162
126
  try {
163
127
  await o(n, r, e, {
164
- accessToken: j(),
165
- workspaceToken: M(),
166
- userId: N,
128
+ accessToken: k(),
129
+ workspaceToken: A(),
130
+ userId: j,
167
131
  organizationId: De()
168
132
  });
169
133
  } catch (e) {
170
- Rt(null), R(i, {
134
+ It(null), F(i, {
171
135
  id: Xe(),
172
136
  role: "system",
173
137
  content: e instanceof Error ? e.message : "The change could not be approved.",
@@ -175,18 +139,18 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
175
139
  });
176
140
  return;
177
141
  }
178
- Rt(null), q.current(O("pendingWrite.approvedPrompt", "I approved that change — go ahead."));
142
+ It(null), q.current(E("pendingWrite.approvedPrompt", "I approved that change — go ahead."));
179
143
  }
180
144
  }, [
181
- N,
182
- R,
183
- O
184
- ]), K = C(async (e, t = [], n = {}) => {
185
- let r = n.voiceSessionId !== void 0, a = S.getState(), o = a.activeConversationId ?? P;
145
+ j,
146
+ F,
147
+ E
148
+ ]), K = x(async (e, t = [], n = {}) => {
149
+ let r = n.voiceSessionId !== void 0, a = y.getState(), o = a.activeConversationId ?? M;
186
150
  if (o) {
187
- if (Se(a.processingByConversationId[o]?.status)) {
151
+ if (b(a.processingByConversationId[o]?.status)) {
188
152
  let r = a.processingByConversationId[o]?.messageId ?? null;
189
- r && G.current.has(r) && (zt.current = {
153
+ r && G.current.has(r) && (Lt.current = {
190
154
  conversationId: o,
191
155
  content: e,
192
156
  attachments: t,
@@ -194,15 +158,15 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
194
158
  });
195
159
  return;
196
160
  }
197
- if (Pt.current.has(o)) return;
161
+ if (Nt.current.has(o)) return;
198
162
  }
199
- let s = a.mode, c = P, u = c ? S.getState().conversations.find((e) => e.id === c) : void 0;
200
- if (c ? u && u.mode !== s && (u.messages.length > 0 || u.backendSessionId) ? c = L(void 0, s) : u && u.mode !== s && dt(c, s) : c = L(void 0, s), !c) return;
163
+ let s = a.mode, c = M, u = c ? y.getState().conversations.find((e) => e.id === c) : void 0;
164
+ if (c ? u && u.mode !== s && (u.messages.length > 0 || u.backendSessionId) ? c = P(void 0, s) : u && u.mode !== s && ft(c, s) : c = P(void 0, s), !c) return;
201
165
  Mt.current[c] = t;
202
166
  let d = Oe(), f = {
203
- accessToken: j(),
204
- workspaceToken: M(),
205
- userId: N,
167
+ accessToken: k(),
168
+ workspaceToken: A(),
169
+ userId: j,
206
170
  organizationId: De()
207
171
  }, p = {
208
172
  id: Xe(),
@@ -210,195 +174,212 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
210
174
  content: e,
211
175
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
212
176
  metadata: {
213
- ...t.length ? { attachments: t.map(xe) } : {},
214
- ..._(n.voiceSessionId)
177
+ ...t.length ? { attachments: t.map(ve) } : {},
178
+ ...h(n.voiceSessionId)
215
179
  }
216
180
  };
217
- R(c, p);
181
+ F(c, p);
218
182
  let m = Xe();
219
- R(c, {
183
+ F(c, {
220
184
  id: m,
221
185
  role: "assistant",
222
186
  content: "",
223
187
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
224
188
  metadata: {
225
189
  lang: ct,
226
- ..._(n.voiceSessionId)
190
+ ...h(n.voiceSessionId)
227
191
  }
228
- }), V(c, "provisioning", m, null);
229
- let h = (e, t, r, i, a = ct) => {
230
- B(c, m, { content: re(e) }), pt(c, m, {
192
+ }), L(c, "provisioning", m, null);
193
+ let se = (e, t, r, i, a = ct) => {
194
+ I(c, m, { content: ie(e) }), ht(c, m, {
231
195
  lang: a,
232
196
  ...t?.length ? { artifacts: t } : {},
233
197
  ...t?.length || r || i ? { mode: s } : {},
234
198
  ...r ? { sessionId: r } : {},
235
199
  ...i ? { sandboxId: i } : {},
236
- ..._(n.voiceSessionId)
200
+ ...h(n.voiceSessionId)
237
201
  });
238
202
  }, g = async (n = 1) => {
239
203
  let i = !1;
240
204
  try {
241
- let { sandboxId: n, sessionId: a } = await It(c, m, s, d, f), o = (await te(n, d, a, f, { limit: 50 }).catch(() => [])).reduce((e, t) => Math.max(e, Ze(t)), 0);
242
- W(c, m, "streaming", b(O, y.thinking));
243
- let u = _e(e, t), p = et?.(s, u, ot, st, r) ?? u, g = ge(p, t), _ = ye(g), v = _ > 0, se = $e?.();
244
- i = ve(t) > _;
205
+ let { sandboxId: n, sessionId: a } = await Pt(c, m, s, d, f), o = (await te(n, d, a, f, { limit: 50 }).catch(() => [])).reduce((e, t) => Math.max(e, re(t)), 0);
206
+ W(c, m, "streaming", "thinking");
207
+ let u = me(e, t), p = et?.(s, u, ot, st, r) ?? u, h = pe(p, t), g = ge(h), _ = g > 0, ce = $e?.();
208
+ i = he(t) > g;
245
209
  try {
246
- await ne(n, d, a, p, s, se, f, g?.length ? { parts: g } : void 0);
210
+ await ne(n, d, a, p, s, ce, f, h?.length ? { parts: h } : void 0);
247
211
  } catch (e) {
248
- if (!g || !Re(e)) throw e;
249
- await ne(n, d, a, p, s, se, f, void 0), i ||= v;
212
+ if (!h || !Re(e)) throw e;
213
+ await ne(n, d, a, p, s, ce, f, void 0), i ||= _;
250
214
  }
251
- let x = Qe([], o), le = Date.now() + ie(s), ue = Date.now(), fe = Date.now(), pe = () => Ce({
215
+ let v = Se([], o), ue = Date.now() + ae(s), de = Date.now(), fe = Date.now(), _e = () => ye({
252
216
  turnId: m,
253
217
  abortRequested: G.current.has(m),
254
- activeTurnId: S.getState().processingByConversationId[c]?.messageId ?? null
255
- }), me = () => {
256
- let e = S.getState().conversations.find((e) => e.id === c)?.messages.find((e) => e.id === m)?.content;
257
- oe(O, e) && z(c, m, b(O, y.stopped));
258
- };
259
- for (; Date.now() < le;) {
260
- let e = pe();
218
+ activeTurnId: y.getState().processingByConversationId[c]?.messageId ?? null
219
+ });
220
+ for (; Date.now() < ue;) {
221
+ let e = _e();
261
222
  if (e.abandon) {
262
- me(), e.clearProcessing && mt(c);
223
+ e.clearProcessing && gt(c);
263
224
  return;
264
225
  }
265
- if (x = Qe(await te(n, d, a, f, {
226
+ if (v = Se(await te(n, d, a, f, {
266
227
  limit: 50,
267
228
  sinceMs: o
268
- }), o), B(c, m, { content: oe(O, x.content) ? ce(O, Date.now() - fe) : re(x.content) }), x.pendingWrite && pt(c, m, { pendingWrite: x.pendingWrite }), x.done) break;
269
- Date.now() - ue > 3e4 && (await l(n, d, 600, f).catch(() => void 0), ue = Date.now()), await new Promise((e) => setTimeout(e, de(Date.now() - fe)));
229
+ }), o), I(c, m, { content: ie(v.content) }), v.pendingWrite && ht(c, m, { pendingWrite: v.pendingWrite }), v.done) break;
230
+ Date.now() - de > 3e4 && (await l(n, d, 600, f).catch(() => void 0), de = Date.now()), await new Promise((e) => setTimeout(e, le(Date.now() - fe)));
270
231
  }
271
- let he = s === "vibe-plugins" ? await ee(n, d, a, f).then((e) => e).catch(() => []) : void 0;
272
- if (x.done || (x = {
273
- ...x,
274
- content: ae(x.content, s, O)
275
- }), i && (x = {
276
- ...x,
277
- content: `${x.content}\n\n${O("attachments.imagesNotSent", "_Your photo was too large to include with this message, so the answer above is from the text and the file link only. Try a smaller or more tightly cropped photo._")}`
278
- }), h(x.content, he, a, n), x.tokens) {
279
- B(c, m, { tokens: x.tokens });
232
+ let ve = s === "vibe-plugins" ? await ee(n, d, a, f).then((e) => e).catch(() => []) : void 0;
233
+ if (v.done || (v = {
234
+ ...v,
235
+ content: oe(v.content, s, E)
236
+ }), i && (v = {
237
+ ...v,
238
+ content: `${v.content}\n\n${E("attachments.imagesNotSent", "_Your photo was too large to include with this message, so the answer above is from the text and the file link only. Try a smaller or more tightly cropped photo._")}`
239
+ }), se(v.content, ve, a, n), v.tokens) {
240
+ I(c, m, { tokens: v.tokens });
280
241
  try {
281
242
  await tt?.({
282
243
  workspaceId: d,
283
244
  sessionId: a,
284
- messageId: x.messageId,
285
- model: x.model,
286
- tokens: x.tokens
287
- }), Ve(k);
245
+ messageId: v.messageId,
246
+ model: v.model,
247
+ tokens: v.tokens
248
+ }), Ve(D);
288
249
  } catch {}
289
250
  }
290
- let be = pe();
291
- if (be.abandon) {
292
- me(), be.clearProcessing && mt(c);
251
+ let b = _e();
252
+ if (b.abandon) {
253
+ b.clearProcessing && gt(c);
293
254
  return;
294
255
  }
295
- V(c, "complete", m, null);
256
+ L(c, "complete", m, null);
296
257
  } catch (e) {
297
- if (n === 1 && ze(e)) return gt(c), _t(s), g(2);
258
+ let t = ye({
259
+ turnId: m,
260
+ abortRequested: G.current.has(m),
261
+ activeTurnId: y.getState().processingByConversationId[c]?.messageId ?? null
262
+ });
263
+ if (t.abandon) {
264
+ t.clearProcessing && gt(c);
265
+ return;
266
+ }
267
+ if (n === 1 && ze(e)) return vt(c), yt(s), mt(c, m, ""), ht(c, m, { pendingWrite: void 0 }), g(2);
298
268
  throw e;
299
269
  }
300
- }, v = c;
301
- Pt.current.add(v);
270
+ }, _ = c;
271
+ Nt.current.add(_);
302
272
  try {
303
273
  if (!d) throw Error("Assistant backend is unavailable without an active workspace context.");
304
274
  await g();
305
275
  } catch (e) {
306
- Nt.current.invalidate(S.getState().sandboxesByMode[s]?.sandboxId ?? null);
276
+ H.current.invalidate(y.getState().sandboxesByMode[s]?.sandboxId ?? null);
307
277
  let t = i(e);
308
278
  if (t) {
309
- t.refusal === "exhausted" && Be(k, "sandbox");
279
+ t.refusal === "exhausted" && Be(D, "sandbox");
310
280
  let e = [t.quotaName, t.traceId ? `reference ${t.traceId}` : null].filter(Boolean).join(" · "), n = t.refusal === "exhausted" ? "You've reached your sandbox limit on the current plan. Upgrade to start the AI assistant." : "This workspace has no sandbox allowance provisioned, so the AI assistant cannot start. Upgrading will not help — ask an administrator to provision it.";
311
- h(e ? `${n}\n\n${e}` : n, void 0, void 0, void 0, "en"), V(c, "error", m, null);
281
+ se(e ? `${n}\n\n${e}` : n, void 0, void 0, void 0, "en"), L(c, "error", m, null);
312
282
  return;
313
283
  }
314
284
  let r = e instanceof Error ? e.message : "Something went wrong";
315
- V(c, "error", m, r), B(c, m, { content: `Sorry, an error occurred: ${r}. Please try again.` }), pt(c, m, {
285
+ L(c, "error", m, r), I(c, m, { content: `Sorry, an error occurred: ${r}. Please try again.` }), ht(c, m, {
316
286
  lang: "en",
317
- ..._(n.voiceSessionId)
287
+ ...h(n.voiceSessionId)
318
288
  });
319
289
  } finally {
320
- Pt.current.delete(v);
321
- let e = zt.current;
322
- zt.current = null, e && e.conversationId === v && q.current(e.content, e.attachments, e.options);
290
+ Nt.current.delete(_);
291
+ let e = Lt.current;
292
+ Lt.current = null, e && e.conversationId === _ && q.current(e.content, e.attachments, e.options);
323
293
  }
324
294
  }, [
325
- P,
326
- R,
295
+ M,
296
+ F,
327
297
  et,
328
- gt,
329
- _t,
298
+ vt,
299
+ yt,
330
300
  lt,
331
- L,
332
- It,
301
+ P,
302
+ Pt,
333
303
  $e,
334
- j,
335
- M,
336
- B,
337
304
  k,
305
+ A,
306
+ I,
307
+ D,
338
308
  tt,
339
309
  st,
340
310
  ct,
341
311
  ot,
342
- ht,
343
- dt,
344
- V,
345
- mt,
346
- O,
312
+ _t,
313
+ ft,
314
+ L,
315
+ gt,
316
+ E,
347
317
  W,
348
- z,
349
- N
350
- ]), Ht = C((e) => {
318
+ mt,
319
+ j
320
+ ]), Bt = x((e) => {
351
321
  K(e);
352
- }, [K]), Ut = C(() => {
353
- let e = [...U.chat].reverse().find((e) => e.role === "user"), t = P ? Mt.current[P] ?? [] : [];
322
+ }, [K]), Vt = x(() => {
323
+ let e = [...z.chat].reverse().find((e) => e.role === "user"), t = M ? Mt.current[M] ?? [] : [];
354
324
  e && K(e.content, t);
355
325
  }, [
356
- bt,
326
+ St,
357
327
  K,
358
- P
359
- ]), q = E(K);
360
- w(() => {
328
+ M
329
+ ]), q = w(K);
330
+ S(() => {
361
331
  q.current = K;
362
332
  }, [K]);
363
- let J = T(() => {
364
- if (St) return null;
365
- for (let e = bt.length - 1; e >= 0; --e) {
366
- let t = bt[e];
367
- if (t?.role !== "assistant" || !g(t) || G.current.has(t.id)) continue;
368
- let n = Te(t.content).text.trim();
369
- return n ? {
333
+ let J = C(() => {
334
+ if (Ct) return null;
335
+ for (let e = St.length - 1; e >= 0; --e) {
336
+ let t = St[e];
337
+ if (t?.role !== "assistant" || !se(t) || G.current.has(t.id)) continue;
338
+ let n = xe(t, B, E);
339
+ if (n.kind !== "output") return null;
340
+ let r = Ce(n.text).text.trim();
341
+ return r ? {
370
342
  id: t.id,
371
- text: n
343
+ text: r
372
344
  } : null;
373
345
  }
374
346
  return null;
375
- }, [bt, St]), Wt = T(() => J ? fe(J.text) : null, [J]), Gt = U.chat, Y = T(() => U.voice.filter((e) => e.role === "user" || e.role === "assistant").map((e) => ({
347
+ }, [
348
+ St,
349
+ Ct,
350
+ B,
351
+ E
352
+ ]), Ht = C(() => J ? ue(J.text) : null, [J]), Ut = z.chat, Y = C(() => z.voice.filter((e) => e.role === "user" || e.role === "assistant").map((e) => ({
376
353
  id: e.id,
377
354
  role: e.role,
378
- text: Te(e.content).text.trim(),
379
- sessionId: v(e),
355
+ text: Te(e, B, E),
356
+ sessionId: g(e),
380
357
  timestamp: e.timestamp
381
- })).filter((e) => e.text.length > 0), [U.voice]), Kt = C(() => {
358
+ })).filter((e) => e.text.length > 0), [
359
+ z.voice,
360
+ B,
361
+ E
362
+ ]), Wt = x(() => {
382
363
  if (Y.length === 0) return;
383
364
  let e = /* @__PURE__ */ new Date();
384
- Me(le(Y, {
385
- title: O("voiceSession.transcript", "Voice conversation"),
386
- savedAt: O("voiceSession.savedAt", "Saved"),
387
- session: O("voiceSession.sessionLabel", "Session"),
388
- earlier: O("voiceSession.earlierLabel", "Earlier"),
389
- you: O("voiceSession.speakerYou", "You"),
390
- assistant: O("voiceSession.speakerAssistant", "Assistant")
391
- }, e), ue(k, e), "text/markdown");
365
+ Me(ce(Y, {
366
+ title: E("voiceSession.transcript", "Voice conversation"),
367
+ savedAt: E("voiceSession.savedAt", "Saved"),
368
+ session: E("voiceSession.sessionLabel", "Session"),
369
+ earlier: E("voiceSession.earlierLabel", "Earlier"),
370
+ you: E("voiceSession.speakerYou", "You"),
371
+ assistant: E("voiceSession.speakerAssistant", "Assistant")
372
+ }, e), v(D, e), "text/markdown");
392
373
  }, [
393
- k,
374
+ D,
394
375
  Y,
395
- O
396
- ]), X = He(), Z = E(X);
376
+ E
377
+ ]), X = He(), Z = w(X);
397
378
  Z.current = X;
398
379
  let Q = Ee({
399
- onSubmit: C((e, t) => {
380
+ onSubmit: x((e, t) => {
400
381
  let n = () => {
401
- let n = Z.current, r = be(n.attachments);
382
+ let n = Z.current, r = _e(n.attachments);
402
383
  q.current(e, r, { voiceSessionId: t }), n.clear();
403
384
  };
404
385
  if (!Z.current.isBusy) {
@@ -410,77 +391,78 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
410
391
  }, 200);
411
392
  }, []),
412
393
  latestReply: J,
413
- language: pe(rt, nt).tag
414
- }), qt = T(() => (yt?.messages ?? []).reduce((e, t) => Math.max(e, t.metadata?.continuedVoiceTurns ?? 0), 0), [yt?.messages]), Jt = Y.length > qt, Yt = C(() => {
415
- let e = S.getState().activeConversationId;
416
- !e || Y.length === 0 || (R(e, {
394
+ language: de(rt, nt).tag
395
+ }), Gt = C(() => (xt?.messages ?? []).reduce((e, t) => Math.max(e, t.metadata?.continuedVoiceTurns ?? 0), 0), [xt?.messages]), $ = we(z.voice, B, E), Kt = $ > Gt, qt = x(() => {
396
+ let e = y.getState().activeConversationId;
397
+ !e || Y.length === 0 || (F(e, {
417
398
  id: Xe(),
418
399
  role: "system",
419
- content: x(Y.slice(qt), {
420
- intro: O("voiceSession.continuedIntro", "Continued from a voice conversation. You asked about:"),
421
- nothing: O("voiceSession.continuedNothing", "Continued from a voice conversation."),
422
- more: (e) => O("voiceSession.continuedMore", "…and {{count}} more", { count: e })
400
+ content: _(Y.slice(Gt), {
401
+ intro: E("voiceSession.continuedIntro", "Continued from a voice conversation. You asked about:"),
402
+ nothing: E("voiceSession.continuedNothing", "Continued from a voice conversation."),
403
+ more: (e) => E("voiceSession.continuedMore", "…and {{count}} more", { count: e })
423
404
  }),
424
405
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
425
- metadata: { continuedVoiceTurns: Y.length }
426
- }), jt(!1), Q.end());
406
+ metadata: { continuedVoiceTurns: $ }
407
+ }), V(!1), Q.end());
427
408
  }, [
428
409
  Y,
429
- qt,
430
- R,
431
- O,
410
+ $,
411
+ Gt,
412
+ F,
413
+ E,
432
414
  Q
433
- ]), Xt = E(0);
434
- w(() => {
435
- Q.active && (Xt.current = Y.length);
415
+ ]), Jt = w(0);
416
+ S(() => {
417
+ Q.active && (Jt.current = $);
436
418
  }, [Q.active]);
437
- let Zt = C(() => {
438
- let e = Y.length > Xt.current;
439
- Q.end(), e && jt(!0);
440
- }, [Y, Q]);
441
- w(() => {
442
- !h && Q.active && Q.end();
443
- }, [h, Q]), w(() => {
444
- Q.active || (Z.current.clear(), zt.current = null);
445
- }, [Q.active]), w(() => {
446
- let e = S.getState().consumePendingPrompt();
447
- return e && q.current(e), S.subscribe((e, t) => {
419
+ let Yt = x(() => {
420
+ let e = $ > Jt.current;
421
+ Q.end(), e && V(!0);
422
+ }, [$, Q]);
423
+ S(() => {
424
+ !Ze && Q.active && Q.end();
425
+ }, [Ze, Q]), S(() => {
426
+ Q.active || (Z.current.clear(), Lt.current = null);
427
+ }, [Q.active]), S(() => {
428
+ let e = y.getState().consumePendingPrompt();
429
+ return e && q.current(e), y.subscribe((e, t) => {
448
430
  if (e.pendingPrompt && e.pendingPrompt !== t.pendingPrompt) {
449
- let e = S.getState().consumePendingPrompt();
431
+ let e = y.getState().consumePendingPrompt();
450
432
  e && q.current(e);
451
433
  }
452
434
  });
453
435
  }, []);
454
- let $ = C((e) => {
455
- let t = P ? S.getState().conversations.find((e) => e.id === P) : void 0;
436
+ let Xt = x((e) => {
437
+ let t = M ? y.getState().conversations.find((e) => e.id === M) : void 0;
456
438
  if (t && (t.messages.length > 0 || t.backendSessionId)) {
457
439
  if (t.mode !== e) {
458
- let t = S.getState().conversations.find((t) => t.mode === e && t.messages.length === 0 && !t.backendSessionId && !S.getState().processingByConversationId[t.id]);
459
- t ? ft(t.id) : L(void 0, e);
440
+ let t = y.getState().conversations.find((t) => t.mode === e && t.messages.length === 0 && !t.backendSessionId && !y.getState().processingByConversationId[t.id]);
441
+ t ? pt(t.id) : P(void 0, e);
460
442
  }
461
- } else P && dt(P, e);
462
- I(e);
443
+ } else M && ft(M, e);
444
+ dt(e);
463
445
  }, [
446
+ M,
464
447
  P,
465
- L,
448
+ pt,
466
449
  ft,
467
- dt,
468
- I
469
- ]), Qt = C((e) => {
470
- if (A.find((t) => t.id === e)?.writeCapable && !S.getState().apiCallsAcknowledged) {
471
- kt(e);
450
+ dt
451
+ ]), Zt = x((e) => {
452
+ if (O.find((t) => t.id === e)?.writeCapable && !y.getState().apiCallsAcknowledged) {
453
+ At(e);
472
454
  return;
473
455
  }
474
- $(e);
475
- }, [$, A]), $t = C(() => {
476
- let e = Ot;
477
- kt(null), vt(), e && $(e);
456
+ Xt(e);
457
+ }, [Xt, O]), Qt = x(() => {
458
+ let e = kt;
459
+ At(null), bt(), e && Xt(e);
478
460
  }, [
479
- Ot,
480
- vt,
481
- $
482
- ]), en = C(() => {
483
- kt(null);
461
+ kt,
462
+ bt,
463
+ Xt
464
+ ]), $t = x(() => {
465
+ At(null);
484
466
  }, []);
485
467
  return /* @__PURE__ */ qe("div", {
486
468
  className: "relative flex flex-1 flex-col overflow-hidden",
@@ -489,44 +471,45 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
489
471
  className: "contents",
490
472
  inert: Q.active || void 0,
491
473
  children: [
492
- Y.length > 0 && !Q.active ? /* @__PURE__ */ D(Ae, {
474
+ Y.length > 0 && !Q.active ? /* @__PURE__ */ T(Ae, {
493
475
  count: Y.length,
494
- onOpenTranscript: () => jt(!0)
476
+ onOpenTranscript: () => V(!0)
495
477
  }) : null,
496
- Gt.length === 0 ? /* @__PURE__ */ D(Ne, {
497
- mode: F,
498
- onSuggestionClick: Ht
499
- }) : /* @__PURE__ */ D("div", {
478
+ Ut.length === 0 ? /* @__PURE__ */ T(Ne, {
479
+ mode: N,
480
+ onSuggestionClick: Bt
481
+ }) : /* @__PURE__ */ T("div", {
500
482
  className: "flex min-h-0 flex-1 flex-col",
501
- children: /* @__PURE__ */ D(Pe, {
502
- onApprovePendingWrite: Vt,
503
- approvingWriteRef: Lt,
504
- messages: Gt,
505
- streamingMessageId: Ct,
506
- failedMessageId: wt,
507
- onRetry: Ut
483
+ children: /* @__PURE__ */ T(Pe, {
484
+ onApprovePendingWrite: zt,
485
+ approvingWriteRef: Ft,
486
+ messages: Ut,
487
+ processing: B ?? null,
488
+ streamingMessageId: wt,
489
+ failedMessageId: Tt,
490
+ onRetry: Vt
508
491
  })
509
492
  }),
510
- /* @__PURE__ */ D(Ue, {
511
- onStartVoiceSession: Q.available && F !== "api-calls" ? Q.start : void 0,
493
+ /* @__PURE__ */ T(Ue, {
494
+ onStartVoiceSession: Q.available && N !== "api-calls" ? Q.start : void 0,
512
495
  onSend: (e, t) => void K(e, t),
513
- disabled: St,
514
- placeholder: F === "api-calls" ? O("chatArea.placeholderActions", "What would you like me to do?") : O("chatArea.placeholderGeneral", "Ask me anything…"),
515
- mode: F,
516
- writeAccessDenied: he === "denied" && !!Ft?.writeCapable,
517
- availableModes: Dt,
518
- onModeChange: Qt
496
+ disabled: Ct,
497
+ placeholder: N === "api-calls" ? E("chatArea.placeholderActions", "What would you like me to do?") : E("chatArea.placeholderGeneral", "Ask me anything…"),
498
+ mode: N,
499
+ writeAccessDenied: Qe === "denied" && !!U?.writeCapable,
500
+ availableModes: Ot,
501
+ onModeChange: Zt
519
502
  })
520
503
  ]
521
504
  }),
522
- At && !Q.active ? /* @__PURE__ */ D(je, {
505
+ jt && !Q.active ? /* @__PURE__ */ T(je, {
523
506
  turns: Y,
524
- onClose: () => jt(!1),
525
- onSave: Kt,
526
- onContinueInChat: Jt ? Yt : void 0,
507
+ onClose: () => V(!1),
508
+ onSave: Wt,
509
+ onContinueInChat: Kt ? qt : void 0,
527
510
  closeOnEscape: !0
528
511
  }) : null,
529
- Q.active && /* @__PURE__ */ D(Fe, {
512
+ Q.active && /* @__PURE__ */ T(Fe, {
530
513
  session: Q.session,
531
514
  notice: Q.notice,
532
515
  capturing: Q.capturing,
@@ -540,22 +523,22 @@ var A = ({ visible: h = !0, writeAccess: he = "unknown" }) => {
540
523
  onRetryAttachment: X.retry,
541
524
  canAttachMore: X.canAddMore,
542
525
  preparingAttachments: X.preparingCount,
543
- onSaveTranscript: Kt,
544
- onContinueInChat: Yt,
526
+ onSaveTranscript: Wt,
527
+ onContinueInChat: qt,
545
528
  onInterrupt: () => {
546
- Q.interrupt(), Bt();
529
+ Q.interrupt(), Rt();
547
530
  },
548
- spoken: Wt,
531
+ spoken: Ht,
549
532
  onToggleMute: Q.toggleMute,
550
- onEnd: Zt
533
+ onEnd: Yt
551
534
  }),
552
- /* @__PURE__ */ D(Ge, {
553
- open: Ot !== null,
554
- onConfirm: $t,
555
- onCancel: en
535
+ /* @__PURE__ */ T(Ge, {
536
+ open: kt !== null,
537
+ onConfirm: Qt,
538
+ onCancel: $t
556
539
  })
557
540
  ]
558
541
  });
559
542
  };
560
543
  //#endregion
561
- export { A as AssistantChatArea };
544
+ export { Ze as AssistantChatArea };