@levo-so/studio 0.3.2 → 0.3.4

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.
@@ -2,13 +2,13 @@
2
2
  import { _ as e, a as t, c as n, f as r, g as i, h as a, i as o, l as s, m as c, n as l, o as u, r as d, s as f, t as p, u as m, v as h } from "./pillChrome-CrJ9a5vj.js";
3
3
  import { Children as g, createContext as _, isValidElement as v, useCallback as y, useContext as b, useEffect as x, useLayoutEffect as S, useRef as C, useState as w } from "react";
4
4
  import { Fragment as T, jsx as E, jsxs as D } from "react/jsx-runtime";
5
- import { ArrowUp as O, Check as k, ChevronDown as A, Copy as j, MessageSquarePlus as M, Mic as ee, RefreshCw as N, Sparkles as te, Square as P, X as F } from "lucide-react";
6
- import { ActionBarPrimitive as I, AssistantRuntimeProvider as L, ComposerPrimitive as R, MessagePrimitive as z, ThreadPrimitive as B, WebSpeechDictationAdapter as ne, useAssistantRuntime as V, useMessage as H, useThread as U, useThreadComposer as re } from "@assistant-ui/react";
5
+ import { ArrowUp as O, Check as k, ChevronDown as ee, Copy as A, MessageSquarePlus as j, Mic as te, RefreshCw as M, Sparkles as ne, Square as N, X as P } from "lucide-react";
6
+ import { ActionBarPrimitive as F, AssistantRuntimeProvider as I, ComposerPrimitive as L, MessagePrimitive as R, ThreadPrimitive as z, WebSpeechDictationAdapter as re, useAui as B, useAuiState as V } from "@assistant-ui/react";
7
7
  import { AssistantChatTransport as ie, useChatRuntime as ae } from "@assistant-ui/react-ai-sdk";
8
8
  import { MarkdownTextPrimitive as oe } from "@assistant-ui/react-markdown";
9
9
  import se from "remark-gfm";
10
10
  //#region ../../libraries/ai-chat/src/FollowUpChips.tsx
11
- var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipClassName: i }) => {
11
+ var H = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipClassName: i }) => {
12
12
  if (e.length === 0) return null;
13
13
  let a = [
14
14
  "rounded-full border border-zinc-200 bg-white text-zinc-700",
@@ -64,12 +64,12 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
64
64
  return Array.isArray(t) ? (n(t.filter((e) => typeof e == "string")), !0) : !1;
65
65
  }, [])
66
66
  };
67
- }, de = (e) => e instanceof Error && e.message.includes("intelligence.site_agent.NO_ACTIVE_AGENT"), G = _({ agentUnavailable: !1 }), fe = () => b(G), pe = (...e) => e.filter(Boolean).join(" "), me = "inline-flex items-center justify-center gap-1.5 transition-all duration-200", he = "rounded-full border border-zinc-200 bg-white/95 px-3 py-1.5 font-medium text-xs text-zinc-500 shadow-lg backdrop-blur-sm hover:text-zinc-900", ge = ({ onClick: e, isRunning: t = !1, iconOnly: n = !1, className: r = he }) => /* @__PURE__ */ D("button", {
67
+ }, de = (e) => e instanceof Error && e.message.includes("intelligence.site_agent.NO_ACTIVE_AGENT"), U = _({ agentUnavailable: !1 }), fe = () => b(U), pe = (...e) => e.filter(Boolean).join(" "), me = "inline-flex items-center justify-center gap-1.5 transition-all duration-200", he = "rounded-full border border-zinc-200 bg-white/95 px-3 py-1.5 font-medium text-xs text-zinc-500 shadow-lg backdrop-blur-sm hover:text-zinc-900", ge = ({ onClick: e, isRunning: t = !1, iconOnly: n = !1, className: r = he }) => /* @__PURE__ */ D("button", {
68
68
  type: "button",
69
69
  "aria-label": "Scroll to bottom",
70
70
  onClick: e,
71
71
  className: pe(me, r),
72
- children: [/* @__PURE__ */ E(A, { className: "h-3 w-3" }), !n && (t ? "New messages" : "Scroll to bottom")]
72
+ children: [/* @__PURE__ */ E(ee, { className: "h-3 w-3" }), !n && (t ? "New messages" : "Scroll to bottom")]
73
73
  }), _e = ({ endpoint: e, headers: t, fallback: n, enabled: r = !0 }) => {
74
74
  let [i, a] = w(null), o = t ? JSON.stringify(t) : "", s = C(t);
75
75
  s.current = t;
@@ -151,7 +151,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
151
151
  });
152
152
  }
153
153
  };
154
- }, K = (...e) => e.filter(Boolean).join(" "), q = ({ onStop: e }) => /* @__PURE__ */ E("button", {
154
+ }, W = (...e) => e.filter(Boolean).join(" "), G = ({ onStop: e }) => /* @__PURE__ */ E("button", {
155
155
  type: "button",
156
156
  onClick: e,
157
157
  "aria-label": "Stop generating",
@@ -160,20 +160,20 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
160
160
  backgroundColor: "var(--color-brand, #0a0a0a)",
161
161
  color: "var(--color-brand-foreground, #fff)"
162
162
  },
163
- children: /* @__PURE__ */ E(P, { className: "h-3.5 w-3.5 fill-current" })
164
- }), J = () => /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(R.If, {
163
+ children: /* @__PURE__ */ E(N, { className: "h-3.5 w-3.5 fill-current" })
164
+ }), K = () => /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(L.If, {
165
165
  dictation: !1,
166
- children: /* @__PURE__ */ E(R.Dictate, {
166
+ children: /* @__PURE__ */ E(L.Dictate, {
167
167
  className: "flex h-8 w-8 items-center justify-center rounded-md text-zinc-500 transition-colors hover:bg-zinc-100 hover:text-zinc-900",
168
- children: /* @__PURE__ */ E(ee, { className: "h-4 w-4" })
168
+ children: /* @__PURE__ */ E(te, { className: "h-4 w-4" })
169
169
  })
170
- }), /* @__PURE__ */ E(R.If, {
170
+ }), /* @__PURE__ */ E(L.If, {
171
171
  dictation: !0,
172
- children: /* @__PURE__ */ E(R.StopDictation, {
172
+ children: /* @__PURE__ */ E(L.StopDictation, {
173
173
  className: "flex h-8 w-8 animate-pulse items-center justify-center rounded-md bg-red-500/15 text-red-500 transition-colors hover:bg-red-500/25",
174
- children: /* @__PURE__ */ E(P, { className: "h-3 w-3 fill-current" })
174
+ children: /* @__PURE__ */ E(N, { className: "h-3 w-3 fill-current" })
175
175
  })
176
- })] }), xe = () => /* @__PURE__ */ E(R.Send, {
176
+ })] }), xe = () => /* @__PURE__ */ E(L.Send, {
177
177
  "aria-label": "Send message",
178
178
  className: "flex h-9 w-9 items-center justify-center rounded-md shadow-md transition-all duration-300 hover:scale-110 active:scale-95 disabled:cursor-not-allowed disabled:opacity-40 disabled:shadow-none disabled:hover:scale-100",
179
179
  style: {
@@ -187,9 +187,9 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
187
187
  };
188
188
  return e === "expanded" ? /* @__PURE__ */ D("div", {
189
189
  className: "rounded-lg border border-zinc-200 bg-white shadow-sm transition-colors focus-within:border-[var(--color-brand,#a1a1aa)]",
190
- children: [/* @__PURE__ */ E(R.Input, {
190
+ children: [/* @__PURE__ */ E(L.Input, {
191
191
  "data-ai-chat-composer": "",
192
- className: K("ai-chat-textarea w-full resize-none overflow-y-auto bg-transparent px-6 pt-4 text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", "max-h-[160px]"),
192
+ className: W("ai-chat-textarea w-full resize-none overflow-y-auto bg-transparent px-6 pt-4 text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", "max-h-[160px]"),
193
193
  placeholder: "Ask anything about this site…",
194
194
  rows: 1,
195
195
  submitMode: "enter",
@@ -201,14 +201,14 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
201
201
  onKeyDown: r
202
202
  }), /* @__PURE__ */ D("div", {
203
203
  className: "flex items-center justify-between px-3 pt-1 pb-2",
204
- children: [/* @__PURE__ */ E(J, {}), t ? /* @__PURE__ */ E(q, { onStop: n }) : /* @__PURE__ */ E(xe, {})]
204
+ children: [/* @__PURE__ */ E(K, {}), t ? /* @__PURE__ */ E(G, { onStop: n }) : /* @__PURE__ */ E(xe, {})]
205
205
  })]
206
206
  }) : /* @__PURE__ */ D("div", {
207
207
  className: "flex items-end gap-2 rounded-lg border border-zinc-200 bg-white p-2 shadow-sm transition-colors focus-within:border-[var(--color-brand,#a1a1aa)]",
208
208
  children: [
209
- /* @__PURE__ */ E(R.Input, {
209
+ /* @__PURE__ */ E(L.Input, {
210
210
  "data-ai-chat-composer": "",
211
- className: K("ai-chat-textarea min-w-0 flex-1 resize-none overflow-y-auto bg-transparent px-2 py-1.5 text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", "max-h-[120px]"),
211
+ className: W("ai-chat-textarea min-w-0 flex-1 resize-none overflow-y-auto bg-transparent px-2 py-1.5 text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", "max-h-[120px]"),
212
212
  placeholder: "Ask a follow-up…",
213
213
  rows: 1,
214
214
  submitMode: "enter",
@@ -219,32 +219,32 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
219
219
  onInput: (e) => i(e.currentTarget),
220
220
  onKeyDown: r
221
221
  }),
222
- /* @__PURE__ */ E(J, {}),
223
- t ? /* @__PURE__ */ E(q, { onStop: n }) : /* @__PURE__ */ E(xe, {})
222
+ /* @__PURE__ */ E(K, {}),
223
+ t ? /* @__PURE__ */ E(G, { onStop: n }) : /* @__PURE__ */ E(xe, {})
224
224
  ]
225
225
  });
226
- }, Ce = "rounded-2xl border border-zinc-200 bg-zinc-100 px-3.5 py-2.5", we = "ai-chat-textarea w-full resize-none bg-transparent text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", Te = "rounded-md px-2 py-1 text-xs text-zinc-500 transition-colors hover:bg-zinc-100", Ee = "rounded-md px-2 py-1 text-xs transition-opacity hover:opacity-80", De = ({ autoGrowMax: e, boxClassName: t = Ce, inputClassName: n = we, cancelClassName: r = Te, sendClassName: a = Ee, sendStyle: o }) => /* @__PURE__ */ E(z.Root, {
226
+ }, Ce = "rounded-2xl border border-zinc-200 bg-zinc-100 px-3.5 py-2.5", we = "ai-chat-textarea w-full resize-none bg-transparent text-base text-zinc-900 leading-relaxed placeholder:text-zinc-500 focus:outline-none", Te = "rounded-md px-2 py-1 text-xs text-zinc-500 transition-colors hover:bg-zinc-100", Ee = "rounded-md px-2 py-1 text-xs transition-opacity hover:opacity-80", De = ({ autoGrowMax: e, boxClassName: t = Ce, inputClassName: n = we, cancelClassName: r = Te, sendClassName: a = Ee, sendStyle: o }) => /* @__PURE__ */ E(R.Root, {
227
227
  className: "mb-4 pr-2 pl-0",
228
- children: /* @__PURE__ */ D(R.Root, { children: [/* @__PURE__ */ E("div", {
228
+ children: /* @__PURE__ */ D(L.Root, { children: [/* @__PURE__ */ E("div", {
229
229
  className: t,
230
- children: /* @__PURE__ */ E(R.Input, {
230
+ children: /* @__PURE__ */ E(L.Input, {
231
231
  className: n,
232
232
  rows: 1,
233
233
  onInput: (t) => i(t.currentTarget, e)
234
234
  })
235
235
  }), /* @__PURE__ */ D("div", {
236
236
  className: "mt-2 flex justify-end gap-1.5",
237
- children: [/* @__PURE__ */ E(R.Cancel, {
237
+ children: [/* @__PURE__ */ E(L.Cancel, {
238
238
  className: r,
239
239
  children: "Cancel"
240
- }), /* @__PURE__ */ E(R.Send, {
240
+ }), /* @__PURE__ */ E(L.Send, {
241
241
  className: a,
242
242
  style: o,
243
243
  children: "Save"
244
244
  })]
245
245
  })] })
246
246
  }), Oe = ({ idleClassName: e = "text-zinc-500 hover:text-zinc-900", copiedClassName: t = "text-emerald-500", errorClassName: n = "text-rose-500", className: r = "rounded p-1.5 transition-colors", iconClassName: i = "h-3 w-3" }) => {
247
- let [a, o] = w("idle"), s = H();
247
+ let [a, o] = w("idle"), s = V((e) => e.message);
248
248
  x(() => {
249
249
  if (a === "idle") return;
250
250
  let e = setTimeout(() => o("idle"), 1500);
@@ -257,7 +257,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
257
257
  } catch {
258
258
  o("error");
259
259
  }
260
- }, l = a === "copied" ? t ?? e : a === "error" ? n ?? e : e, u = a === "copied" ? "Copied" : a === "error" ? "Copy failed" : "Copy message", d = a === "copied" ? k : a === "error" ? F : j;
260
+ }, l = a === "copied" ? t ?? e : a === "error" ? n ?? e : e, u = a === "copied" ? "Copied" : a === "error" ? "Copy failed" : "Copy message", d = a === "copied" ? k : a === "error" ? P : A;
261
261
  return /* @__PURE__ */ E("button", {
262
262
  type: "button",
263
263
  "aria-label": u,
@@ -285,7 +285,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
285
285
  n(!0), setTimeout(() => n(!1), 2e3);
286
286
  }).catch(() => {}),
287
287
  className: "ai-chat-code__copy flex items-center gap-1.5 rounded px-2 py-0.5 text-[10px] transition-colors",
288
- children: t ? /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(k, { className: "h-3 w-3 text-emerald-500" }), /* @__PURE__ */ E("span", { children: "Copied!" })] }) : /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(j, { className: "h-3 w-3" }), /* @__PURE__ */ E("span", { children: "Copy" })] })
288
+ children: t ? /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(k, { className: "h-3 w-3 text-emerald-500" }), /* @__PURE__ */ E("span", { children: "Copied!" })] }) : /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(A, { className: "h-3 w-3" }), /* @__PURE__ */ E("span", { children: "Copy" })] })
289
289
  })]
290
290
  }), /* @__PURE__ */ E("pre", {
291
291
  className: "ai-chat-code__pre overflow-x-auto px-4 py-4 font-mono text-sm leading-relaxed",
@@ -373,14 +373,14 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
373
373
  ]
374
374
  });
375
375
  }, Ie = () => null, Le = "max-w-none text-sm text-zinc-900 leading-relaxed [&>*:first-child]:mt-0 [&>*:last-child]:mb-0 [&_a:hover]:text-sky-700 [&_a]:break-words [&_a]:font-medium [&_a]:text-sky-600 [&_a]:underline [&_a]:underline-offset-2 [&_li]:text-sm [&_ol]:my-2 [&_ol]:list-decimal [&_ol]:pl-5 [&_p]:my-2 [&_p]:text-sm [&_strong]:font-semibold [&_ul]:my-2 [&_ul]:list-disc [&_ul]:pl-5", Re = "group pr-4 pb-6", ze = "mt-2 flex items-center gap-2 opacity-0 transition-opacity group-focus-within:opacity-100 group-hover:opacity-100", Be = "text-xs text-zinc-500/60", Ve = "rounded p-1.5 text-zinc-500 transition-colors hover:text-zinc-900", He = ({ tools: e = Ie, Parts: t, thinkingIndicator: n = /* @__PURE__ */ E(Fe, {}), rootClassName: r = Re, contentClassName: i = Le, metaClassName: a = ze, wrapContent: o, metaSlot: s, copyIdleClassName: c, copyCopiedClassName: l, reloadClassName: u = Ve, timeClassName: d = Be, timeFormatOptions: f, readOnly: p = !1, belowContent: m }) => {
376
- let g = H(), _ = t ?? z.Content, v = g.status?.type === "running", y = /* @__PURE__ */ E("div", {
376
+ let g = V((e) => e.message), _ = t ?? R.Content, v = g.status?.type === "running", y = /* @__PURE__ */ E("div", {
377
377
  className: i,
378
378
  children: /* @__PURE__ */ E(_, { components: {
379
379
  Text: Me,
380
380
  tools: { Fallback: e }
381
381
  } })
382
382
  });
383
- return /* @__PURE__ */ E(z.Root, {
383
+ return /* @__PURE__ */ E(R.Root, {
384
384
  className: r,
385
385
  children: /* @__PURE__ */ D("div", {
386
386
  className: "flex min-w-0 flex-col",
@@ -402,14 +402,14 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
402
402
  children: h(g.createdAt, f)
403
403
  }),
404
404
  s,
405
- /* @__PURE__ */ D(I.Root, {
405
+ /* @__PURE__ */ D(F.Root, {
406
406
  className: "flex items-center gap-0.5",
407
407
  children: [/* @__PURE__ */ E(Oe, {
408
408
  idleClassName: c,
409
409
  copiedClassName: l
410
- }), !p && /* @__PURE__ */ E(I.Reload, {
410
+ }), !p && /* @__PURE__ */ E(F.Reload, {
411
411
  className: u,
412
- children: /* @__PURE__ */ E(N, { className: "h-3 w-3" })
412
+ children: /* @__PURE__ */ E(M, { className: "h-3 w-3" })
413
413
  })]
414
414
  })
415
415
  ]
@@ -418,27 +418,27 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
418
418
  })
419
419
  });
420
420
  }, Ue = "group flex flex-col items-end pb-4 pl-12", We = "rounded-2xl border border-zinc-200 bg-zinc-100 px-3.5 py-2.5 text-sm text-zinc-900 leading-relaxed", Ge = "mt-1 flex items-center gap-2 opacity-0 transition-opacity group-focus-within:opacity-100 group-hover:opacity-100", Ke = "text-xs text-zinc-500/60", qe = "rounded px-2 py-1 font-medium text-xs text-zinc-500 transition-colors hover:text-zinc-900", Je = ({ attachmentsSlot: e, rootClassName: t = Ue, bubbleClassName: n = We, contentSlot: r, metaClassName: i = Ge, timeClassName: a = Ke, editClassName: o = qe, copyIdleClassName: s, copyCopiedClassName: c, timeFormatOptions: l, readOnly: u = !1 }) => {
421
- let d = H();
422
- return /* @__PURE__ */ D(z.Root, {
421
+ let d = V((e) => e.message);
422
+ return /* @__PURE__ */ D(R.Root, {
423
423
  className: t,
424
424
  "data-user-message": "true",
425
425
  children: [
426
426
  e,
427
427
  /* @__PURE__ */ E("div", {
428
428
  className: n,
429
- children: r ?? /* @__PURE__ */ E(z.Content, {})
429
+ children: r ?? /* @__PURE__ */ E(R.Content, {})
430
430
  }),
431
431
  /* @__PURE__ */ D("div", {
432
432
  className: i,
433
433
  children: [/* @__PURE__ */ E("span", {
434
434
  className: a,
435
435
  children: h(d.createdAt, l)
436
- }), /* @__PURE__ */ D(I.Root, {
436
+ }), /* @__PURE__ */ D(F.Root, {
437
437
  className: "flex items-center gap-0.5",
438
438
  children: [/* @__PURE__ */ E(Oe, {
439
439
  idleClassName: s,
440
440
  copiedClassName: c
441
- }), !u && /* @__PURE__ */ E(I.Edit, {
441
+ }), !u && /* @__PURE__ */ E(F.Edit, {
442
442
  className: o,
443
443
  children: "Edit"
444
444
  })]
@@ -460,7 +460,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
460
460
  "w-2/3",
461
461
  "w-3/5"
462
462
  ], Qe = ({ workspaceId: t, siteName: n, siteLogo: r, apiBaseUrl: i, authHeaders: a, agentId: o, followUps: s, hideComposer: c = !1 }) => {
463
- let l = V(), u = U((e) => e.isRunning), { agentUnavailable: d } = fe(), f = C(null), { isAtBottom: p, scrollToBottom: m } = be({
463
+ let l = B(), u = V((e) => e.thread.isRunning), { agentUnavailable: d } = fe(), f = C(null), { isAtBottom: p, scrollToBottom: m } = be({
464
464
  viewportRef: f,
465
465
  isRunning: u
466
466
  }), h = _e({
@@ -471,7 +471,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
471
471
  } : void 0,
472
472
  fallback: Xe
473
473
  }), g = y((t) => {
474
- e(l.thread.composer, t);
474
+ e(l.thread.composer(), t);
475
475
  }, [l]), _ = y(() => l.thread.cancelRun(), [l]), v = C(u);
476
476
  return x(() => {
477
477
  v.current = u;
@@ -480,10 +480,10 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
480
480
  e.key !== "Escape" || e.isComposing || !v.current || (e.preventDefault(), e.stopImmediatePropagation(), l.thread.cancelRun());
481
481
  };
482
482
  return window.addEventListener("keydown", e, !0), () => window.removeEventListener("keydown", e, !0);
483
- }, [l]), /* @__PURE__ */ D(B.Root, {
483
+ }, [l]), /* @__PURE__ */ D(z.Root, {
484
484
  className: "relative flex flex-1 flex-col overflow-hidden",
485
485
  children: [
486
- /* @__PURE__ */ E(B.If, {
486
+ /* @__PURE__ */ E(z.If, {
487
487
  empty: !0,
488
488
  children: /* @__PURE__ */ E("div", {
489
489
  className: "pointer-events-none absolute inset-0 z-0 overflow-hidden",
@@ -498,7 +498,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
498
498
  className: "relative z-20 shrink-0 border-amber-200 border-b bg-amber-50 px-4 py-2.5 text-amber-800 text-xs",
499
499
  children: "This conversation is no longer available. Please refresh the page to start a new chat."
500
500
  }),
501
- /* @__PURE__ */ D(B.Viewport, {
501
+ /* @__PURE__ */ D(z.Viewport, {
502
502
  ref: f,
503
503
  turnAnchor: "top",
504
504
  className: "relative z-10 flex-1 overflow-y-auto",
@@ -506,7 +506,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
506
506
  scrollToBottomOnRunStart: !1,
507
507
  scrollToBottomOnInitialize: !1,
508
508
  scrollToBottomOnThreadSwitch: !1,
509
- children: [/* @__PURE__ */ E(B.Empty, { children: /* @__PURE__ */ D("div", {
509
+ children: [/* @__PURE__ */ E(z.Empty, { children: /* @__PURE__ */ D("div", {
510
510
  className: "flex min-h-full flex-col items-center justify-center px-6 py-6",
511
511
  children: [/* @__PURE__ */ D("div", {
512
512
  className: "mb-5 flex flex-col items-center gap-2 text-center",
@@ -546,11 +546,11 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
546
546
  children: e
547
547
  }, e))
548
548
  })]
549
- }) }), /* @__PURE__ */ E(B.If, {
549
+ }) }), /* @__PURE__ */ E(z.If, {
550
550
  empty: !1,
551
551
  children: /* @__PURE__ */ E("div", {
552
552
  className: "ai-chat-kb-messages mx-auto max-w-3xl px-6 py-6 pt-8",
553
- children: /* @__PURE__ */ E(B.Messages, { components: {
553
+ children: /* @__PURE__ */ E(z.Messages, { components: {
554
554
  UserMessage: Je,
555
555
  AssistantMessage: He,
556
556
  EditComposer: Ye
@@ -573,14 +573,14 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
573
573
  }),
574
574
  s.length > 0 && !u && /* @__PURE__ */ E("div", {
575
575
  className: "mb-2",
576
- children: /* @__PURE__ */ E(W, {
576
+ children: /* @__PURE__ */ E(H, {
577
577
  chips: s,
578
578
  onSelect: g,
579
579
  size: "compact"
580
580
  })
581
581
  }),
582
- /* @__PURE__ */ D(R.Root, { children: [
583
- /* @__PURE__ */ E(B.If, {
582
+ /* @__PURE__ */ D(L.Root, { children: [
583
+ /* @__PURE__ */ E(z.If, {
584
584
  empty: !0,
585
585
  children: /* @__PURE__ */ E(Se, {
586
586
  variant: "expanded",
@@ -588,7 +588,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
588
588
  onStop: _
589
589
  })
590
590
  }),
591
- /* @__PURE__ */ E(B.If, {
591
+ /* @__PURE__ */ E(z.If, {
592
592
  empty: !1,
593
593
  children: /* @__PURE__ */ E(Se, {
594
594
  variant: "compact",
@@ -596,7 +596,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
596
596
  onStop: _
597
597
  })
598
598
  }),
599
- /* @__PURE__ */ E(R.If, {
599
+ /* @__PURE__ */ E(L.If, {
600
600
  dictation: !0,
601
601
  children: /* @__PURE__ */ D("div", {
602
602
  className: "mt-2 flex items-center justify-center gap-2",
@@ -607,7 +607,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
607
607
  })
608
608
  })
609
609
  ] }),
610
- /* @__PURE__ */ E(B.If, {
610
+ /* @__PURE__ */ E(z.If, {
611
611
  empty: !1,
612
612
  children: /* @__PURE__ */ E("p", {
613
613
  className: "mt-2 text-center text-[10px] text-zinc-500/70",
@@ -619,31 +619,32 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
619
619
  })
620
620
  ]
621
621
  });
622
- }, Y = 4096, $e = 400, et = 300, tt = 2e3, nt = (e) => document.querySelector(e)?.content?.trim() || void 0, rt = (e) => {
622
+ }, q = 4096, $e = 400, et = 300, tt = 2e3, nt = (e) => document.querySelector(e)?.content?.trim() || void 0, J = (e) => {
623
623
  for (let t of e) {
624
624
  let e = nt(t);
625
625
  if (e) return e;
626
626
  }
627
- }, it = (e, t) => e.length > t ? `${e.slice(0, t - 1).trimEnd()}…` : e, X = (e) => JSON.stringify(e).length, at = () => {
627
+ }, rt = (e, t) => e.length > t ? `${e.slice(0, t - 1).trimEnd()}…` : e, Y = (e) => JSON.stringify(e).length, it = () => {
628
628
  if (typeof window > "u" || typeof document > "u") return;
629
629
  let e = {}, t = window.location?.href;
630
630
  t && (e.url = t);
631
- let n = document.title?.trim() || rt(["meta[property=\"og:title\"]", "meta[name=\"twitter:title\"]"]);
632
- n && (e.page_title = it(n, et));
633
- let r = rt([
631
+ let n = document.title?.trim() || J(["meta[property=\"og:title\"]", "meta[name=\"twitter:title\"]"]);
632
+ n && (e.page_title = rt(n, et));
633
+ let r = J([
634
634
  "meta[name=\"description\"]",
635
635
  "meta[property=\"og:description\"]",
636
636
  "meta[name=\"twitter:description\"]"
637
637
  ]);
638
- r && (e.description = it(r, $e));
638
+ r && (e.description = rt(r, $e));
639
639
  let i = document.referrer?.trim();
640
- if (i && (e.referrer = i), Object.keys(e).length !== 0) return e.description && X(e) > Y && delete e.description, e.referrer && X(e) > Y && delete e.referrer, e.url && X(e) > Y && (e.url = e.url.slice(0, tt)), e;
641
- }, ot = ({ workspaceId: e, siteName: t, siteLogo: n, agentId: r, apiBaseUrl: i, authHeaders: a, children: o }) => {
640
+ if (i && (e.referrer = i), Object.keys(e).length !== 0) return e.description && Y(e) > q && delete e.description, e.referrer && Y(e) > q && delete e.referrer, e.url && Y(e) > q && (e.url = e.url.slice(0, tt)), e;
641
+ }, at = ({ workspaceId: e, siteName: t, siteLogo: n, agentId: r, apiBaseUrl: i, authHeaders: a, children: o }) => {
642
642
  let s = C(e);
643
643
  s.current = e;
644
644
  let c = C(r);
645
645
  c.current = r;
646
646
  let { followUps: l, clearOnSend: u, handleData: d } = ue(), [f, p] = w(!1), { conversationIdRef: m, handleFinish: h, reset: g } = le(e), _ = ae({
647
+ joinStrategy: "none",
647
648
  transport: ce({
648
649
  api: `${i}/stream`,
649
650
  credentials: "include",
@@ -661,11 +662,11 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
661
662
  workspace_id: s.current
662
663
  };
663
664
  m.current && (t.conversation_id = m.current), c.current && (t.agent_id = c.current);
664
- let n = at();
665
+ let n = it();
665
666
  return n && (t.context = n), t;
666
667
  }
667
668
  }),
668
- adapters: { dictation: new ne() },
669
+ adapters: { dictation: new re({ interimResults: !1 }) },
669
670
  onData: d,
670
671
  onFinish: h,
671
672
  onError: (e) => {
@@ -680,9 +681,9 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
680
681
  g,
681
682
  u
682
683
  ]);
683
- return /* @__PURE__ */ E(L, {
684
+ return /* @__PURE__ */ E(I, {
684
685
  runtime: _,
685
- children: /* @__PURE__ */ E(G.Provider, {
686
+ children: /* @__PURE__ */ E(U.Provider, {
686
687
  value: { agentUnavailable: f },
687
688
  children: o ? o({
688
689
  followUps: l,
@@ -698,7 +699,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
698
699
  })
699
700
  })
700
701
  });
701
- }, st = (e, t, n) => {
702
+ }, ot = (e, t, n) => {
702
703
  x(() => {
703
704
  if (!e) return;
704
705
  let r = (e) => {
@@ -716,16 +717,16 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
716
717
  t,
717
718
  n
718
719
  ]);
719
- }, Z = "(max-width: 639px)", ct = () => {
720
- let [e, t] = w(() => typeof window < "u" && window.matchMedia(Z).matches);
720
+ }, X = "(max-width: 639px)", Z = () => {
721
+ let [e, t] = w(() => typeof window < "u" && window.matchMedia(X).matches);
721
722
  return x(() => {
722
- let e = window.matchMedia(Z), n = () => t(e.matches);
723
+ let e = window.matchMedia(X), n = () => t(e.matches);
723
724
  return n(), e.addEventListener("change", n), () => e.removeEventListener("change", n);
724
725
  }, []), e;
725
- }, lt = (e, t) => {
726
+ }, st = (e, t) => {
726
727
  x(() => {
727
728
  let n = t.current, r = window.visualViewport;
728
- if (!e || !n || !r || !window.matchMedia(Z).matches) return;
729
+ if (!e || !n || !r || !window.matchMedia(X).matches) return;
729
730
  let i = () => {
730
731
  n.style.setProperty("--ai-vv-top", `${r.offsetTop}px`), n.style.setProperty("--ai-vv-height", `${r.height}px`);
731
732
  };
@@ -733,7 +734,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
733
734
  r.removeEventListener("resize", i), r.removeEventListener("scroll", i), n.style.removeProperty("--ai-vv-top"), n.style.removeProperty("--ai-vv-height");
734
735
  };
735
736
  }, [e, t]);
736
- }, ut = (e, t, n) => {
737
+ }, ct = (e, t, n) => {
737
738
  x(() => {
738
739
  if (!e) return;
739
740
  let r = (e) => {
@@ -746,43 +747,43 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
746
747
  t,
747
748
  n
748
749
  ]);
749
- }, Q = (...e) => e.filter(Boolean).join(" "), dt = ({ open: e, onToggle: i, askLabel: a, panelId: h, initialDraft: g }) => {
750
- let _ = V(), v = ct(), y = U((e) => e.isRunning), b = U((e) => e.messages.length > 0), k = re((e) => e.text), A = k.trim().length > 0, [j, M] = w(!1);
750
+ }, Q = (...e) => e.filter(Boolean).join(" "), lt = ({ open: e, onToggle: i, askLabel: a, panelId: h, initialDraft: g }) => {
751
+ let _ = B(), v = Z(), y = V((e) => e.thread.isRunning), b = V((e) => e.thread.messages.length > 0), k = V((e) => e.composer.text), ee = k.trim().length > 0, [A, j] = w(!1);
751
752
  x(() => {
752
- g && _.thread.composer.setText(g);
753
+ g && _.thread.composer().setText(g);
753
754
  }, []);
754
- let N = C(null), F = C(null), I = C(!1);
755
+ let M = C(null), P = C(null), F = C(!1);
755
756
  S(() => {
756
- let e = N.current;
757
- !e || document.activeElement === e || (I.current = !0, e.focus({ preventScroll: !0 }));
757
+ let e = M.current;
758
+ !e || document.activeElement === e || (F.current = !0, e.focus({ preventScroll: !0 }));
758
759
  }, []), S(() => {
759
- let t = N.current, n = F.current;
760
+ let t = M.current, n = P.current;
760
761
  if (!(!t || !n)) {
761
762
  if (!e) {
762
- t.style.height = "", M(!1);
763
+ t.style.height = "", j(!1);
763
764
  return;
764
765
  }
765
- M(c(n, t));
766
+ j(c(n, t));
766
767
  }
767
768
  }, [k, e]);
768
- let L = C(e);
769
+ let I = C(e);
769
770
  x(() => {
770
- let t = L.current;
771
- L.current = e;
772
- let n = N.current;
771
+ let t = I.current;
772
+ I.current = e;
773
+ let n = M.current;
773
774
  e || !t || !n || document.activeElement === n && n.blur();
774
775
  }, [e]);
775
- let z = C(y);
776
+ let R = C(y);
776
777
  x(() => {
777
- let e = !z.current && y;
778
- z.current = y, v && e && N.current?.blur();
778
+ let e = !R.current && y;
779
+ R.current = y, v && e && M.current?.blur();
779
780
  }, [y, v]);
780
- let B = b ? "Continue conversation" : a;
781
+ let z = b ? "Continue conversation" : a;
781
782
  return /* @__PURE__ */ E("div", {
782
783
  className: Q(l, e ? f : n),
783
784
  children: /* @__PURE__ */ D("div", {
784
- ref: F,
785
- className: Q(m, j && "ai-chat-pill-surface--stacked"),
785
+ ref: P,
786
+ className: Q(m, A && "ai-chat-pill-surface--stacked"),
786
787
  children: [
787
788
  /* @__PURE__ */ E("button", {
788
789
  type: "button",
@@ -791,23 +792,23 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
791
792
  "aria-expanded": e,
792
793
  "aria-controls": h,
793
794
  className: s,
794
- children: /* @__PURE__ */ E(te, { className: "h-5 w-5" })
795
+ children: /* @__PURE__ */ E(ne, { className: "h-5 w-5" })
795
796
  }),
796
797
  /* @__PURE__ */ D("div", {
797
798
  className: d,
798
- children: [/* @__PURE__ */ E(R.Input, {
799
- ref: N,
799
+ children: [/* @__PURE__ */ E(L.Input, {
800
+ ref: M,
800
801
  "data-ai-chat-composer": "",
801
802
  placeholder: e ? "Ask anything…" : "",
802
803
  onFocus: () => {
803
- if (I.current) {
804
- I.current = !1;
804
+ if (F.current) {
805
+ F.current = !1;
805
806
  return;
806
807
  }
807
808
  e || i();
808
809
  },
809
810
  onKeyDown: (e) => {
810
- e.nativeEvent.isComposing || e.key !== "Enter" || e.shiftKey || (e.preventDefault(), !y && A && _.thread.composer.send());
811
+ e.nativeEvent.isComposing || e.key !== "Enter" || e.shiftKey || (e.preventDefault(), !y && ee && _.thread.composer().send());
811
812
  },
812
813
  rows: 1,
813
814
  submitMode: "enter",
@@ -822,24 +823,24 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
822
823
  }), /* @__PURE__ */ E("span", {
823
824
  className: Q(o, "transition-opacity duration-150", e && "opacity-0"),
824
825
  "aria-hidden": !0,
825
- children: B
826
+ children: z
826
827
  })]
827
828
  }),
828
829
  /* @__PURE__ */ D("div", {
829
830
  className: p,
830
- children: [e && /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(R.If, {
831
+ children: [e && /* @__PURE__ */ D(T, { children: [/* @__PURE__ */ E(L.If, {
831
832
  dictation: !1,
832
- children: /* @__PURE__ */ E(R.Dictate, {
833
+ children: /* @__PURE__ */ E(L.Dictate, {
833
834
  "aria-label": "Start dictation",
834
835
  className: "ai-chat-icon-btn flex h-11 w-11 flex-shrink-0 items-center justify-center rounded-full transition-colors active:scale-95",
835
- children: /* @__PURE__ */ E(ee, { className: "h-5 w-5" })
836
+ children: /* @__PURE__ */ E(te, { className: "h-5 w-5" })
836
837
  })
837
- }), /* @__PURE__ */ E(R.If, {
838
+ }), /* @__PURE__ */ E(L.If, {
838
839
  dictation: !0,
839
- children: /* @__PURE__ */ E(R.StopDictation, {
840
+ children: /* @__PURE__ */ E(L.StopDictation, {
840
841
  "aria-label": "Stop dictation",
841
842
  className: "flex h-11 w-11 flex-shrink-0 animate-pulse items-center justify-center rounded-full bg-red-500/15 text-red-500 transition-colors hover:bg-red-500/25",
842
- children: /* @__PURE__ */ E(P, { className: "h-4 w-4 fill-current" })
843
+ children: /* @__PURE__ */ E(N, { className: "h-4 w-4 fill-current" })
843
844
  })
844
845
  })] }), e ? y ? /* @__PURE__ */ E("button", {
845
846
  type: "button",
@@ -847,8 +848,8 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
847
848
  "aria-label": "Stop generating",
848
849
  className: t,
849
850
  style: u,
850
- children: /* @__PURE__ */ E(P, { className: "h-4 w-4 fill-current" })
851
- }) : /* @__PURE__ */ E(R.Send, {
851
+ children: /* @__PURE__ */ E(N, { className: "h-4 w-4 fill-current" })
852
+ }) : /* @__PURE__ */ E(L.Send, {
852
853
  "aria-label": "Send message",
853
854
  className: Q(t, "disabled:cursor-not-allowed disabled:opacity-40 disabled:shadow-none disabled:hover:scale-100"),
854
855
  style: u,
@@ -865,7 +866,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
865
866
  ]
866
867
  })
867
868
  });
868
- }, ft = "linear-gradient(to right, color-mix(in oklch, var(--ai-chat-thinking-1, oklch(0.65 0.15 253.81)) 40%, transparent), color-mix(in oklch, var(--ai-chat-thinking-2, oklch(0.65 0.15 17.5826)) 40%, transparent))", $ = (...e) => e.filter(Boolean).join(" "), pt = ({ workspaceId: e, siteName: t, siteLogo: n, siteIcon: r, siteSlug: i, agentId: o, apiBaseUrl: s, authHeaders: c, initialOpen: l, initialDraft: u, showBranding: d = !0 }) => {
869
+ }, ut = "linear-gradient(to right, color-mix(in oklch, var(--ai-chat-thinking-1, oklch(0.65 0.15 253.81)) 40%, transparent), color-mix(in oklch, var(--ai-chat-thinking-2, oklch(0.65 0.15 17.5826)) 40%, transparent))", $ = (...e) => e.filter(Boolean).join(" "), dt = ({ workspaceId: e, siteName: t, siteLogo: n, siteIcon: r, siteSlug: i, agentId: o, apiBaseUrl: s, authHeaders: c, initialOpen: l, initialDraft: u, showBranding: d = !0 }) => {
869
870
  let [f, p] = w(!1);
870
871
  x(() => {
871
872
  if (!l) return;
@@ -873,19 +874,19 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
873
874
  return () => cancelAnimationFrame(e);
874
875
  }, [l]);
875
876
  let m = `kb-chat-panel-${e ?? "default"}`, h = C(null), g = C(null), _ = y(() => p(!1), []);
876
- st(f, g, _), ut(f, h, _), lt(f, h);
877
+ ot(f, g, _), ct(f, h, _), st(f, h);
877
878
  let v = a(t);
878
879
  return /* @__PURE__ */ E("div", {
879
880
  ref: h,
880
881
  className: $("ai-chat-launcher pointer-events-none fixed bottom-5 left-1/2 z-[60] flex -translate-x-1/2 flex-col", "ai-chat-kb-wrap", f ? "w-[min(34rem,calc(100vw-1.5rem))]" : "ai-chat-kb-wrap-closed w-[19.5rem]"),
881
- children: /* @__PURE__ */ E(ot, {
882
+ children: /* @__PURE__ */ E(at, {
882
883
  workspaceId: e,
883
884
  siteName: t,
884
885
  siteLogo: n,
885
886
  agentId: o,
886
887
  apiBaseUrl: s,
887
888
  authHeaders: c,
888
- children: ({ followUps: a, onResetChat: l }) => /* @__PURE__ */ E(ht, {
889
+ children: ({ followUps: a, onResetChat: l }) => /* @__PURE__ */ E(pt, {
889
890
  open: f,
890
891
  onToggle: () => p((e) => !e),
891
892
  threadStateRef: g,
@@ -911,12 +912,12 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
911
912
  })
912
913
  })
913
914
  });
914
- }, mt = [
915
+ }, ft = [
915
916
  "rounded-full border border-zinc-200 bg-white text-zinc-700",
916
917
  "px-3 py-1 text-[13px] leading-snug",
917
918
  "transition-[border-color,background-color,color,transform] duration-150 hover:border-zinc-300 hover:bg-zinc-50 hover:text-zinc-900 active:scale-95"
918
- ].join(" "), ht = ({ open: t, onToggle: n, threadStateRef: r, onResetChat: i, askLabel: a, panelId: o, siteName: s, siteIcon: c, siteSlug: l, initialDraft: u, showBranding: d, followUps: f, thread: p }) => {
919
- let m = V(), h = U((e) => e.isRunning), g = U((e) => e.messages.length > 0), _ = ct() ? f.slice(0, 2) : f;
919
+ ].join(" "), pt = ({ open: t, onToggle: n, threadStateRef: r, onResetChat: i, askLabel: a, panelId: o, siteName: s, siteIcon: c, siteSlug: l, initialDraft: u, showBranding: d, followUps: f, thread: p }) => {
920
+ let m = B(), h = V((e) => e.thread.isRunning), g = V((e) => e.thread.messages.length > 0), _ = Z() ? f.slice(0, 2) : f;
920
921
  x(() => (r.current = {
921
922
  isRunning: h,
922
923
  cancelRun: () => m.thread.cancelRun()
@@ -928,7 +929,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
928
929
  r
929
930
  ]);
930
931
  let v = y((t) => {
931
- e(m.thread.composer, t);
932
+ e(m.thread.composer(), t);
932
933
  }, [m]), b = s ?? "Ask AI", S = `https://levo.so/?utm_source=${encodeURIComponent(l || "website")}&utm_term=Powered%20By%20levo.so&utm_campaign=site_agent&utm_medium=organic_site_agent`;
933
934
  return /* @__PURE__ */ D(T, { children: [
934
935
  /* @__PURE__ */ E("div", {
@@ -937,7 +938,7 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
937
938
  style: { filter: "drop-shadow(0 16px 32px rgba(0,0,0,0.16)) drop-shadow(0 2px 8px rgba(0,0,0,0.08))" },
938
939
  children: /* @__PURE__ */ E("div", {
939
940
  className: $("ai-chat-kb-surface h-full w-full p-[2px]", !t && "ai-chat-kb-surface-closed"),
940
- style: { background: ft },
941
+ style: { background: ut },
941
942
  children: /* @__PURE__ */ E("div", { className: "h-full w-full rounded-t-[26px] rounded-b-[40px] bg-white" })
942
943
  })
943
944
  }),
@@ -967,13 +968,13 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
967
968
  "aria-label": "Start new chat",
968
969
  title: "Start new chat",
969
970
  className: "ai-chat-icon-btn flex h-8 w-8 flex-shrink-0 items-center justify-center rounded-full transition-[background-color,color,transform] duration-150 active:scale-95",
970
- children: /* @__PURE__ */ E(M, { className: "h-4 w-4" })
971
+ children: /* @__PURE__ */ E(j, { className: "h-4 w-4" })
971
972
  }), /* @__PURE__ */ E("button", {
972
973
  type: "button",
973
974
  onClick: n,
974
975
  "aria-label": "Close AI chat",
975
976
  className: "ai-chat-icon-btn flex h-8 w-8 flex-shrink-0 items-center justify-center rounded-full transition-[background-color,color,transform] duration-150 active:scale-95",
976
- children: /* @__PURE__ */ E(F, { className: "h-4 w-4" })
977
+ children: /* @__PURE__ */ E(P, { className: "h-4 w-4" })
977
978
  })]
978
979
  })]
979
980
  }),
@@ -984,17 +985,17 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
984
985
  }),
985
986
  _.length > 0 && !h && /* @__PURE__ */ E("div", {
986
987
  className: "shrink-0 px-4 pt-1 pb-2",
987
- children: /* @__PURE__ */ E(W, {
988
+ children: /* @__PURE__ */ E(H, {
988
989
  chips: _,
989
990
  onSelect: v,
990
- chipClassName: mt
991
+ chipClassName: ft
991
992
  })
992
993
  })
993
994
  ]
994
995
  }),
995
996
  /* @__PURE__ */ E("div", {
996
997
  className: "ai-chat-kb-pillbox pointer-events-auto relative z-20 mx-3 mt-1",
997
- children: /* @__PURE__ */ E(dt, {
998
+ children: /* @__PURE__ */ E(lt, {
998
999
  open: t,
999
1000
  onToggle: n,
1000
1001
  askLabel: a,
@@ -1008,17 +1009,13 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
1008
1009
  className: "overflow-hidden",
1009
1010
  children: /* @__PURE__ */ D("p", {
1010
1011
  className: "pt-2 text-center text-[11px] text-zinc-400",
1011
- children: [
1012
- "Powered by",
1013
- " ",
1014
- /* @__PURE__ */ E("a", {
1015
- href: S,
1016
- target: "_blank",
1017
- rel: "noopener noreferrer",
1018
- className: "pointer-events-auto font-medium text-zinc-500 underline-offset-2 transition-colors hover:text-zinc-700 hover:underline",
1019
- children: "levo.so"
1020
- })
1021
- ]
1012
+ children: ["Powered by ", /* @__PURE__ */ E("a", {
1013
+ href: S,
1014
+ target: "_blank",
1015
+ rel: "noopener noreferrer",
1016
+ className: "pointer-events-auto font-medium text-zinc-500 underline-offset-2 transition-colors hover:text-zinc-700 hover:underline",
1017
+ children: "levo.so"
1018
+ })]
1022
1019
  })
1023
1020
  })
1024
1021
  }),
@@ -1026,4 +1023,4 @@ var W = ({ chips: e, onSelect: t, size: n = "comfortable", className: r, chipCla
1026
1023
  ] });
1027
1024
  };
1028
1025
  //#endregion
1029
- export { pt as KBChatWidget };
1026
+ export { dt as KBChatWidget };