@minimalstuff/ui 3.0.0 → 3.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +5 -21
- package/dist/minimalstuff-ui.css +1 -1
- package/dist/minimalstuff-ui.js +697 -695
- package/package.json +1 -1
package/dist/minimalstuff-ui.js
CHANGED
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
import { Fragment as e, jsx as t, jsxs as n } from "react/jsx-runtime";
|
|
2
2
|
import * as r from "react";
|
|
3
|
-
import i, {
|
|
4
|
-
import * as
|
|
5
|
-
import { createPortal as
|
|
3
|
+
import i, { cloneElement as a, createContext as o, createElement as s, isValidElement as c, useCallback as l, useContext as u, useEffect as d, useId as f, useLayoutEffect as p, useMemo as m, useRef as h, useState as g, useSyncExternalStore as _ } from "react";
|
|
4
|
+
import * as v from "react-dom";
|
|
5
|
+
import { createPortal as y } from "react-dom";
|
|
6
6
|
//#region node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
|
|
7
|
-
function
|
|
7
|
+
function b(e) {
|
|
8
8
|
var t, n, r = "";
|
|
9
9
|
if (typeof e == "string" || typeof e == "number") r += e;
|
|
10
10
|
else if (typeof e == "object") {
|
|
11
11
|
if (Array.isArray(e)) {
|
|
12
12
|
var i = e.length;
|
|
13
|
-
for (t = 0; t < i; t++) e[t] && (n =
|
|
13
|
+
for (t = 0; t < i; t++) e[t] && (n = b(e[t])) && (r && (r += " "), r += n);
|
|
14
14
|
} else for (n in e) e[n] && (r && (r += " "), r += n);
|
|
15
15
|
}
|
|
16
16
|
return r;
|
|
17
17
|
}
|
|
18
|
-
function
|
|
19
|
-
for (var e, t, n = 0, r = "", i = arguments.length; n < i; n++) (e = arguments[n]) && (t =
|
|
18
|
+
function x() {
|
|
19
|
+
for (var e, t, n = 0, r = "", i = arguments.length; n < i; n++) (e = arguments[n]) && (t = b(e)) && (r && (r += " "), r += t);
|
|
20
20
|
return r;
|
|
21
21
|
}
|
|
22
22
|
//#endregion
|
|
23
23
|
//#region src/components/shared/radius.ts
|
|
24
|
-
var
|
|
24
|
+
var S = {
|
|
25
25
|
none: "rounded-none",
|
|
26
26
|
sm: "rounded-sm",
|
|
27
27
|
md: "rounded-md",
|
|
28
28
|
lg: "rounded-lg",
|
|
29
29
|
xl: "rounded-xl",
|
|
30
30
|
full: "rounded-full"
|
|
31
|
-
},
|
|
31
|
+
}, C = "outline-hidden focus-visible:outline-2 focus-visible:outline-offset-2", w = "focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent", T = "focus-within:outline-none focus-within:ring-2 focus-within:ring-offset-2 focus-within:ring-offset-white dark:focus-within:ring-offset-gray-900", E = "focus-within:ring-blue-500", D = "focus-within:ring-red-500", O = {
|
|
32
32
|
primary: {
|
|
33
33
|
solid: "border-transparent bg-blue-600 text-white enabled:hover:bg-blue-700 enabled:active:bg-blue-800 dark:bg-blue-500 dark:enabled:hover:bg-blue-600 dark:enabled:active:bg-blue-700",
|
|
34
34
|
outline: "border-blue-300 bg-transparent text-blue-700 enabled:hover:bg-blue-50 enabled:active:bg-blue-100 dark:border-blue-800 dark:text-blue-400 dark:enabled:hover:bg-blue-950/40 dark:enabled:active:bg-blue-950/60",
|
|
@@ -64,35 +64,35 @@ var w = {
|
|
|
64
64
|
subtle: "border-transparent bg-yellow-50 text-yellow-700 enabled:hover:bg-yellow-100 enabled:active:bg-yellow-200 dark:bg-yellow-500/10 dark:text-yellow-400 dark:enabled:hover:bg-yellow-500/20 dark:enabled:active:bg-yellow-500/30",
|
|
65
65
|
focusOutline: "focus-visible:outline-yellow-500"
|
|
66
66
|
}
|
|
67
|
-
},
|
|
67
|
+
}, k = "inline-flex items-center justify-center disabled:opacity-50 disabled:cursor-not-allowed", A = `cursor-pointer transition-[color,background-color,border-color,transform] duration-200 enabled:active:duration-75 enabled:active:scale-[0.95] ${C}`, j = {
|
|
68
68
|
xs: "px-1.5 py-0.5 text-xs",
|
|
69
69
|
sm: "px-2.5 py-1 text-sm",
|
|
70
70
|
md: "px-3 py-1 text-base",
|
|
71
71
|
lg: "px-3.5 py-1.5 text-lg"
|
|
72
|
-
},
|
|
73
|
-
className:
|
|
72
|
+
}, M = ({ children: e, color: n = "primary", variant: r = "subtle", size: i = "sm", radius: a = "md", className: o, ...s }) => /* @__PURE__ */ t("span", {
|
|
73
|
+
className: x("inline-flex items-center gap-1 border", S[a], j[i], O[n][r], o),
|
|
74
74
|
...s,
|
|
75
75
|
children: e
|
|
76
|
-
}),
|
|
76
|
+
}), N = {
|
|
77
77
|
xs: "px-2 py-1 text-xs",
|
|
78
78
|
sm: "px-3 py-1.5 text-sm",
|
|
79
79
|
md: "px-4 py-2 text-sm",
|
|
80
80
|
lg: "px-4 py-3 text-base"
|
|
81
|
-
},
|
|
81
|
+
}, P = {
|
|
82
82
|
xs: "w-3.5 h-3.5",
|
|
83
83
|
sm: "w-4 h-4",
|
|
84
84
|
md: "w-4 h-4",
|
|
85
85
|
lg: "w-5 h-5"
|
|
86
86
|
};
|
|
87
|
-
function
|
|
88
|
-
let { unstyled: r = !1, variant: i = "solid", color: a = "primary", size: o = "md", radius: s = "md", children: c, className: l, fullWidth: u = !1, loading: d = !1, startIcon: f, endIcon: p, disabled: m, ...h } = e, g =
|
|
87
|
+
function F(e) {
|
|
88
|
+
let { unstyled: r = !1, variant: i = "solid", color: a = "primary", size: o = "md", radius: s = "md", children: c, className: l, fullWidth: u = !1, loading: d = !1, startIcon: f, endIcon: p, disabled: m, ...h } = e, g = O[a], _ = P[o];
|
|
89
89
|
return /* @__PURE__ */ n("button", {
|
|
90
90
|
type: "button",
|
|
91
|
-
className:
|
|
92
|
-
|
|
91
|
+
className: x(k, !r && [
|
|
92
|
+
A,
|
|
93
93
|
"gap-2 font-medium border",
|
|
94
|
-
|
|
95
|
-
|
|
94
|
+
S[s],
|
|
95
|
+
N[o],
|
|
96
96
|
g[i],
|
|
97
97
|
g.focusOutline
|
|
98
98
|
], u && "w-full", l),
|
|
@@ -101,16 +101,16 @@ function ee(e) {
|
|
|
101
101
|
...h,
|
|
102
102
|
children: [
|
|
103
103
|
d && /* @__PURE__ */ t("span", {
|
|
104
|
-
className:
|
|
104
|
+
className: x("i-svg-spinners-3-dots-fade", _),
|
|
105
105
|
"aria-hidden": "true"
|
|
106
106
|
}),
|
|
107
107
|
!d && f && /* @__PURE__ */ t("span", {
|
|
108
|
-
className:
|
|
108
|
+
className: x(f, _),
|
|
109
109
|
"aria-hidden": "true"
|
|
110
110
|
}),
|
|
111
111
|
c,
|
|
112
112
|
!d && p && /* @__PURE__ */ t("span", {
|
|
113
|
-
className:
|
|
113
|
+
className: x(p, _),
|
|
114
114
|
"aria-hidden": "true"
|
|
115
115
|
})
|
|
116
116
|
]
|
|
@@ -118,30 +118,30 @@ function ee(e) {
|
|
|
118
118
|
}
|
|
119
119
|
//#endregion
|
|
120
120
|
//#region src/components/character_count/character_count.tsx
|
|
121
|
-
var
|
|
122
|
-
function
|
|
121
|
+
var I = "text-xs text-gray-500 dark:text-gray-400 mt-1 text-right";
|
|
122
|
+
function L(e, t) {
|
|
123
123
|
return t ? "" : e === "overLimit" ? "text-red-600 dark:text-red-400" : e === "atLimit" ? "text-amber-600 dark:text-amber-400" : "";
|
|
124
124
|
}
|
|
125
|
-
function
|
|
125
|
+
function R({ current: e, min: r, max: i, showMin: a, showMax: o, unstyled: s = !1, className: c }) {
|
|
126
126
|
let l = a === !0 || o === !0, u = r !== void 0 && e <= r ? "atLimit" : "ok", d = i !== void 0 && e > i ? "overLimit" : i !== void 0 && e >= i ? "atLimit" : "ok", f = l ? `${e}/${r} min` : `${e} (min ${r})`, p = l ? `${e}/${i} max` : `${e}/${i}`;
|
|
127
127
|
return /* @__PURE__ */ n("div", {
|
|
128
|
-
className:
|
|
128
|
+
className: x(!s && I, c),
|
|
129
129
|
children: [
|
|
130
130
|
a && r !== void 0 && /* @__PURE__ */ t("span", {
|
|
131
|
-
className:
|
|
131
|
+
className: L(u, s),
|
|
132
132
|
children: f
|
|
133
133
|
}),
|
|
134
134
|
a && o && " · ",
|
|
135
135
|
o && i !== void 0 && /* @__PURE__ */ t("span", {
|
|
136
|
-
className:
|
|
136
|
+
className: L(d, s),
|
|
137
137
|
children: p
|
|
138
138
|
}),
|
|
139
139
|
!a && !o && i !== void 0 && /* @__PURE__ */ t("span", {
|
|
140
|
-
className:
|
|
140
|
+
className: L(d, s),
|
|
141
141
|
children: p
|
|
142
142
|
}),
|
|
143
143
|
!a && !o && r !== void 0 && i === void 0 && /* @__PURE__ */ t("span", {
|
|
144
|
-
className:
|
|
144
|
+
className: L(u, s),
|
|
145
145
|
children: f
|
|
146
146
|
})
|
|
147
147
|
]
|
|
@@ -149,16 +149,16 @@ function te({ current: e, min: r, max: i, showMin: a, showMax: o, unstyled: s =
|
|
|
149
149
|
}
|
|
150
150
|
//#endregion
|
|
151
151
|
//#region src/components/shared/surface_tokens.ts
|
|
152
|
-
var
|
|
152
|
+
var z = "border-gray-300 dark:border-gray-600", ee = "bg-white dark:bg-gray-800", te = "border-gray-100 dark:border-gray-800", ne = "bg-white dark:bg-gray-900", B = `w-full border ${z} ${ee} text-gray-900 dark:text-gray-100 placeholder-gray-500 dark:placeholder-gray-400 ${w} transition-all duration-200 disabled:opacity-50 disabled:cursor-not-allowed`, re = "text-xs text-gray-500 dark:text-gray-400", ie = "text-xs text-red-600 dark:text-red-400", ae = "border-red-500 dark:border-red-400", oe = ({ id: e, error: n, className: r }) => n ? /* @__PURE__ */ t("p", {
|
|
153
153
|
id: e,
|
|
154
|
-
className:
|
|
154
|
+
className: x(ie, r),
|
|
155
155
|
role: "alert",
|
|
156
156
|
children: n
|
|
157
157
|
}) : null;
|
|
158
158
|
//#endregion
|
|
159
159
|
//#region src/components/shared/use_field_ids.ts
|
|
160
|
-
function
|
|
161
|
-
let t =
|
|
160
|
+
function V(e) {
|
|
161
|
+
let t = f(), n = e ?? t;
|
|
162
162
|
return {
|
|
163
163
|
fieldId: n,
|
|
164
164
|
errorId: `${n}-error`,
|
|
@@ -167,35 +167,35 @@ function B(e) {
|
|
|
167
167
|
}
|
|
168
168
|
//#endregion
|
|
169
169
|
//#region src/components/shared/field_description.tsx
|
|
170
|
-
var
|
|
170
|
+
var se = ({ id: e, description: n, className: r }) => n ? typeof n == "string" ? /* @__PURE__ */ t("p", {
|
|
171
171
|
id: e,
|
|
172
|
-
className:
|
|
172
|
+
className: x(re, r),
|
|
173
173
|
children: n
|
|
174
174
|
}) : /* @__PURE__ */ t("span", {
|
|
175
175
|
id: e,
|
|
176
|
-
className:
|
|
176
|
+
className: x(re, "block", r),
|
|
177
177
|
children: n
|
|
178
178
|
}) : null;
|
|
179
179
|
//#endregion
|
|
180
180
|
//#region src/components/shared/use_controlled_state.ts
|
|
181
|
-
function
|
|
182
|
-
let [n, r] =
|
|
181
|
+
function H(e, t) {
|
|
182
|
+
let [n, r] = g(t), i = e !== void 0, a = l((e) => {
|
|
183
183
|
i || r(e);
|
|
184
184
|
}, [i]);
|
|
185
185
|
return [i ? e : n, a];
|
|
186
186
|
}
|
|
187
187
|
//#endregion
|
|
188
188
|
//#region src/components/checkbox/checkbox.tsx
|
|
189
|
-
function
|
|
190
|
-
let { fieldId: h, errorId: g, descriptionId: _ } =
|
|
189
|
+
function ce({ label: r, description: i, error: a, radius: o = "sm", unstyled: s = !1, className: c, wrapperClassName: l, checked: u, defaultChecked: d = !1, onChange: f, id: p, ...m }) {
|
|
190
|
+
let { fieldId: h, errorId: g, descriptionId: _ } = V(p), [v, y] = H(u, d), b = [i && _, a && g].filter(Boolean).join(" ") || void 0;
|
|
191
191
|
return /* @__PURE__ */ n("div", {
|
|
192
|
-
className:
|
|
192
|
+
className: x("w-full", l),
|
|
193
193
|
children: [
|
|
194
194
|
/* @__PURE__ */ n("label", {
|
|
195
195
|
htmlFor: h,
|
|
196
|
-
className:
|
|
196
|
+
className: x("flex items-start gap-3 cursor-pointer", m.disabled && "cursor-not-allowed opacity-50"),
|
|
197
197
|
children: [/* @__PURE__ */ n("span", {
|
|
198
|
-
className:
|
|
198
|
+
className: x("relative shrink-0", S[o], T, a ? D : E),
|
|
199
199
|
children: [/* @__PURE__ */ t("input", {
|
|
200
200
|
type: "checkbox",
|
|
201
201
|
id: h,
|
|
@@ -208,10 +208,10 @@ function fe({ label: r, description: i, error: a, radius: o = "sm", unstyled: s
|
|
|
208
208
|
"aria-describedby": b,
|
|
209
209
|
...m
|
|
210
210
|
}), /* @__PURE__ */ t("span", {
|
|
211
|
-
className:
|
|
212
|
-
|
|
211
|
+
className: x("flex h-5 w-5 items-center justify-center transition-all duration-200", !s && [
|
|
212
|
+
S[o],
|
|
213
213
|
"border-2",
|
|
214
|
-
v ?
|
|
214
|
+
v ? x("border-blue-600 dark:border-blue-500", "bg-blue-600 dark:bg-blue-500") : x("border-gray-300 dark:border-gray-600", "bg-white dark:bg-gray-800"),
|
|
215
215
|
a && "border-red-500 dark:border-red-400"
|
|
216
216
|
], c),
|
|
217
217
|
"aria-hidden": !0,
|
|
@@ -227,7 +227,7 @@ function fe({ label: r, description: i, error: a, radius: o = "sm", unstyled: s
|
|
|
227
227
|
})
|
|
228
228
|
})]
|
|
229
229
|
}), r !== void 0 && (typeof r == "string" ? /* @__PURE__ */ n("span", {
|
|
230
|
-
className:
|
|
230
|
+
className: x("text-sm font-medium text-gray-700 dark:text-gray-300", "select-none"),
|
|
231
231
|
children: [r, m.required && /* @__PURE__ */ t("span", {
|
|
232
232
|
className: "text-red-500 dark:text-red-400 ml-1",
|
|
233
233
|
children: "*"
|
|
@@ -237,12 +237,12 @@ function fe({ label: r, description: i, error: a, radius: o = "sm", unstyled: s
|
|
|
237
237
|
children: "*"
|
|
238
238
|
})] }))]
|
|
239
239
|
}),
|
|
240
|
-
/* @__PURE__ */ t(
|
|
240
|
+
/* @__PURE__ */ t(se, {
|
|
241
241
|
id: _,
|
|
242
242
|
description: i,
|
|
243
243
|
className: "mt-1 ml-8"
|
|
244
244
|
}),
|
|
245
|
-
/* @__PURE__ */ t(
|
|
245
|
+
/* @__PURE__ */ t(oe, {
|
|
246
246
|
id: g,
|
|
247
247
|
error: a,
|
|
248
248
|
className: "mt-1 ml-8"
|
|
@@ -252,9 +252,9 @@ function fe({ label: r, description: i, error: a, radius: o = "sm", unstyled: s
|
|
|
252
252
|
}
|
|
253
253
|
//#endregion
|
|
254
254
|
//#region src/hooks/use_is_client/use_is_client.tsx
|
|
255
|
-
var
|
|
256
|
-
let [e, t] =
|
|
257
|
-
return
|
|
255
|
+
var le = () => {
|
|
256
|
+
let [e, t] = g(!1);
|
|
257
|
+
return d(() => {
|
|
258
258
|
requestAnimationFrame(() => {
|
|
259
259
|
t(!0);
|
|
260
260
|
});
|
|
@@ -262,16 +262,16 @@ var pe = () => {
|
|
|
262
262
|
};
|
|
263
263
|
//#endregion
|
|
264
264
|
//#region src/components/client_only/client_only.tsx
|
|
265
|
-
function
|
|
266
|
-
return
|
|
265
|
+
function ue({ children: n, fallback: r }) {
|
|
266
|
+
return le() ? /* @__PURE__ */ t(e, { children: n }) : r ?? null;
|
|
267
267
|
}
|
|
268
268
|
//#endregion
|
|
269
269
|
//#region src/components/shared/field.tsx
|
|
270
|
-
var
|
|
271
|
-
className:
|
|
270
|
+
var de = ({ fieldId: r, errorId: i, label: a, error: o, required: s = !1, wrapperClassName: c, children: l }) => /* @__PURE__ */ n("div", {
|
|
271
|
+
className: x("w-full", c),
|
|
272
272
|
children: [
|
|
273
273
|
a !== void 0 && (typeof a == "string" ? /* @__PURE__ */ n("label", {
|
|
274
|
-
className:
|
|
274
|
+
className: x("text-sm font-medium text-gray-700 dark:text-gray-300", "block mb-1"),
|
|
275
275
|
htmlFor: r,
|
|
276
276
|
children: [a, s && /* @__PURE__ */ t("span", {
|
|
277
277
|
className: "text-red-500 dark:text-red-400 ml-1",
|
|
@@ -282,7 +282,7 @@ var he = ({ fieldId: r, errorId: i, label: a, error: o, required: s = !1, wrappe
|
|
|
282
282
|
children: "*"
|
|
283
283
|
})] })),
|
|
284
284
|
l,
|
|
285
|
-
/* @__PURE__ */ t(
|
|
285
|
+
/* @__PURE__ */ t(oe, {
|
|
286
286
|
id: i,
|
|
287
287
|
error: o,
|
|
288
288
|
className: "mt-1"
|
|
@@ -291,50 +291,50 @@ var he = ({ fieldId: r, errorId: i, label: a, error: o, required: s = !1, wrappe
|
|
|
291
291
|
});
|
|
292
292
|
//#endregion
|
|
293
293
|
//#region src/components/combobox/combobox.tsx
|
|
294
|
-
function
|
|
295
|
-
let { fieldId: b, errorId:
|
|
294
|
+
function fe({ options: e, label: r, error: i, placeholder: a, noResultsText: o = "No results found", clearLabel: s = "Clear selection", radius: c = "md", unstyled: l = !1, disabled: u = !1, required: d = !1, className: f, wrapperClassName: p, value: h, defaultValue: _ = "", onChange: v, id: y }) {
|
|
295
|
+
let { fieldId: b, errorId: C } = V(y), w = `${b}-listbox`, [T, E] = H(h, _), D = e.find((e) => e.value === T), [O, k] = g(""), [A, j] = g(!1), [M, N] = g(!1), [P, F] = g(-1), I = m(() => A ? e.filter((e) => e.label.toLowerCase().includes(O.toLowerCase())) : e, [
|
|
296
296
|
e,
|
|
297
297
|
A,
|
|
298
298
|
O
|
|
299
|
-
]),
|
|
299
|
+
]), L = M ? O : D?.label ?? "", R = () => {
|
|
300
300
|
u || (k(D?.label ?? ""), j(!1), N(!0), F(-1));
|
|
301
|
-
},
|
|
301
|
+
}, z = () => {
|
|
302
302
|
N(!1), j(!1), F(-1);
|
|
303
|
-
},
|
|
304
|
-
E(e.value),
|
|
305
|
-
},
|
|
306
|
-
E(""),
|
|
307
|
-
},
|
|
303
|
+
}, ee = (e) => {
|
|
304
|
+
E(e.value), v?.(e.value), z();
|
|
305
|
+
}, te = () => {
|
|
306
|
+
E(""), v?.(""), k("");
|
|
307
|
+
}, ne = (e) => {
|
|
308
308
|
k(e.target.value), j(!0), N(!0), F(0);
|
|
309
|
-
},
|
|
309
|
+
}, re = (e) => {
|
|
310
310
|
I.length !== 0 && F((t) => {
|
|
311
311
|
let n = t + e;
|
|
312
312
|
return n < 0 ? I.length - 1 : n >= I.length ? 0 : n;
|
|
313
313
|
});
|
|
314
|
-
},
|
|
314
|
+
}, ie = (e) => {
|
|
315
315
|
if (e.key === "ArrowDown") {
|
|
316
|
-
e.preventDefault(), M ?
|
|
316
|
+
e.preventDefault(), M ? re(1) : R();
|
|
317
317
|
return;
|
|
318
318
|
}
|
|
319
319
|
if (e.key === "ArrowUp") {
|
|
320
|
-
e.preventDefault(), M ?
|
|
320
|
+
e.preventDefault(), M ? re(-1) : R();
|
|
321
321
|
return;
|
|
322
322
|
}
|
|
323
323
|
if (e.key === "Enter") {
|
|
324
324
|
if (!M) return;
|
|
325
325
|
e.preventDefault();
|
|
326
326
|
let t = I[P];
|
|
327
|
-
t &&
|
|
327
|
+
t && ee(t);
|
|
328
328
|
return;
|
|
329
329
|
}
|
|
330
330
|
if (e.key === "Escape") {
|
|
331
331
|
if (!M) return;
|
|
332
|
-
e.preventDefault(),
|
|
332
|
+
e.preventDefault(), z();
|
|
333
333
|
}
|
|
334
|
-
},
|
|
335
|
-
return /* @__PURE__ */ t(
|
|
334
|
+
}, ae = M && P >= 0 ? `${w}-option-${P}` : void 0;
|
|
335
|
+
return /* @__PURE__ */ t(de, {
|
|
336
336
|
fieldId: b,
|
|
337
|
-
errorId:
|
|
337
|
+
errorId: C,
|
|
338
338
|
label: r,
|
|
339
339
|
error: i,
|
|
340
340
|
required: d,
|
|
@@ -353,28 +353,28 @@ function ge({ options: e, label: r, error: i, placeholder: a, noResultsText: o =
|
|
|
353
353
|
autoComplete: "off",
|
|
354
354
|
disabled: u,
|
|
355
355
|
placeholder: a,
|
|
356
|
-
value:
|
|
357
|
-
onChange:
|
|
358
|
-
onFocus:
|
|
359
|
-
onBlur:
|
|
360
|
-
onKeyDown:
|
|
356
|
+
value: L,
|
|
357
|
+
onChange: ne,
|
|
358
|
+
onFocus: R,
|
|
359
|
+
onBlur: z,
|
|
360
|
+
onKeyDown: ie,
|
|
361
361
|
"aria-expanded": M,
|
|
362
|
-
"aria-controls":
|
|
362
|
+
"aria-controls": w,
|
|
363
363
|
"aria-autocomplete": "list",
|
|
364
|
-
"aria-activedescendant":
|
|
364
|
+
"aria-activedescendant": ae,
|
|
365
365
|
"aria-invalid": !!i,
|
|
366
|
-
"aria-describedby": i ?
|
|
367
|
-
className:
|
|
368
|
-
|
|
369
|
-
|
|
366
|
+
"aria-describedby": i ? C : void 0,
|
|
367
|
+
className: x("w-full disabled:opacity-50 disabled:cursor-not-allowed", !l && [
|
|
368
|
+
B,
|
|
369
|
+
S[c],
|
|
370
370
|
"pl-9 pr-8 py-2 text-sm"
|
|
371
|
-
], !l && i &&
|
|
371
|
+
], !l && i && x("border-red-500 dark:border-red-400", "focus:ring-red-500"), f)
|
|
372
372
|
}),
|
|
373
373
|
!l && D && !u && /* @__PURE__ */ t("button", {
|
|
374
374
|
type: "button",
|
|
375
375
|
"aria-label": s,
|
|
376
376
|
onMouseDown: (e) => e.preventDefault(),
|
|
377
|
-
onClick:
|
|
377
|
+
onClick: te,
|
|
378
378
|
className: "absolute right-2.5 top-1/2 -translate-y-1/2 w-4 h-4 text-gray-400 hover:text-gray-600 dark:text-gray-500 dark:hover:text-gray-300",
|
|
379
379
|
children: /* @__PURE__ */ t("span", {
|
|
380
380
|
className: "i-mdi-close block w-4 h-4",
|
|
@@ -382,24 +382,24 @@ function ge({ options: e, label: r, error: i, placeholder: a, noResultsText: o =
|
|
|
382
382
|
})
|
|
383
383
|
}),
|
|
384
384
|
M && /* @__PURE__ */ t("ul", {
|
|
385
|
-
id:
|
|
385
|
+
id: w,
|
|
386
386
|
role: "listbox",
|
|
387
|
-
className:
|
|
387
|
+
className: x("absolute z-10 mt-1 w-full max-h-60 overflow-auto py-1 text-sm shadow-lg", !l && [
|
|
388
388
|
"border",
|
|
389
389
|
"bg-white dark:bg-gray-900",
|
|
390
390
|
"border-gray-100 dark:border-gray-800",
|
|
391
|
-
|
|
391
|
+
S[c]
|
|
392
392
|
]),
|
|
393
393
|
children: I.length === 0 ? /* @__PURE__ */ t("li", {
|
|
394
394
|
className: "px-3 py-2 text-gray-500 dark:text-gray-400",
|
|
395
395
|
children: o
|
|
396
396
|
}) : I.map((e, n) => /* @__PURE__ */ t("li", {
|
|
397
|
-
id: `${
|
|
397
|
+
id: `${w}-option-${n}`,
|
|
398
398
|
role: "option",
|
|
399
399
|
"aria-selected": e.value === T,
|
|
400
400
|
onMouseDown: (e) => e.preventDefault(),
|
|
401
|
-
onClick: () =>
|
|
402
|
-
className:
|
|
401
|
+
onClick: () => ee(e),
|
|
402
|
+
className: x("px-3 py-2 cursor-pointer text-gray-900 dark:text-gray-100", n === P ? "bg-blue-50 dark:bg-blue-900/40" : "hover:bg-gray-50 dark:hover:bg-gray-800/60", e.value === T && "font-medium"),
|
|
403
403
|
children: e.label
|
|
404
404
|
}, e.value))
|
|
405
405
|
})
|
|
@@ -409,75 +409,75 @@ function ge({ options: e, label: r, error: i, placeholder: a, noResultsText: o =
|
|
|
409
409
|
}
|
|
410
410
|
//#endregion
|
|
411
411
|
//#region node_modules/.pnpm/@floating-ui+utils@0.2.12/node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs
|
|
412
|
-
var
|
|
412
|
+
var pe = Math.min, U = Math.max, me = Math.round, he = Math.floor, W = (e) => ({
|
|
413
413
|
x: e,
|
|
414
414
|
y: e
|
|
415
|
-
}),
|
|
415
|
+
}), ge = {
|
|
416
416
|
left: "right",
|
|
417
417
|
right: "left",
|
|
418
418
|
bottom: "top",
|
|
419
419
|
top: "bottom"
|
|
420
420
|
};
|
|
421
|
-
function
|
|
422
|
-
return
|
|
421
|
+
function _e(e, t, n) {
|
|
422
|
+
return U(e, pe(t, n));
|
|
423
423
|
}
|
|
424
|
-
function
|
|
424
|
+
function ve(e, t) {
|
|
425
425
|
return typeof e == "function" ? e(t) : e;
|
|
426
426
|
}
|
|
427
|
-
function
|
|
427
|
+
function ye(e) {
|
|
428
428
|
return e.split("-")[0];
|
|
429
429
|
}
|
|
430
|
-
function
|
|
430
|
+
function be(e) {
|
|
431
431
|
return e.split("-")[1];
|
|
432
432
|
}
|
|
433
|
-
function
|
|
433
|
+
function xe(e) {
|
|
434
434
|
return e === "x" ? "y" : "x";
|
|
435
435
|
}
|
|
436
|
-
function
|
|
436
|
+
function Se(e) {
|
|
437
437
|
return e === "y" ? "height" : "width";
|
|
438
438
|
}
|
|
439
|
-
function
|
|
439
|
+
function G(e) {
|
|
440
440
|
let t = e[0];
|
|
441
441
|
return t === "t" || t === "b" ? "y" : "x";
|
|
442
442
|
}
|
|
443
|
-
function
|
|
444
|
-
return
|
|
443
|
+
function Ce(e) {
|
|
444
|
+
return xe(G(e));
|
|
445
445
|
}
|
|
446
|
-
function
|
|
446
|
+
function we(e, t, n) {
|
|
447
447
|
n === void 0 && (n = !1);
|
|
448
|
-
let r =
|
|
449
|
-
return t.reference[a] > t.floating[a] && (o =
|
|
448
|
+
let r = be(e), i = Ce(e), a = Se(i), o = i === "x" ? r === (n ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
|
|
449
|
+
return t.reference[a] > t.floating[a] && (o = Ne(o)), [o, Ne(o)];
|
|
450
450
|
}
|
|
451
|
-
function
|
|
452
|
-
let t =
|
|
451
|
+
function Te(e) {
|
|
452
|
+
let t = Ne(e);
|
|
453
453
|
return [
|
|
454
|
-
|
|
454
|
+
Ee(e),
|
|
455
455
|
t,
|
|
456
|
-
|
|
456
|
+
Ee(t)
|
|
457
457
|
];
|
|
458
458
|
}
|
|
459
|
-
function
|
|
459
|
+
function Ee(e) {
|
|
460
460
|
return e.includes("start") ? e.replace("start", "end") : e.replace("end", "start");
|
|
461
461
|
}
|
|
462
|
-
var
|
|
463
|
-
function
|
|
462
|
+
var De = ["left", "right"], Oe = ["right", "left"], ke = ["top", "bottom"], Ae = ["bottom", "top"];
|
|
463
|
+
function je(e, t, n) {
|
|
464
464
|
switch (e) {
|
|
465
465
|
case "top":
|
|
466
|
-
case "bottom": return n ? t ?
|
|
466
|
+
case "bottom": return n ? t ? Oe : De : t ? De : Oe;
|
|
467
467
|
case "left":
|
|
468
|
-
case "right": return t ?
|
|
468
|
+
case "right": return t ? ke : Ae;
|
|
469
469
|
default: return [];
|
|
470
470
|
}
|
|
471
471
|
}
|
|
472
|
-
function
|
|
473
|
-
let i =
|
|
474
|
-
return i && (a = a.map((e) => e + "-" + i), t && (a = a.concat(a.map(
|
|
472
|
+
function Me(e, t, n, r) {
|
|
473
|
+
let i = be(e), a = je(ye(e), n === "start", r);
|
|
474
|
+
return i && (a = a.map((e) => e + "-" + i), t && (a = a.concat(a.map(Ee)))), a;
|
|
475
475
|
}
|
|
476
|
-
function
|
|
477
|
-
let t =
|
|
478
|
-
return
|
|
476
|
+
function Ne(e) {
|
|
477
|
+
let t = ye(e);
|
|
478
|
+
return ge[t] + e.slice(t.length);
|
|
479
479
|
}
|
|
480
|
-
function
|
|
480
|
+
function Pe(e) {
|
|
481
481
|
return {
|
|
482
482
|
top: e.top ?? 0,
|
|
483
483
|
right: e.right ?? 0,
|
|
@@ -485,15 +485,15 @@ function Le(e) {
|
|
|
485
485
|
left: e.left ?? 0
|
|
486
486
|
};
|
|
487
487
|
}
|
|
488
|
-
function
|
|
488
|
+
function Fe(e) {
|
|
489
489
|
return typeof e == "number" ? {
|
|
490
490
|
top: e,
|
|
491
491
|
right: e,
|
|
492
492
|
bottom: e,
|
|
493
493
|
left: e
|
|
494
|
-
} :
|
|
494
|
+
} : Pe(e);
|
|
495
495
|
}
|
|
496
|
-
function
|
|
496
|
+
function Ie(e) {
|
|
497
497
|
let { x: t, y: n, width: r, height: i } = e;
|
|
498
498
|
return {
|
|
499
499
|
width: r,
|
|
@@ -508,8 +508,8 @@ function ze(e) {
|
|
|
508
508
|
}
|
|
509
509
|
//#endregion
|
|
510
510
|
//#region node_modules/.pnpm/@floating-ui+core@1.8.0/node_modules/@floating-ui/core/dist/floating-ui.core.mjs
|
|
511
|
-
function
|
|
512
|
-
let { reference: r, floating: i } = e, a =
|
|
511
|
+
function Le(e, t, n) {
|
|
512
|
+
let { reference: r, floating: i } = e, a = G(t), o = Ce(t), s = Se(o), c = ye(t), l = a === "y", u = r.x + r.width / 2 - i.width / 2, d = r.y + r.height / 2 - i.height / 2, f = r[s] / 2 - i[s] / 2, p;
|
|
513
513
|
switch (c) {
|
|
514
514
|
case "top":
|
|
515
515
|
p = {
|
|
@@ -540,12 +540,12 @@ function Be(e, t, n) {
|
|
|
540
540
|
y: r.y
|
|
541
541
|
};
|
|
542
542
|
}
|
|
543
|
-
let m =
|
|
543
|
+
let m = be(t);
|
|
544
544
|
return m && (p[o] += f * (m === "end" ? 1 : -1) * (n && l ? -1 : 1)), p;
|
|
545
545
|
}
|
|
546
|
-
async function
|
|
546
|
+
async function Re(e, t) {
|
|
547
547
|
t === void 0 && (t = {});
|
|
548
|
-
let { x: n, y: r, platform: i, rects: a, elements: o, strategy: s } = e, { boundary: c = "clippingAncestors", rootBoundary: l = "viewport", elementContext: u = "floating", altBoundary: d = !1, padding: f = 0 } =
|
|
548
|
+
let { x: n, y: r, platform: i, rects: a, elements: o, strategy: s } = e, { boundary: c = "clippingAncestors", rootBoundary: l = "viewport", elementContext: u = "floating", altBoundary: d = !1, padding: f = 0 } = ve(t, e), p = Fe(f), m = o[d ? u === "floating" ? "reference" : "floating" : u], h = Ie(await i.getClippingRect({
|
|
549
549
|
element: await (i.isElement == null ? void 0 : i.isElement(m)) ?? !0 ? m : m.contextElement || await (i.getDocumentElement == null ? void 0 : i.getDocumentElement(o.floating)),
|
|
550
550
|
boundary: c,
|
|
551
551
|
rootBoundary: l,
|
|
@@ -558,7 +558,7 @@ async function Ve(e, t) {
|
|
|
558
558
|
} : a.reference, _ = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(o.floating)), v = await (i.isElement == null ? void 0 : i.isElement(_)) && await (i.getScale == null ? void 0 : i.getScale(_)) || {
|
|
559
559
|
x: 1,
|
|
560
560
|
y: 1
|
|
561
|
-
}, y =
|
|
561
|
+
}, y = Ie(i.convertOffsetParentRelativeRectToViewportRelativeRect ? await i.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
562
562
|
elements: o,
|
|
563
563
|
rect: g,
|
|
564
564
|
offsetParent: _,
|
|
@@ -571,15 +571,15 @@ async function Ve(e, t) {
|
|
|
571
571
|
right: (y.right - h.right + p.right) / v.x
|
|
572
572
|
};
|
|
573
573
|
}
|
|
574
|
-
var
|
|
574
|
+
var ze = 50, Be = async (e, t, n) => {
|
|
575
575
|
let { placement: r = "bottom", strategy: i = "absolute", middleware: a = [], platform: o } = n, s = o.detectOverflow ? o : {
|
|
576
576
|
...o,
|
|
577
|
-
detectOverflow:
|
|
577
|
+
detectOverflow: Re
|
|
578
578
|
}, c = await (o.isRTL == null ? void 0 : o.isRTL(t)), l = await o.getElementRects({
|
|
579
579
|
reference: e,
|
|
580
580
|
floating: t,
|
|
581
581
|
strategy: i
|
|
582
|
-
}), { x: u, y: d } =
|
|
582
|
+
}), { x: u, y: d } = Le(l, r, c), f = r, p = 0, m = {};
|
|
583
583
|
for (let n = 0; n < a.length; n++) {
|
|
584
584
|
let h = a[n];
|
|
585
585
|
if (!h) continue;
|
|
@@ -600,11 +600,11 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
600
600
|
u = v ?? u, d = y ?? d, m[g] = {
|
|
601
601
|
...m[g],
|
|
602
602
|
...b
|
|
603
|
-
}, x && p <
|
|
603
|
+
}, x && p < ze && (p++, typeof x == "object" && (x.placement && (f = x.placement), x.rects && (l = x.rects === !0 ? await o.getElementRects({
|
|
604
604
|
reference: e,
|
|
605
605
|
floating: t,
|
|
606
606
|
strategy: i
|
|
607
|
-
}) : x.rects), {x: u, y: d} =
|
|
607
|
+
}) : x.rects), {x: u, y: d} = Le(l, f, c)), n = -1);
|
|
608
608
|
}
|
|
609
609
|
return {
|
|
610
610
|
x: u,
|
|
@@ -613,18 +613,18 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
613
613
|
strategy: i,
|
|
614
614
|
middlewareData: m
|
|
615
615
|
};
|
|
616
|
-
},
|
|
616
|
+
}, Ve = (e) => ({
|
|
617
617
|
name: "arrow",
|
|
618
618
|
options: e,
|
|
619
619
|
async fn(t) {
|
|
620
|
-
let { x: n, y: r, placement: i, rects: a, platform: o, elements: s, middlewareData: c } = t, { element: l, padding: u = 0 } =
|
|
620
|
+
let { x: n, y: r, placement: i, rects: a, platform: o, elements: s, middlewareData: c } = t, { element: l, padding: u = 0 } = ve(e, t) || {};
|
|
621
621
|
if (l == null) return {};
|
|
622
|
-
let d =
|
|
622
|
+
let d = Fe(u), f = {
|
|
623
623
|
x: n,
|
|
624
624
|
y: r
|
|
625
|
-
}, p =
|
|
625
|
+
}, p = Ce(i), m = Se(p), h = await o.getDimensions(l), g = p === "y", _ = g ? "top" : "left", v = g ? "bottom" : "right", y = g ? "clientHeight" : "clientWidth", b = a.reference[m] + a.reference[p] - f[p] - a.floating[m], x = f[p] - a.reference[p], S = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(l)), C = S ? S[y] : 0;
|
|
626
626
|
(!C || !await (o.isElement == null ? void 0 : o.isElement(S))) && (C = s.floating[y] || a.floating[m]);
|
|
627
|
-
let w = b / 2 - x / 2, T = C / 2 - h[m] / 2 - 1, E =
|
|
627
|
+
let w = b / 2 - x / 2, T = C / 2 - h[m] / 2 - 1, E = pe(d[_], T), D = pe(d[v], T), O = C - h[m] - D, k = C / 2 - h[m] / 2 + w, A = _e(E, k, O), j = !c.arrow && be(i) != null && k !== A && a.reference[m] / 2 - (k < E ? E : D) - h[m] / 2 < 0, M = j ? k < E ? k - E : k - O : 0;
|
|
628
628
|
return {
|
|
629
629
|
[p]: f[p] + M,
|
|
630
630
|
data: {
|
|
@@ -635,19 +635,19 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
635
635
|
reset: j
|
|
636
636
|
};
|
|
637
637
|
}
|
|
638
|
-
}),
|
|
638
|
+
}), He = function(e) {
|
|
639
639
|
return e === void 0 && (e = {}), {
|
|
640
640
|
name: "flip",
|
|
641
641
|
options: e,
|
|
642
642
|
async fn(t) {
|
|
643
643
|
var n;
|
|
644
|
-
let { placement: r, middlewareData: i, rects: a, initialPlacement: o, platform: s, elements: c } = t, { mainAxis: l = !0, crossAxis: u = !0, fallbackPlacements: d, fallbackStrategy: f = "bestFit", fallbackAxisSideDirection: p = "none", flipAlignment: m = !0, ...h } =
|
|
644
|
+
let { placement: r, middlewareData: i, rects: a, initialPlacement: o, platform: s, elements: c } = t, { mainAxis: l = !0, crossAxis: u = !0, fallbackPlacements: d, fallbackStrategy: f = "bestFit", fallbackAxisSideDirection: p = "none", flipAlignment: m = !0, ...h } = ve(e, t);
|
|
645
645
|
if ((n = i.arrow) != null && n.alignmentOffset) return {};
|
|
646
|
-
let g =
|
|
647
|
-
!d && x && b.push(...
|
|
646
|
+
let g = ye(r), _ = G(o), v = ye(o) === o, y = await (s.isRTL == null ? void 0 : s.isRTL(c.floating)), b = d || (v || !m ? [Ne(o)] : Te(o)), x = p !== "none";
|
|
647
|
+
!d && x && b.push(...Me(o, m, p, y));
|
|
648
648
|
let S = [o, ...b], C = await s.detectOverflow(t, h), w = [], T = i.flip?.overflows || [];
|
|
649
649
|
if (l && w.push(C[g]), u) {
|
|
650
|
-
let e =
|
|
650
|
+
let e = we(r, a, y);
|
|
651
651
|
w.push(C[e[0]], C[e[1]]);
|
|
652
652
|
}
|
|
653
653
|
if (T = [...T, {
|
|
@@ -655,7 +655,7 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
655
655
|
overflows: w
|
|
656
656
|
}], !w.every((e) => e <= 0)) {
|
|
657
657
|
let e = (i.flip?.index || 0) + 1, t = S[e];
|
|
658
|
-
if (t && (u !== "alignment" || _ ===
|
|
658
|
+
if (t && (u !== "alignment" || _ === G(t) || T.every((e) => G(e.placement) !== _ || e.overflows[0] > 0))) return {
|
|
659
659
|
data: {
|
|
660
660
|
index: e,
|
|
661
661
|
overflows: T
|
|
@@ -667,7 +667,7 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
667
667
|
case "bestFit": {
|
|
668
668
|
let e = T.filter((e) => {
|
|
669
669
|
if (x) {
|
|
670
|
-
let t =
|
|
670
|
+
let t = G(e.placement);
|
|
671
671
|
return t === _ || t === "y";
|
|
672
672
|
}
|
|
673
673
|
return !0;
|
|
@@ -682,9 +682,9 @@ var He = 50, Ue = async (e, t, n) => {
|
|
|
682
682
|
return {};
|
|
683
683
|
}
|
|
684
684
|
};
|
|
685
|
-
},
|
|
686
|
-
async function
|
|
687
|
-
let { placement: n, platform: r, elements: i } = e, a = await (r.isRTL == null ? void 0 : r.isRTL(i.floating)), o =
|
|
685
|
+
}, Ue = /*#__PURE__*/ new Set(["left", "top"]);
|
|
686
|
+
async function We(e, t) {
|
|
687
|
+
let { placement: n, platform: r, elements: i } = e, a = await (r.isRTL == null ? void 0 : r.isRTL(i.floating)), o = ye(n), s = be(n), c = G(n) === "y", l = Ue.has(o) ? -1 : 1, u = a && c ? -1 : 1, d = ve(t, e), { mainAxis: f, crossAxis: p, alignmentAxis: m } = typeof d == "number" ? {
|
|
688
688
|
mainAxis: d,
|
|
689
689
|
crossAxis: 0,
|
|
690
690
|
alignmentAxis: null
|
|
@@ -701,13 +701,13 @@ async function qe(e, t) {
|
|
|
701
701
|
y: p * u
|
|
702
702
|
};
|
|
703
703
|
}
|
|
704
|
-
var
|
|
704
|
+
var Ge = function(e) {
|
|
705
705
|
return e === void 0 && (e = 0), {
|
|
706
706
|
name: "offset",
|
|
707
707
|
options: e,
|
|
708
708
|
async fn(t) {
|
|
709
709
|
var n;
|
|
710
|
-
let { x: r, y: i, placement: a, middlewareData: o } = t, s = await
|
|
710
|
+
let { x: r, y: i, placement: a, middlewareData: o } = t, s = await We(t, e);
|
|
711
711
|
return a === o.offset?.placement && (n = o.arrow) != null && n.alignmentOffset ? {} : {
|
|
712
712
|
x: r + s.x,
|
|
713
713
|
y: i + s.y,
|
|
@@ -718,7 +718,7 @@ var Je = function(e) {
|
|
|
718
718
|
};
|
|
719
719
|
}
|
|
720
720
|
};
|
|
721
|
-
},
|
|
721
|
+
}, Ke = function(e) {
|
|
722
722
|
return e === void 0 && (e = {}), {
|
|
723
723
|
name: "shift",
|
|
724
724
|
options: e,
|
|
@@ -729,10 +729,10 @@ var Je = function(e) {
|
|
|
729
729
|
x: t,
|
|
730
730
|
y: n
|
|
731
731
|
};
|
|
732
|
-
} }, ...l } =
|
|
732
|
+
} }, ...l } = ve(e, t), u = {
|
|
733
733
|
x: n,
|
|
734
734
|
y: r
|
|
735
|
-
}, d = await a.detectOverflow(t, l), f =
|
|
735
|
+
}, d = await a.detectOverflow(t, l), f = G(i), p = xe(f), m = u[p], h = u[f], g = (e, t) => _e(t + d[e === "y" ? "top" : "left"], t, t - d[e === "y" ? "bottom" : "right"]);
|
|
736
736
|
o && (m = g(p, m)), s && (h = g(f, h));
|
|
737
737
|
let _ = c.fn({
|
|
738
738
|
...t,
|
|
@@ -755,39 +755,39 @@ var Je = function(e) {
|
|
|
755
755
|
};
|
|
756
756
|
//#endregion
|
|
757
757
|
//#region node_modules/.pnpm/@floating-ui+utils@0.2.12/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs
|
|
758
|
-
function
|
|
758
|
+
function qe() {
|
|
759
759
|
return typeof window < "u";
|
|
760
760
|
}
|
|
761
|
-
function
|
|
762
|
-
return
|
|
761
|
+
function Je(e) {
|
|
762
|
+
return Ye(e) ? (e.nodeName || "").toLowerCase() : "#document";
|
|
763
763
|
}
|
|
764
|
-
function
|
|
764
|
+
function K(e) {
|
|
765
765
|
var t;
|
|
766
766
|
return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
|
|
767
767
|
}
|
|
768
|
-
function K(e) {
|
|
769
|
-
return ((Qe(e) ? e.ownerDocument : e.document) || window.document)?.documentElement;
|
|
770
|
-
}
|
|
771
|
-
function Qe(e) {
|
|
772
|
-
return Xe() ? e instanceof Node || e instanceof G(e).Node : !1;
|
|
773
|
-
}
|
|
774
768
|
function q(e) {
|
|
775
|
-
return
|
|
769
|
+
return ((Ye(e) ? e.ownerDocument : e.document) || window.document)?.documentElement;
|
|
770
|
+
}
|
|
771
|
+
function Ye(e) {
|
|
772
|
+
return qe() ? e instanceof Node || e instanceof K(e).Node : !1;
|
|
776
773
|
}
|
|
777
774
|
function J(e) {
|
|
778
|
-
return
|
|
775
|
+
return qe() ? e instanceof Element || e instanceof K(e).Element : !1;
|
|
779
776
|
}
|
|
780
|
-
function
|
|
781
|
-
return
|
|
777
|
+
function Y(e) {
|
|
778
|
+
return qe() ? e instanceof HTMLElement || e instanceof K(e).HTMLElement : !1;
|
|
779
|
+
}
|
|
780
|
+
function Xe(e) {
|
|
781
|
+
return !qe() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof K(e).ShadowRoot;
|
|
782
782
|
}
|
|
783
|
-
function
|
|
784
|
-
let { overflow: t, overflowX: n, overflowY: r, display: i } =
|
|
783
|
+
function Ze(e) {
|
|
784
|
+
let { overflow: t, overflowX: n, overflowY: r, display: i } = Z(e);
|
|
785
785
|
return /auto|scroll|overlay|hidden|clip/.test(t + r + n) && i !== "inline" && i !== "contents";
|
|
786
786
|
}
|
|
787
|
-
function
|
|
788
|
-
return /^(table|td|th)$/.test(
|
|
787
|
+
function Qe(e) {
|
|
788
|
+
return /^(table|td|th)$/.test(Je(e));
|
|
789
789
|
}
|
|
790
|
-
function
|
|
790
|
+
function $e(e) {
|
|
791
791
|
try {
|
|
792
792
|
if (e.matches(":popover-open")) return !0;
|
|
793
793
|
} catch {}
|
|
@@ -797,31 +797,31 @@ function nt(e) {
|
|
|
797
797
|
return !1;
|
|
798
798
|
}
|
|
799
799
|
}
|
|
800
|
-
var
|
|
801
|
-
function
|
|
802
|
-
let t =
|
|
803
|
-
return
|
|
804
|
-
}
|
|
805
|
-
function
|
|
806
|
-
let t =
|
|
807
|
-
for (;
|
|
808
|
-
if (
|
|
809
|
-
if (
|
|
810
|
-
t =
|
|
800
|
+
var et = /transform|translate|scale|rotate|perspective|filter/, tt = /paint|layout|strict|content/, X = (e) => !!e && e !== "none", nt;
|
|
801
|
+
function rt(e) {
|
|
802
|
+
let t = J(e) ? Z(e) : e;
|
|
803
|
+
return X(t.transform) || X(t.translate) || X(t.scale) || X(t.rotate) || X(t.perspective) || !at() && (X(t.backdropFilter) || X(t.filter)) || et.test(t.willChange || "") || tt.test(t.contain || "");
|
|
804
|
+
}
|
|
805
|
+
function it(e) {
|
|
806
|
+
let t = Q(e);
|
|
807
|
+
for (; Y(t) && !ot(t);) {
|
|
808
|
+
if (rt(t)) return t;
|
|
809
|
+
if ($e(t)) return null;
|
|
810
|
+
t = Q(t);
|
|
811
811
|
}
|
|
812
812
|
return null;
|
|
813
813
|
}
|
|
814
|
-
function
|
|
815
|
-
return
|
|
814
|
+
function at() {
|
|
815
|
+
return nt ??= typeof CSS < "u" && CSS.supports && CSS.supports("-webkit-backdrop-filter", "none"), nt;
|
|
816
816
|
}
|
|
817
|
-
function
|
|
818
|
-
return /^(html|body|#document)$/.test(
|
|
817
|
+
function ot(e) {
|
|
818
|
+
return /^(html|body|#document)$/.test(Je(e));
|
|
819
819
|
}
|
|
820
|
-
function
|
|
821
|
-
return
|
|
820
|
+
function Z(e) {
|
|
821
|
+
return K(e).getComputedStyle(e);
|
|
822
822
|
}
|
|
823
|
-
function
|
|
824
|
-
return
|
|
823
|
+
function st(e) {
|
|
824
|
+
return J(e) ? {
|
|
825
825
|
scrollLeft: e.scrollLeft,
|
|
826
826
|
scrollTop: e.scrollTop
|
|
827
827
|
} : {
|
|
@@ -829,102 +829,102 @@ function ut(e) {
|
|
|
829
829
|
scrollTop: e.scrollY
|
|
830
830
|
};
|
|
831
831
|
}
|
|
832
|
-
function
|
|
833
|
-
if (
|
|
834
|
-
let t = e.assignedSlot || e.parentNode ||
|
|
835
|
-
return
|
|
832
|
+
function Q(e) {
|
|
833
|
+
if (Je(e) === "html") return e;
|
|
834
|
+
let t = e.assignedSlot || e.parentNode || Xe(e) && e.host || q(e);
|
|
835
|
+
return Xe(t) ? t.host : t;
|
|
836
836
|
}
|
|
837
|
-
function
|
|
838
|
-
let t =
|
|
839
|
-
return
|
|
837
|
+
function ct(e) {
|
|
838
|
+
let t = Q(e);
|
|
839
|
+
return ot(t) ? (e.ownerDocument || e).body : Y(t) && Ze(t) ? t : ct(t);
|
|
840
840
|
}
|
|
841
|
-
function
|
|
841
|
+
function lt(e, t, n) {
|
|
842
842
|
t === void 0 && (t = []), n === void 0 && (n = !0);
|
|
843
|
-
let r =
|
|
843
|
+
let r = ct(e), i = r === e.ownerDocument?.body, a = K(r);
|
|
844
844
|
if (i) {
|
|
845
|
-
let e =
|
|
846
|
-
return t.concat(a, a.visualViewport || [],
|
|
845
|
+
let e = ut(a);
|
|
846
|
+
return t.concat(a, a.visualViewport || [], Ze(r) ? r : [], e && n ? lt(e) : []);
|
|
847
847
|
}
|
|
848
|
-
return t.concat(r,
|
|
848
|
+
return t.concat(r, lt(r, [], n));
|
|
849
849
|
}
|
|
850
|
-
function
|
|
850
|
+
function ut(e) {
|
|
851
851
|
return e.parent && Object.getPrototypeOf(e.parent) ? e.frameElement : null;
|
|
852
852
|
}
|
|
853
853
|
//#endregion
|
|
854
854
|
//#region node_modules/.pnpm/@floating-ui+dom@1.8.0/node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs
|
|
855
|
-
function
|
|
856
|
-
let t =
|
|
855
|
+
function dt(e) {
|
|
856
|
+
let t = Z(e), n = parseFloat(t.width) || 0, r = parseFloat(t.height) || 0, i = Y(e), a = i ? e.offsetWidth : n, o = i ? e.offsetHeight : r, s = me(n) !== a || me(r) !== o;
|
|
857
857
|
return s && (n = a, r = o), {
|
|
858
858
|
width: n,
|
|
859
859
|
height: r,
|
|
860
860
|
$: s
|
|
861
861
|
};
|
|
862
862
|
}
|
|
863
|
-
function
|
|
864
|
-
return
|
|
863
|
+
function ft(e) {
|
|
864
|
+
return J(e) ? e : e.contextElement;
|
|
865
865
|
}
|
|
866
|
-
function
|
|
867
|
-
let t =
|
|
868
|
-
if (!
|
|
869
|
-
let n = t.getBoundingClientRect(), { width: r, height: i, $: a } =
|
|
866
|
+
function pt(e) {
|
|
867
|
+
let t = ft(e);
|
|
868
|
+
if (!Y(t)) return W(1);
|
|
869
|
+
let n = t.getBoundingClientRect(), { width: r, height: i, $: a } = dt(t), o = (a ? me(n.width) : n.width) / r, s = (a ? me(n.height) : n.height) / i;
|
|
870
870
|
return (!o || !Number.isFinite(o)) && (o = 1), (!s || !Number.isFinite(s)) && (s = 1), {
|
|
871
871
|
x: o,
|
|
872
872
|
y: s
|
|
873
873
|
};
|
|
874
874
|
}
|
|
875
|
-
var
|
|
876
|
-
function
|
|
877
|
-
let t =
|
|
878
|
-
return !
|
|
875
|
+
var mt = /*#__PURE__*/ W(0);
|
|
876
|
+
function ht(e) {
|
|
877
|
+
let t = K(e);
|
|
878
|
+
return !at() || !t.visualViewport ? mt : {
|
|
879
879
|
x: t.visualViewport.offsetLeft,
|
|
880
880
|
y: t.visualViewport.offsetTop
|
|
881
881
|
};
|
|
882
882
|
}
|
|
883
|
-
function
|
|
884
|
-
return t === void 0 && (t = !1), !!n && t && n ===
|
|
883
|
+
function gt(e, t, n) {
|
|
884
|
+
return t === void 0 && (t = !1), !!n && t && n === K(e);
|
|
885
885
|
}
|
|
886
886
|
function $(e, t, n, r) {
|
|
887
887
|
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
888
|
-
let i = e.getBoundingClientRect(), a =
|
|
889
|
-
t && (r ?
|
|
890
|
-
let s =
|
|
888
|
+
let i = e.getBoundingClientRect(), a = ft(e), o = W(1);
|
|
889
|
+
t && (r ? J(r) && (o = pt(r)) : o = pt(e));
|
|
890
|
+
let s = gt(a, n, r) ? ht(a) : W(0), c = (i.left + s.x) / o.x, l = (i.top + s.y) / o.y, u = i.width / o.x, d = i.height / o.y;
|
|
891
891
|
if (a && r) {
|
|
892
|
-
let e =
|
|
892
|
+
let e = K(a), t = J(r) ? K(r) : r, n = e, i = ut(n);
|
|
893
893
|
for (; i && t !== n;) {
|
|
894
|
-
let e =
|
|
895
|
-
c *= e.x, l *= e.y, u *= e.x, d *= e.y, c += a, l += o, n =
|
|
894
|
+
let e = pt(i), t = i.getBoundingClientRect(), r = Z(i), a = t.left + (i.clientLeft + parseFloat(r.paddingLeft)) * e.x, o = t.top + (i.clientTop + parseFloat(r.paddingTop)) * e.y;
|
|
895
|
+
c *= e.x, l *= e.y, u *= e.x, d *= e.y, c += a, l += o, n = K(i), i = ut(n);
|
|
896
896
|
}
|
|
897
897
|
}
|
|
898
|
-
return
|
|
898
|
+
return Ie({
|
|
899
899
|
width: u,
|
|
900
900
|
height: d,
|
|
901
901
|
x: c,
|
|
902
902
|
y: l
|
|
903
903
|
});
|
|
904
904
|
}
|
|
905
|
-
function
|
|
906
|
-
let n =
|
|
907
|
-
return t ? t.left + n : $(
|
|
905
|
+
function _t(e, t) {
|
|
906
|
+
let n = st(e).scrollLeft;
|
|
907
|
+
return t ? t.left + n : $(q(e)).left + n;
|
|
908
908
|
}
|
|
909
|
-
function
|
|
909
|
+
function vt(e, t) {
|
|
910
910
|
let n = e.getBoundingClientRect();
|
|
911
911
|
return {
|
|
912
|
-
x: n.left + t.scrollLeft -
|
|
912
|
+
x: n.left + t.scrollLeft - _t(e, n),
|
|
913
913
|
y: n.top + t.scrollTop
|
|
914
914
|
};
|
|
915
915
|
}
|
|
916
|
-
function
|
|
917
|
-
let { elements: t, rect: n, offsetParent: r, strategy: i } = e, a = i === "fixed", o =
|
|
916
|
+
function yt(e) {
|
|
917
|
+
let { elements: t, rect: n, offsetParent: r, strategy: i } = e, a = i === "fixed", o = q(r), s = t ? $e(t.floating) : !1;
|
|
918
918
|
if (r === o || s && a) return n;
|
|
919
919
|
let c = {
|
|
920
920
|
scrollLeft: 0,
|
|
921
921
|
scrollTop: 0
|
|
922
|
-
}, l =
|
|
923
|
-
if ((d || !a) && ((
|
|
922
|
+
}, l = W(1), u = W(0), d = Y(r);
|
|
923
|
+
if ((d || !a) && ((Je(r) !== "body" || Ze(o)) && (c = st(r)), d)) {
|
|
924
924
|
let e = $(r);
|
|
925
|
-
l =
|
|
925
|
+
l = pt(r), u.x = e.x + r.clientLeft, u.y = e.y + r.clientTop;
|
|
926
926
|
}
|
|
927
|
-
let f = o && !d && !a ?
|
|
927
|
+
let f = o && !d && !a ? vt(o, c) : W(0);
|
|
928
928
|
return {
|
|
929
929
|
width: n.width * l.x,
|
|
930
930
|
height: n.height * l.y,
|
|
@@ -932,29 +932,29 @@ function xt(e) {
|
|
|
932
932
|
y: n.y * l.y - c.scrollTop * l.y + u.y + f.y
|
|
933
933
|
};
|
|
934
934
|
}
|
|
935
|
-
function
|
|
935
|
+
function bt(e) {
|
|
936
936
|
return e.getClientRects ? Array.from(e.getClientRects()) : [];
|
|
937
937
|
}
|
|
938
|
-
function
|
|
939
|
-
let t =
|
|
940
|
-
return
|
|
938
|
+
function xt(e) {
|
|
939
|
+
let t = st(e), n = e.ownerDocument.body, r = U(e.scrollWidth, e.clientWidth, n.scrollWidth, n.clientWidth), i = U(e.scrollHeight, e.clientHeight, n.scrollHeight, n.clientHeight), a = -t.scrollLeft + _t(e), o = -t.scrollTop;
|
|
940
|
+
return Z(n).direction === "rtl" && (a += U(e.clientWidth, n.clientWidth) - r), {
|
|
941
941
|
width: r,
|
|
942
942
|
height: i,
|
|
943
943
|
x: a,
|
|
944
944
|
y: o
|
|
945
945
|
};
|
|
946
946
|
}
|
|
947
|
-
var
|
|
948
|
-
function
|
|
947
|
+
var St = 25;
|
|
948
|
+
function Ct(e, t, n) {
|
|
949
949
|
n === void 0 && (n = "viewport");
|
|
950
|
-
let r = n === "layoutViewport", i =
|
|
950
|
+
let r = n === "layoutViewport", i = K(e), a = q(e), o = i.visualViewport, s = a.clientWidth, c = a.clientHeight, l = 0, u = 0;
|
|
951
951
|
if (o) {
|
|
952
|
-
let e = !
|
|
952
|
+
let e = !at() || t === "fixed";
|
|
953
953
|
r ? e || (l = -o.offsetLeft, u = -o.offsetTop) : (s = o.width, c = o.height, e && (l = o.offsetLeft, u = o.offsetTop));
|
|
954
954
|
}
|
|
955
|
-
if (
|
|
955
|
+
if (_t(a) <= 0) {
|
|
956
956
|
let e = a.ownerDocument, t = e.body, n = getComputedStyle(t), r = e.compatMode === "CSS1Compat" && parseFloat(n.marginLeft) + parseFloat(n.marginRight) || 0, i = Math.abs(a.clientWidth - t.clientWidth - r), o = getComputedStyle(a).scrollbarGutter === "stable both-edges" ? i / 2 : i;
|
|
957
|
-
o <=
|
|
957
|
+
o <= St && (s -= o);
|
|
958
958
|
}
|
|
959
959
|
return {
|
|
960
960
|
width: s,
|
|
@@ -963,8 +963,8 @@ function Tt(e, t, n) {
|
|
|
963
963
|
y: u
|
|
964
964
|
};
|
|
965
965
|
}
|
|
966
|
-
function
|
|
967
|
-
let n = $(e, !0, t === "fixed"), r = n.top + e.clientTop, i = n.left + e.clientLeft, a =
|
|
966
|
+
function wt(e, t) {
|
|
967
|
+
let n = $(e, !0, t === "fixed"), r = n.top + e.clientTop, i = n.left + e.clientLeft, a = pt(e);
|
|
968
968
|
return {
|
|
969
969
|
width: e.clientWidth * a.x,
|
|
970
970
|
height: e.clientHeight * a.y,
|
|
@@ -972,13 +972,13 @@ function Et(e, t) {
|
|
|
972
972
|
y: r * a.y
|
|
973
973
|
};
|
|
974
974
|
}
|
|
975
|
-
function
|
|
975
|
+
function Tt(e, t, n) {
|
|
976
976
|
let r;
|
|
977
|
-
if (t === "viewport" || t === "layoutViewport") r =
|
|
978
|
-
else if (t === "document") r =
|
|
979
|
-
else if (
|
|
977
|
+
if (t === "viewport" || t === "layoutViewport") r = Ct(e, n, t);
|
|
978
|
+
else if (t === "document") r = xt(q(e));
|
|
979
|
+
else if (J(t)) r = wt(t, n);
|
|
980
980
|
else {
|
|
981
|
-
let n =
|
|
981
|
+
let n = ht(e);
|
|
982
982
|
r = {
|
|
983
983
|
x: t.x - n.x,
|
|
984
984
|
y: t.y - n.y,
|
|
@@ -986,23 +986,23 @@ function Dt(e, t, n) {
|
|
|
986
986
|
height: t.height
|
|
987
987
|
};
|
|
988
988
|
}
|
|
989
|
-
return
|
|
989
|
+
return Ie(r);
|
|
990
990
|
}
|
|
991
|
-
function
|
|
991
|
+
function Et(e, t) {
|
|
992
992
|
let n = t.get(e);
|
|
993
993
|
if (n) return n;
|
|
994
|
-
let r =
|
|
995
|
-
for (;
|
|
996
|
-
let e =
|
|
997
|
-
!t && (n === "fixed" || n === "absolute" && e.position === "static") ? r = r.filter((e) => e !== o) : i = e, o =
|
|
994
|
+
let r = lt(e, [], !1).filter((e) => J(e) && Je(e) !== "body"), i = null, a = Z(e).position === "fixed", o = a ? Q(e) : e;
|
|
995
|
+
for (; J(o) && !ot(o);) {
|
|
996
|
+
let e = Z(o), t = rt(o), n = i ? i.position : a ? "fixed" : "";
|
|
997
|
+
!t && (n === "fixed" || n === "absolute" && e.position === "static") ? r = r.filter((e) => e !== o) : i = e, o = Q(o);
|
|
998
998
|
}
|
|
999
999
|
return t.set(e, r), r;
|
|
1000
1000
|
}
|
|
1001
|
-
function
|
|
1002
|
-
let { element: t, boundary: n, rootBoundary: r, strategy: i } = e, a = [...n === "clippingAncestors" ?
|
|
1001
|
+
function Dt(e) {
|
|
1002
|
+
let { element: t, boundary: n, rootBoundary: r, strategy: i } = e, a = [...n === "clippingAncestors" ? $e(t) ? [] : Et(t, this._c) : [].concat(n), r], o = Tt(t, a[0], i), s = o.top, c = o.right, l = o.bottom, u = o.left;
|
|
1003
1003
|
for (let e = 1; e < a.length; e++) {
|
|
1004
|
-
let n =
|
|
1005
|
-
s =
|
|
1004
|
+
let n = Tt(t, a[e], i);
|
|
1005
|
+
s = U(n.top, s), c = pe(n.right, c), l = pe(n.bottom, l), u = U(n.left, u);
|
|
1006
1006
|
}
|
|
1007
1007
|
return {
|
|
1008
1008
|
width: c - u,
|
|
@@ -1011,24 +1011,24 @@ function kt(e) {
|
|
|
1011
1011
|
y: s
|
|
1012
1012
|
};
|
|
1013
1013
|
}
|
|
1014
|
-
function
|
|
1015
|
-
let { width: t, height: n } =
|
|
1014
|
+
function Ot(e) {
|
|
1015
|
+
let { width: t, height: n } = dt(e);
|
|
1016
1016
|
return {
|
|
1017
1017
|
width: t,
|
|
1018
1018
|
height: n
|
|
1019
1019
|
};
|
|
1020
1020
|
}
|
|
1021
|
-
function
|
|
1022
|
-
let r =
|
|
1021
|
+
function kt(e, t, n) {
|
|
1022
|
+
let r = Y(t), i = q(t), a = n === "fixed", o = $(e, !0, a, t), s = {
|
|
1023
1023
|
scrollLeft: 0,
|
|
1024
1024
|
scrollTop: 0
|
|
1025
|
-
}, c =
|
|
1026
|
-
if ((r || !a) && ((
|
|
1025
|
+
}, c = W(0);
|
|
1026
|
+
if ((r || !a) && ((Je(t) !== "body" || Ze(i)) && (s = st(t)), r)) {
|
|
1027
1027
|
let e = $(t, !0, a, t);
|
|
1028
1028
|
c.x = e.x + t.clientLeft, c.y = e.y + t.clientTop;
|
|
1029
1029
|
}
|
|
1030
|
-
!r && i && (c.x =
|
|
1031
|
-
let l = i && !r && !a ?
|
|
1030
|
+
!r && i && (c.x = _t(i));
|
|
1031
|
+
let l = i && !r && !a ? vt(i, s) : W(0);
|
|
1032
1032
|
return {
|
|
1033
1033
|
x: o.left + s.scrollLeft - c.x - l.x,
|
|
1034
1034
|
y: o.top + s.scrollTop - c.y - l.y,
|
|
@@ -1036,34 +1036,34 @@ function jt(e, t, n) {
|
|
|
1036
1036
|
height: o.height
|
|
1037
1037
|
};
|
|
1038
1038
|
}
|
|
1039
|
-
function
|
|
1040
|
-
return
|
|
1039
|
+
function At(e) {
|
|
1040
|
+
return Z(e).position === "static";
|
|
1041
1041
|
}
|
|
1042
|
-
function
|
|
1043
|
-
if (!
|
|
1042
|
+
function jt(e, t) {
|
|
1043
|
+
if (!Y(e) || Z(e).position === "fixed") return null;
|
|
1044
1044
|
if (t) return t(e);
|
|
1045
1045
|
let n = e.offsetParent;
|
|
1046
|
-
return
|
|
1047
|
-
}
|
|
1048
|
-
function
|
|
1049
|
-
let n =
|
|
1050
|
-
if (
|
|
1051
|
-
if (!
|
|
1052
|
-
let t =
|
|
1053
|
-
for (; t && !
|
|
1054
|
-
if (
|
|
1055
|
-
t =
|
|
1046
|
+
return q(e) === n && (n = n.ownerDocument.body), n;
|
|
1047
|
+
}
|
|
1048
|
+
function Mt(e, t) {
|
|
1049
|
+
let n = K(e);
|
|
1050
|
+
if ($e(e)) return n;
|
|
1051
|
+
if (!Y(e)) {
|
|
1052
|
+
let t = Q(e);
|
|
1053
|
+
for (; t && !ot(t);) {
|
|
1054
|
+
if (J(t) && !At(t)) return t;
|
|
1055
|
+
t = Q(t);
|
|
1056
1056
|
}
|
|
1057
1057
|
return n;
|
|
1058
1058
|
}
|
|
1059
|
-
let r =
|
|
1060
|
-
for (; r &&
|
|
1061
|
-
return r &&
|
|
1059
|
+
let r = jt(e, t);
|
|
1060
|
+
for (; r && Qe(r) && At(r);) r = jt(r, t);
|
|
1061
|
+
return r && ot(r) && At(r) && !rt(r) ? n : r || it(e) || n;
|
|
1062
1062
|
}
|
|
1063
|
-
var
|
|
1064
|
-
let t = this.getOffsetParent ||
|
|
1063
|
+
var Nt = async function(e) {
|
|
1064
|
+
let t = this.getOffsetParent || Mt, n = this.getDimensions, r = await n(e.floating);
|
|
1065
1065
|
return {
|
|
1066
|
-
reference:
|
|
1066
|
+
reference: kt(e.reference, await t(e.floating), e.strategy),
|
|
1067
1067
|
floating: {
|
|
1068
1068
|
x: 0,
|
|
1069
1069
|
y: 0,
|
|
@@ -1072,26 +1072,26 @@ var Ft = async function(e) {
|
|
|
1072
1072
|
}
|
|
1073
1073
|
};
|
|
1074
1074
|
};
|
|
1075
|
-
function
|
|
1076
|
-
return
|
|
1077
|
-
}
|
|
1078
|
-
var
|
|
1079
|
-
convertOffsetParentRelativeRectToViewportRelativeRect:
|
|
1080
|
-
getDocumentElement:
|
|
1081
|
-
getClippingRect:
|
|
1082
|
-
getOffsetParent:
|
|
1083
|
-
getElementRects:
|
|
1084
|
-
getClientRects:
|
|
1085
|
-
getDimensions:
|
|
1086
|
-
getScale:
|
|
1087
|
-
isElement:
|
|
1088
|
-
isRTL:
|
|
1075
|
+
function Pt(e) {
|
|
1076
|
+
return Z(e).direction === "rtl";
|
|
1077
|
+
}
|
|
1078
|
+
var Ft = {
|
|
1079
|
+
convertOffsetParentRelativeRectToViewportRelativeRect: yt,
|
|
1080
|
+
getDocumentElement: q,
|
|
1081
|
+
getClippingRect: Dt,
|
|
1082
|
+
getOffsetParent: Mt,
|
|
1083
|
+
getElementRects: Nt,
|
|
1084
|
+
getClientRects: bt,
|
|
1085
|
+
getDimensions: Ot,
|
|
1086
|
+
getScale: pt,
|
|
1087
|
+
isElement: J,
|
|
1088
|
+
isRTL: Pt
|
|
1089
1089
|
};
|
|
1090
|
-
function
|
|
1090
|
+
function It(e, t) {
|
|
1091
1091
|
return e.x === t.x && e.y === t.y && e.width === t.width && e.height === t.height;
|
|
1092
1092
|
}
|
|
1093
|
-
function
|
|
1094
|
-
let r = null, i, a =
|
|
1093
|
+
function Lt(e, t, n) {
|
|
1094
|
+
let r = null, i, a = q(e);
|
|
1095
1095
|
function o() {
|
|
1096
1096
|
var e;
|
|
1097
1097
|
clearTimeout(i), (e = r) == null || e.disconnect(), r = null;
|
|
@@ -1100,13 +1100,13 @@ function zt(e, t, n) {
|
|
|
1100
1100
|
n === void 0 && (n = !1), c === void 0 && (c = 1), o();
|
|
1101
1101
|
let l = e.getBoundingClientRect(), { left: u, top: d, width: f, height: p } = l;
|
|
1102
1102
|
if (n || t(), !f || !p) return;
|
|
1103
|
-
let m =
|
|
1103
|
+
let m = he(d), h = he(a.clientWidth - (u + f)), g = he(a.clientHeight - (d + p)), _ = he(u), v = {
|
|
1104
1104
|
rootMargin: -m + "px " + -h + "px " + -g + "px " + -_ + "px",
|
|
1105
|
-
threshold:
|
|
1105
|
+
threshold: U(0, pe(1, c)) || 1
|
|
1106
1106
|
}, y = !0;
|
|
1107
1107
|
function b(t) {
|
|
1108
1108
|
let n = t[0].intersectionRatio;
|
|
1109
|
-
if (!
|
|
1109
|
+
if (!It(l, e.getBoundingClientRect())) return s();
|
|
1110
1110
|
if (n !== c) {
|
|
1111
1111
|
if (!y) return s();
|
|
1112
1112
|
n ? s(!1, n) : i = setTimeout(() => {
|
|
@@ -1125,18 +1125,18 @@ function zt(e, t, n) {
|
|
|
1125
1125
|
}
|
|
1126
1126
|
r.observe(e);
|
|
1127
1127
|
}
|
|
1128
|
-
let c =
|
|
1128
|
+
let c = K(e), l = () => s(n);
|
|
1129
1129
|
return c.addEventListener("resize", l), s(!0), () => {
|
|
1130
1130
|
c.removeEventListener("resize", l), o();
|
|
1131
1131
|
};
|
|
1132
1132
|
}
|
|
1133
|
-
function
|
|
1133
|
+
function Rt(e, t, n, r) {
|
|
1134
1134
|
r === void 0 && (r = {});
|
|
1135
|
-
let { ancestorScroll: i = !0, ancestorResize: a = !0, elementResize: o = typeof ResizeObserver == "function", layoutShift: s = typeof IntersectionObserver == "function", animationFrame: c = !1 } = r, l =
|
|
1135
|
+
let { ancestorScroll: i = !0, ancestorResize: a = !0, elementResize: o = typeof ResizeObserver == "function", layoutShift: s = typeof IntersectionObserver == "function", animationFrame: c = !1 } = r, l = ft(e), u = i || a ? [...l ? lt(l) : [], ...t ? lt(t) : []] : [];
|
|
1136
1136
|
u.forEach((e) => {
|
|
1137
1137
|
i && e.addEventListener("scroll", n), a && e.addEventListener("resize", n);
|
|
1138
1138
|
});
|
|
1139
|
-
let d = l && s ?
|
|
1139
|
+
let d = l && s ? Lt(l, n, a) : null, f = -1, p = null;
|
|
1140
1140
|
o && (p = new ResizeObserver((e) => {
|
|
1141
1141
|
let [r] = e;
|
|
1142
1142
|
r && r.target === l && p && t && (p.unobserve(t), cancelAnimationFrame(f), f = requestAnimationFrame(() => {
|
|
@@ -1148,7 +1148,7 @@ function Bt(e, t, n, r) {
|
|
|
1148
1148
|
c && g();
|
|
1149
1149
|
function g() {
|
|
1150
1150
|
let t = $(e);
|
|
1151
|
-
h && !
|
|
1151
|
+
h && !It(h, t) && n(), h = t, m = requestAnimationFrame(g);
|
|
1152
1152
|
}
|
|
1153
1153
|
return n(), () => {
|
|
1154
1154
|
var e;
|
|
@@ -1157,18 +1157,18 @@ function Bt(e, t, n, r) {
|
|
|
1157
1157
|
}), d?.(), (e = p) == null || e.disconnect(), p = null, c && cancelAnimationFrame(m);
|
|
1158
1158
|
};
|
|
1159
1159
|
}
|
|
1160
|
-
var
|
|
1160
|
+
var zt = Ge, Bt = Ke, Vt = He, Ht = Ve, Ut = (e, t, n) => {
|
|
1161
1161
|
let r = /* @__PURE__ */ new Map(), i = n ?? {}, a = {
|
|
1162
|
-
...
|
|
1162
|
+
...Ft,
|
|
1163
1163
|
...i.platform,
|
|
1164
1164
|
_c: r
|
|
1165
1165
|
};
|
|
1166
|
-
return
|
|
1166
|
+
return Be(e, t, {
|
|
1167
1167
|
...i,
|
|
1168
1168
|
platform: a
|
|
1169
1169
|
});
|
|
1170
|
-
},
|
|
1171
|
-
function
|
|
1170
|
+
}, Wt = typeof document < "u" ? p : function() {};
|
|
1171
|
+
function Gt(e, t) {
|
|
1172
1172
|
if (e === t) return !0;
|
|
1173
1173
|
if (typeof e != typeof t) return !1;
|
|
1174
1174
|
if (typeof e == "function" && e.toString() === t.toString()) return !0;
|
|
@@ -1176,33 +1176,33 @@ function qt(e, t) {
|
|
|
1176
1176
|
if (e && t && typeof e == "object") {
|
|
1177
1177
|
if (Array.isArray(e)) {
|
|
1178
1178
|
if (n = e.length, n !== t.length) return !1;
|
|
1179
|
-
for (r = n; r-- !== 0;) if (!
|
|
1179
|
+
for (r = n; r-- !== 0;) if (!Gt(e[r], t[r])) return !1;
|
|
1180
1180
|
return !0;
|
|
1181
1181
|
}
|
|
1182
1182
|
if (i = Object.keys(e), n = i.length, n !== Object.keys(t).length) return !1;
|
|
1183
1183
|
for (r = n; r-- !== 0;) if (!{}.hasOwnProperty.call(t, i[r])) return !1;
|
|
1184
1184
|
for (r = n; r-- !== 0;) {
|
|
1185
1185
|
let n = i[r];
|
|
1186
|
-
if (!(n === "_owner" && e.$$typeof) && !
|
|
1186
|
+
if (!(n === "_owner" && e.$$typeof) && !Gt(e[n], t[n])) return !1;
|
|
1187
1187
|
}
|
|
1188
1188
|
return !0;
|
|
1189
1189
|
}
|
|
1190
1190
|
return e !== e && t !== t;
|
|
1191
1191
|
}
|
|
1192
|
-
function
|
|
1192
|
+
function Kt(e) {
|
|
1193
1193
|
return typeof window > "u" ? 1 : (e.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
1194
1194
|
}
|
|
1195
|
-
function
|
|
1196
|
-
let n =
|
|
1195
|
+
function qt(e, t) {
|
|
1196
|
+
let n = Kt(e);
|
|
1197
1197
|
return Math.round(t * n) / n;
|
|
1198
1198
|
}
|
|
1199
|
-
function
|
|
1199
|
+
function Jt(e) {
|
|
1200
1200
|
let t = r.useRef(e);
|
|
1201
|
-
return
|
|
1201
|
+
return Wt(() => {
|
|
1202
1202
|
t.current = e;
|
|
1203
1203
|
}), t;
|
|
1204
1204
|
}
|
|
1205
|
-
function
|
|
1205
|
+
function Yt(e) {
|
|
1206
1206
|
e === void 0 && (e = {});
|
|
1207
1207
|
let { placement: t = "bottom", strategy: n = "absolute", middleware: i = [], platform: a, elements: { reference: o, floating: s } = {}, transform: c = !0, whileElementsMounted: l, open: u } = e, [d, f] = r.useState({
|
|
1208
1208
|
x: 0,
|
|
@@ -1212,24 +1212,24 @@ function Zt(e) {
|
|
|
1212
1212
|
middlewareData: {},
|
|
1213
1213
|
isPositioned: !1
|
|
1214
1214
|
}), [p, m] = r.useState(i);
|
|
1215
|
-
|
|
1216
|
-
let [h, g] = r.useState(null), [_,
|
|
1215
|
+
Gt(p, i) || m(i);
|
|
1216
|
+
let [h, g] = r.useState(null), [_, y] = r.useState(null), b = r.useCallback((e) => {
|
|
1217
1217
|
e !== w.current && (w.current = e, g(e));
|
|
1218
1218
|
}, []), x = r.useCallback((e) => {
|
|
1219
|
-
e !== T.current && (T.current = e,
|
|
1220
|
-
}, []), S = o || h, C = s || _, w = r.useRef(null), T = r.useRef(null), E = r.useRef(d), D = l != null, O =
|
|
1219
|
+
e !== T.current && (T.current = e, y(e));
|
|
1220
|
+
}, []), S = o || h, C = s || _, w = r.useRef(null), T = r.useRef(null), E = r.useRef(d), D = l != null, O = Jt(l), k = Jt(a), A = Jt(u), j = r.useCallback(() => {
|
|
1221
1221
|
if (!w.current || !T.current) return;
|
|
1222
1222
|
let e = {
|
|
1223
1223
|
placement: t,
|
|
1224
1224
|
strategy: n,
|
|
1225
1225
|
middleware: p
|
|
1226
1226
|
};
|
|
1227
|
-
k.current && (e.platform = k.current),
|
|
1227
|
+
k.current && (e.platform = k.current), Ut(w.current, T.current, e).then((e) => {
|
|
1228
1228
|
let t = {
|
|
1229
1229
|
...e,
|
|
1230
1230
|
isPositioned: A.current !== !1
|
|
1231
1231
|
};
|
|
1232
|
-
M.current && !
|
|
1232
|
+
M.current && !Gt(E.current, t) && (E.current = t, v.flushSync(() => {
|
|
1233
1233
|
f(t);
|
|
1234
1234
|
}));
|
|
1235
1235
|
});
|
|
@@ -1240,16 +1240,16 @@ function Zt(e) {
|
|
|
1240
1240
|
k,
|
|
1241
1241
|
A
|
|
1242
1242
|
]);
|
|
1243
|
-
|
|
1243
|
+
Wt(() => {
|
|
1244
1244
|
u === !1 && E.current.isPositioned && (E.current.isPositioned = !1, f((e) => ({
|
|
1245
1245
|
...e,
|
|
1246
1246
|
isPositioned: !1
|
|
1247
1247
|
})));
|
|
1248
1248
|
}, [u]);
|
|
1249
1249
|
let M = r.useRef(!1);
|
|
1250
|
-
|
|
1250
|
+
Wt(() => (M.current = !0, () => {
|
|
1251
1251
|
M.current = !1;
|
|
1252
|
-
}), []),
|
|
1252
|
+
}), []), Wt(() => {
|
|
1253
1253
|
if (S && (w.current = S), C && (T.current = C), S && C) {
|
|
1254
1254
|
if (O.current) return O.current(S, C, j);
|
|
1255
1255
|
j();
|
|
@@ -1264,9 +1264,9 @@ function Zt(e) {
|
|
|
1264
1264
|
let N = r.useMemo(() => ({
|
|
1265
1265
|
reference: w,
|
|
1266
1266
|
floating: T,
|
|
1267
|
-
setReference:
|
|
1267
|
+
setReference: b,
|
|
1268
1268
|
setFloating: x
|
|
1269
|
-
}), [
|
|
1269
|
+
}), [b, x]), P = r.useMemo(() => ({
|
|
1270
1270
|
reference: S,
|
|
1271
1271
|
floating: C
|
|
1272
1272
|
}), [S, C]), F = r.useMemo(() => {
|
|
@@ -1276,11 +1276,11 @@ function Zt(e) {
|
|
|
1276
1276
|
top: 0
|
|
1277
1277
|
};
|
|
1278
1278
|
if (!P.floating) return e;
|
|
1279
|
-
let t =
|
|
1279
|
+
let t = qt(P.floating, d.x), r = qt(P.floating, d.y);
|
|
1280
1280
|
return c ? {
|
|
1281
1281
|
...e,
|
|
1282
1282
|
transform: "translate(" + t + "px, " + r + "px)",
|
|
1283
|
-
...
|
|
1283
|
+
...Kt(P.floating) >= 1.5 && { willChange: "transform" }
|
|
1284
1284
|
} : {
|
|
1285
1285
|
position: n,
|
|
1286
1286
|
left: t,
|
|
@@ -1307,7 +1307,7 @@ function Zt(e) {
|
|
|
1307
1307
|
F
|
|
1308
1308
|
]);
|
|
1309
1309
|
}
|
|
1310
|
-
var
|
|
1310
|
+
var Xt = (e) => {
|
|
1311
1311
|
function t(e) {
|
|
1312
1312
|
return {}.hasOwnProperty.call(e, "current");
|
|
1313
1313
|
}
|
|
@@ -1316,61 +1316,61 @@ var Qt = (e) => {
|
|
|
1316
1316
|
options: e,
|
|
1317
1317
|
fn(n) {
|
|
1318
1318
|
let { element: r, padding: i } = typeof e == "function" ? e(n) : e;
|
|
1319
|
-
return r && t(r) ? r.current == null ? {} :
|
|
1319
|
+
return r && t(r) ? r.current == null ? {} : Ht({
|
|
1320
1320
|
element: r.current,
|
|
1321
1321
|
padding: i
|
|
1322
|
-
}).fn(n) : r ?
|
|
1322
|
+
}).fn(n) : r ? Ht({
|
|
1323
1323
|
element: r,
|
|
1324
1324
|
padding: i
|
|
1325
1325
|
}).fn(n) : {};
|
|
1326
1326
|
}
|
|
1327
1327
|
};
|
|
1328
|
-
},
|
|
1329
|
-
let n =
|
|
1328
|
+
}, Zt = (e, t) => {
|
|
1329
|
+
let n = zt(e);
|
|
1330
1330
|
return {
|
|
1331
1331
|
name: n.name,
|
|
1332
1332
|
fn: n.fn,
|
|
1333
1333
|
options: [e, t]
|
|
1334
1334
|
};
|
|
1335
|
-
},
|
|
1336
|
-
let n =
|
|
1335
|
+
}, Qt = (e, t) => {
|
|
1336
|
+
let n = Bt(e);
|
|
1337
1337
|
return {
|
|
1338
1338
|
name: n.name,
|
|
1339
1339
|
fn: n.fn,
|
|
1340
1340
|
options: [e, t]
|
|
1341
1341
|
};
|
|
1342
|
-
},
|
|
1343
|
-
let n =
|
|
1342
|
+
}, $t = (e, t) => {
|
|
1343
|
+
let n = Vt(e);
|
|
1344
1344
|
return {
|
|
1345
1345
|
name: n.name,
|
|
1346
1346
|
fn: n.fn,
|
|
1347
1347
|
options: [e, t]
|
|
1348
1348
|
};
|
|
1349
|
-
},
|
|
1350
|
-
let n =
|
|
1349
|
+
}, en = (e, t) => {
|
|
1350
|
+
let n = Xt(e);
|
|
1351
1351
|
return {
|
|
1352
1352
|
name: n.name,
|
|
1353
1353
|
fn: n.fn,
|
|
1354
1354
|
options: [e, t]
|
|
1355
1355
|
};
|
|
1356
|
-
},
|
|
1357
|
-
function
|
|
1358
|
-
return
|
|
1356
|
+
}, tn = o(null);
|
|
1357
|
+
function nn() {
|
|
1358
|
+
return u(tn);
|
|
1359
1359
|
}
|
|
1360
1360
|
//#endregion
|
|
1361
1361
|
//#region src/components/menu/menu_surface.tsx
|
|
1362
|
-
var
|
|
1363
|
-
function
|
|
1364
|
-
let n = Array.from(e.querySelectorAll(
|
|
1362
|
+
var rn = "[role=\"menuitem\"]:not(:disabled)";
|
|
1363
|
+
function an(e, t) {
|
|
1364
|
+
let n = Array.from(e.querySelectorAll(rn));
|
|
1365
1365
|
n.length !== 0 && n[(t % n.length + n.length) % n.length]?.focus({ preventScroll: !0 });
|
|
1366
1366
|
}
|
|
1367
|
-
function
|
|
1368
|
-
let u =
|
|
1369
|
-
return
|
|
1367
|
+
function on({ setFloating: r, floatingStyles: i, isVisible: a, isPositioned: o, radius: s, onClose: c, children: l }) {
|
|
1368
|
+
let u = h(null);
|
|
1369
|
+
return d(() => {
|
|
1370
1370
|
if (!o) return;
|
|
1371
1371
|
let e = u.current;
|
|
1372
|
-
e && e.querySelector(
|
|
1373
|
-
}, [o]),
|
|
1372
|
+
e && e.querySelector(rn)?.focus({ preventScroll: !0 });
|
|
1373
|
+
}, [o]), y(/* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("div", {
|
|
1374
1374
|
className: "fixed inset-0 z-40",
|
|
1375
1375
|
onClick: c,
|
|
1376
1376
|
"aria-hidden": "true"
|
|
@@ -1386,12 +1386,12 @@ function cn({ setFloating: r, floatingStyles: i, isVisible: a, isPositioned: o,
|
|
|
1386
1386
|
onKeyDown: (e) => {
|
|
1387
1387
|
let t = u.current;
|
|
1388
1388
|
if (!t) return;
|
|
1389
|
-
let n = Array.from(t.querySelectorAll(
|
|
1390
|
-
e.key === "ArrowDown" ? (e.preventDefault(),
|
|
1389
|
+
let n = Array.from(t.querySelectorAll(rn)), r = n.indexOf(document.activeElement);
|
|
1390
|
+
e.key === "ArrowDown" ? (e.preventDefault(), an(t, r + 1)) : e.key === "ArrowUp" ? (e.preventDefault(), an(t, r - 1)) : e.key === "Home" ? (e.preventDefault(), an(t, 0)) : e.key === "End" ? (e.preventDefault(), an(t, n.length - 1)) : (e.key === "Escape" || e.key === "Tab") && c();
|
|
1391
1391
|
},
|
|
1392
|
-
className:
|
|
1392
|
+
className: x("w-max min-w-40 max-w-xs origin-top border py-1 shadow-lg backdrop-blur-sm", "transition-[opacity,transform] duration-150 ease-out", a ? "scale-100 opacity-100" : "scale-95 opacity-0", ne, te, S[s]),
|
|
1393
1393
|
onClick: (e) => e.stopPropagation(),
|
|
1394
|
-
children: /* @__PURE__ */ t(
|
|
1394
|
+
children: /* @__PURE__ */ t(tn.Provider, {
|
|
1395
1395
|
value: c,
|
|
1396
1396
|
children: l
|
|
1397
1397
|
})
|
|
@@ -1400,22 +1400,22 @@ function cn({ setFloating: r, floatingStyles: i, isVisible: a, isPositioned: o,
|
|
|
1400
1400
|
}
|
|
1401
1401
|
//#endregion
|
|
1402
1402
|
//#region src/components/shared/use_overlay_state.ts
|
|
1403
|
-
function
|
|
1404
|
-
let [e, t] =
|
|
1405
|
-
return
|
|
1403
|
+
function sn() {
|
|
1404
|
+
let [e, t] = g(!1), [n, r] = g(!1), i = h(void 0);
|
|
1405
|
+
return d(() => () => clearTimeout(i.current), []), {
|
|
1406
1406
|
isMounted: e,
|
|
1407
1407
|
isVisible: n,
|
|
1408
1408
|
setIsVisible: r,
|
|
1409
|
-
open:
|
|
1409
|
+
open: l((e) => {
|
|
1410
1410
|
clearTimeout(i.current), t(!0), e && r(!0);
|
|
1411
1411
|
}, []),
|
|
1412
|
-
close:
|
|
1412
|
+
close: l(() => {
|
|
1413
1413
|
clearTimeout(i.current), r(!1), i.current = setTimeout(() => t(!1), 150);
|
|
1414
1414
|
}, [])
|
|
1415
1415
|
};
|
|
1416
1416
|
}
|
|
1417
|
-
function
|
|
1418
|
-
|
|
1417
|
+
function cn(e, t, n) {
|
|
1418
|
+
d(() => {
|
|
1419
1419
|
if (!e || !t) return;
|
|
1420
1420
|
let r = requestAnimationFrame(() => n(!0));
|
|
1421
1421
|
return () => cancelAnimationFrame(r);
|
|
@@ -1427,8 +1427,8 @@ function un(e, t, n) {
|
|
|
1427
1427
|
}
|
|
1428
1428
|
//#endregion
|
|
1429
1429
|
//#region src/components/context_menu/context_menu.tsx
|
|
1430
|
-
var
|
|
1431
|
-
function
|
|
1430
|
+
var ln = 2;
|
|
1431
|
+
function un(e, t) {
|
|
1432
1432
|
return { getBoundingClientRect: () => ({
|
|
1433
1433
|
width: 0,
|
|
1434
1434
|
height: 0,
|
|
@@ -1440,7 +1440,7 @@ function fn(e, t) {
|
|
|
1440
1440
|
bottom: t
|
|
1441
1441
|
}) };
|
|
1442
1442
|
}
|
|
1443
|
-
function
|
|
1443
|
+
function dn(e) {
|
|
1444
1444
|
if (e.clientX !== 0 || e.clientY !== 0) return {
|
|
1445
1445
|
x: e.clientX,
|
|
1446
1446
|
y: e.clientY
|
|
@@ -1454,19 +1454,19 @@ function pn(e) {
|
|
|
1454
1454
|
y: 0
|
|
1455
1455
|
};
|
|
1456
1456
|
}
|
|
1457
|
-
function
|
|
1458
|
-
let s =
|
|
1457
|
+
function fn({ children: e, items: r, radius: i = "md", className: a, ref: o }) {
|
|
1458
|
+
let s = h(null), { isMounted: c, isVisible: u, setIsVisible: d, open: f, close: p } = sn(), { refs: m, floatingStyles: g, isPositioned: _ } = Yt({
|
|
1459
1459
|
placement: "bottom-start",
|
|
1460
1460
|
open: c,
|
|
1461
|
-
whileElementsMounted:
|
|
1461
|
+
whileElementsMounted: Rt,
|
|
1462
1462
|
middleware: [
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1463
|
+
Zt(ln),
|
|
1464
|
+
$t(),
|
|
1465
|
+
Qt({ padding: 8 })
|
|
1466
1466
|
]
|
|
1467
1467
|
});
|
|
1468
|
-
|
|
1469
|
-
let v =
|
|
1468
|
+
cn(c, _, d);
|
|
1469
|
+
let v = l(() => {
|
|
1470
1470
|
p(), s.current?.focus();
|
|
1471
1471
|
}, [p]);
|
|
1472
1472
|
return /* @__PURE__ */ n("div", {
|
|
@@ -1474,14 +1474,14 @@ function mn({ children: e, items: r, radius: i = "md", className: a, ref: o }) {
|
|
|
1474
1474
|
className: a,
|
|
1475
1475
|
onContextMenu: (e) => {
|
|
1476
1476
|
e.preventDefault(), s.current = document.activeElement;
|
|
1477
|
-
let { x: t, y: n } =
|
|
1478
|
-
m.setReference(
|
|
1477
|
+
let { x: t, y: n } = dn(e);
|
|
1478
|
+
m.setReference(un(t, n)), f(!1);
|
|
1479
1479
|
},
|
|
1480
|
-
children: [e, c && /* @__PURE__ */ t(
|
|
1480
|
+
children: [e, c && /* @__PURE__ */ t(on, {
|
|
1481
1481
|
setFloating: m.setFloating,
|
|
1482
|
-
floatingStyles:
|
|
1483
|
-
isVisible:
|
|
1484
|
-
isPositioned:
|
|
1482
|
+
floatingStyles: g,
|
|
1483
|
+
isVisible: u,
|
|
1484
|
+
isPositioned: _,
|
|
1485
1485
|
radius: i,
|
|
1486
1486
|
onClose: v,
|
|
1487
1487
|
children: r
|
|
@@ -1490,7 +1490,7 @@ function mn({ children: e, items: r, radius: i = "md", className: a, ref: o }) {
|
|
|
1490
1490
|
}
|
|
1491
1491
|
//#endregion
|
|
1492
1492
|
//#region src/lib/surface_error.ts
|
|
1493
|
-
function
|
|
1493
|
+
function pn(e, t) {
|
|
1494
1494
|
if (t) {
|
|
1495
1495
|
t(e);
|
|
1496
1496
|
return;
|
|
@@ -1501,23 +1501,23 @@ function hn(e, t) {
|
|
|
1501
1501
|
}
|
|
1502
1502
|
//#endregion
|
|
1503
1503
|
//#region src/components/copy_button/copy_button.tsx
|
|
1504
|
-
var
|
|
1505
|
-
function
|
|
1506
|
-
let [a, o] =
|
|
1507
|
-
return
|
|
1504
|
+
var mn = 2e3;
|
|
1505
|
+
function hn({ value: n, children: r, onError: i }) {
|
|
1506
|
+
let [a, o] = g(!1), s = h(void 0);
|
|
1507
|
+
return d(() => () => clearTimeout(s.current), []), /* @__PURE__ */ t(e, { children: r({
|
|
1508
1508
|
copied: a,
|
|
1509
1509
|
copy: async () => {
|
|
1510
1510
|
try {
|
|
1511
|
-
await navigator.clipboard.writeText(n), o(!0), clearTimeout(s.current), s.current = setTimeout(() => o(!1),
|
|
1511
|
+
await navigator.clipboard.writeText(n), o(!0), clearTimeout(s.current), s.current = setTimeout(() => o(!1), mn);
|
|
1512
1512
|
} catch (e) {
|
|
1513
|
-
|
|
1513
|
+
pn(e, i);
|
|
1514
1514
|
}
|
|
1515
1515
|
}
|
|
1516
1516
|
}) });
|
|
1517
1517
|
}
|
|
1518
1518
|
//#endregion
|
|
1519
1519
|
//#region src/lib/split_into_highlight_segments.ts
|
|
1520
|
-
function
|
|
1520
|
+
function gn(e, t) {
|
|
1521
1521
|
if (t.length === 0) return [{
|
|
1522
1522
|
text: e,
|
|
1523
1523
|
isMatch: !1
|
|
@@ -1540,8 +1540,8 @@ function vn(e, t) {
|
|
|
1540
1540
|
}
|
|
1541
1541
|
//#endregion
|
|
1542
1542
|
//#region src/components/highlight/highlight.tsx
|
|
1543
|
-
function
|
|
1544
|
-
let i =
|
|
1543
|
+
function _n({ text: n, ranges: r }) {
|
|
1544
|
+
let i = gn(n, r), a = 0;
|
|
1545
1545
|
return /* @__PURE__ */ t(e, { children: i.map((e) => {
|
|
1546
1546
|
let n = a;
|
|
1547
1547
|
return a += e.text.length, e.isMatch ? /* @__PURE__ */ t("mark", {
|
|
@@ -1552,44 +1552,44 @@ function yn({ text: n, ranges: r }) {
|
|
|
1552
1552
|
}
|
|
1553
1553
|
//#endregion
|
|
1554
1554
|
//#region src/components/icon_button/icon_button.tsx
|
|
1555
|
-
var
|
|
1555
|
+
var vn = {
|
|
1556
1556
|
xs: "p-1",
|
|
1557
1557
|
sm: "p-2",
|
|
1558
1558
|
md: "p-2",
|
|
1559
1559
|
lg: "p-3"
|
|
1560
|
-
},
|
|
1560
|
+
}, yn = {
|
|
1561
1561
|
xs: "w-4 h-4",
|
|
1562
1562
|
sm: "w-4 h-4",
|
|
1563
1563
|
md: "w-5 h-5",
|
|
1564
1564
|
lg: "w-6 h-6"
|
|
1565
1565
|
};
|
|
1566
|
-
function
|
|
1567
|
-
let { icon: r, "aria-label": i, unstyled: a = !1, variant: o = "outline", color: s = "neutral", size: c = "md", radius: l = "md", className: u, children: d, ref: f, ...p } = e, m =
|
|
1566
|
+
function bn(e) {
|
|
1567
|
+
let { icon: r, "aria-label": i, unstyled: a = !1, variant: o = "outline", color: s = "neutral", size: c = "md", radius: l = "md", className: u, children: d, ref: f, ...p } = e, m = O[s];
|
|
1568
1568
|
return /* @__PURE__ */ n("button", {
|
|
1569
1569
|
ref: f,
|
|
1570
1570
|
type: "button",
|
|
1571
1571
|
"aria-label": i,
|
|
1572
|
-
className:
|
|
1573
|
-
|
|
1572
|
+
className: x(k, !a && [
|
|
1573
|
+
A,
|
|
1574
1574
|
"border",
|
|
1575
|
-
|
|
1576
|
-
|
|
1575
|
+
S[l],
|
|
1576
|
+
vn[c],
|
|
1577
1577
|
m[o],
|
|
1578
1578
|
m.focusOutline
|
|
1579
1579
|
], u),
|
|
1580
1580
|
...p,
|
|
1581
|
-
children: [/* @__PURE__ */ t("div", { className:
|
|
1581
|
+
children: [/* @__PURE__ */ t("div", { className: x(r, yn[c], d && "mr-1") }), d]
|
|
1582
1582
|
});
|
|
1583
1583
|
}
|
|
1584
1584
|
//#endregion
|
|
1585
1585
|
//#region src/components/shared/use_controlled_length.ts
|
|
1586
|
-
function
|
|
1586
|
+
function xn(e) {
|
|
1587
1587
|
return typeof e == "string" ? e.length : 0;
|
|
1588
1588
|
}
|
|
1589
|
-
function
|
|
1590
|
-
let [n, r] =
|
|
1589
|
+
function Sn(e, t) {
|
|
1590
|
+
let [n, r] = g(xn(t)), i = e !== void 0;
|
|
1591
1591
|
return {
|
|
1592
|
-
length: i ?
|
|
1592
|
+
length: i ? xn(e) : n,
|
|
1593
1593
|
trackLength: (e) => {
|
|
1594
1594
|
i || r(e.length);
|
|
1595
1595
|
}
|
|
@@ -1597,11 +1597,11 @@ function wn(e, t) {
|
|
|
1597
1597
|
}
|
|
1598
1598
|
//#endregion
|
|
1599
1599
|
//#region src/components/input/input.tsx
|
|
1600
|
-
function
|
|
1601
|
-
let { fieldId: g, errorId: _ } =
|
|
1600
|
+
function Cn({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength: o, radius: s = "md", unstyled: c = !1, className: l, wrapperClassName: u, value: d, defaultValue: f, onChange: p, id: m, ...h }) {
|
|
1601
|
+
let { fieldId: g, errorId: _ } = V(m), { length: v, trackLength: y } = Sn(d, f), b = i && (a !== void 0 || o !== void 0), C = (e) => {
|
|
1602
1602
|
y(e.target.value), p?.(e);
|
|
1603
1603
|
};
|
|
1604
|
-
return /* @__PURE__ */ n(
|
|
1604
|
+
return /* @__PURE__ */ n(de, {
|
|
1605
1605
|
fieldId: g,
|
|
1606
1606
|
errorId: _,
|
|
1607
1607
|
label: e,
|
|
@@ -1610,19 +1610,19 @@ function Tn({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength
|
|
|
1610
1610
|
wrapperClassName: u,
|
|
1611
1611
|
children: [/* @__PURE__ */ t("input", {
|
|
1612
1612
|
id: g,
|
|
1613
|
-
className:
|
|
1614
|
-
|
|
1615
|
-
|
|
1613
|
+
className: x("w-full disabled:opacity-50 disabled:cursor-not-allowed", !c && [
|
|
1614
|
+
B,
|
|
1615
|
+
S[s],
|
|
1616
1616
|
"px-3 py-2 text-sm"
|
|
1617
|
-
], !c && r &&
|
|
1617
|
+
], !c && r && x("border-red-500 dark:border-red-400", "focus:ring-red-500"), l),
|
|
1618
1618
|
...d === void 0 ? { defaultValue: f } : { value: d },
|
|
1619
1619
|
minLength: a,
|
|
1620
1620
|
maxLength: o,
|
|
1621
|
-
onChange:
|
|
1621
|
+
onChange: C,
|
|
1622
1622
|
"aria-invalid": !!r,
|
|
1623
1623
|
"aria-describedby": r ? _ : void 0,
|
|
1624
1624
|
...h
|
|
1625
|
-
}), b && /* @__PURE__ */ t(
|
|
1625
|
+
}), b && /* @__PURE__ */ t(R, {
|
|
1626
1626
|
current: v,
|
|
1627
1627
|
min: a,
|
|
1628
1628
|
max: o,
|
|
@@ -1633,73 +1633,73 @@ function Tn({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength
|
|
|
1633
1633
|
}
|
|
1634
1634
|
//#endregion
|
|
1635
1635
|
//#region src/components/kbd/kbd.tsx
|
|
1636
|
-
var
|
|
1636
|
+
var wn = {
|
|
1637
1637
|
xs: "px-1.5 py-0.5 text-xs",
|
|
1638
1638
|
sm: "px-2 py-0.5 text-xs",
|
|
1639
1639
|
md: "px-2.5 py-1 text-sm",
|
|
1640
1640
|
lg: "px-3 py-1 text-base"
|
|
1641
|
-
},
|
|
1642
|
-
className:
|
|
1641
|
+
}, Tn = ({ children: e, size: n = "sm", radius: r = "sm", unstyled: i = !1, className: a }) => /* @__PURE__ */ t("kbd", {
|
|
1642
|
+
className: x("inline-flex items-center", wn[n], !i && [
|
|
1643
1643
|
"border font-semibold uppercase",
|
|
1644
1644
|
"text-gray-500 dark:text-gray-400",
|
|
1645
1645
|
"bg-gray-100 dark:bg-gray-700",
|
|
1646
1646
|
"border-gray-200 dark:border-gray-600",
|
|
1647
|
-
|
|
1647
|
+
S[r]
|
|
1648
1648
|
], a),
|
|
1649
1649
|
children: e
|
|
1650
1650
|
});
|
|
1651
1651
|
//#endregion
|
|
1652
1652
|
//#region src/lib/merge_refs.ts
|
|
1653
|
-
function
|
|
1653
|
+
function En(...e) {
|
|
1654
1654
|
return (t) => {
|
|
1655
1655
|
for (let n of e) typeof n == "function" ? n(t) : n && (n.current = t);
|
|
1656
1656
|
};
|
|
1657
1657
|
}
|
|
1658
1658
|
//#endregion
|
|
1659
1659
|
//#region src/components/menu/menu.tsx
|
|
1660
|
-
var
|
|
1661
|
-
function
|
|
1660
|
+
var Dn = 4;
|
|
1661
|
+
function On(e, t) {
|
|
1662
1662
|
return t === "center" ? e : `${e}-${t}`;
|
|
1663
1663
|
}
|
|
1664
|
-
function
|
|
1665
|
-
let f =
|
|
1666
|
-
placement:
|
|
1664
|
+
function kn({ trigger: e, children: r, side: i = "bottom", align: o = "start", radius: s = "md", className: u, ref: d }) {
|
|
1665
|
+
let f = h(null), { isMounted: p, isVisible: m, setIsVisible: g, open: _, close: v } = sn(), { refs: y, floatingStyles: b, isPositioned: S } = Yt({
|
|
1666
|
+
placement: On(i, o),
|
|
1667
1667
|
open: p,
|
|
1668
|
-
whileElementsMounted:
|
|
1668
|
+
whileElementsMounted: Rt,
|
|
1669
1669
|
middleware: [
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1670
|
+
Zt(Dn),
|
|
1671
|
+
$t(),
|
|
1672
|
+
Qt({ padding: 8 })
|
|
1673
1673
|
]
|
|
1674
1674
|
});
|
|
1675
|
-
|
|
1676
|
-
let
|
|
1675
|
+
cn(p, S, g);
|
|
1676
|
+
let C = l(() => {
|
|
1677
1677
|
v(), f.current?.querySelector("button, [href], [tabindex]")?.focus();
|
|
1678
|
-
}, [v]), w =
|
|
1678
|
+
}, [v]), w = l((e) => En(y.setReference, f, d)(e), [y, d]), T = {
|
|
1679
1679
|
onClick: (t) => {
|
|
1680
|
-
t.stopPropagation(), m ? v() :
|
|
1680
|
+
t.stopPropagation(), m ? v() : _(S), c(e) && e.props.onClick?.(t);
|
|
1681
1681
|
},
|
|
1682
1682
|
"aria-haspopup": "menu",
|
|
1683
1683
|
"aria-expanded": p
|
|
1684
|
-
}, E =
|
|
1684
|
+
}, E = c(e) ? a(e, T) : e;
|
|
1685
1685
|
return /* @__PURE__ */ n("span", {
|
|
1686
1686
|
ref: w,
|
|
1687
|
-
className:
|
|
1688
|
-
children: [E, p && /* @__PURE__ */ t(
|
|
1687
|
+
className: x("inline-block", u),
|
|
1688
|
+
children: [E, p && /* @__PURE__ */ t(on, {
|
|
1689
1689
|
setFloating: y.setFloating,
|
|
1690
1690
|
floatingStyles: b,
|
|
1691
1691
|
isVisible: m,
|
|
1692
|
-
isPositioned:
|
|
1693
|
-
radius:
|
|
1694
|
-
onClose:
|
|
1692
|
+
isPositioned: S,
|
|
1693
|
+
radius: s,
|
|
1694
|
+
onClose: C,
|
|
1695
1695
|
children: r
|
|
1696
1696
|
})]
|
|
1697
1697
|
});
|
|
1698
1698
|
}
|
|
1699
1699
|
//#endregion
|
|
1700
1700
|
//#region src/components/menu_item/menu_item.tsx
|
|
1701
|
-
function
|
|
1702
|
-
let l =
|
|
1701
|
+
function An({ icon: e, onClick: r, danger: i = !1, disabled: a = !1, children: o, className: s, ref: c }) {
|
|
1702
|
+
let l = nn();
|
|
1703
1703
|
return /* @__PURE__ */ n("button", {
|
|
1704
1704
|
ref: c,
|
|
1705
1705
|
type: "button",
|
|
@@ -1709,14 +1709,14 @@ function Mn({ icon: e, onClick: r, danger: i = !1, disabled: a = !1, children: o
|
|
|
1709
1709
|
e.stopPropagation(), r(e), l?.();
|
|
1710
1710
|
},
|
|
1711
1711
|
disabled: a,
|
|
1712
|
-
className:
|
|
1713
|
-
children: [e && /* @__PURE__ */ t("div", { className:
|
|
1712
|
+
className: x("flex w-full cursor-pointer items-center gap-2 whitespace-nowrap px-4 py-2 text-left text-sm transition-colors", "hover:enabled:bg-gray-100 dark:hover:enabled:bg-gray-700", "focus-visible:bg-gray-100 focus-visible:outline-none dark:focus-visible:bg-gray-700", "disabled:cursor-not-allowed disabled:opacity-50", i ? "text-red-600 dark:text-red-400" : "text-gray-700 dark:text-gray-300", s),
|
|
1713
|
+
children: [e && /* @__PURE__ */ t("div", { className: x(e, "h-4 w-4 flex-shrink-0") }), o]
|
|
1714
1714
|
});
|
|
1715
1715
|
}
|
|
1716
1716
|
//#endregion
|
|
1717
1717
|
//#region node_modules/.pnpm/react-call@2.0.2_react-dom@19.2.8_react@19.2.8__react@19.2.8_vite@8.2.1_@types+node@26.2.0_es_s57p6lt2ddgt4vomhz3tbzqsbu/node_modules/react-call/dist/main.js
|
|
1718
|
-
var
|
|
1719
|
-
function
|
|
1718
|
+
var jn = [];
|
|
1719
|
+
function Mn() {
|
|
1720
1720
|
let e = 0, t = [], n = null, r = /* @__PURE__ */ new Set(), i = () => {
|
|
1721
1721
|
for (let e of r) e(t);
|
|
1722
1722
|
};
|
|
@@ -1737,7 +1737,7 @@ function Pn() {
|
|
|
1737
1737
|
r.delete(i), r.size || (e = 0, t = [], n = null);
|
|
1738
1738
|
}),
|
|
1739
1739
|
getSnapshot: () => t,
|
|
1740
|
-
getServerSnapshot: () =>
|
|
1740
|
+
getServerSnapshot: () => jn,
|
|
1741
1741
|
getListenersSize: () => r.size,
|
|
1742
1742
|
getUpsertPromise: () => n,
|
|
1743
1743
|
setUpsertPromise: (e) => {
|
|
@@ -1745,9 +1745,9 @@ function Pn() {
|
|
|
1745
1745
|
}
|
|
1746
1746
|
};
|
|
1747
1747
|
}
|
|
1748
|
-
var
|
|
1749
|
-
function
|
|
1750
|
-
let n = { current:
|
|
1748
|
+
var Nn = /* @__PURE__ */ new Map();
|
|
1749
|
+
function Pn(e, t = 0) {
|
|
1750
|
+
let n = { current: Mn() }, r = (e) => (r) => {
|
|
1751
1751
|
let i = /* @__PURE__ */ new Set();
|
|
1752
1752
|
n.current.set(e, (e) => (e.resolve(r), i.add(e.promise), {
|
|
1753
1753
|
...e,
|
|
@@ -1788,10 +1788,10 @@ function In(e, t = 0) {
|
|
|
1788
1788
|
promise: o,
|
|
1789
1789
|
resolve: a
|
|
1790
1790
|
}), o;
|
|
1791
|
-
},
|
|
1791
|
+
}, c = (...e) => {
|
|
1792
1792
|
let t = e.length === 2, i = t ? e[0] : null, a = t ? e[1] : e[0];
|
|
1793
1793
|
return (!t || i === n.current.getUpsertPromise()) && n.current.setUpsertPromise(null), r(i)(a);
|
|
1794
|
-
},
|
|
1794
|
+
}, l = (...e) => {
|
|
1795
1795
|
let t = e.length === 2;
|
|
1796
1796
|
n.current.set(t ? e[0] : null, (n) => ({
|
|
1797
1797
|
...n,
|
|
@@ -1801,7 +1801,7 @@ function In(e, t = 0) {
|
|
|
1801
1801
|
}
|
|
1802
1802
|
}));
|
|
1803
1803
|
}, u = function(t) {
|
|
1804
|
-
return
|
|
1804
|
+
return _(n.current.subscribe, n.current.getSnapshot, n.current.getServerSnapshot).map(({ props: n, key: r, end: i, ended: a }, o, c) => /* @__PURE__ */ s(e, {
|
|
1805
1805
|
...n,
|
|
1806
1806
|
key: r,
|
|
1807
1807
|
call: {
|
|
@@ -1810,15 +1810,15 @@ function In(e, t = 0) {
|
|
|
1810
1810
|
ended: a,
|
|
1811
1811
|
root: t,
|
|
1812
1812
|
index: o,
|
|
1813
|
-
stackSize:
|
|
1813
|
+
stackSize: c.length
|
|
1814
1814
|
}
|
|
1815
1815
|
}));
|
|
1816
1816
|
}, d = Object.assign(u, {
|
|
1817
1817
|
Root: u,
|
|
1818
1818
|
call: a,
|
|
1819
1819
|
upsert: o,
|
|
1820
|
-
end:
|
|
1821
|
-
update:
|
|
1820
|
+
end: c,
|
|
1821
|
+
update: l
|
|
1822
1822
|
});
|
|
1823
1823
|
if (process.env.NODE_ENV !== "production") {
|
|
1824
1824
|
Object.defineProperty(d, "name", {
|
|
@@ -1833,53 +1833,46 @@ function In(e, t = 0) {
|
|
|
1833
1833
|
set: (r) => {
|
|
1834
1834
|
if (t || (e = r, !r)) return;
|
|
1835
1835
|
t = !0;
|
|
1836
|
-
let i =
|
|
1837
|
-
i ? n.current = i :
|
|
1836
|
+
let i = Nn.get(r);
|
|
1837
|
+
i ? n.current = i : Nn.set(r, n.current);
|
|
1838
1838
|
}
|
|
1839
1839
|
});
|
|
1840
1840
|
}
|
|
1841
1841
|
return d;
|
|
1842
1842
|
}
|
|
1843
1843
|
//#endregion
|
|
1844
|
-
//#region src/components/modal/
|
|
1845
|
-
var
|
|
1846
|
-
className: C("flex items-center justify-end gap-3 px-6 py-4 border-t flex-shrink-0", ie, n),
|
|
1847
|
-
children: e
|
|
1848
|
-
}), Rn = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
|
|
1849
|
-
function zn(e) {
|
|
1850
|
-
return a.toArray(e).flatMap((e) => u(e) && e.type === o ? zn(e.props.children) : [e]);
|
|
1851
|
-
}
|
|
1852
|
-
var Bn = {
|
|
1844
|
+
//#region src/components/modal/modal_shell.tsx
|
|
1845
|
+
var Fn = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])", In = {
|
|
1853
1846
|
sm: "max-w-md",
|
|
1854
1847
|
md: "max-w-lg",
|
|
1855
1848
|
lg: "max-w-2xl",
|
|
1856
1849
|
xl: "max-w-4xl"
|
|
1857
1850
|
};
|
|
1858
|
-
function
|
|
1859
|
-
let [
|
|
1860
|
-
|
|
1861
|
-
document.body.style.overflow = "hidden",
|
|
1862
|
-
let e =
|
|
1863
|
-
(b.current?.querySelector(
|
|
1851
|
+
function Ln({ isEnded: e, onDismiss: r, title: i, children: a, footer: o, size: s = "md", radius: c = "xl", className: l, dismissible: u = !0, closeLabel: p = "Close" }) {
|
|
1852
|
+
let [m, _] = g(!1), v = h(null), b = h(null), C = h(null), w = f();
|
|
1853
|
+
d(() => {
|
|
1854
|
+
document.body.style.overflow = "hidden", C.current = document.activeElement;
|
|
1855
|
+
let e = v.current;
|
|
1856
|
+
(b.current?.querySelector(Fn) ?? e?.querySelector(Fn) ?? e)?.focus();
|
|
1864
1857
|
let t = requestAnimationFrame(() => {
|
|
1865
|
-
requestAnimationFrame(() =>
|
|
1858
|
+
requestAnimationFrame(() => _(!0));
|
|
1866
1859
|
});
|
|
1867
1860
|
return () => {
|
|
1868
1861
|
cancelAnimationFrame(t), document.body.style.overflow = "";
|
|
1869
1862
|
};
|
|
1870
|
-
}, []),
|
|
1871
|
-
e &&
|
|
1872
|
-
}, [e]),
|
|
1863
|
+
}, []), d(() => {
|
|
1864
|
+
e && C.current?.focus();
|
|
1865
|
+
}, [e]), d(() => {
|
|
1873
1866
|
if (e) return;
|
|
1874
1867
|
let t = (e) => {
|
|
1875
1868
|
if (e.key === "Escape") {
|
|
1876
|
-
|
|
1869
|
+
u && r();
|
|
1877
1870
|
return;
|
|
1878
1871
|
}
|
|
1879
1872
|
if (e.key !== "Tab") return;
|
|
1880
|
-
let t =
|
|
1873
|
+
let t = v.current;
|
|
1881
1874
|
if (!t) return;
|
|
1882
|
-
let n = Array.from(t.querySelectorAll(
|
|
1875
|
+
let n = Array.from(t.querySelectorAll(Fn));
|
|
1883
1876
|
if (n.length === 0) return;
|
|
1884
1877
|
let i = n[0], a = n[n.length - 1];
|
|
1885
1878
|
e.shiftKey && document.activeElement === i ? (e.preventDefault(), a.focus()) : !e.shiftKey && document.activeElement === a && (e.preventDefault(), i.focus());
|
|
@@ -1888,36 +1881,36 @@ function Vn({ isEnded: e, onDismiss: r, title: i, children: a, footer: o, size:
|
|
|
1888
1881
|
}, [
|
|
1889
1882
|
e,
|
|
1890
1883
|
r,
|
|
1891
|
-
|
|
1884
|
+
u
|
|
1892
1885
|
]);
|
|
1893
|
-
let
|
|
1894
|
-
!e &&
|
|
1895
|
-
},
|
|
1896
|
-
return
|
|
1897
|
-
className:
|
|
1898
|
-
onClick:
|
|
1886
|
+
let T = () => {
|
|
1887
|
+
!e && u && r();
|
|
1888
|
+
}, E = m && !e;
|
|
1889
|
+
return y(/* @__PURE__ */ n("div", {
|
|
1890
|
+
className: x("fixed inset-0 z-50 flex items-start justify-center", "p-2 sm:py-[3rem] lg:py-[5rem]", "transition-opacity duration-200 ease-out", E ? "opacity-100" : "opacity-0"),
|
|
1891
|
+
onClick: T,
|
|
1899
1892
|
children: [/* @__PURE__ */ t("div", {
|
|
1900
|
-
className:
|
|
1893
|
+
className: x("fixed inset-0 bg-black/60 backdrop-blur-md", "transition-opacity duration-200 ease-out", E ? "opacity-100" : "opacity-0"),
|
|
1901
1894
|
"aria-hidden": "true"
|
|
1902
1895
|
}), /* @__PURE__ */ n("div", {
|
|
1903
|
-
ref:
|
|
1896
|
+
ref: v,
|
|
1904
1897
|
role: "dialog",
|
|
1905
1898
|
"aria-modal": "true",
|
|
1906
|
-
"aria-labelledby": i ?
|
|
1899
|
+
"aria-labelledby": i ? w : void 0,
|
|
1907
1900
|
tabIndex: -1,
|
|
1908
|
-
className:
|
|
1901
|
+
className: x("relative w-full", In[s], ne, "shadow-2xl", S[c], "max-h-[calc(100vh-4rem)] sm:max-h-[calc(100vh-10rem)] overflow-hidden flex flex-col", "transition-all duration-200 ease-out", "focus:outline-none", E ? "opacity-100 scale-100 translate-y-0" : "opacity-0 scale-95 translate-y-1"),
|
|
1909
1902
|
onClick: (e) => e.stopPropagation(),
|
|
1910
1903
|
children: [
|
|
1911
1904
|
i && /* @__PURE__ */ n("div", {
|
|
1912
1905
|
className: "flex items-center justify-between gap-4 px-6 pt-5 pb-4 flex-shrink-0",
|
|
1913
1906
|
children: [/* @__PURE__ */ t("h2", {
|
|
1914
|
-
id:
|
|
1907
|
+
id: w,
|
|
1915
1908
|
className: "text-base font-medium tracking-tight text-gray-900 dark:text-gray-100",
|
|
1916
1909
|
children: i
|
|
1917
|
-
}),
|
|
1910
|
+
}), u && /* @__PURE__ */ t(bn, {
|
|
1918
1911
|
icon: "i-mdi-close",
|
|
1919
1912
|
onClick: r,
|
|
1920
|
-
"aria-label":
|
|
1913
|
+
"aria-label": p,
|
|
1921
1914
|
variant: "subtle",
|
|
1922
1915
|
size: "sm",
|
|
1923
1916
|
radius: "full",
|
|
@@ -1926,17 +1919,20 @@ function Vn({ isEnded: e, onDismiss: r, title: i, children: a, footer: o, size:
|
|
|
1926
1919
|
}),
|
|
1927
1920
|
/* @__PURE__ */ t("div", {
|
|
1928
1921
|
ref: b,
|
|
1929
|
-
className:
|
|
1922
|
+
className: x("flex-1 overflow-y-auto px-6 pb-6 text-sm leading-relaxed text-gray-600 dark:text-gray-400 min-h-0", !i && "pt-6", l),
|
|
1930
1923
|
children: a
|
|
1931
1924
|
}),
|
|
1932
|
-
|
|
1925
|
+
o && /* @__PURE__ */ t("div", {
|
|
1926
|
+
className: x("flex items-center justify-end gap-3 px-6 py-4 border-t flex-shrink-0", "border-gray-100 dark:border-gray-800"),
|
|
1927
|
+
children: o
|
|
1928
|
+
})
|
|
1933
1929
|
]
|
|
1934
1930
|
})]
|
|
1935
1931
|
}), document.body);
|
|
1936
1932
|
}
|
|
1937
1933
|
//#endregion
|
|
1938
1934
|
//#region node_modules/.pnpm/zustand@5.0.14_@types+react@19.2.18_react@19.2.8_use-sync-external-store@1.6.0_react@19.2.8_/node_modules/zustand/esm/vanilla.mjs
|
|
1939
|
-
var
|
|
1935
|
+
var Rn = (e) => {
|
|
1940
1936
|
let t, n = /* @__PURE__ */ new Set(), r = (e, r) => {
|
|
1941
1937
|
let i = typeof e == "function" ? e(t) : e;
|
|
1942
1938
|
if (!Object.is(i, t)) {
|
|
@@ -1950,47 +1946,47 @@ var Hn = (e) => {
|
|
|
1950
1946
|
subscribe: (e) => (n.add(e), () => n.delete(e))
|
|
1951
1947
|
}, o = t = e(r, i, a);
|
|
1952
1948
|
return a;
|
|
1953
|
-
},
|
|
1954
|
-
function
|
|
1949
|
+
}, zn = ((e) => e ? Rn(e) : Rn), Bn = (e) => e;
|
|
1950
|
+
function Vn(e, t = Bn) {
|
|
1955
1951
|
let n = i.useSyncExternalStore(e.subscribe, i.useCallback(() => t(e.getState()), [e, t]), i.useCallback(() => t(e.getInitialState()), [e, t]));
|
|
1956
1952
|
return i.useDebugValue(n), n;
|
|
1957
1953
|
}
|
|
1958
|
-
var
|
|
1959
|
-
let t =
|
|
1954
|
+
var Hn = (e) => {
|
|
1955
|
+
let t = zn(e), n = (e) => Vn(t, e);
|
|
1960
1956
|
return Object.assign(n, t), n;
|
|
1961
|
-
},
|
|
1957
|
+
}, Un = ((e) => e ? Hn(e) : Hn), Wn = Un((e) => ({
|
|
1962
1958
|
globalHotkeysEnabled: !0,
|
|
1963
1959
|
setGlobalHotkeysEnabled: (t) => e({ globalHotkeysEnabled: t })
|
|
1964
|
-
})),
|
|
1965
|
-
function
|
|
1966
|
-
|
|
1967
|
-
--
|
|
1960
|
+
})), Gn = 0;
|
|
1961
|
+
function Kn() {
|
|
1962
|
+
d(() => (Gn += 1, Gn === 1 && Wn.getState().setGlobalHotkeysEnabled(!1), () => {
|
|
1963
|
+
--Gn, Gn === 0 && Wn.getState().setGlobalHotkeysEnabled(!0);
|
|
1968
1964
|
}), []);
|
|
1969
1965
|
}
|
|
1970
1966
|
//#endregion
|
|
1971
1967
|
//#region src/components/modal/confirm_modal.tsx
|
|
1972
|
-
var
|
|
1968
|
+
var qn = {
|
|
1973
1969
|
danger: "i-mdi-alert-circle",
|
|
1974
1970
|
primary: "i-mdi-help-circle",
|
|
1975
1971
|
success: "i-mdi-check-circle"
|
|
1976
|
-
},
|
|
1972
|
+
}, Jn = {
|
|
1977
1973
|
danger: "bg-red-50 text-red-600 dark:bg-red-500/10 dark:text-red-400",
|
|
1978
1974
|
primary: "bg-blue-50 text-blue-600 dark:bg-blue-500/10 dark:text-blue-400",
|
|
1979
1975
|
success: "bg-green-50 text-green-600 dark:bg-green-500/10 dark:text-green-400"
|
|
1980
1976
|
};
|
|
1981
|
-
function
|
|
1977
|
+
function Yn({ title: e, color: r }) {
|
|
1982
1978
|
return /* @__PURE__ */ n("div", {
|
|
1983
1979
|
className: "flex items-center gap-3",
|
|
1984
1980
|
children: [/* @__PURE__ */ t("span", {
|
|
1985
|
-
className:
|
|
1981
|
+
className: x("flex h-9 w-9 shrink-0 items-center justify-center rounded-full", Jn[r]),
|
|
1986
1982
|
"aria-hidden": "true",
|
|
1987
|
-
children: /* @__PURE__ */ t("span", { className:
|
|
1983
|
+
children: /* @__PURE__ */ t("span", { className: x(qn[r], "h-5 w-5") })
|
|
1988
1984
|
}), e]
|
|
1989
1985
|
});
|
|
1990
1986
|
}
|
|
1991
|
-
var
|
|
1992
|
-
|
|
1993
|
-
let [p, m] =
|
|
1987
|
+
var Xn = Pn(({ call: r, title: i, children: a, confirmLabel: o, cancelLabel: s, confirmColor: c, radius: l, closeLabel: u, onConfirm: d, onError: f }) => {
|
|
1988
|
+
Kn();
|
|
1989
|
+
let [p, m] = g(!1), h = () => r.end(!1), _ = async () => {
|
|
1994
1990
|
if (!d) {
|
|
1995
1991
|
r.end(!0);
|
|
1996
1992
|
return;
|
|
@@ -1999,33 +1995,33 @@ var er = In(({ call: r, title: i, children: a, confirmLabel: o, cancelLabel: s,
|
|
|
1999
1995
|
try {
|
|
2000
1996
|
await d(), r.end(!0);
|
|
2001
1997
|
} catch (e) {
|
|
2002
|
-
m(!1),
|
|
1998
|
+
m(!1), pn(e, f);
|
|
2003
1999
|
}
|
|
2004
|
-
},
|
|
2005
|
-
return /* @__PURE__ */ t(
|
|
2000
|
+
}, v = p, y = o ?? "Confirm", b = s ?? "Cancel", x = c ?? "primary";
|
|
2001
|
+
return /* @__PURE__ */ t(Ln, {
|
|
2006
2002
|
isEnded: r.ended,
|
|
2007
2003
|
onDismiss: h,
|
|
2008
|
-
title: /* @__PURE__ */ t(
|
|
2004
|
+
title: /* @__PURE__ */ t(Yn, {
|
|
2009
2005
|
title: i,
|
|
2010
2006
|
color: x
|
|
2011
2007
|
}),
|
|
2012
2008
|
size: "sm",
|
|
2013
2009
|
radius: l,
|
|
2014
2010
|
closeLabel: u,
|
|
2015
|
-
footer: /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t(
|
|
2011
|
+
footer: /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t(F, {
|
|
2016
2012
|
variant: "outline",
|
|
2017
2013
|
color: "neutral",
|
|
2018
2014
|
onClick: h,
|
|
2019
|
-
disabled:
|
|
2015
|
+
disabled: v,
|
|
2020
2016
|
size: "sm",
|
|
2021
2017
|
children: b
|
|
2022
|
-
}), /* @__PURE__ */ t(
|
|
2018
|
+
}), /* @__PURE__ */ t(F, {
|
|
2023
2019
|
color: x,
|
|
2024
2020
|
onClick: () => {
|
|
2025
|
-
|
|
2021
|
+
_();
|
|
2026
2022
|
},
|
|
2027
|
-
loading:
|
|
2028
|
-
disabled:
|
|
2023
|
+
loading: v,
|
|
2024
|
+
disabled: v,
|
|
2029
2025
|
size: "sm",
|
|
2030
2026
|
children: y
|
|
2031
2027
|
})] }),
|
|
@@ -2034,42 +2030,48 @@ var er = In(({ call: r, title: i, children: a, confirmLabel: o, cancelLabel: s,
|
|
|
2034
2030
|
}, 200);
|
|
2035
2031
|
//#endregion
|
|
2036
2032
|
//#region src/components/modal/modal.tsx
|
|
2037
|
-
function
|
|
2033
|
+
function Zn(e, t) {
|
|
2038
2034
|
return typeof e == "function" ? e(t) : e;
|
|
2039
2035
|
}
|
|
2040
|
-
var
|
|
2041
|
-
|
|
2042
|
-
let u = () => e.end();
|
|
2043
|
-
return /* @__PURE__ */ t(
|
|
2036
|
+
var Qn = o(null), $n = Pn(({ call: e, title: n, children: r, size: i, radius: a, className: o, dismissible: s, closeLabel: c }) => {
|
|
2037
|
+
Kn();
|
|
2038
|
+
let [l, u] = g(null), d = () => e.end();
|
|
2039
|
+
return /* @__PURE__ */ t(Ln, {
|
|
2044
2040
|
isEnded: e.ended,
|
|
2045
|
-
onDismiss:
|
|
2041
|
+
onDismiss: d,
|
|
2046
2042
|
title: n,
|
|
2047
|
-
footer:
|
|
2048
|
-
size:
|
|
2049
|
-
radius:
|
|
2050
|
-
className:
|
|
2051
|
-
dismissible:
|
|
2052
|
-
closeLabel:
|
|
2053
|
-
children:
|
|
2043
|
+
footer: l,
|
|
2044
|
+
size: i,
|
|
2045
|
+
radius: a,
|
|
2046
|
+
className: o,
|
|
2047
|
+
dismissible: s,
|
|
2048
|
+
closeLabel: c,
|
|
2049
|
+
children: /* @__PURE__ */ t(Qn.Provider, {
|
|
2050
|
+
value: u,
|
|
2051
|
+
children: Zn(r, d)
|
|
2052
|
+
})
|
|
2054
2053
|
});
|
|
2055
|
-
}, 200)
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
})
|
|
2054
|
+
}, 200);
|
|
2055
|
+
//#endregion
|
|
2056
|
+
//#region src/components/modal/modal_footer.tsx
|
|
2057
|
+
function er({ children: e }) {
|
|
2058
|
+
let t = u(Qn);
|
|
2059
|
+
return d(() => (t?.(e), () => t?.(null)), [t, e]), null;
|
|
2060
|
+
}
|
|
2059
2061
|
//#endregion
|
|
2060
2062
|
//#region src/components/modal_provider/modal_provider.tsx
|
|
2061
|
-
function
|
|
2062
|
-
return /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t(
|
|
2063
|
+
function tr() {
|
|
2064
|
+
return /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t($n, {}), /* @__PURE__ */ t(Xn, {})] });
|
|
2063
2065
|
}
|
|
2064
2066
|
//#endregion
|
|
2065
2067
|
//#region src/components/radio_options/radio_option_row.tsx
|
|
2066
|
-
function
|
|
2068
|
+
function nr({ option: e, optionId: r, descriptionId: i, name: a, orientation: o, isSelected: s, isDisabled: c, isFirstOption: l, required: u, error: d, radius: f, unstyled: p, className: m, onSelect: h }) {
|
|
2067
2069
|
return /* @__PURE__ */ n("label", {
|
|
2068
2070
|
htmlFor: r,
|
|
2069
|
-
className:
|
|
2070
|
-
|
|
2071
|
+
className: x("flex cursor-pointer items-start gap-3 transition-colors duration-150", o === "horizontal" && "flex-1", T, d ? D : E, !p && [
|
|
2072
|
+
S[f],
|
|
2071
2073
|
"border px-3 py-2.5",
|
|
2072
|
-
s ? d ?
|
|
2074
|
+
s ? d ? x("border-red-500 dark:border-red-400", "bg-red-50 dark:bg-red-950/20") : "border-blue-500 bg-blue-50 dark:border-blue-500 dark:bg-blue-950/25" : d ? "border-red-300 bg-white dark:border-red-800/50 dark:bg-gray-800/50" : x("border-gray-200 dark:border-gray-700", "bg-gray-50 hover:border-gray-300 hover:bg-white dark:bg-gray-800/50 dark:hover:border-gray-600 dark:hover:bg-gray-800")
|
|
2073
2075
|
], c && "cursor-not-allowed opacity-50", m),
|
|
2074
2076
|
children: [
|
|
2075
2077
|
/* @__PURE__ */ t("input", {
|
|
@@ -2086,24 +2088,24 @@ function ar({ option: e, optionId: r, descriptionId: i, name: a, orientation: o,
|
|
|
2086
2088
|
className: "sr-only"
|
|
2087
2089
|
}),
|
|
2088
2090
|
/* @__PURE__ */ t("span", {
|
|
2089
|
-
className:
|
|
2091
|
+
className: x("mt-0.5 flex h-4 w-4 shrink-0 items-center justify-center rounded-full border-2 transition-colors duration-150", s ? d ? ae : "border-blue-600 dark:border-blue-500" : d ? "border-red-400 dark:border-red-600" : z),
|
|
2090
2092
|
"aria-hidden": !0,
|
|
2091
|
-
children: s && /* @__PURE__ */ t("span", { className:
|
|
2093
|
+
children: s && /* @__PURE__ */ t("span", { className: x("h-2 w-2 rounded-full", d ? "bg-red-500 dark:bg-red-400" : "bg-blue-600 dark:bg-blue-500") })
|
|
2092
2094
|
}),
|
|
2093
2095
|
/* @__PURE__ */ n("span", {
|
|
2094
2096
|
className: "flex min-w-0 flex-col",
|
|
2095
2097
|
children: [/* @__PURE__ */ n("span", {
|
|
2096
2098
|
className: "flex items-center gap-1.5",
|
|
2097
2099
|
children: [e.icon && /* @__PURE__ */ t("span", {
|
|
2098
|
-
className:
|
|
2100
|
+
className: x(e.icon, "h-4 w-4 shrink-0", s ? d ? "text-red-600 dark:text-red-400" : "text-blue-600 dark:text-blue-400" : "text-gray-500 dark:text-gray-400"),
|
|
2099
2101
|
"aria-hidden": !0
|
|
2100
2102
|
}), /* @__PURE__ */ t("span", {
|
|
2101
|
-
className:
|
|
2103
|
+
className: x("select-none text-sm font-medium", s ? d ? "text-red-700 dark:text-red-300" : "text-blue-700 dark:text-blue-300" : "text-gray-700 dark:text-gray-300"),
|
|
2102
2104
|
children: e.label
|
|
2103
2105
|
})]
|
|
2104
2106
|
}), e.description && /* @__PURE__ */ t("span", {
|
|
2105
2107
|
id: i,
|
|
2106
|
-
className:
|
|
2108
|
+
className: x("text-xs text-gray-500 dark:text-gray-400", "mt-0.5"),
|
|
2107
2109
|
children: e.description
|
|
2108
2110
|
})]
|
|
2109
2111
|
})
|
|
@@ -2112,36 +2114,36 @@ function ar({ option: e, optionId: r, descriptionId: i, name: a, orientation: o,
|
|
|
2112
2114
|
}
|
|
2113
2115
|
//#endregion
|
|
2114
2116
|
//#region src/components/radio_options/radio_options.tsx
|
|
2115
|
-
function
|
|
2116
|
-
let { fieldId: v, errorId: y } =
|
|
2117
|
+
function rr({ options: e, orientation: r = "vertical", value: i, defaultValue: a, onChange: o, name: s, label: c, error: l, required: u, disabled: d, radius: f = "lg", unstyled: p = !1, className: m, wrapperClassName: h, id: g, ..._ }) {
|
|
2118
|
+
let { fieldId: v, errorId: y } = V(g), b = s ?? v, [S, C] = H(i, a ?? ""), w = e.map((e) => typeof e == "string" ? {
|
|
2117
2119
|
value: e,
|
|
2118
2120
|
label: e
|
|
2119
2121
|
} : e), T = (e) => {
|
|
2120
|
-
|
|
2122
|
+
C(e), o?.(e);
|
|
2121
2123
|
};
|
|
2122
2124
|
return /* @__PURE__ */ n("fieldset", {
|
|
2123
|
-
className:
|
|
2125
|
+
className: x("m-0 border-0 p-0", h),
|
|
2124
2126
|
disabled: d,
|
|
2125
2127
|
"aria-describedby": l ? y : void 0,
|
|
2126
2128
|
"aria-required": u,
|
|
2127
2129
|
..._,
|
|
2128
2130
|
children: [
|
|
2129
2131
|
c && /* @__PURE__ */ n("legend", {
|
|
2130
|
-
className:
|
|
2132
|
+
className: x("text-sm font-medium text-gray-700 dark:text-gray-300", "mb-2"),
|
|
2131
2133
|
children: [c, u && /* @__PURE__ */ t("span", {
|
|
2132
2134
|
className: "text-red-500 dark:text-red-400 ml-1",
|
|
2133
2135
|
children: "*"
|
|
2134
2136
|
})]
|
|
2135
2137
|
}),
|
|
2136
2138
|
/* @__PURE__ */ t("div", {
|
|
2137
|
-
className:
|
|
2138
|
-
children: w.map((e, n) => /* @__PURE__ */ t(
|
|
2139
|
+
className: x(r === "horizontal" ? "flex flex-row gap-2" : "flex flex-col gap-2"),
|
|
2140
|
+
children: w.map((e, n) => /* @__PURE__ */ t(nr, {
|
|
2139
2141
|
option: e,
|
|
2140
2142
|
optionId: `${v}-${n}`,
|
|
2141
2143
|
descriptionId: `${v}-${n}-desc`,
|
|
2142
2144
|
name: b,
|
|
2143
2145
|
orientation: r,
|
|
2144
|
-
isSelected:
|
|
2146
|
+
isSelected: S === e.value,
|
|
2145
2147
|
isDisabled: d === !0 || e.disabled === !0,
|
|
2146
2148
|
isFirstOption: n === 0,
|
|
2147
2149
|
required: u,
|
|
@@ -2152,7 +2154,7 @@ function or({ options: e, orientation: r = "vertical", value: i, defaultValue: a
|
|
|
2152
2154
|
onSelect: T
|
|
2153
2155
|
}, e.value))
|
|
2154
2156
|
}),
|
|
2155
|
-
/* @__PURE__ */ t(
|
|
2157
|
+
/* @__PURE__ */ t(oe, {
|
|
2156
2158
|
id: y,
|
|
2157
2159
|
error: l,
|
|
2158
2160
|
className: "mt-2"
|
|
@@ -2162,9 +2164,9 @@ function or({ options: e, orientation: r = "vertical", value: i, defaultValue: a
|
|
|
2162
2164
|
}
|
|
2163
2165
|
//#endregion
|
|
2164
2166
|
//#region src/components/select/select.tsx
|
|
2165
|
-
function
|
|
2166
|
-
let { fieldId: h, errorId: g } =
|
|
2167
|
-
return /* @__PURE__ */ t(
|
|
2167
|
+
function ir({ options: e, label: r, error: i, placeholder: a, radius: o = "md", unstyled: s = !1, className: c, wrapperClassName: l, value: u, defaultValue: d, onChange: f, id: p, ...m }) {
|
|
2168
|
+
let { fieldId: h, errorId: g } = V(p);
|
|
2169
|
+
return /* @__PURE__ */ t(de, {
|
|
2168
2170
|
fieldId: h,
|
|
2169
2171
|
errorId: g,
|
|
2170
2172
|
label: r,
|
|
@@ -2173,12 +2175,12 @@ function sr({ options: e, label: r, error: i, placeholder: a, radius: o = "md",
|
|
|
2173
2175
|
wrapperClassName: l,
|
|
2174
2176
|
children: /* @__PURE__ */ n("select", {
|
|
2175
2177
|
id: h,
|
|
2176
|
-
className:
|
|
2177
|
-
|
|
2178
|
-
|
|
2178
|
+
className: x("w-full disabled:opacity-50 disabled:cursor-not-allowed", !s && [
|
|
2179
|
+
B,
|
|
2180
|
+
S[o],
|
|
2179
2181
|
"pl-3 pr-8 py-2 text-sm appearance-none bg-[length:1rem_1rem] bg-[position:right_0.5rem_center] bg-no-repeat",
|
|
2180
2182
|
"bg-[url(\"data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 fill=%27none%27 viewBox=%270 0 20 20%27%3e%3cpath stroke=%27%236b7280%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27 stroke-width=%271.5%27 d=%27M6 8l4 4 4-4%27/%3e%3c/svg%3e\")]"
|
|
2181
|
-
], !s && i &&
|
|
2183
|
+
], !s && i && x("border-red-500 dark:border-red-400", "focus:ring-red-500"), c),
|
|
2182
2184
|
...u === void 0 ? { defaultValue: d } : { value: u },
|
|
2183
2185
|
onChange: f,
|
|
2184
2186
|
"aria-invalid": !!i,
|
|
@@ -2196,16 +2198,16 @@ function sr({ options: e, label: r, error: i, placeholder: a, radius: o = "md",
|
|
|
2196
2198
|
}
|
|
2197
2199
|
//#endregion
|
|
2198
2200
|
//#region src/components/switch/switch.tsx
|
|
2199
|
-
function
|
|
2200
|
-
let { fieldId: m, errorId: h, descriptionId: g } =
|
|
2201
|
+
function ar({ label: r, description: i, error: a, unstyled: o = !1, className: s, wrapperClassName: c, checked: l, defaultChecked: u = !1, onChange: d, id: f, ...p }) {
|
|
2202
|
+
let { fieldId: m, errorId: h, descriptionId: g } = V(f), [_, v] = H(l, u), y = [i && g, a && h].filter(Boolean).join(" ") || void 0;
|
|
2201
2203
|
return /* @__PURE__ */ n("div", {
|
|
2202
|
-
className:
|
|
2204
|
+
className: x("w-full", c),
|
|
2203
2205
|
children: [
|
|
2204
2206
|
/* @__PURE__ */ n("label", {
|
|
2205
2207
|
htmlFor: m,
|
|
2206
|
-
className:
|
|
2208
|
+
className: x("flex items-center gap-3 cursor-pointer", p.disabled && "cursor-not-allowed opacity-50"),
|
|
2207
2209
|
children: [/* @__PURE__ */ n("span", {
|
|
2208
|
-
className:
|
|
2210
|
+
className: x("relative inline-flex w-11 shrink-0", "transition-colors duration-200 ease-in-out", T, E, !o && [
|
|
2209
2211
|
"rounded-full border-2 border-transparent",
|
|
2210
2212
|
_ ? "bg-blue-600 dark:bg-blue-500" : "bg-gray-200 dark:bg-gray-600",
|
|
2211
2213
|
a && "ring-2 ring-red-500 dark:ring-red-400"
|
|
@@ -2223,11 +2225,11 @@ function cr({ label: r, description: i, error: a, unstyled: o = !1, className: s
|
|
|
2223
2225
|
"aria-describedby": y,
|
|
2224
2226
|
...p
|
|
2225
2227
|
}), /* @__PURE__ */ t("span", {
|
|
2226
|
-
className:
|
|
2228
|
+
className: x("pointer-events-none inline-block h-5 w-5 transform rounded-full bg-white shadow ring-0", "transition duration-200 ease-in-out", _ ? "translate-x-5.25" : "translate-x-0"),
|
|
2227
2229
|
"aria-hidden": !0
|
|
2228
2230
|
})]
|
|
2229
2231
|
}), r && /* @__PURE__ */ t(e, { children: typeof r == "string" ? /* @__PURE__ */ n("span", {
|
|
2230
|
-
className:
|
|
2232
|
+
className: x("text-sm font-medium text-gray-700 dark:text-gray-300", "select-none"),
|
|
2231
2233
|
children: [r, p.required && /* @__PURE__ */ t("span", {
|
|
2232
2234
|
className: "text-red-500 dark:text-red-400 ml-1",
|
|
2233
2235
|
children: "*"
|
|
@@ -2237,12 +2239,12 @@ function cr({ label: r, description: i, error: a, unstyled: o = !1, className: s
|
|
|
2237
2239
|
children: "*"
|
|
2238
2240
|
})] }) })]
|
|
2239
2241
|
}),
|
|
2240
|
-
/* @__PURE__ */ t(
|
|
2242
|
+
/* @__PURE__ */ t(se, {
|
|
2241
2243
|
id: g,
|
|
2242
2244
|
description: i,
|
|
2243
2245
|
className: "mt-1 ml-14"
|
|
2244
2246
|
}),
|
|
2245
|
-
/* @__PURE__ */ t(
|
|
2247
|
+
/* @__PURE__ */ t(oe, {
|
|
2246
2248
|
id: h,
|
|
2247
2249
|
error: a,
|
|
2248
2250
|
className: "mt-1 ml-14"
|
|
@@ -2252,11 +2254,11 @@ function cr({ label: r, description: i, error: a, unstyled: o = !1, className: s
|
|
|
2252
2254
|
}
|
|
2253
2255
|
//#endregion
|
|
2254
2256
|
//#region src/components/tabs/tabs.tsx
|
|
2255
|
-
function
|
|
2256
|
-
let [d,
|
|
2257
|
-
e[t]?.disabled || (
|
|
2257
|
+
function or({ items: e, value: r, defaultIndex: i = 0, radius: a = "md", unstyled: o = !1, className: s, tabListClassName: c, panelClassName: l, onChange: u }) {
|
|
2258
|
+
let [d, p] = H(r, i), m = f(), g = h([]), _ = (t) => {
|
|
2259
|
+
e[t]?.disabled || (p(t), u?.(t));
|
|
2258
2260
|
}, v = (e) => {
|
|
2259
|
-
|
|
2261
|
+
g.current[e]?.focus(), _(e);
|
|
2260
2262
|
}, y = (t) => {
|
|
2261
2263
|
let n = e.map((e, t) => t).filter((t) => !e[t]?.disabled);
|
|
2262
2264
|
if (n.length === 0) return;
|
|
@@ -2264,40 +2266,40 @@ function lr({ items: e, value: r, defaultIndex: i = 0, radius: a = "md", unstyle
|
|
|
2264
2266
|
t.key === "ArrowRight" ? (t.preventDefault(), v(n[(r + 1) % n.length])) : t.key === "ArrowLeft" ? (t.preventDefault(), v(n[(r - 1 + n.length) % n.length])) : t.key === "Home" ? (t.preventDefault(), v(n[0])) : t.key === "End" && (t.preventDefault(), v(n[n.length - 1]));
|
|
2265
2267
|
}, b = e[d];
|
|
2266
2268
|
return /* @__PURE__ */ n("div", {
|
|
2267
|
-
className:
|
|
2269
|
+
className: x("w-full", s),
|
|
2268
2270
|
children: [/* @__PURE__ */ t("div", {
|
|
2269
2271
|
role: "tablist",
|
|
2270
|
-
className:
|
|
2272
|
+
className: x("flex gap-1 p-1", !o && [
|
|
2271
2273
|
"bg-gray-100 dark:bg-gray-800/50 border",
|
|
2272
2274
|
"border-gray-200 dark:border-gray-700",
|
|
2273
|
-
|
|
2275
|
+
S[a]
|
|
2274
2276
|
], c),
|
|
2275
2277
|
children: e.map((e, r) => /* @__PURE__ */ n("button", {
|
|
2276
2278
|
ref: (e) => {
|
|
2277
|
-
|
|
2279
|
+
g.current[r] = e;
|
|
2278
2280
|
},
|
|
2279
|
-
id: `${
|
|
2281
|
+
id: `${m}-tab-${r}`,
|
|
2280
2282
|
role: "tab",
|
|
2281
2283
|
type: "button",
|
|
2282
2284
|
"aria-selected": d === r,
|
|
2283
2285
|
"aria-disabled": e.disabled,
|
|
2284
|
-
"aria-controls": `${
|
|
2286
|
+
"aria-controls": `${m}-panel-${r}`,
|
|
2285
2287
|
tabIndex: d === r ? 0 : -1,
|
|
2286
2288
|
disabled: e.disabled,
|
|
2287
|
-
onClick: () =>
|
|
2289
|
+
onClick: () => _(r),
|
|
2288
2290
|
onKeyDown: y,
|
|
2289
|
-
className:
|
|
2290
|
-
children: [e.icon && /* @__PURE__ */ t("span", { className:
|
|
2291
|
+
className: x("flex items-center gap-2 px-4 py-2.5 text-sm font-medium", e.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer", !o && [S[a], d === r ? x("bg-white dark:bg-gray-700 text-blue-600 dark:text-blue-400 shadow-sm border", "border-gray-200 dark:border-gray-700") : x("text-gray-600 dark:text-gray-400 border border-transparent", !e.disabled && "hover:text-gray-900 dark:hover:text-gray-200 hover:bg-gray-200/50 dark:hover:bg-gray-700/50")]),
|
|
2292
|
+
children: [e.icon && /* @__PURE__ */ t("span", { className: x("w-4 h-4 block shrink-0", e.icon, !o && (d === r ? "text-blue-600 dark:text-blue-400" : "text-gray-500 dark:text-gray-400")) }), e.title]
|
|
2291
2293
|
}, e.title))
|
|
2292
2294
|
}), /* @__PURE__ */ t("div", {
|
|
2293
2295
|
role: "tabpanel",
|
|
2294
|
-
id: `${
|
|
2295
|
-
"aria-labelledby": `${
|
|
2296
|
+
id: `${m}-panel-${d}`,
|
|
2297
|
+
"aria-labelledby": `${m}-tab-${d}`,
|
|
2296
2298
|
tabIndex: 0,
|
|
2297
|
-
className:
|
|
2299
|
+
className: x("mt-3 overflow-hidden focus:outline-none", !o && [
|
|
2298
2300
|
"border bg-white dark:bg-gray-800/50 p-4",
|
|
2299
2301
|
"border-gray-200 dark:border-gray-700",
|
|
2300
|
-
|
|
2302
|
+
S[a]
|
|
2301
2303
|
], l),
|
|
2302
2304
|
children: /* @__PURE__ */ t("div", {
|
|
2303
2305
|
className: "tabs-panel-inner",
|
|
@@ -2308,11 +2310,11 @@ function lr({ items: e, value: r, defaultIndex: i = 0, radius: a = "md", unstyle
|
|
|
2308
2310
|
}
|
|
2309
2311
|
//#endregion
|
|
2310
2312
|
//#region src/components/textarea/textarea.tsx
|
|
2311
|
-
function
|
|
2312
|
-
let { fieldId: g, errorId: _ } =
|
|
2313
|
+
function sr({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength: o, radius: s = "md", unstyled: c = !1, className: l, wrapperClassName: u, value: d, defaultValue: f, onChange: p, id: m, ...h }) {
|
|
2314
|
+
let { fieldId: g, errorId: _ } = V(m), { length: v, trackLength: y } = Sn(d, f), b = i && (a !== void 0 || o !== void 0), C = (e) => {
|
|
2313
2315
|
y(e.target.value), p?.(e);
|
|
2314
2316
|
};
|
|
2315
|
-
return /* @__PURE__ */ n(
|
|
2317
|
+
return /* @__PURE__ */ n(de, {
|
|
2316
2318
|
fieldId: g,
|
|
2317
2319
|
errorId: _,
|
|
2318
2320
|
label: e,
|
|
@@ -2321,19 +2323,19 @@ function ur({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength
|
|
|
2321
2323
|
wrapperClassName: u,
|
|
2322
2324
|
children: [/* @__PURE__ */ t("textarea", {
|
|
2323
2325
|
id: g,
|
|
2324
|
-
className:
|
|
2325
|
-
|
|
2326
|
-
|
|
2326
|
+
className: x("w-full min-h-[80px] resize-y disabled:opacity-50 disabled:cursor-not-allowed", !c && [
|
|
2327
|
+
B,
|
|
2328
|
+
S[s],
|
|
2327
2329
|
"px-3 py-2 text-sm"
|
|
2328
|
-
], !c && r &&
|
|
2330
|
+
], !c && r && x("border-red-500 dark:border-red-400", "focus:ring-red-500"), l),
|
|
2329
2331
|
...d === void 0 ? { defaultValue: f } : { value: d },
|
|
2330
2332
|
minLength: a,
|
|
2331
2333
|
maxLength: o,
|
|
2332
|
-
onChange:
|
|
2334
|
+
onChange: C,
|
|
2333
2335
|
"aria-invalid": !!r,
|
|
2334
2336
|
"aria-describedby": r ? _ : void 0,
|
|
2335
2337
|
...h
|
|
2336
|
-
}), b && /* @__PURE__ */ t(
|
|
2338
|
+
}), b && /* @__PURE__ */ t(R, {
|
|
2337
2339
|
current: v,
|
|
2338
2340
|
min: a,
|
|
2339
2341
|
max: o,
|
|
@@ -2344,41 +2346,41 @@ function ur({ label: e, error: r, showCharCount: i = !1, minLength: a, maxLength
|
|
|
2344
2346
|
}
|
|
2345
2347
|
//#endregion
|
|
2346
2348
|
//#region src/stores/theme_store/theme_store.ts
|
|
2347
|
-
var
|
|
2348
|
-
function
|
|
2349
|
+
var cr = "theme";
|
|
2350
|
+
function lr(e) {
|
|
2349
2351
|
return e === "light" || e === "dark" || e === "system";
|
|
2350
2352
|
}
|
|
2351
|
-
function
|
|
2353
|
+
function ur() {
|
|
2352
2354
|
return globalThis.window !== void 0 && globalThis.document !== void 0;
|
|
2353
2355
|
}
|
|
2354
|
-
function
|
|
2356
|
+
function dr(e) {
|
|
2355
2357
|
let t = window.matchMedia("(prefers-color-scheme: dark)").matches, n = e === "dark" || e === "system" && t;
|
|
2356
2358
|
document.documentElement.classList.toggle("dark", n);
|
|
2357
2359
|
}
|
|
2358
|
-
function
|
|
2359
|
-
if (!
|
|
2360
|
-
let e = globalThis.localStorage.getItem(
|
|
2361
|
-
return
|
|
2360
|
+
function fr() {
|
|
2361
|
+
if (!ur()) return "system";
|
|
2362
|
+
let e = globalThis.localStorage.getItem(cr);
|
|
2363
|
+
return lr(e) ? e : "system";
|
|
2362
2364
|
}
|
|
2363
|
-
var
|
|
2364
|
-
|
|
2365
|
-
var
|
|
2366
|
-
theme:
|
|
2365
|
+
var pr = fr();
|
|
2366
|
+
ur() && dr(pr);
|
|
2367
|
+
var mr = Un((e) => ({
|
|
2368
|
+
theme: pr,
|
|
2367
2369
|
setTheme: (t) => {
|
|
2368
|
-
|
|
2370
|
+
dr(t), ur() && globalThis.localStorage.setItem(cr, t), e({ theme: t });
|
|
2369
2371
|
}
|
|
2370
2372
|
}));
|
|
2371
|
-
|
|
2372
|
-
if (e.key !==
|
|
2373
|
-
let t =
|
|
2374
|
-
|
|
2373
|
+
ur() && (globalThis.addEventListener("storage", (e) => {
|
|
2374
|
+
if (e.key !== cr) return;
|
|
2375
|
+
let t = lr(e.newValue) ? e.newValue : "system";
|
|
2376
|
+
dr(t), mr.setState({ theme: t });
|
|
2375
2377
|
}), globalThis.matchMedia("(prefers-color-scheme: dark)").addEventListener("change", () => {
|
|
2376
|
-
|
|
2378
|
+
mr.getState().theme === "system" && dr("system");
|
|
2377
2379
|
}));
|
|
2378
2380
|
//#endregion
|
|
2379
2381
|
//#region src/lib/theme_transition.ts
|
|
2380
|
-
var
|
|
2381
|
-
async function
|
|
2382
|
+
var hr = 750, gr = "ease-in-out";
|
|
2383
|
+
async function _r({ theme: e, element: t, transitionDuration: n = hr, transitionEasing: r = gr, applyThemeCallback: i }) {
|
|
2382
2384
|
if (!document.startViewTransition || globalThis.matchMedia("(prefers-reduced-motion: reduce)").matches) {
|
|
2383
2385
|
i(e);
|
|
2384
2386
|
return;
|
|
@@ -2392,37 +2394,37 @@ async function br({ theme: e, element: t, transitionDuration: n = vr, transition
|
|
|
2392
2394
|
pseudoElement: "::view-transition-new(root)"
|
|
2393
2395
|
});
|
|
2394
2396
|
}
|
|
2395
|
-
function
|
|
2397
|
+
function vr(e) {
|
|
2396
2398
|
return e === "light" ? "dark" : e === "dark" ? "system" : "light";
|
|
2397
2399
|
}
|
|
2398
2400
|
//#endregion
|
|
2399
2401
|
//#region src/components/theme_toggle/theme_toggle.tsx
|
|
2400
|
-
var
|
|
2402
|
+
var yr = {
|
|
2401
2403
|
light: "i-tabler-sun text-yellow-500",
|
|
2402
2404
|
dark: "i-tabler-moon-stars text-gray-700 dark:text-yellow-500",
|
|
2403
2405
|
system: "i-tabler-device-desktop text-blue-500"
|
|
2404
|
-
},
|
|
2405
|
-
function
|
|
2406
|
+
}, br = "i-tabler-device-desktop text-gray-400";
|
|
2407
|
+
function xr(e) {
|
|
2406
2408
|
return `Current theme: ${e}`;
|
|
2407
2409
|
}
|
|
2408
|
-
function
|
|
2409
|
-
let c =
|
|
2410
|
-
let t =
|
|
2411
|
-
i && e ? await
|
|
2410
|
+
function Sr({ isTransitionEnabled: e = !0, transitionDuration: n, transitionEasing: r, size: i = "md", radius: a, variant: o, getAriaLabel: s = xr }) {
|
|
2411
|
+
let c = mr((e) => e.theme), u = mr((e) => e.setTheme), d = le(), f = h(null), p = l(async () => {
|
|
2412
|
+
let t = vr(c), i = f.current;
|
|
2413
|
+
i && e ? await _r({
|
|
2412
2414
|
theme: t,
|
|
2413
2415
|
element: i,
|
|
2414
2416
|
transitionDuration: n,
|
|
2415
2417
|
transitionEasing: r,
|
|
2416
|
-
applyThemeCallback:
|
|
2417
|
-
}) :
|
|
2418
|
+
applyThemeCallback: u
|
|
2419
|
+
}) : u(t);
|
|
2418
2420
|
}, [
|
|
2419
2421
|
c,
|
|
2420
2422
|
e,
|
|
2421
2423
|
n,
|
|
2422
2424
|
r,
|
|
2423
|
-
|
|
2424
|
-
]), m =
|
|
2425
|
-
return /* @__PURE__ */ t(
|
|
2425
|
+
u
|
|
2426
|
+
]), m = d ? yr[c] : br;
|
|
2427
|
+
return /* @__PURE__ */ t(bn, {
|
|
2426
2428
|
ref: f,
|
|
2427
2429
|
icon: m,
|
|
2428
2430
|
"aria-label": s(c),
|
|
@@ -2436,55 +2438,55 @@ function Tr({ isTransitionEnabled: e = !0, transitionDuration: n, transitionEasi
|
|
|
2436
2438
|
}
|
|
2437
2439
|
//#endregion
|
|
2438
2440
|
//#region src/components/tooltip/tooltip.tsx
|
|
2439
|
-
var
|
|
2441
|
+
var Cr = 8, wr = 8, Tr = {
|
|
2440
2442
|
top: "data-[state=closed]:translate-y-1",
|
|
2441
2443
|
bottom: "data-[state=closed]:-translate-y-1",
|
|
2442
2444
|
left: "data-[state=closed]:translate-x-1",
|
|
2443
2445
|
right: "data-[state=closed]:-translate-x-1"
|
|
2444
|
-
},
|
|
2446
|
+
}, Er = {
|
|
2445
2447
|
top: "bottom",
|
|
2446
2448
|
bottom: "top",
|
|
2447
2449
|
left: "right",
|
|
2448
2450
|
right: "left"
|
|
2449
2451
|
};
|
|
2450
|
-
function
|
|
2451
|
-
let { isMounted:
|
|
2452
|
-
placement:
|
|
2453
|
-
open:
|
|
2454
|
-
whileElementsMounted:
|
|
2452
|
+
function Dr({ content: r, children: i, position: o = "top", showOnClick: s = !1, temporaryContent: u, temporaryDuration: p = 2e3, disabled: m = !1, radius: _ = "lg", onTemporaryShow: v, className: b, ref: C }) {
|
|
2453
|
+
let { isMounted: w, isVisible: T, setIsVisible: E, open: D, close: O } = sn(), [k, A] = g(!1), j = f(), M = h(null), N = h(void 0), { refs: P, floatingStyles: F, placement: I, middlewareData: L, isPositioned: R } = Yt({
|
|
2454
|
+
placement: o,
|
|
2455
|
+
open: w,
|
|
2456
|
+
whileElementsMounted: Rt,
|
|
2455
2457
|
middleware: [
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2458
|
+
Zt(Cr),
|
|
2459
|
+
$t(),
|
|
2460
|
+
Qt({ padding: 8 }),
|
|
2461
|
+
en({ element: M })
|
|
2460
2462
|
]
|
|
2461
|
-
}),
|
|
2462
|
-
|
|
2463
|
-
let
|
|
2463
|
+
}), z = I.split("-")[0];
|
|
2464
|
+
cn(w, R, E);
|
|
2465
|
+
let ee = l((e) => En(P.setReference, C)(e), [P, C]), te = () => {
|
|
2464
2466
|
A(!1), O();
|
|
2467
|
+
}, ne = () => {
|
|
2468
|
+
m || !u || (A(!0), D(R), clearTimeout(N.current), N.current = setTimeout(te, p), v?.());
|
|
2469
|
+
}, B = () => {
|
|
2470
|
+
m || D(R);
|
|
2465
2471
|
}, re = () => {
|
|
2466
|
-
|
|
2467
|
-
}, ie = () => {
|
|
2468
|
-
f || D(L);
|
|
2469
|
-
}, ae = () => {
|
|
2470
|
-
clearTimeout(N.current), ne();
|
|
2472
|
+
clearTimeout(N.current), te();
|
|
2471
2473
|
};
|
|
2472
|
-
|
|
2473
|
-
let
|
|
2474
|
+
d(() => () => clearTimeout(N.current), []);
|
|
2475
|
+
let ie = w && !m, ae = k && u ? u : r, oe = {
|
|
2474
2476
|
onClick: (e) => {
|
|
2475
|
-
|
|
2477
|
+
s && u && ne(), c(i) && i.props.onClick?.(e);
|
|
2476
2478
|
},
|
|
2477
|
-
"aria-describedby":
|
|
2478
|
-
},
|
|
2479
|
+
"aria-describedby": ie ? j : void 0
|
|
2480
|
+
}, V = c(i) ? a(i, oe) : i, se = L.arrow?.x, H = L.arrow?.y, ce = Er[z];
|
|
2479
2481
|
return /* @__PURE__ */ n(e, { children: [/* @__PURE__ */ t("span", {
|
|
2480
|
-
ref:
|
|
2481
|
-
className:
|
|
2482
|
-
onMouseEnter:
|
|
2483
|
-
onMouseLeave:
|
|
2484
|
-
onFocus:
|
|
2485
|
-
onBlur:
|
|
2486
|
-
children:
|
|
2487
|
-
}),
|
|
2482
|
+
ref: ee,
|
|
2483
|
+
className: x("inline-block", b),
|
|
2484
|
+
onMouseEnter: B,
|
|
2485
|
+
onMouseLeave: re,
|
|
2486
|
+
onFocus: B,
|
|
2487
|
+
onBlur: re,
|
|
2488
|
+
children: V
|
|
2489
|
+
}), ie && y(/* @__PURE__ */ t("div", {
|
|
2488
2490
|
ref: P.setFloating,
|
|
2489
2491
|
style: F,
|
|
2490
2492
|
className: "z-50 inline-block pointer-events-none",
|
|
@@ -2492,16 +2494,16 @@ function Ar({ content: r, children: i, position: a = "top", showOnClick: o = !1,
|
|
|
2492
2494
|
id: j,
|
|
2493
2495
|
role: "tooltip",
|
|
2494
2496
|
"data-state": T ? "open" : "closed",
|
|
2495
|
-
className:
|
|
2496
|
-
children: [
|
|
2497
|
+
className: x("px-3 py-1.5 text-sm whitespace-nowrap", "text-white dark:text-gray-900 bg-gray-900 dark:bg-gray-100 shadow-lg", "transition-[opacity,transform] duration-150 ease-out", T ? "opacity-100" : "opacity-0", Tr[z], S[_]),
|
|
2498
|
+
children: [ae, /* @__PURE__ */ t("div", {
|
|
2497
2499
|
ref: M,
|
|
2498
2500
|
style: {
|
|
2499
2501
|
position: "absolute",
|
|
2500
|
-
width: `${
|
|
2501
|
-
height: `${
|
|
2502
|
-
left:
|
|
2503
|
-
top:
|
|
2504
|
-
[
|
|
2502
|
+
width: `${wr}px`,
|
|
2503
|
+
height: `${wr}px`,
|
|
2504
|
+
left: se === void 0 ? void 0 : `${se}px`,
|
|
2505
|
+
top: H === void 0 ? void 0 : `${H}px`,
|
|
2506
|
+
[ce]: `-${wr / 2}px`
|
|
2505
2507
|
},
|
|
2506
2508
|
className: "rotate-45 bg-gray-900 dark:bg-gray-100"
|
|
2507
2509
|
})]
|
|
@@ -2510,11 +2512,11 @@ function Ar({ content: r, children: i, position: a = "top", showOnClick: o = !1,
|
|
|
2510
2512
|
}
|
|
2511
2513
|
//#endregion
|
|
2512
2514
|
//#region src/hooks/use_is_client/with_client_only.tsx
|
|
2513
|
-
var
|
|
2515
|
+
var Or = (e) => {
|
|
2514
2516
|
function n(n) {
|
|
2515
|
-
return
|
|
2517
|
+
return le() ? /* @__PURE__ */ t(e, { ...n }) : null;
|
|
2516
2518
|
}
|
|
2517
2519
|
return n;
|
|
2518
2520
|
};
|
|
2519
2521
|
//#endregion
|
|
2520
|
-
export {
|
|
2522
|
+
export { B as BASE_INPUT_STYLES, M as Badge, F as Button, R as CharacterCount, ce as Checkbox, ue as ClientOnly, fe as Combobox, Xn as ConfirmModal, fn as ContextMenu, hn as CopyButton, _n as Highlight, bn as IconButton, Cn as Input, Tn as Kbd, kn as Menu, An as MenuItem, $n as Modal, er as ModalFooter, tr as ModalProvider, rr as RadioOptions, ir as Select, ar as Switch, or as Tabs, sr as Textarea, Sr as ThemeToggle, Dr as Tooltip, gn as splitIntoHighlightSegments, Kn as useDisableHotkeysWhileMounted, Wn as useGlobalHotkeysStore, le as useIsClient, mr as useThemeStore, Or as withClientOnly };
|