@versini/sassysaint 6.0.2 → 6.0.3
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.
- package/dist/chunks/{App.9lylFRwi.js → App.BLBn8tAW.js} +890 -882
- package/dist/chunks/{HeaderToolbar.Tm6jGPRy.js → HeaderToolbar.BkfChFW9.js} +4 -4
- package/dist/chunks/{MarkdownWithExtra.D4xUgAKJ.js → MarkdownWithExtra.Bd0uVCob.js} +2 -2
- package/dist/chunks/{MessageAssistant.BUCVo1Ly.js → MessageAssistant.DgkzykE1.js} +3 -3
- package/dist/chunks/{index.TG9DLSxx.js → index.lSfnE_4F.js} +1 -1
- package/dist/components/SassySaint/SassySaint.js +1 -1
- package/dist/index.js +4 -4
- package/package.json +3 -3
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { g as
|
|
1
|
+
import { jsx as u, jsxs as C, Fragment as Qe } from "react/jsx-runtime";
|
|
2
|
+
import { g as Ne, ACTION_RESTORE as jn, ACTION_MESSAGE as Ae, ROLE_ASSISTANT as Be, ACTION_RESET as et, ACTION_MODEL as Yr, ACTION_STREAMING as Jr, ACTION_SORT as qn, ACTION_SEARCH as Kn, ACTION_RESET_PROMPT as Xr, ACTION_TOGGLE_PROMPT as Zr, DEFAULT_AI_ENGINE as we, Y as tt, un as Pe, ENGINE_ANTHROPIC as pt, ENGINE_OPENAI as yr, PROMPT_CLASSNAME as Yn, PROMPT_EDITABLE_AREA_CLASSNAME as Jn, ROLE_SYSTEM as Xn, ROLE_INTERNAL as jt, ROLE_HIDDEN as Zn, STATS_SEPARATOR as br, CLIPBOARD_PROMPT as vr, TYPE_QUESTION as Qn, ERROR_MESSAGE as ea, ROLE_USER as Ct, FOOTER_DISCLAIMER as ta, isLastMessageFromRole as ra, getMessageContaintWrapperClass as na, Logo as aa, getMainPaddingClass as kr, r as oa, LOCAL_STORAGE_PREFIX as xr, LOCAL_STORAGE_SEARCH as sa, LOCAL_STORAGE_SORT as ia } from "./index.lSfnE_4F.js";
|
|
3
3
|
import h from "clsx";
|
|
4
|
-
import * as
|
|
5
|
-
import V, { useRef as A, useState as Z, useCallback as te, useSyncExternalStore as
|
|
6
|
-
import { useFloatingTree as rn, useFloatingNodeId as
|
|
4
|
+
import * as Rt from "react";
|
|
5
|
+
import V, { useRef as A, useState as Z, useCallback as te, useSyncExternalStore as la, useEffect as D, useMemo as Qr, useId as ca, useContext as W, createContext as da, useLayoutEffect as ua, useDebugValue as ma, forwardRef as en, lazy as tn, Suspense as It, useReducer as yt } from "react";
|
|
6
|
+
import { useFloatingTree as rn, useFloatingNodeId as fa, useListItem as nn, useFloating as ga, offset as ha, flip as pa, shift as ya, autoUpdate as ba, useClick as va, useRole as ka, useDismiss as xa, useListNavigation as wa, useTypeahead as _a, useInteractions as Ea, useMergeRefs as an, FloatingNode as Ta, FloatingList as Sa, FloatingPortal as Na, FloatingFocusManager as Ca, FloatingTree as Ra } from "@floating-ui/react";
|
|
7
7
|
const wr = ({
|
|
8
8
|
className: e,
|
|
9
9
|
viewBox: t,
|
|
10
10
|
title: r,
|
|
11
11
|
monotone: n,
|
|
12
12
|
...a
|
|
13
|
-
}) => /* @__PURE__ */
|
|
14
|
-
|
|
13
|
+
}) => /* @__PURE__ */ u(
|
|
14
|
+
Ne,
|
|
15
15
|
{
|
|
16
16
|
defaultViewBox: "0 0 24 24",
|
|
17
17
|
size: "size-5",
|
|
@@ -19,16 +19,16 @@ const wr = ({
|
|
|
19
19
|
className: e,
|
|
20
20
|
title: r || "Anthropic",
|
|
21
21
|
...a,
|
|
22
|
-
children: /* @__PURE__ */
|
|
22
|
+
children: /* @__PURE__ */ u("path", { d: "M17.304 3.541h-3.672l6.696 16.918H24Zm-10.608 0L0 20.459h3.744l1.37-3.553h7.005l1.369 3.553h3.744L10.536 3.541Zm-.371 10.223L8.616 7.82l2.291 5.945Z" })
|
|
23
23
|
}
|
|
24
|
-
),
|
|
24
|
+
), Ia = ({
|
|
25
25
|
className: e,
|
|
26
26
|
viewBox: t,
|
|
27
27
|
title: r,
|
|
28
28
|
monotone: n,
|
|
29
29
|
...a
|
|
30
30
|
}) => /* @__PURE__ */ C(
|
|
31
|
-
|
|
31
|
+
Ne,
|
|
32
32
|
{
|
|
33
33
|
defaultViewBox: "0 0 448 512",
|
|
34
34
|
size: "size-5",
|
|
@@ -37,24 +37,24 @@ const wr = ({
|
|
|
37
37
|
title: r || "Book",
|
|
38
38
|
...a,
|
|
39
39
|
children: [
|
|
40
|
-
/* @__PURE__ */
|
|
40
|
+
/* @__PURE__ */ u(
|
|
41
41
|
"path",
|
|
42
42
|
{
|
|
43
43
|
d: "M48 88v270.7c9.8-4.3 20.6-6.7 32-6.7h312c4.4 0 8-3.6 8-8V56c0-4.4-3.6-8-8-8H88c-22.1 0-40 17.9-40 40m94.3 32.8L160 112l8.8-17.7c2.9-5.9 11.4-5.9 14.3 0L192 112l17.7 8.8c5.9 2.9 5.9 11.4 0 14.3L192 144l-8.8 17.7c-2.9 5.9-11.4 5.9-14.3 0L160 144l-17.7-8.8c-5.9-2.9-5.9-11.4 0-14.3zm82.8 111.8L264 216l16.6-38.8c2.8-6.5 11.9-6.5 14.7 0L312 216l38.8 16.6c6.5 2.8 6.5 11.9 0 14.7L312 264l-16.6 38.8c-2.8 6.5-11.9 6.5-14.7 0L264 264l-38.8-16.6c-6.5-2.8-6.5-11.9 0-14.7z",
|
|
44
44
|
opacity: ".4"
|
|
45
45
|
}
|
|
46
46
|
),
|
|
47
|
-
/* @__PURE__ */
|
|
47
|
+
/* @__PURE__ */ u("path", { d: "M0 88C0 39.4 39.4 0 88 0h304c30.9 0 56 25.1 56 56v288c0 22.3-13.1 41.6-32 50.6V464h8c13.3 0 24 10.7 24 24s-10.7 24-24 24H80c-44.2 0-80-35.8-80-80 0-2.7.1-5.4.4-8H0zm80 312c-17.7 0-32 14.3-32 32s14.3 32 32 32h288v-64zm-32-41.3c9.8-4.3 20.6-6.7 32-6.7h312c4.4 0 8-3.6 8-8V56c0-4.4-3.6-8-8-8H88c-22.1 0-40 17.9-40 40zM160 112l8.8-17.7c2.9-5.9 11.4-5.9 14.3 0L192 112l17.7 8.8c5.9 2.9 5.9 11.4 0 14.3L192 144l-8.8 17.7c-2.9 5.9-11.4 5.9-14.3 0L160 144l-17.7-8.8c-5.9-2.9-5.9-11.4 0-14.3zm104 104 16.6-38.8c2.8-6.5 11.9-6.5 14.7 0L312 216l38.8 16.6c6.5 2.8 6.5 11.9 0 14.7L312 264l-16.6 38.8c-2.8 6.5-11.9 6.5-14.7 0L264 264l-38.8-16.6c-6.5-2.8-6.5-11.9 0-14.7z" })
|
|
48
48
|
]
|
|
49
49
|
}
|
|
50
|
-
),
|
|
50
|
+
), La = ({
|
|
51
51
|
className: e,
|
|
52
52
|
viewBox: t,
|
|
53
53
|
title: r,
|
|
54
54
|
monotone: n,
|
|
55
55
|
...a
|
|
56
|
-
}) => /* @__PURE__ */
|
|
57
|
-
|
|
56
|
+
}) => /* @__PURE__ */ u(
|
|
57
|
+
Ne,
|
|
58
58
|
{
|
|
59
59
|
defaultViewBox: "0 0 384 512",
|
|
60
60
|
size: "size-5",
|
|
@@ -62,7 +62,7 @@ const wr = ({
|
|
|
62
62
|
className: e,
|
|
63
63
|
title: r || "Close",
|
|
64
64
|
...a,
|
|
65
|
-
children: /* @__PURE__ */
|
|
65
|
+
children: /* @__PURE__ */ u(
|
|
66
66
|
"path",
|
|
67
67
|
{
|
|
68
68
|
d: "M297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256l105.3-105.4c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3z",
|
|
@@ -70,14 +70,14 @@ const wr = ({
|
|
|
70
70
|
}
|
|
71
71
|
)
|
|
72
72
|
}
|
|
73
|
-
),
|
|
73
|
+
), Oa = ({
|
|
74
74
|
className: e,
|
|
75
75
|
viewBox: t,
|
|
76
76
|
title: r,
|
|
77
77
|
monotone: n,
|
|
78
78
|
...a
|
|
79
79
|
}) => /* @__PURE__ */ C(
|
|
80
|
-
|
|
80
|
+
Ne,
|
|
81
81
|
{
|
|
82
82
|
defaultViewBox: "0 0 512 512",
|
|
83
83
|
size: "size-5",
|
|
@@ -86,14 +86,14 @@ const wr = ({
|
|
|
86
86
|
title: r || "Edit",
|
|
87
87
|
...a,
|
|
88
88
|
children: [
|
|
89
|
-
/* @__PURE__ */
|
|
89
|
+
/* @__PURE__ */ u(
|
|
90
90
|
"path",
|
|
91
91
|
{
|
|
92
92
|
d: "M0 160c0-53 43-96 96-96h96c17.7 0 32 14.3 32 32s-14.3 32-32 32H96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h256c17.7 0 32-14.3 32-32v-96c0-17.7 14.3-32 32-32s32 14.3 32 32v96c0 53-43 96-96 96H96c-53 0-96-43-96-96z",
|
|
93
93
|
opacity: n ? "1" : "0.4"
|
|
94
94
|
}
|
|
95
95
|
),
|
|
96
|
-
/* @__PURE__ */
|
|
96
|
+
/* @__PURE__ */ u("path", { d: "m392.4 21.7-30.1 30 97.9 97.9 30.1-30.1c21.9-21.9 21.9-57.3 0-79.2l-18.7-18.6c-21.9-21.9-57.3-21.9-79.2 0m-52.7 52.6L172.4 241.7c-6.1 6.1-10.8 13.6-13.5 21.9l-29.6 88.8c-2.9 8.6-.6 18.1 5.8 24.6s15.9 8.7 24.6 5.8l88.8-29.6c8.2-2.7 15.7-7.4 21.9-13.5l167.3-167.4z" })
|
|
97
97
|
]
|
|
98
98
|
}
|
|
99
99
|
), _r = ({
|
|
@@ -102,8 +102,8 @@ const wr = ({
|
|
|
102
102
|
title: r,
|
|
103
103
|
monotone: n,
|
|
104
104
|
...a
|
|
105
|
-
}) => /* @__PURE__ */
|
|
106
|
-
|
|
105
|
+
}) => /* @__PURE__ */ u(
|
|
106
|
+
Ne,
|
|
107
107
|
{
|
|
108
108
|
defaultViewBox: "0 0 24 24",
|
|
109
109
|
size: "size-5",
|
|
@@ -111,16 +111,16 @@ const wr = ({
|
|
|
111
111
|
className: e,
|
|
112
112
|
title: r || "OpenAI",
|
|
113
113
|
...a,
|
|
114
|
-
children: /* @__PURE__ */
|
|
114
|
+
children: /* @__PURE__ */ u("path", { d: "M22.282 9.821a5.99 5.99 0 0 0-.516-4.91 6.05 6.05 0 0 0-6.51-2.9A6.065 6.065 0 0 0 4.981 4.18a5.99 5.99 0 0 0-3.998 2.9 6.05 6.05 0 0 0 .743 7.097 5.98 5.98 0 0 0 .51 4.911 6.05 6.05 0 0 0 6.515 2.9A5.99 5.99 0 0 0 13.26 24a6.06 6.06 0 0 0 5.772-4.206 6 6 0 0 0 3.997-2.9 6.06 6.06 0 0 0-.747-7.073zM13.26 22.43a4.48 4.48 0 0 1-2.876-1.04l.141-.081 4.779-2.758a.8.8 0 0 0 .392-.681v-6.737l2.02 1.168a.07.07 0 0 1 .038.052v5.583a4.504 4.504 0 0 1-4.494 4.494M3.6 18.304a4.47 4.47 0 0 1-.535-3.014l.142.085 4.783 2.759a.77.77 0 0 0 .78 0l5.843-3.369v2.332a.08.08 0 0 1-.033.062L9.74 19.95a4.5 4.5 0 0 1-6.14-1.646M2.34 7.896a4.5 4.5 0 0 1 2.366-1.973V11.6a.77.77 0 0 0 .388.677l5.815 3.354-2.02 1.168a.08.08 0 0 1-.071 0l-4.83-2.786A4.504 4.504 0 0 1 2.34 7.872zm16.597 3.855-5.833-3.387L15.119 7.2a.08.08 0 0 1 .071 0l4.83 2.791a4.494 4.494 0 0 1-.676 8.105v-5.678a.79.79 0 0 0-.407-.667zm2.01-3.023-.141-.085-4.774-2.782a.78.78 0 0 0-.785 0L9.409 9.23V6.897a.07.07 0 0 1 .028-.061l4.83-2.787a4.5 4.5 0 0 1 6.68 4.66zm-12.64 4.135-2.02-1.164a.08.08 0 0 1-.038-.057V6.075a4.5 4.5 0 0 1 7.375-3.453l-.142.08-4.778 2.758a.8.8 0 0 0-.393.681zm1.097-2.365 2.602-1.5 2.607 1.5v2.999l-2.597 1.5-2.607-1.5Z" })
|
|
115
115
|
}
|
|
116
|
-
),
|
|
116
|
+
), Aa = ({
|
|
117
117
|
className: e,
|
|
118
118
|
viewBox: t,
|
|
119
119
|
title: r,
|
|
120
120
|
monotone: n,
|
|
121
121
|
...a
|
|
122
122
|
}) => /* @__PURE__ */ C(
|
|
123
|
-
|
|
123
|
+
Ne,
|
|
124
124
|
{
|
|
125
125
|
defaultViewBox: "0 0 512 512",
|
|
126
126
|
size: "size-5",
|
|
@@ -129,14 +129,14 @@ const wr = ({
|
|
|
129
129
|
title: r || "Send",
|
|
130
130
|
...a,
|
|
131
131
|
children: [
|
|
132
|
-
/* @__PURE__ */
|
|
132
|
+
/* @__PURE__ */ u(
|
|
133
133
|
"path",
|
|
134
134
|
{
|
|
135
135
|
d: "M0 288c0 .7 0 1.3.1 2 .8 12.2 8.4 22.9 19.6 27.6l112 46.7L160 376v-8c0-4.2 1.7-8.3 4.7-11.3l13-13c59.6-59.6 119.2-119.2 178.8-178.7.1-.1.2-.2.2-.3 3-3 6.8-4.5 10.7-4.7s7.9 1.1 11 3.9c3.7 3.3 5.6 7.7 5.6 12.1 0 3.4-1.1 6.8-3.3 9.7L224 389.4v13.2c20 8.3 40 16.7 60 25 39.9 16.6 79.8 33.2 119.7 49.9 9.1 3.8 19.4 3.2 28-1.6s14.5-13.3 16-23l64-416c1.9-12.1-3.4-24.3-13.5-31.2C492.7 1.9 486.4 0 480 0c-5.5 0-10.9 1.4-15.9 4.2l-448 256C6.1 265.9 0 276.6 0 288",
|
|
136
136
|
opacity: ".4"
|
|
137
137
|
}
|
|
138
138
|
),
|
|
139
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ u("path", { d: "M380.7 185.8c5.1-6.7 4.2-16.2-2.1-21.8s-15.9-5.3-21.9.7l-179 179-13 13c-3 3-4.7 7.1-4.7 11.3v112c0 13.2 8.1 25 20.3 29.8s26.2 1.6 35.2-8.1l68.5-74-60-25v-13.2z" })
|
|
140
140
|
]
|
|
141
141
|
}
|
|
142
142
|
);
|
|
@@ -153,7 +153,7 @@ try {
|
|
|
153
153
|
});
|
|
154
154
|
} catch {
|
|
155
155
|
}
|
|
156
|
-
const
|
|
156
|
+
const Ba = "av-header", Ma = ({
|
|
157
157
|
children: e,
|
|
158
158
|
className: t,
|
|
159
159
|
raw: r = !1,
|
|
@@ -165,7 +165,7 @@ const Ma = "av-header", $a = ({
|
|
|
165
165
|
noPadding: l = !1
|
|
166
166
|
}) => {
|
|
167
167
|
const c = h(
|
|
168
|
-
|
|
168
|
+
Ba,
|
|
169
169
|
{
|
|
170
170
|
"border-border-accent": n === "dark" && !r && !a && !s,
|
|
171
171
|
"border-border-medium": n === "light" && !r && !a && !s,
|
|
@@ -185,9 +185,9 @@ const Ma = "av-header", $a = ({
|
|
|
185
185
|
"p-2": !l,
|
|
186
186
|
"flex flex-col w-full md:mx-auto md:max-w-4xl": !r
|
|
187
187
|
});
|
|
188
|
-
return /* @__PURE__ */
|
|
188
|
+
return /* @__PURE__ */ u("header", { className: c, children: /* @__PURE__ */ u("div", { className: g, children: e }) });
|
|
189
189
|
};
|
|
190
|
-
function
|
|
190
|
+
function $a(e) {
|
|
191
191
|
const t = e.toLowerCase().split("+").map((o) => o.trim()), r = {
|
|
192
192
|
alt: t.includes("alt"),
|
|
193
193
|
ctrl: t.includes("ctrl"),
|
|
@@ -200,8 +200,8 @@ function Da(e) {
|
|
|
200
200
|
key: a
|
|
201
201
|
};
|
|
202
202
|
}
|
|
203
|
-
function
|
|
204
|
-
const { alt: r, ctrl: n, meta: a, mod: o, shift: s, key: i } = e, { altKey: l, ctrlKey: c, metaKey: g, shiftKey:
|
|
203
|
+
function Da(e, t) {
|
|
204
|
+
const { alt: r, ctrl: n, meta: a, mod: o, shift: s, key: i } = e, { altKey: l, ctrlKey: c, metaKey: g, shiftKey: d, key: f } = t;
|
|
205
205
|
if (r !== l)
|
|
206
206
|
return !1;
|
|
207
207
|
if (o) {
|
|
@@ -209,20 +209,20 @@ function Pa(e, t) {
|
|
|
209
209
|
return !1;
|
|
210
210
|
} else if (n !== c || a !== g)
|
|
211
211
|
return !1;
|
|
212
|
-
return s !==
|
|
212
|
+
return s !== d ? !1 : !!(i && (f.toLowerCase() === i.toLowerCase() || t.code.replace("Key", "").toLowerCase() === i.toLowerCase()));
|
|
213
213
|
}
|
|
214
|
-
function
|
|
215
|
-
return (t) =>
|
|
214
|
+
function Pa(e) {
|
|
215
|
+
return (t) => Da($a(e), t);
|
|
216
216
|
}
|
|
217
|
-
function
|
|
217
|
+
function Va(e) {
|
|
218
218
|
return (t) => {
|
|
219
219
|
const r = "nativeEvent" in t ? t.nativeEvent : t;
|
|
220
220
|
e.forEach(([n, a, o = { preventDefault: !0 }]) => {
|
|
221
|
-
|
|
221
|
+
Pa(n)(r) && (o.preventDefault && t.preventDefault(), a(r));
|
|
222
222
|
});
|
|
223
223
|
};
|
|
224
224
|
}
|
|
225
|
-
function
|
|
225
|
+
function za() {
|
|
226
226
|
const e = A(null), [t, r] = Z(!1);
|
|
227
227
|
return { ref: te((n) => {
|
|
228
228
|
var a, o;
|
|
@@ -239,18 +239,18 @@ const Er = (e, t) => {
|
|
|
239
239
|
typeof t == "function" ? t() : t
|
|
240
240
|
);
|
|
241
241
|
window.localStorage.setItem(e, r), on(e, r);
|
|
242
|
-
},
|
|
242
|
+
}, Ua = (e) => {
|
|
243
243
|
window.localStorage.removeItem(e), on(e, null);
|
|
244
|
-
}, Tr = (e) => window.localStorage.getItem(e),
|
|
244
|
+
}, Tr = (e) => window.localStorage.getItem(e), Ha = (e) => (window.addEventListener("storage", e), () => window.removeEventListener("storage", e));
|
|
245
245
|
function Sr({
|
|
246
246
|
key: e,
|
|
247
247
|
initialValue: t
|
|
248
248
|
}) {
|
|
249
|
-
const r =
|
|
249
|
+
const r = la(Ha, () => Tr(e)), n = te(
|
|
250
250
|
(s) => {
|
|
251
251
|
try {
|
|
252
252
|
const i = typeof s == "function" ? s(JSON.parse(r)) : s;
|
|
253
|
-
i == null ?
|
|
253
|
+
i == null ? Ua(e) : Er(e, i);
|
|
254
254
|
} catch (i) {
|
|
255
255
|
console.warn(i);
|
|
256
256
|
}
|
|
@@ -261,7 +261,7 @@ function Sr({
|
|
|
261
261
|
}, [t, n]), o = te(() => {
|
|
262
262
|
n(null);
|
|
263
263
|
}, [n]);
|
|
264
|
-
return
|
|
264
|
+
return D(() => {
|
|
265
265
|
try {
|
|
266
266
|
Tr(e) === null && typeof t < "u" && Er(e, t);
|
|
267
267
|
} catch (s) {
|
|
@@ -269,7 +269,7 @@ function Sr({
|
|
|
269
269
|
}
|
|
270
270
|
}, [e, t]), [r ? JSON.parse(r) : null, n, a, o];
|
|
271
271
|
}
|
|
272
|
-
function
|
|
272
|
+
function Fa(e) {
|
|
273
273
|
return Qr(() => e.every((t) => t == null) ? () => {
|
|
274
274
|
} : (t) => {
|
|
275
275
|
e.forEach((r) => {
|
|
@@ -277,7 +277,7 @@ function Wa(e) {
|
|
|
277
277
|
});
|
|
278
278
|
}, e);
|
|
279
279
|
}
|
|
280
|
-
function
|
|
280
|
+
function Wa({
|
|
281
281
|
value: e,
|
|
282
282
|
defaultValue: t,
|
|
283
283
|
finalValue: r,
|
|
@@ -290,14 +290,14 @@ function Ga({
|
|
|
290
290
|
), c = (g) => {
|
|
291
291
|
l(g), n == null || n(g);
|
|
292
292
|
};
|
|
293
|
-
return
|
|
293
|
+
return D(() => {
|
|
294
294
|
(async () => e !== void 0 && !o && a > 0 && (await new Promise(
|
|
295
295
|
(g) => setTimeout(g, a)
|
|
296
296
|
), s(!0)))();
|
|
297
297
|
}, [e, a, o]), e !== void 0 ? !o && a > 0 ? ["", n, !0] : [e, n, !0] : [i, c, !1];
|
|
298
298
|
}
|
|
299
|
-
function
|
|
300
|
-
return
|
|
299
|
+
function Ga(e) {
|
|
300
|
+
return ca();
|
|
301
301
|
}
|
|
302
302
|
/*!
|
|
303
303
|
@versini/ui-table v3.0.16
|
|
@@ -312,10 +312,10 @@ try {
|
|
|
312
312
|
});
|
|
313
313
|
} catch {
|
|
314
314
|
}
|
|
315
|
-
const
|
|
315
|
+
const rt = "thead", qt = "tfoot", xe = "tbody", Oe = {
|
|
316
316
|
ASC: "asc",
|
|
317
317
|
DESC: "desc"
|
|
318
|
-
},
|
|
318
|
+
}, ja = ({
|
|
319
319
|
mode: e,
|
|
320
320
|
className: t,
|
|
321
321
|
wrapperClassName: r,
|
|
@@ -350,7 +350,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
350
350
|
"text-copy-light dark:text-copy-dark": e === "system",
|
|
351
351
|
"text-copy-dark dark:text-copy-light": e === "alt-system"
|
|
352
352
|
})
|
|
353
|
-
}),
|
|
353
|
+
}), qa = ({
|
|
354
354
|
className: e,
|
|
355
355
|
stickyHeader: t,
|
|
356
356
|
mode: r
|
|
@@ -363,7 +363,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
363
363
|
"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"
|
|
364
364
|
},
|
|
365
365
|
e
|
|
366
|
-
),
|
|
366
|
+
), Ka = ({
|
|
367
367
|
className: e,
|
|
368
368
|
stickyFooter: t,
|
|
369
369
|
mode: r
|
|
@@ -376,11 +376,11 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
376
376
|
"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"
|
|
377
377
|
},
|
|
378
378
|
e
|
|
379
|
-
),
|
|
379
|
+
), Ya = ({
|
|
380
380
|
mode: e,
|
|
381
381
|
className: t,
|
|
382
382
|
cellWrapper: r
|
|
383
|
-
}) => r ===
|
|
383
|
+
}) => r === rt || r === qt ? h(
|
|
384
384
|
{
|
|
385
385
|
"bg-table-head-dark": e === "dark" || e === "system",
|
|
386
386
|
"bg-table-head-light": e === "light" || e === "alt-system",
|
|
@@ -401,7 +401,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
401
401
|
"odd:bg-table-light-odd even:bg-table-light-even dark:odd:bg-table-dark-odd dark:even:bg-table-dark-even": r === xe && e === "alt-system"
|
|
402
402
|
},
|
|
403
403
|
t
|
|
404
|
-
),
|
|
404
|
+
), Ja = ({
|
|
405
405
|
cellWrapper: e,
|
|
406
406
|
className: t,
|
|
407
407
|
compact: r,
|
|
@@ -419,15 +419,15 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
419
419
|
"text-copy-dark": n === "light" || n === "alt-system",
|
|
420
420
|
"dark:text-copy-dark": n === "system",
|
|
421
421
|
"dark:text-copy-light": n === "alt-system",
|
|
422
|
-
"px-4 py-3": !r && (e ===
|
|
422
|
+
"px-4 py-3": !r && (e === rt || e === qt),
|
|
423
423
|
"p-4": !r && e === xe,
|
|
424
424
|
"px-2 py-1.5": r
|
|
425
425
|
},
|
|
426
426
|
t
|
|
427
427
|
)
|
|
428
|
-
}),
|
|
428
|
+
}), Xa = ({
|
|
429
429
|
buttonClassName: e
|
|
430
|
-
}) => h("rounded-none text-sm", e), Nr = "av-button", Kt = "icon", sn = "button",
|
|
430
|
+
}) => h("rounded-none text-sm", e), Nr = "av-button", Kt = "icon", sn = "button", Lt = "link", Za = ({
|
|
431
431
|
type: e,
|
|
432
432
|
size: t,
|
|
433
433
|
labelRight: r,
|
|
@@ -437,7 +437,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
437
437
|
const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", i = "max-h-12 py-2 px-4";
|
|
438
438
|
switch (e) {
|
|
439
439
|
case sn:
|
|
440
|
-
case
|
|
440
|
+
case Lt:
|
|
441
441
|
return h({
|
|
442
442
|
[o]: t === "small",
|
|
443
443
|
[s]: t === "medium",
|
|
@@ -456,7 +456,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
456
456
|
"h-12 px-4": t === "large" && (r || n)
|
|
457
457
|
});
|
|
458
458
|
}
|
|
459
|
-
},
|
|
459
|
+
}, Qa = ({
|
|
460
460
|
type: e,
|
|
461
461
|
size: t,
|
|
462
462
|
labelRight: r,
|
|
@@ -465,9 +465,9 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
465
465
|
const a = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
|
|
466
466
|
switch (e) {
|
|
467
467
|
case sn:
|
|
468
|
-
case
|
|
468
|
+
case Lt:
|
|
469
469
|
return h({
|
|
470
|
-
"text-center": e ===
|
|
470
|
+
"text-center": e === Lt,
|
|
471
471
|
[a]: t === "small",
|
|
472
472
|
[o]: t === "medium",
|
|
473
473
|
[s]: t === "large"
|
|
@@ -479,7 +479,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
479
479
|
[s]: t === "large" && (r || n)
|
|
480
480
|
});
|
|
481
481
|
}
|
|
482
|
-
},
|
|
482
|
+
}, eo = ({
|
|
483
483
|
mode: e,
|
|
484
484
|
noBackground: t,
|
|
485
485
|
noTruncate: r,
|
|
@@ -515,7 +515,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
515
515
|
return h("not-prose text-copy-lighter", {
|
|
516
516
|
truncate: !r
|
|
517
517
|
});
|
|
518
|
-
},
|
|
518
|
+
}, to = ({
|
|
519
519
|
mode: e,
|
|
520
520
|
noBackground: t,
|
|
521
521
|
variant: r
|
|
@@ -545,13 +545,13 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
545
545
|
if (r === "selected")
|
|
546
546
|
return "bg-action-selected-dark";
|
|
547
547
|
}
|
|
548
|
-
},
|
|
548
|
+
}, ro = ({
|
|
549
549
|
radius: e
|
|
550
550
|
}) => h({
|
|
551
551
|
"rounded-full": e === "large",
|
|
552
552
|
"rounded-md": e === "medium",
|
|
553
553
|
"rounded-sm": e === "small"
|
|
554
|
-
}),
|
|
554
|
+
}), no = ({
|
|
555
555
|
mode: e,
|
|
556
556
|
disabled: t,
|
|
557
557
|
variant: r
|
|
@@ -581,7 +581,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
581
581
|
});
|
|
582
582
|
if (r === "selected")
|
|
583
583
|
return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
|
|
584
|
-
},
|
|
584
|
+
}, ao = ({
|
|
585
585
|
mode: e,
|
|
586
586
|
disabled: t,
|
|
587
587
|
variant: r
|
|
@@ -611,7 +611,7 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
611
611
|
});
|
|
612
612
|
if (r === "selected")
|
|
613
613
|
return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
|
|
614
|
-
},
|
|
614
|
+
}, oo = ({
|
|
615
615
|
mode: e,
|
|
616
616
|
noBorder: t,
|
|
617
617
|
variant: r
|
|
@@ -641,14 +641,14 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
641
641
|
});
|
|
642
642
|
if (r === "selected")
|
|
643
643
|
return "border border-border-selected-dark";
|
|
644
|
-
},
|
|
644
|
+
}, so = ({
|
|
645
645
|
focusMode: e
|
|
646
646
|
}) => h("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
|
|
647
647
|
"focus:outline-focus-dark": e === "dark",
|
|
648
648
|
"focus:outline-focus-light": e === "light",
|
|
649
649
|
"focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
|
|
650
650
|
"focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
|
|
651
|
-
}),
|
|
651
|
+
}), io = ({
|
|
652
652
|
type: e,
|
|
653
653
|
className: t,
|
|
654
654
|
raw: r,
|
|
@@ -660,49 +660,49 @@ const tt = "thead", qt = "tfoot", xe = "tbody", Le = {
|
|
|
660
660
|
noBorder: l,
|
|
661
661
|
labelRight: c,
|
|
662
662
|
labelLeft: g,
|
|
663
|
-
noBackground:
|
|
663
|
+
noBackground: d,
|
|
664
664
|
variant: f,
|
|
665
665
|
noTruncate: m,
|
|
666
666
|
align: p,
|
|
667
667
|
radius: y
|
|
668
668
|
}) => (f || (f = "primary"), r ? h(Nr, t) : h(
|
|
669
669
|
Nr,
|
|
670
|
-
|
|
670
|
+
eo({
|
|
671
671
|
mode: n,
|
|
672
672
|
variant: f,
|
|
673
|
-
noBackground:
|
|
673
|
+
noBackground: d,
|
|
674
674
|
noTruncate: m
|
|
675
675
|
}),
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
676
|
+
to({ mode: n, noBackground: d, variant: f }),
|
|
677
|
+
ro({ radius: y }),
|
|
678
|
+
Za({
|
|
679
679
|
type: e,
|
|
680
680
|
size: i,
|
|
681
681
|
labelRight: c,
|
|
682
682
|
labelLeft: g,
|
|
683
683
|
align: p
|
|
684
684
|
}),
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
685
|
+
Qa({ type: e, size: i, labelRight: c, labelLeft: g }),
|
|
686
|
+
oo({ mode: n, variant: f, noBorder: l }),
|
|
687
|
+
so({ focusMode: a }),
|
|
688
|
+
no({ mode: n, variant: f, disabled: o }),
|
|
688
689
|
ao({ mode: n, variant: f, disabled: o }),
|
|
689
|
-
oo({ mode: n, variant: f, disabled: o }),
|
|
690
690
|
{
|
|
691
691
|
"w-full": s,
|
|
692
692
|
"disabled:cursor-not-allowed disabled:opacity-50": o
|
|
693
693
|
},
|
|
694
694
|
t
|
|
695
|
-
)),
|
|
695
|
+
)), lo = (e, t, r) => {
|
|
696
696
|
var n;
|
|
697
697
|
!t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((n = e == null ? void 0 : e.currentTarget) == null ? void 0 : n.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
|
|
698
698
|
}, ln = V.forwardRef((e, t) => {
|
|
699
699
|
const { onClick: r, noInternalClick: n = !1, ...a } = e;
|
|
700
|
-
return /* @__PURE__ */
|
|
700
|
+
return /* @__PURE__ */ u(
|
|
701
701
|
"button",
|
|
702
702
|
{
|
|
703
703
|
ref: t,
|
|
704
704
|
onClick: (o) => {
|
|
705
|
-
|
|
705
|
+
lo(o, n, r);
|
|
706
706
|
},
|
|
707
707
|
...a
|
|
708
708
|
}
|
|
@@ -735,7 +735,7 @@ const cn = V.forwardRef(
|
|
|
735
735
|
noBorder: l = !1,
|
|
736
736
|
"aria-label": c,
|
|
737
737
|
label: g,
|
|
738
|
-
size:
|
|
738
|
+
size: d = "medium",
|
|
739
739
|
labelRight: f,
|
|
740
740
|
labelLeft: m,
|
|
741
741
|
noBackground: p = !1,
|
|
@@ -744,7 +744,7 @@ const cn = V.forwardRef(
|
|
|
744
744
|
radius: b = "large",
|
|
745
745
|
...k
|
|
746
746
|
}, w) => {
|
|
747
|
-
const _ =
|
|
747
|
+
const _ = io({
|
|
748
748
|
type: Kt,
|
|
749
749
|
mode: r,
|
|
750
750
|
focusMode: n,
|
|
@@ -753,7 +753,7 @@ const cn = V.forwardRef(
|
|
|
753
753
|
raw: i,
|
|
754
754
|
className: o,
|
|
755
755
|
noBorder: l,
|
|
756
|
-
size:
|
|
756
|
+
size: d,
|
|
757
757
|
labelRight: f,
|
|
758
758
|
labelLeft: m,
|
|
759
759
|
noBackground: p,
|
|
@@ -781,7 +781,7 @@ const cn = V.forwardRef(
|
|
|
781
781
|
"after:border-table-light dark:after:border-table-dark": r === "alt-system"
|
|
782
782
|
}
|
|
783
783
|
) : "";
|
|
784
|
-
return /* @__PURE__ */
|
|
784
|
+
return /* @__PURE__ */ u("div", { className: E, children: /* @__PURE__ */ C(
|
|
785
785
|
ln,
|
|
786
786
|
{
|
|
787
787
|
ref: w,
|
|
@@ -791,9 +791,9 @@ const cn = V.forwardRef(
|
|
|
791
791
|
"aria-label": c || g,
|
|
792
792
|
...k,
|
|
793
793
|
children: [
|
|
794
|
-
m && /* @__PURE__ */
|
|
795
|
-
/* @__PURE__ */
|
|
796
|
-
f && /* @__PURE__ */
|
|
794
|
+
m && /* @__PURE__ */ u("span", { className: "pr-2", children: m }),
|
|
795
|
+
/* @__PURE__ */ u("div", { className: x, children: e }),
|
|
796
|
+
f && /* @__PURE__ */ u("span", { className: "pl-2", children: f })
|
|
797
797
|
]
|
|
798
798
|
}
|
|
799
799
|
) });
|
|
@@ -813,7 +813,7 @@ const Yt = ({
|
|
|
813
813
|
}) => {
|
|
814
814
|
const c = h(o, n);
|
|
815
815
|
return /* @__PURE__ */ C(Qe, { children: [
|
|
816
|
-
/* @__PURE__ */
|
|
816
|
+
/* @__PURE__ */ u(
|
|
817
817
|
"svg",
|
|
818
818
|
{
|
|
819
819
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -827,7 +827,7 @@ const Yt = ({
|
|
|
827
827
|
children: e
|
|
828
828
|
}
|
|
829
829
|
),
|
|
830
|
-
s && i && /* @__PURE__ */
|
|
830
|
+
s && i && /* @__PURE__ */ u("span", { className: "sr-only", children: s })
|
|
831
831
|
] });
|
|
832
832
|
};
|
|
833
833
|
/*!
|
|
@@ -843,7 +843,7 @@ try {
|
|
|
843
843
|
});
|
|
844
844
|
} catch {
|
|
845
845
|
}
|
|
846
|
-
const
|
|
846
|
+
const co = ({
|
|
847
847
|
className: e,
|
|
848
848
|
viewBox: t,
|
|
849
849
|
title: r,
|
|
@@ -859,17 +859,17 @@ const uo = ({
|
|
|
859
859
|
title: r || "Sort",
|
|
860
860
|
...a,
|
|
861
861
|
children: [
|
|
862
|
-
/* @__PURE__ */
|
|
862
|
+
/* @__PURE__ */ u(
|
|
863
863
|
"path",
|
|
864
864
|
{
|
|
865
865
|
d: "M297.4 137.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l41.3-41.4V448c0 17.7 14.3 32 32 32s32-14.3 32-32V141.3l41.4 41.4c12.5 12.5 32.8 12.5 45.3 0 6.2-6.2 9.4-14.4 9.4-22.6s-3.1-16.4-9.4-22.6l-96-96c-6.3-6.4-14.5-9.5-22.7-9.5s-16.4 3.1-22.6 9.4z",
|
|
866
866
|
opacity: n ? "1" : "0.4"
|
|
867
867
|
}
|
|
868
868
|
),
|
|
869
|
-
/* @__PURE__ */
|
|
869
|
+
/* @__PURE__ */ u("path", { d: "M137.4 470.6c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 370.7V64c0-17.7-14.3-32-32-32s-32 14.3-32 32v306.7l-41.4-41.3c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96z" })
|
|
870
870
|
]
|
|
871
871
|
}
|
|
872
|
-
),
|
|
872
|
+
), uo = ({
|
|
873
873
|
className: e,
|
|
874
874
|
viewBox: t,
|
|
875
875
|
title: r,
|
|
@@ -885,17 +885,17 @@ const uo = ({
|
|
|
885
885
|
title: r || "Sort Down",
|
|
886
886
|
...a,
|
|
887
887
|
children: [
|
|
888
|
-
/* @__PURE__ */
|
|
888
|
+
/* @__PURE__ */ u(
|
|
889
889
|
"path",
|
|
890
890
|
{
|
|
891
891
|
d: "M288 64c0-17.7 14.3-32 32-32h224c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h160c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32h-96c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32h-32c-17.7 0-32-14.3-32-32",
|
|
892
892
|
opacity: n ? "1" : "0.4"
|
|
893
893
|
}
|
|
894
894
|
),
|
|
895
|
-
/* @__PURE__ */
|
|
895
|
+
/* @__PURE__ */ u("path", { d: "M128 480c9 0 17.5-3.8 23.6-10.4l88-96c11.9-13 11.1-33.3-2-45.2s-33.3-11.1-45.2 2L160 365.7V64c0-17.7-14.3-32-32-32S96 46.3 96 64v301.7l-32.4-35.3c-11.9-13-32.2-13.9-45.2-2s-13.9 32.2-2 45.2l88 96c6.1 6.6 14.6 10.4 23.6 10.4" })
|
|
896
896
|
]
|
|
897
897
|
}
|
|
898
|
-
),
|
|
898
|
+
), mo = ({
|
|
899
899
|
className: e,
|
|
900
900
|
viewBox: t,
|
|
901
901
|
title: r,
|
|
@@ -911,14 +911,14 @@ const uo = ({
|
|
|
911
911
|
title: r || "Sort Up",
|
|
912
912
|
...a,
|
|
913
913
|
children: [
|
|
914
|
-
/* @__PURE__ */
|
|
914
|
+
/* @__PURE__ */ u(
|
|
915
915
|
"path",
|
|
916
916
|
{
|
|
917
917
|
d: "M288 64c0-17.7 14.3-32 32-32h32c17.7 0 32 14.3 32 32s-14.3 32-32 32h-32c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h96c17.7 0 32 14.3 32 32s-14.3 32-32 32h-96c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h160c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32m0 128c0-17.7 14.3-32 32-32h224c17.7 0 32 14.3 32 32s-14.3 32-32 32H320c-17.7 0-32-14.3-32-32",
|
|
918
918
|
opacity: n ? "1" : "0.4"
|
|
919
919
|
}
|
|
920
920
|
),
|
|
921
|
-
/* @__PURE__ */
|
|
921
|
+
/* @__PURE__ */ u("path", { d: "M128 32c9 0 17.5 3.8 23.6 10.4l88 96c11.9 13 11.1 33.3-2 45.2s-33.3 11.1-45.2-2L160 146.3V448c0 17.7-14.3 32-32 32s-32-14.3-32-32V146.3l-32.4 35.3c-11.9 13-32.2 13.9-45.2 2s-13.9-32.2-2-45.2l88-96C110.5 35.8 119 32 128 32" })
|
|
922
922
|
]
|
|
923
923
|
}
|
|
924
924
|
);
|
|
@@ -935,13 +935,13 @@ try {
|
|
|
935
935
|
});
|
|
936
936
|
} catch {
|
|
937
937
|
}
|
|
938
|
-
const
|
|
938
|
+
const Ce = V.createContext({
|
|
939
939
|
mode: "light",
|
|
940
940
|
cellWrapper: "thead",
|
|
941
941
|
stickyHeader: !1,
|
|
942
942
|
stickyFooter: !1,
|
|
943
943
|
compact: !1
|
|
944
|
-
}),
|
|
944
|
+
}), rl = ({
|
|
945
945
|
children: e,
|
|
946
946
|
mode: t = "system",
|
|
947
947
|
caption: r,
|
|
@@ -954,88 +954,88 @@ const Ne = V.createContext({
|
|
|
954
954
|
stickyFooter: c,
|
|
955
955
|
...g
|
|
956
956
|
}) => {
|
|
957
|
-
const
|
|
957
|
+
const d = ja({
|
|
958
958
|
mode: t,
|
|
959
959
|
className: o,
|
|
960
960
|
wrapperClassName: s,
|
|
961
961
|
stickyHeader: l,
|
|
962
962
|
stickyFooter: c
|
|
963
963
|
});
|
|
964
|
-
return /* @__PURE__ */
|
|
965
|
-
|
|
964
|
+
return /* @__PURE__ */ u(
|
|
965
|
+
Ce.Provider,
|
|
966
966
|
{
|
|
967
967
|
value: { mode: t, stickyHeader: l, stickyFooter: c, compact: n },
|
|
968
|
-
children: /* @__PURE__ */
|
|
968
|
+
children: /* @__PURE__ */ u(
|
|
969
969
|
"div",
|
|
970
970
|
{
|
|
971
|
-
className:
|
|
971
|
+
className: d.wrapper,
|
|
972
972
|
...i && {
|
|
973
973
|
style: { maxHeight: i }
|
|
974
974
|
},
|
|
975
|
-
children: /* @__PURE__ */ C("table", { className:
|
|
976
|
-
r && /* @__PURE__ */
|
|
975
|
+
children: /* @__PURE__ */ C("table", { className: d.table, summary: a, ...g, children: [
|
|
976
|
+
r && /* @__PURE__ */ u("caption", { className: d.caption, children: r }),
|
|
977
977
|
e
|
|
978
978
|
] })
|
|
979
979
|
}
|
|
980
980
|
)
|
|
981
981
|
}
|
|
982
982
|
);
|
|
983
|
-
},
|
|
983
|
+
}, nl = ({
|
|
984
984
|
children: e,
|
|
985
985
|
className: t,
|
|
986
986
|
...r
|
|
987
987
|
}) => {
|
|
988
|
-
const n = W(
|
|
989
|
-
n.cellWrapper =
|
|
990
|
-
const a =
|
|
988
|
+
const n = W(Ce);
|
|
989
|
+
n.cellWrapper = rt;
|
|
990
|
+
const a = qa({
|
|
991
991
|
className: t,
|
|
992
992
|
mode: n.mode,
|
|
993
993
|
stickyHeader: n.stickyHeader
|
|
994
994
|
});
|
|
995
|
-
return /* @__PURE__ */
|
|
996
|
-
},
|
|
995
|
+
return /* @__PURE__ */ u("thead", { className: a, ...r, children: e });
|
|
996
|
+
}, al = ({
|
|
997
997
|
children: e,
|
|
998
998
|
className: t,
|
|
999
999
|
...r
|
|
1000
1000
|
}) => {
|
|
1001
|
-
const n = W(
|
|
1001
|
+
const n = W(Ce);
|
|
1002
1002
|
n.cellWrapper = qt;
|
|
1003
|
-
const a =
|
|
1003
|
+
const a = Ka({
|
|
1004
1004
|
className: t,
|
|
1005
1005
|
mode: n.mode,
|
|
1006
1006
|
stickyFooter: n.stickyFooter
|
|
1007
1007
|
});
|
|
1008
|
-
return /* @__PURE__ */
|
|
1009
|
-
},
|
|
1010
|
-
const r = W(
|
|
1011
|
-
return r.cellWrapper = xe, /* @__PURE__ */
|
|
1012
|
-
},
|
|
1008
|
+
return /* @__PURE__ */ u("tfoot", { className: a, ...r, children: e });
|
|
1009
|
+
}, ol = ({ children: e, ...t }) => {
|
|
1010
|
+
const r = W(Ce);
|
|
1011
|
+
return r.cellWrapper = xe, /* @__PURE__ */ u("tbody", { ...t, children: e });
|
|
1012
|
+
}, sl = ({
|
|
1013
1013
|
children: e,
|
|
1014
1014
|
className: t,
|
|
1015
1015
|
...r
|
|
1016
1016
|
}) => {
|
|
1017
|
-
const n = W(
|
|
1017
|
+
const n = W(Ce), a = Ya({
|
|
1018
1018
|
mode: n.mode,
|
|
1019
1019
|
cellWrapper: n.cellWrapper,
|
|
1020
1020
|
className: t
|
|
1021
1021
|
});
|
|
1022
|
-
return /* @__PURE__ */
|
|
1023
|
-
},
|
|
1022
|
+
return /* @__PURE__ */ u("tr", { className: a, ...r, children: e });
|
|
1023
|
+
}, fo = ({
|
|
1024
1024
|
children: e,
|
|
1025
1025
|
component: t,
|
|
1026
1026
|
className: r,
|
|
1027
1027
|
align: n,
|
|
1028
1028
|
...a
|
|
1029
1029
|
}) => {
|
|
1030
|
-
const o = W(
|
|
1030
|
+
const o = W(Ce), s = t || (o.cellWrapper === rt ? "th" : "td"), { mainClasses: i, alignClasses: l } = Ja({
|
|
1031
1031
|
cellWrapper: o.cellWrapper,
|
|
1032
1032
|
className: r,
|
|
1033
1033
|
mode: o.mode,
|
|
1034
1034
|
compact: o.compact,
|
|
1035
1035
|
align: n
|
|
1036
1036
|
});
|
|
1037
|
-
return n ? /* @__PURE__ */
|
|
1038
|
-
},
|
|
1037
|
+
return n ? /* @__PURE__ */ u(s, { className: i, ...a, children: /* @__PURE__ */ u("div", { className: l, children: e }) }) : /* @__PURE__ */ u(s, { className: i, ...a, children: e });
|
|
1038
|
+
}, il = ({
|
|
1039
1039
|
align: e,
|
|
1040
1040
|
children: t,
|
|
1041
1041
|
buttonClassName: r,
|
|
@@ -1047,18 +1047,18 @@ const Ne = V.createContext({
|
|
|
1047
1047
|
sortDirection: l,
|
|
1048
1048
|
sortedCell: c,
|
|
1049
1049
|
cellId: g,
|
|
1050
|
-
...
|
|
1050
|
+
...d
|
|
1051
1051
|
}) => {
|
|
1052
|
-
const f =
|
|
1053
|
-
return /* @__PURE__ */
|
|
1054
|
-
|
|
1052
|
+
const f = Xa({ buttonClassName: r });
|
|
1053
|
+
return /* @__PURE__ */ u(
|
|
1054
|
+
fo,
|
|
1055
1055
|
{
|
|
1056
1056
|
component: a,
|
|
1057
1057
|
className: n,
|
|
1058
1058
|
role: "columnheader",
|
|
1059
|
-
"aria-sort": l ===
|
|
1060
|
-
...
|
|
1061
|
-
children: /* @__PURE__ */
|
|
1059
|
+
"aria-sort": l === Oe.ASC && c === g ? "ascending" : l === Oe.DESC && c === g ? "descending" : "other",
|
|
1060
|
+
...d,
|
|
1061
|
+
children: /* @__PURE__ */ u(
|
|
1062
1062
|
cn,
|
|
1063
1063
|
{
|
|
1064
1064
|
active: c === g,
|
|
@@ -1070,7 +1070,7 @@ const Ne = V.createContext({
|
|
|
1070
1070
|
mode: s,
|
|
1071
1071
|
fullWidth: !0,
|
|
1072
1072
|
labelRight: t,
|
|
1073
|
-
children: l ===
|
|
1073
|
+
children: l === Oe.ASC && c === g ? /* @__PURE__ */ u(mo, { className: "size-4", monotone: !0 }) : l === Oe.DESC && c === g ? /* @__PURE__ */ u(uo, { className: "size-4", monotone: !0 }) : /* @__PURE__ */ u(co, { className: "size-4", monotone: !0 })
|
|
1074
1074
|
}
|
|
1075
1075
|
)
|
|
1076
1076
|
}
|
|
@@ -1078,38 +1078,39 @@ const Ne = V.createContext({
|
|
|
1078
1078
|
}, F = [];
|
|
1079
1079
|
for (let e = 0; e < 256; ++e)
|
|
1080
1080
|
F.push((e + 256).toString(16).slice(1));
|
|
1081
|
-
function
|
|
1081
|
+
function go(e, t = 0) {
|
|
1082
1082
|
return (F[e[t + 0]] + F[e[t + 1]] + F[e[t + 2]] + F[e[t + 3]] + "-" + F[e[t + 4]] + F[e[t + 5]] + "-" + F[e[t + 6]] + F[e[t + 7]] + "-" + F[e[t + 8]] + F[e[t + 9]] + "-" + F[e[t + 10]] + F[e[t + 11]] + F[e[t + 12]] + F[e[t + 13]] + F[e[t + 14]] + F[e[t + 15]]).toLowerCase();
|
|
1083
1083
|
}
|
|
1084
|
-
let
|
|
1085
|
-
const
|
|
1086
|
-
function
|
|
1087
|
-
if (!
|
|
1084
|
+
let bt;
|
|
1085
|
+
const ho = new Uint8Array(16);
|
|
1086
|
+
function po() {
|
|
1087
|
+
if (!bt) {
|
|
1088
1088
|
if (typeof crypto > "u" || !crypto.getRandomValues)
|
|
1089
1089
|
throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
|
|
1090
|
-
|
|
1090
|
+
bt = crypto.getRandomValues.bind(crypto);
|
|
1091
1091
|
}
|
|
1092
|
-
return
|
|
1092
|
+
return bt(ho);
|
|
1093
1093
|
}
|
|
1094
|
-
const
|
|
1094
|
+
const yo = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), Cr = { randomUUID: yo };
|
|
1095
1095
|
function Jt(e, t, r) {
|
|
1096
1096
|
var a;
|
|
1097
1097
|
if (Cr.randomUUID && !e)
|
|
1098
1098
|
return Cr.randomUUID();
|
|
1099
1099
|
e = e || {};
|
|
1100
|
-
const n = e.random ?? ((a = e.rng) == null ? void 0 : a.call(e)) ??
|
|
1100
|
+
const n = e.random ?? ((a = e.rng) == null ? void 0 : a.call(e)) ?? po();
|
|
1101
1101
|
if (n.length < 16)
|
|
1102
1102
|
throw new Error("Random bytes length must be >= 16");
|
|
1103
|
-
return n[6] = n[6] & 15 | 64, n[8] = n[8] & 63 | 128,
|
|
1103
|
+
return n[6] = n[6] & 15 | 64, n[8] = n[8] & 63 | 128, go(n);
|
|
1104
1104
|
}
|
|
1105
|
-
const
|
|
1106
|
-
|
|
1107
|
-
|
|
1105
|
+
const bo = (e, t) => {
|
|
1106
|
+
var r;
|
|
1107
|
+
if ((t == null ? void 0 : t.type) === jn) {
|
|
1108
|
+
const n = t.payload.messages.map((a) => ({
|
|
1108
1109
|
message: {
|
|
1109
|
-
role:
|
|
1110
|
-
content:
|
|
1111
|
-
name:
|
|
1112
|
-
processingTime:
|
|
1110
|
+
role: a.role,
|
|
1111
|
+
content: a.content,
|
|
1112
|
+
name: a.name,
|
|
1113
|
+
processingTime: a.processingTime
|
|
1113
1114
|
}
|
|
1114
1115
|
}));
|
|
1115
1116
|
return {
|
|
@@ -1117,42 +1118,42 @@ const vo = (e, t) => {
|
|
|
1117
1118
|
model: t.payload.model,
|
|
1118
1119
|
usage: t.payload.usage,
|
|
1119
1120
|
isComponent: e.isComponent,
|
|
1120
|
-
messages:
|
|
1121
|
+
messages: n,
|
|
1121
1122
|
engine: e.engine,
|
|
1122
1123
|
prompts: e.prompts,
|
|
1123
1124
|
streaming: e.streaming,
|
|
1124
1125
|
lastTriggeredTimestamp: e.lastTriggeredTimestamp
|
|
1125
1126
|
};
|
|
1126
1127
|
}
|
|
1127
|
-
if ((t == null ? void 0 : t.type) ===
|
|
1128
|
-
const
|
|
1129
|
-
if (
|
|
1130
|
-
const
|
|
1131
|
-
role:
|
|
1132
|
-
content:
|
|
1133
|
-
name:
|
|
1134
|
-
processingTime:
|
|
1135
|
-
messageId:
|
|
1128
|
+
if ((t == null ? void 0 : t.type) === Ae) {
|
|
1129
|
+
const n = t.payload.message.role, a = t.payload.message.content, o = t.payload.message.name, s = t.payload.message.processingTime, i = t.payload.message.messageId;
|
|
1130
|
+
if (n !== "") {
|
|
1131
|
+
const l = {
|
|
1132
|
+
role: n,
|
|
1133
|
+
content: a,
|
|
1134
|
+
name: o,
|
|
1135
|
+
processingTime: s,
|
|
1136
|
+
messageId: i
|
|
1136
1137
|
};
|
|
1137
|
-
if (
|
|
1138
|
-
const
|
|
1139
|
-
(
|
|
1138
|
+
if (n === Be) {
|
|
1139
|
+
const c = e.messages.findIndex(
|
|
1140
|
+
(g) => g.message.messageId === i
|
|
1140
1141
|
);
|
|
1141
|
-
if (
|
|
1142
|
-
const
|
|
1142
|
+
if (c !== -1) {
|
|
1143
|
+
const g = e.messages.map((d, f) => f === c ? {
|
|
1143
1144
|
message: {
|
|
1144
|
-
...
|
|
1145
|
-
content: `${
|
|
1146
|
-
processingTime:
|
|
1147
|
-
name:
|
|
1145
|
+
...d.message,
|
|
1146
|
+
content: `${d.message.content}${a}`,
|
|
1147
|
+
processingTime: s,
|
|
1148
|
+
name: o
|
|
1148
1149
|
}
|
|
1149
|
-
} :
|
|
1150
|
+
} : d);
|
|
1150
1151
|
return {
|
|
1151
1152
|
id: e.id,
|
|
1152
1153
|
model: e.model,
|
|
1153
1154
|
usage: e.usage,
|
|
1154
1155
|
isComponent: e.isComponent,
|
|
1155
|
-
messages:
|
|
1156
|
+
messages: g,
|
|
1156
1157
|
engine: e.engine,
|
|
1157
1158
|
prompts: e.prompts,
|
|
1158
1159
|
streaming: e.streaming,
|
|
@@ -1172,17 +1173,17 @@ const vo = (e, t) => {
|
|
|
1172
1173
|
messages: [
|
|
1173
1174
|
...e.messages,
|
|
1174
1175
|
{
|
|
1175
|
-
message:
|
|
1176
|
+
message: l
|
|
1176
1177
|
}
|
|
1177
1178
|
]
|
|
1178
1179
|
};
|
|
1179
1180
|
}
|
|
1180
1181
|
}
|
|
1181
|
-
if ((t == null ? void 0 : t.type) ===
|
|
1182
|
+
if ((t == null ? void 0 : t.type) === et)
|
|
1182
1183
|
return {
|
|
1183
1184
|
id: Jt(),
|
|
1184
1185
|
model: e.model,
|
|
1185
|
-
engine: e.engine,
|
|
1186
|
+
engine: ((r = t == null ? void 0 : t.payload) == null ? void 0 : r.engine) || e.engine,
|
|
1186
1187
|
usage: 0,
|
|
1187
1188
|
messages: [],
|
|
1188
1189
|
isComponent: e.isComponent,
|
|
@@ -1203,23 +1204,23 @@ const vo = (e, t) => {
|
|
|
1203
1204
|
lastTriggeredTimestamp: e.lastTriggeredTimestamp
|
|
1204
1205
|
};
|
|
1205
1206
|
if ((t == null ? void 0 : t.type) === Jr) {
|
|
1206
|
-
let
|
|
1207
|
-
return e.streaming !== t.payload.streaming && (
|
|
1207
|
+
let n = e.lastTriggeredTimestamp;
|
|
1208
|
+
return e.streaming !== t.payload.streaming && (n = (/* @__PURE__ */ new Date()).getTime()), {
|
|
1208
1209
|
...e,
|
|
1209
1210
|
streaming: t.payload.streaming,
|
|
1210
|
-
lastTriggeredTimestamp:
|
|
1211
|
+
lastTriggeredTimestamp: n
|
|
1211
1212
|
};
|
|
1212
1213
|
}
|
|
1213
1214
|
return e;
|
|
1214
|
-
},
|
|
1215
|
+
}, vo = (e, t) => {
|
|
1215
1216
|
switch (t == null ? void 0 : t.type) {
|
|
1216
|
-
case
|
|
1217
|
+
case Kn:
|
|
1217
1218
|
return {
|
|
1218
1219
|
searchString: t.payload.searchString,
|
|
1219
1220
|
sortedCell: e.sortedCell,
|
|
1220
1221
|
sortDirection: e.sortDirection
|
|
1221
1222
|
};
|
|
1222
|
-
case
|
|
1223
|
+
case qn:
|
|
1223
1224
|
return {
|
|
1224
1225
|
searchString: e.searchString,
|
|
1225
1226
|
sortedCell: t.payload.sortedCell,
|
|
@@ -1228,7 +1229,7 @@ const vo = (e, t) => {
|
|
|
1228
1229
|
default:
|
|
1229
1230
|
return e;
|
|
1230
1231
|
}
|
|
1231
|
-
},
|
|
1232
|
+
}, ko = (e, t) => {
|
|
1232
1233
|
switch (t == null ? void 0 : t.type) {
|
|
1233
1234
|
case Zr:
|
|
1234
1235
|
return {
|
|
@@ -1244,7 +1245,7 @@ const vo = (e, t) => {
|
|
|
1244
1245
|
return e;
|
|
1245
1246
|
}
|
|
1246
1247
|
};
|
|
1247
|
-
var Ge = { exports: {} },
|
|
1248
|
+
var Ge = { exports: {} }, vt = {};
|
|
1248
1249
|
/**
|
|
1249
1250
|
* @license React
|
|
1250
1251
|
* use-sync-external-store-shim.production.js
|
|
@@ -1255,47 +1256,47 @@ var Ge = { exports: {} }, bt = {};
|
|
|
1255
1256
|
* LICENSE file in the root directory of this source tree.
|
|
1256
1257
|
*/
|
|
1257
1258
|
var Rr;
|
|
1258
|
-
function
|
|
1259
|
-
if (Rr) return
|
|
1259
|
+
function xo() {
|
|
1260
|
+
if (Rr) return vt;
|
|
1260
1261
|
Rr = 1;
|
|
1261
1262
|
var e = V;
|
|
1262
|
-
function t(
|
|
1263
|
-
return
|
|
1263
|
+
function t(d, f) {
|
|
1264
|
+
return d === f && (d !== 0 || 1 / d === 1 / f) || d !== d && f !== f;
|
|
1264
1265
|
}
|
|
1265
1266
|
var r = typeof Object.is == "function" ? Object.is : t, n = e.useState, a = e.useEffect, o = e.useLayoutEffect, s = e.useDebugValue;
|
|
1266
|
-
function i(
|
|
1267
|
+
function i(d, f) {
|
|
1267
1268
|
var m = f(), p = n({ inst: { value: m, getSnapshot: f } }), y = p[0].inst, v = p[1];
|
|
1268
1269
|
return o(
|
|
1269
1270
|
function() {
|
|
1270
1271
|
y.value = m, y.getSnapshot = f, l(y) && v({ inst: y });
|
|
1271
1272
|
},
|
|
1272
|
-
[
|
|
1273
|
+
[d, m, f]
|
|
1273
1274
|
), a(
|
|
1274
1275
|
function() {
|
|
1275
|
-
return l(y) && v({ inst: y }),
|
|
1276
|
+
return l(y) && v({ inst: y }), d(function() {
|
|
1276
1277
|
l(y) && v({ inst: y });
|
|
1277
1278
|
});
|
|
1278
1279
|
},
|
|
1279
|
-
[
|
|
1280
|
+
[d]
|
|
1280
1281
|
), s(m), m;
|
|
1281
1282
|
}
|
|
1282
|
-
function l(
|
|
1283
|
-
var f =
|
|
1284
|
-
|
|
1283
|
+
function l(d) {
|
|
1284
|
+
var f = d.getSnapshot;
|
|
1285
|
+
d = d.value;
|
|
1285
1286
|
try {
|
|
1286
1287
|
var m = f();
|
|
1287
|
-
return !r(
|
|
1288
|
+
return !r(d, m);
|
|
1288
1289
|
} catch {
|
|
1289
1290
|
return !0;
|
|
1290
1291
|
}
|
|
1291
1292
|
}
|
|
1292
|
-
function c(
|
|
1293
|
+
function c(d, f) {
|
|
1293
1294
|
return f();
|
|
1294
1295
|
}
|
|
1295
1296
|
var g = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? c : i;
|
|
1296
|
-
return
|
|
1297
|
+
return vt.useSyncExternalStore = e.useSyncExternalStore !== void 0 ? e.useSyncExternalStore : g, vt;
|
|
1297
1298
|
}
|
|
1298
|
-
var
|
|
1299
|
+
var kt = {};
|
|
1299
1300
|
/**
|
|
1300
1301
|
* @license React
|
|
1301
1302
|
* use-sync-external-store-shim.development.js
|
|
@@ -1306,7 +1307,7 @@ var vt = {};
|
|
|
1306
1307
|
* LICENSE file in the root directory of this source tree.
|
|
1307
1308
|
*/
|
|
1308
1309
|
var Ir;
|
|
1309
|
-
function
|
|
1310
|
+
function wo() {
|
|
1310
1311
|
return Ir || (Ir = 1, process.env.NODE_ENV !== "production" && function() {
|
|
1311
1312
|
function e(m, p) {
|
|
1312
1313
|
return m === p && (m !== 0 || 1 / m === 1 / p) || m !== m && p !== p;
|
|
@@ -1316,11 +1317,11 @@ function _o() {
|
|
|
1316
1317
|
"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."
|
|
1317
1318
|
));
|
|
1318
1319
|
var y = p();
|
|
1319
|
-
if (!
|
|
1320
|
+
if (!d) {
|
|
1320
1321
|
var v = p();
|
|
1321
1322
|
o(y, v) || (console.error(
|
|
1322
1323
|
"The result of getSnapshot should be cached to avoid an infinite loop"
|
|
1323
|
-
),
|
|
1324
|
+
), d = !0);
|
|
1324
1325
|
}
|
|
1325
1326
|
v = s({
|
|
1326
1327
|
inst: { value: y, getSnapshot: p }
|
|
@@ -1354,16 +1355,16 @@ function _o() {
|
|
|
1354
1355
|
return p();
|
|
1355
1356
|
}
|
|
1356
1357
|
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
1357
|
-
var a = V, o = typeof Object.is == "function" ? Object.is : e, s = a.useState, i = a.useEffect, l = a.useLayoutEffect, c = a.useDebugValue, g = !1,
|
|
1358
|
-
|
|
1359
|
-
}()),
|
|
1358
|
+
var a = V, o = typeof Object.is == "function" ? Object.is : e, s = a.useState, i = a.useEffect, l = a.useLayoutEffect, c = a.useDebugValue, g = !1, d = !1, f = typeof window > "u" || typeof window.document > "u" || typeof window.document.createElement > "u" ? n : t;
|
|
1359
|
+
kt.useSyncExternalStore = a.useSyncExternalStore !== void 0 ? a.useSyncExternalStore : f, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
1360
|
+
}()), kt;
|
|
1360
1361
|
}
|
|
1361
1362
|
var Lr;
|
|
1362
|
-
function
|
|
1363
|
-
return Lr || (Lr = 1, process.env.NODE_ENV === "production" ? Ge.exports = /* @__PURE__ */
|
|
1363
|
+
function _o() {
|
|
1364
|
+
return Lr || (Lr = 1, process.env.NODE_ENV === "production" ? Ge.exports = /* @__PURE__ */ xo() : Ge.exports = /* @__PURE__ */ wo()), Ge.exports;
|
|
1364
1365
|
}
|
|
1365
|
-
var
|
|
1366
|
-
function
|
|
1366
|
+
var Eo = /* @__PURE__ */ _o(), Or = Object.prototype.hasOwnProperty;
|
|
1367
|
+
function Ot(e, t) {
|
|
1367
1368
|
var r, n;
|
|
1368
1369
|
if (e === t) return !0;
|
|
1369
1370
|
if (e && t && (r = e.constructor) === t.constructor) {
|
|
@@ -1371,13 +1372,13 @@ function Lt(e, t) {
|
|
|
1371
1372
|
if (r === RegExp) return e.toString() === t.toString();
|
|
1372
1373
|
if (r === Array) {
|
|
1373
1374
|
if ((n = e.length) === t.length)
|
|
1374
|
-
for (; n-- &&
|
|
1375
|
+
for (; n-- && Ot(e[n], t[n]); ) ;
|
|
1375
1376
|
return n === -1;
|
|
1376
1377
|
}
|
|
1377
1378
|
if (!r || typeof e == "object") {
|
|
1378
1379
|
n = 0;
|
|
1379
1380
|
for (r in e)
|
|
1380
|
-
if (Or.call(e, r) && ++n && !Or.call(t, r) || !(r in t) || !
|
|
1381
|
+
if (Or.call(e, r) && ++n && !Or.call(t, r) || !(r in t) || !Ot(e[r], t[r])) return !1;
|
|
1381
1382
|
return Object.keys(t).length === n;
|
|
1382
1383
|
}
|
|
1383
1384
|
}
|
|
@@ -1387,80 +1388,80 @@ const oe = /* @__PURE__ */ new WeakMap(), fe = () => {
|
|
|
1387
1388
|
}, J = (
|
|
1388
1389
|
/*#__NOINLINE__*/
|
|
1389
1390
|
fe()
|
|
1390
|
-
),
|
|
1391
|
+
), At = Object, N = (e) => e === J, se = (e) => typeof e == "function", ge = (e, t) => ({
|
|
1391
1392
|
...e,
|
|
1392
1393
|
...t
|
|
1393
|
-
}), dn = (e) => se(e.then),
|
|
1394
|
+
}), dn = (e) => se(e.then), xt = {}, je = {}, Xt = "undefined", nt = typeof window != Xt, Bt = typeof document != Xt, To = () => nt && typeof window.requestAnimationFrame != Xt, un = (e, t) => {
|
|
1394
1395
|
const r = oe.get(e);
|
|
1395
1396
|
return [
|
|
1396
1397
|
// Getter
|
|
1397
|
-
() => !N(t) && e.get(t) ||
|
|
1398
|
+
() => !N(t) && e.get(t) || xt,
|
|
1398
1399
|
// Setter
|
|
1399
1400
|
(n) => {
|
|
1400
1401
|
if (!N(t)) {
|
|
1401
1402
|
const a = e.get(t);
|
|
1402
|
-
t in je || (je[t] = a), r[5](t, ge(a, n), a ||
|
|
1403
|
+
t in je || (je[t] = a), r[5](t, ge(a, n), a || xt);
|
|
1403
1404
|
}
|
|
1404
1405
|
},
|
|
1405
1406
|
// Subscriber
|
|
1406
1407
|
r[6],
|
|
1407
1408
|
// Get server cache snapshot
|
|
1408
|
-
() => !N(t) && t in je ? je[t] : !N(t) && e.get(t) ||
|
|
1409
|
+
() => !N(t) && t in je ? je[t] : !N(t) && e.get(t) || xt
|
|
1409
1410
|
];
|
|
1410
1411
|
};
|
|
1411
|
-
let
|
|
1412
|
-
const
|
|
1412
|
+
let Mt = !0;
|
|
1413
|
+
const So = () => Mt, [$t, Dt] = nt && window.addEventListener ? [
|
|
1413
1414
|
window.addEventListener.bind(window),
|
|
1414
1415
|
window.removeEventListener.bind(window)
|
|
1415
1416
|
] : [
|
|
1416
1417
|
fe,
|
|
1417
1418
|
fe
|
|
1418
|
-
],
|
|
1419
|
-
const e =
|
|
1419
|
+
], No = () => {
|
|
1420
|
+
const e = Bt && document.visibilityState;
|
|
1420
1421
|
return N(e) || e !== "hidden";
|
|
1421
|
-
},
|
|
1422
|
-
|
|
1423
|
-
}),
|
|
1422
|
+
}, Co = (e) => (Bt && document.addEventListener("visibilitychange", e), $t("focus", e), () => {
|
|
1423
|
+
Bt && document.removeEventListener("visibilitychange", e), Dt("focus", e);
|
|
1424
|
+
}), Ro = (e) => {
|
|
1424
1425
|
const t = () => {
|
|
1425
|
-
|
|
1426
|
+
Mt = !0, e();
|
|
1426
1427
|
}, r = () => {
|
|
1427
|
-
|
|
1428
|
+
Mt = !1;
|
|
1428
1429
|
};
|
|
1429
|
-
return
|
|
1430
|
-
|
|
1430
|
+
return $t("online", t), $t("offline", r), () => {
|
|
1431
|
+
Dt("online", t), Dt("offline", r);
|
|
1431
1432
|
};
|
|
1433
|
+
}, Io = {
|
|
1434
|
+
isOnline: So,
|
|
1435
|
+
isVisible: No
|
|
1432
1436
|
}, Lo = {
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
}, Oo =
|
|
1436
|
-
initFocus: Ro,
|
|
1437
|
-
initReconnect: Io
|
|
1438
|
-
}, Ar = !V.useId, Me = !rt || "Deno" in globalThis, Ao = (e) => So() ? window.requestAnimationFrame(e) : setTimeout(e, 1), xt = Me ? P : ma, wt = typeof navigator < "u" && navigator.connection, Br = !Me && wt && ([
|
|
1437
|
+
initFocus: Co,
|
|
1438
|
+
initReconnect: Ro
|
|
1439
|
+
}, Ar = !V.useId, Me = !nt || "Deno" in globalThis, Oo = (e) => To() ? window.requestAnimationFrame(e) : setTimeout(e, 1), wt = Me ? D : ua, _t = typeof navigator < "u" && navigator.connection, Br = !Me && _t && ([
|
|
1439
1440
|
"slow-2g",
|
|
1440
1441
|
"2g"
|
|
1441
|
-
].includes(
|
|
1442
|
-
let
|
|
1443
|
-
const
|
|
1444
|
-
const t = typeof e, r =
|
|
1442
|
+
].includes(_t.effectiveType) || _t.saveData), qe = /* @__PURE__ */ new WeakMap(), Et = (e, t) => At.prototype.toString.call(e) === `[object ${t}]`;
|
|
1443
|
+
let Ao = 0;
|
|
1444
|
+
const Pt = (e) => {
|
|
1445
|
+
const t = typeof e, r = Et(e, "Date"), n = Et(e, "RegExp"), a = Et(e, "Object");
|
|
1445
1446
|
let o, s;
|
|
1446
|
-
if (
|
|
1447
|
+
if (At(e) === e && !r && !n) {
|
|
1447
1448
|
if (o = qe.get(e), o) return o;
|
|
1448
|
-
if (o = ++
|
|
1449
|
+
if (o = ++Ao + "~", qe.set(e, o), Array.isArray(e)) {
|
|
1449
1450
|
for (o = "@", s = 0; s < e.length; s++)
|
|
1450
|
-
o +=
|
|
1451
|
+
o += Pt(e[s]) + ",";
|
|
1451
1452
|
qe.set(e, o);
|
|
1452
1453
|
}
|
|
1453
1454
|
if (a) {
|
|
1454
1455
|
o = "#";
|
|
1455
|
-
const i =
|
|
1456
|
+
const i = At.keys(e).sort();
|
|
1456
1457
|
for (; !N(s = i.pop()); )
|
|
1457
|
-
N(e[s]) || (o += s + ":" +
|
|
1458
|
+
N(e[s]) || (o += s + ":" + Pt(e[s]) + ",");
|
|
1458
1459
|
qe.set(e, o);
|
|
1459
1460
|
}
|
|
1460
1461
|
} else
|
|
1461
1462
|
o = r ? e.toJSON() : t == "symbol" ? e.toString() : t == "string" ? JSON.stringify(e) : "" + e;
|
|
1462
1463
|
return o;
|
|
1463
|
-
},
|
|
1464
|
+
}, at = (e) => {
|
|
1464
1465
|
if (se(e))
|
|
1465
1466
|
try {
|
|
1466
1467
|
e = e();
|
|
@@ -1468,16 +1469,16 @@ const Dt = (e) => {
|
|
|
1468
1469
|
e = "";
|
|
1469
1470
|
}
|
|
1470
1471
|
const t = e;
|
|
1471
|
-
return e = typeof e == "string" ? e : (Array.isArray(e) ? e.length : e) ?
|
|
1472
|
+
return e = typeof e == "string" ? e : (Array.isArray(e) ? e.length : e) ? Pt(e) : "", [
|
|
1472
1473
|
e,
|
|
1473
1474
|
t
|
|
1474
1475
|
];
|
|
1475
1476
|
};
|
|
1476
|
-
let
|
|
1477
|
-
const
|
|
1478
|
-
var
|
|
1477
|
+
let Bo = 0;
|
|
1478
|
+
const Vt = () => ++Bo, mn = 0, fn = 1, gn = 2, Mo = 3;
|
|
1479
|
+
var Le = {
|
|
1479
1480
|
__proto__: null,
|
|
1480
|
-
ERROR_REVALIDATE_EVENT:
|
|
1481
|
+
ERROR_REVALIDATE_EVENT: Mo,
|
|
1481
1482
|
FOCUS_EVENT: mn,
|
|
1482
1483
|
MUTATE_EVENT: gn,
|
|
1483
1484
|
RECONNECT_EVENT: fn
|
|
@@ -1498,11 +1499,11 @@ async function hn(...e) {
|
|
|
1498
1499
|
for (const y of p)
|
|
1499
1500
|
// Skip the special useSWRInfinite and useSWRSubscription keys.
|
|
1500
1501
|
!/^\$(inf|sub)\$/.test(y) && f(t.get(y)._k) && m.push(y);
|
|
1501
|
-
return Promise.all(m.map(
|
|
1502
|
+
return Promise.all(m.map(d));
|
|
1502
1503
|
}
|
|
1503
|
-
return
|
|
1504
|
-
async function
|
|
1505
|
-
const [m] =
|
|
1504
|
+
return d(r);
|
|
1505
|
+
async function d(f) {
|
|
1506
|
+
const [m] = at(f);
|
|
1506
1507
|
if (!m) return;
|
|
1507
1508
|
const [p, y] = un(t, m), [v, b, k, w] = oe.get(t), _ = () => {
|
|
1508
1509
|
const B = v[m];
|
|
@@ -1511,12 +1512,12 @@ async function hn(...e) {
|
|
|
1511
1512
|
if (e.length < 3)
|
|
1512
1513
|
return _();
|
|
1513
1514
|
let x = n, E;
|
|
1514
|
-
const T =
|
|
1515
|
+
const T = Vt();
|
|
1515
1516
|
b[m] = [
|
|
1516
1517
|
T,
|
|
1517
1518
|
0
|
|
1518
1519
|
];
|
|
1519
|
-
const S = !N(l),
|
|
1520
|
+
const S = !N(l), P = p(), O = P.data, G = P._c, $ = N(G) ? O : G;
|
|
1520
1521
|
if (S && (l = se(l) ? l($, O) : l, y({
|
|
1521
1522
|
data: l,
|
|
1522
1523
|
_c: $
|
|
@@ -1550,7 +1551,7 @@ async function hn(...e) {
|
|
|
1550
1551
|
error: J,
|
|
1551
1552
|
_c: J
|
|
1552
1553
|
});
|
|
1553
|
-
if (b[m][1] =
|
|
1554
|
+
if (b[m][1] = Vt(), Promise.resolve(_()).then(() => {
|
|
1554
1555
|
y({
|
|
1555
1556
|
_c: J
|
|
1556
1557
|
});
|
|
@@ -1564,19 +1565,19 @@ async function hn(...e) {
|
|
|
1564
1565
|
const Mr = (e, t) => {
|
|
1565
1566
|
for (const r in e)
|
|
1566
1567
|
e[r][0] && e[r][0](t);
|
|
1567
|
-
},
|
|
1568
|
+
}, $o = (e, t) => {
|
|
1568
1569
|
if (!oe.has(e)) {
|
|
1569
|
-
const r = ge(
|
|
1570
|
+
const r = ge(Lo, t), n = {}, a = hn.bind(J, e);
|
|
1570
1571
|
let o = fe;
|
|
1571
|
-
const s = {}, i = (g,
|
|
1572
|
+
const s = {}, i = (g, d) => {
|
|
1572
1573
|
const f = s[g] || [];
|
|
1573
|
-
return s[g] = f, f.push(
|
|
1574
|
-
}, l = (g,
|
|
1575
|
-
e.set(g,
|
|
1574
|
+
return s[g] = f, f.push(d), () => f.splice(f.indexOf(d), 1);
|
|
1575
|
+
}, l = (g, d, f) => {
|
|
1576
|
+
e.set(g, d);
|
|
1576
1577
|
const m = s[g];
|
|
1577
1578
|
if (m)
|
|
1578
1579
|
for (const p of m)
|
|
1579
|
-
p(
|
|
1580
|
+
p(d, f);
|
|
1580
1581
|
}, c = () => {
|
|
1581
1582
|
if (!oe.has(e) && (oe.set(e, [
|
|
1582
1583
|
n,
|
|
@@ -1587,9 +1588,9 @@ const Mr = (e, t) => {
|
|
|
1587
1588
|
l,
|
|
1588
1589
|
i
|
|
1589
1590
|
]), !Me)) {
|
|
1590
|
-
const g = r.initFocus(setTimeout.bind(J, Mr.bind(J, n, mn))),
|
|
1591
|
+
const g = r.initFocus(setTimeout.bind(J, Mr.bind(J, n, mn))), d = r.initReconnect(setTimeout.bind(J, Mr.bind(J, n, fn)));
|
|
1591
1592
|
o = () => {
|
|
1592
|
-
g && g(),
|
|
1593
|
+
g && g(), d && d(), oe.delete(e);
|
|
1593
1594
|
};
|
|
1594
1595
|
}
|
|
1595
1596
|
};
|
|
@@ -1604,16 +1605,16 @@ const Mr = (e, t) => {
|
|
|
1604
1605
|
e,
|
|
1605
1606
|
oe.get(e)[4]
|
|
1606
1607
|
];
|
|
1607
|
-
},
|
|
1608
|
+
}, Do = (e, t, r, n, a) => {
|
|
1608
1609
|
const o = r.errorRetryCount, s = a.retryCount, i = ~~((Math.random() + 0.5) * (1 << (s < 8 ? s : 8))) * r.errorRetryInterval;
|
|
1609
1610
|
!N(o) && s > o || setTimeout(n, i, a);
|
|
1610
|
-
},
|
|
1611
|
+
}, Po = Ot, [Zt, Vo] = $o(/* @__PURE__ */ new Map()), zo = ge(
|
|
1611
1612
|
{
|
|
1612
1613
|
// events
|
|
1613
1614
|
onLoadingSlow: fe,
|
|
1614
1615
|
onSuccess: fe,
|
|
1615
1616
|
onError: fe,
|
|
1616
|
-
onErrorRetry:
|
|
1617
|
+
onErrorRetry: Do,
|
|
1617
1618
|
onDiscarded: fe,
|
|
1618
1619
|
// switches
|
|
1619
1620
|
revalidateOnFocus: !0,
|
|
@@ -1626,24 +1627,24 @@ const Mr = (e, t) => {
|
|
|
1626
1627
|
dedupingInterval: 2 * 1e3,
|
|
1627
1628
|
loadingTimeout: Br ? 5e3 : 3e3,
|
|
1628
1629
|
// providers
|
|
1629
|
-
compare:
|
|
1630
|
+
compare: Po,
|
|
1630
1631
|
isPaused: () => !1,
|
|
1631
1632
|
cache: Zt,
|
|
1632
|
-
mutate:
|
|
1633
|
+
mutate: Vo,
|
|
1633
1634
|
fallback: {}
|
|
1634
1635
|
},
|
|
1635
1636
|
// use web preset by default
|
|
1636
|
-
|
|
1637
|
-
),
|
|
1637
|
+
Io
|
|
1638
|
+
), Uo = (e, t) => {
|
|
1638
1639
|
const r = ge(e, t);
|
|
1639
1640
|
if (t) {
|
|
1640
1641
|
const { use: n, fallback: a } = e, { use: o, fallback: s } = t;
|
|
1641
1642
|
n && o && (r.use = n.concat(o)), a && s && (r.fallback = ge(a, s));
|
|
1642
1643
|
}
|
|
1643
1644
|
return r;
|
|
1644
|
-
},
|
|
1645
|
+
}, Ho = da({}), Fo = "$inf$", pn = nt && window.__SWR_DEVTOOLS_USE__, Wo = pn ? window.__SWR_DEVTOOLS_USE__ : [], Go = () => {
|
|
1645
1646
|
pn && (window.__SWR_DEVTOOLS_REACT__ = V);
|
|
1646
|
-
},
|
|
1647
|
+
}, jo = (e) => se(e[1]) ? [
|
|
1647
1648
|
e[0],
|
|
1648
1649
|
e[1],
|
|
1649
1650
|
e[2] || {}
|
|
@@ -1651,33 +1652,33 @@ const Mr = (e, t) => {
|
|
|
1651
1652
|
e[0],
|
|
1652
1653
|
null,
|
|
1653
1654
|
(e[1] === null ? e[2] : e[1]) || {}
|
|
1654
|
-
],
|
|
1655
|
-
const [r, n] =
|
|
1655
|
+
], qo = () => ge(zo, W(Ho)), yn = (e, t) => {
|
|
1656
|
+
const [r, n] = at(e), [, , , a] = oe.get(Zt);
|
|
1656
1657
|
if (a[r]) return a[r];
|
|
1657
1658
|
const o = t(n);
|
|
1658
1659
|
return a[r] = o, o;
|
|
1659
|
-
},
|
|
1660
|
-
const [s] =
|
|
1661
|
-
if (s.startsWith(
|
|
1660
|
+
}, Ko = (e) => (t, r, n) => e(t, r && ((...o) => {
|
|
1661
|
+
const [s] = at(t), [, , , i] = oe.get(Zt);
|
|
1662
|
+
if (s.startsWith(Fo))
|
|
1662
1663
|
return r(...o);
|
|
1663
1664
|
const l = i[s];
|
|
1664
1665
|
return N(l) ? r(...o) : (delete i[s], l);
|
|
1665
|
-
}), n),
|
|
1666
|
-
const n =
|
|
1666
|
+
}), n), Yo = Wo.concat(Ko), Jo = (e) => function(...r) {
|
|
1667
|
+
const n = qo(), [a, o, s] = jo(r), i = Uo(n, s);
|
|
1667
1668
|
let l = e;
|
|
1668
|
-
const { use: c } = i, g = (c || []).concat(
|
|
1669
|
-
for (let
|
|
1670
|
-
l = g[
|
|
1669
|
+
const { use: c } = i, g = (c || []).concat(Yo);
|
|
1670
|
+
for (let d = g.length; d--; )
|
|
1671
|
+
l = g[d](l);
|
|
1671
1672
|
return l(a, o || i.fetcher || null, i);
|
|
1672
|
-
},
|
|
1673
|
+
}, Xo = (e, t, r) => {
|
|
1673
1674
|
const n = t[e] || (t[e] = []);
|
|
1674
1675
|
return n.push(r), () => {
|
|
1675
1676
|
const a = n.indexOf(r);
|
|
1676
1677
|
a >= 0 && (n[a] = n[n.length - 1], n.pop());
|
|
1677
1678
|
};
|
|
1678
1679
|
};
|
|
1679
|
-
|
|
1680
|
-
const
|
|
1680
|
+
Go();
|
|
1681
|
+
const Tt = V.use || // This extra generic is to avoid TypeScript mixing up the generic and JSX sytax
|
|
1681
1682
|
// and emitting an error.
|
|
1682
1683
|
// We assume that this is only for the `use(thenable)` case, not `use(context)`.
|
|
1683
1684
|
// https://github.com/facebook/react/blob/aed00dacfb79d17c53218404c52b1c7aa59c4a89/packages/react-server/src/ReactFizzThenable.js#L45
|
|
@@ -1696,10 +1697,10 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1696
1697
|
e.status = "rejected", e.reason = t;
|
|
1697
1698
|
}), e;
|
|
1698
1699
|
}
|
|
1699
|
-
}),
|
|
1700
|
+
}), St = {
|
|
1700
1701
|
dedupe: !0
|
|
1701
|
-
},
|
|
1702
|
-
const { cache: n, compare: a, suspense: o, fallbackData: s, revalidateOnMount: i, revalidateIfStale: l, refreshInterval: c, refreshWhenHidden: g, refreshWhenOffline:
|
|
1702
|
+
}, Zo = (e, t, r) => {
|
|
1703
|
+
const { cache: n, compare: a, suspense: o, fallbackData: s, revalidateOnMount: i, revalidateIfStale: l, refreshInterval: c, refreshWhenHidden: g, refreshWhenOffline: d, keepPreviousData: f } = r, [m, p, y, v] = oe.get(n), [b, k] = at(e), w = A(!1), _ = A(!1), x = A(b), E = A(t), T = A(r), S = () => T.current, P = () => S().isVisible() && S().isOnline(), [O, G, $, B] = un(n, b), R = A({}).current, X = N(s) ? N(r.fallback) ? J : r.fallback[b] : s, q = (I, L) => {
|
|
1703
1704
|
for (const j in R) {
|
|
1704
1705
|
const M = j;
|
|
1705
1706
|
if (M === "data") {
|
|
@@ -1729,7 +1730,7 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1729
1730
|
}, [
|
|
1730
1731
|
n,
|
|
1731
1732
|
b
|
|
1732
|
-
]), z =
|
|
1733
|
+
]), z = Eo.useSyncExternalStore(te(
|
|
1733
1734
|
(I) => $(b, (L, j) => {
|
|
1734
1735
|
q(j, L) || I();
|
|
1735
1736
|
}),
|
|
@@ -1738,7 +1739,7 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1738
1739
|
n,
|
|
1739
1740
|
b
|
|
1740
1741
|
]
|
|
1741
|
-
), K[0], K[1]), U = !w.current,
|
|
1742
|
+
), K[0], K[1]), U = !w.current, ft = m[b] && m[b].length > 0, be = z.data, ve = N(be) ? X && dn(X) ? Tt(X) : X : be, Fe = z.error, dr = A(ve), We = f ? N(be) ? dr.current : be : ve, ur = ft && !N(Fe) ? !1 : U && !N(i) ? i : S().isPaused() ? !1 : o ? N(ve) ? !1 : l : N(ve) || l, mr = !!(b && t && U && ur), Fn = N(z.isValidating) ? mr : z.isValidating, Wn = N(z.isLoading) ? mr : z.isLoading, Ie = te(
|
|
1742
1743
|
async (I) => {
|
|
1743
1744
|
const L = E.current;
|
|
1744
1745
|
if (!b || !L || _.current || S().isPaused())
|
|
@@ -1761,7 +1762,7 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1761
1762
|
ae && Y() && S().onLoadingSlow(b, r);
|
|
1762
1763
|
}, r.loadingTimeout), y[b] = [
|
|
1763
1764
|
L(k),
|
|
1764
|
-
|
|
1765
|
+
Vt()
|
|
1765
1766
|
]), [j, M] = y[b], j = await j, H && setTimeout(hr, r.dedupingInterval), !y[b] || y[b][1] !== M)
|
|
1766
1767
|
return H && Y() && S().onDiscarded(b), !1;
|
|
1767
1768
|
ce.error = J;
|
|
@@ -1775,10 +1776,10 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1775
1776
|
ce.data = a(de, j) ? de : j, H && Y() && S().onSuccess(j, b, r);
|
|
1776
1777
|
} catch (ee) {
|
|
1777
1778
|
hr();
|
|
1778
|
-
const de = S(), { shouldRetryOnError:
|
|
1779
|
-
de.isPaused() || (ce.error = ee, H && Y() && (de.onError(ee, b, de), (
|
|
1780
|
-
const
|
|
1781
|
-
|
|
1779
|
+
const de = S(), { shouldRetryOnError: gt } = de;
|
|
1780
|
+
de.isPaused() || (ce.error = ee, H && Y() && (de.onError(ee, b, de), (gt === !0 || se(gt) && gt(ee)) && (!S().revalidateOnFocus || !S().revalidateOnReconnect || P()) && de.onErrorRetry(ee, b, de, (Gn) => {
|
|
1781
|
+
const ht = m[b];
|
|
1782
|
+
ht && ht[0] && ht[0](Le.ERROR_REVALIDATE_EVENT, Gn);
|
|
1782
1783
|
}, {
|
|
1783
1784
|
retryCount: (ke.retryCount || 0) + 1,
|
|
1784
1785
|
dedupe: !0
|
|
@@ -1807,40 +1808,40 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1807
1808
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
1808
1809
|
[]
|
|
1809
1810
|
);
|
|
1810
|
-
if (
|
|
1811
|
+
if (wt(() => {
|
|
1811
1812
|
E.current = t, T.current = r, N(be) || (dr.current = be);
|
|
1812
|
-
}),
|
|
1813
|
+
}), wt(() => {
|
|
1813
1814
|
if (!b) return;
|
|
1814
|
-
const I =
|
|
1815
|
+
const I = Ie.bind(J, St);
|
|
1815
1816
|
let L = 0;
|
|
1816
|
-
const M =
|
|
1817
|
-
if (ae ==
|
|
1817
|
+
const M = Xo(b, m, (ae, ke = {}) => {
|
|
1818
|
+
if (ae == Le.FOCUS_EVENT) {
|
|
1818
1819
|
const H = Date.now();
|
|
1819
|
-
S().revalidateOnFocus && H > L &&
|
|
1820
|
-
} else if (ae ==
|
|
1821
|
-
S().revalidateOnReconnect &&
|
|
1820
|
+
S().revalidateOnFocus && H > L && P() && (L = H + S().focusThrottleInterval, I());
|
|
1821
|
+
} else if (ae == Le.RECONNECT_EVENT)
|
|
1822
|
+
S().revalidateOnReconnect && P() && I();
|
|
1822
1823
|
else {
|
|
1823
|
-
if (ae ==
|
|
1824
|
-
return
|
|
1825
|
-
if (ae ==
|
|
1826
|
-
return
|
|
1824
|
+
if (ae == Le.MUTATE_EVENT)
|
|
1825
|
+
return Ie();
|
|
1826
|
+
if (ae == Le.ERROR_REVALIDATE_EVENT)
|
|
1827
|
+
return Ie(ke);
|
|
1827
1828
|
}
|
|
1828
1829
|
});
|
|
1829
1830
|
return _.current = !1, x.current = b, w.current = !0, G({
|
|
1830
1831
|
_k: k
|
|
1831
|
-
}), ur && (N(ve) || Me ? I() :
|
|
1832
|
+
}), ur && (N(ve) || Me ? I() : Oo(I)), () => {
|
|
1832
1833
|
_.current = !0, M();
|
|
1833
1834
|
};
|
|
1834
1835
|
}, [
|
|
1835
1836
|
b
|
|
1836
|
-
]),
|
|
1837
|
+
]), wt(() => {
|
|
1837
1838
|
let I;
|
|
1838
1839
|
function L() {
|
|
1839
1840
|
const M = se(c) ? c(O().data) : c;
|
|
1840
1841
|
M && I !== -1 && (I = setTimeout(j, M));
|
|
1841
1842
|
}
|
|
1842
1843
|
function j() {
|
|
1843
|
-
!O().error && (g || S().isVisible()) && (
|
|
1844
|
+
!O().error && (g || S().isVisible()) && (d || S().isOnline()) ? Ie(St).then(L) : L();
|
|
1844
1845
|
}
|
|
1845
1846
|
return L(), () => {
|
|
1846
1847
|
I && (clearTimeout(I), I = -1);
|
|
@@ -1848,20 +1849,20 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1848
1849
|
}, [
|
|
1849
1850
|
c,
|
|
1850
1851
|
g,
|
|
1851
|
-
|
|
1852
|
+
d,
|
|
1852
1853
|
b
|
|
1853
|
-
]),
|
|
1854
|
+
]), ma(We), o && N(ve) && b) {
|
|
1854
1855
|
if (!Ar && Me)
|
|
1855
1856
|
throw new Error("Fallback data is required when using Suspense in SSR.");
|
|
1856
1857
|
E.current = t, T.current = r, _.current = !1;
|
|
1857
1858
|
const I = v[b];
|
|
1858
1859
|
if (!N(I)) {
|
|
1859
1860
|
const L = fr(I);
|
|
1860
|
-
|
|
1861
|
+
Tt(L);
|
|
1861
1862
|
}
|
|
1862
1863
|
if (N(Fe)) {
|
|
1863
|
-
const L =
|
|
1864
|
-
N(We) || (L.status = "fulfilled", L.value = !0),
|
|
1864
|
+
const L = Ie(St);
|
|
1865
|
+
N(We) || (L.status = "fulfilled", L.value = !0), Tt(L);
|
|
1865
1866
|
} else
|
|
1866
1867
|
throw Fe;
|
|
1867
1868
|
}
|
|
@@ -1874,13 +1875,13 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
1874
1875
|
return R.error = !0, Fe;
|
|
1875
1876
|
},
|
|
1876
1877
|
get isValidating() {
|
|
1877
|
-
return R.isValidating = !0,
|
|
1878
|
+
return R.isValidating = !0, Fn;
|
|
1878
1879
|
},
|
|
1879
1880
|
get isLoading() {
|
|
1880
|
-
return R.isLoading = !0,
|
|
1881
|
+
return R.isLoading = !0, Wn;
|
|
1881
1882
|
}
|
|
1882
1883
|
};
|
|
1883
|
-
},
|
|
1884
|
+
}, Qo = Jo(Zo), me = {
|
|
1884
1885
|
GET_LOCATION: `query GetLocation($latitude: Float!, $longitude: Float!) {
|
|
1885
1886
|
location(latitude: $latitude, longitude: $longitude) {
|
|
1886
1887
|
country
|
|
@@ -2004,11 +2005,11 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2004
2005
|
schema: me.SET_USER_PREFERENCES,
|
|
2005
2006
|
method: "setUserPreferences"
|
|
2006
2007
|
}
|
|
2007
|
-
},
|
|
2008
|
+
}, bn = process.env.PUBLIC_SASSY_API_SERVER_URL, es = async ({
|
|
2008
2009
|
query: e,
|
|
2009
2010
|
data: t,
|
|
2010
2011
|
headers: r = {}
|
|
2011
|
-
}) => await fetch(`${
|
|
2012
|
+
}) => await fetch(`${bn}/graphql`, {
|
|
2012
2013
|
method: "POST",
|
|
2013
2014
|
credentials: "include",
|
|
2014
2015
|
headers: {
|
|
@@ -2020,14 +2021,14 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2020
2021
|
query: e,
|
|
2021
2022
|
variables: t
|
|
2022
2023
|
})
|
|
2023
|
-
}),
|
|
2024
|
+
}), vn = async ({
|
|
2024
2025
|
accessToken: e,
|
|
2025
2026
|
type: t,
|
|
2026
2027
|
params: r = {}
|
|
2027
2028
|
}) => {
|
|
2028
2029
|
const n = t != null && t.data ? t.data(r) : r;
|
|
2029
2030
|
try {
|
|
2030
|
-
const a = `Bearer ${e}`, o = await
|
|
2031
|
+
const a = `Bearer ${e}`, o = await es({
|
|
2031
2032
|
headers: {
|
|
2032
2033
|
authorization: a
|
|
2033
2034
|
},
|
|
@@ -2045,14 +2046,14 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2045
2046
|
} catch (a) {
|
|
2046
2047
|
return console.error(a), { status: 500, data: [] };
|
|
2047
2048
|
}
|
|
2048
|
-
},
|
|
2049
|
+
}, ts = async ({
|
|
2049
2050
|
accessToken: e,
|
|
2050
2051
|
name: t,
|
|
2051
2052
|
data: r,
|
|
2052
2053
|
method: n = "POST"
|
|
2053
2054
|
}) => {
|
|
2054
2055
|
const a = `Bearer ${e}`;
|
|
2055
|
-
return await fetch(`${
|
|
2056
|
+
return await fetch(`${bn}/api/${t}`, {
|
|
2056
2057
|
method: n,
|
|
2057
2058
|
credentials: "include",
|
|
2058
2059
|
headers: {
|
|
@@ -2061,25 +2062,25 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2061
2062
|
},
|
|
2062
2063
|
body: JSON.stringify(r)
|
|
2063
2064
|
});
|
|
2064
|
-
},
|
|
2065
|
+
}, ot = ({
|
|
2065
2066
|
fetcher: e,
|
|
2066
2067
|
scope: t,
|
|
2067
2068
|
keys: r,
|
|
2068
2069
|
swrOptions: n,
|
|
2069
2070
|
getAccessToken: a
|
|
2070
2071
|
}) => {
|
|
2071
|
-
const { data: o, error: s, isLoading: i, mutate: l } =
|
|
2072
|
+
const { data: o, error: s, isLoading: i, mutate: l } = Qo(
|
|
2072
2073
|
[t, ...r],
|
|
2073
2074
|
(c) => e(c, a),
|
|
2074
2075
|
{ ...n }
|
|
2075
2076
|
);
|
|
2076
2077
|
return { data: o, error: s, isLoading: i, mutate: l };
|
|
2077
|
-
},
|
|
2078
|
+
}, st = async ({
|
|
2078
2079
|
getAccessToken: e,
|
|
2079
2080
|
type: t,
|
|
2080
2081
|
params: r
|
|
2081
2082
|
}) => {
|
|
2082
|
-
const n = await e(), a = await
|
|
2083
|
+
const n = await e(), a = await vn({
|
|
2083
2084
|
accessToken: n,
|
|
2084
2085
|
type: t,
|
|
2085
2086
|
params: r
|
|
@@ -2087,44 +2088,36 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2087
2088
|
if (a.status === 200 && a.errors === void 0)
|
|
2088
2089
|
return a.data;
|
|
2089
2090
|
throw new Error("An error occurred while fetching the data.");
|
|
2090
|
-
},
|
|
2091
|
+
}, rs = async ([e, t], r) => st({
|
|
2091
2092
|
getAccessToken: r,
|
|
2092
2093
|
type: Ve.GET_USER_PREFERENCES,
|
|
2093
2094
|
params: {
|
|
2094
2095
|
user: t
|
|
2095
2096
|
}
|
|
2096
|
-
}),
|
|
2097
|
+
}), Qt = ({
|
|
2097
2098
|
keys: e,
|
|
2098
2099
|
getAccessToken: t
|
|
2099
|
-
}) =>
|
|
2100
|
-
fetcher:
|
|
2100
|
+
}) => ot({
|
|
2101
|
+
fetcher: rs,
|
|
2101
2102
|
scope: "/preferences",
|
|
2102
2103
|
keys: e,
|
|
2103
2104
|
swrOptions: { keepPreviousData: !0 },
|
|
2104
2105
|
getAccessToken: t
|
|
2105
|
-
}), ns = ({
|
|
2106
|
-
keys: e,
|
|
2107
|
-
getAccessToken: t
|
|
2108
|
-
}) => {
|
|
2109
|
-
Qt(
|
|
2110
|
-
["/preferences", ...e],
|
|
2111
|
-
(r) => vn(r, t)
|
|
2112
|
-
);
|
|
2113
|
-
}, as = async ([e, t], r) => ot({
|
|
2106
|
+
}), ns = async ([e, t], r) => st({
|
|
2114
2107
|
getAccessToken: r,
|
|
2115
2108
|
type: Ve.GET_CHATS_STATS,
|
|
2116
2109
|
params: {
|
|
2117
2110
|
user: t
|
|
2118
2111
|
}
|
|
2119
|
-
}),
|
|
2112
|
+
}), ll = ({
|
|
2120
2113
|
keys: e,
|
|
2121
2114
|
getAccessToken: t
|
|
2122
|
-
}) =>
|
|
2123
|
-
fetcher:
|
|
2115
|
+
}) => ot({
|
|
2116
|
+
fetcher: ns,
|
|
2124
2117
|
scope: "/stats",
|
|
2125
2118
|
keys: e,
|
|
2126
2119
|
getAccessToken: t
|
|
2127
|
-
}),
|
|
2120
|
+
}), kn = async ([e, t, r, n], a) => st({
|
|
2128
2121
|
getAccessToken: a,
|
|
2129
2122
|
type: Ve.GET_CHATS,
|
|
2130
2123
|
params: {
|
|
@@ -2134,11 +2127,11 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2134
2127
|
limit: 1,
|
|
2135
2128
|
truncateSize: 100
|
|
2136
2129
|
}
|
|
2137
|
-
}),
|
|
2130
|
+
}), cl = ({
|
|
2138
2131
|
keys: e,
|
|
2139
2132
|
getAccessToken: t
|
|
2140
|
-
}) =>
|
|
2141
|
-
fetcher:
|
|
2133
|
+
}) => ot({
|
|
2134
|
+
fetcher: kn,
|
|
2142
2135
|
scope: "/history",
|
|
2143
2136
|
keys: e,
|
|
2144
2137
|
getAccessToken: t,
|
|
@@ -2146,30 +2139,30 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2146
2139
|
keepPreviousData: !0,
|
|
2147
2140
|
dedupingInterval: 1e4
|
|
2148
2141
|
}
|
|
2149
|
-
}),
|
|
2142
|
+
}), as = ({
|
|
2150
2143
|
keys: e,
|
|
2151
2144
|
getAccessToken: t
|
|
2152
2145
|
}) => {
|
|
2153
|
-
|
|
2154
|
-
},
|
|
2146
|
+
yn(["/history", ...e], (r) => kn(r, t));
|
|
2147
|
+
}, xn = async ([e], t) => st({
|
|
2155
2148
|
getAccessToken: t,
|
|
2156
2149
|
type: Ve.GET_SERVER_CAPABILITIES
|
|
2157
|
-
}),
|
|
2150
|
+
}), dl = ({
|
|
2158
2151
|
getAccessToken: e
|
|
2159
|
-
}) =>
|
|
2160
|
-
fetcher:
|
|
2152
|
+
}) => ot({
|
|
2153
|
+
fetcher: xn,
|
|
2161
2154
|
scope: "/capabilities",
|
|
2162
2155
|
keys: [],
|
|
2163
2156
|
getAccessToken: e
|
|
2164
|
-
}),
|
|
2157
|
+
}), os = ({
|
|
2165
2158
|
getAccessToken: e
|
|
2166
2159
|
}) => {
|
|
2167
|
-
|
|
2168
|
-
},
|
|
2160
|
+
yn(["/capabilities"], (t) => xn(t, e));
|
|
2161
|
+
}, ss = "z-20", is = "z-10", pe = V.createContext({
|
|
2169
2162
|
state: {
|
|
2170
2163
|
id: "",
|
|
2171
|
-
model:
|
|
2172
|
-
engine:
|
|
2164
|
+
model: we,
|
|
2165
|
+
engine: we,
|
|
2173
2166
|
usage: 0,
|
|
2174
2167
|
messages: [],
|
|
2175
2168
|
isComponent: !1,
|
|
@@ -2183,11 +2176,11 @@ const Et = V.use || // This extra generic is to avoid TypeScript mixing up the g
|
|
|
2183
2176
|
plugins: [],
|
|
2184
2177
|
engines: []
|
|
2185
2178
|
}
|
|
2186
|
-
}),
|
|
2179
|
+
}), ls = V.createContext({
|
|
2187
2180
|
state: { searchString: "", sortedCell: "", sortDirection: "" },
|
|
2188
2181
|
dispatch: () => {
|
|
2189
2182
|
}
|
|
2190
|
-
}),
|
|
2183
|
+
}), it = V.createContext({
|
|
2191
2184
|
state: { prompt: "", lastTriggeredTimestamp: 0 },
|
|
2192
2185
|
dispatch: () => {
|
|
2193
2186
|
}
|
|
@@ -2205,20 +2198,20 @@ try {
|
|
|
2205
2198
|
});
|
|
2206
2199
|
} catch {
|
|
2207
2200
|
}
|
|
2208
|
-
const
|
|
2201
|
+
const cs = "av-tooltip", ds = "av-tooltip-arrow", $e = Math.min, _e = Math.max, Ye = Math.round, ie = (e) => ({
|
|
2209
2202
|
x: e,
|
|
2210
2203
|
y: e
|
|
2211
|
-
}),
|
|
2204
|
+
}), us = {
|
|
2212
2205
|
left: "right",
|
|
2213
2206
|
right: "left",
|
|
2214
2207
|
bottom: "top",
|
|
2215
2208
|
top: "bottom"
|
|
2216
|
-
},
|
|
2209
|
+
}, ms = {
|
|
2217
2210
|
start: "end",
|
|
2218
2211
|
end: "start"
|
|
2219
2212
|
};
|
|
2220
|
-
function
|
|
2221
|
-
return
|
|
2213
|
+
function zt(e, t, r) {
|
|
2214
|
+
return _e(e, $e(t, r));
|
|
2222
2215
|
}
|
|
2223
2216
|
function ze(e, t) {
|
|
2224
2217
|
return typeof e == "function" ? e(t) : e;
|
|
@@ -2229,32 +2222,32 @@ function ye(e) {
|
|
|
2229
2222
|
function Ue(e) {
|
|
2230
2223
|
return e.split("-")[1];
|
|
2231
2224
|
}
|
|
2232
|
-
function
|
|
2225
|
+
function wn(e) {
|
|
2233
2226
|
return e === "x" ? "y" : "x";
|
|
2234
2227
|
}
|
|
2235
2228
|
function er(e) {
|
|
2236
2229
|
return e === "y" ? "height" : "width";
|
|
2237
2230
|
}
|
|
2238
|
-
function
|
|
2231
|
+
function Te(e) {
|
|
2239
2232
|
return ["top", "bottom"].includes(ye(e)) ? "y" : "x";
|
|
2240
2233
|
}
|
|
2241
2234
|
function tr(e) {
|
|
2242
|
-
return
|
|
2235
|
+
return wn(Te(e));
|
|
2243
2236
|
}
|
|
2244
|
-
function
|
|
2237
|
+
function fs(e, t, r) {
|
|
2245
2238
|
r === void 0 && (r = !1);
|
|
2246
2239
|
const n = Ue(e), a = tr(e), o = er(a);
|
|
2247
2240
|
let s = a === "x" ? n === (r ? "end" : "start") ? "right" : "left" : n === "start" ? "bottom" : "top";
|
|
2248
2241
|
return t.reference[o] > t.floating[o] && (s = Je(s)), [s, Je(s)];
|
|
2249
2242
|
}
|
|
2250
|
-
function
|
|
2243
|
+
function gs(e) {
|
|
2251
2244
|
const t = Je(e);
|
|
2252
|
-
return [
|
|
2245
|
+
return [Ut(e), t, Ut(t)];
|
|
2253
2246
|
}
|
|
2254
|
-
function
|
|
2255
|
-
return e.replace(/start|end/g, (t) =>
|
|
2247
|
+
function Ut(e) {
|
|
2248
|
+
return e.replace(/start|end/g, (t) => ms[t]);
|
|
2256
2249
|
}
|
|
2257
|
-
function
|
|
2250
|
+
function hs(e, t, r) {
|
|
2258
2251
|
const n = ["left", "right"], a = ["right", "left"], o = ["top", "bottom"], s = ["bottom", "top"];
|
|
2259
2252
|
switch (e) {
|
|
2260
2253
|
case "top":
|
|
@@ -2267,15 +2260,15 @@ function ps(e, t, r) {
|
|
|
2267
2260
|
return [];
|
|
2268
2261
|
}
|
|
2269
2262
|
}
|
|
2270
|
-
function
|
|
2263
|
+
function ps(e, t, r, n) {
|
|
2271
2264
|
const a = Ue(e);
|
|
2272
|
-
let o =
|
|
2273
|
-
return a && (o = o.map((s) => s + "-" + a), t && (o = o.concat(o.map(
|
|
2265
|
+
let o = hs(ye(e), r === "start", n);
|
|
2266
|
+
return a && (o = o.map((s) => s + "-" + a), t && (o = o.concat(o.map(Ut)))), o;
|
|
2274
2267
|
}
|
|
2275
2268
|
function Je(e) {
|
|
2276
|
-
return e.replace(/left|right|bottom|top/g, (t) =>
|
|
2269
|
+
return e.replace(/left|right|bottom|top/g, (t) => us[t]);
|
|
2277
2270
|
}
|
|
2278
|
-
function
|
|
2271
|
+
function ys(e) {
|
|
2279
2272
|
return {
|
|
2280
2273
|
top: 0,
|
|
2281
2274
|
right: 0,
|
|
@@ -2284,8 +2277,8 @@ function bs(e) {
|
|
|
2284
2277
|
...e
|
|
2285
2278
|
};
|
|
2286
2279
|
}
|
|
2287
|
-
function
|
|
2288
|
-
return typeof e != "number" ?
|
|
2280
|
+
function _n(e) {
|
|
2281
|
+
return typeof e != "number" ? ys(e) : {
|
|
2289
2282
|
top: e,
|
|
2290
2283
|
right: e,
|
|
2291
2284
|
bottom: e,
|
|
@@ -2315,7 +2308,7 @@ function $r(e, t, r) {
|
|
|
2315
2308
|
reference: n,
|
|
2316
2309
|
floating: a
|
|
2317
2310
|
} = e;
|
|
2318
|
-
const o =
|
|
2311
|
+
const o = Te(t), s = tr(t), i = er(s), l = ye(t), c = o === "y", g = n.x + n.width / 2 - a.width / 2, d = n.y + n.height / 2 - a.height / 2, f = n[i] / 2 - a[i] / 2;
|
|
2319
2312
|
let m;
|
|
2320
2313
|
switch (l) {
|
|
2321
2314
|
case "top":
|
|
@@ -2333,13 +2326,13 @@ function $r(e, t, r) {
|
|
|
2333
2326
|
case "right":
|
|
2334
2327
|
m = {
|
|
2335
2328
|
x: n.x + n.width,
|
|
2336
|
-
y:
|
|
2329
|
+
y: d
|
|
2337
2330
|
};
|
|
2338
2331
|
break;
|
|
2339
2332
|
case "left":
|
|
2340
2333
|
m = {
|
|
2341
2334
|
x: n.x - a.width,
|
|
2342
|
-
y:
|
|
2335
|
+
y: d
|
|
2343
2336
|
};
|
|
2344
2337
|
break;
|
|
2345
2338
|
default:
|
|
@@ -2358,7 +2351,7 @@ function $r(e, t, r) {
|
|
|
2358
2351
|
}
|
|
2359
2352
|
return m;
|
|
2360
2353
|
}
|
|
2361
|
-
const
|
|
2354
|
+
const bs = async (e, t, r) => {
|
|
2362
2355
|
const {
|
|
2363
2356
|
placement: n = "bottom",
|
|
2364
2357
|
strategy: a = "absolute",
|
|
@@ -2371,7 +2364,7 @@ const vs = async (e, t, r) => {
|
|
|
2371
2364
|
strategy: a
|
|
2372
2365
|
}), {
|
|
2373
2366
|
x: g,
|
|
2374
|
-
y:
|
|
2367
|
+
y: d
|
|
2375
2368
|
} = $r(c, n, l), f = n, m = {}, p = 0;
|
|
2376
2369
|
for (let y = 0; y < i.length; y++) {
|
|
2377
2370
|
const {
|
|
@@ -2384,7 +2377,7 @@ const vs = async (e, t, r) => {
|
|
|
2384
2377
|
reset: x
|
|
2385
2378
|
} = await b({
|
|
2386
2379
|
x: g,
|
|
2387
|
-
y:
|
|
2380
|
+
y: d,
|
|
2388
2381
|
initialPlacement: n,
|
|
2389
2382
|
placement: f,
|
|
2390
2383
|
strategy: a,
|
|
@@ -2396,7 +2389,7 @@ const vs = async (e, t, r) => {
|
|
|
2396
2389
|
floating: t
|
|
2397
2390
|
}
|
|
2398
2391
|
});
|
|
2399
|
-
g = k ?? g,
|
|
2392
|
+
g = k ?? g, d = w ?? d, m = {
|
|
2400
2393
|
...m,
|
|
2401
2394
|
[v]: {
|
|
2402
2395
|
...m[v],
|
|
@@ -2408,18 +2401,18 @@ const vs = async (e, t, r) => {
|
|
|
2408
2401
|
strategy: a
|
|
2409
2402
|
}) : x.rects), {
|
|
2410
2403
|
x: g,
|
|
2411
|
-
y:
|
|
2404
|
+
y: d
|
|
2412
2405
|
} = $r(c, f, l)), y = -1);
|
|
2413
2406
|
}
|
|
2414
2407
|
return {
|
|
2415
2408
|
x: g,
|
|
2416
|
-
y:
|
|
2409
|
+
y: d,
|
|
2417
2410
|
placement: f,
|
|
2418
2411
|
strategy: a,
|
|
2419
2412
|
middlewareData: m
|
|
2420
2413
|
};
|
|
2421
2414
|
};
|
|
2422
|
-
async function
|
|
2415
|
+
async function En(e, t) {
|
|
2423
2416
|
var r;
|
|
2424
2417
|
t === void 0 && (t = {});
|
|
2425
2418
|
const {
|
|
@@ -2432,15 +2425,15 @@ async function Tn(e, t) {
|
|
|
2432
2425
|
} = e, {
|
|
2433
2426
|
boundary: c = "clippingAncestors",
|
|
2434
2427
|
rootBoundary: g = "viewport",
|
|
2435
|
-
elementContext:
|
|
2428
|
+
elementContext: d = "floating",
|
|
2436
2429
|
altBoundary: f = !1,
|
|
2437
2430
|
padding: m = 0
|
|
2438
|
-
} = ze(t, e), p =
|
|
2431
|
+
} = ze(t, e), p = _n(m), y = i[f ? d === "floating" ? "reference" : "floating" : d], v = Xe(await o.getClippingRect({
|
|
2439
2432
|
element: (r = await (o.isElement == null ? void 0 : o.isElement(y))) == null || r ? y : y.contextElement || await (o.getDocumentElement == null ? void 0 : o.getDocumentElement(i.floating)),
|
|
2440
2433
|
boundary: c,
|
|
2441
2434
|
rootBoundary: g,
|
|
2442
2435
|
strategy: l
|
|
2443
|
-
})), b =
|
|
2436
|
+
})), b = d === "floating" ? {
|
|
2444
2437
|
x: n,
|
|
2445
2438
|
y: a,
|
|
2446
2439
|
width: s.floating.width,
|
|
@@ -2464,7 +2457,7 @@ async function Tn(e, t) {
|
|
|
2464
2457
|
right: (_.right - v.right + p.right) / w.x
|
|
2465
2458
|
};
|
|
2466
2459
|
}
|
|
2467
|
-
const
|
|
2460
|
+
const vs = (e) => ({
|
|
2468
2461
|
name: "arrow",
|
|
2469
2462
|
options: e,
|
|
2470
2463
|
async fn(t) {
|
|
@@ -2482,13 +2475,13 @@ const ks = (e) => ({
|
|
|
2482
2475
|
} = ze(e, t) || {};
|
|
2483
2476
|
if (c == null)
|
|
2484
2477
|
return {};
|
|
2485
|
-
const
|
|
2478
|
+
const d = _n(g), f = {
|
|
2486
2479
|
x: r,
|
|
2487
2480
|
y: n
|
|
2488
2481
|
}, m = tr(a), p = er(m), y = await s.getDimensions(c), v = m === "y", b = v ? "top" : "left", k = v ? "bottom" : "right", w = v ? "clientHeight" : "clientWidth", _ = o.reference[p] + o.reference[m] - f[m] - o.floating[p], x = f[m] - o.reference[m], E = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(c));
|
|
2489
2482
|
let T = E ? E[w] : 0;
|
|
2490
2483
|
(!T || !await (s.isElement == null ? void 0 : s.isElement(E))) && (T = i.floating[w] || o.floating[p]);
|
|
2491
|
-
const S = _ / 2 - x / 2,
|
|
2484
|
+
const S = _ / 2 - x / 2, P = T / 2 - y[p] / 2 - 1, O = $e(d[b], P), G = $e(d[k], P), $ = O, B = T - y[p] - G, R = T / 2 - y[p] / 2 + S, X = zt($, R, B), q = !l.arrow && Ue(a) != null && R !== X && o.reference[p] / 2 - (R < $ ? O : G) - y[p] / 2 < 0, K = q ? R < $ ? R - $ : R - B : 0;
|
|
2492
2485
|
return {
|
|
2493
2486
|
[m]: f[m] + K,
|
|
2494
2487
|
data: {
|
|
@@ -2501,7 +2494,7 @@ const ks = (e) => ({
|
|
|
2501
2494
|
reset: q
|
|
2502
2495
|
};
|
|
2503
2496
|
}
|
|
2504
|
-
}),
|
|
2497
|
+
}), ks = function(e) {
|
|
2505
2498
|
return e === void 0 && (e = {}), {
|
|
2506
2499
|
name: "flip",
|
|
2507
2500
|
options: e,
|
|
@@ -2516,7 +2509,7 @@ const ks = (e) => ({
|
|
|
2516
2509
|
elements: c
|
|
2517
2510
|
} = t, {
|
|
2518
2511
|
mainAxis: g = !0,
|
|
2519
|
-
crossAxis:
|
|
2512
|
+
crossAxis: d = !0,
|
|
2520
2513
|
fallbackPlacements: f,
|
|
2521
2514
|
fallbackStrategy: m = "bestFit",
|
|
2522
2515
|
fallbackAxisSideDirection: p = "none",
|
|
@@ -2525,18 +2518,18 @@ const ks = (e) => ({
|
|
|
2525
2518
|
} = ze(e, t);
|
|
2526
2519
|
if ((r = o.arrow) != null && r.alignmentOffset)
|
|
2527
2520
|
return {};
|
|
2528
|
-
const b = ye(a), k =
|
|
2529
|
-
!f && E && x.push(...
|
|
2530
|
-
const T = [i, ...x], S = await
|
|
2521
|
+
const b = ye(a), k = Te(i), w = ye(i) === i, _ = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), x = f || (w || !y ? [Je(i)] : gs(i)), E = p !== "none";
|
|
2522
|
+
!f && E && x.push(...ps(i, y, p, _));
|
|
2523
|
+
const T = [i, ...x], S = await En(t, v), P = [];
|
|
2531
2524
|
let O = ((n = o.flip) == null ? void 0 : n.overflows) || [];
|
|
2532
|
-
if (g &&
|
|
2533
|
-
const R =
|
|
2534
|
-
|
|
2525
|
+
if (g && P.push(S[b]), d) {
|
|
2526
|
+
const R = fs(a, s, _);
|
|
2527
|
+
P.push(S[R[0]], S[R[1]]);
|
|
2535
2528
|
}
|
|
2536
2529
|
if (O = [...O, {
|
|
2537
2530
|
placement: a,
|
|
2538
|
-
overflows:
|
|
2539
|
-
}], !
|
|
2531
|
+
overflows: P
|
|
2532
|
+
}], !P.every((R) => R <= 0)) {
|
|
2540
2533
|
var G, $;
|
|
2541
2534
|
const R = (((G = o.flip) == null ? void 0 : G.index) || 0) + 1, X = T[R];
|
|
2542
2535
|
if (X)
|
|
@@ -2556,13 +2549,13 @@ const ks = (e) => ({
|
|
|
2556
2549
|
var B;
|
|
2557
2550
|
const K = (B = O.filter((z) => {
|
|
2558
2551
|
if (E) {
|
|
2559
|
-
const U =
|
|
2552
|
+
const U = Te(z.placement);
|
|
2560
2553
|
return U === k || // Create a bias to the `y` side axis due to horizontal
|
|
2561
2554
|
// reading directions favoring greater width.
|
|
2562
2555
|
U === "y";
|
|
2563
2556
|
}
|
|
2564
2557
|
return !0;
|
|
2565
|
-
}).map((z) => [z.placement, z.overflows.filter((U) => U > 0).reduce((U,
|
|
2558
|
+
}).map((z) => [z.placement, z.overflows.filter((U) => U > 0).reduce((U, ft) => U + ft, 0)]).sort((z, U) => z[1] - U[1])[0]) == null ? void 0 : B[0];
|
|
2566
2559
|
K && (q = K);
|
|
2567
2560
|
break;
|
|
2568
2561
|
}
|
|
@@ -2581,24 +2574,24 @@ const ks = (e) => ({
|
|
|
2581
2574
|
}
|
|
2582
2575
|
};
|
|
2583
2576
|
};
|
|
2584
|
-
async function
|
|
2577
|
+
async function xs(e, t) {
|
|
2585
2578
|
const {
|
|
2586
2579
|
placement: r,
|
|
2587
2580
|
platform: n,
|
|
2588
2581
|
elements: a
|
|
2589
|
-
} = e, o = await (n.isRTL == null ? void 0 : n.isRTL(a.floating)), s = ye(r), i = Ue(r), l =
|
|
2582
|
+
} = e, o = await (n.isRTL == null ? void 0 : n.isRTL(a.floating)), s = ye(r), i = Ue(r), l = Te(r) === "y", c = ["left", "top"].includes(s) ? -1 : 1, g = o && l ? -1 : 1, d = ze(t, e);
|
|
2590
2583
|
let {
|
|
2591
2584
|
mainAxis: f,
|
|
2592
2585
|
crossAxis: m,
|
|
2593
2586
|
alignmentAxis: p
|
|
2594
|
-
} = typeof
|
|
2595
|
-
mainAxis:
|
|
2587
|
+
} = typeof d == "number" ? {
|
|
2588
|
+
mainAxis: d,
|
|
2596
2589
|
crossAxis: 0,
|
|
2597
2590
|
alignmentAxis: null
|
|
2598
2591
|
} : {
|
|
2599
|
-
mainAxis:
|
|
2600
|
-
crossAxis:
|
|
2601
|
-
alignmentAxis:
|
|
2592
|
+
mainAxis: d.mainAxis || 0,
|
|
2593
|
+
crossAxis: d.crossAxis || 0,
|
|
2594
|
+
alignmentAxis: d.alignmentAxis
|
|
2602
2595
|
};
|
|
2603
2596
|
return i && typeof p == "number" && (m = i === "end" ? p * -1 : p), l ? {
|
|
2604
2597
|
x: m * g,
|
|
@@ -2608,7 +2601,7 @@ async function ws(e, t) {
|
|
|
2608
2601
|
y: m * g
|
|
2609
2602
|
};
|
|
2610
2603
|
}
|
|
2611
|
-
const
|
|
2604
|
+
const ws = function(e) {
|
|
2612
2605
|
return e === void 0 && (e = 0), {
|
|
2613
2606
|
name: "offset",
|
|
2614
2607
|
options: e,
|
|
@@ -2619,7 +2612,7 @@ const _s = function(e) {
|
|
|
2619
2612
|
y: o,
|
|
2620
2613
|
placement: s,
|
|
2621
2614
|
middlewareData: i
|
|
2622
|
-
} = t, l = await
|
|
2615
|
+
} = t, l = await xs(t, e);
|
|
2623
2616
|
return s === ((r = i.offset) == null ? void 0 : r.placement) && (n = i.arrow) != null && n.alignmentOffset ? {} : {
|
|
2624
2617
|
x: a + l.x,
|
|
2625
2618
|
y: o + l.y,
|
|
@@ -2630,7 +2623,7 @@ const _s = function(e) {
|
|
|
2630
2623
|
};
|
|
2631
2624
|
}
|
|
2632
2625
|
};
|
|
2633
|
-
},
|
|
2626
|
+
}, _s = function(e) {
|
|
2634
2627
|
return e === void 0 && (e = {}), {
|
|
2635
2628
|
name: "shift",
|
|
2636
2629
|
options: e,
|
|
@@ -2658,20 +2651,20 @@ const _s = function(e) {
|
|
|
2658
2651
|
} = ze(e, t), c = {
|
|
2659
2652
|
x: r,
|
|
2660
2653
|
y: n
|
|
2661
|
-
}, g = await
|
|
2662
|
-
let m = c[f], p = c[
|
|
2654
|
+
}, g = await En(t, l), d = Te(ye(a)), f = wn(d);
|
|
2655
|
+
let m = c[f], p = c[d];
|
|
2663
2656
|
if (o) {
|
|
2664
2657
|
const v = f === "y" ? "top" : "left", b = f === "y" ? "bottom" : "right", k = m + g[v], w = m - g[b];
|
|
2665
|
-
m =
|
|
2658
|
+
m = zt(k, m, w);
|
|
2666
2659
|
}
|
|
2667
2660
|
if (s) {
|
|
2668
|
-
const v =
|
|
2669
|
-
p =
|
|
2661
|
+
const v = d === "y" ? "top" : "left", b = d === "y" ? "bottom" : "right", k = p + g[v], w = p - g[b];
|
|
2662
|
+
p = zt(k, p, w);
|
|
2670
2663
|
}
|
|
2671
2664
|
const y = i.fn({
|
|
2672
2665
|
...t,
|
|
2673
2666
|
[f]: m,
|
|
2674
|
-
[
|
|
2667
|
+
[d]: p
|
|
2675
2668
|
});
|
|
2676
2669
|
return {
|
|
2677
2670
|
...y,
|
|
@@ -2680,18 +2673,18 @@ const _s = function(e) {
|
|
|
2680
2673
|
y: y.y - n,
|
|
2681
2674
|
enabled: {
|
|
2682
2675
|
[f]: o,
|
|
2683
|
-
[
|
|
2676
|
+
[d]: s
|
|
2684
2677
|
}
|
|
2685
2678
|
}
|
|
2686
2679
|
};
|
|
2687
2680
|
}
|
|
2688
2681
|
};
|
|
2689
2682
|
};
|
|
2690
|
-
function
|
|
2683
|
+
function lt() {
|
|
2691
2684
|
return typeof window < "u";
|
|
2692
2685
|
}
|
|
2693
|
-
function
|
|
2694
|
-
return
|
|
2686
|
+
function Re(e) {
|
|
2687
|
+
return Tn(e) ? (e.nodeName || "").toLowerCase() : "#document";
|
|
2695
2688
|
}
|
|
2696
2689
|
function Q(e) {
|
|
2697
2690
|
var t;
|
|
@@ -2699,19 +2692,19 @@ function Q(e) {
|
|
|
2699
2692
|
}
|
|
2700
2693
|
function ue(e) {
|
|
2701
2694
|
var t;
|
|
2702
|
-
return (t = (
|
|
2695
|
+
return (t = (Tn(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
|
|
2703
2696
|
}
|
|
2704
|
-
function
|
|
2705
|
-
return
|
|
2697
|
+
function Tn(e) {
|
|
2698
|
+
return lt() ? e instanceof Node || e instanceof Q(e).Node : !1;
|
|
2706
2699
|
}
|
|
2707
2700
|
function re(e) {
|
|
2708
|
-
return
|
|
2701
|
+
return lt() ? e instanceof Element || e instanceof Q(e).Element : !1;
|
|
2709
2702
|
}
|
|
2710
2703
|
function le(e) {
|
|
2711
|
-
return
|
|
2704
|
+
return lt() ? e instanceof HTMLElement || e instanceof Q(e).HTMLElement : !1;
|
|
2712
2705
|
}
|
|
2713
2706
|
function Dr(e) {
|
|
2714
|
-
return !
|
|
2707
|
+
return !lt() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof Q(e).ShadowRoot;
|
|
2715
2708
|
}
|
|
2716
2709
|
function He(e) {
|
|
2717
2710
|
const {
|
|
@@ -2722,10 +2715,10 @@ function He(e) {
|
|
|
2722
2715
|
} = ne(e);
|
|
2723
2716
|
return /auto|scroll|overlay|hidden|clip/.test(t + n + r) && !["inline", "contents"].includes(a);
|
|
2724
2717
|
}
|
|
2725
|
-
function
|
|
2726
|
-
return ["table", "td", "th"].includes(
|
|
2718
|
+
function Es(e) {
|
|
2719
|
+
return ["table", "td", "th"].includes(Re(e));
|
|
2727
2720
|
}
|
|
2728
|
-
function
|
|
2721
|
+
function ct(e) {
|
|
2729
2722
|
return [":popover-open", ":modal"].some((t) => {
|
|
2730
2723
|
try {
|
|
2731
2724
|
return e.matches(t);
|
|
@@ -2738,12 +2731,12 @@ function rr(e) {
|
|
|
2738
2731
|
const t = nr(), r = re(e) ? ne(e) : e;
|
|
2739
2732
|
return ["transform", "translate", "scale", "rotate", "perspective"].some((n) => r[n] ? r[n] !== "none" : !1) || (r.containerType ? r.containerType !== "normal" : !1) || !t && (r.backdropFilter ? r.backdropFilter !== "none" : !1) || !t && (r.filter ? r.filter !== "none" : !1) || ["transform", "translate", "scale", "rotate", "perspective", "filter"].some((n) => (r.willChange || "").includes(n)) || ["paint", "layout", "strict", "content"].some((n) => (r.contain || "").includes(n));
|
|
2740
2733
|
}
|
|
2741
|
-
function
|
|
2734
|
+
function Ts(e) {
|
|
2742
2735
|
let t = he(e);
|
|
2743
|
-
for (; le(t) && !
|
|
2736
|
+
for (; le(t) && !Se(t); ) {
|
|
2744
2737
|
if (rr(t))
|
|
2745
2738
|
return t;
|
|
2746
|
-
if (
|
|
2739
|
+
if (ct(t))
|
|
2747
2740
|
return null;
|
|
2748
2741
|
t = he(t);
|
|
2749
2742
|
}
|
|
@@ -2752,13 +2745,13 @@ function Ss(e) {
|
|
|
2752
2745
|
function nr() {
|
|
2753
2746
|
return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
|
|
2754
2747
|
}
|
|
2755
|
-
function
|
|
2756
|
-
return ["html", "body", "#document"].includes(
|
|
2748
|
+
function Se(e) {
|
|
2749
|
+
return ["html", "body", "#document"].includes(Re(e));
|
|
2757
2750
|
}
|
|
2758
2751
|
function ne(e) {
|
|
2759
2752
|
return Q(e).getComputedStyle(e);
|
|
2760
2753
|
}
|
|
2761
|
-
function
|
|
2754
|
+
function dt(e) {
|
|
2762
2755
|
return re(e) ? {
|
|
2763
2756
|
scrollLeft: e.scrollLeft,
|
|
2764
2757
|
scrollTop: e.scrollTop
|
|
@@ -2768,7 +2761,7 @@ function ct(e) {
|
|
|
2768
2761
|
};
|
|
2769
2762
|
}
|
|
2770
2763
|
function he(e) {
|
|
2771
|
-
if (
|
|
2764
|
+
if (Re(e) === "html")
|
|
2772
2765
|
return e;
|
|
2773
2766
|
const t = (
|
|
2774
2767
|
// Step into the shadow DOM of the parent of a slotted node.
|
|
@@ -2779,20 +2772,20 @@ function he(e) {
|
|
|
2779
2772
|
);
|
|
2780
2773
|
return Dr(t) ? t.host : t;
|
|
2781
2774
|
}
|
|
2782
|
-
function
|
|
2775
|
+
function Sn(e) {
|
|
2783
2776
|
const t = he(e);
|
|
2784
|
-
return
|
|
2777
|
+
return Se(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : le(t) && He(t) ? t : Sn(t);
|
|
2785
2778
|
}
|
|
2786
|
-
function
|
|
2779
|
+
function Nn(e, t, r) {
|
|
2787
2780
|
var n;
|
|
2788
2781
|
t === void 0 && (t = []);
|
|
2789
|
-
const a =
|
|
2790
|
-
return o ? t.concat(s, s.visualViewport || [], He(a) ? a : [], []) : t.concat(a,
|
|
2782
|
+
const a = Sn(e), o = a === ((n = e.ownerDocument) == null ? void 0 : n.body), s = Q(a);
|
|
2783
|
+
return o ? t.concat(s, s.visualViewport || [], He(a) ? a : [], []) : t.concat(a, Nn(a, []));
|
|
2791
2784
|
}
|
|
2792
2785
|
function Pr(e) {
|
|
2793
2786
|
return e.parent && Object.getPrototypeOf(e.parent) ? e.frameElement : null;
|
|
2794
2787
|
}
|
|
2795
|
-
function
|
|
2788
|
+
function Cn(e) {
|
|
2796
2789
|
const t = ne(e);
|
|
2797
2790
|
let r = parseFloat(t.width) || 0, n = parseFloat(t.height) || 0;
|
|
2798
2791
|
const a = le(e), o = a ? e.offsetWidth : r, s = a ? e.offsetHeight : n, i = Ye(r) !== o || Ye(n) !== s;
|
|
@@ -2802,62 +2795,62 @@ function Rn(e) {
|
|
|
2802
2795
|
$: i
|
|
2803
2796
|
};
|
|
2804
2797
|
}
|
|
2805
|
-
function
|
|
2798
|
+
function Rn(e) {
|
|
2806
2799
|
return re(e) ? e : e.contextElement;
|
|
2807
2800
|
}
|
|
2808
|
-
function
|
|
2809
|
-
const t =
|
|
2801
|
+
function Ee(e) {
|
|
2802
|
+
const t = Rn(e);
|
|
2810
2803
|
if (!le(t))
|
|
2811
2804
|
return ie(1);
|
|
2812
2805
|
const r = t.getBoundingClientRect(), {
|
|
2813
2806
|
width: n,
|
|
2814
2807
|
height: a,
|
|
2815
2808
|
$: o
|
|
2816
|
-
} =
|
|
2809
|
+
} = Cn(t);
|
|
2817
2810
|
let s = (o ? Ye(r.width) : r.width) / n, i = (o ? Ye(r.height) : r.height) / a;
|
|
2818
2811
|
return (!s || !Number.isFinite(s)) && (s = 1), (!i || !Number.isFinite(i)) && (i = 1), {
|
|
2819
2812
|
x: s,
|
|
2820
2813
|
y: i
|
|
2821
2814
|
};
|
|
2822
2815
|
}
|
|
2823
|
-
const
|
|
2824
|
-
function
|
|
2816
|
+
const Ss = /* @__PURE__ */ ie(0);
|
|
2817
|
+
function In(e) {
|
|
2825
2818
|
const t = Q(e);
|
|
2826
|
-
return !nr() || !t.visualViewport ?
|
|
2819
|
+
return !nr() || !t.visualViewport ? Ss : {
|
|
2827
2820
|
x: t.visualViewport.offsetLeft,
|
|
2828
2821
|
y: t.visualViewport.offsetTop
|
|
2829
2822
|
};
|
|
2830
2823
|
}
|
|
2831
|
-
function
|
|
2824
|
+
function Ns(e, t, r) {
|
|
2832
2825
|
return t === void 0 && (t = !1), !r || t && r !== Q(e) ? !1 : t;
|
|
2833
2826
|
}
|
|
2834
2827
|
function De(e, t, r, n) {
|
|
2835
2828
|
t === void 0 && (t = !1), r === void 0 && (r = !1);
|
|
2836
|
-
const a = e.getBoundingClientRect(), o =
|
|
2829
|
+
const a = e.getBoundingClientRect(), o = Rn(e);
|
|
2837
2830
|
let s = ie(1);
|
|
2838
|
-
t && (n ? re(n) && (s =
|
|
2839
|
-
const i =
|
|
2840
|
-
let l = (a.left + i.x) / s.x, c = (a.top + i.y) / s.y, g = a.width / s.x,
|
|
2831
|
+
t && (n ? re(n) && (s = Ee(n)) : s = Ee(e));
|
|
2832
|
+
const i = Ns(o, r, n) ? In(o) : ie(0);
|
|
2833
|
+
let l = (a.left + i.x) / s.x, c = (a.top + i.y) / s.y, g = a.width / s.x, d = a.height / s.y;
|
|
2841
2834
|
if (o) {
|
|
2842
2835
|
const f = Q(o), m = n && re(n) ? Q(n) : n;
|
|
2843
2836
|
let p = f, y = Pr(p);
|
|
2844
2837
|
for (; y && n && m !== p; ) {
|
|
2845
|
-
const v =
|
|
2846
|
-
l *= v.x, c *= v.y, g *= v.x,
|
|
2838
|
+
const v = Ee(y), b = y.getBoundingClientRect(), k = ne(y), w = b.left + (y.clientLeft + parseFloat(k.paddingLeft)) * v.x, _ = b.top + (y.clientTop + parseFloat(k.paddingTop)) * v.y;
|
|
2839
|
+
l *= v.x, c *= v.y, g *= v.x, d *= v.y, l += w, c += _, p = Q(y), y = Pr(p);
|
|
2847
2840
|
}
|
|
2848
2841
|
}
|
|
2849
2842
|
return Xe({
|
|
2850
2843
|
width: g,
|
|
2851
|
-
height:
|
|
2844
|
+
height: d,
|
|
2852
2845
|
x: l,
|
|
2853
2846
|
y: c
|
|
2854
2847
|
});
|
|
2855
2848
|
}
|
|
2856
2849
|
function ar(e, t) {
|
|
2857
|
-
const r =
|
|
2850
|
+
const r = dt(e).scrollLeft;
|
|
2858
2851
|
return t ? t.left + r : De(ue(e)).left + r;
|
|
2859
2852
|
}
|
|
2860
|
-
function
|
|
2853
|
+
function Ln(e, t, r) {
|
|
2861
2854
|
r === void 0 && (r = !1);
|
|
2862
2855
|
const n = e.getBoundingClientRect(), a = n.left + t.scrollLeft - (r ? 0 : (
|
|
2863
2856
|
// RTL <body> scrollbar.
|
|
@@ -2868,26 +2861,26 @@ function On(e, t, r) {
|
|
|
2868
2861
|
y: o
|
|
2869
2862
|
};
|
|
2870
2863
|
}
|
|
2871
|
-
function
|
|
2864
|
+
function Cs(e) {
|
|
2872
2865
|
let {
|
|
2873
2866
|
elements: t,
|
|
2874
2867
|
rect: r,
|
|
2875
2868
|
offsetParent: n,
|
|
2876
2869
|
strategy: a
|
|
2877
2870
|
} = e;
|
|
2878
|
-
const o = a === "fixed", s = ue(n), i = t ?
|
|
2871
|
+
const o = a === "fixed", s = ue(n), i = t ? ct(t.floating) : !1;
|
|
2879
2872
|
if (n === s || i && o)
|
|
2880
2873
|
return r;
|
|
2881
2874
|
let l = {
|
|
2882
2875
|
scrollLeft: 0,
|
|
2883
2876
|
scrollTop: 0
|
|
2884
2877
|
}, c = ie(1);
|
|
2885
|
-
const g = ie(0),
|
|
2886
|
-
if ((
|
|
2878
|
+
const g = ie(0), d = le(n);
|
|
2879
|
+
if ((d || !d && !o) && ((Re(n) !== "body" || He(s)) && (l = dt(n)), le(n))) {
|
|
2887
2880
|
const m = De(n);
|
|
2888
|
-
c =
|
|
2881
|
+
c = Ee(n), g.x = m.x + n.clientLeft, g.y = m.y + n.clientTop;
|
|
2889
2882
|
}
|
|
2890
|
-
const f = s && !
|
|
2883
|
+
const f = s && !d && !o ? Ln(s, l, !0) : ie(0);
|
|
2891
2884
|
return {
|
|
2892
2885
|
width: r.width * c.x,
|
|
2893
2886
|
height: r.height * c.y,
|
|
@@ -2895,21 +2888,21 @@ function Rs(e) {
|
|
|
2895
2888
|
y: r.y * c.y - l.scrollTop * c.y + g.y + f.y
|
|
2896
2889
|
};
|
|
2897
2890
|
}
|
|
2898
|
-
function
|
|
2891
|
+
function Rs(e) {
|
|
2899
2892
|
return Array.from(e.getClientRects());
|
|
2900
2893
|
}
|
|
2901
|
-
function
|
|
2902
|
-
const t = ue(e), r =
|
|
2894
|
+
function Is(e) {
|
|
2895
|
+
const t = ue(e), r = dt(e), n = e.ownerDocument.body, a = _e(t.scrollWidth, t.clientWidth, n.scrollWidth, n.clientWidth), o = _e(t.scrollHeight, t.clientHeight, n.scrollHeight, n.clientHeight);
|
|
2903
2896
|
let s = -r.scrollLeft + ar(e);
|
|
2904
2897
|
const i = -r.scrollTop;
|
|
2905
|
-
return ne(n).direction === "rtl" && (s +=
|
|
2898
|
+
return ne(n).direction === "rtl" && (s += _e(t.clientWidth, n.clientWidth) - a), {
|
|
2906
2899
|
width: a,
|
|
2907
2900
|
height: o,
|
|
2908
2901
|
x: s,
|
|
2909
2902
|
y: i
|
|
2910
2903
|
};
|
|
2911
2904
|
}
|
|
2912
|
-
function
|
|
2905
|
+
function Ls(e, t) {
|
|
2913
2906
|
const r = Q(e), n = ue(e), a = r.visualViewport;
|
|
2914
2907
|
let o = n.clientWidth, s = n.clientHeight, i = 0, l = 0;
|
|
2915
2908
|
if (a) {
|
|
@@ -2924,8 +2917,8 @@ function Os(e, t) {
|
|
|
2924
2917
|
y: l
|
|
2925
2918
|
};
|
|
2926
2919
|
}
|
|
2927
|
-
function
|
|
2928
|
-
const r = De(e, !0, t === "fixed"), n = r.top + e.clientTop, a = r.left + e.clientLeft, o = le(e) ?
|
|
2920
|
+
function Os(e, t) {
|
|
2921
|
+
const r = De(e, !0, t === "fixed"), n = r.top + e.clientTop, a = r.left + e.clientLeft, o = le(e) ? Ee(e) : ie(1), s = e.clientWidth * o.x, i = e.clientHeight * o.y, l = a * o.x, c = n * o.y;
|
|
2929
2922
|
return {
|
|
2930
2923
|
width: s,
|
|
2931
2924
|
height: i,
|
|
@@ -2936,13 +2929,13 @@ function As(e, t) {
|
|
|
2936
2929
|
function Vr(e, t, r) {
|
|
2937
2930
|
let n;
|
|
2938
2931
|
if (t === "viewport")
|
|
2939
|
-
n =
|
|
2932
|
+
n = Ls(e, r);
|
|
2940
2933
|
else if (t === "document")
|
|
2941
|
-
n =
|
|
2934
|
+
n = Is(ue(e));
|
|
2942
2935
|
else if (re(t))
|
|
2943
|
-
n =
|
|
2936
|
+
n = Os(t, r);
|
|
2944
2937
|
else {
|
|
2945
|
-
const a =
|
|
2938
|
+
const a = In(e);
|
|
2946
2939
|
n = {
|
|
2947
2940
|
x: t.x - a.x,
|
|
2948
2941
|
y: t.y - a.y,
|
|
@@ -2952,33 +2945,33 @@ function Vr(e, t, r) {
|
|
|
2952
2945
|
}
|
|
2953
2946
|
return Xe(n);
|
|
2954
2947
|
}
|
|
2955
|
-
function
|
|
2948
|
+
function On(e, t) {
|
|
2956
2949
|
const r = he(e);
|
|
2957
|
-
return r === t || !re(r) ||
|
|
2950
|
+
return r === t || !re(r) || Se(r) ? !1 : ne(r).position === "fixed" || On(r, t);
|
|
2958
2951
|
}
|
|
2959
|
-
function
|
|
2952
|
+
function As(e, t) {
|
|
2960
2953
|
const r = t.get(e);
|
|
2961
2954
|
if (r)
|
|
2962
2955
|
return r;
|
|
2963
|
-
let n =
|
|
2956
|
+
let n = Nn(e, []).filter((i) => re(i) && Re(i) !== "body"), a = null;
|
|
2964
2957
|
const o = ne(e).position === "fixed";
|
|
2965
2958
|
let s = o ? he(e) : e;
|
|
2966
|
-
for (; re(s) && !
|
|
2959
|
+
for (; re(s) && !Se(s); ) {
|
|
2967
2960
|
const i = ne(s), l = rr(s);
|
|
2968
|
-
!l && i.position === "fixed" && (a = null), (o ? !l && !a : !l && i.position === "static" && a && ["absolute", "fixed"].includes(a.position) || He(s) && !l &&
|
|
2961
|
+
!l && i.position === "fixed" && (a = null), (o ? !l && !a : !l && i.position === "static" && a && ["absolute", "fixed"].includes(a.position) || He(s) && !l && On(e, s)) ? n = n.filter((c) => c !== s) : a = i, s = he(s);
|
|
2969
2962
|
}
|
|
2970
2963
|
return t.set(e, n), n;
|
|
2971
2964
|
}
|
|
2972
|
-
function
|
|
2965
|
+
function Bs(e) {
|
|
2973
2966
|
let {
|
|
2974
2967
|
element: t,
|
|
2975
2968
|
boundary: r,
|
|
2976
2969
|
rootBoundary: n,
|
|
2977
2970
|
strategy: a
|
|
2978
2971
|
} = e;
|
|
2979
|
-
const o = [...r === "clippingAncestors" ?
|
|
2972
|
+
const o = [...r === "clippingAncestors" ? ct(t) ? [] : As(t, this._c) : [].concat(r), n], s = o[0], i = o.reduce((l, c) => {
|
|
2980
2973
|
const g = Vr(t, c, a);
|
|
2981
|
-
return l.top =
|
|
2974
|
+
return l.top = _e(g.top, l.top), l.right = $e(g.right, l.right), l.bottom = $e(g.bottom, l.bottom), l.left = _e(g.left, l.left), l;
|
|
2982
2975
|
}, Vr(t, s, a));
|
|
2983
2976
|
return {
|
|
2984
2977
|
width: i.right - i.left,
|
|
@@ -2987,17 +2980,17 @@ function Ms(e) {
|
|
|
2987
2980
|
y: i.top
|
|
2988
2981
|
};
|
|
2989
2982
|
}
|
|
2990
|
-
function
|
|
2983
|
+
function Ms(e) {
|
|
2991
2984
|
const {
|
|
2992
2985
|
width: t,
|
|
2993
2986
|
height: r
|
|
2994
|
-
} =
|
|
2987
|
+
} = Cn(e);
|
|
2995
2988
|
return {
|
|
2996
2989
|
width: t,
|
|
2997
2990
|
height: r
|
|
2998
2991
|
};
|
|
2999
2992
|
}
|
|
3000
|
-
function
|
|
2993
|
+
function $s(e, t, r) {
|
|
3001
2994
|
const n = le(t), a = ue(t), o = r === "fixed", s = De(e, !0, o, t);
|
|
3002
2995
|
let i = {
|
|
3003
2996
|
scrollLeft: 0,
|
|
@@ -3005,19 +2998,19 @@ function Ds(e, t, r) {
|
|
|
3005
2998
|
};
|
|
3006
2999
|
const l = ie(0);
|
|
3007
3000
|
if (n || !n && !o)
|
|
3008
|
-
if ((
|
|
3001
|
+
if ((Re(t) !== "body" || He(a)) && (i = dt(t)), n) {
|
|
3009
3002
|
const f = De(t, !0, o, t);
|
|
3010
3003
|
l.x = f.x + t.clientLeft, l.y = f.y + t.clientTop;
|
|
3011
3004
|
} else a && (l.x = ar(a));
|
|
3012
|
-
const c = a && !n && !o ?
|
|
3005
|
+
const c = a && !n && !o ? Ln(a, i) : ie(0), g = s.left + i.scrollLeft - l.x - c.x, d = s.top + i.scrollTop - l.y - c.y;
|
|
3013
3006
|
return {
|
|
3014
3007
|
x: g,
|
|
3015
|
-
y:
|
|
3008
|
+
y: d,
|
|
3016
3009
|
width: s.width,
|
|
3017
3010
|
height: s.height
|
|
3018
3011
|
};
|
|
3019
3012
|
}
|
|
3020
|
-
function
|
|
3013
|
+
function Nt(e) {
|
|
3021
3014
|
return ne(e).position === "static";
|
|
3022
3015
|
}
|
|
3023
3016
|
function zr(e, t) {
|
|
@@ -3028,28 +3021,28 @@ function zr(e, t) {
|
|
|
3028
3021
|
let r = e.offsetParent;
|
|
3029
3022
|
return ue(e) === r && (r = r.ownerDocument.body), r;
|
|
3030
3023
|
}
|
|
3031
|
-
function
|
|
3024
|
+
function An(e, t) {
|
|
3032
3025
|
const r = Q(e);
|
|
3033
|
-
if (
|
|
3026
|
+
if (ct(e))
|
|
3034
3027
|
return r;
|
|
3035
3028
|
if (!le(e)) {
|
|
3036
3029
|
let a = he(e);
|
|
3037
|
-
for (; a && !
|
|
3038
|
-
if (re(a) && !
|
|
3030
|
+
for (; a && !Se(a); ) {
|
|
3031
|
+
if (re(a) && !Nt(a))
|
|
3039
3032
|
return a;
|
|
3040
3033
|
a = he(a);
|
|
3041
3034
|
}
|
|
3042
3035
|
return r;
|
|
3043
3036
|
}
|
|
3044
3037
|
let n = zr(e, t);
|
|
3045
|
-
for (; n &&
|
|
3038
|
+
for (; n && Es(n) && Nt(n); )
|
|
3046
3039
|
n = zr(n, t);
|
|
3047
|
-
return n &&
|
|
3040
|
+
return n && Se(n) && Nt(n) && !rr(n) ? r : n || Ts(e) || r;
|
|
3048
3041
|
}
|
|
3049
|
-
const
|
|
3050
|
-
const t = this.getOffsetParent ||
|
|
3042
|
+
const Ds = async function(e) {
|
|
3043
|
+
const t = this.getOffsetParent || An, r = this.getDimensions, n = await r(e.floating);
|
|
3051
3044
|
return {
|
|
3052
|
-
reference:
|
|
3045
|
+
reference: $s(e.reference, await t(e.floating), e.strategy),
|
|
3053
3046
|
floating: {
|
|
3054
3047
|
x: 0,
|
|
3055
3048
|
y: 0,
|
|
@@ -3058,36 +3051,36 @@ const Ps = async function(e) {
|
|
|
3058
3051
|
}
|
|
3059
3052
|
};
|
|
3060
3053
|
};
|
|
3061
|
-
function
|
|
3054
|
+
function Ps(e) {
|
|
3062
3055
|
return ne(e).direction === "rtl";
|
|
3063
3056
|
}
|
|
3064
|
-
const
|
|
3065
|
-
convertOffsetParentRelativeRectToViewportRelativeRect:
|
|
3057
|
+
const Vs = {
|
|
3058
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: Cs,
|
|
3066
3059
|
getDocumentElement: ue,
|
|
3067
|
-
getClippingRect:
|
|
3068
|
-
getOffsetParent:
|
|
3069
|
-
getElementRects:
|
|
3070
|
-
getClientRects:
|
|
3071
|
-
getDimensions:
|
|
3072
|
-
getScale:
|
|
3060
|
+
getClippingRect: Bs,
|
|
3061
|
+
getOffsetParent: An,
|
|
3062
|
+
getElementRects: Ds,
|
|
3063
|
+
getClientRects: Rs,
|
|
3064
|
+
getDimensions: Ms,
|
|
3065
|
+
getScale: Ee,
|
|
3073
3066
|
isElement: re,
|
|
3074
|
-
isRTL:
|
|
3075
|
-
}, Us = _s, Hs =
|
|
3067
|
+
isRTL: Ps
|
|
3068
|
+
}, zs = ws, Us = _s, Hs = ks, Fs = vs, Ws = (e, t, r) => {
|
|
3076
3069
|
const n = /* @__PURE__ */ new Map(), a = {
|
|
3077
|
-
platform:
|
|
3070
|
+
platform: Vs,
|
|
3078
3071
|
...r
|
|
3079
3072
|
}, o = {
|
|
3080
3073
|
...a.platform,
|
|
3081
3074
|
_c: n
|
|
3082
3075
|
};
|
|
3083
|
-
return
|
|
3076
|
+
return bs(e, t, {
|
|
3084
3077
|
...a,
|
|
3085
3078
|
platform: o
|
|
3086
3079
|
});
|
|
3087
3080
|
}, Ur = ["mousedown", "touchstart"];
|
|
3088
|
-
function
|
|
3081
|
+
function Gs(e, t, r) {
|
|
3089
3082
|
const n = A(null);
|
|
3090
|
-
return
|
|
3083
|
+
return D(() => {
|
|
3091
3084
|
const a = (o) => {
|
|
3092
3085
|
const s = o ? o.target : void 0;
|
|
3093
3086
|
if (Array.isArray(r)) {
|
|
@@ -3106,50 +3099,50 @@ function js(e, t, r) {
|
|
|
3106
3099
|
};
|
|
3107
3100
|
}, [e, r, t]), n;
|
|
3108
3101
|
}
|
|
3109
|
-
function
|
|
3102
|
+
function js(e, t) {
|
|
3110
3103
|
const [r, n] = Z(!1), a = A(null), o = A(null), s = te(() => {
|
|
3111
3104
|
n((l) => (!l && (!a.current || a.current === -1) && (a.current = window.setInterval(o.current, t)), !0));
|
|
3112
3105
|
}, [t]), i = te(() => {
|
|
3113
3106
|
n(!1), window.clearInterval(a.current || -1), a.current = -1;
|
|
3114
3107
|
}, []);
|
|
3115
|
-
return
|
|
3108
|
+
return D(() => (o.current = e, r && s(), i), [e, r, s, i]), { start: s, stop: i, active: r };
|
|
3116
3109
|
}
|
|
3117
|
-
const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`,
|
|
3110
|
+
const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, qs = () => h("absolute top-0 left-0 w-max py-1 px-2 rounded text-sm z-50"), Hr = ({
|
|
3118
3111
|
mode: e
|
|
3119
3112
|
}) => h({
|
|
3120
3113
|
"bg-surface-darker": e === "dark" || e === "system",
|
|
3121
3114
|
"bg-surface-light": e === "light" || e === "alt-system",
|
|
3122
3115
|
"dark:bg-surface-light": e === "system",
|
|
3123
3116
|
"dark:bg-surface-darker": e === "alt-system"
|
|
3124
|
-
}),
|
|
3117
|
+
}), Ks = ({
|
|
3125
3118
|
mode: e
|
|
3126
3119
|
}) => h({
|
|
3127
3120
|
"text-copy-light": e === "dark" || e === "system",
|
|
3128
3121
|
"text-copy-dark": e === "light" || e === "alt-system",
|
|
3129
3122
|
"dark:text-copy-dark": e === "system",
|
|
3130
3123
|
"dark:text-copy-light": e === "alt-system"
|
|
3131
|
-
}),
|
|
3124
|
+
}), Ys = () => h("absolute", "size-2", "transform rotate-45"), Js = ({
|
|
3132
3125
|
mode: e,
|
|
3133
3126
|
className: t,
|
|
3134
3127
|
tooltipClassName: r,
|
|
3135
3128
|
arrowClassName: n
|
|
3136
3129
|
}) => {
|
|
3137
3130
|
const a = h("relative inline-block", t), o = h(
|
|
3138
|
-
|
|
3139
|
-
|
|
3131
|
+
cs,
|
|
3132
|
+
qs(),
|
|
3140
3133
|
Hr({ mode: e }),
|
|
3141
|
-
|
|
3134
|
+
Ks({ mode: e }),
|
|
3142
3135
|
r
|
|
3143
3136
|
), s = h(
|
|
3144
|
-
|
|
3145
|
-
|
|
3137
|
+
ds,
|
|
3138
|
+
Ys(),
|
|
3146
3139
|
Hr({ mode: e }),
|
|
3147
3140
|
n
|
|
3148
3141
|
);
|
|
3149
3142
|
return { tooltip: o, arrow: s, wrapper: a };
|
|
3150
|
-
},
|
|
3143
|
+
}, Xs = ({ delay: e = 300 }) => ({
|
|
3151
3144
|
animation: `av-tooltip-fade-in ${e}ms ease-in-out`
|
|
3152
|
-
}),
|
|
3145
|
+
}), Zs = 5e3, ut = ({
|
|
3153
3146
|
trigger: e,
|
|
3154
3147
|
label: t,
|
|
3155
3148
|
placement: r = "top",
|
|
@@ -3159,33 +3152,33 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3159
3152
|
tooltipClassName: s,
|
|
3160
3153
|
arrowClassName: i
|
|
3161
3154
|
}) => {
|
|
3162
|
-
const l =
|
|
3155
|
+
const l = Gs(() => {
|
|
3163
3156
|
y.stop(), p(!1);
|
|
3164
|
-
}), c = A(null), g = A(null), [
|
|
3157
|
+
}), c = A(null), g = A(null), [d, f] = Z(!1), [m, p] = Z(!1), y = js(() => {
|
|
3165
3158
|
p(!1);
|
|
3166
|
-
},
|
|
3159
|
+
}, Zs), v = Js({
|
|
3167
3160
|
mode: n,
|
|
3168
3161
|
className: o,
|
|
3169
3162
|
tooltipClassName: s,
|
|
3170
3163
|
arrowClassName: i
|
|
3171
|
-
}), b =
|
|
3172
|
-
var E, T, S,
|
|
3164
|
+
}), b = Xs({ delay: a }), k = te(async () => {
|
|
3165
|
+
var E, T, S, P;
|
|
3173
3166
|
if (l.current && c.current && g.current) {
|
|
3174
3167
|
const {
|
|
3175
3168
|
x: O,
|
|
3176
3169
|
y: G,
|
|
3177
3170
|
middlewareData: $,
|
|
3178
3171
|
placement: B
|
|
3179
|
-
} = await
|
|
3172
|
+
} = await Ws(l.current, c.current, {
|
|
3180
3173
|
placement: r,
|
|
3181
3174
|
middleware: [
|
|
3182
|
-
|
|
3183
|
-
|
|
3175
|
+
zs(10),
|
|
3176
|
+
Hs({
|
|
3184
3177
|
crossAxis: r.includes("-"),
|
|
3185
3178
|
fallbackAxisSideDirection: "start"
|
|
3186
3179
|
}),
|
|
3187
|
-
|
|
3188
|
-
|
|
3180
|
+
Us({ padding: 5 }),
|
|
3181
|
+
Fs({ element: g.current })
|
|
3189
3182
|
]
|
|
3190
3183
|
});
|
|
3191
3184
|
(E = c == null ? void 0 : c.current) != null && E.style && Object.assign(c.current.style, {
|
|
@@ -3201,16 +3194,16 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3201
3194
|
}[B.split("-")[0]];
|
|
3202
3195
|
(T = g == null ? void 0 : g.current) != null && T.style && Object.assign(g.current.style, {
|
|
3203
3196
|
left: Ke((S = $.arrow) == null ? void 0 : S.x),
|
|
3204
|
-
top: Ke((
|
|
3197
|
+
top: Ke((P = $.arrow) == null ? void 0 : P.y),
|
|
3205
3198
|
right: "",
|
|
3206
3199
|
bottom: "",
|
|
3207
3200
|
[R]: "-4px"
|
|
3208
3201
|
});
|
|
3209
3202
|
}
|
|
3210
3203
|
}, [r, b, l]);
|
|
3211
|
-
|
|
3212
|
-
(async () =>
|
|
3213
|
-
}, [k,
|
|
3204
|
+
D(() => {
|
|
3205
|
+
(async () => d && await k())();
|
|
3206
|
+
}, [k, d]);
|
|
3214
3207
|
const w = () => {
|
|
3215
3208
|
f(!1), p(!0), y.start();
|
|
3216
3209
|
}, _ = () => {
|
|
@@ -3228,7 +3221,7 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3228
3221
|
onClick: w,
|
|
3229
3222
|
children: [
|
|
3230
3223
|
e,
|
|
3231
|
-
|
|
3224
|
+
d && /* @__PURE__ */ C(
|
|
3232
3225
|
"div",
|
|
3233
3226
|
{
|
|
3234
3227
|
role: "tooltip",
|
|
@@ -3236,33 +3229,33 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3236
3229
|
className: v.tooltip,
|
|
3237
3230
|
children: [
|
|
3238
3231
|
t,
|
|
3239
|
-
/* @__PURE__ */
|
|
3232
|
+
/* @__PURE__ */ u("div", { ref: g, className: v.arrow })
|
|
3240
3233
|
]
|
|
3241
3234
|
}
|
|
3242
3235
|
)
|
|
3243
3236
|
]
|
|
3244
3237
|
}
|
|
3245
3238
|
);
|
|
3246
|
-
},
|
|
3239
|
+
}, Qs = ({
|
|
3247
3240
|
className: e
|
|
3248
3241
|
}) => {
|
|
3249
3242
|
const { state: t, dispatch: r } = W(pe), n = A(null), a = A(!1), o = (s) => {
|
|
3250
3243
|
s.preventDefault(), r({
|
|
3251
|
-
type:
|
|
3244
|
+
type: et
|
|
3252
3245
|
});
|
|
3253
3246
|
};
|
|
3254
|
-
return
|
|
3247
|
+
return D(() => {
|
|
3255
3248
|
var s;
|
|
3256
3249
|
(t == null ? void 0 : t.streaming) === !0 && !a.current && n.current && (a.current = !0, n.current.focus()), (t == null ? void 0 : t.streaming) === !1 && (a.current = !1, (s = n.current) == null || s.blur());
|
|
3257
|
-
}, [t]), /* @__PURE__ */
|
|
3258
|
-
|
|
3250
|
+
}, [t]), /* @__PURE__ */ u(
|
|
3251
|
+
ut,
|
|
3259
3252
|
{
|
|
3260
3253
|
label: "New Chat",
|
|
3261
3254
|
mode: "light",
|
|
3262
3255
|
placement: "top-start",
|
|
3263
3256
|
className: e,
|
|
3264
|
-
trigger: /* @__PURE__ */
|
|
3265
|
-
|
|
3257
|
+
trigger: /* @__PURE__ */ u(
|
|
3258
|
+
tt,
|
|
3266
3259
|
{
|
|
3267
3260
|
noBorder: !0,
|
|
3268
3261
|
mode: "dark",
|
|
@@ -3270,12 +3263,12 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3270
3263
|
label: "New Chat",
|
|
3271
3264
|
ref: n,
|
|
3272
3265
|
onClick: o,
|
|
3273
|
-
children: t != null && t.streaming ? /* @__PURE__ */
|
|
3266
|
+
children: t != null && t.streaming ? /* @__PURE__ */ u(La, { size: "size-4", monotone: !0 }) : /* @__PURE__ */ u(Oa, { size: "size-4" })
|
|
3274
3267
|
}
|
|
3275
3268
|
)
|
|
3276
3269
|
}
|
|
3277
3270
|
);
|
|
3278
|
-
},
|
|
3271
|
+
}, Ht = Rt.createContext({
|
|
3279
3272
|
getItemProps: () => ({}),
|
|
3280
3273
|
activeIndex: null,
|
|
3281
3274
|
/* v8 ignore next 2 */
|
|
@@ -3295,7 +3288,7 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3295
3288
|
return t.displayName || t.name || "Component";
|
|
3296
3289
|
}
|
|
3297
3290
|
return "Element";
|
|
3298
|
-
},
|
|
3291
|
+
}, Bn = en(
|
|
3299
3292
|
({
|
|
3300
3293
|
trigger: e,
|
|
3301
3294
|
children: t,
|
|
@@ -3306,7 +3299,7 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3306
3299
|
focusMode: s = "system",
|
|
3307
3300
|
...i
|
|
3308
3301
|
}, l) => {
|
|
3309
|
-
const [c, g] = Z(!1), [
|
|
3302
|
+
const [c, g] = Z(!1), [d, f] = Z(!1), [m, p] = Z(null), y = A([]), v = A([]), b = W(Ht), k = rn(), w = fa(), _ = nn(), { floatingStyles: x, refs: E, context: T } = ga({
|
|
3310
3303
|
nodeId: w,
|
|
3311
3304
|
open: c,
|
|
3312
3305
|
onOpenChange: (U) => {
|
|
@@ -3314,23 +3307,23 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3314
3307
|
},
|
|
3315
3308
|
placement: n,
|
|
3316
3309
|
strategy: "fixed",
|
|
3317
|
-
middleware: [
|
|
3318
|
-
whileElementsMounted:
|
|
3319
|
-
}), S =
|
|
3310
|
+
middleware: [ha({ mainAxis: 10 }), pa(), ya()],
|
|
3311
|
+
whileElementsMounted: ba
|
|
3312
|
+
}), S = va(T, {
|
|
3320
3313
|
event: "mousedown",
|
|
3321
3314
|
toggle: !0,
|
|
3322
3315
|
ignoreMouse: !1
|
|
3323
|
-
}),
|
|
3316
|
+
}), P = ka(T, { role: "menu" }), O = xa(T, { bubbles: !0 }), G = wa(T, {
|
|
3324
3317
|
listRef: y,
|
|
3325
3318
|
activeIndex: m,
|
|
3326
3319
|
nested: !1,
|
|
3327
3320
|
onNavigate: p,
|
|
3328
3321
|
loop: !0
|
|
3329
|
-
}), $ =
|
|
3322
|
+
}), $ = _a(T, {
|
|
3330
3323
|
listRef: v,
|
|
3331
3324
|
onMatch: c ? p : void 0,
|
|
3332
3325
|
activeIndex: m
|
|
3333
|
-
}), { getReferenceProps: B, getFloatingProps: R, getItemProps: X } =
|
|
3326
|
+
}), { getReferenceProps: B, getFloatingProps: R, getItemProps: X } = Ea([S, P, O, G, $]), q = Fr(e) === "Button" || Fr(e) === "ButtonIcon", K = q ? {
|
|
3334
3327
|
noInternalClick: q,
|
|
3335
3328
|
focusMode: s,
|
|
3336
3329
|
mode: o
|
|
@@ -3340,7 +3333,7 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3340
3333
|
...K,
|
|
3341
3334
|
"aria-label": r,
|
|
3342
3335
|
"data-open": c ? "" : void 0,
|
|
3343
|
-
"data-focus-inside":
|
|
3336
|
+
"data-focus-inside": d ? "" : void 0,
|
|
3344
3337
|
ref: an([E.setReference, _.ref, l]),
|
|
3345
3338
|
...B(
|
|
3346
3339
|
b.getItemProps({
|
|
@@ -3349,7 +3342,7 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3349
3342
|
)
|
|
3350
3343
|
}
|
|
3351
3344
|
);
|
|
3352
|
-
return
|
|
3345
|
+
return D(() => {
|
|
3353
3346
|
if (!k)
|
|
3354
3347
|
return;
|
|
3355
3348
|
function U() {
|
|
@@ -3358,12 +3351,12 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3358
3351
|
return k.events.on("click", U), () => {
|
|
3359
3352
|
k.events.off("click", U);
|
|
3360
3353
|
};
|
|
3361
|
-
}, [k, a]),
|
|
3354
|
+
}, [k, a]), D(() => {
|
|
3362
3355
|
c && k && k.events.emit("menuopen", { nodeId: w });
|
|
3363
|
-
}, [k, c, w]), /* @__PURE__ */ C(
|
|
3356
|
+
}, [k, c, w]), /* @__PURE__ */ C(Ta, { id: w, children: [
|
|
3364
3357
|
z,
|
|
3365
|
-
/* @__PURE__ */
|
|
3366
|
-
|
|
3358
|
+
/* @__PURE__ */ u(
|
|
3359
|
+
Ht.Provider,
|
|
3367
3360
|
{
|
|
3368
3361
|
value: {
|
|
3369
3362
|
activeIndex: m,
|
|
@@ -3372,14 +3365,14 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3372
3365
|
setHasFocusInside: f,
|
|
3373
3366
|
isOpen: c
|
|
3374
3367
|
},
|
|
3375
|
-
children: /* @__PURE__ */
|
|
3376
|
-
|
|
3368
|
+
children: /* @__PURE__ */ u(Sa, { elementsRef: y, labelsRef: v, children: c && /* @__PURE__ */ u(Na, { children: /* @__PURE__ */ u(
|
|
3369
|
+
Ca,
|
|
3377
3370
|
{
|
|
3378
3371
|
context: T,
|
|
3379
3372
|
modal: !1,
|
|
3380
3373
|
initialFocus: 0,
|
|
3381
3374
|
returnFocus: !0,
|
|
3382
|
-
children: /* @__PURE__ */
|
|
3375
|
+
children: /* @__PURE__ */ u(
|
|
3383
3376
|
"div",
|
|
3384
3377
|
{
|
|
3385
3378
|
ref: E.setFloating,
|
|
@@ -3395,10 +3388,10 @@ const Ke = (e, t = "px") => typeof e > "u" ? "" : `${Math.round(e)}${t}`, Ks = (
|
|
|
3395
3388
|
)
|
|
3396
3389
|
] });
|
|
3397
3390
|
}
|
|
3398
|
-
), or = en((e, t) => /* @__PURE__ */
|
|
3391
|
+
), or = en((e, t) => /* @__PURE__ */ u(Ra, { children: /* @__PURE__ */ u(Bn, { ...e, ref: t }) }));
|
|
3399
3392
|
or.displayName = "Menu";
|
|
3400
|
-
|
|
3401
|
-
const Ze =
|
|
3393
|
+
Bn.displayName = "MenuComponent";
|
|
3394
|
+
const Ze = Rt.forwardRef(
|
|
3402
3395
|
({
|
|
3403
3396
|
label: e,
|
|
3404
3397
|
disabled: t,
|
|
@@ -3410,9 +3403,9 @@ const Ze = Ct.forwardRef(
|
|
|
3410
3403
|
...i
|
|
3411
3404
|
}, l) => {
|
|
3412
3405
|
let c = "";
|
|
3413
|
-
const g =
|
|
3406
|
+
const g = Rt.useContext(Ht), d = nn({ label: t ? null : e }), f = rn(), m = an([d.ref, l]);
|
|
3414
3407
|
if (n && a)
|
|
3415
|
-
return /* @__PURE__ */
|
|
3408
|
+
return /* @__PURE__ */ u(
|
|
3416
3409
|
"div",
|
|
3417
3410
|
{
|
|
3418
3411
|
role: "menuitem",
|
|
@@ -3455,17 +3448,17 @@ const Ze = Ct.forwardRef(
|
|
|
3455
3448
|
}),
|
|
3456
3449
|
children: [
|
|
3457
3450
|
r,
|
|
3458
|
-
e && /* @__PURE__ */
|
|
3451
|
+
e && /* @__PURE__ */ u("span", { className: c, children: e })
|
|
3459
3452
|
]
|
|
3460
3453
|
}
|
|
3461
3454
|
);
|
|
3462
3455
|
}
|
|
3463
3456
|
);
|
|
3464
3457
|
Ze.displayName = "MenuItem";
|
|
3465
|
-
const
|
|
3458
|
+
const ul = ({ className: e, ...t }) => {
|
|
3466
3459
|
const r = h(e, "my-1 border-t border-border-medium");
|
|
3467
|
-
return /* @__PURE__ */
|
|
3468
|
-
},
|
|
3460
|
+
return /* @__PURE__ */ u("div", { className: r, ...t });
|
|
3461
|
+
}, Mn = ({
|
|
3469
3462
|
className: e,
|
|
3470
3463
|
...t
|
|
3471
3464
|
}) => {
|
|
@@ -3473,7 +3466,7 @@ const ml = ({ className: e, ...t }) => {
|
|
|
3473
3466
|
e,
|
|
3474
3467
|
"pt-1 mb-2 text-sm text-copy-dark border-b border-border-medium"
|
|
3475
3468
|
);
|
|
3476
|
-
return /* @__PURE__ */
|
|
3469
|
+
return /* @__PURE__ */ u("div", { className: r, ...t });
|
|
3477
3470
|
};
|
|
3478
3471
|
/*!
|
|
3479
3472
|
@versini/ui-menu v3.2.11
|
|
@@ -3488,20 +3481,20 @@ try {
|
|
|
3488
3481
|
});
|
|
3489
3482
|
} catch {
|
|
3490
3483
|
}
|
|
3491
|
-
const
|
|
3484
|
+
const ei = (e) => {
|
|
3492
3485
|
for (let t = 0; t < e.length; t++)
|
|
3493
3486
|
if (e[t].enabled)
|
|
3494
3487
|
return !0;
|
|
3495
3488
|
return !1;
|
|
3496
|
-
},
|
|
3489
|
+
}, ti = ({
|
|
3497
3490
|
className: e,
|
|
3498
3491
|
defaultPlacement: t = "top-start"
|
|
3499
3492
|
}) => {
|
|
3500
|
-
const { dispatch: r } = W(
|
|
3493
|
+
const { dispatch: r } = W(it), { getAccessToken: n, user: a } = Pe(), {
|
|
3501
3494
|
data: o,
|
|
3502
3495
|
error: s,
|
|
3503
3496
|
isLoading: i
|
|
3504
|
-
} =
|
|
3497
|
+
} = Qt({
|
|
3505
3498
|
keys: [a == null ? void 0 : a.username],
|
|
3506
3499
|
getAccessToken: n
|
|
3507
3500
|
}), l = (c, g) => {
|
|
@@ -3512,8 +3505,8 @@ const ti = (e) => {
|
|
|
3512
3505
|
}
|
|
3513
3506
|
});
|
|
3514
3507
|
};
|
|
3515
|
-
return s || i ? null : o && o.tags &&
|
|
3516
|
-
|
|
3508
|
+
return s || i ? null : o && o.tags && ei(o.tags) && /* @__PURE__ */ u(
|
|
3509
|
+
ut,
|
|
3517
3510
|
{
|
|
3518
3511
|
label: "Custom Prompts",
|
|
3519
3512
|
mode: "light",
|
|
@@ -3523,11 +3516,11 @@ const ti = (e) => {
|
|
|
3523
3516
|
{
|
|
3524
3517
|
mode: "dark",
|
|
3525
3518
|
focusMode: "light",
|
|
3526
|
-
trigger: /* @__PURE__ */
|
|
3519
|
+
trigger: /* @__PURE__ */ u(tt, { noBorder: !0, label: "Prompts", children: /* @__PURE__ */ u(Ia, { size: "size-4" }) }),
|
|
3527
3520
|
defaultPlacement: t,
|
|
3528
3521
|
children: [
|
|
3529
|
-
/* @__PURE__ */
|
|
3530
|
-
o && o.tags && o.tags.map((c) => c.enabled && c.label && c.content && /* @__PURE__ */
|
|
3522
|
+
/* @__PURE__ */ u(Mn, { children: "Prompts" }),
|
|
3523
|
+
o && o.tags && o.tags.map((c) => c.enabled && c.label && c.content && /* @__PURE__ */ u(
|
|
3531
3524
|
Ze,
|
|
3532
3525
|
{
|
|
3533
3526
|
label: c.label,
|
|
@@ -3540,19 +3533,19 @@ const ti = (e) => {
|
|
|
3540
3533
|
)
|
|
3541
3534
|
}
|
|
3542
3535
|
);
|
|
3543
|
-
},
|
|
3536
|
+
}, ri = ({
|
|
3544
3537
|
className: e
|
|
3545
3538
|
}) => {
|
|
3546
3539
|
const { state: t } = W(pe);
|
|
3547
|
-
return /* @__PURE__ */
|
|
3548
|
-
|
|
3540
|
+
return /* @__PURE__ */ u(
|
|
3541
|
+
ut,
|
|
3549
3542
|
{
|
|
3550
3543
|
label: "Send Message",
|
|
3551
3544
|
mode: "light",
|
|
3552
3545
|
placement: "top-end",
|
|
3553
3546
|
className: e,
|
|
3554
|
-
trigger: /* @__PURE__ */
|
|
3555
|
-
|
|
3547
|
+
trigger: /* @__PURE__ */ u(
|
|
3548
|
+
tt,
|
|
3556
3549
|
{
|
|
3557
3550
|
iconClassName: "text-copy-lighter pr-0.5",
|
|
3558
3551
|
disabled: t == null ? void 0 : t.streaming,
|
|
@@ -3561,12 +3554,12 @@ const ti = (e) => {
|
|
|
3561
3554
|
type: "submit",
|
|
3562
3555
|
mode: "light",
|
|
3563
3556
|
focusMode: "light",
|
|
3564
|
-
children: /* @__PURE__ */
|
|
3557
|
+
children: /* @__PURE__ */ u(Aa, { size: "size-4" })
|
|
3565
3558
|
}
|
|
3566
3559
|
)
|
|
3567
3560
|
}
|
|
3568
3561
|
);
|
|
3569
|
-
},
|
|
3562
|
+
}, ni = ({
|
|
3570
3563
|
className: e
|
|
3571
3564
|
}) => {
|
|
3572
3565
|
const { state: t, dispatch: r } = W(pe), { getAccessToken: n, user: a } = Pe(), {
|
|
@@ -3574,26 +3567,29 @@ const ti = (e) => {
|
|
|
3574
3567
|
error: s,
|
|
3575
3568
|
isLoading: i,
|
|
3576
3569
|
mutate: l
|
|
3577
|
-
} =
|
|
3570
|
+
} = Qt({
|
|
3578
3571
|
keys: [a == null ? void 0 : a.username],
|
|
3579
3572
|
getAccessToken: n
|
|
3580
3573
|
}), c = async (g) => {
|
|
3581
3574
|
try {
|
|
3582
|
-
await
|
|
3575
|
+
await vn({
|
|
3583
3576
|
accessToken: await n(),
|
|
3584
3577
|
type: Ve.SET_USER_PREFERENCES,
|
|
3585
3578
|
params: {
|
|
3586
3579
|
user: a == null ? void 0 : a.username,
|
|
3587
3580
|
engine: g
|
|
3588
3581
|
}
|
|
3589
|
-
}), l({ ...o }), t &&
|
|
3590
|
-
type:
|
|
3582
|
+
}), l({ ...o }), t && r({
|
|
3583
|
+
type: et,
|
|
3584
|
+
payload: {
|
|
3585
|
+
engine: g
|
|
3586
|
+
}
|
|
3591
3587
|
});
|
|
3592
3588
|
} catch {
|
|
3593
3589
|
}
|
|
3594
3590
|
};
|
|
3595
|
-
return s || i ? null : o && /* @__PURE__ */
|
|
3596
|
-
|
|
3591
|
+
return s || i ? null : o && /* @__PURE__ */ u(
|
|
3592
|
+
ut,
|
|
3597
3593
|
{
|
|
3598
3594
|
label: "Toggle Engines",
|
|
3599
3595
|
mode: "light",
|
|
@@ -3603,26 +3599,26 @@ const ti = (e) => {
|
|
|
3603
3599
|
{
|
|
3604
3600
|
mode: "dark",
|
|
3605
3601
|
focusMode: "light",
|
|
3606
|
-
trigger: /* @__PURE__ */
|
|
3602
|
+
trigger: /* @__PURE__ */ u(tt, { noBorder: !0, label: "Engines", children: o && o.engine === pt ? /* @__PURE__ */ u(wr, { size: "size-4 sm:size-5" }) : /* @__PURE__ */ u(_r, { size: "size-4 sm:size-5" }) }),
|
|
3607
3603
|
defaultPlacement: "top-start",
|
|
3608
3604
|
children: [
|
|
3609
|
-
/* @__PURE__ */
|
|
3610
|
-
/* @__PURE__ */
|
|
3605
|
+
/* @__PURE__ */ u(Mn, { children: "Engines" }),
|
|
3606
|
+
/* @__PURE__ */ u(
|
|
3611
3607
|
Ze,
|
|
3612
3608
|
{
|
|
3613
|
-
selected: o && o.engine ===
|
|
3614
|
-
label: "
|
|
3615
|
-
icon: /* @__PURE__ */
|
|
3616
|
-
onClick: () => c(
|
|
3609
|
+
selected: o && o.engine === pt,
|
|
3610
|
+
label: "Anthropic",
|
|
3611
|
+
icon: /* @__PURE__ */ u(wr, {}),
|
|
3612
|
+
onClick: () => c(pt)
|
|
3617
3613
|
}
|
|
3618
3614
|
),
|
|
3619
|
-
/* @__PURE__ */
|
|
3615
|
+
/* @__PURE__ */ u(
|
|
3620
3616
|
Ze,
|
|
3621
3617
|
{
|
|
3622
|
-
selected: o && o.engine ===
|
|
3623
|
-
label: "
|
|
3624
|
-
icon: /* @__PURE__ */
|
|
3625
|
-
onClick: () => c(
|
|
3618
|
+
selected: o && o.engine === yr,
|
|
3619
|
+
label: "OpenAI",
|
|
3620
|
+
icon: /* @__PURE__ */ u(_r, {}),
|
|
3621
|
+
onClick: () => c(yr)
|
|
3626
3622
|
}
|
|
3627
3623
|
)
|
|
3628
3624
|
]
|
|
@@ -3630,35 +3626,35 @@ const ti = (e) => {
|
|
|
3630
3626
|
)
|
|
3631
3627
|
}
|
|
3632
3628
|
);
|
|
3633
|
-
},
|
|
3629
|
+
}, ai = () => h(
|
|
3634
3630
|
"relative rounded-md text-base h-auto min-w-28 overflow-hidden pt-2"
|
|
3635
|
-
), Wr = () => h("bg-surface-darker"),
|
|
3631
|
+
), Wr = () => h("bg-surface-darker"), oi = () => h("text-copy-lighter caret-copy-light"), si = () => h(
|
|
3636
3632
|
"has-[.av-prompt-editable:focus]:outline",
|
|
3637
3633
|
"has-[.av-prompt-editable:focus]:outline-2",
|
|
3638
3634
|
"has-[.av-prompt-editable:focus]:outline-offset-2",
|
|
3639
3635
|
"has-[.av-prompt-editable:focus]:outline-focus-light"
|
|
3640
|
-
),
|
|
3636
|
+
), ii = () => h(
|
|
3641
3637
|
"peer",
|
|
3642
3638
|
"text-base resize-none overflow-hidden w-full text-inherit outline-none",
|
|
3643
3639
|
"h-6 pr-2 pl-4"
|
|
3644
|
-
),
|
|
3640
|
+
), li = ({ className: e }) => {
|
|
3645
3641
|
const t = h(
|
|
3646
|
-
|
|
3647
|
-
|
|
3642
|
+
Yn,
|
|
3643
|
+
ai(),
|
|
3648
3644
|
Wr(),
|
|
3645
|
+
oi(),
|
|
3649
3646
|
si(),
|
|
3650
|
-
ii(),
|
|
3651
3647
|
e
|
|
3652
3648
|
), r = h(
|
|
3653
|
-
|
|
3654
|
-
|
|
3649
|
+
Jn,
|
|
3650
|
+
ii(),
|
|
3655
3651
|
Wr()
|
|
3656
3652
|
);
|
|
3657
3653
|
return {
|
|
3658
3654
|
wrapper: t,
|
|
3659
3655
|
textArea: r
|
|
3660
3656
|
};
|
|
3661
|
-
},
|
|
3657
|
+
}, ci = ({
|
|
3662
3658
|
className: e,
|
|
3663
3659
|
label: t,
|
|
3664
3660
|
value: r,
|
|
@@ -3668,9 +3664,9 @@ const ti = (e) => {
|
|
|
3668
3664
|
ref: s,
|
|
3669
3665
|
...i
|
|
3670
3666
|
}) => {
|
|
3671
|
-
const { state:
|
|
3667
|
+
const { state: d } = W(pe), { state: f } = W(it), m = A(null), p = A(null), y = Fa([s, p]), v = Ga(), b = li({
|
|
3672
3668
|
className: e
|
|
3673
|
-
}), [k, w] =
|
|
3669
|
+
}), [k, w] = Wa({
|
|
3674
3670
|
value: r,
|
|
3675
3671
|
initialControlledDelay: 20,
|
|
3676
3672
|
defaultValue: n,
|
|
@@ -3696,21 +3692,21 @@ const ti = (e) => {
|
|
|
3696
3692
|
}, E = (T) => {
|
|
3697
3693
|
w(T.target.value), _();
|
|
3698
3694
|
};
|
|
3699
|
-
return
|
|
3700
|
-
|
|
3701
|
-
}, [
|
|
3695
|
+
return D(() => {
|
|
3696
|
+
d && d.usage === 0 && d.messages.length === 0 && p.current && (p.current.style.height = "24px");
|
|
3697
|
+
}, [d]), D(() => {
|
|
3702
3698
|
f.lastTriggeredTimestamp && setTimeout(() => {
|
|
3703
3699
|
_();
|
|
3704
3700
|
}, 100);
|
|
3705
|
-
}, [f.lastTriggeredTimestamp, _]), /* @__PURE__ */
|
|
3701
|
+
}, [f.lastTriggeredTimestamp, _]), /* @__PURE__ */ u(
|
|
3706
3702
|
"div",
|
|
3707
3703
|
{
|
|
3708
3704
|
className: b.wrapper,
|
|
3709
3705
|
ref: m,
|
|
3710
3706
|
...i,
|
|
3711
3707
|
children: /* @__PURE__ */ C("form", { onSubmit: x, children: [
|
|
3712
|
-
/* @__PURE__ */
|
|
3713
|
-
/* @__PURE__ */
|
|
3708
|
+
/* @__PURE__ */ u("div", { id: v, className: "sr-only", children: t }),
|
|
3709
|
+
/* @__PURE__ */ u("div", { className: "relative", children: /* @__PURE__ */ u(
|
|
3714
3710
|
"textarea",
|
|
3715
3711
|
{
|
|
3716
3712
|
required: !0,
|
|
@@ -3720,21 +3716,21 @@ const ti = (e) => {
|
|
|
3720
3716
|
translate: "no",
|
|
3721
3717
|
onChange: E,
|
|
3722
3718
|
value: k,
|
|
3723
|
-
onKeyDown:
|
|
3719
|
+
onKeyDown: Va([["mod+Enter", x]]),
|
|
3724
3720
|
className: b.textArea,
|
|
3725
3721
|
"aria-labelledby": v
|
|
3726
3722
|
}
|
|
3727
3723
|
) }),
|
|
3728
3724
|
/* @__PURE__ */ C("div", { className: "p-2 flex items-center", children: [
|
|
3729
|
-
/* @__PURE__ */
|
|
3730
|
-
/* @__PURE__ */
|
|
3731
|
-
/* @__PURE__ */
|
|
3732
|
-
/* @__PURE__ */
|
|
3725
|
+
/* @__PURE__ */ u(ri, { className: "order-4 ml-auto" }),
|
|
3726
|
+
/* @__PURE__ */ u(Qs, { className: "order-1 mr-2" }),
|
|
3727
|
+
/* @__PURE__ */ u(ni, { className: "order-2 mr-2" }),
|
|
3728
|
+
/* @__PURE__ */ u(ti, { className: "order-3 mr-2" })
|
|
3733
3729
|
] })
|
|
3734
3730
|
] })
|
|
3735
3731
|
}
|
|
3736
3732
|
);
|
|
3737
|
-
},
|
|
3733
|
+
}, Ft = (e, t) => {
|
|
3738
3734
|
e({
|
|
3739
3735
|
type: Jr,
|
|
3740
3736
|
payload: {
|
|
@@ -3742,42 +3738,42 @@ const ti = (e) => {
|
|
|
3742
3738
|
}
|
|
3743
3739
|
});
|
|
3744
3740
|
}, Gr = (e) => {
|
|
3745
|
-
|
|
3746
|
-
type:
|
|
3741
|
+
Ft(e, !1), e({
|
|
3742
|
+
type: Ae,
|
|
3747
3743
|
payload: {
|
|
3748
3744
|
message: {
|
|
3749
3745
|
role: jt,
|
|
3750
|
-
content:
|
|
3746
|
+
content: ea
|
|
3751
3747
|
}
|
|
3752
3748
|
}
|
|
3753
3749
|
});
|
|
3754
|
-
},
|
|
3755
|
-
const { state: e, dispatch: t } = W(pe), { state: r, dispatch: n } = W(
|
|
3750
|
+
}, di = () => {
|
|
3751
|
+
const { state: e, dispatch: t } = W(pe), { state: r, dispatch: n } = W(it), [a, o] = Z(""), { getAccessToken: s, user: i } = Pe(), l = A(null), c = A(
|
|
3756
3752
|
null
|
|
3757
3753
|
);
|
|
3758
|
-
|
|
3754
|
+
D(() => {
|
|
3759
3755
|
(async () => {
|
|
3760
3756
|
var f;
|
|
3761
3757
|
if (!e || e.messages.length === 0) {
|
|
3762
3758
|
(f = c == null ? void 0 : c.current) == null || f.cancel();
|
|
3763
3759
|
return;
|
|
3764
3760
|
}
|
|
3765
|
-
const
|
|
3766
|
-
if (!(e.messages.length === 0 ||
|
|
3761
|
+
const d = e.messages[e.messages.length - 1];
|
|
3762
|
+
if (!(e.messages.length === 0 || d.message.role === Be || d.message.role === Xn || d.message.role === jt || d.message.role === Zn))
|
|
3767
3763
|
try {
|
|
3768
|
-
const m = await
|
|
3764
|
+
const m = await ts({
|
|
3769
3765
|
accessToken: await s(),
|
|
3770
3766
|
name: "generate",
|
|
3771
3767
|
data: {
|
|
3772
3768
|
messages: e.messages,
|
|
3773
|
-
model: e.engine ||
|
|
3769
|
+
model: e.engine || we,
|
|
3774
3770
|
user: (i == null ? void 0 : i.username) || "",
|
|
3775
3771
|
id: e.id,
|
|
3776
3772
|
usage: e.usage
|
|
3777
3773
|
}
|
|
3778
3774
|
});
|
|
3779
3775
|
if (m && m.ok) {
|
|
3780
|
-
|
|
3776
|
+
Ft(t, !0);
|
|
3781
3777
|
const p = Jt();
|
|
3782
3778
|
c.current = m.body.getReader();
|
|
3783
3779
|
const y = new TextDecoder();
|
|
@@ -3797,11 +3793,11 @@ const ti = (e) => {
|
|
|
3797
3793
|
usage: x.usage
|
|
3798
3794
|
}
|
|
3799
3795
|
}), t({
|
|
3800
|
-
type:
|
|
3796
|
+
type: Ae,
|
|
3801
3797
|
payload: {
|
|
3802
3798
|
message: {
|
|
3803
3799
|
content: _,
|
|
3804
|
-
role:
|
|
3800
|
+
role: Be,
|
|
3805
3801
|
messageId: p,
|
|
3806
3802
|
processingTime: x.processingTime,
|
|
3807
3803
|
name: x.name
|
|
@@ -3811,17 +3807,17 @@ const ti = (e) => {
|
|
|
3811
3807
|
break;
|
|
3812
3808
|
} else
|
|
3813
3809
|
t({
|
|
3814
|
-
type:
|
|
3810
|
+
type: Ae,
|
|
3815
3811
|
payload: {
|
|
3816
3812
|
message: {
|
|
3817
3813
|
content: k,
|
|
3818
|
-
role:
|
|
3814
|
+
role: Be,
|
|
3819
3815
|
messageId: p
|
|
3820
3816
|
}
|
|
3821
3817
|
}
|
|
3822
3818
|
});
|
|
3823
3819
|
}
|
|
3824
|
-
|
|
3820
|
+
Ft(t, !1);
|
|
3825
3821
|
} else
|
|
3826
3822
|
Gr(t);
|
|
3827
3823
|
} catch (m) {
|
|
@@ -3829,77 +3825,77 @@ const ti = (e) => {
|
|
|
3829
3825
|
}
|
|
3830
3826
|
})();
|
|
3831
3827
|
}, [e == null ? void 0 : e.messages]);
|
|
3832
|
-
const g = async (
|
|
3833
|
-
|
|
3834
|
-
type:
|
|
3828
|
+
const g = async (d) => {
|
|
3829
|
+
d.preventDefault(), t({
|
|
3830
|
+
type: Ae,
|
|
3835
3831
|
payload: {
|
|
3836
3832
|
message: {
|
|
3837
|
-
role:
|
|
3833
|
+
role: Ct,
|
|
3838
3834
|
content: a
|
|
3839
3835
|
}
|
|
3840
3836
|
}
|
|
3841
3837
|
}), o("");
|
|
3842
3838
|
};
|
|
3843
|
-
return
|
|
3839
|
+
return D(() => {
|
|
3844
3840
|
if (r.prompt !== "") {
|
|
3845
|
-
const
|
|
3846
|
-
|
|
3847
|
-
o(
|
|
3848
|
-
}) : o(
|
|
3841
|
+
const d = r.prompt.endsWith(":") && !r.prompt.endsWith(": ") ? r.prompt + " " : r.prompt;
|
|
3842
|
+
d.indexOf(vr) !== -1 ? navigator.clipboard.readText().then((m) => {
|
|
3843
|
+
o(d.replace(vr, m));
|
|
3844
|
+
}) : o(d), l.current && l.current.focus(), n({
|
|
3849
3845
|
type: Xr
|
|
3850
3846
|
});
|
|
3851
3847
|
}
|
|
3852
|
-
}, [r, n]),
|
|
3848
|
+
}, [r, n]), D(() => {
|
|
3853
3849
|
e && e.usage === 0 && e.messages.length === 0 && (o(""), l.current && l.current.focus());
|
|
3854
|
-
}, [e]),
|
|
3850
|
+
}, [e]), D(() => {
|
|
3855
3851
|
(e == null ? void 0 : e.streaming) === !1 && l.current && l.current.focus();
|
|
3856
|
-
}, [e]), /* @__PURE__ */
|
|
3857
|
-
|
|
3852
|
+
}, [e]), /* @__PURE__ */ u(Qe, { children: /* @__PURE__ */ u(
|
|
3853
|
+
ci,
|
|
3858
3854
|
{
|
|
3859
|
-
label:
|
|
3855
|
+
label: Qn,
|
|
3860
3856
|
onSubmit: g,
|
|
3861
3857
|
ref: l,
|
|
3862
3858
|
value: a,
|
|
3863
|
-
onChange: (
|
|
3859
|
+
onChange: (d) => o(d.target.value)
|
|
3864
3860
|
}
|
|
3865
3861
|
) });
|
|
3866
|
-
},
|
|
3862
|
+
}, ui = ({ isComponent: e }) => {
|
|
3867
3863
|
const { state: t } = W(pe), r = A(!1), n = window.innerWidth < 403, [a, o] = Z(
|
|
3868
3864
|
n ? "bottom-4" : e ? "top-[300px]" : "top-[245px]"
|
|
3869
3865
|
);
|
|
3870
|
-
return
|
|
3866
|
+
return D(() => {
|
|
3871
3867
|
n || t && (!r.current && t.streaming && o("bottom-4"), r.current = !!t.streaming);
|
|
3872
|
-
}, [t, n]),
|
|
3868
|
+
}, [t, n]), D(() => {
|
|
3873
3869
|
n || (t && t.messages.length === 0 && o(e ? "top-[300px]" : "top-[245px]"), t && !t.streaming && t.messages.length > 0 && o("bottom-4"));
|
|
3874
3870
|
}, [t, n, e]), /* @__PURE__ */ C(
|
|
3875
3871
|
"footer",
|
|
3876
3872
|
{
|
|
3877
3873
|
className: h(
|
|
3878
3874
|
"px-2 sm:px-0 md:mx-auto md:max-w-4xl w-full fixed left-1/2 transform -translate-x-1/2",
|
|
3879
|
-
|
|
3875
|
+
ss,
|
|
3880
3876
|
a
|
|
3881
3877
|
),
|
|
3882
3878
|
children: [
|
|
3883
|
-
/* @__PURE__ */
|
|
3884
|
-
/* @__PURE__ */
|
|
3879
|
+
/* @__PURE__ */ u(di, {}),
|
|
3880
|
+
/* @__PURE__ */ u("div", { className: "w-full text-center text-xs text-copy-lighter pt-2", children: ta })
|
|
3885
3881
|
]
|
|
3886
3882
|
}
|
|
3887
3883
|
);
|
|
3888
|
-
},
|
|
3884
|
+
}, mi = ({ show: e }) => e ? /* @__PURE__ */ u(
|
|
3889
3885
|
"div",
|
|
3890
3886
|
{
|
|
3891
3887
|
className: h(
|
|
3892
|
-
|
|
3888
|
+
is,
|
|
3893
3889
|
"bottom-44 fixed left-1/2 transform -translate-x-1/2"
|
|
3894
3890
|
),
|
|
3895
|
-
children: /* @__PURE__ */
|
|
3891
|
+
children: /* @__PURE__ */ u(
|
|
3896
3892
|
"button",
|
|
3897
3893
|
{
|
|
3898
3894
|
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",
|
|
3899
3895
|
disabled: !0,
|
|
3900
3896
|
type: "button",
|
|
3901
3897
|
"aria-label": "Scroll to bottom",
|
|
3902
|
-
children: /* @__PURE__ */
|
|
3898
|
+
children: /* @__PURE__ */ u("div", { className: "text-copy-light", children: /* @__PURE__ */ u(
|
|
3903
3899
|
"svg",
|
|
3904
3900
|
{
|
|
3905
3901
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -3909,7 +3905,7 @@ const ti = (e) => {
|
|
|
3909
3905
|
role: "img",
|
|
3910
3906
|
"aria-hidden": "true",
|
|
3911
3907
|
focusable: "false",
|
|
3912
|
-
children: /* @__PURE__ */
|
|
3908
|
+
children: /* @__PURE__ */ u("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" })
|
|
3913
3909
|
}
|
|
3914
3910
|
) })
|
|
3915
3911
|
}
|
|
@@ -3929,7 +3925,7 @@ try {
|
|
|
3929
3925
|
});
|
|
3930
3926
|
} catch {
|
|
3931
3927
|
}
|
|
3932
|
-
const
|
|
3928
|
+
const fi = "av-bubble", jr = "av-button", mt = "icon", $n = "button", Wt = "link", gi = ({
|
|
3933
3929
|
type: e,
|
|
3934
3930
|
size: t,
|
|
3935
3931
|
labelRight: r,
|
|
@@ -3938,14 +3934,14 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
3938
3934
|
}) => {
|
|
3939
3935
|
const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", i = "max-h-12 py-2 px-4";
|
|
3940
3936
|
switch (e) {
|
|
3941
|
-
case
|
|
3942
|
-
case
|
|
3937
|
+
case $n:
|
|
3938
|
+
case Wt:
|
|
3943
3939
|
return h({
|
|
3944
3940
|
[o]: t === "small",
|
|
3945
3941
|
[s]: t === "medium",
|
|
3946
3942
|
[i]: t === "large"
|
|
3947
3943
|
});
|
|
3948
|
-
case
|
|
3944
|
+
case mt:
|
|
3949
3945
|
return h("inline-flex items-center", {
|
|
3950
3946
|
"justify-center": a === "center",
|
|
3951
3947
|
"justify-start": a === "left",
|
|
@@ -3958,7 +3954,7 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
3958
3954
|
"h-12 px-4": t === "large" && (r || n)
|
|
3959
3955
|
});
|
|
3960
3956
|
}
|
|
3961
|
-
},
|
|
3957
|
+
}, hi = ({
|
|
3962
3958
|
type: e,
|
|
3963
3959
|
size: t,
|
|
3964
3960
|
labelRight: r,
|
|
@@ -3966,22 +3962,22 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
3966
3962
|
}) => {
|
|
3967
3963
|
const a = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
|
|
3968
3964
|
switch (e) {
|
|
3969
|
-
case
|
|
3970
|
-
case
|
|
3965
|
+
case $n:
|
|
3966
|
+
case Wt:
|
|
3971
3967
|
return h({
|
|
3972
|
-
"text-center": e ===
|
|
3968
|
+
"text-center": e === Wt,
|
|
3973
3969
|
[a]: t === "small",
|
|
3974
3970
|
[o]: t === "medium",
|
|
3975
3971
|
[s]: t === "large"
|
|
3976
3972
|
});
|
|
3977
|
-
case
|
|
3973
|
+
case mt:
|
|
3978
3974
|
return h({
|
|
3979
3975
|
[a]: t === "small" && (r || n),
|
|
3980
3976
|
[o]: t === "medium" && (r || n),
|
|
3981
3977
|
[s]: t === "large" && (r || n)
|
|
3982
3978
|
});
|
|
3983
3979
|
}
|
|
3984
|
-
},
|
|
3980
|
+
}, pi = ({
|
|
3985
3981
|
mode: e,
|
|
3986
3982
|
noBackground: t,
|
|
3987
3983
|
noTruncate: r,
|
|
@@ -4017,7 +4013,7 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4017
4013
|
return h("not-prose text-copy-lighter", {
|
|
4018
4014
|
truncate: !r
|
|
4019
4015
|
});
|
|
4020
|
-
},
|
|
4016
|
+
}, yi = ({
|
|
4021
4017
|
mode: e,
|
|
4022
4018
|
noBackground: t,
|
|
4023
4019
|
variant: r
|
|
@@ -4047,13 +4043,13 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4047
4043
|
if (r === "selected")
|
|
4048
4044
|
return "bg-action-selected-dark";
|
|
4049
4045
|
}
|
|
4050
|
-
},
|
|
4046
|
+
}, bi = ({
|
|
4051
4047
|
radius: e
|
|
4052
4048
|
}) => h({
|
|
4053
4049
|
"rounded-full": e === "large",
|
|
4054
4050
|
"rounded-md": e === "medium",
|
|
4055
4051
|
"rounded-sm": e === "small"
|
|
4056
|
-
}),
|
|
4052
|
+
}), vi = ({
|
|
4057
4053
|
mode: e,
|
|
4058
4054
|
disabled: t,
|
|
4059
4055
|
variant: r
|
|
@@ -4083,7 +4079,7 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4083
4079
|
});
|
|
4084
4080
|
if (r === "selected")
|
|
4085
4081
|
return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
|
|
4086
|
-
},
|
|
4082
|
+
}, ki = ({
|
|
4087
4083
|
mode: e,
|
|
4088
4084
|
disabled: t,
|
|
4089
4085
|
variant: r
|
|
@@ -4113,7 +4109,7 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4113
4109
|
});
|
|
4114
4110
|
if (r === "selected")
|
|
4115
4111
|
return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
|
|
4116
|
-
},
|
|
4112
|
+
}, xi = ({
|
|
4117
4113
|
mode: e,
|
|
4118
4114
|
noBorder: t,
|
|
4119
4115
|
variant: r
|
|
@@ -4143,14 +4139,14 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4143
4139
|
});
|
|
4144
4140
|
if (r === "selected")
|
|
4145
4141
|
return "border border-border-selected-dark";
|
|
4146
|
-
},
|
|
4142
|
+
}, wi = ({
|
|
4147
4143
|
focusMode: e
|
|
4148
4144
|
}) => h("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
|
|
4149
4145
|
"focus:outline-focus-dark": e === "dark",
|
|
4150
4146
|
"focus:outline-focus-light": e === "light",
|
|
4151
4147
|
"focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
|
|
4152
4148
|
"focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
|
|
4153
|
-
}),
|
|
4149
|
+
}), _i = ({
|
|
4154
4150
|
mode: e,
|
|
4155
4151
|
raw: t,
|
|
4156
4152
|
iconClassName: r
|
|
@@ -4162,7 +4158,7 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4162
4158
|
"dark:text-copy-accent-dark": e === "system"
|
|
4163
4159
|
},
|
|
4164
4160
|
r
|
|
4165
|
-
),
|
|
4161
|
+
), Dn = ({
|
|
4166
4162
|
type: e,
|
|
4167
4163
|
className: t,
|
|
4168
4164
|
raw: r,
|
|
@@ -4174,56 +4170,56 @@ const gi = "av-bubble", jr = "av-button", ut = "icon", Dn = "button", Ft = "link
|
|
|
4174
4170
|
noBorder: l,
|
|
4175
4171
|
labelRight: c,
|
|
4176
4172
|
labelLeft: g,
|
|
4177
|
-
noBackground:
|
|
4173
|
+
noBackground: d,
|
|
4178
4174
|
variant: f,
|
|
4179
4175
|
noTruncate: m,
|
|
4180
4176
|
align: p,
|
|
4181
4177
|
radius: y
|
|
4182
4178
|
}) => (f || (f = "primary"), r ? h(jr, t) : h(
|
|
4183
4179
|
jr,
|
|
4184
|
-
|
|
4180
|
+
pi({
|
|
4185
4181
|
mode: n,
|
|
4186
4182
|
variant: f,
|
|
4187
|
-
noBackground:
|
|
4183
|
+
noBackground: d,
|
|
4188
4184
|
noTruncate: m
|
|
4189
4185
|
}),
|
|
4190
|
-
|
|
4191
|
-
|
|
4192
|
-
|
|
4186
|
+
yi({ mode: n, noBackground: d, variant: f }),
|
|
4187
|
+
bi({ radius: y }),
|
|
4188
|
+
gi({
|
|
4193
4189
|
type: e,
|
|
4194
4190
|
size: i,
|
|
4195
4191
|
labelRight: c,
|
|
4196
4192
|
labelLeft: g,
|
|
4197
4193
|
align: p
|
|
4198
4194
|
}),
|
|
4199
|
-
|
|
4200
|
-
|
|
4201
|
-
|
|
4195
|
+
hi({ type: e, size: i, labelRight: c, labelLeft: g }),
|
|
4196
|
+
xi({ mode: n, variant: f, noBorder: l }),
|
|
4197
|
+
wi({ focusMode: a }),
|
|
4198
|
+
vi({ mode: n, variant: f, disabled: o }),
|
|
4202
4199
|
ki({ mode: n, variant: f, disabled: o }),
|
|
4203
|
-
xi({ mode: n, variant: f, disabled: o }),
|
|
4204
4200
|
{
|
|
4205
4201
|
"w-full": s,
|
|
4206
4202
|
"disabled:cursor-not-allowed disabled:opacity-50": o
|
|
4207
4203
|
},
|
|
4208
4204
|
t
|
|
4209
|
-
)),
|
|
4205
|
+
)), Ei = (e, t, r) => {
|
|
4210
4206
|
var n;
|
|
4211
4207
|
!t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((n = e == null ? void 0 : e.currentTarget) == null ? void 0 : n.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
|
|
4212
4208
|
}, sr = V.forwardRef((e, t) => {
|
|
4213
4209
|
const { onClick: r, noInternalClick: n = !1, ...a } = e;
|
|
4214
|
-
return /* @__PURE__ */
|
|
4210
|
+
return /* @__PURE__ */ u(
|
|
4215
4211
|
"button",
|
|
4216
4212
|
{
|
|
4217
4213
|
ref: t,
|
|
4218
4214
|
onClick: (o) => {
|
|
4219
|
-
|
|
4215
|
+
Ei(o, n, r);
|
|
4220
4216
|
},
|
|
4221
4217
|
...a
|
|
4222
4218
|
}
|
|
4223
4219
|
);
|
|
4224
4220
|
});
|
|
4225
4221
|
sr.displayName = "BaseButton";
|
|
4226
|
-
const
|
|
4222
|
+
const Pn = V.forwardRef(
|
|
4227
4223
|
({
|
|
4228
4224
|
children: e,
|
|
4229
4225
|
disabled: t = !1,
|
|
@@ -4236,7 +4232,7 @@ const Vn = V.forwardRef(
|
|
|
4236
4232
|
noBorder: l = !1,
|
|
4237
4233
|
"aria-label": c,
|
|
4238
4234
|
label: g,
|
|
4239
|
-
size:
|
|
4235
|
+
size: d = "medium",
|
|
4240
4236
|
labelRight: f,
|
|
4241
4237
|
labelLeft: m,
|
|
4242
4238
|
noBackground: p = !1,
|
|
@@ -4246,8 +4242,8 @@ const Vn = V.forwardRef(
|
|
|
4246
4242
|
iconClassName: k,
|
|
4247
4243
|
...w
|
|
4248
4244
|
}, _) => {
|
|
4249
|
-
const x =
|
|
4250
|
-
type:
|
|
4245
|
+
const x = Dn({
|
|
4246
|
+
type: mt,
|
|
4251
4247
|
mode: r,
|
|
4252
4248
|
focusMode: n,
|
|
4253
4249
|
fullWidth: a,
|
|
@@ -4255,14 +4251,14 @@ const Vn = V.forwardRef(
|
|
|
4255
4251
|
raw: i,
|
|
4256
4252
|
className: o,
|
|
4257
4253
|
noBorder: l,
|
|
4258
|
-
size:
|
|
4254
|
+
size: d,
|
|
4259
4255
|
labelRight: f,
|
|
4260
4256
|
labelLeft: m,
|
|
4261
4257
|
noBackground: p,
|
|
4262
4258
|
align: y,
|
|
4263
4259
|
radius: v,
|
|
4264
4260
|
variant: b
|
|
4265
|
-
}), E =
|
|
4261
|
+
}), E = _i({ mode: r, raw: i, iconClassName: k });
|
|
4266
4262
|
return /* @__PURE__ */ C(
|
|
4267
4263
|
sr,
|
|
4268
4264
|
{
|
|
@@ -4273,15 +4269,15 @@ const Vn = V.forwardRef(
|
|
|
4273
4269
|
"aria-label": c || g,
|
|
4274
4270
|
...w,
|
|
4275
4271
|
children: [
|
|
4276
|
-
m && /* @__PURE__ */
|
|
4277
|
-
/* @__PURE__ */
|
|
4278
|
-
f && /* @__PURE__ */
|
|
4272
|
+
m && /* @__PURE__ */ u("span", { className: "pr-2", children: m }),
|
|
4273
|
+
/* @__PURE__ */ u("div", { className: E, children: e }),
|
|
4274
|
+
f && /* @__PURE__ */ u("span", { className: "pl-2", children: f })
|
|
4279
4275
|
]
|
|
4280
4276
|
}
|
|
4281
4277
|
);
|
|
4282
4278
|
}
|
|
4283
4279
|
);
|
|
4284
|
-
|
|
4280
|
+
Pn.displayName = "ButtonIcon";
|
|
4285
4281
|
/*!
|
|
4286
4282
|
@versini/ui-button v4.1.4
|
|
4287
4283
|
© 2025 gizmette.com
|
|
@@ -4295,7 +4291,7 @@ try {
|
|
|
4295
4291
|
});
|
|
4296
4292
|
} catch {
|
|
4297
4293
|
}
|
|
4298
|
-
const
|
|
4294
|
+
const Ti = V.forwardRef(
|
|
4299
4295
|
({
|
|
4300
4296
|
children: e,
|
|
4301
4297
|
disabled: t = !1,
|
|
@@ -4308,7 +4304,7 @@ const Si = V.forwardRef(
|
|
|
4308
4304
|
noBorder: l = !1,
|
|
4309
4305
|
"aria-label": c,
|
|
4310
4306
|
label: g,
|
|
4311
|
-
size:
|
|
4307
|
+
size: d = "medium",
|
|
4312
4308
|
labelRight: f,
|
|
4313
4309
|
labelLeft: m,
|
|
4314
4310
|
noBackground: p = !1,
|
|
@@ -4317,8 +4313,8 @@ const Si = V.forwardRef(
|
|
|
4317
4313
|
radius: b = "large",
|
|
4318
4314
|
...k
|
|
4319
4315
|
}, w) => {
|
|
4320
|
-
const _ =
|
|
4321
|
-
type:
|
|
4316
|
+
const _ = Dn({
|
|
4317
|
+
type: mt,
|
|
4322
4318
|
mode: r,
|
|
4323
4319
|
focusMode: n,
|
|
4324
4320
|
fullWidth: a,
|
|
@@ -4326,7 +4322,7 @@ const Si = V.forwardRef(
|
|
|
4326
4322
|
raw: i,
|
|
4327
4323
|
className: o,
|
|
4328
4324
|
noBorder: l,
|
|
4329
|
-
size:
|
|
4325
|
+
size: d,
|
|
4330
4326
|
labelRight: f,
|
|
4331
4327
|
labelLeft: m,
|
|
4332
4328
|
noBackground: p,
|
|
@@ -4354,7 +4350,7 @@ const Si = V.forwardRef(
|
|
|
4354
4350
|
"after:border-table-light dark:after:border-table-dark": r === "alt-system"
|
|
4355
4351
|
}
|
|
4356
4352
|
) : "";
|
|
4357
|
-
return /* @__PURE__ */
|
|
4353
|
+
return /* @__PURE__ */ u("div", { className: E, children: /* @__PURE__ */ C(
|
|
4358
4354
|
sr,
|
|
4359
4355
|
{
|
|
4360
4356
|
ref: w,
|
|
@@ -4364,16 +4360,16 @@ const Si = V.forwardRef(
|
|
|
4364
4360
|
"aria-label": c || g,
|
|
4365
4361
|
...k,
|
|
4366
4362
|
children: [
|
|
4367
|
-
m && /* @__PURE__ */
|
|
4368
|
-
/* @__PURE__ */
|
|
4369
|
-
f && /* @__PURE__ */
|
|
4363
|
+
m && /* @__PURE__ */ u("span", { className: "pr-2", children: m }),
|
|
4364
|
+
/* @__PURE__ */ u("div", { className: x, children: e }),
|
|
4365
|
+
f && /* @__PURE__ */ u("span", { className: "pl-2", children: f })
|
|
4370
4366
|
]
|
|
4371
4367
|
}
|
|
4372
4368
|
) });
|
|
4373
4369
|
}
|
|
4374
4370
|
);
|
|
4375
|
-
|
|
4376
|
-
const
|
|
4371
|
+
Ti.displayName = "ButtonSort";
|
|
4372
|
+
const Vn = ({
|
|
4377
4373
|
children: e,
|
|
4378
4374
|
fill: t,
|
|
4379
4375
|
viewBox: r,
|
|
@@ -4386,7 +4382,7 @@ const zn = ({
|
|
|
4386
4382
|
}) => {
|
|
4387
4383
|
const c = h(o, n);
|
|
4388
4384
|
return /* @__PURE__ */ C(Qe, { children: [
|
|
4389
|
-
/* @__PURE__ */
|
|
4385
|
+
/* @__PURE__ */ u(
|
|
4390
4386
|
"svg",
|
|
4391
4387
|
{
|
|
4392
4388
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -4400,7 +4396,7 @@ const zn = ({
|
|
|
4400
4396
|
children: e
|
|
4401
4397
|
}
|
|
4402
4398
|
),
|
|
4403
|
-
s && i && /* @__PURE__ */
|
|
4399
|
+
s && i && /* @__PURE__ */ u("span", { className: "sr-only", children: s })
|
|
4404
4400
|
] });
|
|
4405
4401
|
};
|
|
4406
4402
|
/*!
|
|
@@ -4416,14 +4412,14 @@ try {
|
|
|
4416
4412
|
});
|
|
4417
4413
|
} catch {
|
|
4418
4414
|
}
|
|
4419
|
-
const
|
|
4415
|
+
const Si = ({
|
|
4420
4416
|
className: e,
|
|
4421
4417
|
viewBox: t,
|
|
4422
4418
|
title: r,
|
|
4423
4419
|
monotone: n,
|
|
4424
4420
|
...a
|
|
4425
4421
|
}) => /* @__PURE__ */ C(
|
|
4426
|
-
|
|
4422
|
+
Vn,
|
|
4427
4423
|
{
|
|
4428
4424
|
defaultViewBox: "0 0 448 512",
|
|
4429
4425
|
size: "size-5",
|
|
@@ -4432,24 +4428,24 @@ const Ni = ({
|
|
|
4432
4428
|
title: r || "Copied",
|
|
4433
4429
|
...a,
|
|
4434
4430
|
children: [
|
|
4435
|
-
/* @__PURE__ */
|
|
4431
|
+
/* @__PURE__ */ u(
|
|
4436
4432
|
"path",
|
|
4437
4433
|
{
|
|
4438
4434
|
d: "M0 96v320c0 35.3 28.7 64 64 64h320c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64C28.7 32 0 60.7 0 96m104 160c0-6.1 2.3-12.3 7-17 9.4-9.4 24.6-9.4 33.9 0l47 47 111-111c4.7-4.7 10.8-7 17-7s12.3 2.3 17 7c2.3 2.3 4.1 5 5.3 7.9.6 1.5 1 2.9 1.3 4.4.2 1.1.3 2.2.3 2.2.1 1.2.1 1.2.1 2.5-.1 1.5-.1 1.9-.1 2.3-.1.7-.2 1.5-.3 2.2-.3 1.5-.7 3-1.3 4.4-1.2 2.9-2.9 5.6-5.3 7.9l-128 128c-4.7 4.7-10.8 7-17 7s-12.3-2.3-17-7l-64-64c-4.7-4.7-7-10.8-7-17z",
|
|
4439
4435
|
opacity: ".4"
|
|
4440
4436
|
}
|
|
4441
4437
|
),
|
|
4442
|
-
/* @__PURE__ */
|
|
4438
|
+
/* @__PURE__ */ u("path", { d: "M337 175c9.4 9.4 9.4 24.6 0 33.9L209 337c-9.4 9.4-24.6 9.4-33.9 0l-64-64c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0l47 47L303 175c9.4-9.4 24.6-9.4 33.9 0z" })
|
|
4443
4439
|
]
|
|
4444
4440
|
}
|
|
4445
|
-
),
|
|
4441
|
+
), Ni = ({
|
|
4446
4442
|
className: e,
|
|
4447
4443
|
viewBox: t,
|
|
4448
4444
|
title: r,
|
|
4449
4445
|
monotone: n,
|
|
4450
4446
|
...a
|
|
4451
|
-
}) => /* @__PURE__ */
|
|
4452
|
-
|
|
4447
|
+
}) => /* @__PURE__ */ u(
|
|
4448
|
+
Vn,
|
|
4453
4449
|
{
|
|
4454
4450
|
defaultViewBox: "0 0 512 512",
|
|
4455
4451
|
size: "size-5",
|
|
@@ -4457,7 +4453,7 @@ const Ni = ({
|
|
|
4457
4453
|
className: e,
|
|
4458
4454
|
title: r || "Copy",
|
|
4459
4455
|
...a,
|
|
4460
|
-
children: /* @__PURE__ */
|
|
4456
|
+
children: /* @__PURE__ */ u("path", { d: "M64 464h224c8.8 0 16-7.2 16-16v-64h48v64c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64V224c0-35.3 28.7-64 64-64h64v48H64c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16m160-160h224c8.8 0 16-7.2 16-16V64c0-8.8-7.2-16-16-16H224c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16m-64-16V64c0-35.3 28.7-64 64-64h224c35.3 0 64 28.7 64 64v224c0 35.3-28.7 64-64 64H224c-35.3 0-64-28.7-64-64" })
|
|
4461
4457
|
}
|
|
4462
4458
|
);
|
|
4463
4459
|
/*!
|
|
@@ -4473,30 +4469,30 @@ try {
|
|
|
4473
4469
|
});
|
|
4474
4470
|
} catch {
|
|
4475
4471
|
}
|
|
4476
|
-
const
|
|
4472
|
+
const Ci = ({
|
|
4477
4473
|
kind: e,
|
|
4478
4474
|
noMaxWidth: t
|
|
4479
4475
|
}) => h("p-4", {
|
|
4480
4476
|
"max-w-xs sm:max-w-md md:max-w-2xl": !t,
|
|
4481
4477
|
"lg:max-w-3xl": e === "left" && !t
|
|
4482
|
-
}),
|
|
4478
|
+
}), Ri = ({ kind: e }) => h({
|
|
4483
4479
|
"bg-surface-lighter dark:bg-surface-dark": e === "left",
|
|
4484
4480
|
"bg-surface-accent": e === "right"
|
|
4485
|
-
}),
|
|
4481
|
+
}), Ii = ({ kind: e }) => h(
|
|
4486
4482
|
"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",
|
|
4487
4483
|
{
|
|
4488
4484
|
"text-copy-lighter": e === "right"
|
|
4489
4485
|
}
|
|
4490
|
-
),
|
|
4486
|
+
), Li = ({ kind: e }) => h("rounded-b-xl", {
|
|
4491
4487
|
"rounded-tr-xl": e === "left",
|
|
4492
4488
|
"rounded-tl-xl": e === "right"
|
|
4493
|
-
}),
|
|
4489
|
+
}), Oi = ({
|
|
4494
4490
|
kind: e,
|
|
4495
4491
|
className: t,
|
|
4496
4492
|
noMaxWidth: r
|
|
4497
4493
|
}) => {
|
|
4498
4494
|
const n = h(
|
|
4499
|
-
|
|
4495
|
+
fi,
|
|
4500
4496
|
"flex items-start",
|
|
4501
4497
|
{
|
|
4502
4498
|
"flex-row-reverse": e === "right"
|
|
@@ -4504,10 +4500,10 @@ const Ri = ({
|
|
|
4504
4500
|
t
|
|
4505
4501
|
), a = h(
|
|
4506
4502
|
"flex flex-col empty:hidden",
|
|
4507
|
-
|
|
4508
|
-
Li({ kind: e }),
|
|
4503
|
+
Ci({ kind: e, noMaxWidth: r }),
|
|
4509
4504
|
Ii({ kind: e }),
|
|
4510
|
-
|
|
4505
|
+
Ri({ kind: e }),
|
|
4506
|
+
Li({ kind: e })
|
|
4511
4507
|
), o = "pr-2 pt-1 text-end text-xs text-copy-light", s = h("flex flex-col-reverse gap-2 sm:flex-row", {
|
|
4512
4508
|
"ml-2": e === "left",
|
|
4513
4509
|
"mr-2": e === "right"
|
|
@@ -4518,7 +4514,7 @@ const Ri = ({
|
|
|
4518
4514
|
footer: o,
|
|
4519
4515
|
copyButton: s
|
|
4520
4516
|
};
|
|
4521
|
-
},
|
|
4517
|
+
}, Ai = ({
|
|
4522
4518
|
children: e,
|
|
4523
4519
|
kind: t = "left",
|
|
4524
4520
|
className: r,
|
|
@@ -4529,28 +4525,28 @@ const Ri = ({
|
|
|
4529
4525
|
copyToClipboardMode: i = "system",
|
|
4530
4526
|
noMaxWidth: l = !1
|
|
4531
4527
|
}) => {
|
|
4532
|
-
const [c, g] = Z(!1),
|
|
4528
|
+
const [c, g] = Z(!1), d = Oi({ kind: t, className: r, noMaxWidth: l }), f = !!o && (typeof o == "function" || typeof o == "string" || typeof e == "string"), m = () => {
|
|
4533
4529
|
g(!0), typeof o == "function" ? o(e) : typeof o == "string" ? navigator.clipboard.writeText(o) : typeof e == "string" && navigator.clipboard.writeText(e);
|
|
4534
4530
|
};
|
|
4535
|
-
return
|
|
4531
|
+
return D(() => {
|
|
4536
4532
|
let p;
|
|
4537
4533
|
return c && (p = window.setTimeout(() => {
|
|
4538
4534
|
g(!1);
|
|
4539
4535
|
}, 3e3)), () => {
|
|
4540
4536
|
clearTimeout(p);
|
|
4541
4537
|
};
|
|
4542
|
-
}, [c]), /* @__PURE__ */ C("div", { className:
|
|
4538
|
+
}, [c]), /* @__PURE__ */ C("div", { className: d.wrapper, children: [
|
|
4543
4539
|
/* @__PURE__ */ C("div", { children: [
|
|
4544
|
-
/* @__PURE__ */
|
|
4545
|
-
n && Object.keys(n).map((p) => n[p] ? /* @__PURE__ */
|
|
4540
|
+
/* @__PURE__ */ u("div", { className: d.main, children: e }),
|
|
4541
|
+
n && Object.keys(n).map((p) => n[p] ? /* @__PURE__ */ u("div", { className: "prose-p:m-0", children: /* @__PURE__ */ C("p", { className: d.footer, children: [
|
|
4546
4542
|
p,
|
|
4547
4543
|
": ",
|
|
4548
4544
|
n[p]
|
|
4549
4545
|
] }) }, `-${p}`) : null),
|
|
4550
4546
|
a && a
|
|
4551
4547
|
] }),
|
|
4552
|
-
f && /* @__PURE__ */
|
|
4553
|
-
|
|
4548
|
+
f && /* @__PURE__ */ u("div", { className: d.copyButton, children: /* @__PURE__ */ u(
|
|
4549
|
+
Pn,
|
|
4554
4550
|
{
|
|
4555
4551
|
noBorder: !0,
|
|
4556
4552
|
noBackground: !0,
|
|
@@ -4560,11 +4556,11 @@ const Ri = ({
|
|
|
4560
4556
|
label: c ? "Copied to clipboard" : "Copy to clipboard",
|
|
4561
4557
|
onClick: m,
|
|
4562
4558
|
disabled: c,
|
|
4563
|
-
children: c ? /* @__PURE__ */
|
|
4559
|
+
children: c ? /* @__PURE__ */ u(Si, { size: "size-3" }) : /* @__PURE__ */ u(Ni, { size: "size-3" })
|
|
4564
4560
|
}
|
|
4565
4561
|
) })
|
|
4566
4562
|
] });
|
|
4567
|
-
}, qr = "av-button", ir = "icon", lr = "button",
|
|
4563
|
+
}, qr = "av-button", ir = "icon", lr = "button", Gt = "link", Bi = ({
|
|
4568
4564
|
type: e,
|
|
4569
4565
|
size: t,
|
|
4570
4566
|
labelRight: r,
|
|
@@ -4574,7 +4570,7 @@ const Ri = ({
|
|
|
4574
4570
|
const o = "max-h-8 py-0 px-2", s = "max-h-9 h-8 px-3", i = "max-h-12 py-2 px-4";
|
|
4575
4571
|
switch (e) {
|
|
4576
4572
|
case lr:
|
|
4577
|
-
case
|
|
4573
|
+
case Gt:
|
|
4578
4574
|
return h({
|
|
4579
4575
|
[o]: t === "small",
|
|
4580
4576
|
[s]: t === "medium",
|
|
@@ -4593,7 +4589,7 @@ const Ri = ({
|
|
|
4593
4589
|
"h-12 px-4": t === "large" && (r || n)
|
|
4594
4590
|
});
|
|
4595
4591
|
}
|
|
4596
|
-
},
|
|
4592
|
+
}, Mi = ({
|
|
4597
4593
|
type: e,
|
|
4598
4594
|
size: t,
|
|
4599
4595
|
labelRight: r,
|
|
@@ -4602,9 +4598,9 @@ const Ri = ({
|
|
|
4602
4598
|
const a = "text-sm font-medium", o = "text-base font-medium", s = "text-lg font-medium";
|
|
4603
4599
|
switch (e) {
|
|
4604
4600
|
case lr:
|
|
4605
|
-
case
|
|
4601
|
+
case Gt:
|
|
4606
4602
|
return h({
|
|
4607
|
-
"text-center": e ===
|
|
4603
|
+
"text-center": e === Gt,
|
|
4608
4604
|
[a]: t === "small",
|
|
4609
4605
|
[o]: t === "medium",
|
|
4610
4606
|
[s]: t === "large"
|
|
@@ -4616,7 +4612,7 @@ const Ri = ({
|
|
|
4616
4612
|
[s]: t === "large" && (r || n)
|
|
4617
4613
|
});
|
|
4618
4614
|
}
|
|
4619
|
-
},
|
|
4615
|
+
}, $i = ({
|
|
4620
4616
|
mode: e,
|
|
4621
4617
|
noBackground: t,
|
|
4622
4618
|
noTruncate: r,
|
|
@@ -4652,7 +4648,7 @@ const Ri = ({
|
|
|
4652
4648
|
return h("not-prose text-copy-lighter", {
|
|
4653
4649
|
truncate: !r
|
|
4654
4650
|
});
|
|
4655
|
-
},
|
|
4651
|
+
}, Di = ({
|
|
4656
4652
|
mode: e,
|
|
4657
4653
|
noBackground: t,
|
|
4658
4654
|
variant: r
|
|
@@ -4682,13 +4678,13 @@ const Ri = ({
|
|
|
4682
4678
|
if (r === "selected")
|
|
4683
4679
|
return "bg-action-selected-dark";
|
|
4684
4680
|
}
|
|
4685
|
-
},
|
|
4681
|
+
}, Pi = ({
|
|
4686
4682
|
radius: e
|
|
4687
4683
|
}) => h({
|
|
4688
4684
|
"rounded-full": e === "large",
|
|
4689
4685
|
"rounded-md": e === "medium",
|
|
4690
4686
|
"rounded-sm": e === "small"
|
|
4691
|
-
}),
|
|
4687
|
+
}), Vi = ({
|
|
4692
4688
|
mode: e,
|
|
4693
4689
|
disabled: t,
|
|
4694
4690
|
variant: r
|
|
@@ -4718,7 +4714,7 @@ const Ri = ({
|
|
|
4718
4714
|
});
|
|
4719
4715
|
if (r === "selected")
|
|
4720
4716
|
return "hover:text-copy-light-hover hover:bg-action-selected-dark-hover";
|
|
4721
|
-
},
|
|
4717
|
+
}, zi = ({
|
|
4722
4718
|
mode: e,
|
|
4723
4719
|
disabled: t,
|
|
4724
4720
|
variant: r
|
|
@@ -4748,7 +4744,7 @@ const Ri = ({
|
|
|
4748
4744
|
});
|
|
4749
4745
|
if (r === "selected")
|
|
4750
4746
|
return "active:text-copy-lighter-active active:bg-action-selected-dark-active";
|
|
4751
|
-
},
|
|
4747
|
+
}, Ui = ({
|
|
4752
4748
|
mode: e,
|
|
4753
4749
|
noBorder: t,
|
|
4754
4750
|
variant: r
|
|
@@ -4778,14 +4774,14 @@ const Ri = ({
|
|
|
4778
4774
|
});
|
|
4779
4775
|
if (r === "selected")
|
|
4780
4776
|
return "border border-border-selected-dark";
|
|
4781
|
-
},
|
|
4777
|
+
}, Hi = ({
|
|
4782
4778
|
focusMode: e
|
|
4783
4779
|
}) => h("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
|
|
4784
4780
|
"focus:outline-focus-dark": e === "dark",
|
|
4785
4781
|
"focus:outline-focus-light": e === "light",
|
|
4786
4782
|
"focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
|
|
4787
4783
|
"focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
|
|
4788
|
-
}),
|
|
4784
|
+
}), zn = ({
|
|
4789
4785
|
type: e,
|
|
4790
4786
|
className: t,
|
|
4791
4787
|
raw: r,
|
|
@@ -4797,56 +4793,56 @@ const Ri = ({
|
|
|
4797
4793
|
noBorder: l,
|
|
4798
4794
|
labelRight: c,
|
|
4799
4795
|
labelLeft: g,
|
|
4800
|
-
noBackground:
|
|
4796
|
+
noBackground: d,
|
|
4801
4797
|
variant: f,
|
|
4802
4798
|
noTruncate: m,
|
|
4803
4799
|
align: p,
|
|
4804
4800
|
radius: y
|
|
4805
4801
|
}) => (f || (f = "primary"), r ? h(qr, t) : h(
|
|
4806
4802
|
qr,
|
|
4807
|
-
|
|
4803
|
+
$i({
|
|
4808
4804
|
mode: n,
|
|
4809
4805
|
variant: f,
|
|
4810
|
-
noBackground:
|
|
4806
|
+
noBackground: d,
|
|
4811
4807
|
noTruncate: m
|
|
4812
4808
|
}),
|
|
4813
|
-
|
|
4814
|
-
|
|
4815
|
-
|
|
4809
|
+
Di({ mode: n, noBackground: d, variant: f }),
|
|
4810
|
+
Pi({ radius: y }),
|
|
4811
|
+
Bi({
|
|
4816
4812
|
type: e,
|
|
4817
4813
|
size: i,
|
|
4818
4814
|
labelRight: c,
|
|
4819
4815
|
labelLeft: g,
|
|
4820
4816
|
align: p
|
|
4821
4817
|
}),
|
|
4822
|
-
|
|
4823
|
-
|
|
4824
|
-
|
|
4818
|
+
Mi({ type: e, size: i, labelRight: c, labelLeft: g }),
|
|
4819
|
+
Ui({ mode: n, variant: f, noBorder: l }),
|
|
4820
|
+
Hi({ focusMode: a }),
|
|
4821
|
+
Vi({ mode: n, variant: f, disabled: o }),
|
|
4825
4822
|
zi({ mode: n, variant: f, disabled: o }),
|
|
4826
|
-
Ui({ mode: n, variant: f, disabled: o }),
|
|
4827
4823
|
{
|
|
4828
4824
|
"w-full": s,
|
|
4829
4825
|
"disabled:cursor-not-allowed disabled:opacity-50": o
|
|
4830
4826
|
},
|
|
4831
4827
|
t
|
|
4832
|
-
)),
|
|
4828
|
+
)), Fi = (e, t, r) => {
|
|
4833
4829
|
var n;
|
|
4834
4830
|
!t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((n = e == null ? void 0 : e.currentTarget) == null ? void 0 : n.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
|
|
4835
4831
|
}, cr = V.forwardRef((e, t) => {
|
|
4836
4832
|
const { onClick: r, noInternalClick: n = !1, ...a } = e;
|
|
4837
|
-
return /* @__PURE__ */
|
|
4833
|
+
return /* @__PURE__ */ u(
|
|
4838
4834
|
"button",
|
|
4839
4835
|
{
|
|
4840
4836
|
ref: t,
|
|
4841
4837
|
onClick: (o) => {
|
|
4842
|
-
|
|
4838
|
+
Fi(o, n, r);
|
|
4843
4839
|
},
|
|
4844
4840
|
...a
|
|
4845
4841
|
}
|
|
4846
4842
|
);
|
|
4847
4843
|
});
|
|
4848
4844
|
cr.displayName = "BaseButton";
|
|
4849
|
-
const
|
|
4845
|
+
const Un = V.forwardRef(
|
|
4850
4846
|
({
|
|
4851
4847
|
children: e,
|
|
4852
4848
|
disabled: t = !1,
|
|
@@ -4859,10 +4855,10 @@ const Hn = V.forwardRef(
|
|
|
4859
4855
|
noBorder: l = !1,
|
|
4860
4856
|
variant: c = "primary",
|
|
4861
4857
|
noTruncate: g = !1,
|
|
4862
|
-
radius:
|
|
4858
|
+
radius: d = "large",
|
|
4863
4859
|
...f
|
|
4864
4860
|
}, m) => {
|
|
4865
|
-
const p =
|
|
4861
|
+
const p = zn({
|
|
4866
4862
|
type: lr,
|
|
4867
4863
|
mode: r,
|
|
4868
4864
|
focusMode: n,
|
|
@@ -4874,9 +4870,9 @@ const Hn = V.forwardRef(
|
|
|
4874
4870
|
noBorder: l,
|
|
4875
4871
|
variant: c,
|
|
4876
4872
|
noTruncate: g,
|
|
4877
|
-
radius:
|
|
4873
|
+
radius: d
|
|
4878
4874
|
});
|
|
4879
|
-
return /* @__PURE__ */
|
|
4875
|
+
return /* @__PURE__ */ u(
|
|
4880
4876
|
cr,
|
|
4881
4877
|
{
|
|
4882
4878
|
ref: m,
|
|
@@ -4888,7 +4884,7 @@ const Hn = V.forwardRef(
|
|
|
4888
4884
|
);
|
|
4889
4885
|
}
|
|
4890
4886
|
);
|
|
4891
|
-
|
|
4887
|
+
Un.displayName = "Button";
|
|
4892
4888
|
/*!
|
|
4893
4889
|
@versini/ui-button v4.1.4
|
|
4894
4890
|
© 2025 gizmette.com
|
|
@@ -4902,7 +4898,7 @@ try {
|
|
|
4902
4898
|
});
|
|
4903
4899
|
} catch {
|
|
4904
4900
|
}
|
|
4905
|
-
const
|
|
4901
|
+
const Wi = V.forwardRef(
|
|
4906
4902
|
({
|
|
4907
4903
|
children: e,
|
|
4908
4904
|
disabled: t = !1,
|
|
@@ -4915,7 +4911,7 @@ const Gi = V.forwardRef(
|
|
|
4915
4911
|
noBorder: l = !1,
|
|
4916
4912
|
"aria-label": c,
|
|
4917
4913
|
label: g,
|
|
4918
|
-
size:
|
|
4914
|
+
size: d = "medium",
|
|
4919
4915
|
labelRight: f,
|
|
4920
4916
|
labelLeft: m,
|
|
4921
4917
|
noBackground: p = !1,
|
|
@@ -4924,7 +4920,7 @@ const Gi = V.forwardRef(
|
|
|
4924
4920
|
radius: b = "large",
|
|
4925
4921
|
...k
|
|
4926
4922
|
}, w) => {
|
|
4927
|
-
const _ =
|
|
4923
|
+
const _ = zn({
|
|
4928
4924
|
type: ir,
|
|
4929
4925
|
mode: r,
|
|
4930
4926
|
focusMode: n,
|
|
@@ -4933,7 +4929,7 @@ const Gi = V.forwardRef(
|
|
|
4933
4929
|
raw: i,
|
|
4934
4930
|
className: o,
|
|
4935
4931
|
noBorder: l,
|
|
4936
|
-
size:
|
|
4932
|
+
size: d,
|
|
4937
4933
|
labelRight: f,
|
|
4938
4934
|
labelLeft: m,
|
|
4939
4935
|
noBackground: p,
|
|
@@ -4961,7 +4957,7 @@ const Gi = V.forwardRef(
|
|
|
4961
4957
|
"after:border-table-light dark:after:border-table-dark": r === "alt-system"
|
|
4962
4958
|
}
|
|
4963
4959
|
) : "";
|
|
4964
|
-
return /* @__PURE__ */
|
|
4960
|
+
return /* @__PURE__ */ u("div", { className: E, children: /* @__PURE__ */ C(
|
|
4965
4961
|
cr,
|
|
4966
4962
|
{
|
|
4967
4963
|
ref: w,
|
|
@@ -4971,18 +4967,18 @@ const Gi = V.forwardRef(
|
|
|
4971
4967
|
"aria-label": c || g,
|
|
4972
4968
|
...k,
|
|
4973
4969
|
children: [
|
|
4974
|
-
m && /* @__PURE__ */
|
|
4975
|
-
/* @__PURE__ */
|
|
4976
|
-
f && /* @__PURE__ */
|
|
4970
|
+
m && /* @__PURE__ */ u("span", { className: "pr-2", children: m }),
|
|
4971
|
+
/* @__PURE__ */ u("div", { className: x, children: e }),
|
|
4972
|
+
f && /* @__PURE__ */ u("span", { className: "pl-2", children: f })
|
|
4977
4973
|
]
|
|
4978
4974
|
}
|
|
4979
4975
|
) });
|
|
4980
4976
|
}
|
|
4981
4977
|
);
|
|
4982
|
-
|
|
4983
|
-
const
|
|
4978
|
+
Wi.displayName = "ButtonSort";
|
|
4979
|
+
const Gi = 200, ji = ({
|
|
4984
4980
|
string: e,
|
|
4985
|
-
idealLength: t =
|
|
4981
|
+
idealLength: t = Gi
|
|
4986
4982
|
}) => {
|
|
4987
4983
|
if (e.length <= t)
|
|
4988
4984
|
return { string: e, isTruncated: !1 };
|
|
@@ -4993,7 +4989,7 @@ const ji = 200, qi = ({
|
|
|
4993
4989
|
string: e.slice(0, t + r),
|
|
4994
4990
|
isTruncated: !0
|
|
4995
4991
|
};
|
|
4996
|
-
},
|
|
4992
|
+
}, qi = ({
|
|
4997
4993
|
children: e,
|
|
4998
4994
|
length: t = 200,
|
|
4999
4995
|
mode: r = "system",
|
|
@@ -5002,14 +4998,14 @@ const ji = 200, qi = ({
|
|
|
5002
4998
|
const [a, o] = Z(!1);
|
|
5003
4999
|
if (typeof e != "string")
|
|
5004
5000
|
return e;
|
|
5005
|
-
const { string: s, isTruncated: i } =
|
|
5001
|
+
const { string: s, isTruncated: i } = ji({
|
|
5006
5002
|
string: e,
|
|
5007
5003
|
idealLength: t
|
|
5008
5004
|
});
|
|
5009
5005
|
return /* @__PURE__ */ C("span", { style: { wordBreak: "break-word" }, children: [
|
|
5010
5006
|
a ? e : s,
|
|
5011
|
-
i && /* @__PURE__ */
|
|
5012
|
-
|
|
5007
|
+
i && /* @__PURE__ */ u(
|
|
5008
|
+
Un,
|
|
5013
5009
|
{
|
|
5014
5010
|
mode: r,
|
|
5015
5011
|
focusMode: n,
|
|
@@ -5039,69 +5035,69 @@ try {
|
|
|
5039
5035
|
const Kr = tn(
|
|
5040
5036
|
() => import(
|
|
5041
5037
|
/* webpackChunkName: "LazyMessageAssistant" */
|
|
5042
|
-
"./MessageAssistant.
|
|
5038
|
+
"./MessageAssistant.DgkzykE1.js"
|
|
5043
5039
|
).then((e) => e.MessageAssistant)
|
|
5044
|
-
),
|
|
5040
|
+
), Ki = () => {
|
|
5045
5041
|
const { state: e } = W(pe);
|
|
5046
5042
|
return /* @__PURE__ */ C("div", { className: "space-y-6 mt-2 @container", children: [
|
|
5047
5043
|
e && e.messages.length > 0 && e.messages.map((t, r) => {
|
|
5048
5044
|
const { role: n, content: a, name: o, processingTime: s } = t.message;
|
|
5049
|
-
return (n ===
|
|
5050
|
-
|
|
5045
|
+
return (n === Be || n === jt) && a ? /* @__PURE__ */ u(It, { fallback: /* @__PURE__ */ u("span", {}), children: /* @__PURE__ */ u(Kr, { name: o, processingTime: s, children: a }) }, `${r}-${n}`) : n === Ct && a ? /* @__PURE__ */ u(
|
|
5046
|
+
Ai,
|
|
5051
5047
|
{
|
|
5052
5048
|
kind: "right",
|
|
5053
5049
|
copyToClipboard: a,
|
|
5054
5050
|
copyToClipboardFocusMode: "light",
|
|
5055
|
-
children: /* @__PURE__ */
|
|
5051
|
+
children: /* @__PURE__ */ u(qi, { mode: "light", focusMode: "light", children: a })
|
|
5056
5052
|
},
|
|
5057
5053
|
`${r}-${n}`
|
|
5058
5054
|
) : null;
|
|
5059
5055
|
}),
|
|
5060
|
-
|
|
5056
|
+
ra(Ct, e) && /* @__PURE__ */ u(It, { fallback: /* @__PURE__ */ u("span", {}), children: /* @__PURE__ */ u(Kr, { loading: !0 }) })
|
|
5061
5057
|
] });
|
|
5062
|
-
},
|
|
5063
|
-
const { isAuthenticated: e } = Pe(), { ref: t, inViewport: r } =
|
|
5058
|
+
}, Yi = () => {
|
|
5059
|
+
const { isAuthenticated: e } = Pe(), { ref: t, inViewport: r } = za(), n = na({
|
|
5064
5060
|
isAuthenticated: e,
|
|
5065
5061
|
extraClass: "rounded-b-md"
|
|
5066
5062
|
});
|
|
5067
5063
|
return /* @__PURE__ */ C(Qe, { children: [
|
|
5068
5064
|
/* @__PURE__ */ C("div", { className: n, children: [
|
|
5069
|
-
/* @__PURE__ */
|
|
5070
|
-
/* @__PURE__ */
|
|
5071
|
-
/* @__PURE__ */
|
|
5065
|
+
/* @__PURE__ */ u(aa, {}),
|
|
5066
|
+
/* @__PURE__ */ u(Ki, {}),
|
|
5067
|
+
/* @__PURE__ */ u("div", { ref: t })
|
|
5072
5068
|
] }),
|
|
5073
|
-
/* @__PURE__ */
|
|
5069
|
+
/* @__PURE__ */ u(mi, { show: !r })
|
|
5074
5070
|
] });
|
|
5075
|
-
},
|
|
5071
|
+
}, Ji = tn(
|
|
5076
5072
|
() => import(
|
|
5077
5073
|
/* webpackChunkName: "LazyHeader" */
|
|
5078
|
-
"./HeaderToolbar.
|
|
5074
|
+
"./HeaderToolbar.BkfChFW9.js"
|
|
5079
5075
|
)
|
|
5080
5076
|
);
|
|
5081
|
-
function
|
|
5077
|
+
function Hn({ isComponent: e = !1 }) {
|
|
5082
5078
|
const { user: t, getAccessToken: r } = Pe(), [n] = Sr({
|
|
5083
|
-
key: xr +
|
|
5079
|
+
key: xr + sa,
|
|
5084
5080
|
initialValue: ""
|
|
5085
5081
|
}), [a] = Sr({
|
|
5086
|
-
key: xr +
|
|
5087
|
-
initialValue:
|
|
5088
|
-
}), [o, s] =
|
|
5082
|
+
key: xr + ia,
|
|
5083
|
+
initialValue: Oe.ASC
|
|
5084
|
+
}), [o, s] = yt(bo, {
|
|
5089
5085
|
id: Jt(),
|
|
5090
|
-
model:
|
|
5091
|
-
engine:
|
|
5086
|
+
model: we,
|
|
5087
|
+
engine: we,
|
|
5092
5088
|
usage: 0,
|
|
5093
5089
|
messages: [],
|
|
5094
5090
|
prompts: [],
|
|
5095
5091
|
isComponent: e
|
|
5096
|
-
}), [i, l] =
|
|
5092
|
+
}), [i, l] = yt(vo, {
|
|
5097
5093
|
searchString: n,
|
|
5098
5094
|
sortedCell: "timestamp",
|
|
5099
5095
|
sortDirection: a
|
|
5100
|
-
}), [c, g] =
|
|
5096
|
+
}), [c, g] = yt(ko, {
|
|
5101
5097
|
prompt: "",
|
|
5102
5098
|
lastTriggeredTimestamp: 0
|
|
5103
5099
|
});
|
|
5104
|
-
|
|
5100
|
+
as({
|
|
5105
5101
|
keys: [
|
|
5106
5102
|
t == null ? void 0 : t.username,
|
|
5107
5103
|
i.searchString,
|
|
@@ -5109,26 +5105,38 @@ function Fn({ isComponent: e = !1 }) {
|
|
|
5109
5105
|
0
|
|
5110
5106
|
],
|
|
5111
5107
|
getAccessToken: r
|
|
5112
|
-
}),
|
|
5113
|
-
|
|
5114
|
-
|
|
5115
|
-
|
|
5116
|
-
|
|
5108
|
+
}), os({ getAccessToken: r });
|
|
5109
|
+
const { data: d } = Qt({
|
|
5110
|
+
keys: [t == null ? void 0 : t.username],
|
|
5111
|
+
getAccessToken: r
|
|
5112
|
+
});
|
|
5113
|
+
return D(() => {
|
|
5114
|
+
var m;
|
|
5115
|
+
(m = document.getElementById("logo")) == null || m.classList.add("fadeOut"), setTimeout(() => {
|
|
5116
|
+
var p;
|
|
5117
|
+
(p = document.getElementById("root")) == null || p.classList.replace("app-hidden", "fadeIn");
|
|
5117
5118
|
}, 500);
|
|
5118
|
-
}),
|
|
5119
|
-
|
|
5119
|
+
}), D(() => {
|
|
5120
|
+
d && s({
|
|
5121
|
+
type: et,
|
|
5122
|
+
payload: {
|
|
5123
|
+
engine: d.engine || we
|
|
5124
|
+
}
|
|
5125
|
+
});
|
|
5126
|
+
}, [d]), /* @__PURE__ */ u(pe.Provider, { value: { state: o, dispatch: s }, children: /* @__PURE__ */ u(
|
|
5127
|
+
ls.Provider,
|
|
5120
5128
|
{
|
|
5121
5129
|
value: {
|
|
5122
5130
|
state: i,
|
|
5123
5131
|
dispatch: l
|
|
5124
5132
|
},
|
|
5125
5133
|
children: /* @__PURE__ */ C(
|
|
5126
|
-
|
|
5134
|
+
it.Provider,
|
|
5127
5135
|
{
|
|
5128
5136
|
value: { state: c, dispatch: g },
|
|
5129
5137
|
children: [
|
|
5130
|
-
/* @__PURE__ */
|
|
5131
|
-
|
|
5138
|
+
/* @__PURE__ */ u(
|
|
5139
|
+
Ma,
|
|
5132
5140
|
{
|
|
5133
5141
|
noColors: !0,
|
|
5134
5142
|
noMargin: !0,
|
|
@@ -5137,55 +5145,55 @@ function Fn({ isComponent: e = !1 }) {
|
|
|
5137
5145
|
className: kr({
|
|
5138
5146
|
extraClass: "mt-5"
|
|
5139
5147
|
}),
|
|
5140
|
-
children: /* @__PURE__ */
|
|
5148
|
+
children: /* @__PURE__ */ u(It, { fallback: /* @__PURE__ */ u("div", {}), children: /* @__PURE__ */ u(Ji, {}) })
|
|
5141
5149
|
}
|
|
5142
5150
|
),
|
|
5143
|
-
/* @__PURE__ */
|
|
5144
|
-
|
|
5151
|
+
/* @__PURE__ */ u(
|
|
5152
|
+
oa,
|
|
5145
5153
|
{
|
|
5146
5154
|
className: kr({
|
|
5147
5155
|
extraClass: "max-h-[calc(100svh_-_250px)]"
|
|
5148
5156
|
}),
|
|
5149
5157
|
noMargin: !0,
|
|
5150
5158
|
noPadding: !0,
|
|
5151
|
-
children: /* @__PURE__ */
|
|
5159
|
+
children: /* @__PURE__ */ u(Yi, {})
|
|
5152
5160
|
}
|
|
5153
5161
|
),
|
|
5154
|
-
/* @__PURE__ */
|
|
5162
|
+
/* @__PURE__ */ u(ui, { isComponent: e })
|
|
5155
5163
|
]
|
|
5156
5164
|
}
|
|
5157
5165
|
)
|
|
5158
5166
|
}
|
|
5159
5167
|
) });
|
|
5160
5168
|
}
|
|
5161
|
-
|
|
5162
|
-
const
|
|
5169
|
+
Hn.displayName = "App";
|
|
5170
|
+
const ml = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, default: Hn }, Symbol.toStringTag, { value: "Module" }));
|
|
5163
5171
|
export {
|
|
5164
|
-
|
|
5172
|
+
ml as App,
|
|
5165
5173
|
pe as AppContext,
|
|
5166
5174
|
Sr as E,
|
|
5167
|
-
|
|
5168
|
-
|
|
5175
|
+
ls as HistoryContext,
|
|
5176
|
+
ul as P,
|
|
5169
5177
|
Ze as R,
|
|
5170
5178
|
Ve as SERVICE_TYPES,
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
|
|
5178
|
-
|
|
5179
|
-
|
|
5180
|
-
|
|
5179
|
+
ut as _e,
|
|
5180
|
+
al as be,
|
|
5181
|
+
Oe as f,
|
|
5182
|
+
rl as ge,
|
|
5183
|
+
nl as he,
|
|
5184
|
+
Ga as i,
|
|
5185
|
+
fo as le,
|
|
5186
|
+
Ai as le$1,
|
|
5187
|
+
Oa as m,
|
|
5188
|
+
ol as me,
|
|
5181
5189
|
or as me$1,
|
|
5182
5190
|
wr as p,
|
|
5183
|
-
|
|
5184
|
-
|
|
5185
|
-
|
|
5186
|
-
|
|
5187
|
-
|
|
5188
|
-
|
|
5189
|
-
|
|
5191
|
+
vn as serviceCall,
|
|
5192
|
+
sl as ue,
|
|
5193
|
+
cl as useChatsHistory,
|
|
5194
|
+
dl as useServerCapabilities,
|
|
5195
|
+
ll as useUserChatStats,
|
|
5196
|
+
Qt as useUserPreferences,
|
|
5197
|
+
il as ye,
|
|
5190
5198
|
_r as z
|
|
5191
5199
|
};
|