@versini/sassysaint 5.5.34 → 5.5.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
- import { jsxs as x, jsx as i, Fragment as ht } from "react/jsx-runtime";
2
- import { g as ie, ACTION_RESTORE as Kr, ACTION_MESSAGE as ye, ROLE_ASSISTANT as ve, ACTION_RESET as ft, ACTION_MODEL as cr, ACTION_STREAMING as lr, ACTION_SORT as Jr, ACTION_SEARCH as Yr, ACTION_RESET_PROMPT as dr, ACTION_TOGGLE_PROMPT as ur, DEFAULT_AI_ENGINE as ke, P as Ee, un as xe, ENGINE_ANTHROPIC as Fe, ENGINE_OPENAI as $t, PROMPT_CLASSNAME as Zr, PROMPT_EDITABLE_AREA_CLASSNAME as Xr, ROLE_SYSTEM as Qr, ROLE_INTERNAL as pt, ROLE_HIDDEN as ea, STATS_SEPARATOR as Dt, CLIPBOARD_PROMPT as Vt, TYPE_QUESTION as ta, ERROR_MESSAGE as ra, ROLE_USER as Qe, FOOTER_DISCLAIMER as aa, isLastMessageFromRole as na, getMessageContaintWrapperClass as oa, Logo as sa, getMainPaddingClass as Pt, r as ia, LOCAL_STORAGE_PREFIX as Ut, LOCAL_STORAGE_SEARCH as ca, LOCAL_STORAGE_SORT as la } from "./index.VGoUE96U.js";
1
+ import { jsxs as x, jsx as i, Fragment as Ae } from "react/jsx-runtime";
2
+ import { g as me, ACTION_RESTORE as qr, ACTION_MESSAGE as ye, ROLE_ASSISTANT as ve, ACTION_RESET as ft, ACTION_MODEL as ir, ACTION_STREAMING as cr, ACTION_SORT as Kr, ACTION_SEARCH as Jr, ACTION_RESET_PROMPT as lr, ACTION_TOGGLE_PROMPT as dr, DEFAULT_AI_ENGINE as ke, P as Oe, un as Ee, ENGINE_ANTHROPIC as He, ENGINE_OPENAI as zt, PROMPT_CLASSNAME as Yr, PROMPT_EDITABLE_AREA_CLASSNAME as Zr, ROLE_SYSTEM as Xr, ROLE_INTERNAL as pt, ROLE_HIDDEN as Qr, STATS_SEPARATOR as $t, CLIPBOARD_PROMPT as Dt, TYPE_QUESTION as ea, ERROR_MESSAGE as ta, ROLE_USER as et, FOOTER_DISCLAIMER as ra, isLastMessageFromRole as aa, getMessageContaintWrapperClass as na, Logo as oa, getMainPaddingClass as Vt, r as sa, LOCAL_STORAGE_PREFIX as Pt, LOCAL_STORAGE_SEARCH as ia, LOCAL_STORAGE_SORT as ca } from "./index.B1Guvajo.js";
3
3
  import l from "clsx";
4
- import * as et from "react";
5
- import M, { useRef as O, useEffect as A, useCallback as K, useSyncExternalStore as da, useMemo as bt, useState as W, useId as ua, useContext as B, createContext as ma, useLayoutEffect as mr, useDebugValue as ga, forwardRef as gr, lazy as hr, Suspense as tt, useReducer as He } from "react";
6
- import { useFloatingTree as fr, useFloatingNodeId as ha, useListItem as pr, useFloating as fa, offset as pa, flip as ba, shift as ya, autoUpdate as va, useClick as ka, useRole as _a, useDismiss as Ea, useListNavigation as xa, useTypeahead as Sa, useInteractions as wa, useMergeRefs as br, FloatingNode as Ta, FloatingList as Na, FloatingPortal as Ca, FloatingFocusManager as Ra, FloatingTree as Ia } from "@floating-ui/react";
4
+ import * as tt from "react";
5
+ import A, { useRef as M, useState as q, useCallback as ne, useSyncExternalStore as la, useEffect as D, useMemo as ur, useId as da, useContext as z, createContext as ua, useLayoutEffect as ma, useDebugValue as ga, forwardRef as mr, lazy as gr, Suspense as rt, useReducer as We } from "react";
6
+ import { useFloatingTree as hr, useFloatingNodeId as ha, useListItem as fr, useFloating as fa, offset as pa, flip as ba, shift as ya, autoUpdate as va, useClick as ka, useRole as _a, useDismiss as Ea, useListNavigation as xa, useTypeahead as wa, useInteractions as Sa, useMergeRefs as pr, FloatingNode as Ta, FloatingList as Na, FloatingPortal as Ca, FloatingFocusManager as Ra, FloatingTree as Ia } from "@floating-ui/react";
7
7
  const La = ({
8
8
  className: e,
9
9
  viewBox: t,
@@ -11,7 +11,7 @@ const La = ({
11
11
  monotone: a,
12
12
  ...n
13
13
  }) => /* @__PURE__ */ x(
14
- ie,
14
+ me,
15
15
  {
16
16
  defaultViewBox: "0 0 448 512",
17
17
  size: "size-5",
@@ -30,14 +30,14 @@ const La = ({
30
30
  )
31
31
  ]
32
32
  }
33
- ), Ft = ({
33
+ ), Ut = ({
34
34
  className: e,
35
35
  viewBox: t,
36
36
  title: r,
37
37
  monotone: a,
38
38
  ...n
39
39
  }) => /* @__PURE__ */ i(
40
- ie,
40
+ me,
41
41
  {
42
42
  defaultViewBox: "0 0 24 24",
43
43
  size: "size-5",
@@ -54,7 +54,7 @@ const La = ({
54
54
  monotone: a,
55
55
  ...n
56
56
  }) => /* @__PURE__ */ x(
57
- ie,
57
+ me,
58
58
  {
59
59
  defaultViewBox: "0 0 448 512",
60
60
  size: "size-5",
@@ -87,7 +87,7 @@ const La = ({
87
87
  monotone: a,
88
88
  ...n
89
89
  }) => /* @__PURE__ */ i(
90
- ie,
90
+ me,
91
91
  {
92
92
  defaultViewBox: "0 0 384 512",
93
93
  size: "size-5",
@@ -97,31 +97,14 @@ const La = ({
97
97
  ...n,
98
98
  children: /* @__PURE__ */ i("path", { d: "M345 137c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0l-119 119L73 103c-9.4-9.4-24.6-9.4-33.9 0s-9.4 24.6 0 33.9l119 119L39 375c-9.4 9.4-9.4 24.6 0 33.9s24.6 9.4 33.9 0l119-119L311 409c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-119-119L345 137z" })
99
99
  }
100
- ), Ba = ({
101
- className: e,
102
- viewBox: t,
103
- title: r,
104
- monotone: a,
105
- ...n
106
- }) => /* @__PURE__ */ i(
107
- ie,
108
- {
109
- defaultViewBox: "0 0 384 512",
110
- size: "size-5",
111
- viewBox: t,
112
- className: e,
113
- title: r || "Down",
114
- ...n,
115
- children: /* @__PURE__ */ i("path", { d: "M174.6 472.6c4.5 4.7 10.8 7.4 17.4 7.4s12.8-2.7 17.4-7.4l168-176c9.2-9.6 8.8-24.8-.8-33.9s-24.8-8.8-33.9 .8L216 396.1 216 56c0-13.3-10.7-24-24-24s-24 10.7-24 24l0 340.1L41.4 263.4c-9.2-9.6-24.3-9.9-33.9-.8s-9.9 24.3-.8 33.9l168 176z" })
116
- }
117
- ), Ht = ({
100
+ ), Ft = ({
118
101
  className: e,
119
102
  viewBox: t,
120
103
  title: r,
121
104
  monotone: a,
122
105
  ...n
123
106
  }) => /* @__PURE__ */ i(
124
- ie,
107
+ me,
125
108
  {
126
109
  defaultViewBox: "0 0 24 24",
127
110
  size: "size-5",
@@ -131,14 +114,14 @@ const La = ({
131
114
  ...n,
132
115
  children: /* @__PURE__ */ i("path", { d: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364 15.1192 7.2a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.407-.667zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z" })
133
116
  }
134
- ), Ma = ({
117
+ ), Ba = ({
135
118
  className: e,
136
119
  viewBox: t,
137
120
  title: r,
138
121
  monotone: a,
139
122
  ...n
140
123
  }) => /* @__PURE__ */ i(
141
- ie,
124
+ me,
142
125
  {
143
126
  defaultViewBox: "0 0 384 512",
144
127
  size: "size-5",
@@ -162,7 +145,7 @@ try {
162
145
  });
163
146
  } catch {
164
147
  }
165
- const za = "av-header", $a = ({
148
+ const Ma = "av-header", za = ({
166
149
  children: e,
167
150
  className: t,
168
151
  raw: r = !1,
@@ -174,7 +157,7 @@ const za = "av-header", $a = ({
174
157
  noPadding: g = !1
175
158
  }) => {
176
159
  const d = l(
177
- za,
160
+ Ma,
178
161
  {
179
162
  "border-border-accent": a === "dark" && !r && !n && !s,
180
163
  "border-border-medium": a === "light" && !r && !n && !s,
@@ -189,14 +172,14 @@ const za = "av-header", $a = ({
189
172
  "sticky top-0 z-50": o
190
173
  },
191
174
  t
192
- ), h = l({
175
+ ), f = l({
193
176
  "mt-0": !c,
194
177
  "p-2": !g,
195
178
  "flex flex-col w-full md:mx-auto md:max-w-4xl": !r
196
179
  });
197
- return /* @__PURE__ */ i("header", { className: d, children: /* @__PURE__ */ i("div", { className: h, children: e }) });
180
+ return /* @__PURE__ */ i("header", { className: d, children: /* @__PURE__ */ i("div", { className: f, children: e }) });
198
181
  };
199
- function Da(e) {
182
+ function $a(e) {
200
183
  const t = e.toLowerCase().split("+").map((o) => o.trim()), r = {
201
184
  alt: t.includes("alt"),
202
185
  ctrl: t.includes("ctrl"),
@@ -209,102 +192,84 @@ function Da(e) {
209
192
  key: n
210
193
  };
211
194
  }
212
- function Va(e, t) {
213
- const { alt: r, ctrl: a, meta: n, mod: o, shift: s, key: c } = e, { altKey: g, ctrlKey: d, metaKey: h, shiftKey: m, key: u } = t;
195
+ function Da(e, t) {
196
+ const { alt: r, ctrl: a, meta: n, mod: o, shift: s, key: c } = e, { altKey: g, ctrlKey: d, metaKey: f, shiftKey: m, key: u } = t;
214
197
  if (r !== g)
215
198
  return !1;
216
199
  if (o) {
217
- if (!d && !h)
200
+ if (!d && !f)
218
201
  return !1;
219
- } else if (a !== d || n !== h)
202
+ } else if (a !== d || n !== f)
220
203
  return !1;
221
204
  return s !== m ? !1 : !!(c && (u.toLowerCase() === c.toLowerCase() || t.code.replace("Key", "").toLowerCase() === c.toLowerCase()));
222
205
  }
223
- function Pa(e) {
224
- return (t) => Va(Da(e), t);
206
+ function Va(e) {
207
+ return (t) => Da($a(e), t);
225
208
  }
226
- function Ua(e) {
209
+ function Pa(e) {
227
210
  return (t) => {
228
211
  const r = "nativeEvent" in t ? t.nativeEvent : t;
229
212
  e.forEach(([a, n, o = { preventDefault: !0 }]) => {
230
- Pa(a)(r) && (o.preventDefault && t.preventDefault(), n(r));
213
+ Va(a)(r) && (o.preventDefault && t.preventDefault(), n(r));
231
214
  });
232
215
  };
233
216
  }
234
- function Fa() {
235
- const e = O(!1);
236
- return A(() => (e.current = !0, () => {
237
- e.current = !1;
238
- }), []), K(() => e.current, []);
217
+ function Ua() {
218
+ const e = M(null), [t, r] = q(!1);
219
+ return { ref: ne((a) => {
220
+ var n, o;
221
+ typeof IntersectionObserver < "u" && (a && !e.current ? e.current = new IntersectionObserver(
222
+ (s) => r(s.some((c) => c.isIntersecting))
223
+ ) : (n = e.current) == null || n.disconnect(), a ? (o = e.current) == null || o.observe(a) : r(!1));
224
+ }, []), inViewport: t };
239
225
  }
240
- function yr(e, t) {
226
+ function br(e, t) {
241
227
  window.dispatchEvent(new StorageEvent("storage", { key: e, newValue: t }));
242
228
  }
243
- const Wt = (e, t) => {
229
+ const Ht = (e, t) => {
244
230
  const r = JSON.stringify(
245
231
  typeof t == "function" ? t() : t
246
232
  );
247
- window.localStorage.setItem(e, r), yr(e, r);
248
- }, Ha = (e) => {
249
- window.localStorage.removeItem(e), yr(e, null);
250
- }, Gt = (e) => window.localStorage.getItem(e), Wa = (e) => (window.addEventListener("storage", e), () => window.removeEventListener("storage", e));
251
- function jt({
233
+ window.localStorage.setItem(e, r), br(e, r);
234
+ }, Fa = (e) => {
235
+ window.localStorage.removeItem(e), br(e, null);
236
+ }, Wt = (e) => window.localStorage.getItem(e), Ha = (e) => (window.addEventListener("storage", e), () => window.removeEventListener("storage", e));
237
+ function Gt({
252
238
  key: e,
253
239
  initialValue: t
254
240
  }) {
255
- const r = da(Wa, () => Gt(e)), a = K(
241
+ const r = la(Ha, () => Wt(e)), a = ne(
256
242
  (s) => {
257
243
  try {
258
244
  const c = typeof s == "function" ? s(JSON.parse(r)) : s;
259
- c == null ? Ha(e) : Wt(e, c);
245
+ c == null ? Fa(e) : Ht(e, c);
260
246
  } catch (c) {
261
247
  console.warn(c);
262
248
  }
263
249
  },
264
250
  [e, r]
265
- ), n = K(() => {
251
+ ), n = ne(() => {
266
252
  a(t);
267
- }, [t, a]), o = K(() => {
253
+ }, [t, a]), o = ne(() => {
268
254
  a(null);
269
255
  }, [a]);
270
- return A(() => {
256
+ return D(() => {
271
257
  try {
272
- Gt(e) === null && typeof t < "u" && Wt(e, t);
258
+ Wt(e) === null && typeof t < "u" && Ht(e, t);
273
259
  } catch (s) {
274
260
  console.warn(s);
275
261
  }
276
262
  }, [e, t]), [r ? JSON.parse(r) : null, a, n, o];
277
263
  }
278
- function Ga(e) {
279
- return bt(() => e.every((t) => t == null) ? () => {
264
+ function Wa(e) {
265
+ return ur(() => e.every((t) => t == null) ? () => {
280
266
  } : (t) => {
281
267
  e.forEach((r) => {
282
268
  typeof r == "function" ? r(t) : r != null && (r.current = t);
283
269
  });
284
270
  }, e);
285
271
  }
286
- const ja = {
287
- x: 0,
288
- y: 0,
289
- width: 0,
290
- height: 0,
291
- top: 0,
292
- left: 0,
293
- bottom: 0,
294
- right: 0
295
- };
296
- function qa(e) {
297
- const t = Fa(), r = O(0), a = O(null), [n, o] = W(ja), s = bt(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((c) => {
298
- const g = c[0];
299
- g && (cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
300
- a.current && t() && o(g.contentRect);
301
- }));
302
- }), [t]);
303
- return A(() => (a.current && (s == null || s.observe(a.current, e)), () => {
304
- s == null || s.disconnect(), r.current && cancelAnimationFrame(r.current);
305
- }), [s, e]), [a, n];
306
- }
307
- function Ka({
272
+ function Ga({
308
273
  value: e,
309
274
  defaultValue: t,
310
275
  finalValue: r,
@@ -312,19 +277,19 @@ function Ka({
312
277
  },
313
278
  initialControlledDelay: n = 0
314
279
  }) {
315
- const [o, s] = W(!1), [c, g] = W(
280
+ const [o, s] = q(!1), [c, g] = q(
316
281
  t !== void 0 ? t : r
317
- ), d = (h) => {
318
- g(h), a == null || a(h);
282
+ ), d = (f) => {
283
+ g(f), a == null || a(f);
319
284
  };
320
- return A(() => {
285
+ return D(() => {
321
286
  (async () => e !== void 0 && !o && n > 0 && (await new Promise(
322
- (h) => setTimeout(h, n)
287
+ (f) => setTimeout(f, n)
323
288
  ), s(!0)))();
324
289
  }, [e, n, o]), e !== void 0 ? !o && n > 0 ? ["", a, !0] : [e, a, !0] : [c, d, !1];
325
290
  }
326
- function Ja(e) {
327
- return ua();
291
+ function ja(e) {
292
+ return da();
328
293
  }
329
294
  /*!
330
295
  @versini/ui-table v3.0.11
@@ -339,10 +304,10 @@ try {
339
304
  });
340
305
  } catch {
341
306
  }
342
- const Oe = "thead", yt = "tfoot", me = "tbody", be = {
307
+ const Be = "thead", bt = "tfoot", ue = "tbody", be = {
343
308
  ASC: "asc",
344
309
  DESC: "desc"
345
- }, Ya = ({
310
+ }, qa = ({
346
311
  mode: e,
347
312
  className: t,
348
313
  wrapperClassName: r,
@@ -377,7 +342,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
377
342
  "text-copy-light dark:text-copy-dark": e === "system",
378
343
  "text-copy-dark dark:text-copy-light": e === "alt-system"
379
344
  })
380
- }), Za = ({
345
+ }), Ka = ({
381
346
  className: e,
382
347
  stickyHeader: t,
383
348
  mode: r
@@ -390,7 +355,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
390
355
  "shadow-[rgb(65_65_65_/30%)_0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_0.5rem_1rem]": t && r === "alt-system"
391
356
  },
392
357
  e
393
- ), Xa = ({
358
+ ), Ja = ({
394
359
  className: e,
395
360
  stickyFooter: t,
396
361
  mode: r
@@ -403,11 +368,11 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
403
368
  "shadow-[rgb(65_65_65_/30%)_-0_0.5rem_1rem] dark:shadow-[rgb(190_190_190_/20%)_0_-0.5rem_1rem]": t && r === "alt-system"
404
369
  },
405
370
  e
406
- ), Qa = ({
371
+ ), Ya = ({
407
372
  mode: e,
408
373
  className: t,
409
374
  cellWrapper: r
410
- }) => r === Oe || r === yt ? l(
375
+ }) => r === Be || r === bt ? l(
411
376
  {
412
377
  "bg-table-head-dark": e === "dark" || e === "system",
413
378
  "bg-table-head-light": e === "light" || e === "alt-system",
@@ -419,16 +384,16 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
419
384
  "border-b last:border-0",
420
385
  {
421
386
  "border-table-dark": e === "dark" || e === "system",
422
- "odd:bg-table-dark-odd even:bg-table-dark-even": r === me && e === "dark",
387
+ "odd:bg-table-dark-odd even:bg-table-dark-even": r === ue && e === "dark",
423
388
  "border-table-light": e === "light" || e === "alt-system",
424
- "odd:bg-table-light-odd even:bg-table-light-even": r === me && e === "light",
389
+ "odd:bg-table-light-odd even:bg-table-light-even": r === ue && e === "light",
425
390
  "dark:border-table-light": e === "system",
426
- "odd:bg-table-dark-odd even:bg-table-dark-even dark:odd:bg-table-light-odd dark:even:bg-table-light-even": r === me && e === "system",
391
+ "odd:bg-table-dark-odd even:bg-table-dark-even dark:odd:bg-table-light-odd dark:even:bg-table-light-even": r === ue && e === "system",
427
392
  "dark:border-table-dark": e === "alt-system",
428
- "odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": r === me && e === "alt-system"
393
+ "odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": r === ue && e === "alt-system"
429
394
  },
430
395
  t
431
- ), en = ({
396
+ ), Za = ({
432
397
  cellWrapper: e,
433
398
  className: t,
434
399
  compact: r,
@@ -446,15 +411,15 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
446
411
  "text-copy-dark": a === "light" || a === "alt-system",
447
412
  "dark:text-copy-dark": a === "system",
448
413
  "dark:text-copy-light": a === "alt-system",
449
- "px-4 py-3": !r && (e === Oe || e === yt),
450
- "p-4": !r && e === me,
414
+ "px-4 py-3": !r && (e === Be || e === bt),
415
+ "p-4": !r && e === ue,
451
416
  "px-2 py-1.5": r
452
417
  },
453
418
  t
454
419
  )
455
- }), tn = ({
420
+ }), Xa = ({
456
421
  buttonClassName: e
457
- }) => l("rounded-none text-sm", e), qt = "av-button", vt = "icon", vr = "button", rt = "link", rn = ({
422
+ }) => l("rounded-none text-sm", e), jt = "av-button", yt = "icon", yr = "button", at = "link", Qa = ({
458
423
  type: e,
459
424
  size: t,
460
425
  labelRight: r,
@@ -463,14 +428,14 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
463
428
  }) => {
464
429
  const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", c = "max-h-12 py-2 px-4";
465
430
  switch (e) {
466
- case vr:
467
- case rt:
431
+ case yr:
432
+ case at:
468
433
  return l({
469
434
  [o]: t === "small",
470
435
  [s]: t === "medium",
471
436
  [c]: t === "large"
472
437
  });
473
- case vt:
438
+ case yt:
474
439
  return l("inline-flex items-center", {
475
440
  "justify-center": n === "center",
476
441
  "justify-start": n === "left",
@@ -483,7 +448,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
483
448
  "h-12 px-4": t === "large" && (r || a)
484
449
  });
485
450
  }
486
- }, an = ({
451
+ }, en = ({
487
452
  type: e,
488
453
  size: t,
489
454
  labelRight: r,
@@ -491,22 +456,22 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
491
456
  }) => {
492
457
  const n = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
493
458
  switch (e) {
494
- case vr:
495
- case rt:
459
+ case yr:
460
+ case at:
496
461
  return l({
497
- "text-center": e === rt,
462
+ "text-center": e === at,
498
463
  [n]: t === "small",
499
464
  [o]: t === "medium",
500
465
  [s]: t === "large"
501
466
  });
502
- case vt:
467
+ case yt:
503
468
  return l({
504
469
  [n]: t === "small" && (r || a),
505
470
  [o]: t === "medium" && (r || a),
506
471
  [s]: t === "large" && (r || a)
507
472
  });
508
473
  }
509
- }, nn = ({
474
+ }, tn = ({
510
475
  mode: e,
511
476
  noBackground: t,
512
477
  noTruncate: r,
@@ -542,7 +507,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
542
507
  return l("not-prose text-copy-lighter", {
543
508
  truncate: !r
544
509
  });
545
- }, on = ({
510
+ }, rn = ({
546
511
  mode: e,
547
512
  noBackground: t,
548
513
  variant: r
@@ -572,13 +537,13 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
572
537
  if (r === "selected")
573
538
  return "bg-action-selected-dark";
574
539
  }
575
- }, sn = ({
540
+ }, an = ({
576
541
  radius: e
577
542
  }) => l({
578
543
  "rounded-full": e === "large",
579
544
  "rounded-md": e === "medium",
580
545
  "rounded-sm": e === "small"
581
- }), cn = ({
546
+ }), nn = ({
582
547
  mode: e,
583
548
  disabled: t,
584
549
  variant: r
@@ -608,7 +573,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
608
573
  });
609
574
  if (r === "selected")
610
575
  return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
611
- }, ln = ({
576
+ }, on = ({
612
577
  mode: e,
613
578
  disabled: t,
614
579
  variant: r
@@ -638,7 +603,7 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
638
603
  });
639
604
  if (r === "selected")
640
605
  return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
641
- }, dn = ({
606
+ }, sn = ({
642
607
  mode: e,
643
608
  noBorder: t,
644
609
  variant: r
@@ -668,14 +633,14 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
668
633
  });
669
634
  if (r === "selected")
670
635
  return "border border-border-selected-dark";
671
- }, un = ({
636
+ }, cn = ({
672
637
  focusMode: e
673
638
  }) => l("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
674
639
  "focus:outline-focus-dark": e === "dark",
675
640
  "focus:outline-focus-light": e === "light",
676
641
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
677
642
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
678
- }), mn = ({
643
+ }), ln = ({
679
644
  type: e,
680
645
  className: t,
681
646
  raw: r,
@@ -686,56 +651,56 @@ const Oe = "thead", yt = "tfoot", me = "tbody", be = {
686
651
  size: c,
687
652
  noBorder: g,
688
653
  labelRight: d,
689
- labelLeft: h,
654
+ labelLeft: f,
690
655
  noBackground: m,
691
656
  variant: u,
692
- noTruncate: f,
657
+ noTruncate: h,
693
658
  align: p,
694
- radius: b
695
- }) => (u || (u = "primary"), r ? l(qt, t) : l(
696
- qt,
697
- nn({
659
+ radius: y
660
+ }) => (u || (u = "primary"), r ? l(jt, t) : l(
661
+ jt,
662
+ tn({
698
663
  mode: a,
699
664
  variant: u,
700
665
  noBackground: m,
701
- noTruncate: f
666
+ noTruncate: h
702
667
  }),
703
- on({ mode: a, noBackground: m, variant: u }),
704
- sn({ radius: b }),
705
- rn({
668
+ rn({ mode: a, noBackground: m, variant: u }),
669
+ an({ radius: y }),
670
+ Qa({
706
671
  type: e,
707
672
  size: c,
708
673
  labelRight: d,
709
- labelLeft: h,
674
+ labelLeft: f,
710
675
  align: p
711
676
  }),
712
- an({ type: e, size: c, labelRight: d, labelLeft: h }),
713
- dn({ mode: a, variant: u, noBorder: g }),
714
- un({ focusMode: n }),
715
- cn({ mode: a, variant: u, disabled: o }),
716
- ln({ mode: a, variant: u, disabled: o }),
677
+ en({ type: e, size: c, labelRight: d, labelLeft: f }),
678
+ sn({ mode: a, variant: u, noBorder: g }),
679
+ cn({ focusMode: n }),
680
+ nn({ mode: a, variant: u, disabled: o }),
681
+ on({ mode: a, variant: u, disabled: o }),
717
682
  {
718
683
  "w-full": s,
719
684
  "disabled:cursor-not-allowed disabled:opacity-50": o
720
685
  },
721
686
  t
722
- )), gn = (e, t, r) => {
687
+ )), dn = (e, t, r) => {
723
688
  var a;
724
689
  !t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
725
- }, kr = M.forwardRef((e, t) => {
690
+ }, vr = A.forwardRef((e, t) => {
726
691
  const { onClick: r, noInternalClick: a = !1, ...n } = e;
727
692
  return /* @__PURE__ */ i(
728
693
  "button",
729
694
  {
730
695
  ref: t,
731
696
  onClick: (o) => {
732
- gn(o, a, r);
697
+ dn(o, a, r);
733
698
  },
734
699
  ...n
735
700
  }
736
701
  );
737
702
  });
738
- kr.displayName = "BaseButton";
703
+ vr.displayName = "BaseButton";
739
704
  /*!
740
705
  @versini/ui-button v4.0.10
741
706
  © 2025 gizmette.com
@@ -749,7 +714,7 @@ try {
749
714
  });
750
715
  } catch {
751
716
  }
752
- const _r = M.forwardRef(
717
+ const kr = A.forwardRef(
753
718
  ({
754
719
  children: e,
755
720
  disabled: t = !1,
@@ -761,18 +726,18 @@ const _r = M.forwardRef(
761
726
  raw: c = !1,
762
727
  noBorder: g = !1,
763
728
  "aria-label": d,
764
- label: h,
729
+ label: f,
765
730
  size: m = "medium",
766
731
  labelRight: u,
767
- labelLeft: f,
732
+ labelLeft: h,
768
733
  noBackground: p = !1,
769
- align: b = "center",
734
+ align: y = "center",
770
735
  active: v = !1,
771
- radius: y = "large",
736
+ radius: b = "large",
772
737
  ..._
773
- }, S) => {
774
- const N = mn({
775
- type: vt,
738
+ }, w) => {
739
+ const N = ln({
740
+ type: yt,
776
741
  mode: r,
777
742
  focusMode: a,
778
743
  fullWidth: n,
@@ -782,10 +747,10 @@ const _r = M.forwardRef(
782
747
  noBorder: g,
783
748
  size: m,
784
749
  labelRight: u,
785
- labelLeft: f,
750
+ labelLeft: h,
786
751
  noBackground: p,
787
- align: b,
788
- radius: y
752
+ align: y,
753
+ radius: b
789
754
  }), k = l({
790
755
  "text-copy-accent-dark": r === "light" && !c,
791
756
  "text-copy-light": r === "dark" && !c,
@@ -809,16 +774,16 @@ const _r = M.forwardRef(
809
774
  }
810
775
  ) : "";
811
776
  return /* @__PURE__ */ i("div", { className: C, children: /* @__PURE__ */ x(
812
- kr,
777
+ vr,
813
778
  {
814
- ref: S,
779
+ ref: w,
815
780
  className: N,
816
781
  disabled: t,
817
782
  type: s,
818
- "aria-label": d || h,
783
+ "aria-label": d || f,
819
784
  ..._,
820
785
  children: [
821
- f && /* @__PURE__ */ i("span", { className: "pr-2", children: f }),
786
+ h && /* @__PURE__ */ i("span", { className: "pr-2", children: h }),
822
787
  /* @__PURE__ */ i("div", { className: k, children: e }),
823
788
  u && /* @__PURE__ */ i("span", { className: "pl-2", children: u })
824
789
  ]
@@ -826,8 +791,8 @@ const _r = M.forwardRef(
826
791
  ) });
827
792
  }
828
793
  );
829
- _r.displayName = "ButtonSort";
830
- const kt = ({
794
+ kr.displayName = "ButtonSort";
795
+ const vt = ({
831
796
  children: e,
832
797
  fill: t,
833
798
  viewBox: r,
@@ -839,7 +804,7 @@ const kt = ({
839
804
  ...g
840
805
  }) => {
841
806
  const d = l(o, a);
842
- return /* @__PURE__ */ x(ht, { children: [
807
+ return /* @__PURE__ */ x(Ae, { children: [
843
808
  /* @__PURE__ */ i(
844
809
  "svg",
845
810
  {
@@ -870,14 +835,14 @@ try {
870
835
  });
871
836
  } catch {
872
837
  }
873
- const hn = ({
838
+ const un = ({
874
839
  className: e,
875
840
  viewBox: t,
876
841
  title: r,
877
842
  monotone: a,
878
843
  ...n
879
844
  }) => /* @__PURE__ */ x(
880
- kt,
845
+ vt,
881
846
  {
882
847
  defaultViewBox: "0 0 576 512",
883
848
  size: "size-5",
@@ -903,14 +868,14 @@ const hn = ({
903
868
  )
904
869
  ]
905
870
  }
906
- ), fn = ({
871
+ ), mn = ({
907
872
  className: e,
908
873
  viewBox: t,
909
874
  title: r,
910
875
  monotone: a,
911
876
  ...n
912
877
  }) => /* @__PURE__ */ x(
913
- kt,
878
+ vt,
914
879
  {
915
880
  defaultViewBox: "0 0 576 512",
916
881
  size: "size-5",
@@ -936,14 +901,14 @@ const hn = ({
936
901
  )
937
902
  ]
938
903
  }
939
- ), pn = ({
904
+ ), gn = ({
940
905
  className: e,
941
906
  viewBox: t,
942
907
  title: r,
943
908
  monotone: a,
944
909
  ...n
945
910
  }) => /* @__PURE__ */ x(
946
- kt,
911
+ vt,
947
912
  {
948
913
  defaultViewBox: "0 0 576 512",
949
914
  size: "size-5",
@@ -983,13 +948,13 @@ try {
983
948
  });
984
949
  } catch {
985
950
  }
986
- const ge = M.createContext({
951
+ const ge = A.createContext({
987
952
  mode: "light",
988
953
  cellWrapper: "thead",
989
954
  stickyHeader: !1,
990
955
  stickyFooter: !1,
991
956
  compact: !1
992
- }), fs = ({
957
+ }), gs = ({
993
958
  children: e,
994
959
  mode: t = "system",
995
960
  caption: r,
@@ -1000,9 +965,9 @@ const ge = M.createContext({
1000
965
  maxHeight: c,
1001
966
  stickyHeader: g,
1002
967
  stickyFooter: d,
1003
- ...h
968
+ ...f
1004
969
  }) => {
1005
- const m = Ya({
970
+ const m = qa({
1006
971
  mode: t,
1007
972
  className: o,
1008
973
  wrapperClassName: s,
@@ -1020,7 +985,7 @@ const ge = M.createContext({
1020
985
  ...c && {
1021
986
  style: { maxHeight: c }
1022
987
  },
1023
- children: /* @__PURE__ */ x("table", { className: m.table, summary: n, ...h, children: [
988
+ children: /* @__PURE__ */ x("table", { className: m.table, summary: n, ...f, children: [
1024
989
  r && /* @__PURE__ */ i("caption", { className: m.caption, children: r }),
1025
990
  e
1026
991
  ] })
@@ -1028,54 +993,54 @@ const ge = M.createContext({
1028
993
  )
1029
994
  }
1030
995
  );
1031
- }, ps = ({
996
+ }, hs = ({
1032
997
  children: e,
1033
998
  className: t,
1034
999
  ...r
1035
1000
  }) => {
1036
- const a = B(ge);
1037
- a.cellWrapper = Oe;
1038
- const n = Za({
1001
+ const a = z(ge);
1002
+ a.cellWrapper = Be;
1003
+ const n = Ka({
1039
1004
  className: t,
1040
1005
  mode: a.mode,
1041
1006
  stickyHeader: a.stickyHeader
1042
1007
  });
1043
1008
  return /* @__PURE__ */ i("thead", { className: n, ...r, children: e });
1044
- }, bs = ({
1009
+ }, fs = ({
1045
1010
  children: e,
1046
1011
  className: t,
1047
1012
  ...r
1048
1013
  }) => {
1049
- const a = B(ge);
1050
- a.cellWrapper = yt;
1051
- const n = Xa({
1014
+ const a = z(ge);
1015
+ a.cellWrapper = bt;
1016
+ const n = Ja({
1052
1017
  className: t,
1053
1018
  mode: a.mode,
1054
1019
  stickyFooter: a.stickyFooter
1055
1020
  });
1056
1021
  return /* @__PURE__ */ i("tfoot", { className: n, ...r, children: e });
1057
- }, ys = ({ children: e, ...t }) => {
1058
- const r = B(ge);
1059
- return r.cellWrapper = me, /* @__PURE__ */ i("tbody", { ...t, children: e });
1060
- }, vs = ({
1022
+ }, ps = ({ children: e, ...t }) => {
1023
+ const r = z(ge);
1024
+ return r.cellWrapper = ue, /* @__PURE__ */ i("tbody", { ...t, children: e });
1025
+ }, bs = ({
1061
1026
  children: e,
1062
1027
  className: t,
1063
1028
  ...r
1064
1029
  }) => {
1065
- const a = B(ge), n = Qa({
1030
+ const a = z(ge), n = Ya({
1066
1031
  mode: a.mode,
1067
1032
  cellWrapper: a.cellWrapper,
1068
1033
  className: t
1069
1034
  });
1070
1035
  return /* @__PURE__ */ i("tr", { className: n, ...r, children: e });
1071
- }, bn = ({
1036
+ }, hn = ({
1072
1037
  children: e,
1073
1038
  component: t,
1074
1039
  className: r,
1075
1040
  align: a,
1076
1041
  ...n
1077
1042
  }) => {
1078
- const o = B(ge), s = t || (o.cellWrapper === Oe ? "th" : "td"), { mainClasses: c, alignClasses: g } = en({
1043
+ const o = z(ge), s = t || (o.cellWrapper === Be ? "th" : "td"), { mainClasses: c, alignClasses: g } = Za({
1079
1044
  cellWrapper: o.cellWrapper,
1080
1045
  className: r,
1081
1046
  mode: o.mode,
@@ -1083,7 +1048,7 @@ const ge = M.createContext({
1083
1048
  align: a
1084
1049
  });
1085
1050
  return a ? /* @__PURE__ */ i(s, { className: c, ...n, children: /* @__PURE__ */ i("div", { className: g, children: e }) }) : /* @__PURE__ */ i(s, { className: c, ...n, children: e });
1086
- }, ks = ({
1051
+ }, ys = ({
1087
1052
  align: e,
1088
1053
  children: t,
1089
1054
  buttonClassName: r,
@@ -1094,22 +1059,22 @@ const ge = M.createContext({
1094
1059
  onClick: c,
1095
1060
  sortDirection: g,
1096
1061
  sortedCell: d,
1097
- cellId: h,
1062
+ cellId: f,
1098
1063
  ...m
1099
1064
  }) => {
1100
- const u = tn({ buttonClassName: r });
1065
+ const u = Xa({ buttonClassName: r });
1101
1066
  return /* @__PURE__ */ i(
1102
- bn,
1067
+ hn,
1103
1068
  {
1104
1069
  component: n,
1105
1070
  className: a,
1106
1071
  role: "columnheader",
1107
- "aria-sort": g === be.ASC && d === h ? "ascending" : g === be.DESC && d === h ? "descending" : "other",
1072
+ "aria-sort": g === be.ASC && d === f ? "ascending" : g === be.DESC && d === f ? "descending" : "other",
1108
1073
  ...m,
1109
1074
  children: /* @__PURE__ */ i(
1110
- _r,
1075
+ kr,
1111
1076
  {
1112
- active: d === h,
1077
+ active: d === f,
1113
1078
  className: u,
1114
1079
  onClick: c,
1115
1080
  align: e,
@@ -1118,40 +1083,40 @@ const ge = M.createContext({
1118
1083
  mode: s,
1119
1084
  fullWidth: !0,
1120
1085
  labelRight: t,
1121
- children: g === be.ASC && d === h ? /* @__PURE__ */ i(pn, { className: "size-4", monotone: !0 }) : g === be.DESC && d === h ? /* @__PURE__ */ i(fn, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ i(hn, { className: "size-4", monotone: !0 })
1086
+ children: g === be.ASC && d === f ? /* @__PURE__ */ i(gn, { className: "size-4", monotone: !0 }) : g === be.DESC && d === f ? /* @__PURE__ */ i(mn, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ i(un, { className: "size-4", monotone: !0 })
1122
1087
  }
1123
1088
  )
1124
1089
  }
1125
1090
  );
1126
- }, $ = [];
1091
+ }, B = [];
1127
1092
  for (let e = 0; e < 256; ++e)
1128
- $.push((e + 256).toString(16).slice(1));
1129
- function yn(e, t = 0) {
1130
- return ($[e[t + 0]] + $[e[t + 1]] + $[e[t + 2]] + $[e[t + 3]] + "-" + $[e[t + 4]] + $[e[t + 5]] + "-" + $[e[t + 6]] + $[e[t + 7]] + "-" + $[e[t + 8]] + $[e[t + 9]] + "-" + $[e[t + 10]] + $[e[t + 11]] + $[e[t + 12]] + $[e[t + 13]] + $[e[t + 14]] + $[e[t + 15]]).toLowerCase();
1093
+ B.push((e + 256).toString(16).slice(1));
1094
+ function fn(e, t = 0) {
1095
+ return (B[e[t + 0]] + B[e[t + 1]] + B[e[t + 2]] + B[e[t + 3]] + "-" + B[e[t + 4]] + B[e[t + 5]] + "-" + B[e[t + 6]] + B[e[t + 7]] + "-" + B[e[t + 8]] + B[e[t + 9]] + "-" + B[e[t + 10]] + B[e[t + 11]] + B[e[t + 12]] + B[e[t + 13]] + B[e[t + 14]] + B[e[t + 15]]).toLowerCase();
1131
1096
  }
1132
- let We;
1133
- const vn = new Uint8Array(16);
1134
- function kn() {
1135
- if (!We) {
1097
+ let Ge;
1098
+ const pn = new Uint8Array(16);
1099
+ function bn() {
1100
+ if (!Ge) {
1136
1101
  if (typeof crypto > "u" || !crypto.getRandomValues)
1137
1102
  throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
1138
- We = crypto.getRandomValues.bind(crypto);
1103
+ Ge = crypto.getRandomValues.bind(crypto);
1139
1104
  }
1140
- return We(vn);
1105
+ return Ge(pn);
1141
1106
  }
1142
- const _n = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), Kt = { randomUUID: _n };
1143
- function _t(e, t, r) {
1107
+ const yn = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), qt = { randomUUID: yn };
1108
+ function kt(e, t, r) {
1144
1109
  var n;
1145
- if (Kt.randomUUID && !t && !e)
1146
- return Kt.randomUUID();
1110
+ if (qt.randomUUID && !t && !e)
1111
+ return qt.randomUUID();
1147
1112
  e = e || {};
1148
- const a = e.random ?? ((n = e.rng) == null ? void 0 : n.call(e)) ?? kn();
1113
+ const a = e.random ?? ((n = e.rng) == null ? void 0 : n.call(e)) ?? bn();
1149
1114
  if (a.length < 16)
1150
1115
  throw new Error("Random bytes length must be >= 16");
1151
- return a[6] = a[6] & 15 | 64, a[8] = a[8] & 63 | 128, yn(a);
1116
+ return a[6] = a[6] & 15 | 64, a[8] = a[8] & 63 | 128, fn(a);
1152
1117
  }
1153
- const En = (e, t) => {
1154
- if ((t == null ? void 0 : t.type) === Kr) {
1118
+ const vn = (e, t) => {
1119
+ if ((t == null ? void 0 : t.type) === qr) {
1155
1120
  const r = t.payload.messages.map((a) => ({
1156
1121
  message: {
1157
1122
  role: a.role,
@@ -1185,14 +1150,14 @@ const En = (e, t) => {
1185
1150
  (d) => d.message.messageId === s
1186
1151
  );
1187
1152
  if (g !== -1) {
1188
- const d = e.messages.map((h, m) => m === g ? {
1153
+ const d = e.messages.map((f, m) => m === g ? {
1189
1154
  message: {
1190
- ...h.message,
1191
- content: `${h.message.content}${a}`,
1155
+ ...f.message,
1156
+ content: `${f.message.content}${a}`,
1192
1157
  processingTime: o,
1193
1158
  name: n
1194
1159
  }
1195
- } : h);
1160
+ } : f);
1196
1161
  return {
1197
1162
  id: e.id,
1198
1163
  model: e.model,
@@ -1221,14 +1186,14 @@ const En = (e, t) => {
1221
1186
  }
1222
1187
  }
1223
1188
  return (t == null ? void 0 : t.type) === ft ? {
1224
- id: _t(),
1189
+ id: kt(),
1225
1190
  model: e.model,
1226
1191
  engine: e.engine,
1227
1192
  usage: 0,
1228
1193
  messages: [],
1229
1194
  isComponent: e.isComponent,
1230
1195
  prompts: e.prompts
1231
- } : (t == null ? void 0 : t.type) === cr ? {
1196
+ } : (t == null ? void 0 : t.type) === ir ? {
1232
1197
  id: e.id,
1233
1198
  model: t.payload.model,
1234
1199
  engine: e.engine,
@@ -1236,19 +1201,19 @@ const En = (e, t) => {
1236
1201
  usage: t.payload.usage,
1237
1202
  messages: e.messages,
1238
1203
  isComponent: e.isComponent
1239
- } : (t == null ? void 0 : t.type) === lr ? {
1204
+ } : (t == null ? void 0 : t.type) === cr ? {
1240
1205
  ...e,
1241
1206
  streaming: t.payload.streaming
1242
1207
  } : e;
1243
- }, xn = (e, t) => {
1208
+ }, kn = (e, t) => {
1244
1209
  switch (t == null ? void 0 : t.type) {
1245
- case Yr:
1210
+ case Jr:
1246
1211
  return {
1247
1212
  searchString: t.payload.searchString,
1248
1213
  sortedCell: e.sortedCell,
1249
1214
  sortDirection: e.sortDirection
1250
1215
  };
1251
- case Jr:
1216
+ case Kr:
1252
1217
  return {
1253
1218
  searchString: e.searchString,
1254
1219
  sortedCell: t.payload.sortedCell,
@@ -1257,14 +1222,14 @@ const En = (e, t) => {
1257
1222
  default:
1258
1223
  return e;
1259
1224
  }
1260
- }, Sn = (e, t) => {
1225
+ }, _n = (e, t) => {
1261
1226
  switch (t == null ? void 0 : t.type) {
1262
- case ur:
1227
+ case dr:
1263
1228
  return {
1264
1229
  prompt: t.payload.prompt,
1265
1230
  lastTriggeredTimestamp: e.lastTriggeredTimestamp
1266
1231
  };
1267
- case dr:
1232
+ case lr:
1268
1233
  return {
1269
1234
  prompt: "",
1270
1235
  lastTriggeredTimestamp: (/* @__PURE__ */ new Date()).getTime()
@@ -1273,7 +1238,7 @@ const En = (e, t) => {
1273
1238
  return e;
1274
1239
  }
1275
1240
  };
1276
- var Ce = { exports: {} }, Ge = {};
1241
+ var Ne = { exports: {} }, je = {};
1277
1242
  /**
1278
1243
  * @license React
1279
1244
  * use-sync-external-store-shim.production.js
@@ -1283,37 +1248,37 @@ var Ce = { exports: {} }, Ge = {};
1283
1248
  * This source code is licensed under the MIT license found in the
1284
1249
  * LICENSE file in the root directory of this source tree.
1285
1250
  */
1286
- var Jt;
1287
- function wn() {
1288
- if (Jt) return Ge;
1289
- Jt = 1;
1290
- var e = M;
1251
+ var Kt;
1252
+ function En() {
1253
+ if (Kt) return je;
1254
+ Kt = 1;
1255
+ var e = A;
1291
1256
  function t(m, u) {
1292
1257
  return m === u && (m !== 0 || 1 / m === 1 / u) || m !== m && u !== u;
1293
1258
  }
1294
1259
  var r = typeof Object.is == "function" ? Object.is : t, a = e.useState, n = e.useEffect, o = e.useLayoutEffect, s = e.useDebugValue;
1295
1260
  function c(m, u) {
1296
- var f = u(), p = a({ inst: { value: f, getSnapshot: u } }), b = p[0].inst, v = p[1];
1261
+ var h = u(), p = a({ inst: { value: h, getSnapshot: u } }), y = p[0].inst, v = p[1];
1297
1262
  return o(
1298
1263
  function() {
1299
- b.value = f, b.getSnapshot = u, g(b) && v({ inst: b });
1264
+ y.value = h, y.getSnapshot = u, g(y) && v({ inst: y });
1300
1265
  },
1301
- [m, f, u]
1266
+ [m, h, u]
1302
1267
  ), n(
1303
1268
  function() {
1304
- return g(b) && v({ inst: b }), m(function() {
1305
- g(b) && v({ inst: b });
1269
+ return g(y) && v({ inst: y }), m(function() {
1270
+ g(y) && v({ inst: y });
1306
1271
  });
1307
1272
  },
1308
1273
  [m]
1309
- ), s(f), f;
1274
+ ), s(h), h;
1310
1275
  }
1311
1276
  function g(m) {
1312
1277
  var u = m.getSnapshot;
1313
1278
  m = m.value;
1314
1279
  try {
1315
- var f = u();
1316
- return !r(m, f);
1280
+ var h = u();
1281
+ return !r(m, h);
1317
1282
  } catch {
1318
1283
  return !0;
1319
1284
  }
@@ -1321,10 +1286,10 @@ function wn() {
1321
1286
  function d(m, u) {
1322
1287
  return u();
1323
1288
  }
1324
- var h = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? d : c;
1325
- return Ge.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : h, Ge;
1289
+ var f = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? d : c;
1290
+ return je.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : f, je;
1326
1291
  }
1327
- var je = {};
1292
+ var qe = {};
1328
1293
  /**
1329
1294
  * @license React
1330
1295
  * use-sync-external-store-shim.development.js
@@ -1334,65 +1299,65 @@ var je = {};
1334
1299
  * This source code is licensed under the MIT license found in the
1335
1300
  * LICENSE file in the root directory of this source tree.
1336
1301
  */
1337
- var Yt;
1338
- function Tn() {
1339
- return Yt || (Yt = 1, process.env.NODE_ENV !== "production" && function() {
1340
- function e(f, p) {
1341
- return f === p && (f !== 0 || 1 / f === 1 / p) || f !== f && p !== p;
1302
+ var Jt;
1303
+ function xn() {
1304
+ return Jt || (Jt = 1, process.env.NODE_ENV !== "production" && function() {
1305
+ function e(h, p) {
1306
+ return h === p && (h !== 0 || 1 / h === 1 / p) || h !== h && p !== p;
1342
1307
  }
1343
- function t(f, p) {
1344
- h || n.startTransition === void 0 || (h = !0, console.error(
1308
+ function t(h, p) {
1309
+ f || n.startTransition === void 0 || (f = !0, console.error(
1345
1310
  "You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
1346
1311
  ));
1347
- var b = p();
1312
+ var y = p();
1348
1313
  if (!m) {
1349
1314
  var v = p();
1350
- o(b, v) || (console.error(
1315
+ o(y, v) || (console.error(
1351
1316
  "The result of getSnapshot should be cached to avoid an infinite loop"
1352
1317
  ), m = !0);
1353
1318
  }
1354
1319
  v = s({
1355
- inst: { value: b, getSnapshot: p }
1320
+ inst: { value: y, getSnapshot: p }
1356
1321
  });
1357
- var y = v[0].inst, _ = v[1];
1322
+ var b = v[0].inst, _ = v[1];
1358
1323
  return g(
1359
1324
  function() {
1360
- y.value = b, y.getSnapshot = p, r(y) && _({ inst: y });
1325
+ b.value = y, b.getSnapshot = p, r(b) && _({ inst: b });
1361
1326
  },
1362
- [f, b, p]
1327
+ [h, y, p]
1363
1328
  ), c(
1364
1329
  function() {
1365
- return r(y) && _({ inst: y }), f(function() {
1366
- r(y) && _({ inst: y });
1330
+ return r(b) && _({ inst: b }), h(function() {
1331
+ r(b) && _({ inst: b });
1367
1332
  });
1368
1333
  },
1369
- [f]
1370
- ), d(b), b;
1334
+ [h]
1335
+ ), d(y), y;
1371
1336
  }
1372
- function r(f) {
1373
- var p = f.getSnapshot;
1374
- f = f.value;
1337
+ function r(h) {
1338
+ var p = h.getSnapshot;
1339
+ h = h.value;
1375
1340
  try {
1376
- var b = p();
1377
- return !o(f, b);
1341
+ var y = p();
1342
+ return !o(h, y);
1378
1343
  } catch {
1379
1344
  return !0;
1380
1345
  }
1381
1346
  }
1382
- function a(f, p) {
1347
+ function a(h, p) {
1383
1348
  return p();
1384
1349
  }
1385
1350
  typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
1386
- var n = M, o = typeof Object.is == "function" ? Object.is : e, s = n.useState, c = n.useEffect, g = n.useLayoutEffect, d = n.useDebugValue, h = !1, m = !1, u = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? a : t;
1387
- je.useSyncExternalStore = n.useSyncExternalStore !== void 0 ? n.useSyncExternalStore : u, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
1388
- }()), je;
1351
+ var n = A, o = typeof Object.is == "function" ? Object.is : e, s = n.useState, c = n.useEffect, g = n.useLayoutEffect, d = n.useDebugValue, f = !1, m = !1, u = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? a : t;
1352
+ qe.useSyncExternalStore = n.useSyncExternalStore !== void 0 ? n.useSyncExternalStore : u, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
1353
+ }()), qe;
1389
1354
  }
1390
- var Zt;
1391
- function Nn() {
1392
- return Zt || (Zt = 1, process.env.NODE_ENV === "production" ? Ce.exports = /* @__PURE__ */ wn() : Ce.exports = /* @__PURE__ */ Tn()), Ce.exports;
1355
+ var Yt;
1356
+ function wn() {
1357
+ return Yt || (Yt = 1, process.env.NODE_ENV === "production" ? Ne.exports = /* @__PURE__ */ En() : Ne.exports = /* @__PURE__ */ xn()), Ne.exports;
1393
1358
  }
1394
- var Cn = /* @__PURE__ */ Nn(), Xt = Object.prototype.hasOwnProperty;
1395
- function at(e, t) {
1359
+ var Sn = /* @__PURE__ */ wn(), Zt = Object.prototype.hasOwnProperty;
1360
+ function nt(e, t) {
1396
1361
  var r, a;
1397
1362
  if (e === t) return !0;
1398
1363
  if (e && t && (r = e.constructor) === t.constructor) {
@@ -1400,119 +1365,119 @@ function at(e, t) {
1400
1365
  if (r === RegExp) return e.toString() === t.toString();
1401
1366
  if (r === Array) {
1402
1367
  if ((a = e.length) === t.length)
1403
- for (; a-- && at(e[a], t[a]); ) ;
1368
+ for (; a-- && nt(e[a], t[a]); ) ;
1404
1369
  return a === -1;
1405
1370
  }
1406
1371
  if (!r || typeof e == "object") {
1407
1372
  a = 0;
1408
1373
  for (r in e)
1409
- if (Xt.call(e, r) && ++a && !Xt.call(t, r) || !(r in t) || !at(e[r], t[r])) return !1;
1374
+ if (Zt.call(e, r) && ++a && !Zt.call(t, r) || !(r in t) || !nt(e[r], t[r])) return !1;
1410
1375
  return Object.keys(t).length === a;
1411
1376
  }
1412
1377
  }
1413
1378
  return e !== e && t !== t;
1414
1379
  }
1415
- const j = /* @__PURE__ */ new WeakMap(), oe = () => {
1380
+ const G = /* @__PURE__ */ new WeakMap(), ae = () => {
1416
1381
  }, P = (
1417
1382
  /*#__NOINLINE__*/
1418
- oe()
1419
- ), nt = Object, E = (e) => e === P, q = (e) => typeof e == "function", se = (e, t) => ({
1383
+ ae()
1384
+ ), ot = Object, E = (e) => e === P, j = (e) => typeof e == "function", oe = (e, t) => ({
1420
1385
  ...e,
1421
1386
  ...t
1422
- }), Er = (e) => q(e.then), qe = {}, Re = {}, Et = "undefined", Be = typeof window != Et, ot = typeof document != Et, Rn = () => Be && typeof window.requestAnimationFrame != Et, xr = (e, t) => {
1423
- const r = j.get(e);
1387
+ }), _r = (e) => j(e.then), Ke = {}, Ce = {}, _t = "undefined", Me = typeof window != _t, st = typeof document != _t, Tn = () => Me && typeof window.requestAnimationFrame != _t, Er = (e, t) => {
1388
+ const r = G.get(e);
1424
1389
  return [
1425
1390
  // Getter
1426
- () => !E(t) && e.get(t) || qe,
1391
+ () => !E(t) && e.get(t) || Ke,
1427
1392
  // Setter
1428
1393
  (a) => {
1429
1394
  if (!E(t)) {
1430
1395
  const n = e.get(t);
1431
- t in Re || (Re[t] = n), r[5](t, se(n, a), n || qe);
1396
+ t in Ce || (Ce[t] = n), r[5](t, oe(n, a), n || Ke);
1432
1397
  }
1433
1398
  },
1434
1399
  // Subscriber
1435
1400
  r[6],
1436
1401
  // Get server cache snapshot
1437
- () => !E(t) && t in Re ? Re[t] : !E(t) && e.get(t) || qe
1402
+ () => !E(t) && t in Ce ? Ce[t] : !E(t) && e.get(t) || Ke
1438
1403
  ];
1439
1404
  };
1440
- let st = !0;
1441
- const In = () => st, [it, ct] = Be && window.addEventListener ? [
1405
+ let it = !0;
1406
+ const Nn = () => it, [ct, lt] = Me && window.addEventListener ? [
1442
1407
  window.addEventListener.bind(window),
1443
1408
  window.removeEventListener.bind(window)
1444
1409
  ] : [
1445
- oe,
1446
- oe
1447
- ], Ln = () => {
1448
- const e = ot && document.visibilityState;
1410
+ ae,
1411
+ ae
1412
+ ], Cn = () => {
1413
+ const e = st && document.visibilityState;
1449
1414
  return E(e) || e !== "hidden";
1450
- }, An = (e) => (ot && document.addEventListener("visibilitychange", e), it("focus", e), () => {
1451
- ot && document.removeEventListener("visibilitychange", e), ct("focus", e);
1452
- }), On = (e) => {
1415
+ }, Rn = (e) => (st && document.addEventListener("visibilitychange", e), ct("focus", e), () => {
1416
+ st && document.removeEventListener("visibilitychange", e), lt("focus", e);
1417
+ }), In = (e) => {
1453
1418
  const t = () => {
1454
- st = !0, e();
1419
+ it = !0, e();
1455
1420
  }, r = () => {
1456
- st = !1;
1421
+ it = !1;
1457
1422
  };
1458
- return it("online", t), it("offline", r), () => {
1459
- ct("online", t), ct("offline", r);
1423
+ return ct("online", t), ct("offline", r), () => {
1424
+ lt("online", t), lt("offline", r);
1460
1425
  };
1461
- }, Bn = {
1462
- isOnline: In,
1463
- isVisible: Ln
1464
- }, Mn = {
1465
- initFocus: An,
1466
- initReconnect: On
1467
- }, Qt = !M.useId, _e = !Be || "Deno" in globalThis, zn = (e) => Rn() ? window.requestAnimationFrame(e) : setTimeout(e, 1), Ke = _e ? A : mr, Je = typeof navigator < "u" && navigator.connection, er = !_e && Je && ([
1426
+ }, Ln = {
1427
+ isOnline: Nn,
1428
+ isVisible: Cn
1429
+ }, An = {
1430
+ initFocus: Rn,
1431
+ initReconnect: In
1432
+ }, Xt = !A.useId, _e = !Me || "Deno" in globalThis, On = (e) => Tn() ? window.requestAnimationFrame(e) : setTimeout(e, 1), Je = _e ? D : ma, Ye = typeof navigator < "u" && navigator.connection, Qt = !_e && Ye && ([
1468
1433
  "slow-2g",
1469
1434
  "2g"
1470
- ].includes(Je.effectiveType) || Je.saveData), Ie = /* @__PURE__ */ new WeakMap(), Ye = (e, t) => nt.prototype.toString.call(e) === `[object ${t}]`;
1471
- let $n = 0;
1472
- const lt = (e) => {
1473
- const t = typeof e, r = Ye(e, "Date"), a = Ye(e, "RegExp"), n = Ye(e, "Object");
1435
+ ].includes(Ye.effectiveType) || Ye.saveData), Re = /* @__PURE__ */ new WeakMap(), Ze = (e, t) => ot.prototype.toString.call(e) === `[object ${t}]`;
1436
+ let Bn = 0;
1437
+ const dt = (e) => {
1438
+ const t = typeof e, r = Ze(e, "Date"), a = Ze(e, "RegExp"), n = Ze(e, "Object");
1474
1439
  let o, s;
1475
- if (nt(e) === e && !r && !a) {
1476
- if (o = Ie.get(e), o) return o;
1477
- if (o = ++$n + "~", Ie.set(e, o), Array.isArray(e)) {
1440
+ if (ot(e) === e && !r && !a) {
1441
+ if (o = Re.get(e), o) return o;
1442
+ if (o = ++Bn + "~", Re.set(e, o), Array.isArray(e)) {
1478
1443
  for (o = "@", s = 0; s < e.length; s++)
1479
- o += lt(e[s]) + ",";
1480
- Ie.set(e, o);
1444
+ o += dt(e[s]) + ",";
1445
+ Re.set(e, o);
1481
1446
  }
1482
1447
  if (n) {
1483
1448
  o = "#";
1484
- const c = nt.keys(e).sort();
1449
+ const c = ot.keys(e).sort();
1485
1450
  for (; !E(s = c.pop()); )
1486
- E(e[s]) || (o += s + ":" + lt(e[s]) + ",");
1487
- Ie.set(e, o);
1451
+ E(e[s]) || (o += s + ":" + dt(e[s]) + ",");
1452
+ Re.set(e, o);
1488
1453
  }
1489
1454
  } else
1490
1455
  o = r ? e.toJSON() : t == "symbol" ? e.toString() : t == "string" ? JSON.stringify(e) : "" + e;
1491
1456
  return o;
1492
- }, Me = (e) => {
1493
- if (q(e))
1457
+ }, ze = (e) => {
1458
+ if (j(e))
1494
1459
  try {
1495
1460
  e = e();
1496
1461
  } catch {
1497
1462
  e = "";
1498
1463
  }
1499
1464
  const t = e;
1500
- return e = typeof e == "string" ? e : (Array.isArray(e) ? e.length : e) ? lt(e) : "", [
1465
+ return e = typeof e == "string" ? e : (Array.isArray(e) ? e.length : e) ? dt(e) : "", [
1501
1466
  e,
1502
1467
  t
1503
1468
  ];
1504
1469
  };
1505
- let Dn = 0;
1506
- const dt = () => ++Dn, Sr = 0, wr = 1, Tr = 2, Vn = 3;
1470
+ let Mn = 0;
1471
+ const ut = () => ++Mn, xr = 0, wr = 1, Sr = 2, zn = 3;
1507
1472
  var pe = {
1508
1473
  __proto__: null,
1509
- ERROR_REVALIDATE_EVENT: Vn,
1510
- FOCUS_EVENT: Sr,
1511
- MUTATE_EVENT: Tr,
1474
+ ERROR_REVALIDATE_EVENT: zn,
1475
+ FOCUS_EVENT: xr,
1476
+ MUTATE_EVENT: Sr,
1512
1477
  RECONNECT_EVENT: wr
1513
1478
  };
1514
- async function Nr(...e) {
1515
- const [t, r, a, n] = e, o = se({
1479
+ async function Tr(...e) {
1480
+ const [t, r, a, n] = e, o = oe({
1516
1481
  populateCache: !0,
1517
1482
  throwOnError: !0
1518
1483
  }, typeof n == "boolean" ? {
@@ -1521,93 +1486,93 @@ async function Nr(...e) {
1521
1486
  let s = o.populateCache;
1522
1487
  const c = o.rollbackOnError;
1523
1488
  let g = o.optimisticData;
1524
- const d = (u) => typeof c == "function" ? c(u) : c !== !1, h = o.throwOnError;
1525
- if (q(r)) {
1526
- const u = r, f = [], p = t.keys();
1527
- for (const b of p)
1489
+ const d = (u) => typeof c == "function" ? c(u) : c !== !1, f = o.throwOnError;
1490
+ if (j(r)) {
1491
+ const u = r, h = [], p = t.keys();
1492
+ for (const y of p)
1528
1493
  // Skip the special useSWRInfinite and useSWRSubscription keys.
1529
- !/^\$(inf|sub)\$/.test(b) && u(t.get(b)._k) && f.push(b);
1530
- return Promise.all(f.map(m));
1494
+ !/^\$(inf|sub)\$/.test(y) && u(t.get(y)._k) && h.push(y);
1495
+ return Promise.all(h.map(m));
1531
1496
  }
1532
1497
  return m(r);
1533
1498
  async function m(u) {
1534
- const [f] = Me(u);
1535
- if (!f) return;
1536
- const [p, b] = xr(t, f), [v, y, _, S] = j.get(t), N = () => {
1537
- const U = v[f];
1538
- return (q(o.revalidate) ? o.revalidate(p().data, u) : o.revalidate !== !1) && (delete _[f], delete S[f], U && U[0]) ? U[0](Tr).then(() => p().data) : p().data;
1499
+ const [h] = ze(u);
1500
+ if (!h) return;
1501
+ const [p, y] = Er(t, h), [v, b, _, w] = G.get(t), N = () => {
1502
+ const U = v[h];
1503
+ return (j(o.revalidate) ? o.revalidate(p().data, u) : o.revalidate !== !1) && (delete _[h], delete w[h], U && U[0]) ? U[0](Sr).then(() => p().data) : p().data;
1539
1504
  };
1540
1505
  if (e.length < 3)
1541
1506
  return N();
1542
1507
  let k = a, C;
1543
- const I = dt();
1544
- y[f] = [
1508
+ const I = ut();
1509
+ b[h] = [
1545
1510
  I,
1546
1511
  0
1547
1512
  ];
1548
- const R = !E(g), Q = p(), F = Q.data, ee = Q._c, J = E(ee) ? F : ee;
1549
- if (R && (g = q(g) ? g(J, F) : g, b({
1513
+ const R = !E(g), Z = p(), F = Z.data, X = Z._c, K = E(X) ? F : X;
1514
+ if (R && (g = j(g) ? g(K, F) : g, y({
1550
1515
  data: g,
1551
- _c: J
1552
- })), q(k))
1516
+ _c: K
1517
+ })), j(k))
1553
1518
  try {
1554
- k = k(J);
1519
+ k = k(K);
1555
1520
  } catch (U) {
1556
1521
  C = U;
1557
1522
  }
1558
- if (k && Er(k))
1523
+ if (k && _r(k))
1559
1524
  if (k = await k.catch((U) => {
1560
1525
  C = U;
1561
- }), I !== y[f][0]) {
1526
+ }), I !== b[h][0]) {
1562
1527
  if (C) throw C;
1563
1528
  return k;
1564
- } else C && R && d(C) && (s = !0, b({
1565
- data: J,
1529
+ } else C && R && d(C) && (s = !0, y({
1530
+ data: K,
1566
1531
  _c: P
1567
1532
  }));
1568
1533
  if (s && !C)
1569
- if (q(s)) {
1570
- const U = s(k, J);
1571
- b({
1534
+ if (j(s)) {
1535
+ const U = s(k, K);
1536
+ y({
1572
1537
  data: U,
1573
1538
  error: P,
1574
1539
  _c: P
1575
1540
  });
1576
1541
  } else
1577
- b({
1542
+ y({
1578
1543
  data: k,
1579
1544
  error: P,
1580
1545
  _c: P
1581
1546
  });
1582
- if (y[f][1] = dt(), Promise.resolve(N()).then(() => {
1583
- b({
1547
+ if (b[h][1] = ut(), Promise.resolve(N()).then(() => {
1548
+ y({
1584
1549
  _c: P
1585
1550
  });
1586
1551
  }), C) {
1587
- if (h) throw C;
1552
+ if (f) throw C;
1588
1553
  return;
1589
1554
  }
1590
1555
  return k;
1591
1556
  }
1592
1557
  }
1593
- const tr = (e, t) => {
1558
+ const er = (e, t) => {
1594
1559
  for (const r in e)
1595
1560
  e[r][0] && e[r][0](t);
1596
- }, Pn = (e, t) => {
1597
- if (!j.has(e)) {
1598
- const r = se(Mn, t), a = {}, n = Nr.bind(P, e);
1599
- let o = oe;
1600
- const s = {}, c = (h, m) => {
1601
- const u = s[h] || [];
1602
- return s[h] = u, u.push(m), () => u.splice(u.indexOf(m), 1);
1603
- }, g = (h, m, u) => {
1604
- e.set(h, m);
1605
- const f = s[h];
1606
- if (f)
1607
- for (const p of f)
1561
+ }, $n = (e, t) => {
1562
+ if (!G.has(e)) {
1563
+ const r = oe(An, t), a = {}, n = Tr.bind(P, e);
1564
+ let o = ae;
1565
+ const s = {}, c = (f, m) => {
1566
+ const u = s[f] || [];
1567
+ return s[f] = u, u.push(m), () => u.splice(u.indexOf(m), 1);
1568
+ }, g = (f, m, u) => {
1569
+ e.set(f, m);
1570
+ const h = s[f];
1571
+ if (h)
1572
+ for (const p of h)
1608
1573
  p(m, u);
1609
1574
  }, d = () => {
1610
- if (!j.has(e) && (j.set(e, [
1575
+ if (!G.has(e) && (G.set(e, [
1611
1576
  a,
1612
1577
  {},
1613
1578
  {},
@@ -1616,9 +1581,9 @@ const tr = (e, t) => {
1616
1581
  g,
1617
1582
  c
1618
1583
  ]), !_e)) {
1619
- const h = r.initFocus(setTimeout.bind(P, tr.bind(P, a, Sr))), m = r.initReconnect(setTimeout.bind(P, tr.bind(P, a, wr)));
1584
+ const f = r.initFocus(setTimeout.bind(P, er.bind(P, a, xr))), m = r.initReconnect(setTimeout.bind(P, er.bind(P, a, wr)));
1620
1585
  o = () => {
1621
- h && h(), m && m(), j.delete(e);
1586
+ f && f(), m && m(), G.delete(e);
1622
1587
  };
1623
1588
  }
1624
1589
  };
@@ -1631,48 +1596,48 @@ const tr = (e, t) => {
1631
1596
  }
1632
1597
  return [
1633
1598
  e,
1634
- j.get(e)[4]
1599
+ G.get(e)[4]
1635
1600
  ];
1636
- }, Un = (e, t, r, a, n) => {
1601
+ }, Dn = (e, t, r, a, n) => {
1637
1602
  const o = r.errorRetryCount, s = n.retryCount, c = ~~((Math.random() + 0.5) * (1 << (s < 8 ? s : 8))) * r.errorRetryInterval;
1638
1603
  !E(o) && s > o || setTimeout(a, c, n);
1639
- }, Fn = at, [xt, Hn] = Pn(/* @__PURE__ */ new Map()), Wn = se(
1604
+ }, Vn = nt, [Et, Pn] = $n(/* @__PURE__ */ new Map()), Un = oe(
1640
1605
  {
1641
1606
  // events
1642
- onLoadingSlow: oe,
1643
- onSuccess: oe,
1644
- onError: oe,
1645
- onErrorRetry: Un,
1646
- onDiscarded: oe,
1607
+ onLoadingSlow: ae,
1608
+ onSuccess: ae,
1609
+ onError: ae,
1610
+ onErrorRetry: Dn,
1611
+ onDiscarded: ae,
1647
1612
  // switches
1648
1613
  revalidateOnFocus: !0,
1649
1614
  revalidateOnReconnect: !0,
1650
1615
  revalidateIfStale: !0,
1651
1616
  shouldRetryOnError: !0,
1652
1617
  // timeouts
1653
- errorRetryInterval: er ? 1e4 : 5e3,
1618
+ errorRetryInterval: Qt ? 1e4 : 5e3,
1654
1619
  focusThrottleInterval: 5 * 1e3,
1655
1620
  dedupingInterval: 2 * 1e3,
1656
- loadingTimeout: er ? 5e3 : 3e3,
1621
+ loadingTimeout: Qt ? 5e3 : 3e3,
1657
1622
  // providers
1658
- compare: Fn,
1623
+ compare: Vn,
1659
1624
  isPaused: () => !1,
1660
- cache: xt,
1661
- mutate: Hn,
1625
+ cache: Et,
1626
+ mutate: Pn,
1662
1627
  fallback: {}
1663
1628
  },
1664
1629
  // use web preset by default
1665
- Bn
1666
- ), Gn = (e, t) => {
1667
- const r = se(e, t);
1630
+ Ln
1631
+ ), Fn = (e, t) => {
1632
+ const r = oe(e, t);
1668
1633
  if (t) {
1669
1634
  const { use: a, fallback: n } = e, { use: o, fallback: s } = t;
1670
- a && o && (r.use = a.concat(o)), n && s && (r.fallback = se(n, s));
1635
+ a && o && (r.use = a.concat(o)), n && s && (r.fallback = oe(n, s));
1671
1636
  }
1672
1637
  return r;
1673
- }, jn = ma({}), qn = "$inf$", Cr = Be && window.__SWR_DEVTOOLS_USE__, Kn = Cr ? window.__SWR_DEVTOOLS_USE__ : [], Jn = () => {
1674
- Cr && (window.__SWR_DEVTOOLS_REACT__ = M);
1675
- }, Yn = (e) => q(e[1]) ? [
1638
+ }, Hn = ua({}), Wn = "$inf$", Nr = Me && window.__SWR_DEVTOOLS_USE__, Gn = Nr ? window.__SWR_DEVTOOLS_USE__ : [], jn = () => {
1639
+ Nr && (window.__SWR_DEVTOOLS_REACT__ = A);
1640
+ }, qn = (e) => j(e[1]) ? [
1676
1641
  e[0],
1677
1642
  e[1],
1678
1643
  e[2] || {}
@@ -1680,33 +1645,33 @@ const tr = (e, t) => {
1680
1645
  e[0],
1681
1646
  null,
1682
1647
  (e[1] === null ? e[2] : e[1]) || {}
1683
- ], Zn = () => se(Wn, B(jn)), St = (e, t) => {
1684
- const [r, a] = Me(e), [, , , n] = j.get(xt);
1648
+ ], Kn = () => oe(Un, z(Hn)), xt = (e, t) => {
1649
+ const [r, a] = ze(e), [, , , n] = G.get(Et);
1685
1650
  if (n[r]) return n[r];
1686
1651
  const o = t(a);
1687
1652
  return n[r] = o, o;
1688
- }, Xn = (e) => (t, r, a) => e(t, r && ((...o) => {
1689
- const [s] = Me(t), [, , , c] = j.get(xt);
1690
- if (s.startsWith(qn))
1653
+ }, Jn = (e) => (t, r, a) => e(t, r && ((...o) => {
1654
+ const [s] = ze(t), [, , , c] = G.get(Et);
1655
+ if (s.startsWith(Wn))
1691
1656
  return r(...o);
1692
1657
  const g = c[s];
1693
1658
  return E(g) ? r(...o) : (delete c[s], g);
1694
- }), a), Qn = Kn.concat(Xn), eo = (e) => function(...r) {
1695
- const a = Zn(), [n, o, s] = Yn(r), c = Gn(a, s);
1659
+ }), a), Yn = Gn.concat(Jn), Zn = (e) => function(...r) {
1660
+ const a = Kn(), [n, o, s] = qn(r), c = Fn(a, s);
1696
1661
  let g = e;
1697
- const { use: d } = c, h = (d || []).concat(Qn);
1698
- for (let m = h.length; m--; )
1699
- g = h[m](g);
1662
+ const { use: d } = c, f = (d || []).concat(Yn);
1663
+ for (let m = f.length; m--; )
1664
+ g = f[m](g);
1700
1665
  return g(n, o || c.fetcher || null, c);
1701
- }, to = (e, t, r) => {
1666
+ }, Xn = (e, t, r) => {
1702
1667
  const a = t[e] || (t[e] = []);
1703
1668
  return a.push(r), () => {
1704
1669
  const n = a.indexOf(r);
1705
1670
  n >= 0 && (a[n] = a[a.length - 1], a.pop());
1706
1671
  };
1707
1672
  };
1708
- Jn();
1709
- const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the generic and JSX sytax
1673
+ jn();
1674
+ const Xe = A.use || // This extra generic is to avoid TypeScript mixing up the generic and JSX sytax
1710
1675
  // and emitting an error.
1711
1676
  // We assume that this is only for the `use(thenable)` case, not `use(context)`.
1712
1677
  // https://github.com/facebook/react/blob/aed00dacfb79d17c53218404c52b1c7aa59c4a89/packages/react-server/src/ReactFizzThenable.js#L45
@@ -1725,95 +1690,95 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
1725
1690
  e.status = "rejected", e.reason = t;
1726
1691
  }), e;
1727
1692
  }
1728
- }), Xe = {
1693
+ }), Qe = {
1729
1694
  dedupe: !0
1730
- }, ro = (e, t, r) => {
1731
- const { cache: a, compare: n, suspense: o, fallbackData: s, revalidateOnMount: c, revalidateIfStale: g, refreshInterval: d, refreshWhenHidden: h, refreshWhenOffline: m, keepPreviousData: u } = r, [f, p, b, v] = j.get(a), [y, _] = Me(e), S = O(!1), N = O(!1), k = O(y), C = O(t), I = O(r), R = () => I.current, Q = () => R().isVisible() && R().isOnline(), [F, ee, J, U] = xr(a, y), te = O({}).current, ce = E(s) ? E(r.fallback) ? P : r.fallback[y] : s, he = (w, T) => {
1732
- for (const D in te) {
1733
- const L = D;
1695
+ }, Qn = (e, t, r) => {
1696
+ const { cache: a, compare: n, suspense: o, fallbackData: s, revalidateOnMount: c, revalidateIfStale: g, refreshInterval: d, refreshWhenHidden: f, refreshWhenOffline: m, keepPreviousData: u } = r, [h, p, y, v] = G.get(a), [b, _] = ze(e), w = M(!1), N = M(!1), k = M(b), C = M(t), I = M(r), R = () => I.current, Z = () => R().isVisible() && R().isOnline(), [F, X, K, U] = Er(a, b), Q = M({}).current, ie = E(s) ? E(r.fallback) ? P : r.fallback[b] : s, he = (S, T) => {
1697
+ for (const $ in Q) {
1698
+ const L = $;
1734
1699
  if (L === "data") {
1735
- if (!n(w[L], T[L]) && (!E(w[L]) || !n(Ne, T[L])))
1700
+ if (!n(S[L], T[L]) && (!E(S[L]) || !n(Te, T[L])))
1736
1701
  return !1;
1737
- } else if (T[L] !== w[L])
1702
+ } else if (T[L] !== S[L])
1738
1703
  return !1;
1739
1704
  }
1740
1705
  return !0;
1741
- }, we = bt(() => {
1742
- const w = !y || !t ? !1 : E(c) ? R().isPaused() || o ? !1 : g !== !1 : c, T = (V) => {
1743
- const Y = se(V);
1744
- return delete Y._k, w ? {
1706
+ }, we = ur(() => {
1707
+ const S = !b || !t ? !1 : E(c) ? R().isPaused() || o ? !1 : g !== !1 : c, T = (V) => {
1708
+ const J = oe(V);
1709
+ return delete J._k, S ? {
1745
1710
  isValidating: !0,
1746
1711
  isLoading: !0,
1747
- ...Y
1748
- } : Y;
1749
- }, D = F(), L = U(), G = T(D), ue = D === L ? G : T(L);
1750
- let z = G;
1712
+ ...J
1713
+ } : J;
1714
+ }, $ = F(), L = U(), W = T($), de = $ === L ? W : T(L);
1715
+ let O = W;
1751
1716
  return [
1752
1717
  () => {
1753
1718
  const V = T(F());
1754
- return he(V, z) ? (z.data = V.data, z.isLoading = V.isLoading, z.isValidating = V.isValidating, z.error = V.error, z) : (z = V, V);
1719
+ return he(V, O) ? (O.data = V.data, O.isLoading = V.isLoading, O.isValidating = V.isValidating, O.error = V.error, O) : (O = V, V);
1755
1720
  },
1756
- () => ue
1721
+ () => de
1757
1722
  ];
1758
1723
  }, [
1759
1724
  a,
1760
- y
1761
- ]), re = Cn.useSyncExternalStore(K(
1762
- (w) => J(y, (T, D) => {
1763
- he(D, T) || w();
1725
+ b
1726
+ ]), ee = Sn.useSyncExternalStore(ne(
1727
+ (S) => K(b, (T, $) => {
1728
+ he($, T) || S();
1764
1729
  }),
1765
1730
  // eslint-disable-next-line react-hooks/exhaustive-deps
1766
1731
  [
1767
1732
  a,
1768
- y
1733
+ b
1769
1734
  ]
1770
- ), we[0], we[1]), ae = !S.current, Wr = f[y] && f[y].length > 0, le = re.data, de = E(le) ? ce && Er(ce) ? Ze(ce) : ce : le, Te = re.error, It = O(de), Ne = u ? E(le) ? It.current : le : de, Lt = Wr && !E(Te) ? !1 : ae && !E(c) ? c : R().isPaused() ? !1 : o ? E(de) ? !1 : g : E(de) || g, At = !!(y && t && ae && Lt), Gr = E(re.isValidating) ? At : re.isValidating, jr = E(re.isLoading) ? At : re.isLoading, fe = K(
1771
- async (w) => {
1735
+ ), we[0], we[1]), te = !w.current, Hr = h[b] && h[b].length > 0, ce = ee.data, le = E(ce) ? ie && _r(ie) ? Xe(ie) : ie : ce, Se = ee.error, Rt = M(le), Te = u ? E(ce) ? Rt.current : ce : le, It = Hr && !E(Se) ? !1 : te && !E(c) ? c : R().isPaused() ? !1 : o ? E(le) ? !1 : g : E(le) || g, Lt = !!(b && t && te && It), Wr = E(ee.isValidating) ? Lt : ee.isValidating, Gr = E(ee.isLoading) ? Lt : ee.isLoading, fe = ne(
1736
+ async (S) => {
1772
1737
  const T = C.current;
1773
- if (!y || !T || N.current || R().isPaused())
1738
+ if (!b || !T || N.current || R().isPaused())
1774
1739
  return !1;
1775
- let D, L, G = !0;
1776
- const ue = w || {}, z = !b[y] || !ue.dedupe, V = () => Qt ? !N.current && y === k.current && S.current : y === k.current, Y = {
1740
+ let $, L, W = !0;
1741
+ const de = S || {}, O = !y[b] || !de.dedupe, V = () => Xt ? !N.current && b === k.current && w.current : b === k.current, J = {
1777
1742
  isValidating: !1,
1778
1743
  isLoading: !1
1744
+ }, Ot = () => {
1745
+ X(J);
1779
1746
  }, Bt = () => {
1780
- ee(Y);
1781
- }, Mt = () => {
1782
- const H = b[y];
1783
- H && H[1] === L && delete b[y];
1784
- }, zt = {
1747
+ const H = y[b];
1748
+ H && H[1] === L && delete y[b];
1749
+ }, Mt = {
1785
1750
  isValidating: !0
1786
1751
  };
1787
- E(F().data) && (zt.isLoading = !0);
1752
+ E(F().data) && (Mt.isLoading = !0);
1788
1753
  try {
1789
- if (z && (ee(zt), r.loadingTimeout && E(F().data) && setTimeout(() => {
1790
- G && V() && R().onLoadingSlow(y, r);
1791
- }, r.loadingTimeout), b[y] = [
1754
+ if (O && (X(Mt), r.loadingTimeout && E(F().data) && setTimeout(() => {
1755
+ W && V() && R().onLoadingSlow(b, r);
1756
+ }, r.loadingTimeout), y[b] = [
1792
1757
  T(_),
1793
- dt()
1794
- ]), [D, L] = b[y], D = await D, z && setTimeout(Mt, r.dedupingInterval), !b[y] || b[y][1] !== L)
1795
- return z && V() && R().onDiscarded(y), !1;
1796
- Y.error = P;
1797
- const H = p[y];
1758
+ ut()
1759
+ ]), [$, L] = y[b], $ = await $, O && setTimeout(Bt, r.dedupingInterval), !y[b] || y[b][1] !== L)
1760
+ return O && V() && R().onDiscarded(b), !1;
1761
+ J.error = P;
1762
+ const H = p[b];
1798
1763
  if (!E(H) && // case 1
1799
1764
  (L <= H[0] || // case 2
1800
1765
  L <= H[1] || // case 3
1801
1766
  H[1] === 0))
1802
- return Bt(), z && V() && R().onDiscarded(y), !1;
1803
- const Z = F().data;
1804
- Y.data = n(Z, D) ? Z : D, z && V() && R().onSuccess(D, y, r);
1767
+ return Ot(), O && V() && R().onDiscarded(b), !1;
1768
+ const Y = F().data;
1769
+ J.data = n(Y, $) ? Y : $, O && V() && R().onSuccess($, b, r);
1805
1770
  } catch (H) {
1806
- Mt();
1807
- const Z = R(), { shouldRetryOnError: Pe } = Z;
1808
- Z.isPaused() || (Y.error = H, z && V() && (Z.onError(H, y, Z), (Pe === !0 || q(Pe) && Pe(H)) && (!R().revalidateOnFocus || !R().revalidateOnReconnect || Q()) && Z.onErrorRetry(H, y, Z, (qr) => {
1809
- const Ue = f[y];
1810
- Ue && Ue[0] && Ue[0](pe.ERROR_REVALIDATE_EVENT, qr);
1771
+ Bt();
1772
+ const Y = R(), { shouldRetryOnError: Ue } = Y;
1773
+ Y.isPaused() || (J.error = H, O && V() && (Y.onError(H, b, Y), (Ue === !0 || j(Ue) && Ue(H)) && (!R().revalidateOnFocus || !R().revalidateOnReconnect || Z()) && Y.onErrorRetry(H, b, Y, (jr) => {
1774
+ const Fe = h[b];
1775
+ Fe && Fe[0] && Fe[0](pe.ERROR_REVALIDATE_EVENT, jr);
1811
1776
  }, {
1812
- retryCount: (ue.retryCount || 0) + 1,
1777
+ retryCount: (de.retryCount || 0) + 1,
1813
1778
  dedupe: !0
1814
1779
  })));
1815
1780
  }
1816
- return G = !1, Bt(), !0;
1781
+ return W = !1, Ot(), !0;
1817
1782
  },
1818
1783
  // `setState` is immutable, and `eventsCallback`, `fnArg`, and
1819
1784
  // `keyValidating` are depending on `key`, so we can exclude them from
@@ -1827,89 +1792,89 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
1827
1792
  // even though it might cause unexpected behaviors.
1828
1793
  // eslint-disable-next-line react-hooks/exhaustive-deps
1829
1794
  [
1830
- y,
1795
+ b,
1831
1796
  a
1832
1797
  ]
1833
- ), Ot = K(
1798
+ ), At = ne(
1834
1799
  // Use callback to make sure `keyRef.current` returns latest result every time
1835
- (...w) => Nr(a, k.current, ...w),
1800
+ (...S) => Tr(a, k.current, ...S),
1836
1801
  // eslint-disable-next-line react-hooks/exhaustive-deps
1837
1802
  []
1838
1803
  );
1839
- if (Ke(() => {
1840
- C.current = t, I.current = r, E(le) || (It.current = le);
1841
- }), Ke(() => {
1842
- if (!y) return;
1843
- const w = fe.bind(P, Xe);
1804
+ if (Je(() => {
1805
+ C.current = t, I.current = r, E(ce) || (Rt.current = ce);
1806
+ }), Je(() => {
1807
+ if (!b) return;
1808
+ const S = fe.bind(P, Qe);
1844
1809
  let T = 0;
1845
- const L = to(y, f, (G, ue = {}) => {
1846
- if (G == pe.FOCUS_EVENT) {
1847
- const z = Date.now();
1848
- R().revalidateOnFocus && z > T && Q() && (T = z + R().focusThrottleInterval, w());
1849
- } else if (G == pe.RECONNECT_EVENT)
1850
- R().revalidateOnReconnect && Q() && w();
1810
+ const L = Xn(b, h, (W, de = {}) => {
1811
+ if (W == pe.FOCUS_EVENT) {
1812
+ const O = Date.now();
1813
+ R().revalidateOnFocus && O > T && Z() && (T = O + R().focusThrottleInterval, S());
1814
+ } else if (W == pe.RECONNECT_EVENT)
1815
+ R().revalidateOnReconnect && Z() && S();
1851
1816
  else {
1852
- if (G == pe.MUTATE_EVENT)
1817
+ if (W == pe.MUTATE_EVENT)
1853
1818
  return fe();
1854
- if (G == pe.ERROR_REVALIDATE_EVENT)
1855
- return fe(ue);
1819
+ if (W == pe.ERROR_REVALIDATE_EVENT)
1820
+ return fe(de);
1856
1821
  }
1857
1822
  });
1858
- return N.current = !1, k.current = y, S.current = !0, ee({
1823
+ return N.current = !1, k.current = b, w.current = !0, X({
1859
1824
  _k: _
1860
- }), Lt && (E(de) || _e ? w() : zn(w)), () => {
1825
+ }), It && (E(le) || _e ? S() : On(S)), () => {
1861
1826
  N.current = !0, L();
1862
1827
  };
1863
1828
  }, [
1864
- y
1865
- ]), Ke(() => {
1866
- let w;
1829
+ b
1830
+ ]), Je(() => {
1831
+ let S;
1867
1832
  function T() {
1868
- const L = q(d) ? d(F().data) : d;
1869
- L && w !== -1 && (w = setTimeout(D, L));
1833
+ const L = j(d) ? d(F().data) : d;
1834
+ L && S !== -1 && (S = setTimeout($, L));
1870
1835
  }
1871
- function D() {
1872
- !F().error && (h || R().isVisible()) && (m || R().isOnline()) ? fe(Xe).then(T) : T();
1836
+ function $() {
1837
+ !F().error && (f || R().isVisible()) && (m || R().isOnline()) ? fe(Qe).then(T) : T();
1873
1838
  }
1874
1839
  return T(), () => {
1875
- w && (clearTimeout(w), w = -1);
1840
+ S && (clearTimeout(S), S = -1);
1876
1841
  };
1877
1842
  }, [
1878
1843
  d,
1879
- h,
1844
+ f,
1880
1845
  m,
1881
- y
1882
- ]), ga(Ne), o && E(de) && y) {
1883
- if (!Qt && _e)
1846
+ b
1847
+ ]), ga(Te), o && E(le) && b) {
1848
+ if (!Xt && _e)
1884
1849
  throw new Error("Fallback data is required when using Suspense in SSR.");
1885
1850
  C.current = t, I.current = r, N.current = !1;
1886
- const w = v[y];
1887
- if (!E(w)) {
1888
- const T = Ot(w);
1889
- Ze(T);
1851
+ const S = v[b];
1852
+ if (!E(S)) {
1853
+ const T = At(S);
1854
+ Xe(T);
1890
1855
  }
1891
- if (E(Te)) {
1892
- const T = fe(Xe);
1893
- E(Ne) || (T.status = "fulfilled", T.value = !0), Ze(T);
1856
+ if (E(Se)) {
1857
+ const T = fe(Qe);
1858
+ E(Te) || (T.status = "fulfilled", T.value = !0), Xe(T);
1894
1859
  } else
1895
- throw Te;
1860
+ throw Se;
1896
1861
  }
1897
1862
  return {
1898
- mutate: Ot,
1863
+ mutate: At,
1899
1864
  get data() {
1900
- return te.data = !0, Ne;
1865
+ return Q.data = !0, Te;
1901
1866
  },
1902
1867
  get error() {
1903
- return te.error = !0, Te;
1868
+ return Q.error = !0, Se;
1904
1869
  },
1905
1870
  get isValidating() {
1906
- return te.isValidating = !0, Gr;
1871
+ return Q.isValidating = !0, Wr;
1907
1872
  },
1908
1873
  get isLoading() {
1909
- return te.isLoading = !0, jr;
1874
+ return Q.isLoading = !0, Gr;
1910
1875
  }
1911
1876
  };
1912
- }, ao = eo(ro), ne = {
1877
+ }, eo = Zn(Qn), re = {
1913
1878
  GET_LOCATION: `query GetLocation($latitude: Float!, $longitude: Float!) {
1914
1879
  location(latitude: $latitude, longitude: $longitude) {
1915
1880
  country
@@ -2000,44 +1965,44 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2000
1965
  engine: $engine,
2001
1966
  tags: $tags)
2002
1967
  }`
2003
- }, Se = {
1968
+ }, xe = {
2004
1969
  GET_LOCATION: {
2005
- schema: ne.GET_LOCATION,
1970
+ schema: re.GET_LOCATION,
2006
1971
  method: "location"
2007
1972
  },
2008
1973
  GET_CHATS: {
2009
- schema: ne.GET_CHATS,
1974
+ schema: re.GET_CHATS,
2010
1975
  method: "chats"
2011
1976
  },
2012
1977
  GET_CHATS_STATS: {
2013
- schema: ne.GET_CHATS_STATS,
1978
+ schema: re.GET_CHATS_STATS,
2014
1979
  method: "chatsStats"
2015
1980
  },
2016
1981
  GET_CHAT: {
2017
- schema: ne.GET_CHAT,
1982
+ schema: re.GET_CHAT,
2018
1983
  method: "chatById"
2019
1984
  },
2020
1985
  DELETE_CHAT: {
2021
- schema: ne.DELETE_CHAT,
1986
+ schema: re.DELETE_CHAT,
2022
1987
  method: "deleteChat"
2023
1988
  },
2024
1989
  GET_SERVER_CAPABILITIES: {
2025
- schema: ne.GET_SERVER_CAPABILITIES,
1990
+ schema: re.GET_SERVER_CAPABILITIES,
2026
1991
  method: "getServerCapabilities"
2027
1992
  },
2028
1993
  GET_USER_PREFERENCES: {
2029
- schema: ne.GET_USER_PREFERENCES,
1994
+ schema: re.GET_USER_PREFERENCES,
2030
1995
  method: "getUserPreferences"
2031
1996
  },
2032
1997
  SET_USER_PREFERENCES: {
2033
- schema: ne.SET_USER_PREFERENCES,
1998
+ schema: re.SET_USER_PREFERENCES,
2034
1999
  method: "setUserPreferences"
2035
2000
  }
2036
- }, Rr = process.env.PUBLIC_SASSY_API_SERVER_URL, no = async ({
2001
+ }, Cr = process.env.PUBLIC_SASSY_API_SERVER_URL, to = async ({
2037
2002
  query: e,
2038
2003
  data: t,
2039
2004
  headers: r = {}
2040
- }) => await fetch(`${Rr}/graphql`, {
2005
+ }) => await fetch(`${Cr}/graphql`, {
2041
2006
  method: "POST",
2042
2007
  credentials: "include",
2043
2008
  headers: {
@@ -2049,14 +2014,14 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2049
2014
  query: e,
2050
2015
  variables: t
2051
2016
  })
2052
- }), Ir = async ({
2017
+ }), Rr = async ({
2053
2018
  accessToken: e,
2054
2019
  type: t,
2055
2020
  params: r = {}
2056
2021
  }) => {
2057
2022
  const a = t != null && t.data ? t.data(r) : r;
2058
2023
  try {
2059
- const n = `Bearer ${e}`, o = await no({
2024
+ const n = `Bearer ${e}`, o = await to({
2060
2025
  headers: {
2061
2026
  authorization: n
2062
2027
  },
@@ -2074,14 +2039,14 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2074
2039
  } catch (n) {
2075
2040
  return console.error(n), { status: 500, data: [] };
2076
2041
  }
2077
- }, oo = async ({
2042
+ }, ro = async ({
2078
2043
  accessToken: e,
2079
2044
  name: t,
2080
2045
  data: r,
2081
2046
  method: a = "POST"
2082
2047
  }) => {
2083
2048
  const n = `Bearer ${e}`;
2084
- return await fetch(`${Rr}/api/${t}`, {
2049
+ return await fetch(`${Cr}/api/${t}`, {
2085
2050
  method: a,
2086
2051
  credentials: "include",
2087
2052
  headers: {
@@ -2090,25 +2055,25 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2090
2055
  },
2091
2056
  body: JSON.stringify(r)
2092
2057
  });
2093
- }, ze = ({
2058
+ }, $e = ({
2094
2059
  fetcher: e,
2095
2060
  scope: t,
2096
2061
  keys: r,
2097
2062
  swrOptions: a,
2098
2063
  getAccessToken: n
2099
2064
  }) => {
2100
- const { data: o, error: s, isLoading: c, mutate: g } = ao(
2065
+ const { data: o, error: s, isLoading: c, mutate: g } = eo(
2101
2066
  [t, ...r],
2102
2067
  (d) => e(d, n),
2103
2068
  { ...a }
2104
2069
  );
2105
2070
  return { data: o, error: s, isLoading: c, mutate: g };
2106
- }, $e = async ({
2071
+ }, De = async ({
2107
2072
  getAccessToken: e,
2108
2073
  type: t,
2109
2074
  params: r
2110
2075
  }) => {
2111
- const a = await e(), n = await Ir({
2076
+ const a = await e(), n = await Rr({
2112
2077
  accessToken: a,
2113
2078
  type: t,
2114
2079
  params: r
@@ -2116,46 +2081,46 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2116
2081
  if (n.status === 200 && n.errors === void 0)
2117
2082
  return n.data;
2118
2083
  throw new Error("An error occurred while fetching the data.");
2119
- }, Lr = async ([e, t], r) => $e({
2084
+ }, Ir = async ([e, t], r) => De({
2120
2085
  getAccessToken: r,
2121
- type: Se.GET_USER_PREFERENCES,
2086
+ type: xe.GET_USER_PREFERENCES,
2122
2087
  params: {
2123
2088
  user: t
2124
2089
  }
2125
- }), Ar = ({
2090
+ }), Lr = ({
2126
2091
  keys: e,
2127
2092
  getAccessToken: t
2128
- }) => ze({
2129
- fetcher: Lr,
2093
+ }) => $e({
2094
+ fetcher: Ir,
2130
2095
  scope: "/preferences",
2131
2096
  keys: e,
2132
2097
  swrOptions: { keepPreviousData: !0 },
2133
2098
  getAccessToken: t
2134
- }), so = ({
2099
+ }), ao = ({
2135
2100
  keys: e,
2136
2101
  getAccessToken: t
2137
2102
  }) => {
2138
- St(
2103
+ xt(
2139
2104
  ["/preferences", ...e],
2140
- (r) => Lr(r, t)
2105
+ (r) => Ir(r, t)
2141
2106
  );
2142
- }, io = async ([e, t], r) => $e({
2107
+ }, no = async ([e, t], r) => De({
2143
2108
  getAccessToken: r,
2144
- type: Se.GET_CHATS_STATS,
2109
+ type: xe.GET_CHATS_STATS,
2145
2110
  params: {
2146
2111
  user: t
2147
2112
  }
2148
- }), _s = ({
2113
+ }), vs = ({
2149
2114
  keys: e,
2150
2115
  getAccessToken: t
2151
- }) => ze({
2152
- fetcher: io,
2116
+ }) => $e({
2117
+ fetcher: no,
2153
2118
  scope: "/stats",
2154
2119
  keys: e,
2155
2120
  getAccessToken: t
2156
- }), Or = async ([e, t, r, a], n) => $e({
2121
+ }), Ar = async ([e, t, r, a], n) => De({
2157
2122
  getAccessToken: n,
2158
- type: Se.GET_CHATS,
2123
+ type: xe.GET_CHATS,
2159
2124
  params: {
2160
2125
  user: t,
2161
2126
  searchString: r,
@@ -2163,11 +2128,11 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2163
2128
  limit: 1,
2164
2129
  truncateSize: 100
2165
2130
  }
2166
- }), Es = ({
2131
+ }), ks = ({
2167
2132
  keys: e,
2168
2133
  getAccessToken: t
2169
- }) => ze({
2170
- fetcher: Or,
2134
+ }) => $e({
2135
+ fetcher: Ar,
2171
2136
  scope: "/history",
2172
2137
  keys: e,
2173
2138
  getAccessToken: t,
@@ -2175,26 +2140,26 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2175
2140
  keepPreviousData: !0,
2176
2141
  dedupingInterval: 1e4
2177
2142
  }
2178
- }), co = ({
2143
+ }), oo = ({
2179
2144
  keys: e,
2180
2145
  getAccessToken: t
2181
2146
  }) => {
2182
- St(["/history", ...e], (r) => Or(r, t));
2183
- }, Br = async ([e], t) => $e({
2147
+ xt(["/history", ...e], (r) => Ar(r, t));
2148
+ }, Or = async ([e], t) => De({
2184
2149
  getAccessToken: t,
2185
- type: Se.GET_SERVER_CAPABILITIES
2186
- }), xs = ({
2150
+ type: xe.GET_SERVER_CAPABILITIES
2151
+ }), _s = ({
2187
2152
  getAccessToken: e
2188
- }) => ze({
2189
- fetcher: Br,
2153
+ }) => $e({
2154
+ fetcher: Or,
2190
2155
  scope: "/capabilities",
2191
2156
  keys: [],
2192
2157
  getAccessToken: e
2193
- }), lo = ({
2158
+ }), so = ({
2194
2159
  getAccessToken: e
2195
2160
  }) => {
2196
- St(["/capabilities"], (t) => Br(t, e));
2197
- }, uo = "z-20", mo = "z-10", X = M.createContext({
2161
+ xt(["/capabilities"], (t) => Or(t, e));
2162
+ }, io = "z-20", co = "z-10", se = A.createContext({
2198
2163
  state: {
2199
2164
  id: "",
2200
2165
  model: ke,
@@ -2212,27 +2177,27 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2212
2177
  plugins: [],
2213
2178
  engines: []
2214
2179
  }
2215
- }), go = M.createContext({
2180
+ }), lo = A.createContext({
2216
2181
  state: { searchString: "", sortedCell: "", sortDirection: "" },
2217
2182
  dispatch: () => {
2218
2183
  }
2219
- }), De = M.createContext({
2184
+ }), Ve = A.createContext({
2220
2185
  state: { prompt: "", lastTriggeredTimestamp: 0 },
2221
2186
  dispatch: () => {
2222
2187
  }
2223
- }), ho = ({
2188
+ }), uo = ({
2224
2189
  className: e
2225
2190
  }) => {
2226
- const { state: t, dispatch: r } = B(X), a = O(null), n = O(!1), o = (s) => {
2191
+ const { state: t, dispatch: r } = z(se), a = M(null), n = M(!1), o = (s) => {
2227
2192
  s.preventDefault(), r({
2228
2193
  type: ft
2229
2194
  });
2230
2195
  };
2231
- return A(() => {
2196
+ return D(() => {
2232
2197
  var s;
2233
2198
  (t == null ? void 0 : t.streaming) === !0 && !n.current && a.current && (n.current = !0, a.current.focus()), (t == null ? void 0 : t.streaming) === !1 && (n.current = !1, (s = a.current) == null || s.blur());
2234
2199
  }, [t]), /* @__PURE__ */ i(
2235
- Ee,
2200
+ Oe,
2236
2201
  {
2237
2202
  className: e,
2238
2203
  noBorder: !0,
@@ -2245,7 +2210,7 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2245
2210
  children: t != null && t.streaming ? /* @__PURE__ */ i(Oa, { size: "size-4", monotone: !0 }) : /* @__PURE__ */ i(La, { size: "size-4", monotone: !0 })
2246
2211
  }
2247
2212
  );
2248
- }, ut = et.createContext({
2213
+ }, mt = tt.createContext({
2249
2214
  getItemProps: () => ({}),
2250
2215
  activeIndex: null,
2251
2216
  /* v8 ignore next 2 */
@@ -2254,7 +2219,7 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2254
2219
  setHasFocusInside: () => {
2255
2220
  },
2256
2221
  isOpen: !1
2257
- }), rr = (e) => {
2222
+ }), tr = (e) => {
2258
2223
  if (typeof e == "string")
2259
2224
  return e;
2260
2225
  if (typeof e == "function")
@@ -2265,7 +2230,7 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2265
2230
  return t.displayName || t.name || "Component";
2266
2231
  }
2267
2232
  return "Element";
2268
- }, Mr = gr(
2233
+ }, Br = mr(
2269
2234
  ({
2270
2235
  trigger: e,
2271
2236
  children: t,
@@ -2276,11 +2241,11 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2276
2241
  focusMode: s = "system",
2277
2242
  ...c
2278
2243
  }, g) => {
2279
- const [d, h] = W(!1), [m, u] = W(!1), [f, p] = W(null), b = O([]), v = O([]), y = B(ut), _ = fr(), S = ha(), N = pr(), { floatingStyles: k, refs: C, context: I } = fa({
2280
- nodeId: S,
2244
+ const [d, f] = q(!1), [m, u] = q(!1), [h, p] = q(null), y = M([]), v = M([]), b = z(mt), _ = hr(), w = ha(), N = fr(), { floatingStyles: k, refs: C, context: I } = fa({
2245
+ nodeId: w,
2281
2246
  open: d,
2282
- onOpenChange: (ae) => {
2283
- h(ae), n == null || n(ae);
2247
+ onOpenChange: (te) => {
2248
+ f(te), n == null || n(te);
2284
2249
  },
2285
2250
  placement: a,
2286
2251
  strategy: "fixed",
@@ -2290,59 +2255,59 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2290
2255
  event: "mousedown",
2291
2256
  toggle: !0,
2292
2257
  ignoreMouse: !1
2293
- }), Q = _a(I, { role: "menu" }), F = Ea(I, { bubbles: !0 }), ee = xa(I, {
2294
- listRef: b,
2295
- activeIndex: f,
2258
+ }), Z = _a(I, { role: "menu" }), F = Ea(I, { bubbles: !0 }), X = xa(I, {
2259
+ listRef: y,
2260
+ activeIndex: h,
2296
2261
  nested: !1,
2297
2262
  onNavigate: p,
2298
2263
  loop: !0
2299
- }), J = Sa(I, {
2264
+ }), K = wa(I, {
2300
2265
  listRef: v,
2301
2266
  onMatch: d ? p : void 0,
2302
- activeIndex: f
2303
- }), { getReferenceProps: U, getFloatingProps: te, getItemProps: ce } = wa([R, Q, F, ee, J]), he = rr(e) === "Button" || rr(e) === "ButtonIcon", we = he ? {
2267
+ activeIndex: h
2268
+ }), { getReferenceProps: U, getFloatingProps: Q, getItemProps: ie } = Sa([R, Z, F, X, K]), he = tr(e) === "Button" || tr(e) === "ButtonIcon", we = he ? {
2304
2269
  noInternalClick: he,
2305
2270
  focusMode: s,
2306
2271
  mode: o
2307
- } : {}, re = M.cloneElement(
2272
+ } : {}, ee = A.cloneElement(
2308
2273
  e,
2309
2274
  {
2310
2275
  ...we,
2311
2276
  "aria-label": r,
2312
2277
  "data-open": d ? "" : void 0,
2313
2278
  "data-focus-inside": m ? "" : void 0,
2314
- ref: br([C.setReference, N.ref, g]),
2279
+ ref: pr([C.setReference, N.ref, g]),
2315
2280
  ...U(
2316
- y.getItemProps({
2281
+ b.getItemProps({
2317
2282
  ...c
2318
2283
  })
2319
2284
  )
2320
2285
  }
2321
2286
  );
2322
- return A(() => {
2287
+ return D(() => {
2323
2288
  if (!_)
2324
2289
  return;
2325
- function ae() {
2326
- h(!1), n == null || n(!1);
2290
+ function te() {
2291
+ f(!1), n == null || n(!1);
2327
2292
  }
2328
- return _.events.on("click", ae), () => {
2329
- _.events.off("click", ae);
2293
+ return _.events.on("click", te), () => {
2294
+ _.events.off("click", te);
2330
2295
  };
2331
- }, [_, n]), A(() => {
2332
- d && _ && _.events.emit("menuopen", { nodeId: S });
2333
- }, [_, d, S]), /* @__PURE__ */ x(Ta, { id: S, children: [
2334
- re,
2296
+ }, [_, n]), D(() => {
2297
+ d && _ && _.events.emit("menuopen", { nodeId: w });
2298
+ }, [_, d, w]), /* @__PURE__ */ x(Ta, { id: w, children: [
2299
+ ee,
2335
2300
  /* @__PURE__ */ i(
2336
- ut.Provider,
2301
+ mt.Provider,
2337
2302
  {
2338
2303
  value: {
2339
- activeIndex: f,
2304
+ activeIndex: h,
2340
2305
  setActiveIndex: p,
2341
- getItemProps: ce,
2306
+ getItemProps: ie,
2342
2307
  setHasFocusInside: u,
2343
2308
  isOpen: d
2344
2309
  },
2345
- children: /* @__PURE__ */ i(Na, { elementsRef: b, labelsRef: v, children: d && /* @__PURE__ */ i(Ca, { children: /* @__PURE__ */ i(
2310
+ children: /* @__PURE__ */ i(Na, { elementsRef: y, labelsRef: v, children: d && /* @__PURE__ */ i(Ca, { children: /* @__PURE__ */ i(
2346
2311
  Ra,
2347
2312
  {
2348
2313
  context: I,
@@ -2355,7 +2320,7 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2355
2320
  ref: C.setFloating,
2356
2321
  className: "rounded-md bg-surface-light shadow-sm shadow-border-dark outline-none p-4 sm:p-2",
2357
2322
  style: k,
2358
- ...te(),
2323
+ ...Q(),
2359
2324
  children: t
2360
2325
  }
2361
2326
  )
@@ -2365,10 +2330,10 @@ const Ze = M.use || // This extra generic is to avoid TypeScript mixing up the g
2365
2330
  )
2366
2331
  ] });
2367
2332
  }
2368
- ), wt = gr((e, t) => /* @__PURE__ */ i(Ia, { children: /* @__PURE__ */ i(Mr, { ...e, ref: t }) }));
2333
+ ), wt = mr((e, t) => /* @__PURE__ */ i(Ia, { children: /* @__PURE__ */ i(Br, { ...e, ref: t }) }));
2369
2334
  wt.displayName = "Menu";
2370
- Mr.displayName = "MenuComponent";
2371
- const Ae = et.forwardRef(
2335
+ Br.displayName = "MenuComponent";
2336
+ const Le = tt.forwardRef(
2372
2337
  ({
2373
2338
  label: e,
2374
2339
  disabled: t,
@@ -2380,16 +2345,16 @@ const Ae = et.forwardRef(
2380
2345
  ...c
2381
2346
  }, g) => {
2382
2347
  let d = "";
2383
- const h = et.useContext(ut), m = pr({ label: t ? null : e }), u = fr(), f = br([m.ref, g]);
2348
+ const f = tt.useContext(mt), m = fr({ label: t ? null : e }), u = hr(), h = pr([m.ref, g]);
2384
2349
  if (a && n)
2385
2350
  return /* @__PURE__ */ i(
2386
2351
  "div",
2387
2352
  {
2388
2353
  role: "menuitem",
2389
- ...h.getItemProps({
2390
- onClick(b) {
2354
+ ...f.getItemProps({
2355
+ onClick(y) {
2391
2356
  var v;
2392
- o || ((v = c.onClick) == null || v.call(c, b), u == null || u.events.emit("click"));
2357
+ o || ((v = c.onClick) == null || v.call(c, y), u == null || u.events.emit("click"));
2393
2358
  }
2394
2359
  }),
2395
2360
  children: n
@@ -2408,19 +2373,19 @@ const Ae = et.forwardRef(
2408
2373
  "button",
2409
2374
  {
2410
2375
  ...c,
2411
- ref: f,
2376
+ ref: h,
2412
2377
  role: "menuitem",
2413
2378
  className: p,
2414
2379
  tabIndex: 0,
2415
2380
  disabled: t,
2416
- ...h.getItemProps({
2417
- onClick(b) {
2381
+ ...f.getItemProps({
2382
+ onClick(y) {
2418
2383
  var v;
2419
- o || ((v = c.onClick) == null || v.call(c, b), u == null || u.events.emit("click"));
2384
+ o || ((v = c.onClick) == null || v.call(c, y), u == null || u.events.emit("click"));
2420
2385
  },
2421
- onFocus(b) {
2386
+ onFocus(y) {
2422
2387
  var v;
2423
- (v = c.onFocus) == null || v.call(c, b), h.setHasFocusInside(!0);
2388
+ (v = c.onFocus) == null || v.call(c, y), f.setHasFocusInside(!0);
2424
2389
  }
2425
2390
  }),
2426
2391
  children: [
@@ -2431,11 +2396,11 @@ const Ae = et.forwardRef(
2431
2396
  );
2432
2397
  }
2433
2398
  );
2434
- Ae.displayName = "MenuItem";
2435
- const Ss = ({ className: e, ...t }) => {
2399
+ Le.displayName = "MenuItem";
2400
+ const Es = ({ className: e, ...t }) => {
2436
2401
  const r = l(e, "my-1 border-t border-border-medium");
2437
2402
  return /* @__PURE__ */ i("div", { className: r, ...t });
2438
- }, zr = ({
2403
+ }, Mr = ({
2439
2404
  className: e,
2440
2405
  ...t
2441
2406
  }) => {
@@ -2455,56 +2420,56 @@ try {
2455
2420
  });
2456
2421
  } catch {
2457
2422
  }
2458
- const fo = (e) => {
2423
+ const mo = (e) => {
2459
2424
  for (let t = 0; t < e.length; t++)
2460
2425
  if (e[t].enabled)
2461
2426
  return !0;
2462
2427
  return !1;
2463
- }, po = ({
2428
+ }, go = ({
2464
2429
  className: e,
2465
2430
  defaultPlacement: t = "top-start"
2466
2431
  }) => {
2467
- const { dispatch: r } = B(De), { getAccessToken: a, user: n } = xe(), {
2432
+ const { dispatch: r } = z(Ve), { getAccessToken: a, user: n } = Ee(), {
2468
2433
  data: o,
2469
2434
  error: s,
2470
2435
  isLoading: c
2471
- } = Ar({
2436
+ } = Lr({
2472
2437
  keys: [n == null ? void 0 : n.username],
2473
2438
  getAccessToken: a
2474
- }), g = (d, h) => {
2439
+ }), g = (d, f) => {
2475
2440
  d.preventDefault(), r({
2476
- type: ur,
2441
+ type: dr,
2477
2442
  payload: {
2478
- prompt: h
2443
+ prompt: f
2479
2444
  }
2480
2445
  });
2481
2446
  };
2482
- return s || c ? null : o && o.tags && fo(o.tags) && /* @__PURE__ */ x(
2447
+ return s || c ? null : o && o.tags && mo(o.tags) && /* @__PURE__ */ x(
2483
2448
  wt,
2484
2449
  {
2485
2450
  mode: "dark",
2486
2451
  focusMode: "light",
2487
- trigger: /* @__PURE__ */ i(Ee, { className: e, noBorder: !0, label: "Prompts", children: /* @__PURE__ */ i(Aa, { size: "size-4" }) }),
2452
+ trigger: /* @__PURE__ */ i(Oe, { className: e, noBorder: !0, label: "Prompts", children: /* @__PURE__ */ i(Aa, { size: "size-4" }) }),
2488
2453
  defaultPlacement: t,
2489
2454
  children: [
2490
- /* @__PURE__ */ i(zr, { children: "Prompts" }),
2455
+ /* @__PURE__ */ i(Mr, { children: "Prompts" }),
2491
2456
  o && o.tags && o.tags.map((d) => d.enabled && d.label && d.content && /* @__PURE__ */ i(
2492
- Ae,
2457
+ Le,
2493
2458
  {
2494
2459
  label: d.label,
2495
- onClick: (h) => g(h, d.content)
2460
+ onClick: (f) => g(f, d.content)
2496
2461
  },
2497
2462
  `prompt-button-${d.slot}`
2498
2463
  ))
2499
2464
  ]
2500
2465
  }
2501
2466
  );
2502
- }, bo = ({
2467
+ }, ho = ({
2503
2468
  className: e
2504
2469
  }) => {
2505
- const { state: t } = B(X);
2470
+ const { state: t } = z(se);
2506
2471
  return /* @__PURE__ */ i(
2507
- Ee,
2472
+ Oe,
2508
2473
  {
2509
2474
  className: e,
2510
2475
  disabled: t == null ? void 0 : t.streaming,
@@ -2513,28 +2478,28 @@ const fo = (e) => {
2513
2478
  type: "submit",
2514
2479
  mode: "light",
2515
2480
  focusMode: "light",
2516
- children: /* @__PURE__ */ i(Ma, { size: "size-4" })
2481
+ children: /* @__PURE__ */ i(Ba, { size: "size-4" })
2517
2482
  }
2518
2483
  );
2519
- }, yo = ({
2484
+ }, fo = ({
2520
2485
  className: e
2521
2486
  }) => {
2522
- const { state: t, dispatch: r } = B(X), { getAccessToken: a, user: n } = xe(), {
2487
+ const { state: t, dispatch: r } = z(se), { getAccessToken: a, user: n } = Ee(), {
2523
2488
  data: o,
2524
2489
  error: s,
2525
2490
  isLoading: c,
2526
2491
  mutate: g
2527
- } = Ar({
2492
+ } = Lr({
2528
2493
  keys: [n == null ? void 0 : n.username],
2529
2494
  getAccessToken: a
2530
- }), d = async (h) => {
2495
+ }), d = async (f) => {
2531
2496
  try {
2532
- await Ir({
2497
+ await Rr({
2533
2498
  accessToken: await a(),
2534
- type: Se.SET_USER_PREFERENCES,
2499
+ type: xe.SET_USER_PREFERENCES,
2535
2500
  params: {
2536
2501
  user: n == null ? void 0 : n.username,
2537
- engine: h
2502
+ engine: f
2538
2503
  }
2539
2504
  }), g({ ...o }), t && (t == null ? void 0 : t.messages.length) > 0 && r({
2540
2505
  type: ft
@@ -2547,60 +2512,60 @@ const fo = (e) => {
2547
2512
  {
2548
2513
  mode: "dark",
2549
2514
  focusMode: "light",
2550
- trigger: /* @__PURE__ */ i(Ee, { className: e, noBorder: !0, label: "Engines", children: o && o.engine === Fe ? /* @__PURE__ */ i(Ft, { size: "size-4" }) : /* @__PURE__ */ i(Ht, { size: "size-4" }) }),
2515
+ trigger: /* @__PURE__ */ i(Oe, { className: e, noBorder: !0, label: "Engines", children: o && o.engine === He ? /* @__PURE__ */ i(Ut, { size: "size-4" }) : /* @__PURE__ */ i(Ft, { size: "size-4" }) }),
2551
2516
  defaultPlacement: "top-start",
2552
2517
  children: [
2553
- /* @__PURE__ */ i(zr, { children: "Engines" }),
2518
+ /* @__PURE__ */ i(Mr, { children: "Engines" }),
2554
2519
  /* @__PURE__ */ i(
2555
- Ae,
2520
+ Le,
2556
2521
  {
2557
- selected: o && o.engine === $t,
2522
+ selected: o && o.engine === zt,
2558
2523
  label: "OpenAI",
2559
- icon: /* @__PURE__ */ i(Ht, {}),
2560
- onClick: () => d($t)
2524
+ icon: /* @__PURE__ */ i(Ft, {}),
2525
+ onClick: () => d(zt)
2561
2526
  }
2562
2527
  ),
2563
2528
  /* @__PURE__ */ i(
2564
- Ae,
2529
+ Le,
2565
2530
  {
2566
- selected: o && o.engine === Fe,
2531
+ selected: o && o.engine === He,
2567
2532
  label: "Anthropic",
2568
- icon: /* @__PURE__ */ i(Ft, {}),
2569
- onClick: () => d(Fe)
2533
+ icon: /* @__PURE__ */ i(Ut, {}),
2534
+ onClick: () => d(He)
2570
2535
  }
2571
2536
  )
2572
2537
  ]
2573
2538
  }
2574
2539
  );
2575
- }, vo = () => l(
2540
+ }, po = () => l(
2576
2541
  "relative rounded-md text-base h-auto min-w-28 overflow-hidden pt-2"
2577
- ), ar = () => l("bg-surface-darker"), ko = () => l("text-copy-lighter caret-copy-light"), _o = () => l(
2542
+ ), rr = () => l("bg-surface-darker"), bo = () => l("text-copy-lighter caret-copy-light"), yo = () => l(
2578
2543
  "has-[.av-prompt-editable:focus]:outline",
2579
2544
  "has-[.av-prompt-editable:focus]:outline-2",
2580
2545
  "has-[.av-prompt-editable:focus]:outline-offset-2",
2581
2546
  "has-[.av-prompt-editable:focus]:outline-focus-light"
2582
- ), Eo = () => l(
2547
+ ), vo = () => l(
2583
2548
  "peer",
2584
2549
  "text-base resize-none overflow-hidden w-full text-inherit outline-none",
2585
2550
  "h-6 pr-2 pl-4"
2586
- ), xo = ({ className: e }) => {
2551
+ ), ko = ({ className: e }) => {
2587
2552
  const t = l(
2588
- Zr,
2589
- vo(),
2590
- ar(),
2591
- ko(),
2592
- _o(),
2553
+ Yr,
2554
+ po(),
2555
+ rr(),
2556
+ bo(),
2557
+ yo(),
2593
2558
  e
2594
2559
  ), r = l(
2595
- Xr,
2596
- Eo(),
2597
- ar()
2560
+ Zr,
2561
+ vo(),
2562
+ rr()
2598
2563
  );
2599
2564
  return {
2600
2565
  wrapper: t,
2601
2566
  textArea: r
2602
2567
  };
2603
- }, So = ({
2568
+ }, _o = ({
2604
2569
  className: e,
2605
2570
  label: t,
2606
2571
  value: r,
@@ -2610,9 +2575,9 @@ const fo = (e) => {
2610
2575
  ref: s,
2611
2576
  ...c
2612
2577
  }) => {
2613
- const { state: m } = B(X), { state: u } = B(De), f = O(null), p = O(null), b = Ga([s, p]), v = Ja(), y = xo({
2578
+ const { state: m } = z(se), { state: u } = z(Ve), h = M(null), p = M(null), y = Wa([s, p]), v = ja(), b = ko({
2614
2579
  className: e
2615
- }), [_, S] = Ka({
2580
+ }), [_, w] = Ga({
2616
2581
  value: r,
2617
2582
  initialControlledDelay: 20,
2618
2583
  defaultValue: a,
@@ -2623,7 +2588,7 @@ const fo = (e) => {
2623
2588
  }
2624
2589
  });
2625
2590
  }
2626
- }), N = K(() => {
2591
+ }), N = ne(() => {
2627
2592
  if (!p.current)
2628
2593
  return;
2629
2594
  p.current.style.height = "auto";
@@ -2634,21 +2599,21 @@ const fo = (e) => {
2634
2599
  }
2635
2600
  p.current.style.height = `${I}px`, p.current.style.overflowY = "hidden";
2636
2601
  }, [120]), k = (I) => {
2637
- p.current && (p.current.style.height = "24px"), o(I, _), S("");
2602
+ p.current && (p.current.style.height = "24px"), o(I, _), w("");
2638
2603
  }, C = (I) => {
2639
- S(I.target.value), N();
2604
+ w(I.target.value), N();
2640
2605
  };
2641
- return A(() => {
2606
+ return D(() => {
2642
2607
  m && m.usage === 0 && m.messages.length === 0 && p.current && (p.current.style.height = "24px");
2643
- }, [m]), A(() => {
2608
+ }, [m]), D(() => {
2644
2609
  u.lastTriggeredTimestamp && setTimeout(() => {
2645
2610
  N();
2646
2611
  }, 100);
2647
2612
  }, [u.lastTriggeredTimestamp, N]), /* @__PURE__ */ i(
2648
2613
  "div",
2649
2614
  {
2650
- className: y.wrapper,
2651
- ref: f,
2615
+ className: b.wrapper,
2616
+ ref: h,
2652
2617
  ...c,
2653
2618
  children: /* @__PURE__ */ x("form", { onSubmit: k, children: [
2654
2619
  /* @__PURE__ */ i("div", { id: v, className: "sr-only", children: t }),
@@ -2657,47 +2622,47 @@ const fo = (e) => {
2657
2622
  {
2658
2623
  required: !0,
2659
2624
  rows: 1,
2660
- ref: b,
2625
+ ref: y,
2661
2626
  placeholder: "Type your question here.",
2662
2627
  translate: "no",
2663
2628
  onChange: C,
2664
2629
  value: _,
2665
- onKeyDown: Ua([["mod+Enter", k]]),
2666
- className: y.textArea,
2630
+ onKeyDown: Pa([["mod+Enter", k]]),
2631
+ className: b.textArea,
2667
2632
  "aria-labelledby": v
2668
2633
  }
2669
2634
  ) }),
2670
2635
  /* @__PURE__ */ x("div", { className: "p-2 flex items-center", children: [
2671
- /* @__PURE__ */ i(bo, { className: "order-4 ml-auto" }),
2672
- /* @__PURE__ */ i(ho, { className: "order-1 mr-4" }),
2673
- /* @__PURE__ */ i(po, { className: "order-2 mr-2" }),
2674
- /* @__PURE__ */ i(yo, { className: "order-3" })
2636
+ /* @__PURE__ */ i(ho, { className: "order-4 ml-auto" }),
2637
+ /* @__PURE__ */ i(uo, { className: "order-1 mr-4" }),
2638
+ /* @__PURE__ */ i(go, { className: "order-2 mr-2" }),
2639
+ /* @__PURE__ */ i(fo, { className: "order-3" })
2675
2640
  ] })
2676
2641
  ] })
2677
2642
  }
2678
2643
  );
2679
- }, Le = (e, t) => {
2644
+ }, Ie = (e, t) => {
2680
2645
  e({
2681
- type: lr,
2646
+ type: cr,
2682
2647
  payload: {
2683
2648
  streaming: t
2684
2649
  }
2685
2650
  });
2686
- }, nr = (e) => {
2687
- Le(e, !1), e({
2651
+ }, ar = (e) => {
2652
+ Ie(e, !1), e({
2688
2653
  type: ye,
2689
2654
  payload: {
2690
2655
  message: {
2691
2656
  role: pt,
2692
- content: ra
2657
+ content: ta
2693
2658
  }
2694
2659
  }
2695
2660
  });
2696
- }, wo = () => {
2697
- const { state: e, dispatch: t } = B(X), { state: r, dispatch: a } = B(De), [n, o] = W(""), { getAccessToken: s, user: c } = xe(), g = O(null), d = O(
2661
+ }, Eo = () => {
2662
+ const { state: e, dispatch: t } = z(se), { state: r, dispatch: a } = z(Ve), [n, o] = q(""), { getAccessToken: s, user: c } = Ee(), g = M(null), d = M(
2698
2663
  null
2699
2664
  );
2700
- A(() => {
2665
+ D(() => {
2701
2666
  (async () => {
2702
2667
  var u;
2703
2668
  if (!e || e.messages.length === 0) {
@@ -2705,9 +2670,9 @@ const fo = (e) => {
2705
2670
  return;
2706
2671
  }
2707
2672
  const m = e.messages[e.messages.length - 1];
2708
- if (!(e.messages.length === 0 || m.message.role === ve || m.message.role === Qr || m.message.role === pt || m.message.role === ea))
2673
+ if (!(e.messages.length === 0 || m.message.role === ve || m.message.role === Xr || m.message.role === pt || m.message.role === Qr))
2709
2674
  try {
2710
- const f = await oo({
2675
+ const h = await ro({
2711
2676
  accessToken: await s(),
2712
2677
  name: "generate",
2713
2678
  data: {
@@ -2718,24 +2683,24 @@ const fo = (e) => {
2718
2683
  usage: e.usage
2719
2684
  }
2720
2685
  });
2721
- if (f && f.ok) {
2722
- const p = _t();
2723
- d.current = f.body.getReader();
2724
- const b = new TextDecoder();
2686
+ if (h && h.ok) {
2687
+ const p = kt();
2688
+ d.current = h.body.getReader();
2689
+ const y = new TextDecoder();
2725
2690
  for (; ; ) {
2726
- Le(t, !0);
2727
- const { done: v, value: y } = await d.current.read();
2691
+ Ie(t, !0);
2692
+ const { done: v, value: b } = await d.current.read();
2728
2693
  if (v) {
2729
- Le(t, !1);
2694
+ Ie(t, !1);
2730
2695
  break;
2731
2696
  }
2732
- const _ = b.decode(y, { stream: !0 }), S = _.indexOf(Dt);
2733
- if (S !== -1) {
2734
- const N = _.substring(0, S), k = JSON.parse(
2735
- _.substring(S + Dt.length)
2697
+ const _ = y.decode(b, { stream: !0 }), w = _.indexOf($t);
2698
+ if (w !== -1) {
2699
+ const N = _.substring(0, w), k = JSON.parse(
2700
+ _.substring(w + $t.length)
2736
2701
  );
2737
2702
  t({
2738
- type: cr,
2703
+ type: ir,
2739
2704
  payload: {
2740
2705
  model: k.model,
2741
2706
  usage: k.usage
@@ -2751,7 +2716,7 @@ const fo = (e) => {
2751
2716
  name: k.name
2752
2717
  }
2753
2718
  }
2754
- }), Le(t, !1);
2719
+ }), Ie(t, !1);
2755
2720
  break;
2756
2721
  } else
2757
2722
  t({
@@ -2766,69 +2731,99 @@ const fo = (e) => {
2766
2731
  });
2767
2732
  }
2768
2733
  } else
2769
- nr(t);
2770
- } catch (f) {
2771
- console.error(f), nr(t);
2734
+ ar(t);
2735
+ } catch (h) {
2736
+ console.error(h), ar(t);
2772
2737
  }
2773
2738
  })();
2774
2739
  }, [e == null ? void 0 : e.messages]);
2775
- const h = async (m) => {
2740
+ const f = async (m) => {
2776
2741
  m.preventDefault(), t({
2777
2742
  type: ye,
2778
2743
  payload: {
2779
2744
  message: {
2780
- role: Qe,
2745
+ role: et,
2781
2746
  content: n
2782
2747
  }
2783
2748
  }
2784
2749
  }), o("");
2785
2750
  };
2786
- return A(() => {
2751
+ return D(() => {
2787
2752
  if (r.prompt !== "") {
2788
2753
  const m = r.prompt.endsWith(":") && !r.prompt.endsWith(": ") ? r.prompt + " " : r.prompt;
2789
- m.indexOf(Vt) !== -1 ? navigator.clipboard.readText().then((f) => {
2790
- o(m.replace(Vt, f));
2754
+ m.indexOf(Dt) !== -1 ? navigator.clipboard.readText().then((h) => {
2755
+ o(m.replace(Dt, h));
2791
2756
  }) : o(m), g.current && g.current.focus(), a({
2792
- type: dr
2757
+ type: lr
2793
2758
  });
2794
2759
  }
2795
- }, [r, a]), A(() => {
2760
+ }, [r, a]), D(() => {
2796
2761
  e && e.usage === 0 && e.messages.length === 0 && (o(""), g.current && g.current.focus());
2797
- }, [e]), A(() => {
2762
+ }, [e]), D(() => {
2798
2763
  (e == null ? void 0 : e.streaming) === !1 && g.current && g.current.focus();
2799
- }, [e]), /* @__PURE__ */ i(ht, { children: /* @__PURE__ */ i(
2800
- So,
2764
+ }, [e]), /* @__PURE__ */ i(Ae, { children: /* @__PURE__ */ i(
2765
+ _o,
2801
2766
  {
2802
- label: ta,
2803
- onSubmit: h,
2767
+ label: ea,
2768
+ onSubmit: f,
2804
2769
  ref: g,
2805
2770
  value: n,
2806
2771
  onChange: (m) => o(m.target.value)
2807
2772
  }
2808
2773
  ) });
2809
- }, To = () => {
2810
- const { state: e } = B(X), t = O(!1), r = window.innerWidth < 403, [a, n] = W(
2774
+ }, xo = () => {
2775
+ const { state: e } = z(se), t = M(!1), r = window.innerWidth < 403, [a, n] = q(
2811
2776
  r ? "bottom-4" : "top-[245px]"
2812
2777
  );
2813
- return A(() => {
2778
+ return D(() => {
2814
2779
  r || e && (!t.current && e.streaming && n("bottom-4"), t.current = !!e.streaming);
2815
- }, [e, r]), A(() => {
2780
+ }, [e, r]), D(() => {
2816
2781
  r || (e && e.messages.length === 0 && n("top-[245px]"), e && !e.streaming && e.messages.length > 0 && n("bottom-4"));
2817
2782
  }, [e, r]), /* @__PURE__ */ x(
2818
2783
  "footer",
2819
2784
  {
2820
2785
  className: l(
2821
2786
  "px-2 sm:px-0 md:mx-auto md:max-w-4xl w-full fixed left-1/2 transform -translate-x-1/2",
2822
- uo,
2787
+ io,
2823
2788
  a
2824
2789
  ),
2825
2790
  children: [
2826
- /* @__PURE__ */ i(wo, {}),
2827
- /* @__PURE__ */ i("div", { className: "w-full text-center text-xs text-copy-lighter pt-2", children: aa })
2791
+ /* @__PURE__ */ i(Eo, {}),
2792
+ /* @__PURE__ */ i("div", { className: "w-full text-center text-xs text-copy-lighter pt-2", children: ra })
2828
2793
  ]
2829
2794
  }
2830
2795
  );
2831
- };
2796
+ }, wo = ({ show: e }) => e ? /* @__PURE__ */ i(
2797
+ "div",
2798
+ {
2799
+ className: l(
2800
+ co,
2801
+ "bottom-44 fixed left-1/2 transform -translate-x-1/2"
2802
+ ),
2803
+ children: /* @__PURE__ */ i(
2804
+ "button",
2805
+ {
2806
+ className: "av-button not-prose truncate text-copy-light rounded-full inline-flex items-center justify-center h-8 w-8 p-1 border border-transparent focus:outline focus:outline-2 focus:outline-offset-2 focus:outline-focus-dark dark:focus:outline-focus-light disabled:opacity-50 dark:bg-slate-50 bg-slate-500 disabled:cursor-auto",
2807
+ disabled: !0,
2808
+ type: "button",
2809
+ "aria-label": "Scroll to bottom",
2810
+ children: /* @__PURE__ */ i("div", { className: "text-copy-light", children: /* @__PURE__ */ i(
2811
+ "svg",
2812
+ {
2813
+ xmlns: "http://www.w3.org/2000/svg",
2814
+ className: "size-4 dark:text-copy-dark text-copy-lighter",
2815
+ viewBox: "0 0 384 512",
2816
+ fill: "currentColor",
2817
+ role: "img",
2818
+ "aria-hidden": "true",
2819
+ focusable: "false",
2820
+ children: /* @__PURE__ */ i("path", { d: "M174.6 472.6c4.5 4.7 10.8 7.4 17.4 7.4s12.8-2.7 17.4-7.4l168-176c9.2-9.6 8.8-24.8-.8-33.9s-24.8-8.8-33.9 .8L216 396.1 216 56c0-13.3-10.7-24-24-24s-24 10.7-24 24l0 340.1L41.4 263.4c-9.2-9.6-24.3-9.9-33.9-.8s-9.9 24.3-.8 33.9l168 176z" })
2821
+ }
2822
+ ) })
2823
+ }
2824
+ )
2825
+ }
2826
+ ) : null;
2832
2827
  /*!
2833
2828
  @versini/ui-bubble v3.1.7
2834
2829
  © 2025 gizmette.com
@@ -2842,7 +2837,7 @@ try {
2842
2837
  });
2843
2838
  } catch {
2844
2839
  }
2845
- const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link", Co = ({
2840
+ const So = "av-bubble", nr = "av-button", Pe = "icon", zr = "button", gt = "link", To = ({
2846
2841
  type: e,
2847
2842
  size: t,
2848
2843
  labelRight: r,
@@ -2851,14 +2846,14 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2851
2846
  }) => {
2852
2847
  const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", c = "max-h-12 py-2 px-4";
2853
2848
  switch (e) {
2854
- case $r:
2855
- case mt:
2849
+ case zr:
2850
+ case gt:
2856
2851
  return l({
2857
2852
  [o]: t === "small",
2858
2853
  [s]: t === "medium",
2859
2854
  [c]: t === "large"
2860
2855
  });
2861
- case Ve:
2856
+ case Pe:
2862
2857
  return l("inline-flex items-center", {
2863
2858
  "justify-center": n === "center",
2864
2859
  "justify-start": n === "left",
@@ -2871,7 +2866,7 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2871
2866
  "h-12 px-4": t === "large" && (r || a)
2872
2867
  });
2873
2868
  }
2874
- }, Ro = ({
2869
+ }, No = ({
2875
2870
  type: e,
2876
2871
  size: t,
2877
2872
  labelRight: r,
@@ -2879,22 +2874,22 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2879
2874
  }) => {
2880
2875
  const n = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
2881
2876
  switch (e) {
2882
- case $r:
2883
- case mt:
2877
+ case zr:
2878
+ case gt:
2884
2879
  return l({
2885
- "text-center": e === mt,
2880
+ "text-center": e === gt,
2886
2881
  [n]: t === "small",
2887
2882
  [o]: t === "medium",
2888
2883
  [s]: t === "large"
2889
2884
  });
2890
- case Ve:
2885
+ case Pe:
2891
2886
  return l({
2892
2887
  [n]: t === "small" && (r || a),
2893
2888
  [o]: t === "medium" && (r || a),
2894
2889
  [s]: t === "large" && (r || a)
2895
2890
  });
2896
2891
  }
2897
- }, Io = ({
2892
+ }, Co = ({
2898
2893
  mode: e,
2899
2894
  noBackground: t,
2900
2895
  noTruncate: r,
@@ -2930,7 +2925,7 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2930
2925
  return l("not-prose text-copy-lighter", {
2931
2926
  truncate: !r
2932
2927
  });
2933
- }, Lo = ({
2928
+ }, Ro = ({
2934
2929
  mode: e,
2935
2930
  noBackground: t,
2936
2931
  variant: r
@@ -2960,13 +2955,13 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2960
2955
  if (r === "selected")
2961
2956
  return "bg-action-selected-dark";
2962
2957
  }
2963
- }, Ao = ({
2958
+ }, Io = ({
2964
2959
  radius: e
2965
2960
  }) => l({
2966
2961
  "rounded-full": e === "large",
2967
2962
  "rounded-md": e === "medium",
2968
2963
  "rounded-sm": e === "small"
2969
- }), Oo = ({
2964
+ }), Lo = ({
2970
2965
  mode: e,
2971
2966
  disabled: t,
2972
2967
  variant: r
@@ -2996,7 +2991,7 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
2996
2991
  });
2997
2992
  if (r === "selected")
2998
2993
  return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
2999
- }, Bo = ({
2994
+ }, Ao = ({
3000
2995
  mode: e,
3001
2996
  disabled: t,
3002
2997
  variant: r
@@ -3026,7 +3021,7 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
3026
3021
  });
3027
3022
  if (r === "selected")
3028
3023
  return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
3029
- }, Mo = ({
3024
+ }, Oo = ({
3030
3025
  mode: e,
3031
3026
  noBorder: t,
3032
3027
  variant: r
@@ -3056,14 +3051,14 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
3056
3051
  });
3057
3052
  if (r === "selected")
3058
3053
  return "border border-border-selected-dark";
3059
- }, zo = ({
3054
+ }, Bo = ({
3060
3055
  focusMode: e
3061
3056
  }) => l("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
3062
3057
  "focus:outline-focus-dark": e === "dark",
3063
3058
  "focus:outline-focus-light": e === "light",
3064
3059
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
3065
3060
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
3066
- }), Dr = ({
3061
+ }), $r = ({
3067
3062
  type: e,
3068
3063
  className: t,
3069
3064
  raw: r,
@@ -3074,57 +3069,57 @@ const No = "av-bubble", or = "av-button", Ve = "icon", $r = "button", mt = "link
3074
3069
  size: c,
3075
3070
  noBorder: g,
3076
3071
  labelRight: d,
3077
- labelLeft: h,
3072
+ labelLeft: f,
3078
3073
  noBackground: m,
3079
3074
  variant: u,
3080
- noTruncate: f,
3075
+ noTruncate: h,
3081
3076
  align: p,
3082
- radius: b
3083
- }) => (u || (u = "primary"), r ? l(or, t) : l(
3084
- or,
3085
- Io({
3077
+ radius: y
3078
+ }) => (u || (u = "primary"), r ? l(nr, t) : l(
3079
+ nr,
3080
+ Co({
3086
3081
  mode: a,
3087
3082
  variant: u,
3088
3083
  noBackground: m,
3089
- noTruncate: f
3084
+ noTruncate: h
3090
3085
  }),
3091
- Lo({ mode: a, noBackground: m, variant: u }),
3092
- Ao({ radius: b }),
3093
- Co({
3086
+ Ro({ mode: a, noBackground: m, variant: u }),
3087
+ Io({ radius: y }),
3088
+ To({
3094
3089
  type: e,
3095
3090
  size: c,
3096
3091
  labelRight: d,
3097
- labelLeft: h,
3092
+ labelLeft: f,
3098
3093
  align: p
3099
3094
  }),
3100
- Ro({ type: e, size: c, labelRight: d, labelLeft: h }),
3101
- Mo({ mode: a, variant: u, noBorder: g }),
3102
- zo({ focusMode: n }),
3103
- Oo({ mode: a, variant: u, disabled: o }),
3104
- Bo({ mode: a, variant: u, disabled: o }),
3095
+ No({ type: e, size: c, labelRight: d, labelLeft: f }),
3096
+ Oo({ mode: a, variant: u, noBorder: g }),
3097
+ Bo({ focusMode: n }),
3098
+ Lo({ mode: a, variant: u, disabled: o }),
3099
+ Ao({ mode: a, variant: u, disabled: o }),
3105
3100
  {
3106
3101
  "w-full": s,
3107
3102
  "disabled:cursor-not-allowed disabled:opacity-50": o
3108
3103
  },
3109
3104
  t
3110
- )), $o = (e, t, r) => {
3105
+ )), Mo = (e, t, r) => {
3111
3106
  var a;
3112
3107
  !t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
3113
- }, Tt = M.forwardRef((e, t) => {
3108
+ }, St = A.forwardRef((e, t) => {
3114
3109
  const { onClick: r, noInternalClick: a = !1, ...n } = e;
3115
3110
  return /* @__PURE__ */ i(
3116
3111
  "button",
3117
3112
  {
3118
3113
  ref: t,
3119
3114
  onClick: (o) => {
3120
- $o(o, a, r);
3115
+ Mo(o, a, r);
3121
3116
  },
3122
3117
  ...n
3123
3118
  }
3124
3119
  );
3125
3120
  });
3126
- Tt.displayName = "BaseButton";
3127
- const Vr = M.forwardRef(
3121
+ St.displayName = "BaseButton";
3122
+ const Dr = A.forwardRef(
3128
3123
  ({
3129
3124
  children: e,
3130
3125
  disabled: t = !1,
@@ -3136,18 +3131,18 @@ const Vr = M.forwardRef(
3136
3131
  raw: c = !1,
3137
3132
  noBorder: g = !1,
3138
3133
  "aria-label": d,
3139
- label: h,
3134
+ label: f,
3140
3135
  size: m = "medium",
3141
3136
  labelRight: u,
3142
- labelLeft: f,
3137
+ labelLeft: h,
3143
3138
  noBackground: p = !1,
3144
- align: b = "center",
3139
+ align: y = "center",
3145
3140
  radius: v = "large",
3146
- variant: y = "primary",
3141
+ variant: b = "primary",
3147
3142
  ..._
3148
- }, S) => {
3149
- const N = Dr({
3150
- type: Ve,
3143
+ }, w) => {
3144
+ const N = $r({
3145
+ type: Pe,
3151
3146
  mode: r,
3152
3147
  focusMode: a,
3153
3148
  fullWidth: n,
@@ -3157,11 +3152,11 @@ const Vr = M.forwardRef(
3157
3152
  noBorder: g,
3158
3153
  size: m,
3159
3154
  labelRight: u,
3160
- labelLeft: f,
3155
+ labelLeft: h,
3161
3156
  noBackground: p,
3162
- align: b,
3157
+ align: y,
3163
3158
  radius: v,
3164
- variant: y
3159
+ variant: b
3165
3160
  }), k = l({
3166
3161
  "text-copy-accent-dark": (r === "light" || r === "alt-system") && !c,
3167
3162
  "text-copy-light": (r === "dark" || r === "system") && !c,
@@ -3169,16 +3164,16 @@ const Vr = M.forwardRef(
3169
3164
  "dark:text-copy-accent-dark": r === "system" && !c
3170
3165
  });
3171
3166
  return /* @__PURE__ */ x(
3172
- Tt,
3167
+ St,
3173
3168
  {
3174
- ref: S,
3169
+ ref: w,
3175
3170
  className: N,
3176
3171
  disabled: t,
3177
3172
  type: s,
3178
- "aria-label": d || h,
3173
+ "aria-label": d || f,
3179
3174
  ..._,
3180
3175
  children: [
3181
- f && /* @__PURE__ */ i("span", { className: "pr-2", children: f }),
3176
+ h && /* @__PURE__ */ i("span", { className: "pr-2", children: h }),
3182
3177
  /* @__PURE__ */ i("div", { className: k, children: e }),
3183
3178
  u && /* @__PURE__ */ i("span", { className: "pl-2", children: u })
3184
3179
  ]
@@ -3186,7 +3181,7 @@ const Vr = M.forwardRef(
3186
3181
  );
3187
3182
  }
3188
3183
  );
3189
- Vr.displayName = "ButtonIcon";
3184
+ Dr.displayName = "ButtonIcon";
3190
3185
  /*!
3191
3186
  @versini/ui-button v4.0.10
3192
3187
  © 2025 gizmette.com
@@ -3200,7 +3195,7 @@ try {
3200
3195
  });
3201
3196
  } catch {
3202
3197
  }
3203
- const Do = M.forwardRef(
3198
+ const zo = A.forwardRef(
3204
3199
  ({
3205
3200
  children: e,
3206
3201
  disabled: t = !1,
@@ -3212,18 +3207,18 @@ const Do = M.forwardRef(
3212
3207
  raw: c = !1,
3213
3208
  noBorder: g = !1,
3214
3209
  "aria-label": d,
3215
- label: h,
3210
+ label: f,
3216
3211
  size: m = "medium",
3217
3212
  labelRight: u,
3218
- labelLeft: f,
3213
+ labelLeft: h,
3219
3214
  noBackground: p = !1,
3220
- align: b = "center",
3215
+ align: y = "center",
3221
3216
  active: v = !1,
3222
- radius: y = "large",
3217
+ radius: b = "large",
3223
3218
  ..._
3224
- }, S) => {
3225
- const N = Dr({
3226
- type: Ve,
3219
+ }, w) => {
3220
+ const N = $r({
3221
+ type: Pe,
3227
3222
  mode: r,
3228
3223
  focusMode: a,
3229
3224
  fullWidth: n,
@@ -3233,10 +3228,10 @@ const Do = M.forwardRef(
3233
3228
  noBorder: g,
3234
3229
  size: m,
3235
3230
  labelRight: u,
3236
- labelLeft: f,
3231
+ labelLeft: h,
3237
3232
  noBackground: p,
3238
- align: b,
3239
- radius: y
3233
+ align: y,
3234
+ radius: b
3240
3235
  }), k = l({
3241
3236
  "text-copy-accent-dark": r === "light" && !c,
3242
3237
  "text-copy-light": r === "dark" && !c,
@@ -3260,16 +3255,16 @@ const Do = M.forwardRef(
3260
3255
  }
3261
3256
  ) : "";
3262
3257
  return /* @__PURE__ */ i("div", { className: C, children: /* @__PURE__ */ x(
3263
- Tt,
3258
+ St,
3264
3259
  {
3265
- ref: S,
3260
+ ref: w,
3266
3261
  className: N,
3267
3262
  disabled: t,
3268
3263
  type: s,
3269
- "aria-label": d || h,
3264
+ "aria-label": d || f,
3270
3265
  ..._,
3271
3266
  children: [
3272
- f && /* @__PURE__ */ i("span", { className: "pr-2", children: f }),
3267
+ h && /* @__PURE__ */ i("span", { className: "pr-2", children: h }),
3273
3268
  /* @__PURE__ */ i("div", { className: k, children: e }),
3274
3269
  u && /* @__PURE__ */ i("span", { className: "pl-2", children: u })
3275
3270
  ]
@@ -3277,8 +3272,8 @@ const Do = M.forwardRef(
3277
3272
  ) });
3278
3273
  }
3279
3274
  );
3280
- Do.displayName = "ButtonSort";
3281
- const Pr = ({
3275
+ zo.displayName = "ButtonSort";
3276
+ const Vr = ({
3282
3277
  children: e,
3283
3278
  fill: t,
3284
3279
  viewBox: r,
@@ -3290,7 +3285,7 @@ const Pr = ({
3290
3285
  ...g
3291
3286
  }) => {
3292
3287
  const d = l(o, a);
3293
- return /* @__PURE__ */ x(ht, { children: [
3288
+ return /* @__PURE__ */ x(Ae, { children: [
3294
3289
  /* @__PURE__ */ i(
3295
3290
  "svg",
3296
3291
  {
@@ -3321,14 +3316,14 @@ try {
3321
3316
  });
3322
3317
  } catch {
3323
3318
  }
3324
- const Vo = ({
3319
+ const $o = ({
3325
3320
  className: e,
3326
3321
  viewBox: t,
3327
3322
  title: r,
3328
3323
  monotone: a,
3329
3324
  ...n
3330
3325
  }) => /* @__PURE__ */ x(
3331
- Pr,
3326
+ Vr,
3332
3327
  {
3333
3328
  defaultViewBox: "0 0 448 512",
3334
3329
  size: "size-5",
@@ -3354,14 +3349,14 @@ const Vo = ({
3354
3349
  )
3355
3350
  ]
3356
3351
  }
3357
- ), Po = ({
3352
+ ), Do = ({
3358
3353
  className: e,
3359
3354
  viewBox: t,
3360
3355
  title: r,
3361
3356
  monotone: a,
3362
3357
  ...n
3363
3358
  }) => /* @__PURE__ */ i(
3364
- Pr,
3359
+ Vr,
3365
3360
  {
3366
3361
  defaultViewBox: "0 0 512 512",
3367
3362
  size: "size-5",
@@ -3385,30 +3380,30 @@ try {
3385
3380
  });
3386
3381
  } catch {
3387
3382
  }
3388
- const Uo = ({
3383
+ const Vo = ({
3389
3384
  kind: e,
3390
3385
  noMaxWidth: t
3391
3386
  }) => l("p-4", {
3392
3387
  "max-w-xs sm:max-w-md md:max-w-2xl": !t,
3393
3388
  "lg:max-w-3xl": e === "left" && !t
3394
- }), Fo = ({ kind: e }) => l({
3389
+ }), Po = ({ kind: e }) => l({
3395
3390
  "bg-surface-lighter dark:bg-surface-dark": e === "left",
3396
3391
  "bg-surface-accent": e === "right"
3397
- }), Ho = ({ kind: e }) => l(
3392
+ }), Uo = ({ kind: e }) => l(
3398
3393
  "prose prose-dark dark:prose-lighter prose-p:my-3 prose-blockquote:my-3 prose-ol:my-3 prose-ul:my-3 prose-ul:prose-li:marker:text-black",
3399
3394
  {
3400
3395
  "text-copy-lighter": e === "right"
3401
3396
  }
3402
- ), Wo = ({ kind: e }) => l("rounded-b-xl", {
3397
+ ), Fo = ({ kind: e }) => l("rounded-b-xl", {
3403
3398
  "rounded-tr-xl": e === "left",
3404
3399
  "rounded-tl-xl": e === "right"
3405
- }), Go = ({
3400
+ }), Ho = ({
3406
3401
  kind: e,
3407
3402
  className: t,
3408
3403
  noMaxWidth: r
3409
3404
  }) => {
3410
3405
  const a = l(
3411
- No,
3406
+ So,
3412
3407
  "flex items-start",
3413
3408
  {
3414
3409
  "flex-row-reverse": e === "right"
@@ -3416,10 +3411,10 @@ const Uo = ({
3416
3411
  t
3417
3412
  ), n = l(
3418
3413
  "flex flex-col empty:hidden",
3419
- Uo({ kind: e, noMaxWidth: r }),
3420
- Ho({ kind: e }),
3421
- Fo({ kind: e }),
3422
- Wo({ kind: e })
3414
+ Vo({ kind: e, noMaxWidth: r }),
3415
+ Uo({ kind: e }),
3416
+ Po({ kind: e }),
3417
+ Fo({ kind: e })
3423
3418
  ), o = "pr-2 pt-1 text-end text-xs text-copy-light", s = l("flex flex-col-reverse gap-2 sm:flex-row", {
3424
3419
  "ml-2": e === "left",
3425
3420
  "mr-2": e === "right"
@@ -3430,7 +3425,7 @@ const Uo = ({
3430
3425
  footer: o,
3431
3426
  copyButton: s
3432
3427
  };
3433
- }, jo = ({
3428
+ }, Wo = ({
3434
3429
  children: e,
3435
3430
  kind: t = "left",
3436
3431
  className: r,
@@ -3441,13 +3436,13 @@ const Uo = ({
3441
3436
  copyToClipboardMode: c = "system",
3442
3437
  noMaxWidth: g = !1
3443
3438
  }) => {
3444
- const [d, h] = W(!1), m = Go({ kind: t, className: r, noMaxWidth: g }), u = !!o && (typeof o == "function" || typeof o == "string" || typeof e == "string"), f = () => {
3445
- h(!0), typeof o == "function" ? o(e) : typeof o == "string" ? navigator.clipboard.writeText(o) : typeof e == "string" && navigator.clipboard.writeText(e);
3439
+ const [d, f] = q(!1), m = Ho({ kind: t, className: r, noMaxWidth: g }), u = !!o && (typeof o == "function" || typeof o == "string" || typeof e == "string"), h = () => {
3440
+ f(!0), typeof o == "function" ? o(e) : typeof o == "string" ? navigator.clipboard.writeText(o) : typeof e == "string" && navigator.clipboard.writeText(e);
3446
3441
  };
3447
- return A(() => {
3442
+ return D(() => {
3448
3443
  let p;
3449
3444
  return d && (p = window.setTimeout(() => {
3450
- h(!1);
3445
+ f(!1);
3451
3446
  }, 3e3)), () => {
3452
3447
  clearTimeout(p);
3453
3448
  };
@@ -3462,7 +3457,7 @@ const Uo = ({
3462
3457
  n && n
3463
3458
  ] }),
3464
3459
  u && /* @__PURE__ */ i("div", { className: m.copyButton, children: /* @__PURE__ */ i(
3465
- Vr,
3460
+ Dr,
3466
3461
  {
3467
3462
  noBorder: !0,
3468
3463
  noBackground: !0,
@@ -3470,13 +3465,13 @@ const Uo = ({
3470
3465
  mode: c,
3471
3466
  focusMode: s,
3472
3467
  label: d ? "Copied to clipboard" : "Copy to clipboard",
3473
- onClick: f,
3468
+ onClick: h,
3474
3469
  disabled: d,
3475
- children: d ? /* @__PURE__ */ i(Vo, { size: "size-3" }) : /* @__PURE__ */ i(Po, { size: "size-3" })
3470
+ children: d ? /* @__PURE__ */ i($o, { size: "size-3" }) : /* @__PURE__ */ i(Do, { size: "size-3" })
3476
3471
  }
3477
3472
  ) })
3478
3473
  ] });
3479
- }, sr = "av-button", Nt = "icon", Ct = "button", gt = "link", qo = ({
3474
+ }, or = "av-button", Tt = "icon", Nt = "button", ht = "link", Go = ({
3480
3475
  type: e,
3481
3476
  size: t,
3482
3477
  labelRight: r,
@@ -3485,14 +3480,14 @@ const Uo = ({
3485
3480
  }) => {
3486
3481
  const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", c = "max-h-12 py-2 px-4";
3487
3482
  switch (e) {
3488
- case Ct:
3489
- case gt:
3483
+ case Nt:
3484
+ case ht:
3490
3485
  return l({
3491
3486
  [o]: t === "small",
3492
3487
  [s]: t === "medium",
3493
3488
  [c]: t === "large"
3494
3489
  });
3495
- case Nt:
3490
+ case Tt:
3496
3491
  return l("inline-flex items-center", {
3497
3492
  "justify-center": n === "center",
3498
3493
  "justify-start": n === "left",
@@ -3505,7 +3500,7 @@ const Uo = ({
3505
3500
  "h-12 px-4": t === "large" && (r || a)
3506
3501
  });
3507
3502
  }
3508
- }, Ko = ({
3503
+ }, jo = ({
3509
3504
  type: e,
3510
3505
  size: t,
3511
3506
  labelRight: r,
@@ -3513,22 +3508,22 @@ const Uo = ({
3513
3508
  }) => {
3514
3509
  const n = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
3515
3510
  switch (e) {
3516
- case Ct:
3517
- case gt:
3511
+ case Nt:
3512
+ case ht:
3518
3513
  return l({
3519
- "text-center": e === gt,
3514
+ "text-center": e === ht,
3520
3515
  [n]: t === "small",
3521
3516
  [o]: t === "medium",
3522
3517
  [s]: t === "large"
3523
3518
  });
3524
- case Nt:
3519
+ case Tt:
3525
3520
  return l({
3526
3521
  [n]: t === "small" && (r || a),
3527
3522
  [o]: t === "medium" && (r || a),
3528
3523
  [s]: t === "large" && (r || a)
3529
3524
  });
3530
3525
  }
3531
- }, Jo = ({
3526
+ }, qo = ({
3532
3527
  mode: e,
3533
3528
  noBackground: t,
3534
3529
  noTruncate: r,
@@ -3564,7 +3559,7 @@ const Uo = ({
3564
3559
  return l("not-prose text-copy-lighter", {
3565
3560
  truncate: !r
3566
3561
  });
3567
- }, Yo = ({
3562
+ }, Ko = ({
3568
3563
  mode: e,
3569
3564
  noBackground: t,
3570
3565
  variant: r
@@ -3594,13 +3589,13 @@ const Uo = ({
3594
3589
  if (r === "selected")
3595
3590
  return "bg-action-selected-dark";
3596
3591
  }
3597
- }, Zo = ({
3592
+ }, Jo = ({
3598
3593
  radius: e
3599
3594
  }) => l({
3600
3595
  "rounded-full": e === "large",
3601
3596
  "rounded-md": e === "medium",
3602
3597
  "rounded-sm": e === "small"
3603
- }), Xo = ({
3598
+ }), Yo = ({
3604
3599
  mode: e,
3605
3600
  disabled: t,
3606
3601
  variant: r
@@ -3630,7 +3625,7 @@ const Uo = ({
3630
3625
  });
3631
3626
  if (r === "selected")
3632
3627
  return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
3633
- }, Qo = ({
3628
+ }, Zo = ({
3634
3629
  mode: e,
3635
3630
  disabled: t,
3636
3631
  variant: r
@@ -3660,7 +3655,7 @@ const Uo = ({
3660
3655
  });
3661
3656
  if (r === "selected")
3662
3657
  return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
3663
- }, es = ({
3658
+ }, Xo = ({
3664
3659
  mode: e,
3665
3660
  noBorder: t,
3666
3661
  variant: r
@@ -3690,14 +3685,14 @@ const Uo = ({
3690
3685
  });
3691
3686
  if (r === "selected")
3692
3687
  return "border border-border-selected-dark";
3693
- }, ts = ({
3688
+ }, Qo = ({
3694
3689
  focusMode: e
3695
3690
  }) => l("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
3696
3691
  "focus:outline-focus-dark": e === "dark",
3697
3692
  "focus:outline-focus-light": e === "light",
3698
3693
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
3699
3694
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
3700
- }), Ur = ({
3695
+ }), Pr = ({
3701
3696
  type: e,
3702
3697
  className: t,
3703
3698
  raw: r,
@@ -3708,57 +3703,57 @@ const Uo = ({
3708
3703
  size: c,
3709
3704
  noBorder: g,
3710
3705
  labelRight: d,
3711
- labelLeft: h,
3706
+ labelLeft: f,
3712
3707
  noBackground: m,
3713
3708
  variant: u,
3714
- noTruncate: f,
3709
+ noTruncate: h,
3715
3710
  align: p,
3716
- radius: b
3717
- }) => (u || (u = "primary"), r ? l(sr, t) : l(
3718
- sr,
3719
- Jo({
3711
+ radius: y
3712
+ }) => (u || (u = "primary"), r ? l(or, t) : l(
3713
+ or,
3714
+ qo({
3720
3715
  mode: a,
3721
3716
  variant: u,
3722
3717
  noBackground: m,
3723
- noTruncate: f
3718
+ noTruncate: h
3724
3719
  }),
3725
- Yo({ mode: a, noBackground: m, variant: u }),
3726
- Zo({ radius: b }),
3727
- qo({
3720
+ Ko({ mode: a, noBackground: m, variant: u }),
3721
+ Jo({ radius: y }),
3722
+ Go({
3728
3723
  type: e,
3729
3724
  size: c,
3730
3725
  labelRight: d,
3731
- labelLeft: h,
3726
+ labelLeft: f,
3732
3727
  align: p
3733
3728
  }),
3734
- Ko({ type: e, size: c, labelRight: d, labelLeft: h }),
3735
- es({ mode: a, variant: u, noBorder: g }),
3736
- ts({ focusMode: n }),
3737
- Xo({ mode: a, variant: u, disabled: o }),
3738
- Qo({ mode: a, variant: u, disabled: o }),
3729
+ jo({ type: e, size: c, labelRight: d, labelLeft: f }),
3730
+ Xo({ mode: a, variant: u, noBorder: g }),
3731
+ Qo({ focusMode: n }),
3732
+ Yo({ mode: a, variant: u, disabled: o }),
3733
+ Zo({ mode: a, variant: u, disabled: o }),
3739
3734
  {
3740
3735
  "w-full": s,
3741
3736
  "disabled:cursor-not-allowed disabled:opacity-50": o
3742
3737
  },
3743
3738
  t
3744
- )), rs = (e, t, r) => {
3739
+ )), es = (e, t, r) => {
3745
3740
  var a;
3746
3741
  !t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
3747
- }, Rt = M.forwardRef((e, t) => {
3742
+ }, Ct = A.forwardRef((e, t) => {
3748
3743
  const { onClick: r, noInternalClick: a = !1, ...n } = e;
3749
3744
  return /* @__PURE__ */ i(
3750
3745
  "button",
3751
3746
  {
3752
3747
  ref: t,
3753
3748
  onClick: (o) => {
3754
- rs(o, a, r);
3749
+ es(o, a, r);
3755
3750
  },
3756
3751
  ...n
3757
3752
  }
3758
3753
  );
3759
3754
  });
3760
- Rt.displayName = "BaseButton";
3761
- const Fr = M.forwardRef(
3755
+ Ct.displayName = "BaseButton";
3756
+ const Ur = A.forwardRef(
3762
3757
  ({
3763
3758
  children: e,
3764
3759
  disabled: t = !1,
@@ -3770,12 +3765,12 @@ const Fr = M.forwardRef(
3770
3765
  raw: c = !1,
3771
3766
  noBorder: g = !1,
3772
3767
  variant: d = "primary",
3773
- noTruncate: h = !1,
3768
+ noTruncate: f = !1,
3774
3769
  radius: m = "large",
3775
3770
  ...u
3776
- }, f) => {
3777
- const p = Ur({
3778
- type: Ct,
3771
+ }, h) => {
3772
+ const p = Pr({
3773
+ type: Nt,
3779
3774
  mode: r,
3780
3775
  focusMode: a,
3781
3776
  fullWidth: n,
@@ -3785,13 +3780,13 @@ const Fr = M.forwardRef(
3785
3780
  size: s,
3786
3781
  noBorder: g,
3787
3782
  variant: d,
3788
- noTruncate: h,
3783
+ noTruncate: f,
3789
3784
  radius: m
3790
3785
  });
3791
3786
  return /* @__PURE__ */ i(
3792
- Rt,
3787
+ Ct,
3793
3788
  {
3794
- ref: f,
3789
+ ref: h,
3795
3790
  className: p,
3796
3791
  disabled: t,
3797
3792
  ...u,
@@ -3800,7 +3795,7 @@ const Fr = M.forwardRef(
3800
3795
  );
3801
3796
  }
3802
3797
  );
3803
- Fr.displayName = "Button";
3798
+ Ur.displayName = "Button";
3804
3799
  /*!
3805
3800
  @versini/ui-button v4.0.10
3806
3801
  © 2025 gizmette.com
@@ -3814,7 +3809,7 @@ try {
3814
3809
  });
3815
3810
  } catch {
3816
3811
  }
3817
- const as = M.forwardRef(
3812
+ const ts = A.forwardRef(
3818
3813
  ({
3819
3814
  children: e,
3820
3815
  disabled: t = !1,
@@ -3826,18 +3821,18 @@ const as = M.forwardRef(
3826
3821
  raw: c = !1,
3827
3822
  noBorder: g = !1,
3828
3823
  "aria-label": d,
3829
- label: h,
3824
+ label: f,
3830
3825
  size: m = "medium",
3831
3826
  labelRight: u,
3832
- labelLeft: f,
3827
+ labelLeft: h,
3833
3828
  noBackground: p = !1,
3834
- align: b = "center",
3829
+ align: y = "center",
3835
3830
  active: v = !1,
3836
- radius: y = "large",
3831
+ radius: b = "large",
3837
3832
  ..._
3838
- }, S) => {
3839
- const N = Ur({
3840
- type: Nt,
3833
+ }, w) => {
3834
+ const N = Pr({
3835
+ type: Tt,
3841
3836
  mode: r,
3842
3837
  focusMode: a,
3843
3838
  fullWidth: n,
@@ -3847,10 +3842,10 @@ const as = M.forwardRef(
3847
3842
  noBorder: g,
3848
3843
  size: m,
3849
3844
  labelRight: u,
3850
- labelLeft: f,
3845
+ labelLeft: h,
3851
3846
  noBackground: p,
3852
- align: b,
3853
- radius: y
3847
+ align: y,
3848
+ radius: b
3854
3849
  }), k = l({
3855
3850
  "text-copy-accent-dark": r === "light" && !c,
3856
3851
  "text-copy-light": r === "dark" && !c,
@@ -3874,16 +3869,16 @@ const as = M.forwardRef(
3874
3869
  }
3875
3870
  ) : "";
3876
3871
  return /* @__PURE__ */ i("div", { className: C, children: /* @__PURE__ */ x(
3877
- Rt,
3872
+ Ct,
3878
3873
  {
3879
- ref: S,
3874
+ ref: w,
3880
3875
  className: N,
3881
3876
  disabled: t,
3882
3877
  type: s,
3883
- "aria-label": d || h,
3878
+ "aria-label": d || f,
3884
3879
  ..._,
3885
3880
  children: [
3886
- f && /* @__PURE__ */ i("span", { className: "pr-2", children: f }),
3881
+ h && /* @__PURE__ */ i("span", { className: "pr-2", children: h }),
3887
3882
  /* @__PURE__ */ i("div", { className: k, children: e }),
3888
3883
  u && /* @__PURE__ */ i("span", { className: "pl-2", children: u })
3889
3884
  ]
@@ -3891,10 +3886,10 @@ const as = M.forwardRef(
3891
3886
  ) });
3892
3887
  }
3893
3888
  );
3894
- as.displayName = "ButtonSort";
3895
- const ns = 200, os = ({
3889
+ ts.displayName = "ButtonSort";
3890
+ const rs = 200, as = ({
3896
3891
  string: e,
3897
- idealLength: t = ns
3892
+ idealLength: t = rs
3898
3893
  }) => {
3899
3894
  if (e.length <= t)
3900
3895
  return { string: e, isTruncated: !1 };
@@ -3905,23 +3900,23 @@ const ns = 200, os = ({
3905
3900
  string: e.slice(0, t + r),
3906
3901
  isTruncated: !0
3907
3902
  };
3908
- }, ss = ({
3903
+ }, ns = ({
3909
3904
  children: e,
3910
3905
  length: t = 200,
3911
3906
  mode: r = "system",
3912
3907
  focusMode: a = "system"
3913
3908
  }) => {
3914
- const [n, o] = W(!1);
3909
+ const [n, o] = q(!1);
3915
3910
  if (typeof e != "string")
3916
3911
  return e;
3917
- const { string: s, isTruncated: c } = os({
3912
+ const { string: s, isTruncated: c } = as({
3918
3913
  string: e,
3919
3914
  idealLength: t
3920
3915
  });
3921
3916
  return /* @__PURE__ */ x("span", { style: { wordBreak: "break-word" }, children: [
3922
3917
  n ? e : s,
3923
3918
  c && /* @__PURE__ */ i(
3924
- Fr,
3919
+ Ur,
3925
3920
  {
3926
3921
  mode: r,
3927
3922
  focusMode: a,
@@ -3948,205 +3943,153 @@ try {
3948
3943
  });
3949
3944
  } catch {
3950
3945
  }
3951
- const ir = hr(
3946
+ const sr = gr(
3952
3947
  () => import(
3953
3948
  /* webpackChunkName: "LazyMessageAssistant" */
3954
- "./MessageAssistant.wYO5jy_g.js"
3949
+ "./MessageAssistant.DA7hPd0S.js"
3955
3950
  ).then((e) => e.MessageAssistant)
3956
- ), is = () => {
3957
- const { state: e } = B(X);
3951
+ ), os = () => {
3952
+ const { state: e } = z(se);
3958
3953
  return /* @__PURE__ */ x("div", { className: "space-y-6 mt-2 @container", children: [
3959
3954
  e && e.messages.length > 0 && e.messages.map((t, r) => {
3960
3955
  const { role: a, content: n, name: o, processingTime: s } = t.message;
3961
- return (a === ve || a === pt) && n ? /* @__PURE__ */ i(tt, { fallback: /* @__PURE__ */ i("span", {}), children: /* @__PURE__ */ i(ir, { name: o, processingTime: s, children: n }) }, `${r}-${a}`) : a === Qe && n ? /* @__PURE__ */ i(
3962
- jo,
3956
+ return (a === ve || a === pt) && n ? /* @__PURE__ */ i(rt, { fallback: /* @__PURE__ */ i("span", {}), children: /* @__PURE__ */ i(sr, { name: o, processingTime: s, children: n }) }, `${r}-${a}`) : a === et && n ? /* @__PURE__ */ i(
3957
+ Wo,
3963
3958
  {
3964
3959
  kind: "right",
3965
3960
  copyToClipboard: n,
3966
3961
  copyToClipboardFocusMode: "light",
3967
- children: /* @__PURE__ */ i(ss, { mode: "light", focusMode: "light", children: n })
3962
+ children: /* @__PURE__ */ i(ns, { mode: "light", focusMode: "light", children: n })
3968
3963
  },
3969
3964
  `${r}-${a}`
3970
3965
  ) : null;
3971
3966
  }),
3972
- na(Qe, e) && /* @__PURE__ */ i(tt, { fallback: /* @__PURE__ */ i("span", {}), children: /* @__PURE__ */ i(ir, { loading: !0 }) })
3967
+ aa(et, e) && /* @__PURE__ */ i(rt, { fallback: /* @__PURE__ */ i("span", {}), children: /* @__PURE__ */ i(sr, { loading: !0 }) })
3973
3968
  ] });
3974
- }, cs = () => {
3975
- const { isAuthenticated: e } = xe(), { state: t } = B(X), [r, a] = W(!1), [n, o] = qa(), s = oa({
3969
+ }, ss = () => {
3970
+ const { isAuthenticated: e } = Ee(), { ref: t, inViewport: r } = Ua(), a = na({
3976
3971
  isAuthenticated: e,
3977
3972
  extraClass: "rounded-b-md"
3978
- }), c = O(!1), g = K(() => {
3979
- const h = n.current;
3980
- if (h) {
3981
- const { scrollHeight: m, clientHeight: u, scrollTop: f } = h, p = m - u - f;
3982
- h.scrollBy({
3983
- top: p,
3984
- behavior: "smooth"
3985
- });
3986
- }
3987
- }, [n]), d = K(() => {
3988
- const h = n.current;
3989
- if (h) {
3990
- const { scrollTop: m, scrollHeight: u, clientHeight: f } = h, p = u > f, b = m + f >= u - 1;
3991
- a(p && !b);
3992
- }
3993
- }, [n]);
3994
- return mr(() => {
3995
- o && o.width && t && !t.streaming && d();
3996
- }, [o, t, d]), A(() => {
3997
- const h = n.current;
3998
- if (h)
3999
- return h.addEventListener("scroll", d), () => h.removeEventListener("scroll", d);
4000
- }, [d, n]), A(() => {
4001
- t && t.streaming && d();
4002
- }, [t, d]), A(() => {
4003
- t && (!c.current && t.streaming && g(), c.current = !!t.streaming);
4004
- }, [t, g]), /* @__PURE__ */ x("div", { className: s, ref: n, children: [
4005
- r && /* @__PURE__ */ i(
4006
- "div",
4007
- {
4008
- className: l(
4009
- mo,
4010
- "bottom-44 fixed left-1/2 transform -translate-x-1/2"
4011
- ),
4012
- children: /* @__PURE__ */ i(
4013
- Ee,
4014
- {
4015
- label: "Scroll to bottom",
4016
- className: l(
4017
- "dark:bg-slate-50 dark:hover:bg-slate-300 dark:active:bg-slate-400",
4018
- "bg-slate-500 hover:bg-slate-600 active:bg-slate-700"
4019
- ),
4020
- noBorder: !0,
4021
- size: "medium",
4022
- mode: "dark",
4023
- onClick: g,
4024
- children: /* @__PURE__ */ i(
4025
- Ba,
4026
- {
4027
- monotone: !0,
4028
- size: "size-4",
4029
- className: "dark:text-copy-dark text-copy-lighter"
4030
- }
4031
- )
4032
- }
4033
- )
4034
- }
4035
- ),
4036
- /* @__PURE__ */ i(sa, {}),
4037
- e && /* @__PURE__ */ i(is, {})
3973
+ });
3974
+ return /* @__PURE__ */ x(Ae, { children: [
3975
+ /* @__PURE__ */ x("div", { className: a, children: [
3976
+ /* @__PURE__ */ i(oa, {}),
3977
+ /* @__PURE__ */ i(os, {}),
3978
+ /* @__PURE__ */ i("div", { ref: t })
3979
+ ] }),
3980
+ /* @__PURE__ */ i(wo, { show: !r })
4038
3981
  ] });
4039
- }, ls = hr(
3982
+ }, is = gr(
4040
3983
  () => import(
4041
3984
  /* webpackChunkName: "LazyHeader" */
4042
- "./HeaderToolbar.qJtZsjJJ.js"
3985
+ "./HeaderToolbar.CP9YNkrJ.js"
4043
3986
  )
4044
3987
  );
4045
- function Hr({ isComponent: e = !1 }) {
4046
- const { user: t, getAccessToken: r } = xe(), [a] = jt({
4047
- key: Ut + ca,
3988
+ function Fr({ isComponent: e = !1 }) {
3989
+ const { user: t, getAccessToken: r } = Ee(), [a] = Gt({
3990
+ key: Pt + ia,
4048
3991
  initialValue: ""
4049
- }), [n] = jt({
4050
- key: Ut + la,
3992
+ }), [n] = Gt({
3993
+ key: Pt + ca,
4051
3994
  initialValue: be.ASC
4052
- }), [o, s] = He(En, {
4053
- id: _t(),
3995
+ }), [o, s] = We(vn, {
3996
+ id: kt(),
4054
3997
  model: ke,
4055
3998
  engine: ke,
4056
3999
  usage: 0,
4057
4000
  messages: [],
4058
4001
  prompts: [],
4059
4002
  isComponent: e
4060
- }), [c, g] = He(xn, {
4003
+ }), [c, g] = We(kn, {
4061
4004
  searchString: a,
4062
4005
  sortedCell: "timestamp",
4063
4006
  sortDirection: n
4064
- }), [d, h] = He(Sn, {
4007
+ }), [d, f] = We(_n, {
4065
4008
  prompt: "",
4066
4009
  lastTriggeredTimestamp: 0
4067
4010
  });
4068
- return co({
4011
+ return oo({
4069
4012
  keys: [
4070
4013
  t == null ? void 0 : t.username,
4071
4014
  c.searchString,
4072
4015
  c.sortDirection
4073
4016
  ],
4074
4017
  getAccessToken: r
4075
- }), lo({ getAccessToken: r }), so({ keys: [t == null ? void 0 : t.username], getAccessToken: r }), A(() => {
4018
+ }), so({ getAccessToken: r }), ao({ keys: [t == null ? void 0 : t.username], getAccessToken: r }), D(() => {
4076
4019
  var u;
4077
4020
  (u = document.getElementById("logo")) == null || u.classList.add("fadeOut"), setTimeout(() => {
4078
- var f;
4079
- (f = document.getElementById("root")) == null || f.classList.replace("app-hidden", "fadeIn");
4021
+ var h;
4022
+ (h = document.getElementById("root")) == null || h.classList.replace("app-hidden", "fadeIn");
4080
4023
  }, 500);
4081
- }), /* @__PURE__ */ i(X.Provider, { value: { state: o, dispatch: s }, children: /* @__PURE__ */ i(
4082
- go.Provider,
4024
+ }), /* @__PURE__ */ i(se.Provider, { value: { state: o, dispatch: s }, children: /* @__PURE__ */ i(
4025
+ lo.Provider,
4083
4026
  {
4084
4027
  value: {
4085
4028
  state: c,
4086
4029
  dispatch: g
4087
4030
  },
4088
4031
  children: /* @__PURE__ */ x(
4089
- De.Provider,
4032
+ Ve.Provider,
4090
4033
  {
4091
- value: { state: d, dispatch: h },
4034
+ value: { state: d, dispatch: f },
4092
4035
  children: [
4093
4036
  /* @__PURE__ */ i(
4094
- $a,
4037
+ za,
4095
4038
  {
4096
4039
  noColors: !0,
4097
4040
  noMargin: !0,
4098
4041
  noPadding: !0,
4099
4042
  noBorder: !0,
4100
- className: Pt({
4043
+ className: Vt({
4101
4044
  extraClass: "mt-5"
4102
4045
  }),
4103
- children: /* @__PURE__ */ i(tt, { fallback: /* @__PURE__ */ i("div", {}), children: /* @__PURE__ */ i(ls, {}) })
4046
+ children: /* @__PURE__ */ i(rt, { fallback: /* @__PURE__ */ i("div", {}), children: /* @__PURE__ */ i(is, {}) })
4104
4047
  }
4105
4048
  ),
4106
4049
  /* @__PURE__ */ i(
4107
- ia,
4050
+ sa,
4108
4051
  {
4109
- className: Pt({
4052
+ className: Vt({
4110
4053
  extraClass: "max-h-[calc(100svh_-_250px)]"
4111
4054
  }),
4112
4055
  noMargin: !0,
4113
4056
  noPadding: !0,
4114
- children: /* @__PURE__ */ i(cs, {})
4057
+ children: /* @__PURE__ */ i(ss, {})
4115
4058
  }
4116
4059
  ),
4117
- /* @__PURE__ */ i(To, {})
4060
+ /* @__PURE__ */ i(xo, {})
4118
4061
  ]
4119
4062
  }
4120
4063
  )
4121
4064
  }
4122
4065
  ) });
4123
4066
  }
4124
- Hr.displayName = "App";
4125
- const ws = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: Hr }, Symbol.toStringTag, { value: "Module" }));
4067
+ Fr.displayName = "App";
4068
+ const xs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: Fr }, Symbol.toStringTag, { value: "Module" }));
4126
4069
  export {
4127
- ws as App,
4128
- X as AppContext,
4129
- jt as E,
4130
- go as HistoryContext,
4131
- Ss as P,
4132
- Ae as R,
4133
- Se as SERVICE_TYPES,
4134
- bs as be,
4070
+ xs as App,
4071
+ se as AppContext,
4072
+ Gt as E,
4073
+ lo as HistoryContext,
4074
+ Es as P,
4075
+ Le as R,
4076
+ xe as SERVICE_TYPES,
4077
+ fs as be,
4135
4078
  be as f,
4136
- fs as ge,
4137
- ps as he,
4138
- Ja as i,
4139
- Ht as i$1,
4140
- bn as ie,
4141
- jo as le,
4142
- ys as me,
4079
+ gs as ge,
4080
+ hs as he,
4081
+ ja as i,
4082
+ Ft as i$1,
4083
+ hn as ie,
4084
+ Wo as le,
4085
+ ps as me,
4143
4086
  wt as me$1,
4144
- Ft as p,
4145
- Ir as serviceCall,
4146
- vs as ue,
4147
- Es as useChatsHistory,
4148
- xs as useServerCapabilities,
4149
- _s as useUserChatStats,
4150
- Ar as useUserPreferences,
4151
- ks as ye
4087
+ Ut as p,
4088
+ Rr as serviceCall,
4089
+ bs as ue,
4090
+ ks as useChatsHistory,
4091
+ _s as useServerCapabilities,
4092
+ vs as useUserChatStats,
4093
+ Lr as useUserPreferences,
4094
+ ys as ye
4152
4095
  };