@inupedia/spotlight-vue 0.1.9 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
- import { defineComponent as jt, ref as D, onMounted as Pt, nextTick as kt, onBeforeUnmount as It, computed as H, watch as bt, openBlock as r, createElementBlock as o, normalizeClass as B, createElementVNode as s, toDisplayString as a, createCommentVNode as u, Fragment as d, renderList as m, createBlock as Vt, unref as M, createVNode as W, normalizeStyle as ft } from "vue";
1
+ import { defineComponent as jt, ref as D, onMounted as It, nextTick as kt, onBeforeUnmount as Pt, computed as M, watch as bt, openBlock as r, createElementBlock as o, normalizeClass as B, createElementVNode as s, toDisplayString as a, createCommentVNode as u, Fragment as d, renderList as m, createBlock as Vt, unref as N, createVNode as W, normalizeStyle as ft } from "vue";
2
2
  import { MdPreview as mt } from "md-editor-v3";
3
3
  import "md-editor-v3/lib/preview.css";
4
4
  import qt from "./SpotlightMarkdownPreview.vue.js";
5
5
  import { isToolExecutionStep as Kt, humanizeSpotlightStepContent as Jt, getIntentStepDisplayContent as Ut, splitToolStepContent as pt, sanitizeToolStepAnswerText as yt } from "../store/pipeline/displayText.js";
6
6
  import { partitionToolCalls as _t } from "../store/pipeline/toolDisplay.js";
7
7
  import { TOOL_NAMES as Wt } from "../constants/toolNames.js";
8
- import Yt from "./OfficialBorderBeam.js";
9
- const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-stack" }, Xt = { class: "thinking-bar-title" }, Zt = {
8
+ import Gt from "./OfficialBorderBeam.js";
9
+ const Qt = { class: "thinking-bar-header" }, Xt = { class: "thinking-bar-title-stack" }, Yt = { class: "thinking-bar-title" }, Zt = {
10
10
  key: 0,
11
11
  class: "thinking-bar-memory-badge"
12
12
  }, te = {
@@ -27,31 +27,31 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
27
27
  }, _e = { class: "thinking-bar-tool-call-head-side" }, ve = { class: "thinking-bar-tool-call-body" }, we = {
28
28
  key: 0,
29
29
  class: "thinking-bar-tool-call-block"
30
- }, Te = { class: "thinking-bar-tool-call-pre" }, Se = {
30
+ }, Te = { class: "thinking-bar-tool-call-pre" }, xe = {
31
31
  key: 1,
32
32
  class: "thinking-bar-tool-call-block thinking-bar-tool-call-block--result"
33
- }, xe = { class: "thinking-bar-tool-call-pre" }, $e = {
33
+ }, Se = { class: "thinking-bar-tool-call-pre" }, $e = {
34
34
  key: 2,
35
35
  class: "thinking-bar-tool-call-block thinking-bar-tool-call-block--result"
36
36
  }, Ae = {
37
37
  key: 0,
38
38
  class: "thinking-bar-tool-result-image-shell"
39
- }, Be = ["src", "alt"], Ce = ["srcdoc", "title"], Re = {
39
+ }, Be = ["src", "alt"], Ce = ["srcdoc", "title"], Fe = {
40
40
  key: 2,
41
41
  class: "thinking-bar-tool-result-table-wrap"
42
- }, Ee = { class: "thinking-bar-tool-result-table" }, Fe = {
42
+ }, Re = { class: "thinking-bar-tool-result-table" }, Ee = {
43
43
  key: 3,
44
44
  class: "thinking-bar-tool-call-pre"
45
- }, Oe = {
45
+ }, ze = {
46
46
  key: 3,
47
47
  class: "thinking-bar-tool-call-block"
48
- }, ze = { class: "thinking-bar-tool-call-pre" }, De = {
48
+ }, Oe = { class: "thinking-bar-tool-call-pre" }, De = {
49
49
  key: 4,
50
50
  class: "thinking-bar-tool-call-block thinking-bar-tool-call-block--error"
51
- }, He = { class: "thinking-bar-tool-call-pre" }, Me = {
51
+ }, Me = { class: "thinking-bar-tool-call-pre" }, Ne = {
52
52
  key: 5,
53
53
  class: "thinking-bar-nested-tools"
54
- }, Ne = { class: "thinking-bar-tool-call-head" }, Le = { class: "thinking-bar-tool-call-head-main" }, je = { class: "thinking-bar-tool-call-name" }, Pe = { class: "thinking-bar-tool-call-head-side" }, Ie = { class: "thinking-bar-tool-call-body" }, Ve = {
54
+ }, He = { class: "thinking-bar-tool-call-head" }, Le = { class: "thinking-bar-tool-call-head-main" }, je = { class: "thinking-bar-tool-call-name" }, Ie = { class: "thinking-bar-tool-call-head-side" }, Pe = { class: "thinking-bar-tool-call-body" }, Ve = {
55
55
  key: 0,
56
56
  class: "thinking-bar-tool-call-block"
57
57
  }, qe = { class: "thinking-bar-tool-call-pre" }, Ke = {
@@ -60,13 +60,13 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
60
60
  }, Je = { class: "thinking-bar-tool-call-pre" }, Ue = {
61
61
  key: 1,
62
62
  class: "thinking-bar-step-answer-section"
63
- }, We = { class: "thinking-bar-step-text thinking-bar-step-markdown thinking-bar-step-answer" }, Ye = {
63
+ }, We = { class: "thinking-bar-step-text thinking-bar-step-markdown thinking-bar-step-answer" }, Ge = {
64
64
  key: 0,
65
65
  class: "thinking-bar-chat-items"
66
- }, Ge = {
66
+ }, Qe = {
67
67
  key: 0,
68
68
  class: "thinking-bar-step-text thinking-bar-step-markdown"
69
- }, Qe = ["open"], Xe = { class: "thinking-bar-tool-call-head" }, Ze = { class: "thinking-bar-tool-call-head-main" }, tn = { class: "thinking-bar-tool-call-name" }, en = { class: "thinking-bar-tool-call-head-side" }, nn = { class: "thinking-bar-tool-call-body" }, sn = {
69
+ }, Xe = ["open"], Ye = { class: "thinking-bar-tool-call-head" }, Ze = { class: "thinking-bar-tool-call-head-main" }, tn = { class: "thinking-bar-tool-call-name" }, en = { class: "thinking-bar-tool-call-head-side" }, nn = { class: "thinking-bar-tool-call-body" }, sn = {
70
70
  key: 0,
71
71
  class: "thinking-bar-tool-call-block thinking-bar-tool-call-block--result"
72
72
  }, rn = {
@@ -90,16 +90,16 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
90
90
  }, yn = { class: "thinking-bar-workspace-shell" }, _n = { class: "thinking-bar-file-tree-pane" }, vn = { class: "thinking-bar-file-tree-body" }, wn = {
91
91
  key: 0,
92
92
  class: "thinking-bar-tree-node"
93
- }, Tn = ["onClick"], Sn = { class: "thinking-bar-tree-caret" }, xn = { class: "thinking-bar-tree-label" }, $n = ["onClick"], An = { class: "thinking-bar-tree-icon" }, Bn = { class: "thinking-bar-tree-label" }, Cn = { class: "thinking-bar-file-preview" }, Rn = { class: "thinking-bar-file-preview-head" }, En = { class: "thinking-bar-file-preview-title" }, Fn = { class: "thinking-bar-tree-icon" }, On = {
93
+ }, Tn = ["onClick"], xn = { class: "thinking-bar-tree-caret" }, Sn = { class: "thinking-bar-tree-label" }, $n = ["onClick"], An = { class: "thinking-bar-tree-icon" }, Bn = { class: "thinking-bar-tree-label" }, Cn = { class: "thinking-bar-file-preview" }, Fn = { class: "thinking-bar-file-preview-head" }, Rn = { class: "thinking-bar-file-preview-title" }, En = { class: "thinking-bar-tree-icon" }, zn = {
94
94
  key: 0,
95
95
  class: "thinking-bar-preview-chip"
96
- }, zn = {
96
+ }, On = {
97
97
  key: 0,
98
98
  class: "thinking-bar-image-shell"
99
- }, Dn = ["src", "alt"], Hn = {
99
+ }, Dn = ["src", "alt"], Mn = {
100
100
  key: 1,
101
101
  class: "thinking-bar-empty-preview"
102
- }, Mn = ["srcdoc", "title"], Nn = {
102
+ }, Nn = ["srcdoc", "title"], Hn = {
103
103
  key: 2,
104
104
  class: "thinking-bar-file-preview-body"
105
105
  }, Ln = {
@@ -115,8 +115,8 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
115
115
  },
116
116
  emits: ["close"],
117
117
  setup(w) {
118
- const Y = D(!1), L = D(null), _ = D({}), T = /* @__PURE__ */ new Map();
119
- let C = null, S = null;
118
+ const G = D(!1), L = D(null), _ = D({}), T = /* @__PURE__ */ new Map();
119
+ let C = null, x = null;
120
120
  function j(e) {
121
121
  K(e), requestAnimationFrame(() => {
122
122
  K(e);
@@ -124,22 +124,22 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
124
124
  }
125
125
  function vt(e, t) {
126
126
  const i = T.get(e);
127
- i && S && S.unobserve(i);
127
+ i && x && x.unobserve(i);
128
128
  const n = t instanceof HTMLElement ? t : null;
129
- n ? (T.set(e, n), S?.observe(n)) : T.delete(e);
129
+ n ? (T.set(e, n), x?.observe(n)) : T.delete(e);
130
130
  }
131
- function G(e) {
131
+ function Q(e) {
132
132
  return e.scrollHeight - e.scrollTop - e.clientHeight <= 96;
133
133
  }
134
134
  function wt(e, t) {
135
135
  const i = t.target;
136
136
  C != null && window.clearTimeout(C), _.value = {
137
137
  ..._.value,
138
- [e]: G(i)
138
+ [e]: Q(i)
139
139
  }, C = window.setTimeout(() => {
140
140
  _.value = {
141
141
  ..._.value,
142
- [e]: G(i)
142
+ [e]: Q(i)
143
143
  };
144
144
  }, 120);
145
145
  }
@@ -149,33 +149,33 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
149
149
  const t = h.steps[h.steps.length - 1];
150
150
  return t ? [t.id] : [];
151
151
  }
152
- function Q(e, t) {
152
+ function X(e, t) {
153
153
  return t ? !0 : _.value[e] !== !1;
154
154
  }
155
- Pt(() => {
156
- typeof ResizeObserver < "u" && (S = new ResizeObserver(() => {
155
+ It(() => {
156
+ typeof ResizeObserver < "u" && (x = new ResizeObserver(() => {
157
157
  K();
158
158
  }), kt(() => {
159
159
  T.forEach((e) => {
160
- S?.observe(e);
160
+ x?.observe(e);
161
161
  });
162
162
  })), requestAnimationFrame(() => {
163
- Y.value = !0;
163
+ G.value = !0;
164
164
  }), requestAnimationFrame(() => {
165
165
  j(!0);
166
166
  });
167
- }), It(() => {
168
- C != null && window.clearTimeout(C), S?.disconnect(), S = null, T.clear();
167
+ }), Pt(() => {
168
+ C != null && window.clearTimeout(C), x?.disconnect(), x = null, T.clear();
169
169
  });
170
- const h = w, St = H(() => h.steps.length > 0 && h.steps.every((t) => t.status === "done" || t.status === "error") ? "执行完成" : "思考中"), X = H(() => h.memoryReplay ? h.memoryReplay.source === "semantic" ? "语义缓存" : h.memoryReplay.source === "exact" ? "Memory 缓存" : "Session 缓存" : ""), xt = H(
170
+ const h = w, xt = M(() => h.steps.length > 0 && h.steps.every((t) => t.status === "done" || t.status === "error") ? "执行完成" : "思考中"), Y = M(() => h.memoryReplay ? h.memoryReplay.source === "semantic" ? "语义缓存" : h.memoryReplay.source === "exact" ? "Memory 缓存" : "Session 缓存" : ""), St = M(
171
171
  () => h.steps.some(
172
172
  (e) => e.status === "active" || e.status === "pending" || e.toolCalls?.some(
173
173
  (t) => t.status === "pending" || t.status === "running"
174
174
  )
175
175
  )
176
- ), $t = H(
176
+ ), $t = M(
177
177
  () => h.steps.filter((e) => e.status === "active").length
178
- ), At = H(
178
+ ), At = M(
179
179
  () => h.steps.filter((e) => e.status === "done").length
180
180
  );
181
181
  function Bt(e) {
@@ -193,10 +193,10 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
193
193
  function Ct(e) {
194
194
  return e.name.trim().toLowerCase();
195
195
  }
196
- function N(e) {
196
+ function H(e) {
197
197
  return e.displayName?.trim() || e.name;
198
198
  }
199
- function P(e) {
199
+ function I(e) {
200
200
  return pt(e.content ?? "").planning;
201
201
  }
202
202
  function Z(e) {
@@ -216,23 +216,23 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
216
216
  (t) => t.type === "tool"
217
217
  ).map((t) => t.toolCall);
218
218
  }
219
- function I(e) {
219
+ function P(e) {
220
220
  return _t(et(e)).visible;
221
221
  }
222
222
  function nt(e) {
223
223
  return _t(et(e)).nestedKnowledge;
224
224
  }
225
- function Rt(e) {
226
- return Et(e.name) === Wt.knowledge.answer;
225
+ function Ft(e) {
226
+ return Rt(e.name) === Wt.knowledge.answer;
227
227
  }
228
- function Et(e) {
228
+ function Rt(e) {
229
229
  return e.trim().toLowerCase();
230
230
  }
231
- function Ft(e) {
232
- return !!(P(e).trim() || I(e).length > 0);
231
+ function Et(e) {
232
+ return !!(I(e).trim() || P(e).length > 0);
233
233
  }
234
- function Ot(e) {
235
- const t = I(e).length;
234
+ function zt(e) {
235
+ const t = P(e).length;
236
236
  return t > 0 ? `${t} 个工具调用` : "规划记录";
237
237
  }
238
238
  function it(e) {
@@ -264,7 +264,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
264
264
  return null;
265
265
  }
266
266
  }
267
- function x(e) {
267
+ function S(e) {
268
268
  const t = Ct(e), i = e.resultText?.trim() || "";
269
269
  if (!i) return "";
270
270
  if (t === "list_kbs") {
@@ -281,19 +281,19 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
281
281
  const t = e.resultText?.trim() || "";
282
282
  return t ? V(t) ?? t : null;
283
283
  }
284
- function R(e) {
284
+ function F(e) {
285
285
  return typeof e == "object" && e !== null && !Array.isArray(e);
286
286
  }
287
287
  function ot(e) {
288
288
  return /<(table|html|body|svg|div|span|img|p|iframe)[\s>]/i.test(e);
289
289
  }
290
- function E(e) {
290
+ function R(e) {
291
291
  const t = q(e);
292
292
  if (typeof t == "string") {
293
293
  const i = t.trim();
294
294
  return /^data:image\//i.test(i) || /\.(png|jpe?g|gif|webp|svg)(\?.*)?$/i.test(i) ? i : null;
295
295
  }
296
- if (R(t)) {
296
+ if (F(t)) {
297
297
  const i = [t.url, t.uri, t.path].find(
298
298
  (n) => typeof n == "string" && /^data:image\//i.test(n)
299
299
  );
@@ -301,11 +301,11 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
301
301
  }
302
302
  return null;
303
303
  }
304
- function F(e) {
304
+ function E(e) {
305
305
  const t = q(e);
306
306
  if (typeof t == "string" && ot(t.trim()))
307
307
  return t;
308
- if (R(t)) {
308
+ if (F(t)) {
309
309
  const i = [t.html, t.content, t.markup].find(
310
310
  (n) => typeof n == "string" && ot(n)
311
311
  );
@@ -314,7 +314,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
314
314
  return null;
315
315
  }
316
316
  function lt(e) {
317
- return !Array.isArray(e) || e.length === 0 || !e.every((t) => R(t)) ? null : e;
317
+ return !Array.isArray(e) || e.length === 0 || !e.every((t) => F(t)) ? null : e;
318
318
  }
319
319
  function y(e) {
320
320
  const t = q(e);
@@ -328,10 +328,10 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
328
328
  const n = [...new Set(i.flatMap((l) => Object.keys(l)))];
329
329
  return n.length > 0 ? { columns: n, rows: i } : null;
330
330
  }
331
- if (!R(t)) return null;
331
+ if (!F(t)) return null;
332
332
  if (Array.isArray(t.columns) && Array.isArray(t.rows) && t.columns.every((n) => typeof n == "string")) {
333
333
  const n = t.columns, l = t.rows.map(
334
- (c) => R(c) ? c : Array.isArray(c) ? Object.fromEntries(
334
+ (c) => F(c) ? c : Array.isArray(c) ? Object.fromEntries(
335
335
  n.map((f, p) => [f, c[p]])
336
336
  ) : { value: c }
337
337
  );
@@ -349,8 +349,8 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
349
349
  return null;
350
350
  }
351
351
  function at(e) {
352
- const t = x(e), i = e.summary?.trim();
353
- return t && i && t.trim() === i ? !1 : !!(E(e) || F(e) || y(e) || t);
352
+ const t = S(e), i = e.summary?.trim();
353
+ return t && i && t.trim() === i ? !1 : !!(R(e) || E(e) || y(e) || t);
354
354
  }
355
355
  function ct(e) {
356
356
  if (e == null) return "-";
@@ -373,7 +373,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
373
373
  const i = Tt();
374
374
  for (const n of i) {
375
375
  const l = T.get(n);
376
- !l || !Q(n, e) || l.scrollTo({
376
+ !l || !X(n, e) || l.scrollTo({
377
377
  top: l.scrollHeight,
378
378
  behavior: e ? "auto" : "smooth"
379
379
  });
@@ -386,7 +386,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
386
386
  });
387
387
  for (const l of i) {
388
388
  const c = T.get(l);
389
- !c || !Q(l, e) || c.scrollTo({
389
+ !c || !X(l, e) || c.scrollTo({
390
390
  top: c.scrollHeight,
391
391
  behavior: "auto"
392
392
  });
@@ -396,7 +396,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
396
396
  bt(
397
397
  () => h.steps,
398
398
  () => {
399
- if (xt.value) {
399
+ if (St.value) {
400
400
  const e = h.steps.find((t) => t.status === "active");
401
401
  e && !(e.id in _.value) && (_.value = {
402
402
  ..._.value,
@@ -408,40 +408,40 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
408
408
  },
409
409
  { deep: !0 }
410
410
  );
411
- const O = D({}), A = D({});
411
+ const z = D({}), A = D({});
412
412
  bt(
413
413
  () => h.steps,
414
414
  (e) => {
415
- const t = { ...O.value }, i = { ...A.value };
415
+ const t = { ...z.value }, i = { ...A.value };
416
416
  for (const n of e) {
417
417
  if (n.files?.length && !t[n.id] && (t[n.id] = n.files[0].id), !n.files?.length && t[n.id] && delete t[n.id], n.files?.length) {
418
418
  const l = new Set(i[n.id] || []);
419
419
  for (const c of n.files)
420
- Ht(c.path).forEach(
420
+ Mt(c.path).forEach(
421
421
  (f) => l.add(f)
422
422
  );
423
423
  i[n.id] = [...l];
424
424
  }
425
425
  !n.files?.length && i[n.id] && delete i[n.id];
426
426
  }
427
- O.value = t, A.value = i;
427
+ z.value = t, A.value = i;
428
428
  },
429
429
  { deep: !0, immediate: !0 }
430
430
  );
431
- function zt(e, t) {
432
- O.value = {
433
- ...O.value,
431
+ function Ot(e, t) {
432
+ z.value = {
433
+ ...z.value,
434
434
  [e]: t
435
435
  };
436
436
  }
437
437
  function Dt(e, t) {
438
- t && zt(e, t.id);
438
+ t && Ot(e, t.id);
439
439
  }
440
440
  function k(e) {
441
- const t = O.value[e.id];
441
+ const t = z.value[e.id];
442
442
  return e.files?.find((i) => i.id === t) ?? e.files?.[0] ?? null;
443
443
  }
444
- function Ht(e) {
444
+ function Mt(e) {
445
445
  const t = e.split("/").filter(Boolean), i = [];
446
446
  let n = "";
447
447
  return t.slice(0, -1).forEach((l) => {
@@ -451,14 +451,14 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
451
451
  function ut(e, t) {
452
452
  return (A.value[e] || []).includes(t);
453
453
  }
454
- function Mt(e, t) {
454
+ function Nt(e, t) {
455
455
  const i = new Set(A.value[e] || []);
456
456
  i.has(t) ? i.delete(t) : i.add(t), A.value = {
457
457
  ...A.value,
458
458
  [e]: [...i]
459
459
  };
460
460
  }
461
- function Nt(e, t) {
461
+ function Ht(e, t) {
462
462
  const i = /* @__PURE__ */ new Map(), n = (p, $, v) => (i.has(p) || i.set(p, {
463
463
  path: p,
464
464
  name: $,
@@ -468,12 +468,12 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
468
468
  }), i.get(p)), l = n("", "root", -1);
469
469
  for (const p of t) {
470
470
  const $ = p.path.split("/").filter(Boolean);
471
- let v = "", z = l;
471
+ let v = "", O = l;
472
472
  $.slice(0, -1).forEach((b, g) => {
473
473
  v += `/${b}`;
474
474
  const Lt = n(v, b, g);
475
- z.directoryChildren.includes(v) || z.directoryChildren.push(v), z = Lt;
476
- }), z.files.push(p);
475
+ O.directoryChildren.includes(v) || O.directoryChildren.push(v), O = Lt;
476
+ }), O.files.push(p);
477
477
  }
478
478
  const c = [], f = (p) => {
479
479
  const $ = i.get(p);
@@ -529,7 +529,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
529
529
  return (e, t) => (r(), o("div", {
530
530
  class: B(["thinking-bar", [
531
531
  { "thinking-bar--embedded": w.embedded },
532
- { "thinking-bar--open": Y.value },
532
+ { "thinking-bar--open": G.value },
533
533
  { "thinking-bar--centered": w.centered },
534
534
  { "thinking-bar--corner": !w.centered && !w.embedded }
535
535
  ]])
@@ -538,11 +538,11 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
538
538
  class: "thinking-bar-grid",
539
539
  "aria-hidden": "true"
540
540
  }, null, -1)),
541
- s("div", Gt, [
542
- s("div", Qt, [
543
- t[1] || (t[1] = s("span", { class: "thinking-bar-kicker" }, "HYDRO PROCESS", -1)),
544
- s("span", Xt, a(St.value), 1),
545
- X.value ? (r(), o("span", Zt, a(X.value), 1)) : u("", !0)
541
+ s("div", Qt, [
542
+ s("div", Xt, [
543
+ t[1] || (t[1] = s("span", { class: "thinking-bar-kicker" }, "Spotlight", -1)),
544
+ s("span", Yt, a(xt.value), 1),
545
+ Y.value ? (r(), o("span", Zt, a(Y.value), 1)) : u("", !0)
546
546
  ]),
547
547
  s("div", te, [
548
548
  s("span", ee, [
@@ -574,14 +574,14 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
574
574
  key: i.id,
575
575
  class: B(["thinking-bar-step", [i.status]])
576
576
  }, [
577
- i.status === "active" ? (r(), Vt(Yt, {
577
+ i.status === "active" ? (r(), Vt(Gt, {
578
578
  key: 0,
579
579
  class: "thinking-bar-step-beam",
580
580
  size: 88,
581
581
  duration: 6,
582
582
  "border-width": 1.5,
583
- "color-from": "#c9a25d",
584
- "color-to": "#5d8f9b"
583
+ "color-from": "#0A84FF",
584
+ "color-to": "#64D2FF"
585
585
  })) : u("", !0),
586
586
  s("div", se, [
587
587
  s("span", re, a(Bt(i.status)), 1),
@@ -593,24 +593,24 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
593
593
  class: "thinking-bar-step-body",
594
594
  onScrollPassive: (n) => wt(i.id, n)
595
595
  }, [
596
- M(Kt)(i.id) ? (r(), o("div", ce, [
597
- Ft(i) ? (r(), o("details", ue, [
596
+ N(Kt)(i.id) ? (r(), o("div", ce, [
597
+ Et(i) ? (r(), o("details", ue, [
598
598
  s("summary", de, [
599
599
  t[5] || (t[5] = s("span", { class: "thinking-bar-execution-details-title" }, "调用工具", -1)),
600
- s("span", he, a(Ot(i)), 1),
600
+ s("span", he, a(zt(i)), 1),
601
601
  t[6] || (t[6] = s("span", { class: "thinking-bar-execution-details-caret" }, "▾", -1))
602
602
  ]),
603
603
  s("div", ge, [
604
- P(i) ? (r(), o("pre", ke, a(P(i)), 1)) : u("", !0),
605
- (r(!0), o(d, null, m(I(i), (n) => (r(), o("details", {
604
+ I(i) ? (r(), o("pre", ke, a(I(i)), 1)) : u("", !0),
605
+ (r(!0), o(d, null, m(P(i), (n) => (r(), o("details", {
606
606
  key: n.id,
607
607
  class: "thinking-bar-tool-call",
608
608
  open: rt(n)
609
609
  }, [
610
610
  s("summary", fe, [
611
611
  s("div", me, [
612
- s("span", pe, a(N(n)), 1),
613
- n.name !== N(n) ? (r(), o("span", ye, a(n.name), 1)) : u("", !0)
612
+ s("span", pe, a(H(n)), 1),
613
+ n.name !== H(n) ? (r(), o("span", ye, a(n.name), 1)) : u("", !0)
614
614
  ]),
615
615
  s("div", _e, [
616
616
  s("span", {
@@ -624,26 +624,26 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
624
624
  t[8] || (t[8] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 请求参数 ", -1)),
625
625
  s("pre", Te, a(n.argsText), 1)
626
626
  ])) : u("", !0),
627
- n.summary?.trim() ? (r(), o("div", Se, [
627
+ n.summary?.trim() ? (r(), o("div", xe, [
628
628
  t[9] || (t[9] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 执行摘要 ", -1)),
629
- s("pre", xe, a(n.summary), 1)
629
+ s("pre", Se, a(n.summary), 1)
630
630
  ])) : u("", !0),
631
631
  at(n) ? (r(), o("div", $e, [
632
632
  t[10] || (t[10] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 接口结果 ", -1)),
633
- E(n) ? (r(), o("div", Ae, [
633
+ R(n) ? (r(), o("div", Ae, [
634
634
  s("img", {
635
635
  class: "thinking-bar-tool-result-image",
636
- src: E(n) || "",
636
+ src: R(n) || "",
637
637
  alt: n.name
638
638
  }, null, 8, Be)
639
- ])) : F(n) ? (r(), o("iframe", {
639
+ ])) : E(n) ? (r(), o("iframe", {
640
640
  key: 1,
641
641
  class: "thinking-bar-tool-result-html",
642
- srcdoc: F(n) || "",
642
+ srcdoc: E(n) || "",
643
643
  title: n.name,
644
644
  sandbox: ""
645
- }, null, 8, Ce)) : y(n) ? (r(), o("div", Re, [
646
- s("table", Ee, [
645
+ }, null, 8, Ce)) : y(n) ? (r(), o("div", Fe, [
646
+ s("table", Re, [
647
647
  s("thead", null, [
648
648
  s("tr", null, [
649
649
  (r(!0), o(d, null, m(y(
@@ -663,17 +663,17 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
663
663
  ]))), 128))
664
664
  ])
665
665
  ])
666
- ])) : x(n) ? (r(), o("pre", Fe, a(x(n)), 1)) : u("", !0)
666
+ ])) : S(n) ? (r(), o("pre", Ee, a(S(n)), 1)) : u("", !0)
667
667
  ])) : u("", !0),
668
- st(n.trace) ? (r(), o("div", Oe, [
668
+ st(n.trace) ? (r(), o("div", ze, [
669
669
  t[11] || (t[11] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 执行轨迹 ", -1)),
670
- s("pre", ze, a(st(n.trace)), 1)
670
+ s("pre", Oe, a(st(n.trace)), 1)
671
671
  ])) : u("", !0),
672
672
  n.errorCode ? (r(), o("div", De, [
673
673
  t[12] || (t[12] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 错误码 ", -1)),
674
- s("pre", He, a(n.errorCode), 1)
674
+ s("pre", Me, a(n.errorCode), 1)
675
675
  ])) : u("", !0),
676
- Rt(n) && nt(i).length > 0 ? (r(), o("div", Me, [
676
+ Ft(n) && nt(i).length > 0 ? (r(), o("div", Ne, [
677
677
  t[16] || (t[16] = s("div", { class: "thinking-bar-nested-tools-label" }, " 知识库内部步骤 ", -1)),
678
678
  (r(!0), o(d, null, m(nt(
679
679
  i
@@ -681,25 +681,25 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
681
681
  key: l.id,
682
682
  class: "thinking-bar-tool-call thinking-bar-tool-call--nested"
683
683
  }, [
684
- s("summary", Ne, [
684
+ s("summary", He, [
685
685
  s("div", Le, [
686
- s("span", je, a(N(l)), 1)
686
+ s("span", je, a(H(l)), 1)
687
687
  ]),
688
- s("div", Pe, [
688
+ s("div", Ie, [
689
689
  s("span", {
690
690
  class: B(["thinking-bar-tool-call-status", `is-${l.status}`])
691
691
  }, a(it(l.status)), 3),
692
692
  t[13] || (t[13] = s("span", { class: "thinking-bar-tool-call-caret" }, "▾", -1))
693
693
  ])
694
694
  ]),
695
- s("div", Ie, [
695
+ s("div", Pe, [
696
696
  l.argsText?.trim() ? (r(), o("div", Ve, [
697
697
  t[14] || (t[14] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 请求参数 ", -1)),
698
698
  s("pre", qe, a(l.argsText), 1)
699
699
  ])) : u("", !0),
700
- x(l) ? (r(), o("div", Ke, [
700
+ S(l) ? (r(), o("div", Ke, [
701
701
  t[15] || (t[15] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 接口结果 ", -1)),
702
- s("pre", Je, a(x(l)), 1)
702
+ s("pre", Je, a(S(l)), 1)
703
703
  ])) : u("", !0)
704
704
  ])
705
705
  ]))), 128))
@@ -718,14 +718,14 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
718
718
  ])
719
719
  ])) : u("", !0)
720
720
  ])) : (r(), o(d, { key: 1 }, [
721
- i.chatItems && i.chatItems.length > 0 ? (r(), o("div", Ye, [
721
+ i.chatItems && i.chatItems.length > 0 ? (r(), o("div", Ge, [
722
722
  (r(!0), o(d, null, m(i.chatItems, (n) => (r(), o("div", {
723
723
  key: n.id,
724
724
  class: "thinking-bar-chat-item"
725
725
  }, [
726
- n.type === "text" && n.text.trim() ? (r(), o("div", Ge, [
727
- W(M(mt), {
728
- "model-value": M(Jt)(n.text),
726
+ n.type === "text" && n.text.trim() ? (r(), o("div", Qe, [
727
+ W(N(mt), {
728
+ "model-value": N(Jt)(n.text),
729
729
  theme: "dark",
730
730
  "preview-theme": "github",
731
731
  "code-theme": "github",
@@ -736,9 +736,9 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
736
736
  class: "thinking-bar-tool-call",
737
737
  open: rt(n.toolCall)
738
738
  }, [
739
- s("summary", Xe, [
739
+ s("summary", Ye, [
740
740
  s("div", Ze, [
741
- s("span", tn, a(N(n.toolCall)), 1)
741
+ s("span", tn, a(H(n.toolCall)), 1)
742
742
  ]),
743
743
  s("div", en, [
744
744
  s("span", {
@@ -750,16 +750,16 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
750
750
  s("div", nn, [
751
751
  at(n.toolCall) ? (r(), o("div", sn, [
752
752
  t[19] || (t[19] = s("div", { class: "thinking-bar-tool-call-block-title" }, " 结果 ", -1)),
753
- E(n.toolCall) ? (r(), o("div", rn, [
753
+ R(n.toolCall) ? (r(), o("div", rn, [
754
754
  s("img", {
755
755
  class: "thinking-bar-tool-result-image",
756
- src: E(n.toolCall) || "",
756
+ src: R(n.toolCall) || "",
757
757
  alt: n.toolCall.name
758
758
  }, null, 8, on)
759
- ])) : F(n.toolCall) ? (r(), o("iframe", {
759
+ ])) : E(n.toolCall) ? (r(), o("iframe", {
760
760
  key: 1,
761
761
  class: "thinking-bar-tool-result-html",
762
- srcdoc: F(n.toolCall) || "",
762
+ srcdoc: E(n.toolCall) || "",
763
763
  title: n.toolCall.name,
764
764
  sandbox: ""
765
765
  }, null, 8, ln)) : y(n.toolCall) ? (r(), o("div", an, [
@@ -785,14 +785,14 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
785
785
  ]))), 128))
786
786
  ])
787
787
  ])
788
- ])) : x(n.toolCall) ? (r(), o("pre", un, a(x(n.toolCall)), 1)) : u("", !0)
788
+ ])) : S(n.toolCall) ? (r(), o("pre", un, a(S(n.toolCall)), 1)) : u("", !0)
789
789
  ])) : u("", !0)
790
790
  ])
791
- ], 8, Qe)) : u("", !0)
791
+ ], 8, Xe)) : u("", !0)
792
792
  ]))), 128))
793
793
  ])) : i.content ? (r(), o("div", dn, [
794
- W(M(mt), {
795
- "model-value": M(Ut)(i.content ?? ""),
794
+ W(N(mt), {
795
+ "model-value": N(Ut)(i.content ?? ""),
796
796
  theme: "dark",
797
797
  "preview-theme": "github",
798
798
  "code-theme": "github",
@@ -826,7 +826,7 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
826
826
  s("div", _n, [
827
827
  t[21] || (t[21] = s("div", { class: "thinking-bar-file-tree-head" }, "文件系统", -1)),
828
828
  s("div", vn, [
829
- (r(!0), o(d, null, m(Nt(i.id, i.files), (n) => (r(), o(d, {
829
+ (r(!0), o(d, null, m(Ht(i.id, i.files), (n) => (r(), o(d, {
830
830
  key: `${i.id}:${n.path}`
831
831
  }, [
832
832
  n.type === "directory" ? (r(), o("div", wn, [
@@ -836,11 +836,11 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
836
836
  style: ft({
837
837
  paddingLeft: `${n.depth * 14 + 10}px`
838
838
  }),
839
- onClick: (l) => Mt(i.id, n.path)
839
+ onClick: (l) => Nt(i.id, n.path)
840
840
  }, [
841
- s("span", Sn, a(ut(i.id, n.path) ? "▾" : "▸"), 1),
841
+ s("span", xn, a(ut(i.id, n.path) ? "▾" : "▸"), 1),
842
842
  t[20] || (t[20] = s("span", { class: "thinking-bar-tree-icon" }, "📁", -1)),
843
- s("span", xn, a(n.name), 1)
843
+ s("span", Sn, a(n.name), 1)
844
844
  ], 12, Tn)
845
845
  ])) : (r(), o("button", {
846
846
  key: 1,
@@ -859,27 +859,27 @@ const Gt = { class: "thinking-bar-header" }, Qt = { class: "thinking-bar-title-s
859
859
  ]),
860
860
  s("div", Cn, [
861
861
  k(i) ? (r(), o(d, { key: 0 }, [
862
- s("div", Rn, [
863
- s("div", En, [
864
- s("span", Fn, a(gt(k(i)?.path || "")), 1),
862
+ s("div", Fn, [
863
+ s("div", Rn, [
864
+ s("span", En, a(gt(k(i)?.path || "")), 1),
865
865
  s("span", null, a(k(i)?.path), 1)
866
866
  ]),
867
- U(k(i)?.path || "") ? (r(), o("span", On, " HTML 预览 ")) : u("", !0)
867
+ U(k(i)?.path || "") ? (r(), o("span", zn, " HTML 预览 ")) : u("", !0)
868
868
  ]),
869
- dt(k(i)?.path || "") ? (r(), o("div", zn, [
869
+ dt(k(i)?.path || "") ? (r(), o("div", On, [
870
870
  ht(k(i)) ? (r(), o("img", {
871
871
  key: 0,
872
872
  class: "thinking-bar-image-preview",
873
873
  src: ht(k(i)) || "",
874
874
  alt: k(i)?.name || "图片预览"
875
- }, null, 8, Dn)) : (r(), o("div", Hn, " 当前图片文件没有可直接渲染的内容。 "))
875
+ }, null, 8, Dn)) : (r(), o("div", Mn, " 当前图片文件没有可直接渲染的内容。 "))
876
876
  ])) : U(k(i)?.path || "") ? (r(), o("iframe", {
877
877
  key: 1,
878
878
  class: "thinking-bar-html-preview",
879
879
  srcdoc: J(k(i)),
880
880
  title: k(i)?.path,
881
881
  sandbox: ""
882
- }, null, 8, Mn)) : (r(), o("pre", Nn, a(J(k(i))), 1))
882
+ }, null, 8, Nn)) : (r(), o("pre", Hn, a(J(k(i))), 1))
883
883
  ], 64)) : (r(), o("div", Ln, " 还没选中文件,左边点一个看看。 "))
884
884
  ])
885
885
  ])