@versini/sassysaint 8.95.0 → 8.95.1

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 (26) hide show
  1. package/dist/chunks/{AboutChangelog.BqpSKrNZ.js → AboutChangelog.oKYEpTAu.js} +3 -3
  2. package/dist/chunks/{AboutEntry.Cx6IKOQG.js → AboutEntry.C3YYsRM3.js} +5 -5
  3. package/dist/chunks/{App.DLoz17ih.js → App.YJ6X6xsL.js} +940 -929
  4. package/dist/chunks/{Chart.Bfutic-q.js → Chart.C9KO1m34.js} +2 -2
  5. package/dist/chunks/{ChatBubbleAssistant.6Xu3MZrx.js → ChatBubbleAssistant.D-_zHFRv.js} +4 -4
  6. package/dist/chunks/{ChatBubbleUser.BQpzE_nc.js → ChatBubbleUser.DhmmlriT.js} +6 -6
  7. package/dist/chunks/{ChatHistoryTable._wit5nB6.js → ChatHistoryTable.D8zIPSxa.js} +18 -18
  8. package/dist/chunks/{HistoryEntry.DUOzZAtx.js → HistoryEntry.A_zM8X2l.js} +3 -3
  9. package/dist/chunks/{ProfileEntry.CgX_IsH2.js → ProfileEntry.BTJI95Ps.js} +2 -2
  10. package/dist/chunks/{SettingsEntry.DgDbgbp8.js → SettingsEntry.Bh6zMUQR.js} +3 -3
  11. package/dist/chunks/{UsageEntry.BD2iSXcr.js → UsageEntry.DDAJ5UIh.js} +3 -3
  12. package/dist/chunks/{UserMemoriesPanel.BRw2SUCk.js → UserMemoriesPanel.Cb4rReTt.js} +4 -4
  13. package/dist/chunks/{index.lZiFVMEz.js → index.B3VxdF5s.js} +3 -3
  14. package/dist/chunks/{index.DKZ5ZW-U.js → index.BV3huGg5.js} +4 -4
  15. package/dist/chunks/{index.Mc6SYERm.js → index.Bb0qPlsw.js} +17 -17
  16. package/dist/chunks/{index.NeUcWtV6.js → index.CLoLtkdg.js} +1 -1
  17. package/dist/chunks/{index.D1cH5wfc.js → index.DE1Lyuoz.js} +4 -4
  18. package/dist/chunks/{index.DzeyT7xJ.js → index.DeMYwl1b.js} +1 -1
  19. package/dist/chunks/{index.U5DkfFOw.js → index.DzVmZ1PW.js} +4 -4
  20. package/dist/chunks/{index.CErwlnvi.js → index.E7vY8f-A.js} +2 -2
  21. package/dist/chunks/{index.C3lH1rJ_.js → index.ksfUny7U.js} +1 -1
  22. package/dist/chunks/{useMarkdown.Ctf1YOy_.js → useMarkdown.DwJslJ5L.js} +6 -6
  23. package/dist/components/SassySaint/SassySaint.js +1 -1
  24. package/dist/index.js +4 -4
  25. package/dist/style.css +2 -2
  26. package/package.json +3 -3
@@ -1,8 +1,8 @@
1
- import { jsx as p, jsxs as N, Fragment as Me } from "react/jsx-runtime";
2
- import { ACTION_SORT as da, e$1 as gt, ACTION_SEARCH as pa, ACTION_RESET_PROMPT as mo, ACTION_TOGGLE_PROMPT as ho, ChatContext as we, LOCAL_STORAGE_PREFIX as ke, LOCAL_STORAGE_CHAT_ID as jt, n as Ie, useLocalStorage as Ne, isDev as fa, isPWAMode as go, isTauri as _t, useChat as ma, useClickOutside as ha, useInterval as ga, useTheme as Ce, ButtonIcon as xe, IconAddLight as va, DEFAULT_ICON_ACTION_SIZE as Oe, useUserPreferences as je, useHotkeys as Fr, isProbablyiPhone as ze, IconCloseLight as ya, IconEditLight as _a, serverUrl as vo, useEntitlements as Br, IconClose as yo, useHaptic as ba, L as Sr, j as at, Button as cn, useSaveChat as wa, LOCAL_STORAGE_PRIVATE_DISCLOSURE as Ia, w as Jt, IconLockedLight as Ea, IconUnlockedLight as Ta, IconSelected as Sa, IconUnSelected as ka, IconNext as Ca, PromptsContext as Vr, IconBookSparklesLight as xa, IconRewrite as Aa, IconProofread as Na, IconMagic as Oa, LOCAL_STORAGE_REASONING_DISCLOSURE as Pa, IconLightBulbLight as Ra, IconSendLight as za, INPUT_PLACEHOLDER_TEXT_IN_SESSION as _o, INPUT_PLACEHOLDER_TEXT_MORNING as Ma, INPUT_PLACEHOLDER_TEXT_TODAY as $a, INPUT_PLACEHOLDER_TEXT_AFTERNOON as Za, INPUT_PLACEHOLDER_TEXT_EVENING as Da, INPUT_PLACEHOLDER_TEXT_NIGHT as La, INPUT_PLACEHOLDER_TEXT_DEFAULT as Ua, PROMPT_EDITABLE_AREA_CLASSNAME as ja, PROMPT_CLASSNAME as Fa, AppContext as Ct, HistoryContext as bo, useChatsHistory as Ba, useUniqueId as Va, j$1 as wo, ERROR_MESSAGE as Ha, o as bt, CLIPBOARD_PROMPT as ln, getHotkeyHandler as Ga, U as Ja, FOOTER_DISCLAIMERS as un, useViewportSize as Wa, useVisualViewportSize as Ya, useResizeObserver as Io, isProbablyiPad as qa, INPUT_BOTTOM_OFFSET_EXTRA as dn, INPUT_BOTTOM_OFFSET_IPHONE as Xa, INPUT_BOTTOM_OFFSET_IPAD as Qa, INPUT_BOTTOM_OFFSET as Eo, APP_SET_FOOTER_HEIGHT as Ka, FOOTER_TOP as kr, FOOTER_BOTTOM as vt, APP_SET_FOOTER_POSITION as dr, getLayoutPaddingClass as Cr, canEvaluateModels as pn, k as ei, IconOpenAI as ti, a as ri, IconAnthropic as ni, i as oi, IconGoogleGemini as si, s as ai, x as ii, p as pr, setNewProvider as fn, TOAST_PROVIDER_CHANGED as mn, useQueryClient as ci, LOG_OUT as hn, IconProfile as li, IconSliders as ui, IconHistory as di, IconEditUser as pi, IconChart as fi, IconInfo as mi, IconBack as hi, IconSettings as gi, n$1 as To, useInViewport as vi, useServerCapabilities as yi, getMessageContaintWrapperClass as _i, UI_FOOTER_BUFFER as So, UI_BUTTON_SCROLL_BUFFER as bi, Logo as wi, isProbablyMobile as Ii, UI_DEFAULT_MAIN_HEIGHT as gn, e as Ei, appReducer as Ti, applyOledMode as Si, APP_SET_OLED_MODE as ki, APP_SET_FULL_SCREEN as Ci, APP_SET_THEME_MODE as xi, APP_SET_THEME_PALETTE as Ai, UI_DEFAULT_MAIN_HEIGHT_IPHONE as Ni, APP_CLASSNAME as Oi, y as vn, v as Pi, LOCAL_STORAGE_SORT as Ri, LOCAL_STORAGE_SEARCH as zi, LOCAL_STORAGE_OLED_MODE as Mi, LOCAL_STORAGE_FULL_SCREEN as $i, LOCAL_STORAGE_SORT_TIMESTAMP as Zi, LOCAL_STORAGE_SORT_TOKEN_USAGE as Di, TOAST_CACHE_ENABLED as Li, TOAST_CACHE_DISABLED as Ui } from "./index.Mc6SYERm.js";
3
- import ko, { useRef as W, useCallback as q, useSyncExternalStore as fr, useEffect as $, useState as Z, createContext as Hr, useContext as X, forwardRef as Xe, useId as Co, useLayoutEffect as Gr, cloneElement as ji, useMemo as be, Suspense as Wt, lazy as Pe, useReducer as Rt } from "react";
4
- import z, { clsx as $e } from "clsx";
5
- import { computePosition as Fi, offset as xo, flip as Ao, shift as No, arrow as Bi, useMergeRefs as Jr, FloatingPortal as xr, FloatingOverlay as Vi, FloatingFocusManager as Ar, useFloating as Oo, useClick as Po, useDismiss as Ro, useRole as zo, useInteractions as Mo, useFloatingParentNodeId as $o, FloatingTree as Hi, useListItem as Zo, useFloatingTree as Do, useFloatingNodeId as Gi, autoUpdate as Ji, useHover as Wi, safePolygon as Yi, useListNavigation as qi, useTypeahead as Xi, FloatingNode as yn, FloatingList as _n } from "@floating-ui/react";
1
+ import { jsx as p, jsxs as N, Fragment as $e } from "react/jsx-runtime";
2
+ import { ACTION_SORT as da, e$1 as gt, ACTION_SEARCH as pa, ACTION_RESET_PROMPT as mo, ACTION_TOGGLE_PROMPT as ho, ChatContext as Ie, LOCAL_STORAGE_PREFIX as Ce, LOCAL_STORAGE_CHAT_ID as jt, n as Ee, useLocalStorage as Oe, isDev as fa, isPWAMode as go, isTauri as _t, useChat as ma, useClickOutside as ha, useInterval as ga, isProbablyiPhone as Pe, useTheme as xe, ButtonIcon as Ae, IconAddLight as va, DEFAULT_ICON_ACTION_SIZE as Re, useUserPreferences as Fe, useHotkeys as Fr, IconCloseLight as ya, IconEditLight as _a, serverUrl as vo, useEntitlements as Br, IconClose as yo, useHaptic as ba, L as Sr, j as at, Button as cn, useSaveChat as wa, LOCAL_STORAGE_PRIVATE_DISCLOSURE as Ia, w as Jt, IconLockedLight as Ea, IconUnlockedLight as Ta, IconSelected as Sa, IconUnSelected as ka, IconNext as Ca, PromptsContext as Vr, IconBookSparklesLight as xa, IconRewrite as Aa, IconProofread as Na, IconMagic as Oa, LOCAL_STORAGE_REASONING_DISCLOSURE as Pa, IconLightBulbLight as Ra, IconSendLight as Ma, INPUT_PLACEHOLDER_TEXT_IN_SESSION as _o, INPUT_PLACEHOLDER_TEXT_MORNING as za, INPUT_PLACEHOLDER_TEXT_TODAY as $a, INPUT_PLACEHOLDER_TEXT_AFTERNOON as Za, INPUT_PLACEHOLDER_TEXT_EVENING as Da, INPUT_PLACEHOLDER_TEXT_NIGHT as La, INPUT_PLACEHOLDER_TEXT_DEFAULT as Ua, PROMPT_EDITABLE_AREA_CLASSNAME as ja, PROMPT_CLASSNAME as Fa, AppContext as Ct, HistoryContext as bo, useChatsHistory as Ba, useUniqueId as Va, j$1 as wo, ERROR_MESSAGE as Ha, o as bt, CLIPBOARD_PROMPT as ln, getHotkeyHandler as Ga, U as Ja, FOOTER_DISCLAIMERS as un, useViewportSize as Wa, useVisualViewportSize as Ya, useResizeObserver as Io, isProbablyiPad as qa, INPUT_BOTTOM_OFFSET_EXTRA as dn, INPUT_BOTTOM_OFFSET_IPHONE as Xa, INPUT_BOTTOM_OFFSET_IPAD as Qa, INPUT_BOTTOM_OFFSET as Eo, APP_SET_FOOTER_HEIGHT as Ka, FOOTER_TOP as kr, FOOTER_BOTTOM as vt, APP_SET_FOOTER_POSITION as dr, getLayoutPaddingClass as Cr, canEvaluateModels as pn, k as ei, IconOpenAI as ti, a as ri, IconAnthropic as ni, i as oi, IconGoogleGemini as si, s as ai, x as ii, p as pr, setNewProvider as fn, TOAST_PROVIDER_CHANGED as mn, useQueryClient as ci, LOG_OUT as hn, IconProfile as li, IconSliders as ui, IconHistory as di, IconEditUser as pi, IconChart as fi, IconInfo as mi, IconBack as hi, IconSettings as gi, n$1 as To, useInViewport as vi, useServerCapabilities as yi, getMessageContaintWrapperClass as _i, UI_FOOTER_BUFFER as So, UI_BUTTON_SCROLL_BUFFER as bi, Logo as wi, isProbablyMobile as Ii, UI_DEFAULT_MAIN_HEIGHT as gn, e as Ei, appReducer as Ti, applyOledMode as Si, APP_SET_OLED_MODE as ki, APP_SET_FULL_SCREEN as Ci, APP_SET_THEME_MODE as xi, APP_SET_THEME_PALETTE as Ai, UI_DEFAULT_MAIN_HEIGHT_IPHONE as Ni, APP_CLASSNAME as Oi, y as vn, v as Pi, LOCAL_STORAGE_SORT as Ri, LOCAL_STORAGE_SEARCH as Mi, LOCAL_STORAGE_OLED_MODE as zi, LOCAL_STORAGE_FULL_SCREEN as $i, LOCAL_STORAGE_SORT_TIMESTAMP as Zi, LOCAL_STORAGE_SORT_TOKEN_USAGE as Di, TOAST_CACHE_ENABLED as Li, TOAST_CACHE_DISABLED as Ui } from "./index.Bb0qPlsw.js";
3
+ import ko, { useRef as J, useCallback as X, useSyncExternalStore as fr, useEffect as $, useState as Z, createContext as Hr, useContext as Q, useMemo as he, forwardRef as Qe, useId as Co, useLayoutEffect as Gr, cloneElement as ji, Suspense as Wt, lazy as Me, useReducer as Rt } from "react";
4
+ import R, { clsx as Ze } from "clsx";
5
+ import { computePosition as Fi, offset as xo, flip as Ao, shift as No, arrow as Bi, useMergeRefs as Jr, FloatingPortal as xr, FloatingOverlay as Vi, FloatingFocusManager as Ar, useFloating as Oo, useClick as Po, useDismiss as Ro, useRole as Mo, useInteractions as zo, useFloatingParentNodeId as $o, FloatingTree as Hi, useListItem as Zo, useFloatingTree as Do, useFloatingNodeId as Gi, autoUpdate as Ji, useHover as Wi, safePolygon as Yi, useListNavigation as qi, useTypeahead as Xi, FloatingNode as yn, FloatingList as _n } from "@floating-ui/react";
6
6
  var Lo = "vercel.ai.error", Qi = Symbol.for(Lo), Uo, Ki = class jo extends Error {
7
7
  /**
8
8
  * Creates an AI SDK Error.
@@ -33,11 +33,11 @@ var Lo = "vercel.ai.error", Qi = Symbol.for(Lo), Uo, Ki = class jo extends Error
33
33
  }
34
34
  };
35
35
  Uo = Qi;
36
- var Ze = Ki;
36
+ var De = Ki;
37
37
  function Fo(e) {
38
38
  return e == null ? "unknown error" : typeof e == "string" ? e : e instanceof Error ? e.message : JSON.stringify(e);
39
39
  }
40
- var Bo = "AI_InvalidArgumentError", Vo = `vercel.ai.error.${Bo}`, ec = Symbol.for(Vo), Ho, tc = class extends Ze {
40
+ var Bo = "AI_InvalidArgumentError", Vo = `vercel.ai.error.${Bo}`, ec = Symbol.for(Vo), Ho, tc = class extends De {
41
41
  constructor({
42
42
  message: e,
43
43
  cause: t,
@@ -46,11 +46,11 @@ var Bo = "AI_InvalidArgumentError", Vo = `vercel.ai.error.${Bo}`, ec = Symbol.fo
46
46
  super({ name: Bo, message: e, cause: t }), this[Ho] = !0, this.argument = r;
47
47
  }
48
48
  static isInstance(e) {
49
- return Ze.hasMarker(e, Vo);
49
+ return De.hasMarker(e, Vo);
50
50
  }
51
51
  };
52
52
  Ho = ec;
53
- var Go = "AI_JSONParseError", Jo = `vercel.ai.error.${Go}`, rc = Symbol.for(Jo), Wo, bn = class extends Ze {
53
+ var Go = "AI_JSONParseError", Jo = `vercel.ai.error.${Go}`, rc = Symbol.for(Jo), Wo, bn = class extends De {
54
54
  constructor({ text: e, cause: t }) {
55
55
  super({
56
56
  name: Go,
@@ -60,11 +60,11 @@ Error message: ${Fo(t)}`,
60
60
  }), this[Wo] = !0, this.text = e;
61
61
  }
62
62
  static isInstance(e) {
63
- return Ze.hasMarker(e, Jo);
63
+ return De.hasMarker(e, Jo);
64
64
  }
65
65
  };
66
66
  Wo = rc;
67
- var Yo = "AI_TypeValidationError", qo = `vercel.ai.error.${Yo}`, nc = Symbol.for(qo), Xo, oc = class Nr extends Ze {
67
+ var Yo = "AI_TypeValidationError", qo = `vercel.ai.error.${Yo}`, nc = Symbol.for(qo), Xo, oc = class Nr extends De {
68
68
  constructor({ value: t, cause: r }) {
69
69
  super({
70
70
  name: Yo,
@@ -74,7 +74,7 @@ Error message: ${Fo(r)}`,
74
74
  }), this[Xo] = !0, this.value = t;
75
75
  }
76
76
  static isInstance(t) {
77
- return Ze.hasMarker(t, qo);
77
+ return De.hasMarker(t, qo);
78
78
  }
79
79
  /**
80
80
  * Wraps an error into a TypeValidationError.
@@ -251,7 +251,7 @@ class wt extends Error {
251
251
  }
252
252
  }
253
253
  const Qo = {};
254
- function De(e) {
254
+ function Le(e) {
255
255
  return Qo;
256
256
  }
257
257
  function Ko(e) {
@@ -338,7 +338,7 @@ const dc = /* @__PURE__ */ new Set(["string", "number", "symbol"]);
338
338
  function xt(e) {
339
339
  return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
340
340
  }
341
- function Qe(e, t, r) {
341
+ function Ke(e, t, r) {
342
342
  const n = new e._zod.constr(t ?? e._zod.def);
343
343
  return (!t || r?.parent) && (n._zod.parent = e), n;
344
344
  }
@@ -372,7 +372,7 @@ function mc(e, t) {
372
372
  throw new Error(`Unrecognized key: "${o}"`);
373
373
  t[o] && (r[o] = n.shape[o]);
374
374
  }
375
- return Qe(e, {
375
+ return Ke(e, {
376
376
  ...e._zod.def,
377
377
  shape: r,
378
378
  checks: []
@@ -385,7 +385,7 @@ function hc(e, t) {
385
385
  throw new Error(`Unrecognized key: "${o}"`);
386
386
  t[o] && delete r[o];
387
387
  }
388
- return Qe(e, {
388
+ return Ke(e, {
389
389
  ...e._zod.def,
390
390
  shape: r,
391
391
  checks: []
@@ -403,10 +403,10 @@ function gc(e, t) {
403
403
  checks: []
404
404
  // delete existing checks
405
405
  };
406
- return Qe(e, r);
406
+ return Ke(e, r);
407
407
  }
408
408
  function vc(e, t) {
409
- return Qe(e, {
409
+ return Ke(e, {
410
410
  ...e._zod.def,
411
411
  get shape() {
412
412
  const r = { ...e._zod.def.shape, ...t._zod.def.shape };
@@ -434,7 +434,7 @@ function yc(e, t, r) {
434
434
  type: "optional",
435
435
  innerType: n[s]
436
436
  }) : n[s];
437
- return Qe(t, {
437
+ return Ke(t, {
438
438
  ...t._zod.def,
439
439
  shape: o,
440
440
  checks: []
@@ -457,7 +457,7 @@ function _c(e, t, r) {
457
457
  type: "nonoptional",
458
458
  innerType: n[s]
459
459
  });
460
- return Qe(t, {
460
+ return Ke(t, {
461
461
  ...t._zod.def,
462
462
  shape: o,
463
463
  // optional: [],
@@ -470,19 +470,19 @@ function yt(e, t = 0) {
470
470
  return !0;
471
471
  return !1;
472
472
  }
473
- function Ye(e, t) {
473
+ function qe(e, t) {
474
474
  return t.map((r) => {
475
475
  var n;
476
476
  return (n = r).path ?? (n.path = []), r.path.unshift(e), r;
477
477
  });
478
478
  }
479
- function zt(e) {
479
+ function Mt(e) {
480
480
  return typeof e == "string" ? e : e?.message;
481
481
  }
482
- function Le(e, t, r) {
482
+ function Ue(e, t, r) {
483
483
  const n = { ...e, path: e.path ?? [] };
484
484
  if (!e.message) {
485
- const o = zt(e.inst?._zod.def?.error?.(e)) ?? zt(t?.error?.(e)) ?? zt(r.customError?.(e)) ?? zt(r.localeError?.(e)) ?? "Invalid input";
485
+ const o = Mt(e.inst?._zod.def?.error?.(e)) ?? Mt(t?.error?.(e)) ?? Mt(r.customError?.(e)) ?? Mt(r.localeError?.(e)) ?? "Invalid input";
486
486
  n.message = o;
487
487
  }
488
488
  return delete n.inst, delete n.continue, t?.reportInput || delete n.input, n;
@@ -551,7 +551,7 @@ const Ic = (e) => (t, r, n, o) => {
551
551
  if (i instanceof Promise)
552
552
  throw new wt();
553
553
  if (i.issues.length) {
554
- const a = new (o?.Err ?? e)(i.issues.map((l) => Le(l, s, De())));
554
+ const a = new (o?.Err ?? e)(i.issues.map((l) => Ue(l, s, Le())));
555
555
  throw es(a, o?.callee), a;
556
556
  }
557
557
  return i.value;
@@ -559,7 +559,7 @@ const Ic = (e) => (t, r, n, o) => {
559
559
  const s = n ? Object.assign(n, { async: !0 }) : { async: !0 };
560
560
  let i = t._zod.run({ value: r, issues: [] }, s);
561
561
  if (i instanceof Promise && (i = await i), i.issues.length) {
562
- const a = new (o?.Err ?? e)(i.issues.map((l) => Le(l, s, De())));
562
+ const a = new (o?.Err ?? e)(i.issues.map((l) => Ue(l, s, Le())));
563
563
  throw es(a, o?.callee), a;
564
564
  }
565
565
  return i.value;
@@ -569,18 +569,18 @@ const Ic = (e) => (t, r, n, o) => {
569
569
  throw new wt();
570
570
  return s.issues.length ? {
571
571
  success: !1,
572
- error: new (e ?? rs)(s.issues.map((i) => Le(i, o, De())))
572
+ error: new (e ?? rs)(s.issues.map((i) => Ue(i, o, Le())))
573
573
  } : { success: !0, data: s.value };
574
574
  }, Tc = /* @__PURE__ */ os(ns), ss = (e) => async (t, r, n) => {
575
575
  const o = n ? Object.assign(n, { async: !0 }) : { async: !0 };
576
576
  let s = t._zod.run({ value: r, issues: [] }, o);
577
577
  return s instanceof Promise && (s = await s), s.issues.length ? {
578
578
  success: !1,
579
- error: new e(s.issues.map((i) => Le(i, o, De())))
579
+ error: new e(s.issues.map((i) => Ue(i, o, Le())))
580
580
  } : { success: !0, data: s.value };
581
- }, Sc = /* @__PURE__ */ ss(ns), kc = /^[cC][^\s-]{8,}$/, Cc = /^[0-9a-z]+$/, xc = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/, Ac = /^[0-9a-vA-V]{20}$/, Nc = /^[A-Za-z0-9]{27}$/, Oc = /^[a-zA-Z0-9_-]{21}$/, Pc = /^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/, Rc = /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/, In = (e) => e ? new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`) : /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/, zc = /^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/, Mc = "^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";
581
+ }, Sc = /* @__PURE__ */ ss(ns), kc = /^[cC][^\s-]{8,}$/, Cc = /^[0-9a-z]+$/, xc = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/, Ac = /^[0-9a-vA-V]{20}$/, Nc = /^[A-Za-z0-9]{27}$/, Oc = /^[a-zA-Z0-9_-]{21}$/, Pc = /^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/, Rc = /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/, In = (e) => e ? new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`) : /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/, Mc = /^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/, zc = "^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";
582
582
  function $c() {
583
- return new RegExp(Mc, "u");
583
+ return new RegExp(zc, "u");
584
584
  }
585
585
  const Zc = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/, Dc = /^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})$/, Lc = /^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/, Uc = /^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/, jc = /^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/, as = /^[A-Za-z0-9_-]*$/, Fc = /^([a-zA-Z0-9-]+\.)*[a-zA-Z0-9-]+$/, Bc = /^\+(?:[0-9]){6,14}[0-9]$/, is = "(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))", Vc = /* @__PURE__ */ new RegExp(`^${is}$`);
586
586
  function cs(e) {
@@ -599,7 +599,7 @@ function Gc(e) {
599
599
  const Jc = (e) => {
600
600
  const t = e ? `[\\s\\S]{${e?.minimum ?? 0},${e?.maximum ?? ""}}` : "[\\s\\S]*";
601
601
  return new RegExp(`^${t}$`);
602
- }, Wc = /^\d+$/, Yc = /^-?\d+(?:\.\d+)?/i, qc = /true|false/i, Xc = /null/i, Qc = /^[^A-Z]*$/, Kc = /^[^a-z]*$/, ie = /* @__PURE__ */ _("$ZodCheck", (e, t) => {
602
+ }, Wc = /^\d+$/, Yc = /^-?\d+(?:\.\d+)?/i, qc = /true|false/i, Xc = /null/i, Qc = /^[^A-Z]*$/, Kc = /^[^a-z]*$/, ce = /* @__PURE__ */ _("$ZodCheck", (e, t) => {
603
603
  var r;
604
604
  e._zod ?? (e._zod = {}), e._zod.def = t, (r = e._zod).onattach ?? (r.onattach = []);
605
605
  }), ls = {
@@ -607,7 +607,7 @@ const Jc = (e) => {
607
607
  bigint: "bigint",
608
608
  object: "date"
609
609
  }, us = /* @__PURE__ */ _("$ZodCheckLessThan", (e, t) => {
610
- ie.init(e, t);
610
+ ce.init(e, t);
611
611
  const r = ls[typeof t.value];
612
612
  e._zod.onattach.push((n) => {
613
613
  const o = n._zod.bag, s = (t.inclusive ? o.maximum : o.exclusiveMaximum) ?? Number.POSITIVE_INFINITY;
@@ -624,7 +624,7 @@ const Jc = (e) => {
624
624
  });
625
625
  };
626
626
  }), ds = /* @__PURE__ */ _("$ZodCheckGreaterThan", (e, t) => {
627
- ie.init(e, t);
627
+ ce.init(e, t);
628
628
  const r = ls[typeof t.value];
629
629
  e._zod.onattach.push((n) => {
630
630
  const o = n._zod.bag, s = (t.inclusive ? o.minimum : o.exclusiveMinimum) ?? Number.NEGATIVE_INFINITY;
@@ -641,7 +641,7 @@ const Jc = (e) => {
641
641
  });
642
642
  };
643
643
  }), el = /* @__PURE__ */ _("$ZodCheckMultipleOf", (e, t) => {
644
- ie.init(e, t), e._zod.onattach.push((r) => {
644
+ ce.init(e, t), e._zod.onattach.push((r) => {
645
645
  var n;
646
646
  (n = r._zod.bag).multipleOf ?? (n.multipleOf = t.value);
647
647
  }), e._zod.check = (r) => {
@@ -657,7 +657,7 @@ const Jc = (e) => {
657
657
  });
658
658
  };
659
659
  }), tl = /* @__PURE__ */ _("$ZodCheckNumberFormat", (e, t) => {
660
- ie.init(e, t), t.format = t.format || "float64";
660
+ ce.init(e, t), t.format = t.format || "float64";
661
661
  const r = t.format?.includes("int"), n = r ? "int" : "number", [o, s] = fc[t.format];
662
662
  e._zod.onattach.push((i) => {
663
663
  const a = i._zod.bag;
@@ -714,7 +714,7 @@ const Jc = (e) => {
714
714
  };
715
715
  }), rl = /* @__PURE__ */ _("$ZodCheckMaxLength", (e, t) => {
716
716
  var r;
717
- ie.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
717
+ ce.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
718
718
  const o = n.value;
719
719
  return !Yr(o) && o.length !== void 0;
720
720
  }), e._zod.onattach.push((n) => {
@@ -737,7 +737,7 @@ const Jc = (e) => {
737
737
  };
738
738
  }), nl = /* @__PURE__ */ _("$ZodCheckMinLength", (e, t) => {
739
739
  var r;
740
- ie.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
740
+ ce.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
741
741
  const o = n.value;
742
742
  return !Yr(o) && o.length !== void 0;
743
743
  }), e._zod.onattach.push((n) => {
@@ -760,7 +760,7 @@ const Jc = (e) => {
760
760
  };
761
761
  }), ol = /* @__PURE__ */ _("$ZodCheckLengthEquals", (e, t) => {
762
762
  var r;
763
- ie.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
763
+ ce.init(e, t), (r = e._zod.def).when ?? (r.when = (n) => {
764
764
  const o = n.value;
765
765
  return !Yr(o) && o.length !== void 0;
766
766
  }), e._zod.onattach.push((n) => {
@@ -783,7 +783,7 @@ const Jc = (e) => {
783
783
  };
784
784
  }), sr = /* @__PURE__ */ _("$ZodCheckStringFormat", (e, t) => {
785
785
  var r, n;
786
- ie.init(e, t), e._zod.onattach.push((o) => {
786
+ ce.init(e, t), e._zod.onattach.push((o) => {
787
787
  const s = o._zod.bag;
788
788
  s.format = t.format, t.pattern && (s.patterns ?? (s.patterns = /* @__PURE__ */ new Set()), s.patterns.add(t.pattern));
789
789
  }), t.pattern ? (r = e._zod).check ?? (r.check = (o) => {
@@ -815,7 +815,7 @@ const Jc = (e) => {
815
815
  }), il = /* @__PURE__ */ _("$ZodCheckUpperCase", (e, t) => {
816
816
  t.pattern ?? (t.pattern = Kc), sr.init(e, t);
817
817
  }), cl = /* @__PURE__ */ _("$ZodCheckIncludes", (e, t) => {
818
- ie.init(e, t);
818
+ ce.init(e, t);
819
819
  const r = xt(t.includes), n = new RegExp(typeof t.position == "number" ? `^.{${t.position}}${r}` : r);
820
820
  t.pattern = n, e._zod.onattach.push((o) => {
821
821
  const s = o._zod.bag;
@@ -832,7 +832,7 @@ const Jc = (e) => {
832
832
  });
833
833
  };
834
834
  }), ll = /* @__PURE__ */ _("$ZodCheckStartsWith", (e, t) => {
835
- ie.init(e, t);
835
+ ce.init(e, t);
836
836
  const r = new RegExp(`^${xt(t.prefix)}.*`);
837
837
  t.pattern ?? (t.pattern = r), e._zod.onattach.push((n) => {
838
838
  const o = n._zod.bag;
@@ -849,7 +849,7 @@ const Jc = (e) => {
849
849
  });
850
850
  };
851
851
  }), ul = /* @__PURE__ */ _("$ZodCheckEndsWith", (e, t) => {
852
- ie.init(e, t);
852
+ ce.init(e, t);
853
853
  const r = new RegExp(`.*${xt(t.suffix)}$`);
854
854
  t.pattern ?? (t.pattern = r), e._zod.onattach.push((n) => {
855
855
  const o = n._zod.bag;
@@ -866,7 +866,7 @@ const Jc = (e) => {
866
866
  });
867
867
  };
868
868
  }), dl = /* @__PURE__ */ _("$ZodCheckOverwrite", (e, t) => {
869
- ie.init(e, t), e._zod.check = (r) => {
869
+ ce.init(e, t), e._zod.check = (r) => {
870
870
  r.value = t.tx(r.value);
871
871
  };
872
872
  });
@@ -992,7 +992,7 @@ const fl = {
992
992
  t.pattern ?? (t.pattern = In());
993
993
  V.init(e, t);
994
994
  }), gl = /* @__PURE__ */ _("$ZodEmail", (e, t) => {
995
- t.pattern ?? (t.pattern = zc), V.init(e, t);
995
+ t.pattern ?? (t.pattern = Mc), V.init(e, t);
996
996
  }), vl = /* @__PURE__ */ _("$ZodURL", (e, t) => {
997
997
  V.init(e, t), e._zod.check = (r) => {
998
998
  try {
@@ -1118,17 +1118,17 @@ const Rl = /* @__PURE__ */ _("$ZodBase64", (e, t) => {
1118
1118
  });
1119
1119
  };
1120
1120
  });
1121
- function zl(e) {
1121
+ function Ml(e) {
1122
1122
  if (!as.test(e))
1123
1123
  return !1;
1124
1124
  const t = e.replace(/[-_]/g, (n) => n === "-" ? "+" : "/"), r = t.padEnd(Math.ceil(t.length / 4) * 4, "=");
1125
1125
  return ps(r);
1126
1126
  }
1127
- const Ml = /* @__PURE__ */ _("$ZodBase64URL", (e, t) => {
1127
+ const zl = /* @__PURE__ */ _("$ZodBase64URL", (e, t) => {
1128
1128
  t.pattern ?? (t.pattern = as), V.init(e, t), e._zod.onattach.push((r) => {
1129
1129
  r._zod.bag.contentEncoding = "base64url";
1130
1130
  }), e._zod.check = (r) => {
1131
- zl(r.value) || r.issues.push({
1131
+ Ml(r.value) || r.issues.push({
1132
1132
  code: "invalid_format",
1133
1133
  format: "base64url",
1134
1134
  input: r.value,
@@ -1220,7 +1220,7 @@ const Dl = /* @__PURE__ */ _("$ZodJWT", (e, t) => {
1220
1220
  }), r);
1221
1221
  });
1222
1222
  function En(e, t, r) {
1223
- e.issues.length && t.issues.push(...Ye(r, e.issues)), t.value[r] = e.value;
1223
+ e.issues.length && t.issues.push(...qe(r, e.issues)), t.value[r] = e.value;
1224
1224
  }
1225
1225
  const Vl = /* @__PURE__ */ _("$ZodArray", (e, t) => {
1226
1226
  F.init(e, t), e._zod.parse = (r, n) => {
@@ -1244,11 +1244,11 @@ const Vl = /* @__PURE__ */ _("$ZodArray", (e, t) => {
1244
1244
  return s.length ? Promise.all(s).then(() => r) : r;
1245
1245
  };
1246
1246
  });
1247
- function Mt(e, t, r) {
1248
- e.issues.length && t.issues.push(...Ye(r, e.issues)), t.value[r] = e.value;
1247
+ function zt(e, t, r) {
1248
+ e.issues.length && t.issues.push(...qe(r, e.issues)), t.value[r] = e.value;
1249
1249
  }
1250
1250
  function Tn(e, t, r, n) {
1251
- e.issues.length ? n[r] === void 0 ? r in n ? t.value[r] = void 0 : t.value[r] = e.value : t.issues.push(...Ye(r, e.issues)) : e.value === void 0 ? r in n && (t.value[r] = void 0) : t.value[r] = e.value;
1251
+ e.issues.length ? n[r] === void 0 ? r in n ? t.value[r] = void 0 : t.value[r] = e.value : t.issues.push(...qe(r, e.issues)) : e.value === void 0 ? r in n && (t.value[r] = void 0) : t.value[r] = e.value;
1252
1252
  }
1253
1253
  const Hl = /* @__PURE__ */ _("$ZodObject", (e, t) => {
1254
1254
  F.init(e, t);
@@ -1347,7 +1347,7 @@ const Hl = /* @__PURE__ */ _("$ZodObject", (e, t) => {
1347
1347
  const I = d.shape;
1348
1348
  for (const h of d.keys) {
1349
1349
  const S = I[h], x = S._zod.run({ value: g[h], issues: [] }, y), E = S._zod.optin === "optional" && S._zod.optout === "optional";
1350
- x instanceof Promise ? f.push(x.then((k) => E ? Tn(k, u, h, g) : Mt(k, u, h))) : E ? Tn(x, u, h, g) : Mt(x, u, h);
1350
+ x instanceof Promise ? f.push(x.then((C) => E ? Tn(C, u, h, g) : zt(C, u, h))) : E ? Tn(x, u, h, g) : zt(x, u, h);
1351
1351
  }
1352
1352
  }
1353
1353
  if (!c)
@@ -1361,7 +1361,7 @@ const Hl = /* @__PURE__ */ _("$ZodObject", (e, t) => {
1361
1361
  continue;
1362
1362
  }
1363
1363
  const h = b.run({ value: g[I], issues: [] }, y);
1364
- h instanceof Promise ? f.push(h.then((S) => Mt(S, u, I))) : Mt(h, u, I);
1364
+ h instanceof Promise ? f.push(h.then((S) => zt(S, u, I))) : zt(h, u, I);
1365
1365
  }
1366
1366
  return m.length && u.issues.push({
1367
1367
  code: "unrecognized_keys",
@@ -1379,7 +1379,7 @@ function Sn(e, t, r, n) {
1379
1379
  code: "invalid_union",
1380
1380
  input: t.value,
1381
1381
  inst: r,
1382
- errors: e.map((o) => o.issues.map((s) => Le(s, n, De())))
1382
+ errors: e.map((o) => o.issues.map((s) => Ue(s, n, Le())))
1383
1383
  }), t;
1384
1384
  }
1385
1385
  const ms = /* @__PURE__ */ _("$ZodUnion", (e, t) => {
@@ -1526,8 +1526,8 @@ const Wl = /* @__PURE__ */ _("$ZodRecord", (e, t) => {
1526
1526
  if (typeof l == "string" || typeof l == "number" || typeof l == "symbol") {
1527
1527
  const c = t.valueType._zod.run({ value: o[l], issues: [] }, n);
1528
1528
  c instanceof Promise ? s.push(c.then((d) => {
1529
- d.issues.length && r.issues.push(...Ye(l, d.issues)), r.value[l] = d.value;
1530
- })) : (c.issues.length && r.issues.push(...Ye(l, c.issues)), r.value[l] = c.value);
1529
+ d.issues.length && r.issues.push(...qe(l, d.issues)), r.value[l] = d.value;
1530
+ })) : (c.issues.length && r.issues.push(...qe(l, c.issues)), r.value[l] = c.value);
1531
1531
  }
1532
1532
  let a;
1533
1533
  for (const l in o)
@@ -1550,7 +1550,7 @@ const Wl = /* @__PURE__ */ _("$ZodRecord", (e, t) => {
1550
1550
  r.issues.push({
1551
1551
  origin: "record",
1552
1552
  code: "invalid_key",
1553
- issues: a.issues.map((c) => Le(c, n, De())),
1553
+ issues: a.issues.map((c) => Ue(c, n, Le())),
1554
1554
  input: i,
1555
1555
  path: [i],
1556
1556
  inst: e
@@ -1559,8 +1559,8 @@ const Wl = /* @__PURE__ */ _("$ZodRecord", (e, t) => {
1559
1559
  }
1560
1560
  const l = t.valueType._zod.run({ value: o[i], issues: [] }, n);
1561
1561
  l instanceof Promise ? s.push(l.then((c) => {
1562
- c.issues.length && r.issues.push(...Ye(i, c.issues)), r.value[a.value] = c.value;
1563
- })) : (l.issues.length && r.issues.push(...Ye(i, l.issues)), r.value[a.value] = l.value);
1562
+ c.issues.length && r.issues.push(...qe(i, c.issues)), r.value[a.value] = c.value;
1563
+ })) : (l.issues.length && r.issues.push(...qe(i, l.issues)), r.value[a.value] = l.value);
1564
1564
  }
1565
1565
  }
1566
1566
  return s.length ? Promise.all(s).then(() => r) : r;
@@ -1642,13 +1642,13 @@ const nu = /* @__PURE__ */ _("$ZodCatch", (e, t) => {
1642
1642
  return o instanceof Promise ? o.then((s) => (r.value = s.value, s.issues.length && (r.value = t.catchValue({
1643
1643
  ...r,
1644
1644
  error: {
1645
- issues: s.issues.map((i) => Le(i, n, De()))
1645
+ issues: s.issues.map((i) => Ue(i, n, Le()))
1646
1646
  },
1647
1647
  input: r.value
1648
1648
  }), r.issues = []), r)) : (r.value = o.value, o.issues.length && (r.value = t.catchValue({
1649
1649
  ...r,
1650
1650
  error: {
1651
- issues: o.issues.map((s) => Le(s, n, De()))
1651
+ issues: o.issues.map((s) => Ue(s, n, Le()))
1652
1652
  },
1653
1653
  input: r.value
1654
1654
  }), r.issues = []), r);
@@ -1674,7 +1674,7 @@ function Nn(e) {
1674
1674
  const au = /* @__PURE__ */ _("$ZodLazy", (e, t) => {
1675
1675
  F.init(e, t), L(e._zod, "innerType", () => t.getter()), L(e._zod, "pattern", () => e._zod.innerType._zod.pattern), L(e._zod, "propValues", () => e._zod.innerType._zod.propValues), L(e._zod, "optin", () => e._zod.innerType._zod.optin), L(e._zod, "optout", () => e._zod.innerType._zod.optout), e._zod.parse = (r, n) => e._zod.innerType._zod.run(r, n);
1676
1676
  }), iu = /* @__PURE__ */ _("$ZodCustom", (e, t) => {
1677
- ie.init(e, t), F.init(e, t), e._zod.parse = (r, n) => r, e._zod.check = (r) => {
1677
+ ce.init(e, t), F.init(e, t), e._zod.parse = (r, n) => r, e._zod.check = (r) => {
1678
1678
  const n = r.value, o = t.fn(n);
1679
1679
  if (o instanceof Promise)
1680
1680
  return o.then((s) => On(s, r, n, e));
@@ -1967,7 +1967,7 @@ function Ru(e, t) {
1967
1967
  ...T(t)
1968
1968
  });
1969
1969
  }
1970
- function zu(e, t) {
1970
+ function Mu(e, t) {
1971
1971
  return new e({
1972
1972
  type: "string",
1973
1973
  format: "duration",
@@ -1975,7 +1975,7 @@ function zu(e, t) {
1975
1975
  ...T(t)
1976
1976
  });
1977
1977
  }
1978
- function Mu(e, t) {
1978
+ function zu(e, t) {
1979
1979
  return new e({
1980
1980
  type: "number",
1981
1981
  checks: [],
@@ -2030,7 +2030,7 @@ function hr(e, t) {
2030
2030
  inclusive: !0
2031
2031
  });
2032
2032
  }
2033
- function zn(e, t) {
2033
+ function Mn(e, t) {
2034
2034
  return new ds({
2035
2035
  check: "greater_than",
2036
2036
  ...T(t),
@@ -2046,7 +2046,7 @@ function gr(e, t) {
2046
2046
  inclusive: !0
2047
2047
  });
2048
2048
  }
2049
- function Mn(e, t) {
2049
+ function zn(e, t) {
2050
2050
  return new el({
2051
2051
  check: "multiple_of",
2052
2052
  ...T(t),
@@ -2458,7 +2458,7 @@ class $n {
2458
2458
  }
2459
2459
  }
2460
2460
  const c = this.metadataRegistry.get(t);
2461
- return c && Object.assign(a.schema, c), this.io === "input" && K(t) && (delete a.schema.examples, delete a.schema.default), this.io === "input" && a.schema._prefault && ((n = a.schema).default ?? (n.default = a.schema._prefault)), delete a.schema._prefault, this.seen.get(t).schema;
2461
+ return c && Object.assign(a.schema, c), this.io === "input" && ee(t) && (delete a.schema.examples, delete a.schema.default), this.io === "input" && a.schema._prefault && ((n = a.schema).default ?? (n.default = a.schema._prefault)), delete a.schema._prefault, this.seen.get(t).schema;
2462
2462
  }
2463
2463
  emit(t, r) {
2464
2464
  const n = {
@@ -2596,7 +2596,7 @@ function ed(e, t) {
2596
2596
  const r = new $n(t);
2597
2597
  return r.process(e), r.emit(e, t);
2598
2598
  }
2599
- function K(e, t) {
2599
+ function ee(e, t) {
2600
2600
  const r = t ?? { seen: /* @__PURE__ */ new Set() };
2601
2601
  if (r.seen.has(e))
2602
2602
  return !1;
@@ -2622,52 +2622,52 @@ function K(e, t) {
2622
2622
  case "template_literal":
2623
2623
  return !1;
2624
2624
  case "array":
2625
- return K(o.element, r);
2625
+ return ee(o.element, r);
2626
2626
  case "object": {
2627
2627
  for (const s in o.shape)
2628
- if (K(o.shape[s], r))
2628
+ if (ee(o.shape[s], r))
2629
2629
  return !0;
2630
2630
  return !1;
2631
2631
  }
2632
2632
  case "union": {
2633
2633
  for (const s of o.options)
2634
- if (K(s, r))
2634
+ if (ee(s, r))
2635
2635
  return !0;
2636
2636
  return !1;
2637
2637
  }
2638
2638
  case "intersection":
2639
- return K(o.left, r) || K(o.right, r);
2639
+ return ee(o.left, r) || ee(o.right, r);
2640
2640
  case "tuple": {
2641
2641
  for (const s of o.items)
2642
- if (K(s, r))
2642
+ if (ee(s, r))
2643
2643
  return !0;
2644
- return !!(o.rest && K(o.rest, r));
2644
+ return !!(o.rest && ee(o.rest, r));
2645
2645
  }
2646
2646
  case "record":
2647
- return K(o.keyType, r) || K(o.valueType, r);
2647
+ return ee(o.keyType, r) || ee(o.valueType, r);
2648
2648
  case "map":
2649
- return K(o.keyType, r) || K(o.valueType, r);
2649
+ return ee(o.keyType, r) || ee(o.valueType, r);
2650
2650
  case "set":
2651
- return K(o.valueType, r);
2651
+ return ee(o.valueType, r);
2652
2652
  // inner types
2653
2653
  case "promise":
2654
2654
  case "optional":
2655
2655
  case "nonoptional":
2656
2656
  case "nullable":
2657
2657
  case "readonly":
2658
- return K(o.innerType, r);
2658
+ return ee(o.innerType, r);
2659
2659
  case "lazy":
2660
- return K(o.getter(), r);
2660
+ return ee(o.getter(), r);
2661
2661
  case "default":
2662
- return K(o.innerType, r);
2662
+ return ee(o.innerType, r);
2663
2663
  case "prefault":
2664
- return K(o.innerType, r);
2664
+ return ee(o.innerType, r);
2665
2665
  case "custom":
2666
2666
  return !1;
2667
2667
  case "transform":
2668
2668
  return !0;
2669
2669
  case "pipe":
2670
- return K(o.in, r) || K(o.out, r);
2670
+ return ee(o.in, r) || ee(o.out, r);
2671
2671
  case "success":
2672
2672
  return !1;
2673
2673
  case "catch":
@@ -2676,28 +2676,28 @@ function K(e, t) {
2676
2676
  throw new Error(`Unknown schema type: ${o.type}`);
2677
2677
  }
2678
2678
  const td = /* @__PURE__ */ _("ZodISODateTime", (e, t) => {
2679
- Sl.init(e, t), J.init(e, t);
2679
+ Sl.init(e, t), W.init(e, t);
2680
2680
  });
2681
2681
  function rd(e) {
2682
2682
  return Ou(td, e);
2683
2683
  }
2684
2684
  const nd = /* @__PURE__ */ _("ZodISODate", (e, t) => {
2685
- kl.init(e, t), J.init(e, t);
2685
+ kl.init(e, t), W.init(e, t);
2686
2686
  });
2687
2687
  function od(e) {
2688
2688
  return Pu(nd, e);
2689
2689
  }
2690
2690
  const sd = /* @__PURE__ */ _("ZodISOTime", (e, t) => {
2691
- Cl.init(e, t), J.init(e, t);
2691
+ Cl.init(e, t), W.init(e, t);
2692
2692
  });
2693
2693
  function ad(e) {
2694
2694
  return Ru(sd, e);
2695
2695
  }
2696
2696
  const id = /* @__PURE__ */ _("ZodISODuration", (e, t) => {
2697
- xl.init(e, t), J.init(e, t);
2697
+ xl.init(e, t), W.init(e, t);
2698
2698
  });
2699
2699
  function cd(e) {
2700
- return zu(id, e);
2700
+ return Mu(id, e);
2701
2701
  }
2702
2702
  const ld = (e, t) => {
2703
2703
  rs.init(e, t), e.name = "ZodError", Object.defineProperties(e, {
@@ -2735,7 +2735,7 @@ const ld = (e, t) => {
2735
2735
  ]
2736
2736
  }
2737
2737
  // { parent: true }
2738
- ), e.clone = (r, n) => Qe(e, r, n), e.brand = () => e, e.register = ((r, n) => (r.add(e, n), e)), e.parse = (r, n) => ud(e, r, n, { callee: e.parse }), e.safeParse = (r, n) => pd(e, r, n), e.parseAsync = async (r, n) => dd(e, r, n, { callee: e.parseAsync }), e.safeParseAsync = async (r, n) => ys(e, r, n), e.spa = e.safeParseAsync, e.refine = (r, n) => e.check(ip(r, n)), e.superRefine = (r) => e.check(cp(r)), e.overwrite = (r) => e.check(At(r)), e.optional = () => Ln(e), e.nullable = () => Un(e), e.nullish = () => Ln(Un(e)), e.nonoptional = (r) => Qd(e, r), e.array = () => ct(e), e.or = (r) => me([e, r]), e.and = (r) => Fd(e, r), e.transform = (r) => jn(e, Gd(r)), e.default = (r) => Yd(e, r), e.prefault = (r) => Xd(e, r), e.catch = (r) => ep(e, r), e.pipe = (r) => jn(e, r), e.readonly = () => np(e), e.describe = (r) => {
2738
+ ), e.clone = (r, n) => Ke(e, r, n), e.brand = () => e, e.register = ((r, n) => (r.add(e, n), e)), e.parse = (r, n) => ud(e, r, n, { callee: e.parse }), e.safeParse = (r, n) => pd(e, r, n), e.parseAsync = async (r, n) => dd(e, r, n, { callee: e.parseAsync }), e.safeParseAsync = async (r, n) => ys(e, r, n), e.spa = e.safeParseAsync, e.refine = (r, n) => e.check(ip(r, n)), e.superRefine = (r) => e.check(cp(r)), e.overwrite = (r) => e.check(At(r)), e.optional = () => Ln(e), e.nullable = () => Un(e), e.nullish = () => Ln(Un(e)), e.nonoptional = (r) => Qd(e, r), e.array = () => ct(e), e.or = (r) => ge([e, r]), e.and = (r) => Fd(e, r), e.transform = (r) => jn(e, Gd(r)), e.default = (r) => Yd(e, r), e.prefault = (r) => Xd(e, r), e.catch = (r) => ep(e, r), e.pipe = (r) => jn(e, r), e.readonly = () => np(e), e.describe = (r) => {
2739
2739
  const n = e.clone();
2740
2740
  return pt.add(n, { description: r }), n;
2741
2741
  }, Object.defineProperty(e, "description", {
@@ -2755,56 +2755,56 @@ const ld = (e, t) => {
2755
2755
  }), fd = /* @__PURE__ */ _("ZodString", (e, t) => {
2756
2756
  Qr.init(e, t), _s.init(e, t), e.email = (r) => e.check(uu(md, r)), e.url = (r) => e.check(hu(hd, r)), e.jwt = (r) => e.check(Nu(Nd, r)), e.emoji = (r) => e.check(gu(gd, r)), e.guid = (r) => e.check(Pn(Zn, r)), e.uuid = (r) => e.check(du($t, r)), e.uuidv4 = (r) => e.check(pu($t, r)), e.uuidv6 = (r) => e.check(fu($t, r)), e.uuidv7 = (r) => e.check(mu($t, r)), e.nanoid = (r) => e.check(vu(vd, r)), e.guid = (r) => e.check(Pn(Zn, r)), e.cuid = (r) => e.check(yu(yd, r)), e.cuid2 = (r) => e.check(_u(_d, r)), e.ulid = (r) => e.check(bu(bd, r)), e.base64 = (r) => e.check(Cu(Cd, r)), e.base64url = (r) => e.check(xu(xd, r)), e.xid = (r) => e.check(wu(wd, r)), e.ksuid = (r) => e.check(Iu(Id, r)), e.ipv4 = (r) => e.check(Eu(Ed, r)), e.ipv6 = (r) => e.check(Tu(Td, r)), e.cidrv4 = (r) => e.check(Su(Sd, r)), e.cidrv6 = (r) => e.check(ku(kd, r)), e.e164 = (r) => e.check(Au(Ad, r)), e.datetime = (r) => e.check(rd(r)), e.date = (r) => e.check(od(r)), e.time = (r) => e.check(ad(r)), e.duration = (r) => e.check(cd(r));
2757
2757
  });
2758
- function C(e) {
2758
+ function k(e) {
2759
2759
  return lu(fd, e);
2760
2760
  }
2761
- const J = /* @__PURE__ */ _("ZodStringFormat", (e, t) => {
2761
+ const W = /* @__PURE__ */ _("ZodStringFormat", (e, t) => {
2762
2762
  V.init(e, t), _s.init(e, t);
2763
2763
  }), md = /* @__PURE__ */ _("ZodEmail", (e, t) => {
2764
- gl.init(e, t), J.init(e, t);
2764
+ gl.init(e, t), W.init(e, t);
2765
2765
  }), Zn = /* @__PURE__ */ _("ZodGUID", (e, t) => {
2766
- ml.init(e, t), J.init(e, t);
2766
+ ml.init(e, t), W.init(e, t);
2767
2767
  }), $t = /* @__PURE__ */ _("ZodUUID", (e, t) => {
2768
- hl.init(e, t), J.init(e, t);
2768
+ hl.init(e, t), W.init(e, t);
2769
2769
  }), hd = /* @__PURE__ */ _("ZodURL", (e, t) => {
2770
- vl.init(e, t), J.init(e, t);
2770
+ vl.init(e, t), W.init(e, t);
2771
2771
  }), gd = /* @__PURE__ */ _("ZodEmoji", (e, t) => {
2772
- yl.init(e, t), J.init(e, t);
2772
+ yl.init(e, t), W.init(e, t);
2773
2773
  }), vd = /* @__PURE__ */ _("ZodNanoID", (e, t) => {
2774
- _l.init(e, t), J.init(e, t);
2774
+ _l.init(e, t), W.init(e, t);
2775
2775
  }), yd = /* @__PURE__ */ _("ZodCUID", (e, t) => {
2776
- bl.init(e, t), J.init(e, t);
2776
+ bl.init(e, t), W.init(e, t);
2777
2777
  }), _d = /* @__PURE__ */ _("ZodCUID2", (e, t) => {
2778
- wl.init(e, t), J.init(e, t);
2778
+ wl.init(e, t), W.init(e, t);
2779
2779
  }), bd = /* @__PURE__ */ _("ZodULID", (e, t) => {
2780
- Il.init(e, t), J.init(e, t);
2780
+ Il.init(e, t), W.init(e, t);
2781
2781
  }), wd = /* @__PURE__ */ _("ZodXID", (e, t) => {
2782
- El.init(e, t), J.init(e, t);
2782
+ El.init(e, t), W.init(e, t);
2783
2783
  }), Id = /* @__PURE__ */ _("ZodKSUID", (e, t) => {
2784
- Tl.init(e, t), J.init(e, t);
2784
+ Tl.init(e, t), W.init(e, t);
2785
2785
  }), Ed = /* @__PURE__ */ _("ZodIPv4", (e, t) => {
2786
- Al.init(e, t), J.init(e, t);
2786
+ Al.init(e, t), W.init(e, t);
2787
2787
  }), Td = /* @__PURE__ */ _("ZodIPv6", (e, t) => {
2788
- Nl.init(e, t), J.init(e, t);
2788
+ Nl.init(e, t), W.init(e, t);
2789
2789
  }), Sd = /* @__PURE__ */ _("ZodCIDRv4", (e, t) => {
2790
- Ol.init(e, t), J.init(e, t);
2790
+ Ol.init(e, t), W.init(e, t);
2791
2791
  }), kd = /* @__PURE__ */ _("ZodCIDRv6", (e, t) => {
2792
- Pl.init(e, t), J.init(e, t);
2792
+ Pl.init(e, t), W.init(e, t);
2793
2793
  }), Cd = /* @__PURE__ */ _("ZodBase64", (e, t) => {
2794
- Rl.init(e, t), J.init(e, t);
2794
+ Rl.init(e, t), W.init(e, t);
2795
2795
  }), xd = /* @__PURE__ */ _("ZodBase64URL", (e, t) => {
2796
- Ml.init(e, t), J.init(e, t);
2796
+ zl.init(e, t), W.init(e, t);
2797
2797
  }), Ad = /* @__PURE__ */ _("ZodE164", (e, t) => {
2798
- $l.init(e, t), J.init(e, t);
2798
+ $l.init(e, t), W.init(e, t);
2799
2799
  }), Nd = /* @__PURE__ */ _("ZodJWT", (e, t) => {
2800
- Dl.init(e, t), J.init(e, t);
2800
+ Dl.init(e, t), W.init(e, t);
2801
2801
  }), bs = /* @__PURE__ */ _("ZodNumber", (e, t) => {
2802
- fs.init(e, t), H.init(e, t), e.gt = (n, o) => e.check(zn(n, o)), e.gte = (n, o) => e.check(gr(n, o)), e.min = (n, o) => e.check(gr(n, o)), e.lt = (n, o) => e.check(Rn(n, o)), e.lte = (n, o) => e.check(hr(n, o)), e.max = (n, o) => e.check(hr(n, o)), e.int = (n) => e.check(Dn(n)), e.safe = (n) => e.check(Dn(n)), e.positive = (n) => e.check(zn(0, n)), e.nonnegative = (n) => e.check(gr(0, n)), e.negative = (n) => e.check(Rn(0, n)), e.nonpositive = (n) => e.check(hr(0, n)), e.multipleOf = (n, o) => e.check(Mn(n, o)), e.step = (n, o) => e.check(Mn(n, o)), e.finite = () => e;
2802
+ fs.init(e, t), H.init(e, t), e.gt = (n, o) => e.check(Mn(n, o)), e.gte = (n, o) => e.check(gr(n, o)), e.min = (n, o) => e.check(gr(n, o)), e.lt = (n, o) => e.check(Rn(n, o)), e.lte = (n, o) => e.check(hr(n, o)), e.max = (n, o) => e.check(hr(n, o)), e.int = (n) => e.check(Dn(n)), e.safe = (n) => e.check(Dn(n)), e.positive = (n) => e.check(Mn(0, n)), e.nonnegative = (n) => e.check(gr(0, n)), e.negative = (n) => e.check(Rn(0, n)), e.nonpositive = (n) => e.check(hr(0, n)), e.multipleOf = (n, o) => e.check(zn(n, o)), e.step = (n, o) => e.check(zn(n, o)), e.finite = () => e;
2803
2803
  const r = e._zod.bag;
2804
2804
  e.minValue = Math.max(r.minimum ?? Number.NEGATIVE_INFINITY, r.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null, e.maxValue = Math.min(r.maximum ?? Number.POSITIVE_INFINITY, r.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null, e.isInt = (r.format ?? "").includes("int") || Number.isSafeInteger(r.multipleOf ?? 0.5), e.isFinite = !0, e.format = r.format ?? null;
2805
2805
  });
2806
2806
  function Od(e) {
2807
- return Mu(bs, e);
2807
+ return zu(bs, e);
2808
2808
  }
2809
2809
  const Pd = /* @__PURE__ */ _("ZodNumberFormat", (e, t) => {
2810
2810
  Ll.init(e, t), bs.init(e, t);
@@ -2815,19 +2815,19 @@ function Dn(e) {
2815
2815
  const Rd = /* @__PURE__ */ _("ZodBoolean", (e, t) => {
2816
2816
  Ul.init(e, t), H.init(e, t);
2817
2817
  });
2818
- function ae(e) {
2818
+ function ie(e) {
2819
2819
  return Zu(Rd, e);
2820
2820
  }
2821
- const zd = /* @__PURE__ */ _("ZodNull", (e, t) => {
2821
+ const Md = /* @__PURE__ */ _("ZodNull", (e, t) => {
2822
2822
  jl.init(e, t), H.init(e, t);
2823
2823
  });
2824
- function Md(e) {
2825
- return Du(zd, e);
2824
+ function zd(e) {
2825
+ return Du(Md, e);
2826
2826
  }
2827
2827
  const $d = /* @__PURE__ */ _("ZodUnknown", (e, t) => {
2828
2828
  Fl.init(e, t), H.init(e, t);
2829
2829
  });
2830
- function Se() {
2830
+ function ke() {
2831
2831
  return Lu($d);
2832
2832
  }
2833
2833
  const Zd = /* @__PURE__ */ _("ZodNever", (e, t) => {
@@ -2843,7 +2843,7 @@ function ct(e, t) {
2843
2843
  return Xu(Dd, e, t);
2844
2844
  }
2845
2845
  const Is = /* @__PURE__ */ _("ZodObject", (e, t) => {
2846
- Hl.init(e, t), H.init(e, t), L(e, "shape", () => t.shape), e.keyof = () => Ts(Object.keys(e._zod.def.shape)), e.catchall = (r) => e.clone({ ...e._zod.def, catchall: r }), e.passthrough = () => e.clone({ ...e._zod.def, catchall: Se() }), e.loose = () => e.clone({ ...e._zod.def, catchall: Se() }), e.strict = () => e.clone({ ...e._zod.def, catchall: ws() }), e.strip = () => e.clone({ ...e._zod.def, catchall: void 0 }), e.extend = (r) => gc(e, r), e.merge = (r) => vc(e, r), e.pick = (r) => mc(e, r), e.omit = (r) => hc(e, r), e.partial = (...r) => yc(Ss, e, r[0]), e.required = (...r) => _c(ks, e, r[0]);
2846
+ Hl.init(e, t), H.init(e, t), L(e, "shape", () => t.shape), e.keyof = () => Ts(Object.keys(e._zod.def.shape)), e.catchall = (r) => e.clone({ ...e._zod.def, catchall: r }), e.passthrough = () => e.clone({ ...e._zod.def, catchall: ke() }), e.loose = () => e.clone({ ...e._zod.def, catchall: ke() }), e.strict = () => e.clone({ ...e._zod.def, catchall: ws() }), e.strip = () => e.clone({ ...e._zod.def, catchall: void 0 }), e.extend = (r) => gc(e, r), e.merge = (r) => vc(e, r), e.pick = (r) => mc(e, r), e.omit = (r) => hc(e, r), e.partial = (...r) => yc(Ss, e, r[0]), e.required = (...r) => _c(ks, e, r[0]);
2847
2847
  });
2848
2848
  function oe(e, t) {
2849
2849
  const r = {
@@ -2868,7 +2868,7 @@ function G(e, t) {
2868
2868
  const Es = /* @__PURE__ */ _("ZodUnion", (e, t) => {
2869
2869
  ms.init(e, t), H.init(e, t), e.options = t.options;
2870
2870
  });
2871
- function me(e, t) {
2871
+ function ge(e, t) {
2872
2872
  return new Es({
2873
2873
  type: "union",
2874
2874
  options: e,
@@ -2955,7 +2955,7 @@ const Vd = /* @__PURE__ */ _("ZodLiteral", (e, t) => {
2955
2955
  }
2956
2956
  });
2957
2957
  });
2958
- function R(e, t) {
2958
+ function P(e, t) {
2959
2959
  return new Vd({
2960
2960
  type: "literal",
2961
2961
  values: Array.isArray(e) ? e : [e],
@@ -3077,7 +3077,7 @@ const Kr = /* @__PURE__ */ _("ZodCustom", (e, t) => {
3077
3077
  iu.init(e, t), H.init(e, t);
3078
3078
  });
3079
3079
  function ap(e) {
3080
- const t = new ie({
3080
+ const t = new ce({
3081
3081
  check: "custom"
3082
3082
  // ...util.normalizeParams(params),
3083
3083
  });
@@ -3141,7 +3141,7 @@ function Fn(e = globalThis) {
3141
3141
  var t, r, n;
3142
3142
  return e.window ? "runtime/browser" : (t = e.navigator) != null && t.userAgent ? `runtime/${e.navigator.userAgent.toLowerCase()}` : (n = (r = e.process) == null ? void 0 : r.versions) != null && n.node ? `runtime/node.js/${e.process.version.substring(0)}` : e.EdgeRuntime ? "runtime/vercel-edge" : "runtime/unknown";
3143
3143
  }
3144
- function We(e) {
3144
+ function Ye(e) {
3145
3145
  if (e == null)
3146
3146
  return {};
3147
3147
  const t = {};
@@ -3157,7 +3157,7 @@ function We(e) {
3157
3157
  return t;
3158
3158
  }
3159
3159
  function Bn(e, ...t) {
3160
- const r = new Headers(We(e)), n = r.get("user-agent") || "";
3160
+ const r = new Headers(Ye(e)), n = r.get("user-agent") || "";
3161
3161
  return r.set(
3162
3162
  "user-agent",
3163
3163
  [n, ...t].filter(Boolean).join(" ")
@@ -3447,7 +3447,7 @@ function Rp(e) {
3447
3447
  const: e.value
3448
3448
  };
3449
3449
  }
3450
- var vr = void 0, ve = {
3450
+ var vr = void 0, _e = {
3451
3451
  /**
3452
3452
  * `c` was changed to `[cC]` to replicate /i flag
3453
3453
  */
@@ -3508,33 +3508,33 @@ function Ns(e, t) {
3508
3508
  case "email":
3509
3509
  switch (t.emailStrategy) {
3510
3510
  case "format:email":
3511
- ye(r, "email", n.message, t);
3511
+ be(r, "email", n.message, t);
3512
3512
  break;
3513
3513
  case "format:idn-email":
3514
- ye(r, "idn-email", n.message, t);
3514
+ be(r, "idn-email", n.message, t);
3515
3515
  break;
3516
3516
  case "pattern:zod":
3517
- se(r, ve.email, n.message, t);
3517
+ ae(r, _e.email, n.message, t);
3518
3518
  break;
3519
3519
  }
3520
3520
  break;
3521
3521
  case "url":
3522
- ye(r, "uri", n.message, t);
3522
+ be(r, "uri", n.message, t);
3523
3523
  break;
3524
3524
  case "uuid":
3525
- ye(r, "uuid", n.message, t);
3525
+ be(r, "uuid", n.message, t);
3526
3526
  break;
3527
3527
  case "regex":
3528
- se(r, n.regex, n.message, t);
3528
+ ae(r, n.regex, n.message, t);
3529
3529
  break;
3530
3530
  case "cuid":
3531
- se(r, ve.cuid, n.message, t);
3531
+ ae(r, _e.cuid, n.message, t);
3532
3532
  break;
3533
3533
  case "cuid2":
3534
- se(r, ve.cuid2, n.message, t);
3534
+ ae(r, _e.cuid2, n.message, t);
3535
3535
  break;
3536
3536
  case "startsWith":
3537
- se(
3537
+ ae(
3538
3538
  r,
3539
3539
  RegExp(`^${yr(n.value, t)}`),
3540
3540
  n.message,
@@ -3542,7 +3542,7 @@ function Ns(e, t) {
3542
3542
  );
3543
3543
  break;
3544
3544
  case "endsWith":
3545
- se(
3545
+ ae(
3546
3546
  r,
3547
3547
  RegExp(`${yr(n.value, t)}$`),
3548
3548
  n.message,
@@ -3550,22 +3550,22 @@ function Ns(e, t) {
3550
3550
  );
3551
3551
  break;
3552
3552
  case "datetime":
3553
- ye(r, "date-time", n.message, t);
3553
+ be(r, "date-time", n.message, t);
3554
3554
  break;
3555
3555
  case "date":
3556
- ye(r, "date", n.message, t);
3556
+ be(r, "date", n.message, t);
3557
3557
  break;
3558
3558
  case "time":
3559
- ye(r, "time", n.message, t);
3559
+ be(r, "time", n.message, t);
3560
3560
  break;
3561
3561
  case "duration":
3562
- ye(r, "duration", n.message, t);
3562
+ be(r, "duration", n.message, t);
3563
3563
  break;
3564
3564
  case "length":
3565
3565
  r.minLength = typeof r.minLength == "number" ? Math.max(r.minLength, n.value) : n.value, r.maxLength = typeof r.maxLength == "number" ? Math.min(r.maxLength, n.value) : n.value;
3566
3566
  break;
3567
3567
  case "includes": {
3568
- se(
3568
+ ae(
3569
3569
  r,
3570
3570
  RegExp(yr(n.value, t)),
3571
3571
  n.message,
@@ -3574,30 +3574,30 @@ function Ns(e, t) {
3574
3574
  break;
3575
3575
  }
3576
3576
  case "ip": {
3577
- n.version !== "v6" && ye(r, "ipv4", n.message, t), n.version !== "v4" && ye(r, "ipv6", n.message, t);
3577
+ n.version !== "v6" && be(r, "ipv4", n.message, t), n.version !== "v4" && be(r, "ipv6", n.message, t);
3578
3578
  break;
3579
3579
  }
3580
3580
  case "base64url":
3581
- se(r, ve.base64url, n.message, t);
3581
+ ae(r, _e.base64url, n.message, t);
3582
3582
  break;
3583
3583
  case "jwt":
3584
- se(r, ve.jwt, n.message, t);
3584
+ ae(r, _e.jwt, n.message, t);
3585
3585
  break;
3586
3586
  case "cidr": {
3587
- n.version !== "v6" && se(r, ve.ipv4Cidr, n.message, t), n.version !== "v4" && se(r, ve.ipv6Cidr, n.message, t);
3587
+ n.version !== "v6" && ae(r, _e.ipv4Cidr, n.message, t), n.version !== "v4" && ae(r, _e.ipv6Cidr, n.message, t);
3588
3588
  break;
3589
3589
  }
3590
3590
  case "emoji":
3591
- se(r, ve.emoji(), n.message, t);
3591
+ ae(r, _e.emoji(), n.message, t);
3592
3592
  break;
3593
3593
  case "ulid": {
3594
- se(r, ve.ulid, n.message, t);
3594
+ ae(r, _e.ulid, n.message, t);
3595
3595
  break;
3596
3596
  }
3597
3597
  case "base64": {
3598
3598
  switch (t.base64Strategy) {
3599
3599
  case "format:binary": {
3600
- ye(r, "binary", n.message, t);
3600
+ be(r, "binary", n.message, t);
3601
3601
  break;
3602
3602
  }
3603
3603
  case "contentEncoding:base64": {
@@ -3605,30 +3605,30 @@ function Ns(e, t) {
3605
3605
  break;
3606
3606
  }
3607
3607
  case "pattern:zod": {
3608
- se(r, ve.base64, n.message, t);
3608
+ ae(r, _e.base64, n.message, t);
3609
3609
  break;
3610
3610
  }
3611
3611
  }
3612
3612
  break;
3613
3613
  }
3614
3614
  case "nanoid":
3615
- se(r, ve.nanoid, n.message, t);
3615
+ ae(r, _e.nanoid, n.message, t);
3616
3616
  }
3617
3617
  return r;
3618
3618
  }
3619
3619
  function yr(e, t) {
3620
- return t.patternStrategy === "escape" ? Mp(e) : e;
3620
+ return t.patternStrategy === "escape" ? zp(e) : e;
3621
3621
  }
3622
- var zp = new Set(
3622
+ var Mp = new Set(
3623
3623
  "ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789"
3624
3624
  );
3625
- function Mp(e) {
3625
+ function zp(e) {
3626
3626
  let t = "";
3627
3627
  for (let r = 0; r < e.length; r++)
3628
- zp.has(e[r]) || (t += "\\"), t += e[r];
3628
+ Mp.has(e[r]) || (t += "\\"), t += e[r];
3629
3629
  return t;
3630
3630
  }
3631
- function ye(e, t, r, n) {
3631
+ function be(e, t, r, n) {
3632
3632
  var o;
3633
3633
  e.format || (o = e.anyOf) != null && o.some((s) => s.format) ? (e.anyOf || (e.anyOf = []), e.format && (e.anyOf.push({
3634
3634
  format: e.format
@@ -3637,7 +3637,7 @@ function ye(e, t, r, n) {
3637
3637
  ...r && n.errorMessages && { errorMessage: { format: r } }
3638
3638
  })) : e.format = t;
3639
3639
  }
3640
- function se(e, t, r, n) {
3640
+ function ae(e, t, r, n) {
3641
3641
  var o;
3642
3642
  e.pattern || (o = e.allOf) != null && o.some((s) => s.pattern) ? (e.allOf || (e.allOf = []), e.pattern && (e.allOf.push({
3643
3643
  pattern: e.pattern
@@ -3770,7 +3770,7 @@ function Lp() {
3770
3770
  type: "null"
3771
3771
  };
3772
3772
  }
3773
- var zr = {
3773
+ var Mr = {
3774
3774
  ZodString: "string",
3775
3775
  ZodNumber: "number",
3776
3776
  ZodBigInt: "integer",
@@ -3780,10 +3780,10 @@ var zr = {
3780
3780
  function Up(e, t) {
3781
3781
  const r = e.options instanceof Map ? Array.from(e.options.values()) : e.options;
3782
3782
  if (r.every(
3783
- (n) => n._def.typeName in zr && (!n._def.checks || !n._def.checks.length)
3783
+ (n) => n._def.typeName in Mr && (!n._def.checks || !n._def.checks.length)
3784
3784
  )) {
3785
3785
  const n = r.reduce((o, s) => {
3786
- const i = zr[s._def.typeName];
3786
+ const i = Mr[s._def.typeName];
3787
3787
  return i && !o.includes(i) ? [...o, i] : o;
3788
3788
  }, []);
3789
3789
  return {
@@ -3851,7 +3851,7 @@ function Fp(e, t) {
3851
3851
  ) && (!e.innerType._def.checks || !e.innerType._def.checks.length))
3852
3852
  return {
3853
3853
  type: [
3854
- zr[e.innerType._def.typeName],
3854
+ Mr[e.innerType._def.typeName],
3855
3855
  "null"
3856
3856
  ]
3857
3857
  };
@@ -4224,12 +4224,12 @@ function uf(e) {
4224
4224
  function Ps(e, t) {
4225
4225
  return uf(e) ? lf(e) : cf(e);
4226
4226
  }
4227
- var Mr = Symbol.for("vercel.ai.schema");
4227
+ var zr = Symbol.for("vercel.ai.schema");
4228
4228
  function tn(e, {
4229
4229
  validate: t
4230
4230
  } = {}) {
4231
4231
  return {
4232
- [Mr]: !0,
4232
+ [zr]: !0,
4233
4233
  _type: void 0,
4234
4234
  // should never be used directly
4235
4235
  [er]: !0,
@@ -4240,7 +4240,7 @@ function tn(e, {
4240
4240
  };
4241
4241
  }
4242
4242
  function df(e) {
4243
- return typeof e == "object" && e !== null && Mr in e && e[Mr] === !0 && "jsonSchema" in e && "validate" in e;
4243
+ return typeof e == "object" && e !== null && zr in e && e[zr] === !0 && "jsonSchema" in e && "validate" in e;
4244
4244
  }
4245
4245
  function pf(e) {
4246
4246
  return e == null ? tn({
@@ -4254,7 +4254,7 @@ function ff(e) {
4254
4254
  var mf = Object.defineProperty, hf = (e, t) => {
4255
4255
  for (var r in t)
4256
4256
  mf(e, r, { get: t[r], enumerable: !0 });
4257
- }, Rs = "AI_NoObjectGeneratedError", zs = `vercel.ai.error.${Rs}`, gf = Symbol.for(zs), Ms, Wn = class extends Ze {
4257
+ }, Rs = "AI_NoObjectGeneratedError", Ms = `vercel.ai.error.${Rs}`, gf = Symbol.for(Ms), zs, Wn = class extends De {
4258
4258
  constructor({
4259
4259
  message: e = "No object generated.",
4260
4260
  cause: t,
@@ -4263,15 +4263,15 @@ var mf = Object.defineProperty, hf = (e, t) => {
4263
4263
  usage: o,
4264
4264
  finishReason: s
4265
4265
  }) {
4266
- super({ name: Rs, message: e, cause: t }), this[Ms] = !0, this.text = r, this.response = n, this.usage = o, this.finishReason = s;
4266
+ super({ name: Rs, message: e, cause: t }), this[zs] = !0, this.text = r, this.response = n, this.usage = o, this.finishReason = s;
4267
4267
  }
4268
4268
  static isInstance(e) {
4269
- return Ze.hasMarker(e, zs);
4269
+ return De.hasMarker(e, Ms);
4270
4270
  }
4271
4271
  };
4272
- Ms = gf;
4273
- var Yn = "5.0.102", $s = me([
4274
- C(),
4272
+ zs = gf;
4273
+ var Yn = "5.0.102", $s = ge([
4274
+ k(),
4275
4275
  Kt(Uint8Array),
4276
4276
  Kt(ArrayBuffer),
4277
4277
  Cs(
@@ -4283,101 +4283,101 @@ var Yn = "5.0.102", $s = me([
4283
4283
  { message: "Must be a Buffer" }
4284
4284
  )
4285
4285
  ]), Et = sp(
4286
- () => me([
4287
- Md(),
4288
- C(),
4286
+ () => ge([
4287
+ zd(),
4288
+ k(),
4289
4289
  Od(),
4290
- ae(),
4291
- Pr(C(), Et),
4290
+ ie(),
4291
+ Pr(k(), Et),
4292
4292
  ct(Et)
4293
4293
  ])
4294
- ), Y = Pr(
4295
- C(),
4296
- Pr(C(), Et)
4294
+ ), q = Pr(
4295
+ k(),
4296
+ Pr(k(), Et)
4297
4297
  ), Zs = oe({
4298
- type: R("text"),
4299
- text: C(),
4300
- providerOptions: Y.optional()
4298
+ type: P("text"),
4299
+ text: k(),
4300
+ providerOptions: q.optional()
4301
4301
  }), vf = oe({
4302
- type: R("image"),
4303
- image: me([$s, Kt(URL)]),
4304
- mediaType: C().optional(),
4305
- providerOptions: Y.optional()
4302
+ type: P("image"),
4303
+ image: ge([$s, Kt(URL)]),
4304
+ mediaType: k().optional(),
4305
+ providerOptions: q.optional()
4306
4306
  }), Ds = oe({
4307
- type: R("file"),
4308
- data: me([$s, Kt(URL)]),
4309
- filename: C().optional(),
4310
- mediaType: C(),
4311
- providerOptions: Y.optional()
4307
+ type: P("file"),
4308
+ data: ge([$s, Kt(URL)]),
4309
+ filename: k().optional(),
4310
+ mediaType: k(),
4311
+ providerOptions: q.optional()
4312
4312
  }), yf = oe({
4313
- type: R("reasoning"),
4314
- text: C(),
4315
- providerOptions: Y.optional()
4313
+ type: P("reasoning"),
4314
+ text: k(),
4315
+ providerOptions: q.optional()
4316
4316
  }), _f = oe({
4317
- type: R("tool-call"),
4318
- toolCallId: C(),
4319
- toolName: C(),
4320
- input: Se(),
4321
- providerOptions: Y.optional(),
4322
- providerExecuted: ae().optional()
4317
+ type: P("tool-call"),
4318
+ toolCallId: k(),
4319
+ toolName: k(),
4320
+ input: ke(),
4321
+ providerOptions: q.optional(),
4322
+ providerExecuted: ie().optional()
4323
4323
  }), bf = Ud("type", [
4324
4324
  oe({
4325
- type: R("text"),
4326
- value: C()
4325
+ type: P("text"),
4326
+ value: k()
4327
4327
  }),
4328
4328
  oe({
4329
- type: R("json"),
4329
+ type: P("json"),
4330
4330
  value: Et
4331
4331
  }),
4332
4332
  oe({
4333
- type: R("error-text"),
4334
- value: C()
4333
+ type: P("error-text"),
4334
+ value: k()
4335
4335
  }),
4336
4336
  oe({
4337
- type: R("error-json"),
4337
+ type: P("error-json"),
4338
4338
  value: Et
4339
4339
  }),
4340
4340
  oe({
4341
- type: R("content"),
4341
+ type: P("content"),
4342
4342
  value: ct(
4343
- me([
4343
+ ge([
4344
4344
  oe({
4345
- type: R("text"),
4346
- text: C()
4345
+ type: P("text"),
4346
+ text: k()
4347
4347
  }),
4348
4348
  oe({
4349
- type: R("media"),
4350
- data: C(),
4351
- mediaType: C()
4349
+ type: P("media"),
4350
+ data: k(),
4351
+ mediaType: k()
4352
4352
  })
4353
4353
  ])
4354
4354
  )
4355
4355
  })
4356
4356
  ]), Ls = oe({
4357
- type: R("tool-result"),
4358
- toolCallId: C(),
4359
- toolName: C(),
4357
+ type: P("tool-result"),
4358
+ toolCallId: k(),
4359
+ toolName: k(),
4360
4360
  output: bf,
4361
- providerOptions: Y.optional()
4361
+ providerOptions: q.optional()
4362
4362
  }), wf = oe(
4363
4363
  {
4364
- role: R("system"),
4365
- content: C(),
4366
- providerOptions: Y.optional()
4364
+ role: P("system"),
4365
+ content: k(),
4366
+ providerOptions: q.optional()
4367
4367
  }
4368
4368
  ), If = oe({
4369
- role: R("user"),
4370
- content: me([
4371
- C(),
4372
- ct(me([Zs, vf, Ds]))
4369
+ role: P("user"),
4370
+ content: ge([
4371
+ k(),
4372
+ ct(ge([Zs, vf, Ds]))
4373
4373
  ]),
4374
- providerOptions: Y.optional()
4374
+ providerOptions: q.optional()
4375
4375
  }), Ef = oe({
4376
- role: R("assistant"),
4377
- content: me([
4378
- C(),
4376
+ role: P("assistant"),
4377
+ content: ge([
4378
+ k(),
4379
4379
  ct(
4380
- me([
4380
+ ge([
4381
4381
  Zs,
4382
4382
  Ds,
4383
4383
  yf,
@@ -4386,13 +4386,13 @@ var Yn = "5.0.102", $s = me([
4386
4386
  ])
4387
4387
  )
4388
4388
  ]),
4389
- providerOptions: Y.optional()
4389
+ providerOptions: q.optional()
4390
4390
  }), Tf = oe({
4391
- role: R("tool"),
4391
+ role: P("tool"),
4392
4392
  content: ct(Ls),
4393
- providerOptions: Y.optional()
4393
+ providerOptions: q.optional()
4394
4394
  });
4395
- me([
4395
+ ge([
4396
4396
  wf,
4397
4397
  If,
4398
4398
  Ef,
@@ -4404,132 +4404,132 @@ Nt({
4404
4404
  });
4405
4405
  var Sf = gp(
4406
4406
  () => Ps(
4407
- me([
4407
+ ge([
4408
4408
  G({
4409
- type: R("text-start"),
4410
- id: C(),
4411
- providerMetadata: Y.optional()
4409
+ type: P("text-start"),
4410
+ id: k(),
4411
+ providerMetadata: q.optional()
4412
4412
  }),
4413
4413
  G({
4414
- type: R("text-delta"),
4415
- id: C(),
4416
- delta: C(),
4417
- providerMetadata: Y.optional()
4414
+ type: P("text-delta"),
4415
+ id: k(),
4416
+ delta: k(),
4417
+ providerMetadata: q.optional()
4418
4418
  }),
4419
4419
  G({
4420
- type: R("text-end"),
4421
- id: C(),
4422
- providerMetadata: Y.optional()
4420
+ type: P("text-end"),
4421
+ id: k(),
4422
+ providerMetadata: q.optional()
4423
4423
  }),
4424
4424
  G({
4425
- type: R("error"),
4426
- errorText: C()
4425
+ type: P("error"),
4426
+ errorText: k()
4427
4427
  }),
4428
4428
  G({
4429
- type: R("tool-input-start"),
4430
- toolCallId: C(),
4431
- toolName: C(),
4432
- providerExecuted: ae().optional(),
4433
- dynamic: ae().optional()
4429
+ type: P("tool-input-start"),
4430
+ toolCallId: k(),
4431
+ toolName: k(),
4432
+ providerExecuted: ie().optional(),
4433
+ dynamic: ie().optional()
4434
4434
  }),
4435
4435
  G({
4436
- type: R("tool-input-delta"),
4437
- toolCallId: C(),
4438
- inputTextDelta: C()
4436
+ type: P("tool-input-delta"),
4437
+ toolCallId: k(),
4438
+ inputTextDelta: k()
4439
4439
  }),
4440
4440
  G({
4441
- type: R("tool-input-available"),
4442
- toolCallId: C(),
4443
- toolName: C(),
4444
- input: Se(),
4445
- providerExecuted: ae().optional(),
4446
- providerMetadata: Y.optional(),
4447
- dynamic: ae().optional()
4441
+ type: P("tool-input-available"),
4442
+ toolCallId: k(),
4443
+ toolName: k(),
4444
+ input: ke(),
4445
+ providerExecuted: ie().optional(),
4446
+ providerMetadata: q.optional(),
4447
+ dynamic: ie().optional()
4448
4448
  }),
4449
4449
  G({
4450
- type: R("tool-input-error"),
4451
- toolCallId: C(),
4452
- toolName: C(),
4453
- input: Se(),
4454
- providerExecuted: ae().optional(),
4455
- providerMetadata: Y.optional(),
4456
- dynamic: ae().optional(),
4457
- errorText: C()
4450
+ type: P("tool-input-error"),
4451
+ toolCallId: k(),
4452
+ toolName: k(),
4453
+ input: ke(),
4454
+ providerExecuted: ie().optional(),
4455
+ providerMetadata: q.optional(),
4456
+ dynamic: ie().optional(),
4457
+ errorText: k()
4458
4458
  }),
4459
4459
  G({
4460
- type: R("tool-output-available"),
4461
- toolCallId: C(),
4462
- output: Se(),
4463
- providerExecuted: ae().optional(),
4464
- dynamic: ae().optional(),
4465
- preliminary: ae().optional()
4460
+ type: P("tool-output-available"),
4461
+ toolCallId: k(),
4462
+ output: ke(),
4463
+ providerExecuted: ie().optional(),
4464
+ dynamic: ie().optional(),
4465
+ preliminary: ie().optional()
4466
4466
  }),
4467
4467
  G({
4468
- type: R("tool-output-error"),
4469
- toolCallId: C(),
4470
- errorText: C(),
4471
- providerExecuted: ae().optional(),
4472
- dynamic: ae().optional()
4468
+ type: P("tool-output-error"),
4469
+ toolCallId: k(),
4470
+ errorText: k(),
4471
+ providerExecuted: ie().optional(),
4472
+ dynamic: ie().optional()
4473
4473
  }),
4474
4474
  G({
4475
- type: R("reasoning-start"),
4476
- id: C(),
4477
- providerMetadata: Y.optional()
4475
+ type: P("reasoning-start"),
4476
+ id: k(),
4477
+ providerMetadata: q.optional()
4478
4478
  }),
4479
4479
  G({
4480
- type: R("reasoning-delta"),
4481
- id: C(),
4482
- delta: C(),
4483
- providerMetadata: Y.optional()
4480
+ type: P("reasoning-delta"),
4481
+ id: k(),
4482
+ delta: k(),
4483
+ providerMetadata: q.optional()
4484
4484
  }),
4485
4485
  G({
4486
- type: R("reasoning-end"),
4487
- id: C(),
4488
- providerMetadata: Y.optional()
4486
+ type: P("reasoning-end"),
4487
+ id: k(),
4488
+ providerMetadata: q.optional()
4489
4489
  }),
4490
4490
  G({
4491
- type: R("source-url"),
4492
- sourceId: C(),
4493
- url: C(),
4494
- title: C().optional(),
4495
- providerMetadata: Y.optional()
4491
+ type: P("source-url"),
4492
+ sourceId: k(),
4493
+ url: k(),
4494
+ title: k().optional(),
4495
+ providerMetadata: q.optional()
4496
4496
  }),
4497
4497
  G({
4498
- type: R("source-document"),
4499
- sourceId: C(),
4500
- mediaType: C(),
4501
- title: C(),
4502
- filename: C().optional(),
4503
- providerMetadata: Y.optional()
4498
+ type: P("source-document"),
4499
+ sourceId: k(),
4500
+ mediaType: k(),
4501
+ title: k(),
4502
+ filename: k().optional(),
4503
+ providerMetadata: q.optional()
4504
4504
  }),
4505
4505
  G({
4506
- type: R("file"),
4507
- url: C(),
4508
- mediaType: C(),
4509
- providerMetadata: Y.optional()
4506
+ type: P("file"),
4507
+ url: k(),
4508
+ mediaType: k(),
4509
+ providerMetadata: q.optional()
4510
4510
  }),
4511
4511
  G({
4512
4512
  type: Cs(
4513
4513
  (e) => typeof e == "string" && e.startsWith("data-"),
4514
4514
  { message: 'Type must start with "data-"' }
4515
4515
  ),
4516
- id: C().optional(),
4517
- data: Se(),
4518
- transient: ae().optional()
4516
+ id: k().optional(),
4517
+ data: ke(),
4518
+ transient: ie().optional()
4519
4519
  }),
4520
4520
  G({
4521
- type: R("start-step")
4521
+ type: P("start-step")
4522
4522
  }),
4523
4523
  G({
4524
- type: R("finish-step")
4524
+ type: P("finish-step")
4525
4525
  }),
4526
4526
  G({
4527
- type: R("start"),
4528
- messageId: C().optional(),
4529
- messageMetadata: Se().optional()
4527
+ type: P("start"),
4528
+ messageId: k().optional(),
4529
+ messageMetadata: ke().optional()
4530
4530
  }),
4531
4531
  G({
4532
- type: R("finish"),
4532
+ type: P("finish"),
4533
4533
  finishReason: Ts([
4534
4534
  "stop",
4535
4535
  "length",
@@ -4539,14 +4539,14 @@ var Sf = gp(
4539
4539
  "other",
4540
4540
  "unknown"
4541
4541
  ]).optional(),
4542
- messageMetadata: Se().optional()
4542
+ messageMetadata: ke().optional()
4543
4543
  }),
4544
4544
  G({
4545
- type: R("abort")
4545
+ type: P("abort")
4546
4546
  }),
4547
4547
  G({
4548
- type: R("message-metadata"),
4549
- messageMetadata: Se()
4548
+ type: P("message-metadata"),
4549
+ messageMetadata: ke()
4550
4550
  })
4551
4551
  ])
4552
4552
  )
@@ -4897,8 +4897,8 @@ function Nf({
4897
4897
  var S;
4898
4898
  const x = c.message.parts.find(
4899
4899
  (M) => Ft(M) && M.toolCallId === h.toolCallId
4900
- ), E = h, k = x;
4901
- x != null ? (x.state = h.state, k.input = E.input, k.output = E.output, k.errorText = E.errorText, k.rawInput = E.rawInput, k.preliminary = E.preliminary, k.providerExecuted = (S = E.providerExecuted) != null ? S : x.providerExecuted, E.providerMetadata != null && x.state === "input-available" && (x.callProviderMetadata = E.providerMetadata)) : c.message.parts.push({
4900
+ ), E = h, C = x;
4901
+ x != null ? (x.state = h.state, C.input = E.input, C.output = E.output, C.errorText = E.errorText, C.rawInput = E.rawInput, C.preliminary = E.preliminary, C.providerExecuted = (S = E.providerExecuted) != null ? S : x.providerExecuted, E.providerMetadata != null && x.state === "input-available" && (x.callProviderMetadata = E.providerMetadata)) : c.message.parts.push({
4902
4902
  type: `tool-${h.toolName}`,
4903
4903
  toolCallId: h.toolCallId,
4904
4904
  state: h.state,
@@ -4915,18 +4915,18 @@ function Nf({
4915
4915
  var S, x;
4916
4916
  const E = c.message.parts.find(
4917
4917
  (D) => D.type === "dynamic-tool" && D.toolCallId === h.toolCallId
4918
- ), k = h, M = E;
4919
- E != null ? (E.state = h.state, M.toolName = h.toolName, M.input = k.input, M.output = k.output, M.errorText = k.errorText, M.rawInput = (S = k.rawInput) != null ? S : M.rawInput, M.preliminary = k.preliminary, M.providerExecuted = (x = k.providerExecuted) != null ? x : E.providerExecuted, k.providerMetadata != null && E.state === "input-available" && (E.callProviderMetadata = k.providerMetadata)) : c.message.parts.push({
4918
+ ), C = h, M = E;
4919
+ E != null ? (E.state = h.state, M.toolName = h.toolName, M.input = C.input, M.output = C.output, M.errorText = C.errorText, M.rawInput = (S = C.rawInput) != null ? S : M.rawInput, M.preliminary = C.preliminary, M.providerExecuted = (x = C.providerExecuted) != null ? x : E.providerExecuted, C.providerMetadata != null && E.state === "input-available" && (E.callProviderMetadata = C.providerMetadata)) : c.message.parts.push({
4920
4920
  type: "dynamic-tool",
4921
4921
  toolName: h.toolName,
4922
4922
  toolCallId: h.toolCallId,
4923
4923
  state: h.state,
4924
- input: k.input,
4925
- output: k.output,
4926
- errorText: k.errorText,
4927
- preliminary: k.preliminary,
4928
- providerExecuted: k.providerExecuted,
4929
- ...k.providerMetadata != null ? { callProviderMetadata: k.providerMetadata } : {}
4924
+ input: C.input,
4925
+ output: C.output,
4926
+ errorText: C.errorText,
4927
+ preliminary: C.preliminary,
4928
+ providerExecuted: C.providerExecuted,
4929
+ ...C.providerMetadata != null ? { callProviderMetadata: C.providerMetadata } : {}
4930
4930
  });
4931
4931
  }
4932
4932
  async function I(h) {
@@ -5241,10 +5241,10 @@ var Pf = class {
5241
5241
  Nt({ prefix: "aiobj", size: 24 });
5242
5242
  var Rf = {};
5243
5243
  hf(Rf, {
5244
- object: () => Mf,
5245
- text: () => zf
5244
+ object: () => zf,
5245
+ text: () => Mf
5246
5246
  });
5247
- var zf = () => ({
5247
+ var Mf = () => ({
5248
5248
  type: "text",
5249
5249
  responseFormat: { type: "text" },
5250
5250
  async parsePartial({ text: e }) {
@@ -5253,7 +5253,7 @@ var zf = () => ({
5253
5253
  async parseOutput({ text: e }) {
5254
5254
  return e;
5255
5255
  }
5256
- }), Mf = ({
5256
+ }), zf = ({
5257
5257
  schema: e
5258
5258
  }) => {
5259
5259
  const t = pf(e);
@@ -5350,8 +5350,8 @@ var Zf = class {
5350
5350
  }) {
5351
5351
  var r, n, o, s, i;
5352
5352
  const a = await nt(this.body), l = await nt(this.headers), c = await nt(this.credentials), d = {
5353
- ...We(l),
5354
- ...We(t.headers)
5353
+ ...Ye(l),
5354
+ ...Ye(t.headers)
5355
5355
  }, u = await ((r = this.prepareSendMessagesRequest) == null ? void 0 : r.call(this, {
5356
5356
  api: this.api,
5357
5357
  id: t.chatId,
@@ -5362,7 +5362,7 @@ var Zf = class {
5362
5362
  requestMetadata: t.metadata,
5363
5363
  trigger: t.trigger,
5364
5364
  messageId: t.messageId
5365
- })), y = (n = u?.api) != null ? n : this.api, g = u?.headers !== void 0 ? We(u.headers) : d, f = u?.body !== void 0 ? u.body : {
5365
+ })), y = (n = u?.api) != null ? n : this.api, g = u?.headers !== void 0 ? Ye(u.headers) : d, f = u?.body !== void 0 ? u.body : {
5366
5366
  ...a,
5367
5367
  ...t.body,
5368
5368
  id: t.chatId,
@@ -5394,8 +5394,8 @@ var Zf = class {
5394
5394
  async reconnectToStream(e) {
5395
5395
  var t, r, n, o, s;
5396
5396
  const i = await nt(this.body), a = await nt(this.headers), l = await nt(this.credentials), c = {
5397
- ...We(a),
5398
- ...We(e.headers)
5397
+ ...Ye(a),
5398
+ ...Ye(e.headers)
5399
5399
  }, d = await ((t = this.prepareReconnectToStreamRequest) == null ? void 0 : t.call(this, {
5400
5400
  api: this.api,
5401
5401
  id: e.chatId,
@@ -5403,7 +5403,7 @@ var Zf = class {
5403
5403
  headers: c,
5404
5404
  credentials: l,
5405
5405
  requestMetadata: e.metadata
5406
- })), u = (r = d?.api) != null ? r : `${this.api}/${e.chatId}/stream`, y = d?.headers !== void 0 ? We(d.headers) : c, g = (n = d?.credentials) != null ? n : l, m = await ((o = this.fetch) != null ? o : globalThis.fetch)(u, {
5406
+ })), u = (r = d?.api) != null ? r : `${this.api}/${e.chatId}/stream`, y = d?.headers !== void 0 ? Ye(d.headers) : c, g = (n = d?.credentials) != null ? n : l, m = await ((o = this.fetch) != null ? o : globalThis.fetch)(u, {
5407
5407
  method: "GET",
5408
5408
  headers: Bn(
5409
5409
  y,
@@ -5699,7 +5699,7 @@ function jf() {
5699
5699
  return _r(Uf);
5700
5700
  }
5701
5701
  const Ff = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), Qn = { randomUUID: Ff };
5702
- function Ue(e, t, r) {
5702
+ function je(e, t, r) {
5703
5703
  if (Qn.randomUUID && !e)
5704
5704
  return Qn.randomUUID();
5705
5705
  e = e || {};
@@ -5714,7 +5714,7 @@ const Fs = async () => (br || (br = import(
5714
5714
  "./index.790ujKXR.js"
5715
5715
  )), br), Bs = async () => (wr || (wr = import(
5716
5716
  /* webpackChunkName: "toast-utilities" */
5717
- "./index.Mc6SYERm.js"
5717
+ "./index.Bb0qPlsw.js"
5718
5718
  ).then((e) => e.utilities)), wr), Bf = async () => {
5719
5719
  try {
5720
5720
  await Promise.all([Fs(), Bs()]);
@@ -5736,7 +5736,7 @@ const Fs = async () => (br || (br = import(
5736
5736
  }, 100);
5737
5737
  } catch {
5738
5738
  }
5739
- }, rr = (e, t) => Vs(e, "success", t), Vf = (e, t) => Vs(e, "error", t), qe = "CHAT_SET_STATUS", Hs = "CHAT_SET_USAGE", Tt = "CHAT_SET_ATTACHMENTS", $r = "CHAT_SET_PRIVATE", Gs = "CHAT_SET_PROVIDER", it = "CHAT_RESET", Hf = (e, t) => {
5739
+ }, rr = (e, t) => Vs(e, "success", t), Vf = (e, t) => Vs(e, "error", t), Xe = "CHAT_SET_STATUS", Hs = "CHAT_SET_USAGE", Tt = "CHAT_SET_ATTACHMENTS", $r = "CHAT_SET_PRIVATE", Gs = "CHAT_SET_PROVIDER", it = "CHAT_RESET", Hf = (e, t) => {
5740
5740
  switch (t.type) {
5741
5741
  case Hs:
5742
5742
  return {
@@ -5753,7 +5753,7 @@ const Fs = async () => (br || (br = import(
5753
5753
  ...e,
5754
5754
  privateChat: t.payload.privateChat
5755
5755
  };
5756
- case qe: {
5756
+ case Xe: {
5757
5757
  let r = !1, n = !1, o = !1, s = !1, i = "", a = 0, l = e.tokenUsage;
5758
5758
  return typeof t?.payload?.loading == "boolean" ? o = t.payload.loading : typeof e.loading == "boolean" && (o = e.loading), typeof t?.payload?.streaming == "boolean" ? n = t.payload.streaming : typeof e.streaming == "boolean" && (n = e.streaming), typeof t?.payload?.restoring == "boolean" ? (r = t.payload.restoring, i = t.payload.restoredModel || "", a = t.payload.restoredUsage || 0, r && (l = a)) : typeof e.restoring == "boolean" && (r = e.restoring, i = e.restoredModel || "", a = e.restoredUsage || 0), typeof t?.payload?.aborted == "boolean" ? s = t.payload.aborted : typeof e.aborted == "boolean" && (s = e.aborted), (n || o) && (r = !1, i = "", a = 0, s = !1), {
5759
5759
  ...e,
@@ -5851,26 +5851,26 @@ const qf = /* @__PURE__ */ ff(Yf);
5851
5851
  var Js = (e, t, r) => {
5852
5852
  if (!t.has(e))
5853
5853
  throw TypeError("Cannot " + r);
5854
- }, B = (e, t, r) => (Js(e, t, "read from private field"), r ? r.call(e) : t.get(e)), Te = (e, t, r) => {
5854
+ }, B = (e, t, r) => (Js(e, t, "read from private field"), r ? r.call(e) : t.get(e)), Se = (e, t, r) => {
5855
5855
  if (t.has(e))
5856
5856
  throw TypeError("Cannot add the same private member more than once");
5857
5857
  t instanceof WeakSet ? t.add(e) : t.set(e, r);
5858
- }, Re = (e, t, r, n) => (Js(e, t, "write to private field"), t.set(e, r), r);
5858
+ }, ze = (e, t, r, n) => (Js(e, t, "write to private field"), t.set(e, r), r);
5859
5859
  function Xf(e, t) {
5860
5860
  return t != null ? qf(e, t) : e;
5861
5861
  }
5862
- var fe, Bt, Vt, ft, mt, ht, ot, Zr, Dr, Qf = class {
5862
+ var me, Bt, Vt, ft, mt, ht, ot, Zr, Dr, Qf = class {
5863
5863
  constructor(e = []) {
5864
- Te(this, fe, void 0), Te(this, Bt, "ready"), Te(this, Vt, void 0), Te(this, ft, /* @__PURE__ */ new Set()), Te(this, mt, /* @__PURE__ */ new Set()), Te(this, ht, /* @__PURE__ */ new Set()), this.pushMessage = (t) => {
5865
- Re(this, fe, B(this, fe).concat(t)), B(this, ot).call(this);
5864
+ Se(this, me, void 0), Se(this, Bt, "ready"), Se(this, Vt, void 0), Se(this, ft, /* @__PURE__ */ new Set()), Se(this, mt, /* @__PURE__ */ new Set()), Se(this, ht, /* @__PURE__ */ new Set()), this.pushMessage = (t) => {
5865
+ ze(this, me, B(this, me).concat(t)), B(this, ot).call(this);
5866
5866
  }, this.popMessage = () => {
5867
- Re(this, fe, B(this, fe).slice(0, -1)), B(this, ot).call(this);
5867
+ ze(this, me, B(this, me).slice(0, -1)), B(this, ot).call(this);
5868
5868
  }, this.replaceMessage = (t, r) => {
5869
- Re(this, fe, [
5870
- ...B(this, fe).slice(0, t),
5869
+ ze(this, me, [
5870
+ ...B(this, me).slice(0, t),
5871
5871
  // We deep clone the message here to ensure the new React Compiler (currently in RC) detects deeply nested parts/metadata changes:
5872
5872
  this.snapshot(r),
5873
- ...B(this, fe).slice(t + 1)
5873
+ ...B(this, me).slice(t + 1)
5874
5874
  ]), B(this, ot).call(this);
5875
5875
  }, this.snapshot = (t) => structuredClone(t), this["~registerMessagesCallback"] = (t, r) => {
5876
5876
  const n = r ? Xf(t, r) : t;
@@ -5881,34 +5881,34 @@ var fe, Bt, Vt, ft, mt, ht, ot, Zr, Dr, Qf = class {
5881
5881
  B(this, mt).delete(t);
5882
5882
  }), this["~registerErrorCallback"] = (t) => (B(this, ht).add(t), () => {
5883
5883
  B(this, ht).delete(t);
5884
- }), Te(this, ot, () => {
5884
+ }), Se(this, ot, () => {
5885
5885
  B(this, ft).forEach((t) => t());
5886
- }), Te(this, Zr, () => {
5886
+ }), Se(this, Zr, () => {
5887
5887
  B(this, mt).forEach((t) => t());
5888
- }), Te(this, Dr, () => {
5888
+ }), Se(this, Dr, () => {
5889
5889
  B(this, ht).forEach((t) => t());
5890
- }), Re(this, fe, e);
5890
+ }), ze(this, me, e);
5891
5891
  }
5892
5892
  get status() {
5893
5893
  return B(this, Bt);
5894
5894
  }
5895
5895
  set status(e) {
5896
- Re(this, Bt, e), B(this, Zr).call(this);
5896
+ ze(this, Bt, e), B(this, Zr).call(this);
5897
5897
  }
5898
5898
  get error() {
5899
5899
  return B(this, Vt);
5900
5900
  }
5901
5901
  set error(e) {
5902
- Re(this, Vt, e), B(this, Dr).call(this);
5902
+ ze(this, Vt, e), B(this, Dr).call(this);
5903
5903
  }
5904
5904
  get messages() {
5905
- return B(this, fe);
5905
+ return B(this, me);
5906
5906
  }
5907
5907
  set messages(e) {
5908
- Re(this, fe, [...e]), B(this, ot).call(this);
5908
+ ze(this, me, [...e]), B(this, ot).call(this);
5909
5909
  }
5910
5910
  };
5911
- fe = /* @__PURE__ */ new WeakMap();
5911
+ me = /* @__PURE__ */ new WeakMap();
5912
5912
  Bt = /* @__PURE__ */ new WeakMap();
5913
5913
  Vt = /* @__PURE__ */ new WeakMap();
5914
5914
  ft = /* @__PURE__ */ new WeakMap();
@@ -5920,7 +5920,7 @@ Dr = /* @__PURE__ */ new WeakMap();
5920
5920
  var st, eo = class extends Df {
5921
5921
  constructor({ messages: e, ...t }) {
5922
5922
  const r = new Qf(e);
5923
- super({ ...t, state: r }), Te(this, st, void 0), this["~registerMessagesCallback"] = (n, o) => B(this, st)["~registerMessagesCallback"](n, o), this["~registerStatusCallback"] = (n) => B(this, st)["~registerStatusCallback"](n), this["~registerErrorCallback"] = (n) => B(this, st)["~registerErrorCallback"](n), Re(this, st, r);
5923
+ super({ ...t, state: r }), Se(this, st, void 0), this["~registerMessagesCallback"] = (n, o) => B(this, st)["~registerMessagesCallback"](n, o), this["~registerStatusCallback"] = (n) => B(this, st)["~registerStatusCallback"](n), this["~registerErrorCallback"] = (n) => B(this, st)["~registerErrorCallback"](n), ze(this, st, r);
5924
5924
  }
5925
5925
  };
5926
5926
  st = /* @__PURE__ */ new WeakMap();
@@ -5929,11 +5929,11 @@ function Kf({
5929
5929
  resume: t = !1,
5930
5930
  ...r
5931
5931
  } = {}) {
5932
- const n = W(
5932
+ const n = J(
5933
5933
  "chat" in r ? r.chat : new eo(r)
5934
5934
  );
5935
5935
  ("chat" in r && r.chat !== n.current || "id" in r && n.current.id !== r.id) && (n.current = "chat" in r ? r.chat : new eo(r));
5936
- const s = "id" in r ? r.id : null, i = q(
5936
+ const s = "id" in r ? r.id : null, i = X(
5937
5937
  (u) => n.current["~registerMessagesCallback"](u, e),
5938
5938
  // optionsId is required to trigger re-subscription when the chat ID changes
5939
5939
  // eslint-disable-next-line react-hooks/exhaustive-deps
@@ -5950,7 +5950,7 @@ function Kf({
5950
5950
  n.current["~registerErrorCallback"],
5951
5951
  () => n.current.error,
5952
5952
  () => n.current.error
5953
- ), d = q(
5953
+ ), d = X(
5954
5954
  (u) => {
5955
5955
  typeof u == "function" && (u = u(n.current.messages)), n.current.messages = u;
5956
5956
  },
@@ -5982,11 +5982,11 @@ const to = () => ({
5982
5982
  onData: /* @__PURE__ */ new Set(),
5983
5983
  onToolCall: /* @__PURE__ */ new Set()
5984
5984
  }), Ws = Hr(null);
5985
- function Fe(e = {}) {
5986
- const t = X(Ws);
5985
+ function Be(e = {}) {
5986
+ const t = Q(Ws);
5987
5987
  if (!t)
5988
5988
  throw new Error("useAiChat must be used within a AiChatProvider");
5989
- const r = W(e);
5989
+ const r = J(e);
5990
5990
  return $(() => {
5991
5991
  r.current = e;
5992
5992
  }, [e]), $(() => {
@@ -6004,20 +6004,20 @@ function em({
6004
6004
  children: e,
6005
6005
  value: t
6006
6006
  }) {
6007
- const r = W(to()), [n, o] = Z("");
6007
+ const r = J(to()), [n, o] = Z("");
6008
6008
  $(() => {
6009
6009
  r.current = to();
6010
6010
  }, [t]);
6011
- const s = q((d) => {
6011
+ const s = X((d) => {
6012
6012
  for (const u of r.current.onError)
6013
6013
  u(d);
6014
- }, []), i = q((d) => {
6014
+ }, []), i = X((d) => {
6015
6015
  for (const u of r.current.onFinish)
6016
6016
  u(d);
6017
- }, []), a = q((d) => {
6017
+ }, []), a = X((d) => {
6018
6018
  for (const u of r.current.onData)
6019
6019
  u(d);
6020
- }, []), l = q(async (d) => {
6020
+ }, []), l = X(async (d) => {
6021
6021
  for (const u of r.current.onToolCall)
6022
6022
  await u(d);
6023
6023
  }, []), c = Kf({
@@ -6047,18 +6047,18 @@ function em({
6047
6047
  );
6048
6048
  }
6049
6049
  const tm = ({ chatId: e }) => {
6050
- const { messages: t } = Fe(), {
6050
+ const { messages: t } = Be(), {
6051
6051
  state: { privateChat: r }
6052
- } = X(we), n = W(e), o = W(!1);
6052
+ } = Q(Ie), n = J(e), o = J(!1);
6053
6053
  return $(() => {
6054
6054
  const s = n.current !== e, i = t.length > 0;
6055
6055
  i && !r ? (window.localStorage.setItem(
6056
- ke + jt,
6056
+ Ce + jt,
6057
6057
  JSON.stringify(e)
6058
6058
  ), o.current = !0) : r && i ? window.localStorage.removeItem(
6059
- ke + jt
6059
+ Ce + jt
6060
6060
  ) : s && o.current && (window.localStorage.removeItem(
6061
- ke + jt
6061
+ Ce + jt
6062
6062
  ), o.current = !1), n.current = e;
6063
6063
  }, [e, t.length, r]), null;
6064
6064
  };
@@ -6094,8 +6094,8 @@ const ro = ({
6094
6094
  setInitialMessages: r,
6095
6095
  dispatchChat: n
6096
6096
  }) => {
6097
- const { user: o, getAccessToken: s } = Ie(), [i, a] = Z(!1), [l] = Ne({
6098
- key: ke + jt,
6097
+ const { user: o, getAccessToken: s } = Ee(), [i, a] = Z(!1), [l] = Oe({
6098
+ key: Ce + jt,
6099
6099
  initialValue: ""
6100
6100
  }), d = (fa || go() || _t()) && !!l && !i && !!o?.username && l !== e, { data: u } = ma({
6101
6101
  chatId: d ? l : void 0,
@@ -6104,7 +6104,7 @@ const ro = ({
6104
6104
  });
6105
6105
  return $(() => {
6106
6106
  !u || !d || i || u.messages && (n({
6107
- type: qe,
6107
+ type: Xe,
6108
6108
  payload: {
6109
6109
  streaming: !1,
6110
6110
  loading: !1,
@@ -6124,34 +6124,34 @@ const ro = ({
6124
6124
  ]), { hasRestoredFromCache: i };
6125
6125
  }, nm = "z-20", om = "z-10";
6126
6126
  /*!
6127
- @versini/ui-tooltip v3.1.1
6127
+ @versini/ui-tooltip v4.0.1
6128
6128
  © 2025 gizmette.com
6129
6129
  */
6130
6130
  try {
6131
6131
  window.__VERSINI_UI_TOOLTIP__ || (window.__VERSINI_UI_TOOLTIP__ = {
6132
- version: "3.1.1",
6133
- buildTime: "11/16/2025 05:49 PM EST",
6132
+ version: "4.0.1",
6133
+ buildTime: "11/30/2025 07:18 PM EST",
6134
6134
  homepage: "https://github.com/aversini/ui-components",
6135
6135
  license: "MIT"
6136
6136
  });
6137
6137
  } catch {
6138
6138
  }
6139
- const sm = "av-tooltip", am = "av-tooltip-arrow", Dt = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, im = () => z("absolute top-0 left-0 w-max py-1 px-2 rounded-sm text-sm z-50"), no = ({ mode: e }) => z({
6139
+ const sm = "av-tooltip", am = "av-tooltip-arrow", Dt = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, im = () => R("absolute top-0 left-0 w-max py-1 px-2 rounded-sm text-sm z-50"), no = ({ mode: e }) => R({
6140
6140
  "bg-surface-darker": e === "dark" || e === "system",
6141
6141
  "bg-surface-light": e === "light" || e === "alt-system",
6142
6142
  "dark:bg-surface-light": e === "system",
6143
6143
  "dark:bg-surface-darker": e === "alt-system"
6144
- }), cm = ({ mode: e }) => z({
6144
+ }), cm = ({ mode: e }) => R({
6145
6145
  "text-copy-light": e === "dark" || e === "system",
6146
6146
  "text-copy-dark": e === "light" || e === "alt-system",
6147
6147
  "dark:text-copy-dark": e === "system",
6148
6148
  "dark:text-copy-light": e === "alt-system"
6149
- }), lm = () => z("absolute", "size-2", "transform rotate-45"), um = ({ mode: e, className: t, tooltipClassName: r, arrowClassName: n }) => {
6150
- const o = z("relative inline-block", t), s = z(sm, im(), no({
6149
+ }), lm = () => R("absolute", "size-2", "transform rotate-45"), um = ({ mode: e, className: t, tooltipClassName: r, arrowClassName: n }) => {
6150
+ const o = R("relative inline-block", t), s = R(sm, im(), no({
6151
6151
  mode: e
6152
6152
  }), cm({
6153
6153
  mode: e
6154
- }), r), i = z(am, lm(), no({
6154
+ }), r), i = R(am, lm(), no({
6155
6155
  mode: e
6156
6156
  }), n);
6157
6157
  return {
@@ -6159,23 +6159,23 @@ const sm = "av-tooltip", am = "av-tooltip-arrow", Dt = (e, t = "px") => typeof e
6159
6159
  arrow: i,
6160
6160
  wrapper: o
6161
6161
  };
6162
- }, dm = ({ delay: e = 300 }) => ({
6162
+ }, dm = ({ animationDuration: e = 300 }) => ({
6163
6163
  animation: `av-tooltip-fade-in ${e}ms ease-in-out`
6164
- }), pm = 5e3, Be = ({ trigger: e, label: t, placement: r = "top", mode: n = "system", delay: o = 300, className: s, tooltipClassName: i, arrowClassName: a }) => {
6165
- const l = ha(() => {
6166
- m.stop(), f(!1);
6167
- }), c = W(null), d = W(null), [u, y] = Z(!1), [g, f] = Z(!1), m = ga(() => {
6168
- f(!1);
6169
- }, pm), v = um({
6164
+ }), pm = 5e3, fm = ({ trigger: e, label: t, placement: r = "top", mode: n = "system", animationDuration: o = 300, delay: s = 0, className: i, tooltipClassName: a, arrowClassName: l }) => {
6165
+ const c = ha(() => {
6166
+ I.stop(), v(!1);
6167
+ }), d = J(null), u = J(null), y = J(null), [g, f] = Z(!1), [m, v] = Z(!1), [b, w] = Z(!1), I = ga(() => {
6168
+ v(!1);
6169
+ }, pm), h = um({
6170
6170
  mode: n,
6171
- className: s,
6172
- tooltipClassName: i,
6173
- arrowClassName: a
6174
- }), b = dm({
6175
- delay: o
6176
- }), w = q(async () => {
6177
- if (l.current && c.current && d.current) {
6178
- const { x, y: E, middlewareData: k, placement: M } = await Fi(l.current, c.current, {
6171
+ className: i,
6172
+ tooltipClassName: a,
6173
+ arrowClassName: l
6174
+ }), S = dm({
6175
+ animationDuration: o
6176
+ }), x = X(async () => {
6177
+ if (c.current && d.current && u.current) {
6178
+ const { x: D, y: se, middlewareData: z, placement: Y } = await Fi(c.current, d.current, {
6179
6179
  placement: r,
6180
6180
  middleware: [
6181
6181
  xo(10),
@@ -6187,83 +6187,94 @@ const sm = "av-tooltip", am = "av-tooltip-arrow", Dt = (e, t = "px") => typeof e
6187
6187
  padding: 5
6188
6188
  }),
6189
6189
  Bi({
6190
- element: d.current
6190
+ element: u.current
6191
6191
  })
6192
6192
  ]
6193
6193
  });
6194
- c?.current?.style && Object.assign(c.current.style, {
6195
- left: Dt(x),
6196
- top: Dt(E),
6197
- ...b
6194
+ d?.current?.style && Object.assign(d.current.style, {
6195
+ left: Dt(D),
6196
+ top: Dt(se),
6197
+ ...S
6198
6198
  });
6199
- const D = {
6199
+ const O = {
6200
6200
  top: "bottom",
6201
6201
  right: "left",
6202
6202
  bottom: "top",
6203
6203
  left: "right"
6204
- }[M.split("-")[0]];
6205
- d?.current?.style && Object.assign(d.current.style, {
6206
- left: Dt(k.arrow?.x),
6207
- top: Dt(k.arrow?.y),
6204
+ }[Y.split("-")[0]];
6205
+ u?.current?.style && Object.assign(u.current.style, {
6206
+ left: Dt(z.arrow?.x),
6207
+ top: Dt(z.arrow?.y),
6208
6208
  right: "",
6209
6209
  bottom: "",
6210
- [D]: "-4px"
6211
- });
6210
+ [O]: "-4px"
6211
+ }), w(!0);
6212
6212
  }
6213
6213
  }, [
6214
6214
  r,
6215
- b,
6216
- l
6215
+ S,
6216
+ c
6217
6217
  ]);
6218
6218
  $(() => {
6219
- (async () => u && await w())();
6219
+ (async () => g ? await x() : w(!1))();
6220
6220
  }, [
6221
- w,
6222
- u
6223
- ]);
6224
- const I = () => {
6225
- y(!1), f(!0), m.start();
6226
- }, h = () => {
6227
- g || y(!0);
6228
- }, S = () => {
6229
- g || y(!1);
6221
+ x,
6222
+ g
6223
+ ]), $(() => () => {
6224
+ y.current && clearTimeout(y.current);
6225
+ }, []);
6226
+ const E = () => {
6227
+ y.current && (clearTimeout(y.current), y.current = null), f(!1), v(!0), I.start();
6228
+ }, C = () => {
6229
+ m || (s > 0 ? y.current = setTimeout(() => {
6230
+ f(!0), y.current = null;
6231
+ }, s) : f(!0));
6232
+ }, M = () => {
6233
+ y.current && (clearTimeout(y.current), y.current = null), m || f(!1);
6230
6234
  };
6231
6235
  return /* @__PURE__ */ N("div", {
6232
- className: v.wrapper,
6233
- ref: l,
6234
- onMouseEnter: h,
6235
- onMouseLeave: S,
6236
- onClick: I,
6236
+ className: h.wrapper,
6237
+ ref: c,
6238
+ onMouseEnter: C,
6239
+ onMouseLeave: M,
6240
+ onClick: E,
6237
6241
  children: [
6238
6242
  e,
6239
- u && /* @__PURE__ */ N("div", {
6243
+ g && /* @__PURE__ */ N("div", {
6240
6244
  role: "tooltip",
6241
- ref: c,
6242
- className: v.tooltip,
6245
+ ref: d,
6246
+ className: h.tooltip,
6247
+ style: {
6248
+ opacity: b ? void 0 : 0
6249
+ },
6243
6250
  children: [
6244
6251
  t,
6245
6252
  /* @__PURE__ */ p("div", {
6246
- ref: d,
6247
- className: v.arrow
6253
+ ref: u,
6254
+ className: h.arrow
6248
6255
  })
6249
6256
  ]
6250
6257
  })
6251
6258
  ]
6252
6259
  });
6253
- }, fm = ({
6260
+ }, Ve = ({
6261
+ trigger: e,
6262
+ className: t,
6263
+ ...r
6264
+ }) => he(() => Pe(), []) ? /* @__PURE__ */ p("div", { className: t, children: e }) : /* @__PURE__ */ p(fm, { delay: 500, className: t, trigger: e, ...r }), mm = ({
6254
6265
  className: e,
6255
6266
  onClick: t
6256
6267
  }) => {
6257
- const [r, n] = Ce();
6268
+ const [r, n] = xe();
6258
6269
  return /* @__PURE__ */ p(
6259
- Be,
6270
+ Ve,
6260
6271
  {
6261
6272
  label: "Attach files",
6262
6273
  mode: "light",
6263
6274
  placement: "top",
6264
6275
  className: e,
6265
6276
  trigger: /* @__PURE__ */ p(
6266
- xe,
6277
+ Ae,
6267
6278
  {
6268
6279
  mode: "dark",
6269
6280
  focusMode: "light",
@@ -6274,7 +6285,7 @@ const sm = "av-tooltip", am = "av-tooltip-arrow", Dt = (e, t = "px") => typeof e
6274
6285
  children: /* @__PURE__ */ p(
6275
6286
  va,
6276
6287
  {
6277
- size: Oe,
6288
+ size: Re,
6278
6289
  monotone: !0,
6279
6290
  className: r(n.Attachment)
6280
6291
  }
@@ -6292,19 +6303,19 @@ function Ys(e, t) {
6292
6303
  };
6293
6304
  }, [e, t]);
6294
6305
  }
6295
- const mm = ({
6306
+ const hm = ({
6296
6307
  className: e
6297
6308
  }) => {
6298
- const { getAccessToken: t, user: r } = Ie(), {
6309
+ const { getAccessToken: t, user: r } = Ee(), {
6299
6310
  state: { streaming: n, loading: o },
6300
6311
  dispatch: s,
6301
6312
  setChatId: i,
6302
6313
  setInitialMessages: a
6303
- } = X(we), { id: l, setInput: c, stop: d } = Fe(), u = W(null), y = W(!1), [g, f] = Ce(), { data: m, isSuccess: v } = je({
6314
+ } = Q(Ie), { id: l, setInput: c, stop: d } = Be(), u = J(null), y = J(!1), [g, f] = xe(), { data: m, isSuccess: v } = Fe({
6304
6315
  user: r?.username,
6305
6316
  getAccessToken: t
6306
- }), b = g(f.NewChat), w = q(() => {
6307
- i(Ue()), a([]), c(""), s({
6317
+ }), b = g(f.NewChat), w = X(() => {
6318
+ i(je()), a([]), c(""), s({
6308
6319
  type: it,
6309
6320
  payload: {
6310
6321
  privateChat: !1,
@@ -6341,7 +6352,7 @@ const mm = ({
6341
6352
  );
6342
6353
  const I = async (S) => {
6343
6354
  S.preventDefault(), d(), s({
6344
- type: qe,
6355
+ type: Xe,
6345
6356
  payload: {
6346
6357
  aborted: !0,
6347
6358
  streaming: !1,
@@ -6365,16 +6376,16 @@ const mm = ({
6365
6376
  S.preventDefault(), w();
6366
6377
  };
6367
6378
  return $(() => {
6368
- ze() || ((n === !0 || o === !0) && !y.current && u.current && (y.current = !0, u.current.focus()), n === !1 && y.current && (y.current = !1));
6379
+ Pe() || ((n === !0 || o === !0) && !y.current && u.current && (y.current = !0, u.current.focus()), n === !1 && y.current && (y.current = !1));
6369
6380
  }, [n, o]), /* @__PURE__ */ p(
6370
- Be,
6381
+ Ve,
6371
6382
  {
6372
6383
  label: "New Chat",
6373
6384
  mode: "light",
6374
6385
  placement: "top-start",
6375
6386
  className: e,
6376
6387
  trigger: /* @__PURE__ */ p(
6377
- xe,
6388
+ Ae,
6378
6389
  {
6379
6390
  noBorder: !0,
6380
6391
  noBackground: !0,
@@ -6387,14 +6398,14 @@ const mm = ({
6387
6398
  children: n || o ? /* @__PURE__ */ p(
6388
6399
  ya,
6389
6400
  {
6390
- size: Oe,
6401
+ size: Re,
6391
6402
  monotone: !0,
6392
6403
  className: b
6393
6404
  }
6394
6405
  ) : /* @__PURE__ */ p(
6395
6406
  _a,
6396
6407
  {
6397
- size: Oe,
6408
+ size: Re,
6398
6409
  className: b
6399
6410
  }
6400
6411
  )
@@ -6407,34 +6418,34 @@ const mm = ({
6407
6418
  return t(e);
6408
6419
  };
6409
6420
  /*!
6410
- @versini/ui-panel v4.0.0
6421
+ @versini/ui-panel v4.0.1
6411
6422
  © 2025 gizmette.com
6412
6423
  */
6413
6424
  try {
6414
6425
  window.__VERSINI_UI_PANEL__ || (window.__VERSINI_UI_PANEL__ = {
6415
- version: "4.0.0",
6416
- buildTime: "11/28/2025 01:51 PM EST",
6426
+ version: "4.0.1",
6427
+ buildTime: "11/30/2025 06:52 PM EST",
6417
6428
  homepage: "https://github.com/aversini/ui-components",
6418
6429
  license: "MIT"
6419
6430
  });
6420
6431
  } catch {
6421
6432
  }
6422
- const hm = "av-messagebox", gm = "av-panel";
6433
+ const gm = "av-messagebox", vm = "av-panel";
6423
6434
  /*!
6424
- @versini/ui-modal v3.1.0
6435
+ @versini/ui-modal v3.1.1
6425
6436
  © 2025 gizmette.com
6426
6437
  */
6427
6438
  try {
6428
6439
  window.__VERSINI_UI_MODAL__ || (window.__VERSINI_UI_MODAL__ = {
6429
- version: "3.1.0",
6430
- buildTime: "11/28/2025 01:51 PM EST",
6440
+ version: "3.1.1",
6441
+ buildTime: "11/30/2025 06:52 PM EST",
6431
6442
  homepage: "https://github.com/aversini/ui-components",
6432
6443
  license: "MIT"
6433
6444
  });
6434
6445
  } catch {
6435
6446
  }
6436
6447
  const qs = /* @__PURE__ */ Hr(null);
6437
- function vm({ initialOpen: e = !1, open: t, onOpenChange: r } = {}) {
6448
+ function ym({ initialOpen: e = !1, open: t, onOpenChange: r } = {}) {
6438
6449
  const [n, o] = Z(e), [s, i] = Z(), [a, l] = Z(), c = t ?? n, d = r ?? o, u = Oo({
6439
6450
  open: c,
6440
6451
  onOpenChange: d
@@ -6443,12 +6454,12 @@ function vm({ initialOpen: e = !1, open: t, onOpenChange: r } = {}) {
6443
6454
  }), f = Ro(y, {
6444
6455
  outsidePress: !1,
6445
6456
  outsidePressEvent: "mousedown"
6446
- }), m = zo(y), v = Mo([
6457
+ }), m = Mo(y), v = zo([
6447
6458
  g,
6448
6459
  f,
6449
6460
  m
6450
6461
  ]);
6451
- return be(() => ({
6462
+ return he(() => ({
6452
6463
  open: c,
6453
6464
  setOpen: d,
6454
6465
  ...v,
@@ -6467,26 +6478,26 @@ function vm({ initialOpen: e = !1, open: t, onOpenChange: r } = {}) {
6467
6478
  ]);
6468
6479
  }
6469
6480
  const ir = () => {
6470
- const e = X(qs);
6481
+ const e = Q(qs);
6471
6482
  if (e == null)
6472
6483
  throw new Error("Modal components must be wrapped in <Modal />");
6473
6484
  return e;
6474
6485
  };
6475
- function ym({ children: e, ...t }) {
6476
- const r = vm(t);
6486
+ function _m({ children: e, ...t }) {
6487
+ const r = ym(t);
6477
6488
  return /* @__PURE__ */ p(qs.Provider, {
6478
6489
  value: r,
6479
6490
  children: e
6480
6491
  });
6481
6492
  }
6482
- const _m = /* @__PURE__ */ Xe(function(t, r) {
6493
+ const bm = /* @__PURE__ */ Qe(function(t, r) {
6483
6494
  const { context: n, ...o } = ir(), s = Jr([
6484
6495
  o.refs.setFloating,
6485
6496
  r
6486
6497
  ]);
6487
6498
  if (!n.open)
6488
6499
  return null;
6489
- const { overlayBackground: i, ...a } = t, l = z("grid place-items-center", {
6500
+ const { overlayBackground: i, ...a } = t, l = R("grid place-items-center", {
6490
6501
  [`${i}`]: i,
6491
6502
  "bg-black sm:bg-black/[.8]": !i
6492
6503
  });
@@ -6506,7 +6517,7 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6506
6517
  })
6507
6518
  })
6508
6519
  });
6509
- }), bm = /* @__PURE__ */ Xe(function({ children: t, ...r }, n) {
6520
+ }), wm = /* @__PURE__ */ Qe(function({ children: t, ...r }, n) {
6510
6521
  const { setLabelId: o } = ir(), s = Co();
6511
6522
  return Gr(() => (o(s), () => o(void 0)), [
6512
6523
  s,
@@ -6517,7 +6528,7 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6517
6528
  id: s,
6518
6529
  children: t
6519
6530
  });
6520
- }), wm = /* @__PURE__ */ Xe(function({ children: t, ...r }, n) {
6531
+ }), Im = /* @__PURE__ */ Qe(function({ children: t, ...r }, n) {
6521
6532
  const { setDescriptionId: o } = ir(), s = Co();
6522
6533
  return Gr(() => (o(s), () => o(void 0)), [
6523
6534
  s,
@@ -6528,8 +6539,8 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6528
6539
  id: s,
6529
6540
  children: t
6530
6541
  });
6531
- }), Im = /* @__PURE__ */ Xe(function(t, r) {
6532
- const { setOpen: n } = ir(), { trigger: o, className: s, ...i } = t, a = q(() => n(!1), [
6542
+ }), Em = /* @__PURE__ */ Qe(function(t, r) {
6543
+ const { setOpen: n } = ir(), { trigger: o, className: s, ...i } = t, a = X(() => n(!1), [
6533
6544
  n
6534
6545
  ]);
6535
6546
  return /* @__PURE__ */ p("div", {
@@ -6540,20 +6551,20 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6540
6551
  ...i
6541
6552
  })
6542
6553
  });
6543
- }), le = "panel", Ae = "messagebox", oo = ({ blurEffect: e }) => z("sticky z-10 backdrop-brightness-50", {
6554
+ }), le = "panel", Ne = "messagebox", oo = ({ blurEffect: e }) => R("sticky z-10 backdrop-brightness-50", {
6544
6555
  "backdrop-blur-sm": e === "small",
6545
6556
  "backdrop-blur-md": e === "medium",
6546
6557
  "backdrop-blur-lg": e === "large",
6547
6558
  "bg-surface-darker": e === "none"
6548
- }), Em = ({ className: e, kind: t, borderMode: r, animation: n, maxWidth: o = "medium", maxHeight: s, blurEffect: i = "none" }) => {
6559
+ }), Tm = ({ className: e, kind: t, borderMode: r, animation: n, maxWidth: o = "medium", maxHeight: s, blurEffect: i = "none" }) => {
6549
6560
  const a = s ?? (t === le ? "large" : void 0);
6550
6561
  return {
6551
- outerWrapper: z("main prose prose-lighter flex flex-col bg-surface-dark", {
6562
+ outerWrapper: R("main prose prose-lighter flex flex-col bg-surface-dark", {
6552
6563
  "duration-200 ease-out": n,
6553
6564
  /**
6554
6565
  * Panel styles
6555
6566
  */
6556
- [`${gm} min-h-full sm:min-h-[10rem] sm:rounded-lg sm:border-2`]: t === le,
6567
+ [`${vm} min-h-full sm:min-h-[10rem] sm:rounded-lg sm:border-2`]: t === le,
6557
6568
  "w-full sm:w-[95%] md:max-w-2xl": t === le && !e && o === "small",
6558
6569
  "w-full sm:w-[95%] md:max-w-3xl": t === le && !e && o === "medium",
6559
6570
  "w-full sm:w-[95%] md:max-w-4xl": t === le && !e && o === "large",
@@ -6565,38 +6576,38 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6565
6576
  /**
6566
6577
  * Messagebox styles
6567
6578
  */
6568
- [`${hm} rounded-lg border-2`]: t === Ae,
6569
- "w-[95%] sm:w-[50%] md:max-w-2xl": t === Ae && !e,
6570
- "max-h-[20%]": t === Ae && a === "small",
6571
- "max-h-[50%]": t === Ae && a === "medium",
6572
- "max-h-[95%]": t === Ae && a === "large",
6573
- "border-border-dark": r === "dark" && t === Ae,
6574
- "border-border-accent": r === "light" && t === Ae,
6579
+ [`${gm} rounded-lg border-2`]: t === Ne,
6580
+ "w-[95%] sm:w-[50%] md:max-w-2xl": t === Ne && !e,
6581
+ "max-h-[20%]": t === Ne && a === "small",
6582
+ "max-h-[50%]": t === Ne && a === "medium",
6583
+ "max-h-[95%]": t === Ne && a === "large",
6584
+ "border-border-dark": r === "dark" && t === Ne,
6585
+ "border-border-accent": r === "light" && t === Ne,
6575
6586
  [`${e}`]: !!e
6576
6587
  }),
6577
6588
  innerWrapper: "content flex flex-col overflow-y-auto",
6578
- footer: z(oo({
6589
+ footer: R(oo({
6579
6590
  blurEffect: i
6580
6591
  }), "p-2 bottom-0", {
6581
6592
  "sm:rounded-b-md": t === le,
6582
- "rounded-b-md": t === Ae
6593
+ "rounded-b-md": t === Ne
6583
6594
  }),
6584
- header: z("flex flex-row-reverse items-center justify-between", oo({
6595
+ header: R("flex flex-row-reverse items-center justify-between", oo({
6585
6596
  blurEffect: i
6586
6597
  }), "top-0", {
6587
6598
  "sm:rounded-t-md": t === le,
6588
- "rounded-t-md": t === Ae
6599
+ "rounded-t-md": t === Ne
6589
6600
  }),
6590
6601
  title: "mb-0 p-2",
6591
6602
  close: "p-2",
6592
6603
  content: "py-2 px-2"
6593
6604
  };
6594
- }, Tm = "slide", so = "fade", Sm = ({ open: e, onOpenChange: t, title: r, children: n, footer: o, borderMode: s = "light", kind: i = le, className: a, animation: l = !1, animationType: c = Tm, maxWidth: d = "medium", maxHeight: u, blurEffect: y = "none" }) => {
6595
- const g = W(""), [f, m] = Z(l ? c === so ? {
6605
+ }, Sm = "slide", so = "fade", km = ({ open: e, onOpenChange: t, title: r, children: n, footer: o, borderMode: s = "light", kind: i = le, className: a, animation: l = !1, animationType: c = Sm, maxWidth: d = "medium", maxHeight: u, blurEffect: y = "none" }) => {
6606
+ const g = J(""), [f, m] = Z(l ? c === so ? {
6596
6607
  opacity: 0
6597
6608
  } : {
6598
6609
  transform: "translateY(-100vh)"
6599
- } : {}), v = Em({
6610
+ } : {}), v = Tm({
6600
6611
  className: a,
6601
6612
  kind: i,
6602
6613
  borderMode: s,
@@ -6630,22 +6641,22 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6630
6641
  e,
6631
6642
  l,
6632
6643
  c
6633
- ]), /* @__PURE__ */ p(Me, {
6634
- children: e && /* @__PURE__ */ p(ym, {
6644
+ ]), /* @__PURE__ */ p($e, {
6645
+ children: e && /* @__PURE__ */ p(_m, {
6635
6646
  open: e,
6636
6647
  onOpenChange: t,
6637
- children: /* @__PURE__ */ p(_m, {
6648
+ children: /* @__PURE__ */ p(bm, {
6638
6649
  className: v.outerWrapper,
6639
6650
  style: f,
6640
- children: /* @__PURE__ */ N(wm, {
6651
+ children: /* @__PURE__ */ N(Im, {
6641
6652
  className: v.innerWrapper,
6642
6653
  children: [
6643
6654
  /* @__PURE__ */ N("div", {
6644
6655
  className: v.header,
6645
6656
  children: [
6646
- /* @__PURE__ */ p(Im, {
6657
+ /* @__PURE__ */ p(Em, {
6647
6658
  className: v.close,
6648
- trigger: /* @__PURE__ */ p(xe, {
6659
+ trigger: /* @__PURE__ */ p(Ae, {
6649
6660
  mode: "dark",
6650
6661
  focusMode: "light",
6651
6662
  noBorder: !0,
@@ -6655,7 +6666,7 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6655
6666
  })
6656
6667
  })
6657
6668
  }),
6658
- /* @__PURE__ */ p(bm, {
6669
+ /* @__PURE__ */ p(wm, {
6659
6670
  className: v.title,
6660
6671
  children: r
6661
6672
  })
@@ -6676,19 +6687,19 @@ const _m = /* @__PURE__ */ Xe(function(t, r) {
6676
6687
  });
6677
6688
  };
6678
6689
  /*!
6679
- @versini/ui-toggle v5.5.2
6690
+ @versini/ui-toggle v5.5.3
6680
6691
  © 2025 gizmette.com
6681
6692
  */
6682
6693
  try {
6683
6694
  window.__VERSINI_UI_TOGGLE__ || (window.__VERSINI_UI_TOGGLE__ = {
6684
- version: "5.5.2",
6685
- buildTime: "11/16/2025 06:13 PM EST",
6695
+ version: "5.5.3",
6696
+ buildTime: "11/30/2025 06:54 PM EST",
6686
6697
  homepage: "https://github.com/aversini/ui-components",
6687
6698
  license: "MIT"
6688
6699
  });
6689
6700
  } catch {
6690
6701
  }
6691
- const km = "av-toggle", Cm = ({ narrow: e }) => z(
6702
+ const Cm = "av-toggle", xm = ({ narrow: e }) => R(
6692
6703
  "peer",
6693
6704
  "rounded-full",
6694
6705
  {
@@ -6697,12 +6708,12 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6697
6708
  },
6698
6709
  // Smooth background/border transition when toggling
6699
6710
  "transition-colors duration-300 ease-in-out motion-reduce:transition-none"
6700
- ), xm = ({ focusMode: e }) => z("peer-focus:outline", "peer-focus:outline-2", "peer-focus:outline-offset-2", {
6711
+ ), Am = ({ focusMode: e }) => R("peer-focus:outline", "peer-focus:outline-2", "peer-focus:outline-offset-2", {
6701
6712
  "peer-focus:outline-focus-dark": e === "dark",
6702
6713
  "peer-focus:outline-focus-light": e === "light",
6703
6714
  "peer-focus:outline-focus-light dark:peer-focus:outline-focus-dark": e === "alt-system",
6704
6715
  "peer-focus:outline-focus-dark dark:peer-focus:outline-focus-light": e === "system"
6705
- }), Am = ({ narrow: e }) => z(
6716
+ }), Nm = ({ narrow: e }) => R(
6706
6717
  {
6707
6718
  "peer-checked:after:translate-x-full": !e,
6708
6719
  "peer-checked:after:translate-x-4": e
@@ -6712,18 +6723,18 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6712
6723
  // knob circle and border color when checked
6713
6724
  "peer-checked:after:bg-white",
6714
6725
  "peer-checked:after:border-white"
6715
- ), Nm = ({ narrow: e }) => z("after:left-[2px]", "after:top-[2px]", "after:border", "after:border-surface-light dark:after:border-surface-medium", "after:bg-surface-light dark:after:bg-surface-medium", "after:absolute", "after:transition-all after:duration-300 after:ease-in-out after:motion-reduce:transition-none after:will-change-transform", "after:content-['']", "after:rounded-full", {
6726
+ ), Om = ({ narrow: e }) => R("after:left-[2px]", "after:top-[2px]", "after:border", "after:border-surface-light dark:after:border-surface-medium", "after:bg-surface-light dark:after:bg-surface-medium", "after:absolute", "after:transition-all after:duration-300 after:ease-in-out after:motion-reduce:transition-none after:will-change-transform", "after:content-['']", "after:rounded-full", {
6716
6727
  // Normal toggle knob (circle)
6717
6728
  "after:h-5 after:w-5": !e,
6718
6729
  // Narrow toggle knob (oval)
6719
6730
  " after:h-4 after:w-7": e
6720
- }), Om = ({ mode: e, noBorder: t }) => z({
6731
+ }), Pm = ({ mode: e, noBorder: t }) => R({
6721
6732
  border: !t,
6722
6733
  "border-border-medium bg-surface-medium": e === "light",
6723
6734
  "border-border-light bg-surface-darker": e === "dark",
6724
6735
  "border-border-light bg-surface-darker dark:border-border-dark dark:bg-surface-medium": e === "alt-system",
6725
6736
  "border-border-medium bg-surface-medium dark:border-border-light dark:bg-surface-darker": e === "system"
6726
- }), ao = ({ labelHidden: e, labelMode: t, mode: r, labelPosition: n = "right", subLabel: o = !1 }) => (t = t || r, e ? "sr-only" : z("select-none", {
6737
+ }), ao = ({ labelHidden: e, labelMode: t, mode: r, labelPosition: n = "right", subLabel: o = !1 }) => (t = t || r, e ? "sr-only" : R("select-none", {
6727
6738
  "ml-2": n === "right",
6728
6739
  "mr-2": n === "left",
6729
6740
  "text-copy-dark": t === "light" && !o,
@@ -6736,17 +6747,17 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6736
6747
  "text-copy-lighter/60 dark:text-copy-dark/60": t === "alt-system" && o,
6737
6748
  "text-copy-dark/60 dark:text-copy-lighter/60": t === "system" && o,
6738
6749
  "text-xs": o
6739
- })), Pm = ({ className: e }) => z(km, "relative flex cursor-pointer items-center", e), Rm = () => "relative inline-block", zm = ({ mode: e, focusMode: t, labelHidden: r, className: n, noBorder: o, narrow: s, labelMode: i, labelPosition: a = "right", subLabel: l }) => ({
6740
- toggle: z(Cm({
6750
+ })), Rm = ({ className: e }) => R(Cm, "relative flex cursor-pointer items-center", e), Mm = () => "relative inline-block", zm = ({ mode: e, focusMode: t, labelHidden: r, className: n, noBorder: o, narrow: s, labelMode: i, labelPosition: a = "right", subLabel: l }) => ({
6751
+ toggle: R(xm({
6741
6752
  narrow: s
6742
- }), Om({
6753
+ }), Pm({
6743
6754
  mode: e,
6744
6755
  noBorder: o
6745
- }), xm({
6756
+ }), Am({
6746
6757
  focusMode: t
6747
- }), Nm({
6758
+ }), Om({
6748
6759
  narrow: s
6749
- }), Am({
6760
+ }), Nm({
6750
6761
  narrow: s
6751
6762
  })),
6752
6763
  label: ao({
@@ -6763,11 +6774,11 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6763
6774
  subLabel: l
6764
6775
  }),
6765
6776
  input: "peer sr-only",
6766
- wrapper: Pm({
6777
+ wrapper: Rm({
6767
6778
  className: n
6768
6779
  }),
6769
- toggleWrapper: Rm()
6770
- }), Mm = ({ checked: e = !1, onChange: t, label: r, labelHidden: n = !1, name: o, mode: s = "system", focusMode: i = "system", labelMode: a, className: l, noBorder: c = !1, narrow: d = !1, noHaptic: u = !1, labelPosition: y = "right", subLabel: g }) => {
6780
+ toggleWrapper: Mm()
6781
+ }), $m = ({ checked: e = !1, onChange: t, label: r, labelHidden: n = !1, name: o, mode: s = "system", focusMode: i = "system", labelMode: a, className: l, noBorder: c = !1, narrow: d = !1, noHaptic: u = !1, labelPosition: y = "right", subLabel: g }) => {
6771
6782
  const { haptic: f } = ba(), m = zm({
6772
6783
  mode: s,
6773
6784
  focusMode: i,
@@ -6870,7 +6881,7 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6870
6881
  columnGap: 2,
6871
6882
  children: [
6872
6883
  /* @__PURE__ */ p(at, { span: "auto", children: /* @__PURE__ */ p(
6873
- Mm,
6884
+ $m,
6874
6885
  {
6875
6886
  narrow: !0,
6876
6887
  mode: "dark",
@@ -6889,7 +6900,7 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6889
6900
  }
6890
6901
  ) : u;
6891
6902
  return /* @__PURE__ */ p(
6892
- Sm,
6903
+ km,
6893
6904
  {
6894
6905
  kind: "messagebox",
6895
6906
  open: e,
@@ -6900,16 +6911,16 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6900
6911
  children: n
6901
6912
  }
6902
6913
  );
6903
- }, $m = ({
6914
+ }, Zm = ({
6904
6915
  className: e
6905
6916
  }) => {
6906
- const { getAccessToken: t, user: r } = Ie(), {
6917
+ const { getAccessToken: t, user: r } = Ee(), {
6907
6918
  state: { privateChat: n, provider: o, tokenUsage: s },
6908
6919
  dispatch: i
6909
- } = X(we), { messages: a, id: l } = Fe(), { mutateAsync: c } = wa({ getAccessToken: t }), [d, u] = Ce(), [y, g] = Z(!1), [f, m] = Z(!1), [v, b] = Ne({
6910
- key: ke + Ia,
6920
+ } = Q(Ie), { messages: a, id: l } = Be(), { mutateAsync: c } = wa({ getAccessToken: t }), [d, u] = xe(), [y, g] = Z(!1), [f, m] = Z(!1), [v, b] = Oe({
6921
+ key: Ce + Ia,
6911
6922
  initialValue: ""
6912
- }), w = nr(Jt.TOOL.MEMORIES), { data: I, isSuccess: h } = je({
6923
+ }), w = nr(Jt.TOOL.MEMORIES), { data: I, isSuccess: h } = Fe({
6913
6924
  user: r?.username,
6914
6925
  getAccessToken: t
6915
6926
  }), S = async () => {
@@ -6926,8 +6937,8 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6926
6937
  });
6927
6938
  return;
6928
6939
  }
6929
- let k = [];
6930
- !E && a && a.length > 0 && (k = a.filter((M) => M.parts && M.parts.length > 0 ? M.parts.some(
6940
+ let C = [];
6941
+ !E && a && a.length > 0 && (C = a.filter((M) => M.parts && M.parts.length > 0 ? M.parts.some(
6931
6942
  (D) => D.type === "text" && D.text?.trim()
6932
6943
  ) : !1).map((M) => ({
6933
6944
  role: M.role,
@@ -6937,7 +6948,7 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6937
6948
  }))), await c({
6938
6949
  userId: r?.username || "",
6939
6950
  id: l,
6940
- messages: k,
6951
+ messages: C,
6941
6952
  provider: o,
6942
6953
  tokenUsage: s,
6943
6954
  privateChat: E
@@ -6953,7 +6964,7 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6953
6964
  });
6954
6965
  }
6955
6966
  };
6956
- return /* @__PURE__ */ N(Me, { children: [
6967
+ return /* @__PURE__ */ N($e, { children: [
6957
6968
  f && /* @__PURE__ */ p(
6958
6969
  St,
6959
6970
  {
@@ -6982,14 +6993,14 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
6982
6993
  }
6983
6994
  ),
6984
6995
  /* @__PURE__ */ p(
6985
- Be,
6996
+ Ve,
6986
6997
  {
6987
6998
  label: "Private Chat",
6988
6999
  mode: "light",
6989
7000
  placement: "top",
6990
7001
  className: e,
6991
7002
  trigger: /* @__PURE__ */ p(
6992
- xe,
7003
+ Ae,
6993
7004
  {
6994
7005
  noBorder: !0,
6995
7006
  noBackground: !n,
@@ -7004,10 +7015,10 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
7004
7015
  },
7005
7016
  className: "text-sm",
7006
7017
  disabled: !(h && I),
7007
- children: n ? /* @__PURE__ */ p(Ea, { size: Oe }) : /* @__PURE__ */ p(
7018
+ children: n ? /* @__PURE__ */ p(Ea, { size: Re }) : /* @__PURE__ */ p(
7008
7019
  Ta,
7009
7020
  {
7010
- size: Oe,
7021
+ size: Re,
7011
7022
  className: d(u.PrivateChat)
7012
7023
  }
7013
7024
  )
@@ -7018,13 +7029,13 @@ const km = "av-toggle", Cm = ({ narrow: e }) => z(
7018
7029
  ] });
7019
7030
  };
7020
7031
  /*!
7021
- @versini/ui-menu v5.3.1
7032
+ @versini/ui-menu v5.3.2
7022
7033
  © 2025 gizmette.com
7023
7034
  */
7024
7035
  try {
7025
7036
  window.__VERSINI_UI_MENU__ || (window.__VERSINI_UI_MENU__ = {
7026
- version: "5.3.1",
7027
- buildTime: "11/16/2025 05:49 PM EST",
7037
+ version: "5.3.2",
7038
+ buildTime: "11/30/2025 06:53 PM EST",
7028
7039
  homepage: "https://github.com/aversini/ui-components",
7029
7040
  license: "MIT"
7030
7041
  });
@@ -7052,19 +7063,19 @@ const Ht = /* @__PURE__ */ Hr({
7052
7063
  return t.displayName || t.name || "Component";
7053
7064
  }
7054
7065
  return "Element";
7055
- }, Lr = /* @__PURE__ */ Xe(({ trigger: e, children: t, label: r = "Open menu", defaultPlacement: n = "bottom-start", onOpenChange: o, mode: s = "system", focusMode: i = "system", ...a }, l) => {
7056
- const [c, d] = Z(!1), [u, y] = Z(!1), [g, f] = Z(null), [m, v] = Z(!1), b = W([]), w = W([]), I = X(Ht), h = Do(), S = Gi(), x = $o(), E = Zo({
7066
+ }, Lr = /* @__PURE__ */ Qe(({ trigger: e, children: t, label: r = "Open menu", defaultPlacement: n = "bottom-start", onOpenChange: o, mode: s = "system", focusMode: i = "system", ...a }, l) => {
7067
+ const [c, d] = Z(!1), [u, y] = Z(!1), [g, f] = Z(null), [m, v] = Z(!1), b = J([]), w = J([]), I = Q(Ht), h = Do(), S = Gi(), x = $o(), E = Zo({
7057
7068
  label: r !== "Open menu" ? r : null
7058
- }), k = x != null, { floatingStyles: M, refs: D, context: O } = Oo({
7069
+ }), C = x != null, { floatingStyles: M, refs: D, context: se } = Oo({
7059
7070
  nodeId: S,
7060
7071
  open: c,
7061
- onOpenChange: (Q) => {
7062
- d(Q), o?.(Q);
7072
+ onOpenChange: (K) => {
7073
+ d(K), o?.(K);
7063
7074
  },
7064
- placement: k ? "right-start" : n,
7075
+ placement: C ? "right-start" : n,
7065
7076
  strategy: "fixed",
7066
7077
  middleware: [
7067
- xo(() => k ? {
7078
+ xo(() => C ? {
7068
7079
  mainAxis: window.innerWidth < 640 ? 22 : 14,
7069
7080
  alignmentAxis: -4
7070
7081
  } : {
@@ -7075,39 +7086,39 @@ const Ht = /* @__PURE__ */ Hr({
7075
7086
  No()
7076
7087
  ],
7077
7088
  whileElementsMounted: Ji
7078
- }), ee = Wi(O, {
7079
- enabled: k && m,
7089
+ }), z = Wi(se, {
7090
+ enabled: C && m,
7080
7091
  delay: {
7081
7092
  open: 75
7082
7093
  },
7083
7094
  handleClose: Yi({
7084
7095
  blockPointerEvents: !0
7085
7096
  })
7086
- }), ce = Po(O, {
7097
+ }), Y = Po(se, {
7087
7098
  event: "mousedown",
7088
- toggle: !k || !m,
7089
- ignoreMouse: k && m
7090
- }), P = zo(O, {
7099
+ toggle: !C || !m,
7100
+ ignoreMouse: C && m
7101
+ }), O = Mo(se, {
7091
7102
  role: "menu"
7092
- }), Ke = Ro(O, {
7103
+ }), de = Ro(se, {
7093
7104
  bubbles: !0
7094
- }), de = qi(O, {
7105
+ }), pe = qi(se, {
7095
7106
  listRef: b,
7096
7107
  activeIndex: g,
7097
- nested: k,
7108
+ nested: C,
7098
7109
  onNavigate: f,
7099
7110
  loop: !0
7100
- }), Ve = Xi(O, {
7111
+ }), He = Xi(se, {
7101
7112
  listRef: w,
7102
7113
  onMatch: c ? f : void 0,
7103
7114
  activeIndex: g
7104
- }), { getReferenceProps: lt, getFloatingProps: pe, getItemProps: ut } = Mo([
7105
- ee,
7106
- ce,
7107
- P,
7108
- Ke,
7115
+ }), { getReferenceProps: lt, getFloatingProps: fe, getItemProps: ut } = zo([
7116
+ z,
7117
+ Y,
7118
+ O,
7109
7119
  de,
7110
- Ve
7120
+ pe,
7121
+ He
7111
7122
  ]), et = Jr([
7112
7123
  D.setReference,
7113
7124
  E.ref,
@@ -7116,14 +7127,14 @@ const Ht = /* @__PURE__ */ Hr({
7116
7127
  $(() => {
7117
7128
  if (!h)
7118
7129
  return;
7119
- function Q() {
7130
+ function K() {
7120
7131
  d(!1), o?.(!1);
7121
7132
  }
7122
- function he(tt) {
7133
+ function ve(tt) {
7123
7134
  tt.nodeId !== S && tt.parentId === x && d(!1);
7124
7135
  }
7125
- return h.events.on("click", Q), h.events.on("menuopen", he), () => {
7126
- h.events.off("click", Q), h.events.off("menuopen", he);
7136
+ return h.events.on("click", K), h.events.on("menuopen", ve), () => {
7137
+ h.events.off("click", K), h.events.off("menuopen", ve);
7127
7138
  };
7128
7139
  }, [
7129
7140
  h,
@@ -7141,19 +7152,19 @@ const Ht = /* @__PURE__ */ Hr({
7141
7152
  S,
7142
7153
  x
7143
7154
  ]), $(() => {
7144
- function Q({ pointerType: tt }) {
7155
+ function K({ pointerType: tt }) {
7145
7156
  tt !== "touch" && v(!0);
7146
7157
  }
7147
- function he() {
7158
+ function ve() {
7148
7159
  v(!1);
7149
7160
  }
7150
- return window.addEventListener("pointermove", Q, {
7161
+ return window.addEventListener("pointermove", K, {
7151
7162
  once: !0,
7152
7163
  capture: !0
7153
- }), window.addEventListener("keydown", he, !0), () => {
7154
- window.removeEventListener("pointermove", Q, {
7164
+ }), window.addEventListener("keydown", ve, !0), () => {
7165
+ window.removeEventListener("pointermove", K, {
7155
7166
  capture: !0
7156
- }), window.removeEventListener("keydown", he, !0);
7167
+ }), window.removeEventListener("keydown", ve, !0);
7157
7168
  };
7158
7169
  }, []);
7159
7170
  const Ot = io(e) === "Button" || io(e) === "ButtonIcon", Pt = Ot ? {
@@ -7161,8 +7172,8 @@ const Ht = /* @__PURE__ */ Hr({
7161
7172
  focusMode: i,
7162
7173
  mode: s
7163
7174
  } : {};
7164
- if (k && !e) {
7165
- const Q = z("flex items-center flex-row justify-between", "w-full", "m-0 first:mt-0 mt-2 sm:mt-1 px-2 py-1", "rounded-md border border-transparent", "text-left text-base", "outline-hidden focus:border focus:border-border-medium focus:bg-surface-lighter focus:underline", "disabled:cursor-not-allowed disabled:text-copy-medium", {
7175
+ if (C && !e) {
7176
+ const K = R("flex items-center flex-row justify-between", "w-full", "m-0 first:mt-0 mt-2 sm:mt-1 px-2 py-1", "rounded-md border border-transparent", "text-left text-base", "outline-hidden focus:border focus:border-border-medium focus:bg-surface-lighter focus:underline", "disabled:cursor-not-allowed disabled:text-copy-medium", {
7166
7177
  "bg-surface-lighter": c && !u
7167
7178
  });
7168
7179
  return /* @__PURE__ */ N(yn, {
@@ -7173,12 +7184,12 @@ const Ht = /* @__PURE__ */ Hr({
7173
7184
  "data-open": c ? "" : void 0,
7174
7185
  ...lt(I.getItemProps({
7175
7186
  ...a,
7176
- className: Q,
7177
- onFocus(he) {
7178
- a.onFocus?.(he), y(!1), I.setHasFocusInside(!0);
7187
+ className: K,
7188
+ onFocus(ve) {
7189
+ a.onFocus?.(ve), y(!1), I.setHasFocusInside(!0);
7179
7190
  },
7180
- onMouseEnter(he) {
7181
- a.onMouseEnter?.(he), I.allowHover && I.isOpen && I.setActiveIndex(E.index);
7191
+ onMouseEnter(ve) {
7192
+ a.onMouseEnter?.(ve), I.allowHover && I.isOpen && I.setActiveIndex(E.index);
7182
7193
  }
7183
7194
  })),
7184
7195
  children: [
@@ -7207,7 +7218,7 @@ const Ht = /* @__PURE__ */ Hr({
7207
7218
  labelsRef: w,
7208
7219
  children: c && /* @__PURE__ */ p(xr, {
7209
7220
  children: /* @__PURE__ */ p(Ar, {
7210
- context: O,
7221
+ context: se,
7211
7222
  modal: !1,
7212
7223
  initialFocus: -1,
7213
7224
  returnFocus: !1,
@@ -7215,7 +7226,7 @@ const Ht = /* @__PURE__ */ Hr({
7215
7226
  ref: D.setFloating,
7216
7227
  className: "rounded-md bg-surface-light shadow-sm shadow-border-dark outline-hidden p-3 sm:p-2",
7217
7228
  style: M,
7218
- ...pe(),
7229
+ ...fe(),
7219
7230
  children: t
7220
7231
  })
7221
7232
  })
@@ -7225,7 +7236,7 @@ const Ht = /* @__PURE__ */ Hr({
7225
7236
  ]
7226
7237
  });
7227
7238
  }
7228
- const Ee = /* @__PURE__ */ ko.cloneElement(e, {
7239
+ const Te = /* @__PURE__ */ ko.cloneElement(e, {
7229
7240
  ...Pt,
7230
7241
  "aria-label": r,
7231
7242
  "data-open": c ? "" : void 0,
@@ -7238,7 +7249,7 @@ const Ht = /* @__PURE__ */ Hr({
7238
7249
  return /* @__PURE__ */ N(yn, {
7239
7250
  id: S,
7240
7251
  children: [
7241
- Ee,
7252
+ Te,
7242
7253
  /* @__PURE__ */ p(Ht.Provider, {
7243
7254
  value: {
7244
7255
  activeIndex: g,
@@ -7254,7 +7265,7 @@ const Ht = /* @__PURE__ */ Hr({
7254
7265
  labelsRef: w,
7255
7266
  children: c && /* @__PURE__ */ p(xr, {
7256
7267
  children: /* @__PURE__ */ p(Ar, {
7257
- context: O,
7268
+ context: se,
7258
7269
  modal: !1,
7259
7270
  initialFocus: 0,
7260
7271
  returnFocus: !0,
@@ -7262,7 +7273,7 @@ const Ht = /* @__PURE__ */ Hr({
7262
7273
  ref: D.setFloating,
7263
7274
  className: "rounded-md bg-surface-light shadow-sm shadow-border-dark outline-hidden p-3 sm:p-2",
7264
7275
  style: M,
7265
- ...pe(),
7276
+ ...fe(),
7266
7277
  children: t
7267
7278
  })
7268
7279
  })
@@ -7271,7 +7282,7 @@ const Ht = /* @__PURE__ */ Hr({
7271
7282
  })
7272
7283
  ]
7273
7284
  });
7274
- }), kt = /* @__PURE__ */ Xe((e, t) => $o() === null ? /* @__PURE__ */ p(Hi, {
7285
+ }), kt = /* @__PURE__ */ Qe((e, t) => $o() === null ? /* @__PURE__ */ p(Hi, {
7275
7286
  children: /* @__PURE__ */ p(Lr, {
7276
7287
  ...e,
7277
7288
  ref: t
@@ -7282,9 +7293,9 @@ const Ht = /* @__PURE__ */ Hr({
7282
7293
  }));
7283
7294
  kt.displayName = "Menu";
7284
7295
  Lr.displayName = "MenuComponent";
7285
- const _e = /* @__PURE__ */ Xe(({ label: e, disabled: t, icon: r, raw: n = !1, children: o, ignoreClick: s = !1, selected: i, ...a }, l) => {
7296
+ const we = /* @__PURE__ */ Qe(({ label: e, disabled: t, icon: r, raw: n = !1, children: o, ignoreClick: s = !1, selected: i, ...a }, l) => {
7286
7297
  let c = "";
7287
- const d = X(Ht), u = Zo({
7298
+ const d = Q(Ht), u = Zo({
7288
7299
  label: t ? null : e
7289
7300
  }), y = Do(), g = Jr([
7290
7301
  u.ref,
@@ -7301,7 +7312,7 @@ const _e = /* @__PURE__ */ Xe(({ label: e, disabled: t, icon: r, raw: n = !1, ch
7301
7312
  children: o
7302
7313
  });
7303
7314
  r && (c = "pl-2");
7304
- const f = z("flex flex-row items-center", "w-full", "m-0 first:mt-0 mt-2 sm:mt-1 px-2 py-1", "rounded-md border border-transparent", "text-left text-base", "outline-hidden focus:border focus:border-border-medium focus:bg-surface-lighter focus:underline", "disabled:cursor-not-allowed disabled:text-copy-medium", {
7315
+ const f = R("flex flex-row items-center", "w-full", "m-0 first:mt-0 mt-2 sm:mt-1 px-2 py-1", "rounded-md border border-transparent", "text-left text-base", "outline-hidden focus:border focus:border-border-medium focus:bg-surface-lighter focus:underline", "disabled:cursor-not-allowed disabled:text-copy-medium", {
7305
7316
  "bg-none": !t && !i
7306
7317
  });
7307
7318
  return /* @__PURE__ */ N("button", {
@@ -7336,33 +7347,33 @@ const _e = /* @__PURE__ */ Xe(({ label: e, disabled: t, icon: r, raw: n = !1, ch
7336
7347
  ]
7337
7348
  });
7338
7349
  });
7339
- _e.displayName = "MenuItem";
7340
- const Zm = ({ className: e, ...t }) => {
7341
- const r = z(e, "my-1 border-t border-border-medium");
7350
+ we.displayName = "MenuItem";
7351
+ const Dm = ({ className: e, ...t }) => {
7352
+ const r = R(e, "my-1 border-t border-border-medium");
7342
7353
  return /* @__PURE__ */ p("div", {
7343
7354
  className: r,
7344
7355
  ...t
7345
7356
  });
7346
7357
  }, Ur = ({ className: e, ...t }) => {
7347
- const r = z(e, "pt-1 mb-2", "text-sm text-copy-dark font-bold", "border-b border-border-medium");
7358
+ const r = R(e, "pt-1 mb-2", "text-sm text-copy-dark font-bold", "border-b border-border-medium");
7348
7359
  return /* @__PURE__ */ p("div", {
7349
7360
  className: r,
7350
7361
  ...t
7351
7362
  });
7352
- }, Dm = (e) => {
7363
+ }, Lm = (e) => {
7353
7364
  for (let t = 0; t < e.length; t++)
7354
7365
  if (e[t].enabled)
7355
7366
  return !0;
7356
7367
  return !1;
7357
- }, Lm = ({
7368
+ }, Um = ({
7358
7369
  className: e,
7359
7370
  defaultPlacement: t = "top-start"
7360
7371
  }) => {
7361
- const { dispatch: r, setChatId: n, setInitialMessages: o } = X(we), { dispatch: s } = X(Vr), { getAccessToken: i, user: a } = Ie(), [l, c] = Ce(), { data: d, isSuccess: u } = je({
7372
+ const { dispatch: r, setChatId: n, setInitialMessages: o } = Q(Ie), { dispatch: s } = Q(Vr), { getAccessToken: i, user: a } = Ee(), [l, c] = xe(), { data: d, isSuccess: u } = Fe({
7362
7373
  user: a?.username,
7363
7374
  getAccessToken: i
7364
7375
  }), y = (m, v, b) => {
7365
- m.preventDefault(), n(Ue()), o([]), r({
7376
+ m.preventDefault(), n(je()), o([]), r({
7366
7377
  type: it,
7367
7378
  payload: {
7368
7379
  privateChat: b
@@ -7373,13 +7384,13 @@ const Zm = ({ className: e, ...t }) => {
7373
7384
  prompt: v
7374
7385
  }
7375
7386
  });
7376
- }, g = u && d && d.tags && Dm(d.tags), f = /* @__PURE__ */ N(
7387
+ }, g = u && d && d.tags && Lm(d.tags), f = /* @__PURE__ */ N(
7377
7388
  kt,
7378
7389
  {
7379
7390
  mode: "dark",
7380
7391
  focusMode: "light",
7381
7392
  trigger: /* @__PURE__ */ p(
7382
- xe,
7393
+ Ae,
7383
7394
  {
7384
7395
  noBorder: !0,
7385
7396
  noBackground: !0,
@@ -7388,7 +7399,7 @@ const Zm = ({ className: e, ...t }) => {
7388
7399
  children: /* @__PURE__ */ p(
7389
7400
  xa,
7390
7401
  {
7391
- size: Oe,
7402
+ size: Re,
7392
7403
  className: l(c.Prompts)
7393
7404
  }
7394
7405
  )
@@ -7414,7 +7425,7 @@ const Zm = ({ className: e, ...t }) => {
7414
7425
  break;
7415
7426
  }
7416
7427
  return m.enabled && m.label && m.content && /* @__PURE__ */ p(
7417
- _e,
7428
+ we,
7418
7429
  {
7419
7430
  label: m.label,
7420
7431
  icon: v,
@@ -7427,7 +7438,7 @@ const Zm = ({ className: e, ...t }) => {
7427
7438
  }
7428
7439
  );
7429
7440
  return g ? /* @__PURE__ */ p(
7430
- Be,
7441
+ Ve,
7431
7442
  {
7432
7443
  label: "Prompts",
7433
7444
  mode: "light",
@@ -7435,7 +7446,7 @@ const Zm = ({ className: e, ...t }) => {
7435
7446
  trigger: f
7436
7447
  }
7437
7448
  ) : /* @__PURE__ */ p("div", { className: e, children: f });
7438
- }, Um = ({
7449
+ }, jm = ({
7439
7450
  className: e
7440
7451
  }) => {
7441
7452
  const {
@@ -7443,11 +7454,11 @@ const Zm = ({ className: e, ...t }) => {
7443
7454
  dispatch: n,
7444
7455
  setChatId: o,
7445
7456
  setInitialMessages: s
7446
- } = X(we), [i, a] = Ce(), [l, c] = Z(!1), [d, u] = Z(!1), [y, g] = Ne({
7447
- key: ke + Pa,
7457
+ } = Q(Ie), [i, a] = xe(), [l, c] = Z(!1), [d, u] = Z(!1), [y, g] = Oe({
7458
+ key: Ce + Pa,
7448
7459
  initialValue: ""
7449
7460
  }), [f, m] = Z(!1), v = (w) => {
7450
- o(Ue()), s([]), n({
7461
+ o(je()), s([]), n({
7451
7462
  type: it,
7452
7463
  payload: {
7453
7464
  reasoning: !t
@@ -7459,7 +7470,7 @@ const Zm = ({ className: e, ...t }) => {
7459
7470
  }
7460
7471
  });
7461
7472
  };
7462
- return /* @__PURE__ */ N(Me, { children: [
7473
+ return /* @__PURE__ */ N($e, { children: [
7463
7474
  d && /* @__PURE__ */ p(
7464
7475
  St,
7465
7476
  {
@@ -7499,14 +7510,14 @@ const Zm = ({ className: e, ...t }) => {
7499
7510
  }
7500
7511
  ),
7501
7512
  /* @__PURE__ */ p(
7502
- Be,
7513
+ Ve,
7503
7514
  {
7504
7515
  label: "Reasoning Chat",
7505
7516
  mode: "light",
7506
7517
  placement: "top",
7507
7518
  className: e,
7508
7519
  trigger: /* @__PURE__ */ p(
7509
- xe,
7520
+ Ae,
7510
7521
  {
7511
7522
  noBorder: !0,
7512
7523
  animated: !0,
@@ -7522,8 +7533,8 @@ const Zm = ({ className: e, ...t }) => {
7522
7533
  children: /* @__PURE__ */ p(
7523
7534
  Ra,
7524
7535
  {
7525
- size: Oe,
7526
- className: $e({
7536
+ size: Re,
7537
+ className: Ze({
7527
7538
  [`${i(a.Reasoning)}`]: !t
7528
7539
  })
7529
7540
  }
@@ -7533,24 +7544,24 @@ const Zm = ({ className: e, ...t }) => {
7533
7544
  }
7534
7545
  )
7535
7546
  ] });
7536
- }, jm = ({
7547
+ }, Fm = ({
7537
7548
  className: e
7538
7549
  }) => {
7539
- const { getAccessToken: t, user: r } = Ie(), {
7550
+ const { getAccessToken: t, user: r } = Ee(), {
7540
7551
  state: { loading: n, streaming: o }
7541
- } = X(we), [s, i] = Ce(), { data: a, isSuccess: l } = je({
7552
+ } = Q(Ie), [s, i] = xe(), { data: a, isSuccess: l } = Fe({
7542
7553
  user: r?.username,
7543
7554
  getAccessToken: t
7544
7555
  });
7545
7556
  return /* @__PURE__ */ p(
7546
- Be,
7557
+ Ve,
7547
7558
  {
7548
7559
  label: "Send Message",
7549
7560
  mode: "light",
7550
7561
  placement: "top-end",
7551
7562
  className: e,
7552
7563
  trigger: /* @__PURE__ */ p(
7553
- xe,
7564
+ Ae,
7554
7565
  {
7555
7566
  iconClassName: "text-copy-lighter pr-0.5",
7556
7567
  disabled: !(l && a) || n || o,
@@ -7560,9 +7571,9 @@ const Zm = ({ className: e, ...t }) => {
7560
7571
  mode: "dark",
7561
7572
  focusMode: "light",
7562
7573
  children: /* @__PURE__ */ p(
7563
- za,
7574
+ Ma,
7564
7575
  {
7565
- size: Oe,
7576
+ size: Re,
7566
7577
  className: s(i.Send)
7567
7578
  }
7568
7579
  )
@@ -7571,7 +7582,7 @@ const Zm = ({ className: e, ...t }) => {
7571
7582
  }
7572
7583
  );
7573
7584
  };
7574
- function Fm(e) {
7585
+ function Bm(e) {
7575
7586
  const [t, r] = Z(
7576
7587
  () => co()
7577
7588
  );
@@ -7585,9 +7596,9 @@ function Fm(e) {
7585
7596
  }
7586
7597
  function co() {
7587
7598
  const e = (/* @__PURE__ */ new Date()).getHours();
7588
- return e >= 5 && e < 11 ? Ma : e >= 11 && e < 12 ? $a : e >= 12 && e < 17 ? Za : e >= 17 && e < 21 ? Da : e >= 21 && e < 24 ? La : Ua;
7599
+ return e >= 5 && e < 11 ? za : e >= 11 && e < 12 ? $a : e >= 12 && e < 17 ? Za : e >= 17 && e < 21 ? Da : e >= 21 && e < 24 ? La : Ua;
7589
7600
  }
7590
- const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7601
+ const Vm = [".png", ".jpg", ".jpeg", ".webp"], Hm = [".pdf", ".txt"], Gm = [
7591
7602
  ".js",
7592
7603
  ".cjs",
7593
7604
  ".mjs",
@@ -7601,29 +7612,29 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7601
7612
  ".html",
7602
7613
  ".json",
7603
7614
  ".md"
7604
- ], Je = [
7605
- ...Vm,
7615
+ ], We = [
7606
7616
  ...Hm,
7607
- ...Bm
7608
- ], jr = 400 * 1024, Gm = "text/plain", Gt = (e) => {
7617
+ ...Gm,
7618
+ ...Vm
7619
+ ], jr = 400 * 1024, Jm = "text/plain", Gt = (e) => {
7609
7620
  if (e === 0)
7610
7621
  return "0 Bytes";
7611
7622
  const t = 1024, r = ["Bytes", "KB", "MB", "GB"], n = Math.floor(Math.log(e) / Math.log(t));
7612
7623
  return parseFloat((e / Math.pow(t, n)).toFixed(2)) + " " + r[n];
7613
- }, Xs = (e) => e.reduce((t, r) => t + r.size, 0), Jm = (e) => e.type ? e : new File(
7624
+ }, Xs = (e) => e.reduce((t, r) => t + r.size, 0), Wm = (e) => e.type ? e : new File(
7614
7625
  [e],
7615
7626
  // Use the original file content
7616
7627
  e.name,
7617
7628
  {
7618
- type: Gm,
7629
+ type: Jm,
7619
7630
  lastModified: e.lastModified
7620
7631
  }
7621
- ), Wm = () => $e(
7632
+ ), Ym = () => Ze(
7622
7633
  "relative rounded-md text-base h-auto min-w-28 overflow-hidden pt-2"
7623
- ), Ym = ({ oledMode: e }) => $e({
7634
+ ), qm = ({ oledMode: e }) => Ze({
7624
7635
  "bg-slate-900/95 dark:bg-slate-900": e,
7625
7636
  "bg-slate-900": !e
7626
- }), qm = () => $e("text-copy-lighter caret-copy-light"), Xm = ({ oledMode: e }) => $e(
7637
+ }), Xm = () => Ze("text-copy-lighter caret-copy-light"), Qm = ({ oledMode: e }) => Ze(
7627
7638
  "has-[.av-prompt-editable:focus]:outline",
7628
7639
  "has-[.av-prompt-editable:focus]:outline-2",
7629
7640
  "has-[.av-prompt-editable:focus]:outline-offset-2",
@@ -7631,28 +7642,28 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7631
7642
  "has-[.av-prompt-editable:focus]:outline-focus-light": !e,
7632
7643
  "dark:has-[.av-prompt-editable:focus]:outline-focus-light has-[.av-prompt-editable:focus]:outline-focus-dark": e
7633
7644
  }
7634
- ), Qm = (e) => $e(
7645
+ ), Km = (e) => Ze(
7635
7646
  "peer",
7636
7647
  "text-base resize-none overflow-hidden w-full text-inherit outline-none",
7637
7648
  "h-6 pr-2 pl-3",
7638
7649
  "placeholder:text-sm",
7639
7650
  e
7640
- ), Km = ({
7651
+ ), eh = ({
7641
7652
  oledMode: e,
7642
7653
  placeholderColor: t
7643
7654
  }) => ({
7644
- wrapper: $e(
7655
+ wrapper: Ze(
7645
7656
  Fa,
7646
- Ym({ oledMode: e }),
7647
- Wm(),
7648
- qm(),
7649
- Xm({ oledMode: e })
7657
+ qm({ oledMode: e }),
7658
+ Ym(),
7659
+ Xm(),
7660
+ Qm({ oledMode: e })
7650
7661
  ),
7651
- textArea: $e(
7662
+ textArea: Ze(
7652
7663
  ja,
7653
- Qm(t)
7664
+ Km(t)
7654
7665
  )
7655
- }), eh = ({
7666
+ }), th = ({
7656
7667
  files: e,
7657
7668
  clearFile: t
7658
7669
  }) => e && e.length > 0 && /* @__PURE__ */ N("div", { className: "px-4 py-2", children: [
@@ -7668,7 +7679,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7668
7679
  ")"
7669
7680
  ] }),
7670
7681
  /* @__PURE__ */ p(
7671
- xe,
7682
+ Ae,
7672
7683
  {
7673
7684
  mode: "dark",
7674
7685
  focusMode: "light",
@@ -7691,7 +7702,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7691
7702
  " ",
7692
7703
  Gt(jr)
7693
7704
  ] })
7694
- ] }), nn = 1200, Qs = 200 * 1024, th = 0.85, lo = 0.5, rh = 0.1, nh = ["image/jpeg", "image/webp"], oh = ["image/png", "image/jpeg", "image/webp"], Ks = (e) => oh.includes(e.type), sh = (e, t, r = nn) => {
7705
+ ] }), nn = 1200, Qs = 200 * 1024, rh = 0.85, lo = 0.5, nh = 0.1, oh = ["image/jpeg", "image/webp"], sh = ["image/png", "image/jpeg", "image/webp"], Ks = (e) => sh.includes(e.type), ah = (e, t, r = nn) => {
7695
7706
  if (e <= r && t <= r)
7696
7707
  return { width: e, height: t };
7697
7708
  const n = e / t;
@@ -7702,14 +7713,14 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7702
7713
  width: Math.round(r * n),
7703
7714
  height: r
7704
7715
  };
7705
- }, ah = (e) => new Promise((t, r) => {
7716
+ }, ih = (e) => new Promise((t, r) => {
7706
7717
  const n = new Image(), o = URL.createObjectURL(e);
7707
7718
  n.onload = () => {
7708
7719
  URL.revokeObjectURL(o), t(n);
7709
7720
  }, n.onerror = () => {
7710
7721
  URL.revokeObjectURL(o), r(new Error(`Failed to load image: ${e.name}`));
7711
7722
  }, n.src = o;
7712
- }), ih = (e, t, r) => new Promise((n, o) => {
7723
+ }), ch = (e, t, r) => new Promise((n, o) => {
7713
7724
  e.toBlob(
7714
7725
  (s) => {
7715
7726
  s ? n(s) : o(new Error("Failed to convert canvas to blob"));
@@ -7717,11 +7728,11 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7717
7728
  t,
7718
7729
  r
7719
7730
  );
7720
- }), ch = (e) => e === "image/png" ? "image/jpeg" : e, lh = async (e, t = Qs, r = nn) => {
7731
+ }), lh = (e) => e === "image/png" ? "image/jpeg" : e, uh = async (e, t = Qs, r = nn) => {
7721
7732
  if (!Ks(e) || e.size <= t)
7722
7733
  return e;
7723
7734
  try {
7724
- const n = await ah(e), { width: o, height: s } = sh(
7735
+ const n = await ih(e), { width: o, height: s } = ah(
7725
7736
  n.naturalWidth,
7726
7737
  n.naturalHeight,
7727
7738
  r
@@ -7731,16 +7742,16 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7731
7742
  if (!a)
7732
7743
  return e;
7733
7744
  a.fillStyle = "#FFFFFF", a.fillRect(0, 0, o, s), a.drawImage(n, 0, 0, o, s);
7734
- const l = ch(e.type), c = nh.includes(l);
7735
- let d = th, u;
7745
+ const l = lh(e.type), c = oh.includes(l);
7746
+ let d = rh, u;
7736
7747
  do {
7737
- if (u = await ih(
7748
+ if (u = await ch(
7738
7749
  i,
7739
7750
  l,
7740
7751
  c ? d : 1
7741
7752
  ), u.size <= t || d <= lo)
7742
7753
  break;
7743
- d -= rh;
7754
+ d -= nh;
7744
7755
  } while (d >= lo);
7745
7756
  if (u.size >= e.size)
7746
7757
  return e;
@@ -7756,14 +7767,14 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7756
7767
  } catch (n) {
7757
7768
  return console.warn("Image compression failed, using original file:", n), e;
7758
7769
  }
7759
- }, uh = async (e, t = Qs, r = nn) => await Promise.all(
7760
- e.map((o) => Ks(o) ? lh(o, t, r) : Promise.resolve(o))
7761
- ), ea = 24, dh = 500, ta = 1, ph = 5, fh = ea * ta, uo = ph * ea, mh = "ready", hh = "streaming", gh = "error", vh = "submitted", Lt = (e) => {
7762
- e.current && (e.current.style.height = `${fh}px`);
7763
- }, yh = () => {
7764
- const { user: e, getAccessToken: t } = Ie(), r = nr(Jt.ADDON.ATTACHMENTS), n = nr(Jt.ADDON.REASONING), { allowedModels: o } = Br(), [s, i] = Z(null), [a, l] = Z(!1), [c, d] = Z(!1), {
7770
+ }, dh = async (e, t = Qs, r = nn) => await Promise.all(
7771
+ e.map((o) => Ks(o) ? uh(o, t, r) : Promise.resolve(o))
7772
+ ), ea = 24, ph = 500, ta = 1, fh = 5, mh = ea * ta, uo = fh * ea, hh = "ready", gh = "streaming", vh = "error", yh = "submitted", Lt = (e) => {
7773
+ e.current && (e.current.style.height = `${mh}px`);
7774
+ }, _h = () => {
7775
+ const { user: e, getAccessToken: t } = Ee(), r = nr(Jt.ADDON.ATTACHMENTS), n = nr(Jt.ADDON.REASONING), { allowedModels: o } = Br(), [s, i] = Z(null), [a, l] = Z(!1), [c, d] = Z(!1), {
7765
7776
  state: { oledMode: u }
7766
- } = X(Ct), {
7777
+ } = Q(Ct), {
7767
7778
  dispatch: y,
7768
7779
  state: {
7769
7780
  reasoning: g,
@@ -7774,20 +7785,20 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7774
7785
  provider: w,
7775
7786
  privateChat: I
7776
7787
  }
7777
- } = X(we), { state: h, dispatch: S } = X(Vr), { state: x } = X(bo), { refetch: E } = Ba({
7788
+ } = Q(Ie), { state: h, dispatch: S } = Q(Vr), { state: x } = Q(bo), { refetch: E } = Ba({
7778
7789
  enabled: !1,
7779
7790
  user: e?.username || "",
7780
7791
  searchString: x.searchString,
7781
7792
  sortDirection: x.sortDirection,
7782
7793
  sortedCell: x.sortedCell,
7783
7794
  getAccessToken: t
7784
- }), { data: k } = je({
7795
+ }), { data: C } = Fe({
7785
7796
  user: e?.username,
7786
7797
  getAccessToken: t
7787
- }), M = W(null), D = W(null), O = W(!1), ee = W(0), ce = W(null), P = W(null), Ke = Va(), [de, Ve] = Ce(), lt = Km({
7798
+ }), M = J(null), D = J(null), se = J(!1), z = J(0), Y = J(null), O = J(null), de = Va(), [pe, He] = xe(), lt = eh({
7788
7799
  oledMode: u,
7789
- placeholderColor: de(Ve.Placeholder)
7790
- }), pe = n && k?.showReasoningButton, { setMessages: ut, status: et, id: Ot, sendMessage: Pt, input: Ee, setInput: Q, messages: he } = Fe({
7800
+ placeholderColor: pe(He.Placeholder)
7801
+ }), fe = n && C?.showReasoningButton, { setMessages: ut, status: et, id: Ot, sendMessage: Pt, input: Te, setInput: K, messages: ve } = Be({
7791
7802
  onFinish: (U) => {
7792
7803
  E();
7793
7804
  const te = U.message?.metadata;
@@ -7798,14 +7809,14 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7798
7809
  }
7799
7810
  });
7800
7811
  }
7801
- }), tt = Fm(!!he.length), oa = q(
7812
+ }), tt = Bm(!!ve.length), oa = X(
7802
7813
  (U) => {
7803
- Q(U.target.value);
7814
+ K(U.target.value);
7804
7815
  },
7805
- [Q]
7806
- ), sa = q(
7816
+ [K]
7817
+ ), sa = X(
7807
7818
  (U, re) => {
7808
- if (U.preventDefault(), Ee.trim()) {
7819
+ if (U.preventDefault(), Te.trim()) {
7809
7820
  const te = {
7810
7821
  /**
7811
7822
  * Include dynamic values that change during runtime. Static values like
@@ -7815,9 +7826,9 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7815
7826
  privateChat: I,
7816
7827
  ...re?.body
7817
7828
  };
7818
- k?.model && wo(k.model, o) && (te.model = k.model), Pt(
7829
+ C?.model && wo(C.model, o) && (te.model = C.model), Pt(
7819
7830
  {
7820
- text: Ee,
7831
+ text: Te,
7821
7832
  ...re?.experimental_attachments && {
7822
7833
  files: re.experimental_attachments
7823
7834
  }
@@ -7826,41 +7837,41 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7826
7837
  headers: re?.headers,
7827
7838
  body: te
7828
7839
  }
7829
- ), Q("");
7840
+ ), K("");
7830
7841
  }
7831
7842
  },
7832
7843
  [
7833
- Ee,
7844
+ Te,
7834
7845
  Pt,
7835
- Q,
7846
+ K,
7836
7847
  w,
7837
7848
  I,
7838
- k?.model,
7849
+ C?.model,
7839
7850
  o
7840
7851
  ]
7841
- ), sn = q(
7852
+ ), sn = X(
7842
7853
  async (U) => {
7843
- U === mh && y({
7844
- type: qe,
7854
+ U === hh && y({
7855
+ type: Xe,
7845
7856
  payload: {
7846
7857
  loading: !1,
7847
7858
  streaming: !1
7848
7859
  }
7849
- }), U === vh && y({
7850
- type: qe,
7860
+ }), U === yh && y({
7861
+ type: Xe,
7851
7862
  payload: {
7852
7863
  loading: !0,
7853
7864
  streaming: !1
7854
7865
  }
7855
- }), U === hh && y({
7856
- type: qe,
7866
+ }), U === gh && y({
7867
+ type: Xe,
7857
7868
  payload: {
7858
7869
  loading: !1,
7859
7870
  streaming: !0
7860
7871
  }
7861
- }), U === gh && setTimeout(() => {
7872
+ }), U === vh && setTimeout(() => {
7862
7873
  m || (y({
7863
- type: qe,
7874
+ type: Xe,
7864
7875
  payload: {
7865
7876
  loading: !1,
7866
7877
  streaming: !1
@@ -7868,7 +7879,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7868
7879
  }), ut((re) => [
7869
7880
  ...re,
7870
7881
  {
7871
- id: Ue(),
7882
+ id: je(),
7872
7883
  role: bt,
7873
7884
  parts: [{ type: "text", text: Ha }]
7874
7885
  }
@@ -7880,46 +7891,46 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7880
7891
  $(() => {
7881
7892
  et && sn(et);
7882
7893
  }, [et, sn]), $(() => {
7883
- k?.sendOnEnter !== void 0 && d(k.sendOnEnter);
7884
- }, [k]);
7885
- const cr = q(() => {
7886
- if (!P.current)
7894
+ C?.sendOnEnter !== void 0 && d(C.sendOnEnter);
7895
+ }, [C]);
7896
+ const cr = X(() => {
7897
+ if (!O.current)
7887
7898
  return;
7888
- P.current.style.height = "auto";
7889
- const U = P.current.scrollHeight;
7899
+ O.current.style.height = "auto";
7900
+ const U = O.current.scrollHeight;
7890
7901
  if (U > uo) {
7891
- P.current.style.height = `${uo}px`, P.current.style.overflowY = "scroll";
7902
+ O.current.style.height = `${uo}px`, O.current.style.overflowY = "scroll";
7892
7903
  return;
7893
7904
  }
7894
- P.current.style.height = `${U}px`, P.current.style.overflowY = "hidden";
7905
+ O.current.style.height = `${U}px`, O.current.style.overflowY = "hidden";
7895
7906
  }, []), aa = async (U) => {
7896
7907
  if (U.preventDefault(), U.target.files && U.target.files.length > 0) {
7897
7908
  const re = s ? Array.from(s) : [], te = Array.from(U.target.files), rt = [...re];
7898
- let He = !1;
7899
- for (const ge of te) {
7900
- const lr = "." + ge.name.split(".").pop()?.toLowerCase();
7901
- Je.includes(lr) ? rt.some(
7902
- (ur) => ur.name === ge.name && ur.size === ge.size && ur.lastModified === ge.lastModified
7903
- ) || rt.push(ge) : He = !0;
7909
+ let Ge = !1;
7910
+ for (const ye of te) {
7911
+ const lr = "." + ye.name.split(".").pop()?.toLowerCase();
7912
+ We.includes(lr) ? rt.some(
7913
+ (ur) => ur.name === ye.name && ur.size === ye.size && ur.lastModified === ye.lastModified
7914
+ ) || rt.push(ye) : Ge = !0;
7904
7915
  }
7905
- if (D.current && (D.current.value = ""), He) {
7906
- const ge = Je.length > 1 ? `${Je.slice(0, -1).join(", ")} and ${Je[Je.length - 1]}` : Je[0];
7907
- M.current = `Only ${ge} files are allowed.`, l(!0);
7916
+ if (D.current && (D.current.value = ""), Ge) {
7917
+ const ye = We.length > 1 ? `${We.slice(0, -1).join(", ")} and ${We[We.length - 1]}` : We[0];
7918
+ M.current = `Only ${ye} files are allowed.`, l(!0);
7908
7919
  return;
7909
7920
  }
7910
- const Ge = await uh(rt);
7911
- if (Xs(Ge) > jr) {
7921
+ const Je = await dh(rt);
7922
+ if (Xs(Je) > jr) {
7912
7923
  M.current = `Total file size exceeds the limit of ${Gt(
7913
7924
  jr
7914
7925
  )}.`, l(!0);
7915
7926
  return;
7916
7927
  }
7917
- if (Ge.length > 0) {
7918
- const ge = new DataTransfer();
7919
- Ge.forEach((lr) => ge.items.add(lr)), i(ge.files), y({
7928
+ if (Je.length > 0) {
7929
+ const ye = new DataTransfer();
7930
+ Je.forEach((lr) => ye.items.add(lr)), i(ye.files), y({
7920
7931
  type: Tt,
7921
7932
  payload: {
7922
- attachments: ge.files.length
7933
+ attachments: ye.files.length
7923
7934
  }
7924
7935
  });
7925
7936
  }
@@ -7938,17 +7949,17 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7938
7949
  attachments: re.files.length
7939
7950
  }
7940
7951
  }), D.current && (D.current.value = "");
7941
- }, la = q(() => {
7952
+ }, la = X(() => {
7942
7953
  D.current && (D.current.value = ""), i(null);
7943
7954
  }, []), an = async (U) => {
7944
- U.preventDefault(), Lt(P);
7955
+ U.preventDefault(), Lt(O);
7945
7956
  const re = await t();
7946
7957
  let te;
7947
7958
  if (s && s.length > 0) {
7948
7959
  const rt = Array.from(s).map(
7949
- (Ge) => Jm(Ge)
7950
- ), He = new DataTransfer();
7951
- rt.forEach((Ge) => He.items.add(Ge)), te = He.files;
7960
+ (Je) => Wm(Je)
7961
+ ), Ge = new DataTransfer();
7962
+ rt.forEach((Je) => Ge.items.add(Je)), te = Ge.files;
7952
7963
  }
7953
7964
  sa(U, {
7954
7965
  headers: {
@@ -7968,34 +7979,34 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
7968
7979
  [
7969
7980
  "mod+K",
7970
7981
  () => {
7971
- P && P.current && !ze() && P.current.focus();
7982
+ O && O.current && !Pe() && O.current.focus();
7972
7983
  }
7973
7984
  ]
7974
7985
  ]), $(() => {
7975
7986
  if (h.prompt !== "") {
7976
7987
  const U = h.prompt.endsWith(":") && !h.prompt.endsWith(": ") ? h.prompt + " " : h.prompt;
7977
7988
  U.indexOf(ln) !== -1 ? navigator.clipboard.readText().then((te) => {
7978
- const He = te.startsWith("http://") || te.startsWith("https://") ? te : `"""${te}"""`;
7979
- Q(U.replace(ln, He));
7980
- }) : Q(U), !ze() && P.current && P.current.focus(), S({
7989
+ const Ge = te.startsWith("http://") || te.startsWith("https://") ? te : `"""${te}"""`;
7990
+ K(U.replace(ln, Ge));
7991
+ }) : K(U), !Pe() && O.current && O.current.focus(), S({
7981
7992
  type: mo
7982
7993
  });
7983
7994
  }
7984
- }, [h, S, Q]), $(() => {
7985
- if (O.current === !1) {
7986
- O.current = !0, !Ee && Lt(P);
7995
+ }, [h, S, K]), $(() => {
7996
+ if (se.current === !1) {
7997
+ se.current = !0, !Te && Lt(O);
7987
7998
  return;
7988
7999
  }
7989
- v > 0 && v !== ee.current ? (ee.current = v, setTimeout(() => {
7990
- P.current && (!Ee && Lt(P), P.current.focus());
7991
- }, dh)) : f === !1 && !Ee && (Lt(P), !ze() && P.current && P.current.focus());
7992
- }, [v, f, Ee]), $(() => {
8000
+ v > 0 && v !== z.current ? (z.current = v, setTimeout(() => {
8001
+ O.current && (!Te && Lt(O), O.current.focus());
8002
+ }, ph)) : f === !1 && !Te && (Lt(O), !Pe() && O.current && O.current.focus());
8003
+ }, [v, f, Te]), $(() => {
7993
8004
  h.lastTriggeredTimestamp && setTimeout(() => {
7994
8005
  cr();
7995
8006
  }, 100);
7996
8007
  }, [h.lastTriggeredTimestamp, cr]), $(() => {
7997
8008
  b === 0 && (D.current && (D.current.value = ""), i(null));
7998
- }, [b]), /* @__PURE__ */ N(Me, { children: [
8009
+ }, [b]), /* @__PURE__ */ N($e, { children: [
7999
8010
  /* @__PURE__ */ p(
8000
8011
  St,
8001
8012
  {
@@ -8012,24 +8023,24 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8012
8023
  children: /* @__PURE__ */ p("p", { className: "m-0", children: M.current })
8013
8024
  }
8014
8025
  ),
8015
- /* @__PURE__ */ p("div", { className: lt.wrapper, ref: ce, children: /* @__PURE__ */ N("form", { onSubmit: an, children: [
8016
- /* @__PURE__ */ p("div", { id: Ke, className: "sr-only", children: _o }),
8026
+ /* @__PURE__ */ p("div", { className: lt.wrapper, ref: Y, children: /* @__PURE__ */ N("form", { onSubmit: an, children: [
8027
+ /* @__PURE__ */ p("div", { id: de, className: "sr-only", children: _o }),
8017
8028
  /* @__PURE__ */ N("div", { className: "relative pb-3 sm:pb-0", children: [
8018
8029
  /* @__PURE__ */ p(
8019
8030
  "textarea",
8020
8031
  {
8021
8032
  required: !0,
8022
8033
  rows: ta,
8023
- ref: P,
8034
+ ref: O,
8024
8035
  placeholder: tt,
8025
8036
  translate: "no",
8026
8037
  onChange: ua,
8027
- value: Ee,
8038
+ value: Te,
8028
8039
  onKeyDown: Ga([
8029
8040
  [c ? "enter" : "mod+Enter", an]
8030
8041
  ]),
8031
8042
  className: lt.textArea,
8032
- "aria-labelledby": Ke
8043
+ "aria-labelledby": de
8033
8044
  }
8034
8045
  ),
8035
8046
  /* @__PURE__ */ p(
@@ -8040,64 +8051,64 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8040
8051
  onChange: aa,
8041
8052
  className: "hidden",
8042
8053
  multiple: !0,
8043
- accept: Je.join(","),
8054
+ accept: We.join(","),
8044
8055
  "aria-label": "Upload files"
8045
8056
  }
8046
8057
  )
8047
8058
  ] }),
8048
- /* @__PURE__ */ p(eh, { files: s, clearFile: ca }),
8059
+ /* @__PURE__ */ p(th, { files: s, clearFile: ca }),
8049
8060
  /* @__PURE__ */ N("div", { className: "p-2 flex items-center", children: [
8050
- /* @__PURE__ */ p(jm, { className: "order-7 ml-auto" }),
8061
+ /* @__PURE__ */ p(Fm, { className: "order-7 ml-auto" }),
8051
8062
  /* @__PURE__ */ p(
8052
- mm,
8063
+ hm,
8053
8064
  {
8054
- className: z("order-1 sm:mr-2", {
8055
- "mr-3": pe,
8056
- "mr-4": !pe
8065
+ className: R("order-1 sm:mr-2", {
8066
+ "mr-3": fe,
8067
+ "mr-4": !fe
8057
8068
  })
8058
8069
  }
8059
8070
  ),
8060
8071
  /* @__PURE__ */ p(
8061
- Lm,
8072
+ Um,
8062
8073
  {
8063
- className: z("order-2 sm:mr-2", {
8064
- "mr-3": pe,
8065
- "mr-4": !pe
8074
+ className: R("order-2 sm:mr-2", {
8075
+ "mr-3": fe,
8076
+ "mr-4": !fe
8066
8077
  })
8067
8078
  }
8068
8079
  ),
8069
8080
  r && /* @__PURE__ */ p(
8070
- fm,
8081
+ mm,
8071
8082
  {
8072
- className: z("order-3 sm:mr-2", {
8073
- "mr-3": pe,
8074
- "mr-4": !pe
8083
+ className: R("order-3 sm:mr-2", {
8084
+ "mr-3": fe,
8085
+ "mr-4": !fe
8075
8086
  }),
8076
8087
  onClick: ia
8077
8088
  }
8078
8089
  ),
8079
- pe && /* @__PURE__ */ p(Um, { className: z("order-4 mr-3 sm:mr-2") }),
8090
+ fe && /* @__PURE__ */ p(jm, { className: R("order-4 mr-3 sm:mr-2") }),
8080
8091
  /* @__PURE__ */ p(
8081
- $m,
8092
+ Zm,
8082
8093
  {
8083
- className: z("order-5 mr-3 sm:mr-2", {
8084
- "mr-3": pe,
8085
- "mr-4": !pe
8094
+ className: R("order-5 mr-3 sm:mr-2", {
8095
+ "mr-3": fe,
8096
+ "mr-4": !fe
8086
8097
  })
8087
8098
  }
8088
8099
  )
8089
8100
  ] })
8090
8101
  ] }) })
8091
8102
  ] });
8092
- }, Ut = "--sassy-bottom", _h = ({ isComponent: e }) => {
8103
+ }, Ut = "--sassy-bottom", bh = ({ isComponent: e }) => {
8093
8104
  const {
8094
8105
  state: { loading: t, streaming: r, restoring: n }
8095
- } = X(we), {
8106
+ } = Q(Ie), {
8096
8107
  state: { footerHeight: o, footerPosition: s, fullScreen: i },
8097
8108
  dispatch: a
8098
- } = X(Ct), [l] = Z(
8109
+ } = Q(Ct), [l] = Z(
8099
8110
  () => un[Math.floor(Math.random() * un.length)]
8100
- ), { messages: c } = Fe(), { height: d } = Wa(), { height: u } = Ya(), [y, g] = Io(), [f, m] = Ce(), v = be(() => ze(), []), b = be(() => qa(), []), w = d - u, I = be(() => {
8111
+ ), { messages: c } = Be(), { height: d } = Wa(), { height: u } = Ya(), [y, g] = Io(), [f, m] = xe(), v = he(() => Pe(), []), b = he(() => qa(), []), w = d - u, I = he(() => {
8101
8112
  const h = v ? Xa : b ? Qa : Eo;
8102
8113
  return w > 70 && w < 500 ? v ? dn / 2 : dn : h;
8103
8114
  }, [w, v, b]);
@@ -8159,17 +8170,17 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8159
8170
  "footer",
8160
8171
  {
8161
8172
  ref: y,
8162
- className: z(
8173
+ className: R(
8163
8174
  "border-transparent mt-5",
8164
8175
  "bottom-(--sassy-bottom)",
8165
8176
  nm
8166
8177
  ),
8167
8178
  children: /* @__PURE__ */ N("div", { className: Cr({ fullScreen: i }), children: [
8168
- /* @__PURE__ */ p(yh, {}),
8179
+ /* @__PURE__ */ p(_h, {}),
8169
8180
  /* @__PURE__ */ p(
8170
8181
  "div",
8171
8182
  {
8172
- className: z(
8183
+ className: R(
8173
8184
  "w-full text-center text-xs pt-2",
8174
8185
  f(m.Footer)
8175
8186
  ),
@@ -8195,45 +8206,45 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8195
8206
  label: "Google Gemini",
8196
8207
  icon: si
8197
8208
  }
8198
- ], bh = ({ className: e }) => {
8209
+ ], wh = ({ className: e }) => {
8199
8210
  const {
8200
8211
  dispatch: t,
8201
8212
  state: { privateChat: r },
8202
8213
  setChatId: n,
8203
8214
  setInitialMessages: o
8204
- } = X(we), { getAccessToken: s, user: i } = Ie(), { status: a } = Fe(), { allowedModels: l, status: c } = Br(), [d, u] = Ce(), [y, g] = Z(!1), f = q(() => {
8215
+ } = Q(Ie), { getAccessToken: s, user: i } = Ee(), { status: a } = Be(), { allowedModels: l, status: c } = Br(), [d, u] = xe(), [y, g] = Z(!1), f = X(() => {
8205
8216
  y || (Bf(), g(!0));
8206
8217
  }, [y]), {
8207
8218
  isSuccess: m,
8208
8219
  refetch: v,
8209
8220
  data: b
8210
- } = je({
8221
+ } = Fe({
8211
8222
  user: i?.username,
8212
8223
  getAccessToken: s
8213
- }), w = be(() => {
8224
+ }), w = he(() => {
8214
8225
  if (pn(l, c)) {
8215
- const O = ei(l), ee = Tr.filter(
8216
- (ce) => O.includes(
8217
- ce.id
8226
+ const z = ei(l), Y = Tr.filter(
8227
+ (O) => z.includes(
8228
+ O.id
8218
8229
  )
8219
8230
  );
8220
- return ee.length > 0 ? ee : Tr;
8231
+ return Y.length > 0 ? Y : Tr;
8221
8232
  }
8222
8233
  return Tr;
8223
- }, [l, c]), I = be(() => pn(l, c) ? ii(l) : /* @__PURE__ */ new Map(), [l, c]), h = be(() => {
8234
+ }, [l, c]), I = he(() => pn(l, c) ? ii(l) : /* @__PURE__ */ new Map(), [l, c]), h = he(() => {
8224
8235
  if (!b?.useNestedModelSelection)
8225
8236
  return !1;
8226
- for (const O of I.values())
8227
- if (O.length > 1)
8237
+ for (const z of I.values())
8238
+ if (z.length > 1)
8228
8239
  return !0;
8229
8240
  return !1;
8230
- }, [b?.useNestedModelSelection, I]), S = async (O) => {
8241
+ }, [b?.useNestedModelSelection, I]), S = async (z) => {
8231
8242
  try {
8232
- n(Ue()), o([]), O !== b?.provider && (await fn({
8233
- provider: O,
8243
+ n(je()), o([]), z !== b?.provider && (await fn({
8244
+ provider: z,
8234
8245
  accessToken: await s(),
8235
8246
  username: i?.username || ""
8236
- }), v(), await rr(`${mn} ${O}`, {
8247
+ }), v(), await rr(`${mn} ${z}`, {
8237
8248
  containerId: "toggle-provider"
8238
8249
  })), t({
8239
8250
  type: it,
@@ -8243,18 +8254,18 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8243
8254
  });
8244
8255
  } catch {
8245
8256
  }
8246
- }, x = async (O, ee) => {
8257
+ }, x = async (z, Y) => {
8247
8258
  try {
8248
- if (n(Ue()), o([]), O !== b?.provider || ee !== b?.model) {
8259
+ if (n(je()), o([]), z !== b?.provider || Y !== b?.model) {
8249
8260
  await fn({
8250
- provider: O,
8251
- model: ee,
8261
+ provider: z,
8262
+ model: Y,
8252
8263
  accessToken: await s(),
8253
8264
  username: i?.username || ""
8254
8265
  }), v();
8255
- const ce = pr[ee] || ee;
8266
+ const O = pr[Y] || Y;
8256
8267
  await rr(
8257
- `${mn} ${O} (${ce})`,
8268
+ `${mn} ${z} (${O})`,
8258
8269
  {
8259
8270
  containerId: "toggle-provider"
8260
8271
  }
@@ -8268,15 +8279,15 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8268
8279
  });
8269
8280
  } catch {
8270
8281
  }
8271
- }, E = b && m, k = E && w.find(
8272
- (O) => b.provider === O.id
8273
- )?.icon || w[0]?.icon, M = be(() => !b?.useNestedModelSelection || !b?.model || !l || !wo(b.model, l) ? null : pr[b.model] || b.model, [b?.useNestedModelSelection, b?.model, l]), D = /* @__PURE__ */ p(Me, { children: /* @__PURE__ */ N(
8282
+ }, E = b && m, C = E && w.find(
8283
+ (z) => b.provider === z.id
8284
+ )?.icon || w[0]?.icon, M = he(() => !b?.useNestedModelSelection || !b?.model || !l || !wo(b.model, l) ? null : pr[b.model] || b.model, [b?.useNestedModelSelection, b?.model, l]), D = /* @__PURE__ */ p($e, { children: /* @__PURE__ */ N(
8274
8285
  kt,
8275
8286
  {
8276
8287
  mode: "dark",
8277
8288
  focusMode: "light",
8278
8289
  trigger: /* @__PURE__ */ p(
8279
- xe,
8290
+ Ae,
8280
8291
  {
8281
8292
  noBorder: !0,
8282
8293
  noBackground: !0,
@@ -8285,10 +8296,10 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8285
8296
  onMouseEnter: f,
8286
8297
  onFocus: f,
8287
8298
  children: /* @__PURE__ */ p(
8288
- k,
8299
+ C,
8289
8300
  {
8290
8301
  className: E && a === "streaming" ? "av-pulsate-icon" : d(u.Provider),
8291
- size: Oe
8302
+ size: Re
8292
8303
  }
8293
8304
  )
8294
8305
  }
@@ -8296,31 +8307,31 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8296
8307
  defaultPlacement: "top-start",
8297
8308
  children: [
8298
8309
  /* @__PURE__ */ p(Ur, { children: "Providers" }),
8299
- E && w.map((O) => {
8300
- const ee = I.get(O.id) || [];
8301
- return h && ee.length > 1 ? /* @__PURE__ */ N(kt, { label: O.label, children: [
8310
+ E && w.map((z) => {
8311
+ const Y = I.get(z.id) || [];
8312
+ return h && Y.length > 1 ? /* @__PURE__ */ N(kt, { label: z.label, children: [
8302
8313
  /* @__PURE__ */ N(Ur, { children: [
8303
- O.label,
8314
+ z.label,
8304
8315
  " Models"
8305
8316
  ] }),
8306
- ee.map((P) => /* @__PURE__ */ p(
8307
- _e,
8317
+ Y.map((de) => /* @__PURE__ */ p(
8318
+ we,
8308
8319
  {
8309
- selected: b.provider === O.id && b.model === P,
8310
- label: pr[P] || P,
8311
- onClick: () => x(O.id, P)
8320
+ selected: b.provider === z.id && b.model === de,
8321
+ label: pr[de] || de,
8322
+ onClick: () => x(z.id, de)
8312
8323
  },
8313
- P
8324
+ de
8314
8325
  ))
8315
- ] }, O.id) : /* @__PURE__ */ p(
8316
- _e,
8326
+ ] }, z.id) : /* @__PURE__ */ p(
8327
+ we,
8317
8328
  {
8318
- selected: b.provider === O.id,
8319
- label: O.label,
8320
- icon: /* @__PURE__ */ p(O.icon, {}),
8321
- onClick: () => S(O.id)
8329
+ selected: b.provider === z.id,
8330
+ label: z.label,
8331
+ icon: /* @__PURE__ */ p(z.icon, {}),
8332
+ onClick: () => S(z.id)
8322
8333
  },
8323
- O.id
8334
+ z.id
8324
8335
  );
8325
8336
  })
8326
8337
  ]
@@ -8328,7 +8339,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8328
8339
  ) });
8329
8340
  return E ? /* @__PURE__ */ N("div", { className: "flex items-center", children: [
8330
8341
  /* @__PURE__ */ p(
8331
- Be,
8342
+ Ve,
8332
8343
  {
8333
8344
  label: "Toggle Providers",
8334
8345
  mode: "light",
@@ -8340,7 +8351,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8340
8351
  M && /* @__PURE__ */ p(
8341
8352
  "span",
8342
8353
  {
8343
- className: z(
8354
+ className: R(
8344
8355
  "text-xs font-medium select-none",
8345
8356
  d(u.Header)
8346
8357
  ),
@@ -8348,120 +8359,120 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8348
8359
  }
8349
8360
  )
8350
8361
  ] }) : /* @__PURE__ */ p("div", { className: e, children: D });
8351
- }, wh = Pe(
8362
+ }, Ih = Me(
8352
8363
  () => import(
8353
8364
  /* webpackChunkName: "modal-chunk" */
8354
- "./ProfileEntry.CgX_IsH2.js"
8365
+ "./ProfileEntry.BTJI95Ps.js"
8355
8366
  ).then((e) => ({
8356
8367
  default: e.Profile
8357
8368
  }))
8358
- ), Ih = Pe(
8369
+ ), Eh = Me(
8359
8370
  () => import(
8360
8371
  /* webpackChunkName: "modal-chunk" */
8361
- "./SettingsEntry.DgDbgbp8.js"
8372
+ "./SettingsEntry.Bh6zMUQR.js"
8362
8373
  ).then((e) => ({
8363
8374
  default: e.SettingsPanel
8364
8375
  }))
8365
- ), Eh = Pe(
8376
+ ), Th = Me(
8366
8377
  () => import(
8367
8378
  /* webpackChunkName: "modal-chunk" */
8368
- "./HistoryEntry.DUOzZAtx.js"
8379
+ "./HistoryEntry.A_zM8X2l.js"
8369
8380
  ).then((e) => ({
8370
8381
  default: e.HistoryPanel
8371
8382
  }))
8372
- ), Th = Pe(
8383
+ ), Sh = Me(
8373
8384
  () => import(
8374
8385
  /* webpackChunkName: "modal-chunk" */
8375
- "./AboutEntry.Cx6IKOQG.js"
8386
+ "./AboutEntry.C3YYsRM3.js"
8376
8387
  ).then((e) => ({ default: e.About }))
8377
- ), Sh = Pe(
8388
+ ), kh = Me(
8378
8389
  () => import(
8379
8390
  /* webpackChunkName: "modal-chunk" */
8380
- "./UsageEntry.BD2iSXcr.js"
8391
+ "./UsageEntry.DDAJ5UIh.js"
8381
8392
  ).then((e) => ({ default: e.Usage }))
8382
- ), kh = Pe(
8393
+ ), Ch = Me(
8383
8394
  () => import(
8384
8395
  /* webpackChunkName: "modal-chunk" */
8385
- "./UserMemoriesPanel.BRw2SUCk.js"
8396
+ "./UserMemoriesPanel.Cb4rReTt.js"
8386
8397
  ).then(
8387
8398
  (e) => ({ default: e.default })
8388
8399
  )
8389
- ), Ch = ({
8400
+ ), xh = ({
8390
8401
  open: e,
8391
8402
  onOpenChange: t
8392
8403
  }) => {
8393
- const { user: r } = Ie();
8404
+ const { user: r } = Ee();
8394
8405
  return /* @__PURE__ */ p(
8395
- kh,
8406
+ Ch,
8396
8407
  {
8397
8408
  open: e,
8398
8409
  onOpenChange: t,
8399
8410
  user: r?.username
8400
8411
  }
8401
8412
  );
8402
- }, xh = ({ type: e, open: t, onOpenChange: r }) => t ? /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("div", {}), children: (() => {
8413
+ }, Ah = ({ type: e, open: t, onOpenChange: r }) => t ? /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("div", {}), children: (() => {
8403
8414
  switch (e) {
8404
8415
  case "profile":
8405
- return /* @__PURE__ */ p(wh, { open: t, onOpenChange: r });
8406
- case "settings":
8407
8416
  return /* @__PURE__ */ p(Ih, { open: t, onOpenChange: r });
8408
- case "history":
8417
+ case "settings":
8409
8418
  return /* @__PURE__ */ p(Eh, { open: t, onOpenChange: r });
8410
- case "about":
8419
+ case "history":
8411
8420
  return /* @__PURE__ */ p(Th, { open: t, onOpenChange: r });
8412
- case "usage":
8421
+ case "about":
8413
8422
  return /* @__PURE__ */ p(Sh, { open: t, onOpenChange: r });
8423
+ case "usage":
8424
+ return /* @__PURE__ */ p(kh, { open: t, onOpenChange: r });
8414
8425
  case "memories":
8415
- return /* @__PURE__ */ p(Ch, { open: t, onOpenChange: r });
8426
+ return /* @__PURE__ */ p(xh, { open: t, onOpenChange: r });
8416
8427
  default:
8417
8428
  return null;
8418
8429
  }
8419
- })() }) : null, Ah = ({
8430
+ })() }) : null, Nh = ({
8420
8431
  isComponent: e = !1
8421
8432
  }) => {
8422
8433
  const {
8423
8434
  state: { oledMode: t }
8424
- } = X(Ct), { logout: r, getAccessToken: n, user: o } = Ie(), s = ci(), [i, a] = Ce(), { data: l, isSuccess: c } = je({
8435
+ } = Q(Ct), { logout: r, getAccessToken: n, user: o } = Ee(), s = ci(), [i, a] = xe(), { data: l, isSuccess: c } = Fe({
8425
8436
  user: o?.username,
8426
8437
  getAccessToken: n
8427
8438
  }), [d, u] = Z(null), [y, g] = Z(!1), [f, m] = Z(!1), [v, b] = Z(!1), w = nr(Jt.TOOL.MEMORIES);
8428
8439
  $(() => {
8429
8440
  c && l && w && b(l?.useMemory ?? !1);
8430
8441
  }, [c, l, w]);
8431
- const I = q(() => {
8442
+ const I = X(() => {
8432
8443
  f || Promise.all([
8433
8444
  import(
8434
8445
  /* webpackChunkName: "modal-chunk" */
8435
- "./ProfileEntry.CgX_IsH2.js"
8446
+ "./ProfileEntry.BTJI95Ps.js"
8436
8447
  ),
8437
8448
  import(
8438
8449
  /* webpackChunkName: "modal-chunk" */
8439
- "./SettingsEntry.DgDbgbp8.js"
8450
+ "./SettingsEntry.Bh6zMUQR.js"
8440
8451
  ),
8441
8452
  import(
8442
8453
  /* webpackChunkName: "modal-chunk" */
8443
- "./HistoryEntry.DUOzZAtx.js"
8454
+ "./HistoryEntry.A_zM8X2l.js"
8444
8455
  ),
8445
8456
  import(
8446
8457
  /* webpackChunkName: "modal-chunk" */
8447
- "./AboutEntry.Cx6IKOQG.js"
8458
+ "./AboutEntry.C3YYsRM3.js"
8448
8459
  ),
8449
8460
  import(
8450
8461
  /* webpackChunkName: "modal-chunk" */
8451
- "./UsageEntry.BD2iSXcr.js"
8462
+ "./UsageEntry.DDAJ5UIh.js"
8452
8463
  )
8453
8464
  ]).finally(() => m(!0));
8454
- }, [f]), h = q((M) => {
8465
+ }, [f]), h = X((M) => {
8455
8466
  u(M);
8456
- }, []), S = q(() => {
8467
+ }, []), S = X(() => {
8457
8468
  u(null);
8458
- }, []), x = q(() => {
8469
+ }, []), x = X(() => {
8459
8470
  h("settings");
8460
8471
  }, [h]);
8461
8472
  Ys("openSettings", x);
8462
8473
  const E = () => {
8463
8474
  g(!y);
8464
- }, k = q(() => {
8475
+ }, C = X(() => {
8465
8476
  s.clear(), r();
8466
8477
  }, [r, s]);
8467
8478
  return Fr(
@@ -8479,13 +8490,13 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8479
8490
  * focus.
8480
8491
  */
8481
8492
  []
8482
- ), /* @__PURE__ */ N(Me, { children: [
8493
+ ), /* @__PURE__ */ N($e, { children: [
8483
8494
  /* @__PURE__ */ p(
8484
8495
  St,
8485
8496
  {
8486
8497
  showConfirmation: y,
8487
8498
  setShowConfirmation: g,
8488
- action: k,
8499
+ action: C,
8489
8500
  customStrings: {
8490
8501
  confirmAction: hn,
8491
8502
  cancelAction: "Cancel",
@@ -8495,7 +8506,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8495
8506
  }
8496
8507
  ),
8497
8508
  /* @__PURE__ */ p(
8498
- xh,
8509
+ Ah,
8499
8510
  {
8500
8511
  type: d,
8501
8512
  open: d !== null,
@@ -8505,7 +8516,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8505
8516
  /* @__PURE__ */ p(
8506
8517
  "div",
8507
8518
  {
8508
- className: z("py-4 px-4 rounded-t-md", {
8519
+ className: R("py-4 px-4 rounded-t-md", {
8509
8520
  "bg-slate-900": !t,
8510
8521
  "bg-slate-900/95 dark:bg-slate-900": t
8511
8522
  }),
@@ -8517,9 +8528,9 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8517
8528
  rowGap: 0,
8518
8529
  columnGap: 0,
8519
8530
  children: [
8520
- /* @__PURE__ */ p(at, { children: /* @__PURE__ */ p(bh, { className: "mr-2" }) }),
8531
+ /* @__PURE__ */ p(at, { children: /* @__PURE__ */ p(wh, { className: "mr-2" }) }),
8521
8532
  /* @__PURE__ */ p(at, { children: /* @__PURE__ */ p(
8522
- Be,
8533
+ Ve,
8523
8534
  {
8524
8535
  label: "Profile, Settings, etc.",
8525
8536
  mode: "light",
@@ -8530,7 +8541,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8530
8541
  mode: "dark",
8531
8542
  focusMode: "light",
8532
8543
  trigger: /* @__PURE__ */ p(
8533
- xe,
8544
+ Ae,
8534
8545
  {
8535
8546
  noBorder: !0,
8536
8547
  noBackground: !0,
@@ -8543,7 +8554,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8543
8554
  defaultPlacement: "bottom-end",
8544
8555
  children: [
8545
8556
  /* @__PURE__ */ p(
8546
- _e,
8557
+ we,
8547
8558
  {
8548
8559
  label: "Profile",
8549
8560
  onClick: () => h("profile"),
@@ -8551,7 +8562,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8551
8562
  }
8552
8563
  ),
8553
8564
  /* @__PURE__ */ p(
8554
- _e,
8565
+ we,
8555
8566
  {
8556
8567
  label: "Settings",
8557
8568
  onClick: () => h("settings"),
@@ -8559,7 +8570,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8559
8570
  }
8560
8571
  ),
8561
8572
  /* @__PURE__ */ p(
8562
- _e,
8573
+ we,
8563
8574
  {
8564
8575
  label: "History",
8565
8576
  onClick: () => h("history"),
@@ -8567,7 +8578,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8567
8578
  }
8568
8579
  ),
8569
8580
  v && /* @__PURE__ */ p(
8570
- _e,
8581
+ we,
8571
8582
  {
8572
8583
  label: "Memories",
8573
8584
  onClick: () => h("memories"),
@@ -8575,7 +8586,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8575
8586
  }
8576
8587
  ),
8577
8588
  !e && /* @__PURE__ */ p(
8578
- _e,
8589
+ we,
8579
8590
  {
8580
8591
  label: "Usage",
8581
8592
  onClick: () => h("usage"),
@@ -8583,17 +8594,17 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8583
8594
  }
8584
8595
  ),
8585
8596
  /* @__PURE__ */ p(
8586
- _e,
8597
+ we,
8587
8598
  {
8588
8599
  label: "About",
8589
8600
  onClick: () => h("about"),
8590
8601
  icon: /* @__PURE__ */ p(mi, {})
8591
8602
  }
8592
8603
  ),
8593
- !e && /* @__PURE__ */ N(Me, { children: [
8594
- /* @__PURE__ */ p(Zm, {}),
8604
+ !e && /* @__PURE__ */ N($e, { children: [
8605
+ /* @__PURE__ */ p(Dm, {}),
8595
8606
  /* @__PURE__ */ p(
8596
- _e,
8607
+ we,
8597
8608
  {
8598
8609
  label: "Log out",
8599
8610
  onClick: E,
@@ -8612,7 +8623,7 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8612
8623
  }
8613
8624
  )
8614
8625
  ] });
8615
- }, Nh = ({
8626
+ }, Oh = ({
8616
8627
  show: e,
8617
8628
  bottom: t,
8618
8629
  onClick: r,
@@ -8622,14 +8633,14 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8622
8633
  "div",
8623
8634
  {
8624
8635
  style: { bottom: `${t}px` },
8625
- className: n || z(
8636
+ className: n || R(
8626
8637
  om,
8627
8638
  "fixed left-1/2 transform -translate-x-1/2 isolate"
8628
8639
  ),
8629
8640
  children: /* @__PURE__ */ p(
8630
8641
  "button",
8631
8642
  {
8632
- className: z(
8643
+ className: R(
8633
8644
  "focus:outline-2",
8634
8645
  "focus:outline-focus-dark dark:focus:outline-focus-light",
8635
8646
  "av-button not-prose truncate text-copy-light rounded-full inline-flex items-center justify-center h-8 w-8 p-1 border border-white/20 dark:border-black/20 focus:outline-offset-2 disabled:opacity-50 dark:bg-slate-50/60 bg-slate-500/60 backdrop-blur-lg backdrop-saturate-150 disabled:cursor-auto opacity-90 hover:opacity-100 transition-opacity",
@@ -8659,25 +8670,25 @@ const Bm = [".png", ".jpg", ".jpeg", ".webp"], Vm = [".pdf", ".txt"], Hm = [
8659
8670
  }
8660
8671
  ) : null;
8661
8672
  /*!
8662
- @versini/ui-spinner v5.1.1
8673
+ @versini/ui-spinner v5.1.2
8663
8674
  © 2025 gizmette.com
8664
8675
  */
8665
8676
  try {
8666
8677
  window.__VERSINI_UI_SPINNER__ || (window.__VERSINI_UI_SPINNER__ = {
8667
- version: "5.1.1",
8668
- buildTime: "11/16/2025 05:50 PM EST",
8678
+ version: "5.1.2",
8679
+ buildTime: "11/30/2025 06:54 PM EST",
8669
8680
  homepage: "https://github.com/aversini/ui-components",
8670
8681
  license: "MIT"
8671
8682
  });
8672
8683
  } catch {
8673
8684
  }
8674
8685
  const po = "av-spinner", ra = ({ spinnerRef: e, mode: t = "system", type: r = "circle", className: n }) => {
8675
- const o = r === "circle" ? z(po, "h-8 w-8", "align-[-0.125em]", "border-4", "inline-block animate-spin rounded-full border-solid border-current border-r-transparent motion-reduce:animate-[spin_1.5s_linear_infinite]", {
8686
+ const o = r === "circle" ? R(po, "h-8 w-8", "align-[-0.125em]", "border-4", "inline-block animate-spin rounded-full border-solid border-current border-r-transparent motion-reduce:animate-[spin_1.5s_linear_infinite]", {
8676
8687
  "text-copy-dark": t === "dark",
8677
8688
  "text-copy-accent": t === "light",
8678
8689
  "text-copy-dark dark:text-copy-accent": t === "system",
8679
8690
  "text-copy-accent dark:text-copy-dark": t === "alt-system"
8680
- }, n) : z(po, n), s = z("av-spinner__dot", {
8691
+ }, n) : R(po, n), s = R("av-spinner__dot", {
8681
8692
  "fill-copy-dark": t === "dark",
8682
8693
  "fill-copy-accent": t === "light",
8683
8694
  "fill-copy-dark dark:fill-copy-accent": t === "system",
@@ -8717,21 +8728,21 @@ const po = "av-spinner", ra = ({ spinnerRef: e, mode: t = "system", type: r = "c
8717
8728
  })
8718
8729
  ]
8719
8730
  });
8720
- }, Oh = Pe(
8721
- () => import("./index.U5DkfFOw.js").then((e) => ({ default: e.Bubble }))
8722
- ), on = (e) => /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("span", { className: "inline-block" }), children: /* @__PURE__ */ p(Oh, { ...e }) });
8731
+ }, Ph = Me(
8732
+ () => import("./index.DzVmZ1PW.js").then((e) => ({ default: e.Bubble }))
8733
+ ), on = (e) => /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("span", { className: "inline-block" }), children: /* @__PURE__ */ p(Ph, { ...e }) });
8723
8734
  on.displayName = "AsyncBubble";
8724
- const fo = 1, Ph = 150, Rh = Pe(
8735
+ const fo = 1, Rh = 150, Mh = Me(
8725
8736
  () => import(
8726
8737
  /* webpackChunkName: "LazyMessageAssistant" */
8727
- "./ChatBubbleAssistant.6Xu3MZrx.js"
8738
+ "./ChatBubbleAssistant.D-_zHFRv.js"
8728
8739
  )
8729
- ), zh = Pe(
8740
+ ), zh = Me(
8730
8741
  () => import(
8731
8742
  /* webpackChunkName: "LazyMessageUser" */
8732
- "./ChatBubbleUser.BQpzE_nc.js"
8743
+ "./ChatBubbleUser.DhmmlriT.js"
8733
8744
  )
8734
- ), Mh = ko.memo(
8745
+ ), $h = ko.memo(
8735
8746
  ({
8736
8747
  role: e,
8737
8748
  content: t,
@@ -8740,12 +8751,12 @@ const fo = 1, Ph = 150, Rh = Pe(
8740
8751
  isLastAssistantMessage: o = !1,
8741
8752
  status: s
8742
8753
  }) => {
8743
- const [i, a] = Z(!0), l = W(Date.now()), [c] = Z(
8754
+ const [i, a] = Z(!0), l = J(Date.now()), [c] = Z(
8744
8755
  () => o && (s === "streaming" || s === "submitted")
8745
8756
  );
8746
8757
  return $(() => {
8747
8758
  if (o && i && t && t.trim().length >= fo) {
8748
- const u = Date.now() - l.current, y = Ph - u;
8759
+ const u = Date.now() - l.current, y = Rh - u;
8749
8760
  if (y > 0) {
8750
8761
  const g = setTimeout(
8751
8762
  () => a(!1),
@@ -8756,7 +8767,7 @@ const fo = 1, Ph = 150, Rh = Pe(
8756
8767
  a(!1);
8757
8768
  }
8758
8769
  }, [t, i, o]), e === To && t ? /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("span", {}), children: /* @__PURE__ */ p(zh, { content: t }) }) : e === bt && o && (s === "submitted" || s === "streaming") && i ? /* @__PURE__ */ p(on, { tail: !0, children: /* @__PURE__ */ p(ra, { type: "dots" }) }) : e === bt && t && t.trim().length >= fo ? /* @__PURE__ */ p(Wt, { fallback: /* @__PURE__ */ p("span", {}), children: /* @__PURE__ */ p(
8759
- Rh,
8770
+ Mh,
8760
8771
  {
8761
8772
  role: e,
8762
8773
  content: t,
@@ -8767,7 +8778,7 @@ const fo = 1, Ph = 150, Rh = Pe(
8767
8778
  }
8768
8779
  ) }) : null;
8769
8780
  }
8770
- ), $h = (e) => {
8781
+ ), Zh = (e) => {
8771
8782
  if (e.parts && Array.isArray(e.parts)) {
8772
8783
  const t = e.parts.filter((r) => r.type === "text").map((r) => r.text).filter(Boolean);
8773
8784
  return t.length > 0 ? t.join(`
@@ -8776,7 +8787,7 @@ const fo = 1, Ph = 150, Rh = Pe(
8776
8787
  if ("content" in e && typeof e.content == "string")
8777
8788
  return e.content;
8778
8789
  };
8779
- function Zh(e) {
8790
+ function Dh(e) {
8780
8791
  const t = e.metadata;
8781
8792
  if (t?.model)
8782
8793
  return { model: String(t.model) };
@@ -8790,14 +8801,14 @@ function Zh(e) {
8790
8801
  }
8791
8802
  }
8792
8803
  }
8793
- const Dh = () => {
8794
- const { messages: e, status: t } = Fe(), r = e ? e.map((s, i) => s.role === bt ? i : -1).filter((s) => s !== -1).pop() : -1, n = e && e.length > 0 ? e[e.length - 1] : null, o = (t === "submitted" || t === "streaming") && n?.role === To;
8804
+ const Lh = () => {
8805
+ const { messages: e, status: t } = Be(), r = e ? e.map((s, i) => s.role === bt ? i : -1).filter((s) => s !== -1).pop() : -1, n = e && e.length > 0 ? e[e.length - 1] : null, o = (t === "submitted" || t === "streaming") && n?.role === To;
8795
8806
  return e && e.length > 0 ? /* @__PURE__ */ N("div", { className: "space-y-6 mt-2 @container", children: [
8796
8807
  e?.map((s, i) => {
8797
8808
  let a;
8798
- const l = `${i}-${s.role}`, c = $h(s), d = Zh(s), u = s.role === bt && i === r;
8809
+ const l = `${i}-${s.role}`, c = Zh(s), d = Dh(s), u = s.role === bt && i === r;
8799
8810
  return /* @__PURE__ */ p(
8800
- Mh,
8811
+ $h,
8801
8812
  {
8802
8813
  role: s.role,
8803
8814
  content: c,
@@ -8811,16 +8822,16 @@ const Dh = () => {
8811
8822
  }),
8812
8823
  o && /* @__PURE__ */ p(on, { tail: !0, children: /* @__PURE__ */ p(ra, { type: "dots" }) })
8813
8824
  ] }) : null;
8814
- }, Lh = () => {
8815
- const { isAuthenticated: e } = Ie(), { ref: t, inViewport: r } = vi(), n = W(null), o = W(null), {
8825
+ }, Uh = () => {
8826
+ const { isAuthenticated: e } = Ee(), { ref: t, inViewport: r } = vi(), n = J(null), o = J(null), {
8816
8827
  state: { footerPosition: s, footerHeight: i, footerOffset: a, oledMode: l }
8817
- } = X(Ct), {
8828
+ } = Q(Ct), {
8818
8829
  state: { loading: c }
8819
- } = X(we), { messages: d } = Fe(), u = W(0), { data: y, isSuccess: g } = yi(), f = _i({
8830
+ } = Q(Ie), { messages: d } = Be(), u = J(0), { data: y, isSuccess: g } = yi(), f = _i({
8820
8831
  isAuthenticated: e,
8821
8832
  oledMode: l,
8822
8833
  extraClass: "rounded-b-md relative border-b-16 border-transparent"
8823
- }), m = Ii() ? "mt-4" : "", v = q(() => {
8834
+ }), m = Ii() ? "mt-4" : "", v = X(() => {
8824
8835
  o.current && o.current.scrollIntoView({
8825
8836
  behavior: "smooth",
8826
8837
  block: "end"
@@ -8830,7 +8841,7 @@ const Dh = () => {
8830
8841
  c && v();
8831
8842
  }, [c, v]), $(() => {
8832
8843
  u.current = s === vt ? i + a + So + bi + 15 : 0;
8833
- }, [s, i, a]), /* @__PURE__ */ N(Me, { children: [
8844
+ }, [s, i, a]), /* @__PURE__ */ N($e, { children: [
8834
8845
  /* @__PURE__ */ N("div", { className: f, ref: n, children: [
8835
8846
  /* @__PURE__ */ p(
8836
8847
  wi,
@@ -8840,20 +8851,20 @@ const Dh = () => {
8840
8851
  capabilities: y
8841
8852
  }
8842
8853
  ),
8843
- /* @__PURE__ */ p(Dh, {}),
8854
+ /* @__PURE__ */ p(Lh, {}),
8844
8855
  /* @__PURE__ */ p("div", { ref: t, className: "scroll-marker" }),
8845
8856
  /* @__PURE__ */ p(
8846
8857
  "div",
8847
8858
  {
8848
8859
  ref: o,
8849
- className: z({
8860
+ className: R({
8850
8861
  "pt-20": d && d.length > 1
8851
8862
  })
8852
8863
  }
8853
8864
  )
8854
8865
  ] }),
8855
8866
  /* @__PURE__ */ p(
8856
- Nh,
8867
+ Oh,
8857
8868
  {
8858
8869
  show: !r && s === vt,
8859
8870
  bottom: u.current,
@@ -8866,34 +8877,34 @@ function na({
8866
8877
  isComponent: e = !1,
8867
8878
  headerHeight: t = 0
8868
8879
  }) {
8869
- const { user: r, getAccessToken: n } = Ie(), [o, s] = Z(`${gn}px`), [i, a] = Io(), [l, c] = Z(Ue()), [d, u] = Z([]), [y] = Ne({
8870
- key: ke + zi,
8880
+ const { user: r, getAccessToken: n } = Ee(), [o, s] = Z(`${gn}px`), [i, a] = Io(), [l, c] = Z(je()), [d, u] = Z([]), [y] = Oe({
8881
+ key: Ce + Mi,
8871
8882
  initialValue: ""
8872
- }), [g] = Ne({
8873
- key: ke + Ri,
8883
+ }), [g] = Oe({
8884
+ key: Ce + Ri,
8874
8885
  initialValue: vn
8875
- }), [f] = Ne({
8876
- key: ke + Zi,
8886
+ }), [f] = Oe({
8887
+ key: Ce + Zi,
8877
8888
  initialValue: gt.DESC
8878
- }), [m] = Ne({
8879
- key: ke + Di,
8889
+ }), [m] = Oe({
8890
+ key: Ce + Di,
8880
8891
  initialValue: gt.ASC
8881
- }), [v] = Ne({
8882
- key: Mi,
8892
+ }), [v] = Oe({
8893
+ key: zi,
8883
8894
  initialValue: !1
8884
- }), [b] = Ne({
8895
+ }), [b] = Oe({
8885
8896
  key: $i,
8886
8897
  initialValue: !1
8887
- }), w = be(() => ({
8898
+ }), w = he(() => ({
8888
8899
  footerPosition: kr,
8889
8900
  footerHeight: 0,
8890
- footerOffset: ze() ? Eo : 0,
8901
+ footerOffset: Pe() ? Eo : 0,
8891
8902
  oledMode: !1,
8892
8903
  fullScreen: !1,
8893
8904
  themeMode: Ei
8894
- }), []), [I, h] = Rt(Ti, w), S = be(() => {
8895
- const de = ze(), Ve = go();
8896
- return de && Ve ? "mt-1" : "mt-5";
8905
+ }), []), [I, h] = Rt(Ti, w), S = he(() => {
8906
+ const pe = Pe(), He = go();
8907
+ return pe && He ? "mt-1" : "mt-5";
8897
8908
  }, []), E = {
8898
8909
  searchString: y,
8899
8910
  sortedCell: g,
@@ -8906,13 +8917,13 @@ function na({
8906
8917
  return f;
8907
8918
  }
8908
8919
  })()
8909
- }, [k, M] = Rt(
8920
+ }, [C, M] = Rt(
8910
8921
  Gf,
8911
8922
  E
8912
- ), [D, O] = Rt(Jf, {
8923
+ ), [D, se] = Rt(Jf, {
8913
8924
  prompt: "",
8914
8925
  lastTriggeredTimestamp: 0
8915
- }), [ee, ce] = Rt(Hf, {
8926
+ }), [z, Y] = Rt(Hf, {
8916
8927
  provider: "",
8917
8928
  // OpenAI, Anthropic, etc.
8918
8929
  privateChat: !1,
@@ -8925,10 +8936,10 @@ function na({
8925
8936
  attachments: 0,
8926
8937
  lastStreamingTimestamp: 0,
8927
8938
  lastResetTimestamp: 0
8928
- }), { data: P } = je({
8939
+ }), { data: O } = Fe({
8929
8940
  user: r?.username,
8930
8941
  getAccessToken: n
8931
- }), Ke = be(() => new rn({
8942
+ }), de = he(() => new rn({
8932
8943
  api: `${vo}/api/generate`,
8933
8944
  // Only include static values in transport body.
8934
8945
  body: {
@@ -8939,7 +8950,7 @@ function na({
8939
8950
  currentChatId: l,
8940
8951
  setChatId: c,
8941
8952
  setInitialMessages: u,
8942
- dispatchChat: ce
8953
+ dispatchChat: Y
8943
8954
  }), $(() => {
8944
8955
  document.getElementById("root")?.classList.replace("app-hidden", "fadeIn");
8945
8956
  }, []), $(() => {
@@ -8953,55 +8964,55 @@ function na({
8953
8964
  payload: { fullScreen: b }
8954
8965
  });
8955
8966
  }, [b]), $(() => {
8956
- P?.themeMode && h({
8967
+ O?.themeMode && h({
8957
8968
  type: xi,
8958
- payload: { themeMode: P.themeMode }
8959
- }), P?.themePalette && h({
8969
+ payload: { themeMode: O.themeMode }
8970
+ }), O?.themePalette && h({
8960
8971
  type: Ai,
8961
- payload: { themePalette: P.themePalette }
8972
+ payload: { themePalette: O.themePalette }
8962
8973
  });
8963
- }, [P]), $(() => {
8964
- P && P.provider && ce({
8974
+ }, [O]), $(() => {
8975
+ O && O.provider && Y({
8965
8976
  type: Gs,
8966
8977
  payload: {
8967
- provider: P.provider
8978
+ provider: O.provider
8968
8979
  }
8969
8980
  });
8970
- }, [P]), $(() => {
8981
+ }, [O]), $(() => {
8971
8982
  try {
8972
- const de = sessionStorage.getItem("sw-toggle-pending");
8973
- de && (de === "enabled" ? rr(Li, { containerId: "toggle-save" }) : de === "disabled" && rr(Ui, {
8983
+ const pe = sessionStorage.getItem("sw-toggle-pending");
8984
+ pe && (pe === "enabled" ? rr(Li, { containerId: "toggle-save" }) : pe === "disabled" && rr(Ui, {
8974
8985
  containerId: "toggle-save"
8975
8986
  }), sessionStorage.removeItem("sw-toggle-pending"));
8976
8987
  } catch {
8977
8988
  }
8978
8989
  }, []), Gr(() => {
8979
8990
  if (I.footerPosition === "FOOTER_BOTTOM") {
8980
- const de = S === "mt-1" ? 4 : 20, Ve = `calc(${a.height}px + ${de}px)`;
8991
+ const pe = S === "mt-1" ? 4 : 20, He = `calc(${a.height}px + ${pe}px)`;
8981
8992
  s(
8982
- `calc(100svh - ${t}px - ${Ve} - ${I.footerHeight}px - ${I.footerOffset}px - ${So}px)`
8993
+ `calc(100svh - ${t}px - ${He} - ${I.footerHeight}px - ${I.footerOffset}px - ${So}px)`
8983
8994
  );
8984
8995
  } else
8985
8996
  s(
8986
- ze() ? `${Ni}px` : `${gn}px`
8997
+ Pe() ? `${Ni}px` : `${gn}px`
8987
8998
  );
8988
8999
  }, [I, a, t, S]), /* @__PURE__ */ p(
8989
9000
  bo.Provider,
8990
9001
  {
8991
9002
  value: {
8992
- state: k,
9003
+ state: C,
8993
9004
  dispatch: M
8994
9005
  },
8995
9006
  children: /* @__PURE__ */ p(Ct.Provider, { value: { state: I, dispatch: h }, children: /* @__PURE__ */ p(
8996
9007
  Vr.Provider,
8997
9008
  {
8998
- value: { state: D, dispatch: O },
9009
+ value: { state: D, dispatch: se },
8999
9010
  children: /* @__PURE__ */ p(
9000
- we.Provider,
9011
+ Ie.Provider,
9001
9012
  {
9002
9013
  value: {
9003
- state: ee,
9004
- dispatch: ce,
9014
+ state: z,
9015
+ dispatch: Y,
9005
9016
  setChatId: c,
9006
9017
  setInitialMessages: u
9007
9018
  },
@@ -9011,10 +9022,10 @@ function na({
9011
9022
  value: {
9012
9023
  id: l,
9013
9024
  messages: d,
9014
- transport: Ke,
9025
+ transport: de,
9015
9026
  experimental_throttle: 300,
9016
9027
  generateId() {
9017
- return Ue();
9028
+ return je();
9018
9029
  }
9019
9030
  },
9020
9031
  children: [
@@ -9031,7 +9042,7 @@ function na({
9031
9042
  extraClass: S,
9032
9043
  fullScreen: b
9033
9044
  }),
9034
- children: /* @__PURE__ */ p(Ah, { isComponent: e })
9045
+ children: /* @__PURE__ */ p(Nh, { isComponent: e })
9035
9046
  }
9036
9047
  ),
9037
9048
  /* @__PURE__ */ p(
@@ -9041,10 +9052,10 @@ function na({
9041
9052
  style: {
9042
9053
  height: o
9043
9054
  },
9044
- children: /* @__PURE__ */ p(Lh, {})
9055
+ children: /* @__PURE__ */ p(Uh, {})
9045
9056
  }
9046
9057
  ),
9047
- /* @__PURE__ */ p(_h, { isComponent: e })
9058
+ /* @__PURE__ */ p(bh, { isComponent: e })
9048
9059
  ]
9049
9060
  }
9050
9061
  )
@@ -9056,27 +9067,27 @@ function na({
9056
9067
  );
9057
9068
  }
9058
9069
  na.displayName = "App";
9059
- const Jh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: na }, Symbol.toStringTag, { value: "Module" }));
9070
+ const Wh = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: na }, Symbol.toStringTag, { value: "Module" }));
9060
9071
  export {
9061
- Jh as App,
9072
+ Wh as App,
9062
9073
  on as AsyncBubble,
9063
- Nh as ButtonScroll,
9074
+ Oh as ButtonScroll,
9064
9075
  it as CHAT_RESET,
9065
9076
  Tt as CHAT_SET_ATTACHMENTS,
9066
- qe as CHAT_SET_STATUS,
9077
+ Xe as CHAT_SET_STATUS,
9067
9078
  St as ConfirmationPanel,
9068
9079
  ro as LazyToastContainerWrapper,
9069
9080
  kt as Menu,
9070
9081
  Ur as MenuGroupLabel,
9071
- _e as MenuItem,
9072
- Sm as Panel,
9073
- Mm as Toggle,
9074
- Be as Tooltip,
9082
+ we as MenuItem,
9083
+ km as Panel,
9084
+ Ve as ResponsiveTooltip,
9085
+ $m as Toggle,
9075
9086
  ff as getDefaultExportFromCjs,
9076
9087
  Bf as preloadToast,
9077
9088
  Vf as showErrorToast,
9078
9089
  rr as showSuccessToast,
9079
- Fe as useAiChat,
9090
+ Be as useAiChat,
9080
9091
  nr as useCapability,
9081
- Ue as v4
9092
+ je as v4
9082
9093
  };