@burdenoff/fe-libs 2026.909.3 → 2026.910.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.
@@ -68,6 +68,7 @@ export * from './conversation';
68
68
  export * from './attachments';
69
69
  export * from './store';
70
70
  export * from './turnState';
71
+ export * from './stageCopy';
71
72
  export * from './gatewayLimits';
72
73
  export * from './documentText';
73
74
  export * from './ui/AssistantToolActivity';
@@ -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,gBAAgB,CAAC;AAK/B,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,4B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Ac,uBAAuB,CAAC;AACtC,cAAc,kCAAkC,CAAC;AACjD,cAAc,0BAA0B,CAAC;AAGzC,cAAc,WAAW,CAAC;AAE1B,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0BAA0B,CAAC;AACzC,cAAc,sBAAsB,CAAC;AAErC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,2BAA2B,CAAC;AAE1C,cAAc,kCAAkC,CAAC;AAEjD,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,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,123 @@
1
+ import { AssistantConversationStatus } from './conversation';
2
+ import { AssistantTr } from './i18n';
3
+ /**
4
+ * Every string the assistant shows in its own bubble while a turn is still
5
+ * working — and the one predicate that recognises them.
6
+ *
7
+ * ★★ THE REASON THIS IS ONE MODULE. Two features depend on the same set and
8
+ * they fail in opposite directions if it drifts:
9
+ *
10
+ * - the bubble rotates filler while the model thinks, so the set GROWS;
11
+ * - an interrupted turn must have its filler replaced, so the set must be
12
+ * RECOGNISED exhaustively.
13
+ *
14
+ * Add a phrase to the rotation without teaching the predicate about it and an
15
+ * interrupt during that phrase strands it in the transcript forever — which is
16
+ * precisely the defect this module exists to fix (BOFF-7229), reintroduced one
17
+ * word at a time. Keeping both sides here makes that impossible: the predicate
18
+ * is derived from the same tables the writers use, and a test asserts it.
19
+ */
20
+ export interface StageCopyEntry {
21
+ /** Relative i18n key, resolved through `AssistantTr`. */
22
+ readonly key: string;
23
+ /** English copy, used when the key is unseeded or no provider is mounted. */
24
+ readonly fallback: string;
25
+ }
26
+ /**
27
+ * The environment steps.
28
+ *
29
+ * ★ These are INFORMATIVE, not filler: each names a different thing the runtime
30
+ * is actually doing, and on a cold start they are the only signal the user gets
31
+ * for 11-15 seconds. They are deliberately NOT part of the rotation — swapping
32
+ * "Starting assistant environment..." for "Pondering..." would trade real
33
+ * progress information for decoration.
34
+ */
35
+ export declare const STAGE_COPY: {
36
+ readonly reusingEnvironment: {
37
+ readonly key: "stage.reusingEnvironment";
38
+ readonly fallback: "Reusing assistant environment...";
39
+ };
40
+ readonly lookingForEnvironment: {
41
+ readonly key: "stage.lookingForEnvironment";
42
+ readonly fallback: "Looking for existing environment...";
43
+ };
44
+ readonly startingEnvironment: {
45
+ readonly key: "stage.startingEnvironment";
46
+ readonly fallback: "Starting assistant environment...";
47
+ };
48
+ readonly preparingSession: {
49
+ readonly key: "stage.preparingSession";
50
+ readonly fallback: "Preparing session...";
51
+ };
52
+ readonly connecting: {
53
+ readonly key: "stage.connecting";
54
+ readonly fallback: "Connecting to assistant...";
55
+ };
56
+ readonly thinking: {
57
+ readonly key: "stage.thinking";
58
+ readonly fallback: "Thinking...";
59
+ };
60
+ /**
61
+ * What replaces stage copy on a turn the user cut off.
62
+ *
63
+ * ★ Deliberately NOT a member of `isStageCopy`: it is a settled outcome, not
64
+ * a turn still working. That asymmetry is what makes the replacement
65
+ * idempotent — a second pass over an already-stopped turn rewrites nothing.
66
+ */
67
+ readonly stopped: {
68
+ readonly key: "stage.stopped";
69
+ readonly fallback: "Stopped";
70
+ };
71
+ };
72
+ /**
73
+ * Filler shown while the model is working and has produced nothing yet.
74
+ *
75
+ * ★ `thinking` is first so the sequence always opens on the familiar word, and
76
+ * so index 0 is stable for tests. The rest exist because a single frozen
77
+ * "Thinking..." for the length of a turn reads as a hang; a phrase that moves
78
+ * reads as work in progress.
79
+ *
80
+ * ★ Every entry here is machine copy by construction, so `isStageCopy` covers
81
+ * the whole list rather than a hand-maintained subset.
82
+ */
83
+ export declare const THINKING_PHRASES: readonly StageCopyEntry[];
84
+ /**
85
+ * How long each phrase holds.
86
+ *
87
+ * ★ Not the poll cadence. Polls land every 600-1500ms
88
+ * (`voice/assistantPollSchedule`), and rotating on every one of them flickers.
89
+ * Rotation is driven by ELAPSED TIME so the cadence is independent of how often
90
+ * the loop happens to write.
91
+ */
92
+ export declare const PHRASE_ROTATE_MS = 2500;
93
+ /** Resolve one entry through the product's translator. */
94
+ export declare function stageText(tr: AssistantTr, entry: StageCopyEntry): string;
95
+ /**
96
+ * The phrase for a turn that has been working `elapsedMs`.
97
+ *
98
+ * Pure in `elapsedMs` — the caller owns the clock — so the rotation is
99
+ * exercised by tests without faking timers.
100
+ */
101
+ export declare function thinkingPhrase(tr: AssistantTr, elapsedMs: number): string;
102
+ /**
103
+ * The copy for a conversation status, when a caller has none of its own.
104
+ *
105
+ * ★ Translated, where the literals it replaces were bare English. The assistant
106
+ * rendering English in every locale is a defect this codebase has already paid
107
+ * for once in the fe-libs shell.
108
+ */
109
+ export declare function statusStageCopy(tr: AssistantTr, status: AssistantConversationStatus): string;
110
+ /**
111
+ * Is this bubble still showing machine copy rather than an answer?
112
+ *
113
+ * ★★ Both the translation AND the English fallback are compared, for two
114
+ * reasons that are easy to miss. A locale can change mid-turn, leaving content
115
+ * written under the previous one; and a key that is published but not yet
116
+ * ACTIVE resolves to its fallback, which is how ~9,000 assistant keys behaved
117
+ * in prod. Matching one form only would leave the bubble stranded in exactly
118
+ * the cases this predicate exists to catch.
119
+ *
120
+ * ★ Empty is machine copy too — a bubble with nothing in it is not an answer.
121
+ */
122
+ export declare function isStageCopy(tr: AssistantTr, content: string | null | undefined): boolean;
123
+ //# sourceMappingURL=stageCopy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stageCopy.d.ts","sourceRoot":"","sources":["../../../src/shared/assistant/stageCopy.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAE1C;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,WAAW,cAAc;IAC7B,yDAAyD;IACzD,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,6EAA6E;IAC7E,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;IAyBrB;;;;;;OAMG;;;;;CAK8C,CAAC;AAEpD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gBAAgB,EAAE,SAAS,cAAc,EAWrD,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,OAAO,CAAC;AAErC,0DAA0D;AAC1D,wBAAgB,SAAS,CAAC,EAAE,EAAE,WAAW,EAAE,KAAK,EAAE,cAAc,GAAG,MAAM,CAExE;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,EAAE,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAKzE;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,EAAE,EAAE,WAAW,EACf,MAAM,EAAE,2BAA2B,GAClC,MAAM,CAcR;AAeD;;;;;;;;;;;GAWG;AACH,wBAAgB,WAAW,CACzB,EAAE,EAAE,WAAW,EACf,OAAO,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GACjC,OAAO,CAOT"}
@@ -0,0 +1,97 @@
1
+ //#region src/shared/assistant/stageCopy.ts
2
+ var e = {
3
+ reusingEnvironment: {
4
+ key: "stage.reusingEnvironment",
5
+ fallback: "Reusing assistant environment..."
6
+ },
7
+ lookingForEnvironment: {
8
+ key: "stage.lookingForEnvironment",
9
+ fallback: "Looking for existing environment..."
10
+ },
11
+ startingEnvironment: {
12
+ key: "stage.startingEnvironment",
13
+ fallback: "Starting assistant environment..."
14
+ },
15
+ preparingSession: {
16
+ key: "stage.preparingSession",
17
+ fallback: "Preparing session..."
18
+ },
19
+ connecting: {
20
+ key: "stage.connecting",
21
+ fallback: "Connecting to assistant..."
22
+ },
23
+ thinking: {
24
+ key: "stage.thinking",
25
+ fallback: "Thinking..."
26
+ },
27
+ stopped: {
28
+ key: "stage.stopped",
29
+ fallback: "Stopped"
30
+ }
31
+ }, t = [
32
+ e.thinking,
33
+ {
34
+ key: "stage.pondering",
35
+ fallback: "Pondering..."
36
+ },
37
+ {
38
+ key: "stage.reasoning",
39
+ fallback: "Reasoning..."
40
+ },
41
+ {
42
+ key: "stage.inferring",
43
+ fallback: "Inferring..."
44
+ },
45
+ {
46
+ key: "stage.considering",
47
+ fallback: "Considering..."
48
+ },
49
+ {
50
+ key: "stage.working",
51
+ fallback: "Working..."
52
+ },
53
+ {
54
+ key: "stage.reflecting",
55
+ fallback: "Reflecting..."
56
+ },
57
+ {
58
+ key: "stage.deliberating",
59
+ fallback: "Deliberating..."
60
+ },
61
+ {
62
+ key: "stage.weighing",
63
+ fallback: "Weighing it up..."
64
+ },
65
+ {
66
+ key: "stage.piecing",
67
+ fallback: "Piecing it together..."
68
+ }
69
+ ], n = 2500;
70
+ function r(e, t) {
71
+ return e(t.key, t.fallback);
72
+ }
73
+ function i(e, i) {
74
+ return r(e, t[Math.floor((Number.isFinite(i) ? Math.max(0, i) : 0) / n) % t.length]);
75
+ }
76
+ function a(t, n) {
77
+ switch (n) {
78
+ case "provisioning": return r(t, e.startingEnvironment);
79
+ case "connecting": return r(t, e.connecting);
80
+ case "streaming": return r(t, e.thinking);
81
+ default: return "";
82
+ }
83
+ }
84
+ var o = [
85
+ e.reusingEnvironment,
86
+ e.lookingForEnvironment,
87
+ e.startingEnvironment,
88
+ e.preparingSession,
89
+ e.connecting,
90
+ ...t
91
+ ];
92
+ function s(e, t) {
93
+ let n = (t ?? "").trim();
94
+ return n ? o.some((t) => e(t.key, t.fallback) === n || t.fallback === n) : !0;
95
+ }
96
+ //#endregion
97
+ export { n as PHRASE_ROTATE_MS, e as STAGE_COPY, t as THINKING_PHRASES, s as isStageCopy, r as stageText, a as statusStageCopy, i as thinkingPhrase };
@@ -1,6 +1,7 @@
1
1
  import { FC } from 'react';
2
2
  import { PanelProps } from '../../plugins/types';
3
3
  import { WorkspaceWriteAccess } from '../useWorkspaceWriteAccess';
4
+ import { AssistantNavigate } from './AssistantMarkdownRenderer';
4
5
  export type AIAssistantPanelProps = PanelProps & {
5
6
  /** When provided, renders a dock/float toggle in the header. */
6
7
  docked?: boolean;
@@ -13,6 +14,14 @@ export type AIAssistantPanelProps = PanelProps & {
13
14
  * it and the panel simply never claims a write will be refused.
14
15
  */
15
16
  writeAccess?: WorkspaceWriteAccess;
17
+ /**
18
+ * Route an in-app link from an assistant reply instead of a full page load.
19
+ *
20
+ * ★ Threaded through rather than resolved here, for the same reason as
21
+ * `writeAccess`: only the product owns a router. Omit it and internal links
22
+ * stay ordinary same-tab anchors — the assistant never navigates on its own.
23
+ */
24
+ onNavigate?: AssistantNavigate;
16
25
  };
17
26
  /**
18
27
  * The panel.
@@ -1 +1 @@
1
- {"version":3,"file":"AIAssistantPanel.d.ts","sourceRoot":"","sources":["../../../../src/shared/assistant/ui/AIAssistantPanel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAU,KAAK,EAAE,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAMtD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAQvE,MAAM,MAAM,qBAAqB,GAAG,UAAU,GAAG;IAC/C,gEAAgE;IAChE,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,oBAAoB,CAAC;CACpC,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CA+FtD,CAAC"}
1
+ {"version":3,"file":"AIAssistantPanel.d.ts","sourceRoot":"","sources":["../../../../src/shared/assistant/ui/AIAssistantPanel.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAU,KAAK,EAAE,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAMtD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAIvE,OAAO,EAEL,KAAK,iBAAiB,EACvB,MAAM,6BAA6B,CAAC;AAKrC,MAAM,MAAM,qBAAqB,GAAG,UAAU,GAAG;IAC/C,gEAAgE;IAChE,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,oBAAoB,CAAC;IACnC;;;;;;OAMG;IACH,UAAU,CAAC,EAAE,iBAAiB,CAAC;CAChC,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,EAAE,CAAC,qBAAqB,CA6GtD,CAAC"}
@@ -2,49 +2,53 @@ import { useAssistantPageLabel as e } from "../product.js";
2
2
  import { useAssistantTr as t } from "../i18n.js";
3
3
  import { useAssistantStore as n } from "../store.js";
4
4
  import { AssistantSpeechProvider as r } from "./AssistantSpeechProvider.js";
5
- import { AssistantHeader as i } from "./AssistantHeader.js";
6
- import { AssistantConversationList as a } from "./AssistantConversationList.js";
7
- import { useFilesServiceWarmup as o } from "../../../storage/warmFilesService.js";
8
- import { useAssistantHeartbeat as s } from "../useAssistantHeartbeat.js";
9
- import { useAssistantKeyboardShortcuts as c } from "../useAssistantKeyboardShortcuts.js";
10
- import { AssistantChatArea as l } from "./AssistantChatArea.js";
11
- import { useRef as u } from "react";
12
- import { jsx as d, jsxs as f } from "react/jsx-runtime";
5
+ import { AssistantNavigateProvider as i } from "./AssistantMarkdownRenderer.js";
6
+ import { AssistantHeader as a } from "./AssistantHeader.js";
7
+ import { AssistantConversationList as o } from "./AssistantConversationList.js";
8
+ import { useFilesServiceWarmup as s } from "../../../storage/warmFilesService.js";
9
+ import { useAssistantHeartbeat as c } from "../useAssistantHeartbeat.js";
10
+ import { useAssistantKeyboardShortcuts as l } from "../useAssistantKeyboardShortcuts.js";
11
+ import { AssistantChatArea as u } from "./AssistantChatArea.js";
12
+ import { useRef as d } from "react";
13
+ import { jsx as f, jsxs as p } from "react/jsx-runtime";
13
14
  //#region src/shared/assistant/ui/AIAssistantPanel.tsx
14
- var p = ({ onClose: p, visible: m, docked: h, onToggleDock: g, writeAccess: _ }) => {
15
- let v = t(), y = u(null), { conversations: b, activeConversationId: x, conversationListOpen: S, toggleConversationList: C, createConversation: w } = n(), T = b.find((e) => e.id === x);
16
- s(T?.backendSessionId ?? null, T?.mode ?? null, m ?? !0), o(m ?? !0);
17
- let E = e(m !== !1);
18
- return c({
19
- panelRef: y,
20
- onClose: p
21
- }), /* @__PURE__ */ d(r, {
22
- visible: m ?? !0,
23
- children: /* @__PURE__ */ f("div", {
24
- ref: y,
25
- className: "relative flex h-full w-full flex-col bg-bg-surface",
26
- role: "complementary",
27
- "aria-label": v("panel.ariaLabel", "AI Assistant"),
28
- "data-testid": "ai-assistant-panel",
29
- tabIndex: -1,
30
- children: [
31
- /* @__PURE__ */ d(i, {
32
- contextLabel: E,
33
- onNewConversation: () => w(),
34
- onOpenHistory: C,
35
- historyOpen: S,
36
- onClose: p,
37
- docked: h,
38
- onToggleDock: g
39
- }),
40
- S && /* @__PURE__ */ d(a, {}),
41
- /* @__PURE__ */ d(l, {
42
- visible: m ?? !0,
43
- writeAccess: _
44
- })
45
- ]
15
+ var m = ({ onClose: m, visible: h, docked: g, onToggleDock: _, writeAccess: v, onNavigate: y }) => {
16
+ let b = t(), x = d(null), { conversations: S, activeConversationId: C, conversationListOpen: w, toggleConversationList: T, createConversation: E } = n(), D = S.find((e) => e.id === C);
17
+ c(D?.backendSessionId ?? null, D?.mode ?? null, h ?? !0), s(h ?? !0);
18
+ let O = e(h !== !1);
19
+ return l({
20
+ panelRef: x,
21
+ onClose: m
22
+ }), /* @__PURE__ */ f(r, {
23
+ visible: h ?? !0,
24
+ children: /* @__PURE__ */ f(i, {
25
+ value: y,
26
+ children: /* @__PURE__ */ p("div", {
27
+ ref: x,
28
+ className: "relative flex h-full w-full flex-col bg-bg-surface",
29
+ role: "complementary",
30
+ "aria-label": b("panel.ariaLabel", "AI Assistant"),
31
+ "data-testid": "ai-assistant-panel",
32
+ tabIndex: -1,
33
+ children: [
34
+ /* @__PURE__ */ f(a, {
35
+ contextLabel: O,
36
+ onNewConversation: () => E(),
37
+ onOpenHistory: T,
38
+ historyOpen: w,
39
+ onClose: m,
40
+ docked: g,
41
+ onToggleDock: _
42
+ }),
43
+ w && /* @__PURE__ */ f(o, {}),
44
+ /* @__PURE__ */ f(u, {
45
+ visible: h ?? !0,
46
+ writeAccess: v
47
+ })
48
+ ]
49
+ })
46
50
  })
47
51
  });
48
52
  };
49
53
  //#endregion
50
- export { p as AIAssistantPanel };
54
+ export { m as AIAssistantPanel };
@@ -1 +1 @@
1
- {"version":3,"file":"AssistantChatArea.d.ts","sourceRoot":"","sources":["../../../../src/shared/assistant/ui/AssistantChatArea.tsx"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,EAAE,EACR,MAAM,OAAO,CAAC;AAyEf,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAoLvE;;;;;GAKG;AACH,MAAM,WAAW,sBAAsB;IACrC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;;;;;;;;;OAYG;IACH,WAAW,CAAC,EAAE,oBAAoB,CAAC;CACpC;AAED,eAAO,MAAM,iBAAiB,EAAE,EAAE,CAAC,sBAAsB,CAi6DxD,CAAC"}
1
+ {"version":3,"file":"AssistantChatArea.d.ts","sourceRoot":"","sources":["../../../../src/shared/assistant/ui/AssistantChatArea.tsx"],"names":[],"mappings":"AAAA,OAAO,EAML,KAAK,EAAE,EACR,MAAM,OAAO,CAAC;AAyEf,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAgLvE;;;;;GAKG;AACH,MAAM,WAAW,sBAAsB;IACrC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;;;;;;;;;;OAYG;IACH,WAAW,CAAC,EAAE,oBAAoB,CAAC;CACpC;AAED,eAAO,MAAM,iBAAiB,EAAE,EAAE,CAAC,sBAAsB,CAg9DxD,CAAC"}