florixui 1.0.0 → 1.2.0
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/README.md +183 -0
- package/dist/components/custom/card-radio-group.d.ts +32 -0
- package/dist/components/custom/custom-tabs.d.ts +34 -0
- package/dist/components/custom/data-table.d.ts +7 -1
- package/dist/components/custom/def-row.d.ts +12 -0
- package/dist/components/custom/faceted-filter.d.ts +44 -0
- package/dist/components/custom/file-upload.d.ts +26 -0
- package/dist/components/custom/form-dialog.d.ts +30 -0
- package/dist/components/custom/quick-stat.d.ts +15 -0
- package/dist/components/custom/sensor-card.d.ts +45 -0
- package/dist/components/custom/side-sheet.d.ts +56 -0
- package/dist/components/custom/stat-card.d.ts +54 -0
- package/dist/components/ui/badge.d.ts +1 -1
- package/dist/components/ui/button.d.ts +8 -2
- package/dist/components/ui/item.d.ts +1 -1
- package/dist/components/ui/tabs.d.ts +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1631 -1134
- package/dist/index.js.map +1 -1
- package/dist/lib/use-file-upload.d.ts +58 -0
- package/dist/styles.css +1 -1
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -2,25 +2,205 @@ import { clsx as e } from "clsx";
|
|
|
2
2
|
import { twMerge as t } from "tailwind-merge";
|
|
3
3
|
import * as n from "react";
|
|
4
4
|
import { createContext as r, forwardRef as i, useCallback as a, useContext as o, useEffect as s, useId as c, useImperativeHandle as l, useMemo as u, useRef as d, useState as f } from "react";
|
|
5
|
-
import {
|
|
6
|
-
import { cva as
|
|
7
|
-
import { AlertDialog as
|
|
8
|
-
import { Fragment as
|
|
9
|
-
import { Command as
|
|
10
|
-
import { DayPicker as
|
|
11
|
-
import * as
|
|
12
|
-
import
|
|
5
|
+
import { AlertCircleIcon as p, Calendar as m, Check as h, CheckIcon as g, ChevronDown as _, ChevronDownIcon as v, ChevronLeftIcon as y, ChevronRightIcon as b, ChevronUpIcon as x, ChevronsLeftIcon as S, ChevronsRightIcon as C, CircleCheckIcon as w, Clock as T, Eye as E, EyeOff as ee, FileArchiveIcon as D, FileIcon as O, FileSpreadsheetIcon as k, FileTextIcon as te, HeadphonesIcon as A, ImageIcon as j, ImageUpIcon as M, InfoIcon as N, Layers as P, Loader2 as F, Loader2Icon as ne, LoaderCircleIcon as I, Locate as re, Maximize as L, Minus as ie, MoreVertical as R, OctagonXIcon as z, Plus as ae, PlusIcon as oe, SearchIcon as se, Trash2Icon as B, TriangleAlertIcon as ce, UploadIcon as V, VideoIcon as le, X as ue, XIcon as de } from "lucide-react";
|
|
6
|
+
import { cva as H } from "class-variance-authority";
|
|
7
|
+
import { AlertDialog as U, Checkbox as W, Dialog as G, DropdownMenu as K, HoverCard as fe, Label as pe, Popover as me, Progress as he, RadioGroup as ge, Select as q, Separator as _e, Slider as ve, Slot as J, Switch as ye, Tabs as be, Toggle as xe, ToggleGroup as Se, Tooltip as Ce } from "radix-ui";
|
|
8
|
+
import { Fragment as we, jsx as Y, jsxs as X } from "react/jsx-runtime";
|
|
9
|
+
import { Command as Z } from "cmdk";
|
|
10
|
+
import { DayPicker as Te, getDefaultClassNames as Ee } from "react-day-picker";
|
|
11
|
+
import * as De from "recharts";
|
|
12
|
+
import Oe from "maplibre-gl";
|
|
13
13
|
import "maplibre-gl/dist/maplibre-gl.css";
|
|
14
|
-
import { createPortal as
|
|
15
|
-
import { useTheme as
|
|
16
|
-
import { Toaster as
|
|
14
|
+
import { createPortal as ke } from "react-dom";
|
|
15
|
+
import { useTheme as Ae } from "next-themes";
|
|
16
|
+
import { Toaster as je } from "sonner";
|
|
17
17
|
//#region src/lib/utils.ts
|
|
18
|
-
function
|
|
18
|
+
function Q(...n) {
|
|
19
19
|
return t(e(n));
|
|
20
20
|
}
|
|
21
21
|
//#endregion
|
|
22
|
+
//#region src/lib/use-file-upload.ts
|
|
23
|
+
var Me = (e, t = 2) => {
|
|
24
|
+
if (e === 0) return "0 Bytes";
|
|
25
|
+
let n = 1024, r = t < 0 ? 0 : t, i = [
|
|
26
|
+
"Bytes",
|
|
27
|
+
"KB",
|
|
28
|
+
"MB",
|
|
29
|
+
"GB",
|
|
30
|
+
"TB",
|
|
31
|
+
"PB",
|
|
32
|
+
"EB",
|
|
33
|
+
"ZB",
|
|
34
|
+
"YB"
|
|
35
|
+
], a = Math.floor(Math.log(e) / Math.log(n));
|
|
36
|
+
return Number.parseFloat((e / n ** a).toFixed(r)) + i[a];
|
|
37
|
+
}, Ne = (e = {}) => {
|
|
38
|
+
let { maxFiles: t = Infinity, maxSize: n = Infinity, accept: r = "*", multiple: i = !1, initialFiles: o = [], onFilesChange: s, onFilesAdded: c } = e, [l, u] = f({
|
|
39
|
+
errors: [],
|
|
40
|
+
files: o.map((e) => ({
|
|
41
|
+
file: e,
|
|
42
|
+
id: e.id,
|
|
43
|
+
preview: e.url
|
|
44
|
+
})),
|
|
45
|
+
isDragging: !1
|
|
46
|
+
}), p = d(null), m = a((e) => {
|
|
47
|
+
if (e.size > n) return `File "${e.name}" exceeds the maximum size of ${Me(n)}.`;
|
|
48
|
+
if (r !== "*") {
|
|
49
|
+
let t = r.split(",").map((e) => e.trim()), n = e instanceof File ? e.type || "" : e.type, i = `.${e.name.split(".").pop()}`;
|
|
50
|
+
if (!t.some((e) => {
|
|
51
|
+
if (e.startsWith(".")) return i.toLowerCase() === e.toLowerCase();
|
|
52
|
+
if (e.endsWith("/*")) {
|
|
53
|
+
let t = e.split("/")[0];
|
|
54
|
+
return n.startsWith(`${t}/`);
|
|
55
|
+
}
|
|
56
|
+
return n === e;
|
|
57
|
+
})) return `File "${e.name}" is not an accepted file type.`;
|
|
58
|
+
}
|
|
59
|
+
return null;
|
|
60
|
+
}, [r, n]), h = a((e) => e instanceof File ? URL.createObjectURL(e) : e.url, []), g = a((e) => e instanceof File ? `${e.name}-${Date.now()}-${Math.random().toString(36).substring(2, 9)}` : e.id, []), _ = a(() => {
|
|
61
|
+
u((e) => {
|
|
62
|
+
for (let t of e.files ?? []) t.preview && t.file instanceof File && t.file.type.startsWith("image/") && URL.revokeObjectURL(t.preview);
|
|
63
|
+
p.current && (p.current.value = "");
|
|
64
|
+
let t = {
|
|
65
|
+
...e,
|
|
66
|
+
errors: [],
|
|
67
|
+
files: []
|
|
68
|
+
};
|
|
69
|
+
return s?.(t.files), t;
|
|
70
|
+
});
|
|
71
|
+
}, [s]), v = a((e) => {
|
|
72
|
+
if (!e || e.length === 0) return;
|
|
73
|
+
let r = Array.from(e), a = [];
|
|
74
|
+
if (u((e) => ({
|
|
75
|
+
...e,
|
|
76
|
+
errors: []
|
|
77
|
+
})), i || _(), i && t !== Infinity && l.files.length + r.length > t) {
|
|
78
|
+
a.push(`You can only upload a maximum of ${t} files.`), u((e) => ({
|
|
79
|
+
...e,
|
|
80
|
+
errors: a
|
|
81
|
+
}));
|
|
82
|
+
return;
|
|
83
|
+
}
|
|
84
|
+
let o = [];
|
|
85
|
+
for (let e of r) {
|
|
86
|
+
if (i && l.files.some((t) => t.file.name === e.name && t.file.size === e.size)) continue;
|
|
87
|
+
if (e.size > n) {
|
|
88
|
+
a.push(i ? `Some files exceed the maximum size of ${Me(n)}.` : `File exceeds the maximum size of ${Me(n)}.`);
|
|
89
|
+
continue;
|
|
90
|
+
}
|
|
91
|
+
let t = m(e);
|
|
92
|
+
if (t) {
|
|
93
|
+
a.push(t);
|
|
94
|
+
continue;
|
|
95
|
+
}
|
|
96
|
+
o.push({
|
|
97
|
+
file: e,
|
|
98
|
+
id: g(e),
|
|
99
|
+
preview: h(e)
|
|
100
|
+
});
|
|
101
|
+
}
|
|
102
|
+
o.length > 0 ? (c?.(o), u((e) => {
|
|
103
|
+
let t = i ? [...e.files, ...o] : o;
|
|
104
|
+
return s?.(t), {
|
|
105
|
+
...e,
|
|
106
|
+
errors: a,
|
|
107
|
+
files: t
|
|
108
|
+
};
|
|
109
|
+
})) : a.length > 0 && u((e) => ({
|
|
110
|
+
...e,
|
|
111
|
+
errors: a
|
|
112
|
+
})), p.current && (p.current.value = "");
|
|
113
|
+
}, [
|
|
114
|
+
l.files,
|
|
115
|
+
t,
|
|
116
|
+
i,
|
|
117
|
+
n,
|
|
118
|
+
m,
|
|
119
|
+
h,
|
|
120
|
+
g,
|
|
121
|
+
_,
|
|
122
|
+
s,
|
|
123
|
+
c
|
|
124
|
+
]), y = a((e) => {
|
|
125
|
+
u((t) => {
|
|
126
|
+
let n = t.files.find((t) => t.id === e);
|
|
127
|
+
n?.preview && n.file instanceof File && n.file.type.startsWith("image/") && URL.revokeObjectURL(n.preview);
|
|
128
|
+
let r = t.files.filter((t) => t.id !== e);
|
|
129
|
+
return s?.(r), {
|
|
130
|
+
...t,
|
|
131
|
+
errors: [],
|
|
132
|
+
files: r
|
|
133
|
+
};
|
|
134
|
+
});
|
|
135
|
+
}, [s]), b = a(() => {
|
|
136
|
+
u((e) => ({
|
|
137
|
+
...e,
|
|
138
|
+
errors: []
|
|
139
|
+
}));
|
|
140
|
+
}, []), x = a((e) => {
|
|
141
|
+
e.preventDefault(), e.stopPropagation(), u((e) => ({
|
|
142
|
+
...e,
|
|
143
|
+
isDragging: !0
|
|
144
|
+
}));
|
|
145
|
+
}, []), S = a((e) => {
|
|
146
|
+
e.preventDefault(), e.stopPropagation(), !e.currentTarget.contains(e.relatedTarget) && u((e) => ({
|
|
147
|
+
...e,
|
|
148
|
+
isDragging: !1
|
|
149
|
+
}));
|
|
150
|
+
}, []), C = a((e) => {
|
|
151
|
+
e.preventDefault(), e.stopPropagation();
|
|
152
|
+
}, []), w = a((e) => {
|
|
153
|
+
if (e.preventDefault(), e.stopPropagation(), u((e) => ({
|
|
154
|
+
...e,
|
|
155
|
+
isDragging: !1
|
|
156
|
+
})), !p.current?.disabled && e.dataTransfer.files && e.dataTransfer.files.length > 0) if (i) v(e.dataTransfer.files);
|
|
157
|
+
else {
|
|
158
|
+
let t = e.dataTransfer.files[0];
|
|
159
|
+
v([t]);
|
|
160
|
+
}
|
|
161
|
+
}, [v, i]), T = a((e) => {
|
|
162
|
+
e.target.files && e.target.files.length > 0 && v(e.target.files);
|
|
163
|
+
}, [v]), E = a(() => {
|
|
164
|
+
p.current && p.current.click();
|
|
165
|
+
}, []);
|
|
166
|
+
return [l, {
|
|
167
|
+
addFiles: v,
|
|
168
|
+
clearErrors: b,
|
|
169
|
+
clearFiles: _,
|
|
170
|
+
getInputProps: a((e = {}) => ({
|
|
171
|
+
...e,
|
|
172
|
+
accept: e.accept || r,
|
|
173
|
+
multiple: e.multiple === void 0 ? i : e.multiple,
|
|
174
|
+
onChange: T,
|
|
175
|
+
ref: p,
|
|
176
|
+
type: "file"
|
|
177
|
+
}), [
|
|
178
|
+
r,
|
|
179
|
+
i,
|
|
180
|
+
T
|
|
181
|
+
]),
|
|
182
|
+
handleDragEnter: x,
|
|
183
|
+
handleDragLeave: S,
|
|
184
|
+
handleDragOver: C,
|
|
185
|
+
handleDrop: w,
|
|
186
|
+
handleFileChange: T,
|
|
187
|
+
openFileDialog: E,
|
|
188
|
+
removeFile: y
|
|
189
|
+
}];
|
|
190
|
+
};
|
|
191
|
+
//#endregion
|
|
192
|
+
//#region src/components/ui/spinner.tsx
|
|
193
|
+
function Pe({ className: e, ...t }) {
|
|
194
|
+
return /* @__PURE__ */ Y(ne, {
|
|
195
|
+
role: "status",
|
|
196
|
+
"aria-label": "Loading",
|
|
197
|
+
className: Q("size-4 animate-spin", e),
|
|
198
|
+
...t
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
//#endregion
|
|
22
202
|
//#region src/components/ui/button.tsx
|
|
23
|
-
var
|
|
203
|
+
var Fe = H("group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
24
204
|
variants: {
|
|
25
205
|
variant: {
|
|
26
206
|
default: "bg-primary text-primary-foreground hover:bg-primary/80",
|
|
@@ -46,178 +226,188 @@ var be = P("group/button inline-flex shrink-0 items-center justify-center rounde
|
|
|
46
226
|
size: "default"
|
|
47
227
|
}
|
|
48
228
|
});
|
|
49
|
-
function
|
|
50
|
-
|
|
229
|
+
function $({ className: e, variant: t = "default", size: n = "default", asChild: r = !1, loading: i = !1, startItem: a, endItem: o, disabled: s, children: c, ...l }) {
|
|
230
|
+
let u = r ? J.Root : "button", d = r ? c : /* @__PURE__ */ X(we, { children: [
|
|
231
|
+
i ? /* @__PURE__ */ Y(Pe, {}) : a,
|
|
232
|
+
c,
|
|
233
|
+
o
|
|
234
|
+
] });
|
|
235
|
+
return /* @__PURE__ */ Y(u, {
|
|
51
236
|
"data-slot": "button",
|
|
52
237
|
"data-variant": t,
|
|
53
238
|
"data-size": n,
|
|
54
|
-
|
|
239
|
+
"data-loading": i || void 0,
|
|
240
|
+
disabled: s ?? (u === "button" ? i : void 0),
|
|
241
|
+
"aria-disabled": i || void 0,
|
|
242
|
+
"aria-busy": i || void 0,
|
|
243
|
+
className: Q(Fe({
|
|
55
244
|
variant: t,
|
|
56
245
|
size: n,
|
|
57
246
|
className: e
|
|
58
247
|
})),
|
|
59
|
-
...
|
|
248
|
+
...l,
|
|
249
|
+
children: d
|
|
60
250
|
});
|
|
61
251
|
}
|
|
62
252
|
//#endregion
|
|
63
253
|
//#region src/components/ui/dropdown-menu.tsx
|
|
64
|
-
function
|
|
65
|
-
return /* @__PURE__ */
|
|
254
|
+
function Ie({ ...e }) {
|
|
255
|
+
return /* @__PURE__ */ Y(K.Root, {
|
|
66
256
|
"data-slot": "dropdown-menu",
|
|
67
257
|
...e
|
|
68
258
|
});
|
|
69
259
|
}
|
|
70
|
-
function
|
|
71
|
-
return /* @__PURE__ */
|
|
260
|
+
function Le({ ...e }) {
|
|
261
|
+
return /* @__PURE__ */ Y(K.Portal, {
|
|
72
262
|
"data-slot": "dropdown-menu-portal",
|
|
73
263
|
...e
|
|
74
264
|
});
|
|
75
265
|
}
|
|
76
|
-
function
|
|
77
|
-
return /* @__PURE__ */
|
|
266
|
+
function Re({ ...e }) {
|
|
267
|
+
return /* @__PURE__ */ Y(K.Trigger, {
|
|
78
268
|
"data-slot": "dropdown-menu-trigger",
|
|
79
269
|
...e
|
|
80
270
|
});
|
|
81
271
|
}
|
|
82
|
-
function
|
|
83
|
-
return /* @__PURE__ */
|
|
272
|
+
function ze({ className: e, align: t = "start", sideOffset: n = 4, ...r }) {
|
|
273
|
+
return /* @__PURE__ */ Y(K.Portal, { children: /* @__PURE__ */ Y(K.Content, {
|
|
84
274
|
"data-slot": "dropdown-menu-content",
|
|
85
275
|
sideOffset: n,
|
|
86
276
|
align: t,
|
|
87
|
-
className:
|
|
277
|
+
className: Q("z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:overflow-hidden data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
88
278
|
...r
|
|
89
279
|
}) });
|
|
90
280
|
}
|
|
91
|
-
function
|
|
92
|
-
return /* @__PURE__ */
|
|
281
|
+
function Be({ ...e }) {
|
|
282
|
+
return /* @__PURE__ */ Y(K.Group, {
|
|
93
283
|
"data-slot": "dropdown-menu-group",
|
|
94
284
|
...e
|
|
95
285
|
});
|
|
96
286
|
}
|
|
97
|
-
function
|
|
98
|
-
return /* @__PURE__ */
|
|
287
|
+
function Ve({ className: e, inset: t, variant: n = "default", ...r }) {
|
|
288
|
+
return /* @__PURE__ */ Y(K.Item, {
|
|
99
289
|
"data-slot": "dropdown-menu-item",
|
|
100
290
|
"data-inset": t,
|
|
101
291
|
"data-variant": n,
|
|
102
|
-
className:
|
|
292
|
+
className: Q("group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive", e),
|
|
103
293
|
...r
|
|
104
294
|
});
|
|
105
295
|
}
|
|
106
|
-
function
|
|
107
|
-
return /* @__PURE__ */
|
|
296
|
+
function He({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
297
|
+
return /* @__PURE__ */ X(K.CheckboxItem, {
|
|
108
298
|
"data-slot": "dropdown-menu-checkbox-item",
|
|
109
299
|
"data-inset": r,
|
|
110
|
-
className:
|
|
300
|
+
className: Q("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", e),
|
|
111
301
|
checked: n,
|
|
112
302
|
...i,
|
|
113
|
-
children: [/* @__PURE__ */
|
|
303
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
114
304
|
className: "pointer-events-none absolute right-2 flex items-center justify-center",
|
|
115
305
|
"data-slot": "dropdown-menu-checkbox-item-indicator",
|
|
116
|
-
children: /* @__PURE__ */
|
|
306
|
+
children: /* @__PURE__ */ Y(K.ItemIndicator, { children: /* @__PURE__ */ Y(g, {}) })
|
|
117
307
|
}), t]
|
|
118
308
|
});
|
|
119
309
|
}
|
|
120
|
-
function
|
|
121
|
-
return /* @__PURE__ */
|
|
310
|
+
function Ue({ ...e }) {
|
|
311
|
+
return /* @__PURE__ */ Y(K.RadioGroup, {
|
|
122
312
|
"data-slot": "dropdown-menu-radio-group",
|
|
123
313
|
...e
|
|
124
314
|
});
|
|
125
315
|
}
|
|
126
|
-
function
|
|
127
|
-
return /* @__PURE__ */
|
|
316
|
+
function We({ className: e, children: t, inset: n, ...r }) {
|
|
317
|
+
return /* @__PURE__ */ X(K.RadioItem, {
|
|
128
318
|
"data-slot": "dropdown-menu-radio-item",
|
|
129
319
|
"data-inset": n,
|
|
130
|
-
className:
|
|
320
|
+
className: Q("relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", e),
|
|
131
321
|
...r,
|
|
132
|
-
children: [/* @__PURE__ */
|
|
322
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
133
323
|
className: "pointer-events-none absolute right-2 flex items-center justify-center",
|
|
134
324
|
"data-slot": "dropdown-menu-radio-item-indicator",
|
|
135
|
-
children: /* @__PURE__ */
|
|
325
|
+
children: /* @__PURE__ */ Y(K.ItemIndicator, { children: /* @__PURE__ */ Y(g, {}) })
|
|
136
326
|
}), t]
|
|
137
327
|
});
|
|
138
328
|
}
|
|
139
|
-
function
|
|
140
|
-
return /* @__PURE__ */
|
|
329
|
+
function Ge({ className: e, inset: t, ...n }) {
|
|
330
|
+
return /* @__PURE__ */ Y(K.Label, {
|
|
141
331
|
"data-slot": "dropdown-menu-label",
|
|
142
332
|
"data-inset": t,
|
|
143
|
-
className:
|
|
333
|
+
className: Q("px-1.5 py-1 text-xs font-medium text-muted-foreground data-inset:pl-7", e),
|
|
144
334
|
...n
|
|
145
335
|
});
|
|
146
336
|
}
|
|
147
|
-
function
|
|
148
|
-
return /* @__PURE__ */
|
|
337
|
+
function Ke({ className: e, ...t }) {
|
|
338
|
+
return /* @__PURE__ */ Y(K.Separator, {
|
|
149
339
|
"data-slot": "dropdown-menu-separator",
|
|
150
|
-
className:
|
|
340
|
+
className: Q("-mx-1 my-1 h-px bg-border", e),
|
|
151
341
|
...t
|
|
152
342
|
});
|
|
153
343
|
}
|
|
154
|
-
function
|
|
155
|
-
return /* @__PURE__ */
|
|
344
|
+
function qe({ className: e, ...t }) {
|
|
345
|
+
return /* @__PURE__ */ Y("span", {
|
|
156
346
|
"data-slot": "dropdown-menu-shortcut",
|
|
157
|
-
className:
|
|
347
|
+
className: Q("ml-auto text-xs tracking-widest text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground", e),
|
|
158
348
|
...t
|
|
159
349
|
});
|
|
160
350
|
}
|
|
161
|
-
function
|
|
162
|
-
return /* @__PURE__ */
|
|
351
|
+
function Je({ ...e }) {
|
|
352
|
+
return /* @__PURE__ */ Y(K.Sub, {
|
|
163
353
|
"data-slot": "dropdown-menu-sub",
|
|
164
354
|
...e
|
|
165
355
|
});
|
|
166
356
|
}
|
|
167
|
-
function
|
|
168
|
-
return /* @__PURE__ */
|
|
357
|
+
function Ye({ className: e, inset: t, children: n, ...r }) {
|
|
358
|
+
return /* @__PURE__ */ X(K.SubTrigger, {
|
|
169
359
|
"data-slot": "dropdown-menu-sub-trigger",
|
|
170
360
|
"data-inset": t,
|
|
171
|
-
className:
|
|
361
|
+
className: Q("flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-open:bg-accent data-open:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", e),
|
|
172
362
|
...r,
|
|
173
|
-
children: [n, /* @__PURE__ */
|
|
363
|
+
children: [n, /* @__PURE__ */ Y(b, { className: "ml-auto" })]
|
|
174
364
|
});
|
|
175
365
|
}
|
|
176
|
-
function
|
|
177
|
-
return /* @__PURE__ */
|
|
366
|
+
function Xe({ className: e, ...t }) {
|
|
367
|
+
return /* @__PURE__ */ Y(K.SubContent, {
|
|
178
368
|
"data-slot": "dropdown-menu-sub-content",
|
|
179
|
-
className:
|
|
369
|
+
className: Q("z-50 min-w-[96px] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-lg bg-popover p-1 text-popover-foreground shadow-lg ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
180
370
|
...t
|
|
181
371
|
});
|
|
182
372
|
}
|
|
183
373
|
//#endregion
|
|
184
374
|
//#region src/components/custom/actions-menu.tsx
|
|
185
|
-
var
|
|
186
|
-
function
|
|
375
|
+
var Ze = 16;
|
|
376
|
+
function Qe(e) {
|
|
187
377
|
return e.type === void 0 || e.type === "action";
|
|
188
378
|
}
|
|
189
|
-
function
|
|
190
|
-
return /* @__PURE__ */
|
|
379
|
+
function $e({ items: e, trigger: t, triggerIcon: n = R, triggerLabel: r = "Open menu", width: i = "10rem", align: a = "end", className: o, open: s, onOpenChange: c }) {
|
|
380
|
+
return /* @__PURE__ */ X(Ie, {
|
|
191
381
|
open: s,
|
|
192
382
|
onOpenChange: c,
|
|
193
|
-
children: [/* @__PURE__ */
|
|
383
|
+
children: [/* @__PURE__ */ Y(Re, {
|
|
194
384
|
asChild: !0,
|
|
195
|
-
children: t ?? /* @__PURE__ */
|
|
385
|
+
children: t ?? /* @__PURE__ */ X($, {
|
|
196
386
|
variant: "ghost",
|
|
197
387
|
size: "icon",
|
|
198
|
-
className:
|
|
388
|
+
className: Q("size-8", o),
|
|
199
389
|
"aria-label": r,
|
|
200
|
-
children: [/* @__PURE__ */
|
|
390
|
+
children: [/* @__PURE__ */ Y(n, { size: Ze }), /* @__PURE__ */ Y("span", {
|
|
201
391
|
className: "sr-only",
|
|
202
392
|
children: r
|
|
203
393
|
})]
|
|
204
394
|
})
|
|
205
|
-
}), /* @__PURE__ */
|
|
395
|
+
}), /* @__PURE__ */ Y(ze, {
|
|
206
396
|
align: a,
|
|
207
397
|
style: { width: i },
|
|
208
398
|
children: e.map((e, t) => {
|
|
209
|
-
if (e.type === "separator") return /* @__PURE__ */
|
|
210
|
-
if (e.type === "label") return /* @__PURE__ */
|
|
211
|
-
if (!
|
|
399
|
+
if (e.type === "separator") return /* @__PURE__ */ Y(Ke, {}, `sep-${t}`);
|
|
400
|
+
if (e.type === "label") return /* @__PURE__ */ Y(Ge, { children: e.label }, `label-${t}`);
|
|
401
|
+
if (!Qe(e)) return null;
|
|
212
402
|
let n = e.icon;
|
|
213
|
-
return /* @__PURE__ */
|
|
403
|
+
return /* @__PURE__ */ X(Ve, {
|
|
214
404
|
onSelect: e.onSelect,
|
|
215
405
|
disabled: e.disabled,
|
|
216
406
|
variant: e.destructive ? "destructive" : "default",
|
|
217
407
|
children: [
|
|
218
|
-
n && /* @__PURE__ */
|
|
408
|
+
n && /* @__PURE__ */ Y(n, { size: Ze }),
|
|
219
409
|
e.label,
|
|
220
|
-
e.shortcut && /* @__PURE__ */
|
|
410
|
+
e.shortcut && /* @__PURE__ */ Y(qe, { children: e.shortcut })
|
|
221
411
|
]
|
|
222
412
|
}, t);
|
|
223
413
|
})
|
|
@@ -226,49 +416,49 @@ function Re({ items: e, trigger: t, triggerIcon: n = j, triggerLabel: r = "Open
|
|
|
226
416
|
}
|
|
227
417
|
//#endregion
|
|
228
418
|
//#region src/components/ui/label.tsx
|
|
229
|
-
function
|
|
230
|
-
return /* @__PURE__ */
|
|
419
|
+
function et({ className: e, ...t }) {
|
|
420
|
+
return /* @__PURE__ */ Y(pe.Root, {
|
|
231
421
|
"data-slot": "label",
|
|
232
|
-
className:
|
|
422
|
+
className: Q("flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50", e),
|
|
233
423
|
...t
|
|
234
424
|
});
|
|
235
425
|
}
|
|
236
426
|
//#endregion
|
|
237
427
|
//#region src/components/ui/separator.tsx
|
|
238
|
-
function
|
|
239
|
-
return /* @__PURE__ */
|
|
428
|
+
function tt({ className: e, orientation: t = "horizontal", decorative: n = !0, ...r }) {
|
|
429
|
+
return /* @__PURE__ */ Y(_e.Root, {
|
|
240
430
|
"data-slot": "separator",
|
|
241
431
|
decorative: n,
|
|
242
432
|
orientation: t,
|
|
243
|
-
className:
|
|
433
|
+
className: Q("shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch", e),
|
|
244
434
|
...r
|
|
245
435
|
});
|
|
246
436
|
}
|
|
247
437
|
//#endregion
|
|
248
438
|
//#region src/components/ui/field.tsx
|
|
249
|
-
function
|
|
250
|
-
return /* @__PURE__ */
|
|
439
|
+
function nt({ className: e, ...t }) {
|
|
440
|
+
return /* @__PURE__ */ Y("fieldset", {
|
|
251
441
|
"data-slot": "field-set",
|
|
252
|
-
className:
|
|
442
|
+
className: Q("flex flex-col gap-4 has-[>[data-slot=checkbox-group]]:gap-3 has-[>[data-slot=radio-group]]:gap-3", e),
|
|
253
443
|
...t
|
|
254
444
|
});
|
|
255
445
|
}
|
|
256
|
-
function
|
|
257
|
-
return /* @__PURE__ */
|
|
446
|
+
function rt({ className: e, variant: t = "legend", ...n }) {
|
|
447
|
+
return /* @__PURE__ */ Y("legend", {
|
|
258
448
|
"data-slot": "field-legend",
|
|
259
449
|
"data-variant": t,
|
|
260
|
-
className:
|
|
450
|
+
className: Q("mb-1.5 font-medium data-[variant=label]:text-sm data-[variant=legend]:text-base", e),
|
|
261
451
|
...n
|
|
262
452
|
});
|
|
263
453
|
}
|
|
264
|
-
function
|
|
265
|
-
return /* @__PURE__ */
|
|
454
|
+
function it({ className: e, ...t }) {
|
|
455
|
+
return /* @__PURE__ */ Y("div", {
|
|
266
456
|
"data-slot": "field-group",
|
|
267
|
-
className:
|
|
457
|
+
className: Q("group/field-group @container/field-group flex w-full flex-col gap-5 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4", e),
|
|
268
458
|
...t
|
|
269
459
|
});
|
|
270
460
|
}
|
|
271
|
-
var
|
|
461
|
+
var at = H("group/field flex w-full gap-2 data-[invalid=true]:text-destructive", {
|
|
272
462
|
variants: { orientation: {
|
|
273
463
|
vertical: "flex-col *:w-full [&>.sr-only]:w-auto",
|
|
274
464
|
horizontal: "flex-row items-center has-[>[data-slot=field-content]]:items-start *:data-[slot=field-label]:flex-auto has-[>[data-slot=field-content]]:[&>[role=checkbox],[role=radio]]:mt-px",
|
|
@@ -276,262 +466,485 @@ var We = P("group/field flex w-full gap-2 data-[invalid=true]:text-destructive",
|
|
|
276
466
|
} },
|
|
277
467
|
defaultVariants: { orientation: "vertical" }
|
|
278
468
|
});
|
|
279
|
-
function
|
|
280
|
-
return /* @__PURE__ */
|
|
469
|
+
function ot({ className: e, orientation: t = "vertical", ...n }) {
|
|
470
|
+
return /* @__PURE__ */ Y("div", {
|
|
281
471
|
role: "group",
|
|
282
472
|
"data-slot": "field",
|
|
283
473
|
"data-orientation": t,
|
|
284
|
-
className:
|
|
474
|
+
className: Q(at({ orientation: t }), e),
|
|
285
475
|
...n
|
|
286
476
|
});
|
|
287
477
|
}
|
|
288
|
-
function
|
|
289
|
-
return /* @__PURE__ */
|
|
478
|
+
function st({ className: e, ...t }) {
|
|
479
|
+
return /* @__PURE__ */ Y("div", {
|
|
290
480
|
"data-slot": "field-content",
|
|
291
|
-
className:
|
|
481
|
+
className: Q("group/field-content flex flex-1 flex-col gap-0.5 leading-snug", e),
|
|
292
482
|
...t
|
|
293
483
|
});
|
|
294
484
|
}
|
|
295
|
-
function
|
|
296
|
-
return /* @__PURE__ */
|
|
485
|
+
function ct({ className: e, ...t }) {
|
|
486
|
+
return /* @__PURE__ */ Y(et, {
|
|
297
487
|
"data-slot": "field-label",
|
|
298
|
-
className:
|
|
488
|
+
className: Q("group/field-label peer/field-label flex w-fit gap-2 leading-snug group-data-[disabled=true]/field:opacity-50 has-data-checked:border-primary/30 has-data-checked:bg-primary/5 has-[>[data-slot=field]]:rounded-lg has-[>[data-slot=field]]:border *:data-[slot=field]:p-2.5 dark:has-data-checked:border-primary/20 dark:has-data-checked:bg-primary/10", "has-[>[data-slot=field]]:w-full has-[>[data-slot=field]]:flex-col", e),
|
|
299
489
|
...t
|
|
300
490
|
});
|
|
301
491
|
}
|
|
302
|
-
function
|
|
303
|
-
return /* @__PURE__ */
|
|
492
|
+
function lt({ className: e, ...t }) {
|
|
493
|
+
return /* @__PURE__ */ Y("div", {
|
|
304
494
|
"data-slot": "field-label",
|
|
305
|
-
className:
|
|
495
|
+
className: Q("flex w-fit items-center gap-2 text-sm font-medium group-data-[disabled=true]/field:opacity-50", e),
|
|
306
496
|
...t
|
|
307
497
|
});
|
|
308
498
|
}
|
|
309
|
-
function
|
|
310
|
-
return /* @__PURE__ */
|
|
499
|
+
function ut({ className: e, ...t }) {
|
|
500
|
+
return /* @__PURE__ */ Y("p", {
|
|
311
501
|
"data-slot": "field-description",
|
|
312
|
-
className:
|
|
502
|
+
className: Q("text-left text-sm leading-normal font-normal text-muted-foreground group-has-data-horizontal/field:text-balance [[data-variant=legend]+&]:-mt-1.5", "last:mt-0 nth-last-2:-mt-1", "[&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", e),
|
|
313
503
|
...t
|
|
314
504
|
});
|
|
315
505
|
}
|
|
316
|
-
function
|
|
317
|
-
return /* @__PURE__ */
|
|
506
|
+
function dt({ children: e, className: t, ...n }) {
|
|
507
|
+
return /* @__PURE__ */ X("div", {
|
|
318
508
|
"data-slot": "field-separator",
|
|
319
509
|
"data-content": !!e,
|
|
320
|
-
className:
|
|
510
|
+
className: Q("relative -my-2 h-5 text-sm group-data-[variant=outline]/field-group:-mb-2", t),
|
|
321
511
|
...n,
|
|
322
|
-
children: [/* @__PURE__ */
|
|
512
|
+
children: [/* @__PURE__ */ Y(tt, { className: "absolute inset-0 top-1/2" }), e && /* @__PURE__ */ Y("span", {
|
|
323
513
|
className: "relative mx-auto block w-fit bg-background px-2 text-muted-foreground",
|
|
324
514
|
"data-slot": "field-separator-content",
|
|
325
515
|
children: e
|
|
326
516
|
})]
|
|
327
517
|
});
|
|
328
518
|
}
|
|
329
|
-
function
|
|
519
|
+
function ft({ className: e, children: t, errors: n, ...r }) {
|
|
330
520
|
let i = u(() => {
|
|
331
521
|
if (t) return t;
|
|
332
522
|
if (!n?.length) return null;
|
|
333
523
|
let e = [...new Map(n.map((e) => [e?.message, e])).values()];
|
|
334
|
-
return e?.length == 1 ? e[0]?.message : /* @__PURE__ */
|
|
524
|
+
return e?.length == 1 ? e[0]?.message : /* @__PURE__ */ Y("ul", {
|
|
335
525
|
className: "ml-4 flex list-disc flex-col gap-1",
|
|
336
|
-
children: e.map((e, t) => e?.message && /* @__PURE__ */
|
|
526
|
+
children: e.map((e, t) => e?.message && /* @__PURE__ */ Y("li", { children: e.message }, t))
|
|
337
527
|
});
|
|
338
528
|
}, [t, n]);
|
|
339
|
-
return i ? /* @__PURE__ */
|
|
529
|
+
return i ? /* @__PURE__ */ Y("div", {
|
|
340
530
|
role: "alert",
|
|
341
531
|
"data-slot": "field-error",
|
|
342
|
-
className:
|
|
532
|
+
className: Q("text-sm font-normal text-destructive", e),
|
|
343
533
|
...r,
|
|
344
534
|
children: i
|
|
345
535
|
}) : null;
|
|
346
536
|
}
|
|
347
537
|
//#endregion
|
|
348
538
|
//#region src/components/custom/advanced-input.tsx
|
|
349
|
-
function
|
|
350
|
-
return !t && !n ? null : /* @__PURE__ */
|
|
539
|
+
function pt({ error: e, errorMessage: t, helperText: n, errorId: r, helperId: i }) {
|
|
540
|
+
return !t && !n ? null : /* @__PURE__ */ Y("div", {
|
|
351
541
|
className: "mt-1.5 min-h-5",
|
|
352
|
-
children: e && t ? /* @__PURE__ */
|
|
542
|
+
children: e && t ? /* @__PURE__ */ Y("p", {
|
|
353
543
|
id: r,
|
|
354
544
|
className: "text-xs leading-5 text-destructive",
|
|
355
545
|
children: t
|
|
356
|
-
}) : !e && n ? /* @__PURE__ */
|
|
546
|
+
}) : !e && n ? /* @__PURE__ */ Y("p", {
|
|
357
547
|
id: i,
|
|
358
548
|
className: "text-xs leading-5 text-muted-foreground",
|
|
359
549
|
children: n
|
|
360
550
|
}) : null
|
|
361
551
|
});
|
|
362
552
|
}
|
|
363
|
-
var
|
|
364
|
-
let { className: r, wrapperClassName: i, label: a, description: o, errorMessage: s, helperText: c, required: l = !1, size: u = "default", variant: d = "default", leftIcon: f, rightIcon: p, disabled: m, startItem: h, endItem: g, loading: _ = !1, as: v = "input", id: y, error: b, ...x } = e, S = b ?? !!s,
|
|
365
|
-
S && s ?
|
|
366
|
-
!S && c ?
|
|
553
|
+
var mt = n.forwardRef(function(e, t) {
|
|
554
|
+
let { className: r, wrapperClassName: i, label: a, description: o, errorMessage: s, helperText: c, required: l = !1, size: u = "default", variant: d = "default", leftIcon: f, rightIcon: p, disabled: m, startItem: h, endItem: g, loading: _ = !1, as: v = "input", id: y, error: b, ...x } = e, S = b ?? !!s, C = n.useId(), w = y || C, [T, D] = n.useState(!1), O = `${w}-error`, k = `${w}-helper`, te = `${w}-description`, A = [
|
|
555
|
+
S && s ? O : null,
|
|
556
|
+
!S && c ? k : null,
|
|
367
557
|
o ? te : null
|
|
368
|
-
].filter(Boolean).join(" ") || void 0,
|
|
558
|
+
].filter(Boolean).join(" ") || void 0, j = d === "alt" ? "bg-muted" : "bg-transparent dark:bg-input/30", M = l ? /* @__PURE__ */ Y("span", {
|
|
369
559
|
"aria-hidden": !0,
|
|
370
560
|
className: "ml-0.5 text-destructive",
|
|
371
561
|
children: "*"
|
|
372
562
|
}) : null;
|
|
373
563
|
if (v === "textarea") {
|
|
374
564
|
let e = x;
|
|
375
|
-
return /* @__PURE__ */
|
|
376
|
-
className:
|
|
565
|
+
return /* @__PURE__ */ X("div", {
|
|
566
|
+
className: Q("space-y-1.5", i),
|
|
377
567
|
children: [
|
|
378
|
-
a && /* @__PURE__ */
|
|
379
|
-
htmlFor:
|
|
380
|
-
className:
|
|
381
|
-
children: [a,
|
|
568
|
+
a && /* @__PURE__ */ X(ct, {
|
|
569
|
+
htmlFor: w,
|
|
570
|
+
className: Q(m && "text-muted-foreground"),
|
|
571
|
+
children: [a, M]
|
|
382
572
|
}),
|
|
383
|
-
/* @__PURE__ */
|
|
384
|
-
id:
|
|
573
|
+
/* @__PURE__ */ Y("textarea", {
|
|
574
|
+
id: w,
|
|
385
575
|
ref: t,
|
|
386
576
|
disabled: m,
|
|
387
577
|
"aria-invalid": S,
|
|
388
|
-
"aria-describedby":
|
|
389
|
-
className:
|
|
578
|
+
"aria-describedby": A,
|
|
579
|
+
className: Q("flex min-h-20 w-full rounded-lg border border-input px-3 py-2 text-base outline-none transition-colors placeholder:text-muted-foreground md:text-sm", j, "focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", "disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50", "aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40", r),
|
|
390
580
|
...e
|
|
391
581
|
}),
|
|
392
|
-
/* @__PURE__ */
|
|
582
|
+
/* @__PURE__ */ Y(pt, {
|
|
393
583
|
error: S,
|
|
394
584
|
errorMessage: s,
|
|
395
585
|
helperText: c,
|
|
396
|
-
errorId:
|
|
397
|
-
helperId:
|
|
586
|
+
errorId: O,
|
|
587
|
+
helperId: k
|
|
398
588
|
}),
|
|
399
|
-
o && /* @__PURE__ */
|
|
589
|
+
o && /* @__PURE__ */ Y(ut, {
|
|
400
590
|
id: te,
|
|
401
591
|
children: o
|
|
402
592
|
})
|
|
403
593
|
]
|
|
404
594
|
});
|
|
405
595
|
}
|
|
406
|
-
let { type:
|
|
596
|
+
let { type: N, onFocus: P, ...ne } = x, I = N ?? "text", re = I === "password", L = re && T ? "text" : I, ie = re ? /* @__PURE__ */ Y("button", {
|
|
407
597
|
type: "button",
|
|
408
|
-
onClick: () =>
|
|
409
|
-
"aria-label":
|
|
598
|
+
onClick: () => D((e) => !e),
|
|
599
|
+
"aria-label": T ? "Hide password" : "Show password",
|
|
410
600
|
className: "cursor-pointer text-muted-foreground transition-colors hover:text-foreground",
|
|
411
601
|
tabIndex: -1,
|
|
412
|
-
children:
|
|
413
|
-
}) : null,
|
|
414
|
-
|
|
415
|
-
},
|
|
416
|
-
id:
|
|
417
|
-
type:
|
|
602
|
+
children: Y(T ? ee : E, { className: "size-4" })
|
|
603
|
+
}) : null, R = _ ? /* @__PURE__ */ Y(F, { className: "size-4 animate-spin text-muted-foreground" }) : f, z = re ? ie : p, ae = (e) => {
|
|
604
|
+
L === "number" && e.target.select(), P?.(e);
|
|
605
|
+
}, oe = !!(h || g), se = /* @__PURE__ */ Y("input", {
|
|
606
|
+
id: w,
|
|
607
|
+
type: L,
|
|
418
608
|
ref: t,
|
|
419
609
|
disabled: m,
|
|
420
610
|
"aria-invalid": S,
|
|
421
|
-
"aria-describedby":
|
|
422
|
-
onFocus:
|
|
423
|
-
className:
|
|
424
|
-
...
|
|
611
|
+
"aria-describedby": A,
|
|
612
|
+
onFocus: ae,
|
|
613
|
+
className: Q("w-full min-w-0 bg-transparent text-base text-foreground outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed md:text-sm", oe ? "h-full border-0 py-1 focus-visible:ring-0" : Q("rounded-lg border border-input px-3 py-1 transition-colors", j, u === "default" ? "h-9" : "h-8", "focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", "disabled:opacity-50", "aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40", R && "pl-9", z && "pr-9"), oe && Q(h ? "pl-0" : "pl-3", g ? "pr-0" : "pr-3"), oe && R && !h && "pl-9", oe && z && !g && "pr-9", r),
|
|
614
|
+
...ne
|
|
425
615
|
});
|
|
426
|
-
return /* @__PURE__ */
|
|
427
|
-
className:
|
|
616
|
+
return /* @__PURE__ */ X("div", {
|
|
617
|
+
className: Q("space-y-1.5", i),
|
|
428
618
|
children: [
|
|
429
|
-
a && /* @__PURE__ */
|
|
430
|
-
htmlFor:
|
|
431
|
-
className:
|
|
432
|
-
children: [a,
|
|
619
|
+
a && /* @__PURE__ */ X(ct, {
|
|
620
|
+
htmlFor: w,
|
|
621
|
+
className: Q(m && "text-muted-foreground"),
|
|
622
|
+
children: [a, M]
|
|
433
623
|
}),
|
|
434
|
-
|
|
624
|
+
oe ? /* @__PURE__ */ X("div", {
|
|
435
625
|
"aria-invalid": S,
|
|
436
|
-
className:
|
|
626
|
+
className: Q("flex items-center overflow-hidden rounded-lg border border-input transition-colors", j, u === "default" ? "h-9" : "h-8", "focus-within:border-ring focus-within:ring-3 focus-within:ring-ring/50", "aria-[invalid=true]:border-destructive aria-[invalid=true]:ring-3 aria-[invalid=true]:ring-destructive/20 dark:aria-[invalid=true]:ring-destructive/40", m && "cursor-not-allowed opacity-50"),
|
|
437
627
|
children: [
|
|
438
|
-
h && /* @__PURE__ */
|
|
628
|
+
h && /* @__PURE__ */ Y("div", {
|
|
439
629
|
className: "flex h-full shrink-0 items-center justify-center border-r border-input bg-muted/40 px-3 text-sm text-muted-foreground [&_svg]:size-4",
|
|
440
630
|
children: h
|
|
441
631
|
}),
|
|
442
|
-
/* @__PURE__ */
|
|
632
|
+
/* @__PURE__ */ X("div", {
|
|
443
633
|
className: "relative flex h-full flex-1 items-center",
|
|
444
634
|
children: [
|
|
445
|
-
|
|
635
|
+
R && /* @__PURE__ */ Y("div", {
|
|
446
636
|
className: "pointer-events-none absolute left-3 flex items-center text-muted-foreground [&_svg]:size-4",
|
|
447
|
-
children:
|
|
637
|
+
children: R
|
|
448
638
|
}),
|
|
449
639
|
se,
|
|
450
|
-
|
|
640
|
+
z && /* @__PURE__ */ Y("div", {
|
|
451
641
|
className: "absolute right-3 z-10 flex items-center",
|
|
452
|
-
children:
|
|
642
|
+
children: z
|
|
453
643
|
})
|
|
454
644
|
]
|
|
455
645
|
}),
|
|
456
|
-
g && /* @__PURE__ */
|
|
646
|
+
g && /* @__PURE__ */ Y("div", {
|
|
457
647
|
className: "flex h-full shrink-0 items-center justify-center border-l border-input bg-muted/40 px-3 text-sm text-foreground [&_svg]:size-4",
|
|
458
648
|
children: g
|
|
459
649
|
})
|
|
460
650
|
]
|
|
461
|
-
}) : /* @__PURE__ */
|
|
651
|
+
}) : /* @__PURE__ */ X("div", {
|
|
462
652
|
className: "relative",
|
|
463
653
|
children: [
|
|
464
|
-
|
|
654
|
+
R && /* @__PURE__ */ Y("div", {
|
|
465
655
|
className: "pointer-events-none absolute left-3 top-1/2 flex -translate-y-1/2 items-center text-muted-foreground [&_svg]:size-4",
|
|
466
|
-
children:
|
|
656
|
+
children: R
|
|
467
657
|
}),
|
|
468
658
|
se,
|
|
469
|
-
|
|
659
|
+
z && /* @__PURE__ */ Y("div", {
|
|
470
660
|
className: "absolute right-3 top-1/2 z-10 flex -translate-y-1/2 items-center",
|
|
471
|
-
children:
|
|
661
|
+
children: z
|
|
472
662
|
})
|
|
473
663
|
]
|
|
474
664
|
}),
|
|
475
|
-
/* @__PURE__ */
|
|
665
|
+
/* @__PURE__ */ Y(pt, {
|
|
476
666
|
error: S,
|
|
477
667
|
errorMessage: s,
|
|
478
668
|
helperText: c,
|
|
479
|
-
errorId:
|
|
480
|
-
helperId:
|
|
669
|
+
errorId: O,
|
|
670
|
+
helperId: k
|
|
481
671
|
}),
|
|
482
|
-
o && /* @__PURE__ */
|
|
672
|
+
o && /* @__PURE__ */ Y(ut, {
|
|
483
673
|
id: te,
|
|
484
674
|
children: o
|
|
485
675
|
})
|
|
486
676
|
]
|
|
487
677
|
});
|
|
488
|
-
})
|
|
678
|
+
}), ht = [
|
|
679
|
+
{
|
|
680
|
+
match: (e, t) => e.includes("zip") || e.includes("archive") || t.endsWith(".zip") || t.endsWith(".rar"),
|
|
681
|
+
Icon: D
|
|
682
|
+
},
|
|
683
|
+
{
|
|
684
|
+
match: (e) => e.includes("audio/"),
|
|
685
|
+
Icon: A
|
|
686
|
+
},
|
|
687
|
+
{
|
|
688
|
+
match: (e, t) => e.includes("excel") || t.endsWith(".xls") || t.endsWith(".xlsx"),
|
|
689
|
+
Icon: k
|
|
690
|
+
},
|
|
691
|
+
{
|
|
692
|
+
match: (e) => e.startsWith("image/"),
|
|
693
|
+
Icon: j
|
|
694
|
+
},
|
|
695
|
+
{
|
|
696
|
+
match: (e, t) => e.includes("pdf") || t.endsWith(".pdf") || e.includes("word") || t.endsWith(".doc") || t.endsWith(".docx"),
|
|
697
|
+
Icon: te
|
|
698
|
+
},
|
|
699
|
+
{
|
|
700
|
+
match: (e) => e.includes("video/"),
|
|
701
|
+
Icon: le
|
|
702
|
+
}
|
|
703
|
+
];
|
|
704
|
+
function gt(e) {
|
|
705
|
+
for (let { match: t, Icon: n } of ht) if (t(e.type, e.name)) return /* @__PURE__ */ Y(n, { className: "size-5 opacity-60" });
|
|
706
|
+
return /* @__PURE__ */ Y(O, { className: "size-5 opacity-60" });
|
|
707
|
+
}
|
|
708
|
+
function _t({ entry: e }) {
|
|
709
|
+
let { file: t } = e;
|
|
710
|
+
return /* @__PURE__ */ Y("div", {
|
|
711
|
+
className: "flex aspect-square items-center justify-center overflow-hidden rounded-t-[inherit] bg-accent",
|
|
712
|
+
children: t.type.startsWith("image/") && e.preview ? /* @__PURE__ */ Y("img", {
|
|
713
|
+
alt: t.name,
|
|
714
|
+
className: "size-full rounded-t-[inherit] object-cover",
|
|
715
|
+
src: e.preview
|
|
716
|
+
}) : gt(t)
|
|
717
|
+
});
|
|
718
|
+
}
|
|
719
|
+
function vt({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024 * 1024, maxFiles: r = 6, multiple: i, initialFiles: a, disabled: o, onFilesChange: s, className: c }) {
|
|
720
|
+
let [{ files: l, isDragging: u, errors: d }, { handleDragEnter: f, handleDragLeave: m, handleDragOver: h, handleDrop: g, openFileDialog: _, removeFile: v, clearFiles: y, getInputProps: b }] = Ne({
|
|
721
|
+
accept: t,
|
|
722
|
+
maxSize: n,
|
|
723
|
+
maxFiles: r,
|
|
724
|
+
multiple: e === "files" ? !0 : i ?? !1,
|
|
725
|
+
initialFiles: a,
|
|
726
|
+
onFilesChange: s
|
|
727
|
+
}), x = Me(n), S = d.length > 0 && /* @__PURE__ */ X("div", {
|
|
728
|
+
className: "flex items-center gap-1 text-destructive text-xs",
|
|
729
|
+
role: "alert",
|
|
730
|
+
children: [/* @__PURE__ */ Y(p, { className: "size-3 shrink-0" }), /* @__PURE__ */ Y("span", { children: d[0] })]
|
|
731
|
+
});
|
|
732
|
+
if (e === "image") {
|
|
733
|
+
let e = l[0]?.preview || null, t = l[0];
|
|
734
|
+
return /* @__PURE__ */ X("div", {
|
|
735
|
+
className: Q("flex w-full flex-col gap-2", c),
|
|
736
|
+
children: [/* @__PURE__ */ X("div", {
|
|
737
|
+
className: "relative",
|
|
738
|
+
children: [/* @__PURE__ */ X("div", {
|
|
739
|
+
className: "relative flex min-h-52 flex-col items-center justify-center overflow-hidden rounded-xl border border-input border-dashed p-4 transition-colors hover:bg-accent/50 has-disabled:pointer-events-none has-[img]:border-none has-disabled:opacity-50 has-[input:focus]:border-ring has-[input:focus]:ring-[3px] has-[input:focus]:ring-ring/50 data-[dragging=true]:bg-accent/50",
|
|
740
|
+
"data-dragging": u || void 0,
|
|
741
|
+
onClick: o ? void 0 : _,
|
|
742
|
+
onDragEnter: f,
|
|
743
|
+
onDragLeave: m,
|
|
744
|
+
onDragOver: h,
|
|
745
|
+
onDrop: g,
|
|
746
|
+
role: "button",
|
|
747
|
+
tabIndex: -1,
|
|
748
|
+
children: [/* @__PURE__ */ Y("input", {
|
|
749
|
+
...b({ disabled: o }),
|
|
750
|
+
"aria-label": "Upload image file",
|
|
751
|
+
className: "sr-only"
|
|
752
|
+
}), e ? /* @__PURE__ */ Y("div", {
|
|
753
|
+
className: "absolute inset-0 overflow-hidden rounded-xl",
|
|
754
|
+
children: /* @__PURE__ */ Y("img", {
|
|
755
|
+
alt: t?.file?.name || "Uploaded image",
|
|
756
|
+
className: "size-full rounded-xl object-cover",
|
|
757
|
+
src: e
|
|
758
|
+
})
|
|
759
|
+
}) : /* @__PURE__ */ X("div", {
|
|
760
|
+
className: "flex flex-col items-center justify-center px-4 py-3 text-center",
|
|
761
|
+
children: [
|
|
762
|
+
/* @__PURE__ */ Y("div", {
|
|
763
|
+
"aria-hidden": "true",
|
|
764
|
+
className: "mb-2 flex size-11 shrink-0 items-center justify-center rounded-full border bg-background",
|
|
765
|
+
children: /* @__PURE__ */ Y(M, { className: "size-4 opacity-60" })
|
|
766
|
+
}),
|
|
767
|
+
/* @__PURE__ */ Y("p", {
|
|
768
|
+
className: "mb-1.5 font-medium text-sm",
|
|
769
|
+
children: "Drop your image here or click to browse"
|
|
770
|
+
}),
|
|
771
|
+
/* @__PURE__ */ X("p", {
|
|
772
|
+
className: "text-muted-foreground text-xs",
|
|
773
|
+
children: ["Max size: ", x]
|
|
774
|
+
})
|
|
775
|
+
]
|
|
776
|
+
})]
|
|
777
|
+
}), e && /* @__PURE__ */ Y("div", {
|
|
778
|
+
className: "absolute top-4 right-4",
|
|
779
|
+
children: /* @__PURE__ */ Y("button", {
|
|
780
|
+
"aria-label": "Remove image",
|
|
781
|
+
className: "z-50 flex size-8 cursor-pointer items-center justify-center rounded-full bg-black/60 text-white outline-none transition-[color,box-shadow] hover:bg-black/80 focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50",
|
|
782
|
+
onClick: () => t && v(t.id),
|
|
783
|
+
type: "button",
|
|
784
|
+
children: /* @__PURE__ */ Y(de, {
|
|
785
|
+
"aria-hidden": "true",
|
|
786
|
+
className: "size-4"
|
|
787
|
+
})
|
|
788
|
+
})
|
|
789
|
+
})]
|
|
790
|
+
}), S]
|
|
791
|
+
});
|
|
792
|
+
}
|
|
793
|
+
return /* @__PURE__ */ X("div", {
|
|
794
|
+
className: Q("flex w-full flex-col gap-2", c),
|
|
795
|
+
children: [/* @__PURE__ */ X("div", {
|
|
796
|
+
className: "relative flex min-h-52 flex-col items-center not-data-files:justify-center overflow-hidden rounded-xl border border-input border-dashed p-4 transition-colors has-disabled:pointer-events-none has-disabled:opacity-50 has-[input:focus]:border-ring has-[input:focus]:ring-[3px] has-[input:focus]:ring-ring/50 data-[dragging=true]:bg-accent/50",
|
|
797
|
+
"data-dragging": u || void 0,
|
|
798
|
+
"data-files": l.length > 0 || void 0,
|
|
799
|
+
onDragEnter: f,
|
|
800
|
+
onDragLeave: m,
|
|
801
|
+
onDragOver: h,
|
|
802
|
+
onDrop: g,
|
|
803
|
+
children: [/* @__PURE__ */ Y("input", {
|
|
804
|
+
...b({ disabled: o }),
|
|
805
|
+
"aria-label": "Upload files",
|
|
806
|
+
className: "sr-only"
|
|
807
|
+
}), l.length > 0 ? /* @__PURE__ */ X("div", {
|
|
808
|
+
className: "flex w-full flex-col gap-3",
|
|
809
|
+
children: [/* @__PURE__ */ X("div", {
|
|
810
|
+
className: "flex items-center justify-between gap-2",
|
|
811
|
+
children: [/* @__PURE__ */ X("h3", {
|
|
812
|
+
className: "truncate font-medium text-sm",
|
|
813
|
+
children: [
|
|
814
|
+
"Files (",
|
|
815
|
+
l.length,
|
|
816
|
+
")"
|
|
817
|
+
]
|
|
818
|
+
}), /* @__PURE__ */ X("div", {
|
|
819
|
+
className: "flex gap-2",
|
|
820
|
+
children: [/* @__PURE__ */ X($, {
|
|
821
|
+
disabled: o,
|
|
822
|
+
onClick: _,
|
|
823
|
+
size: "sm",
|
|
824
|
+
variant: "outline",
|
|
825
|
+
children: [/* @__PURE__ */ Y(V, {
|
|
826
|
+
"aria-hidden": "true",
|
|
827
|
+
className: "-ms-0.5 size-3.5 opacity-60"
|
|
828
|
+
}), "Add files"]
|
|
829
|
+
}), /* @__PURE__ */ X($, {
|
|
830
|
+
disabled: o,
|
|
831
|
+
onClick: y,
|
|
832
|
+
size: "sm",
|
|
833
|
+
variant: "outline",
|
|
834
|
+
children: [/* @__PURE__ */ Y(B, {
|
|
835
|
+
"aria-hidden": "true",
|
|
836
|
+
className: "-ms-0.5 size-3.5 opacity-60"
|
|
837
|
+
}), "Remove all"]
|
|
838
|
+
})]
|
|
839
|
+
})]
|
|
840
|
+
}), /* @__PURE__ */ Y("div", {
|
|
841
|
+
className: "grid grid-cols-2 gap-4 md:grid-cols-3",
|
|
842
|
+
children: l.map((e) => /* @__PURE__ */ X("div", {
|
|
843
|
+
className: "relative flex flex-col rounded-md border bg-background",
|
|
844
|
+
children: [
|
|
845
|
+
/* @__PURE__ */ Y(_t, { entry: e }),
|
|
846
|
+
/* @__PURE__ */ Y($, {
|
|
847
|
+
"aria-label": "Remove file",
|
|
848
|
+
className: "-top-2 -right-2 absolute size-6 rounded-full border-2 border-background shadow-none focus-visible:border-background",
|
|
849
|
+
onClick: () => v(e.id),
|
|
850
|
+
size: "icon",
|
|
851
|
+
children: /* @__PURE__ */ Y(de, { className: "size-3.5" })
|
|
852
|
+
}),
|
|
853
|
+
/* @__PURE__ */ X("div", {
|
|
854
|
+
className: "flex min-w-0 flex-col gap-0.5 border-t p-3",
|
|
855
|
+
children: [/* @__PURE__ */ Y("p", {
|
|
856
|
+
className: "truncate font-medium text-[13px]",
|
|
857
|
+
children: e.file.name
|
|
858
|
+
}), /* @__PURE__ */ Y("p", {
|
|
859
|
+
className: "truncate text-muted-foreground text-xs",
|
|
860
|
+
children: Me(e.file.size)
|
|
861
|
+
})]
|
|
862
|
+
})
|
|
863
|
+
]
|
|
864
|
+
}, e.id))
|
|
865
|
+
})]
|
|
866
|
+
}) : /* @__PURE__ */ X("div", {
|
|
867
|
+
className: "flex flex-col items-center justify-center px-4 py-3 text-center",
|
|
868
|
+
children: [
|
|
869
|
+
/* @__PURE__ */ Y("div", {
|
|
870
|
+
"aria-hidden": "true",
|
|
871
|
+
className: "mb-2 flex size-11 shrink-0 items-center justify-center rounded-full border bg-background",
|
|
872
|
+
children: /* @__PURE__ */ Y(j, { className: "size-4 opacity-60" })
|
|
873
|
+
}),
|
|
874
|
+
/* @__PURE__ */ Y("p", {
|
|
875
|
+
className: "mb-1.5 font-medium text-sm",
|
|
876
|
+
children: "Drop your files here"
|
|
877
|
+
}),
|
|
878
|
+
/* @__PURE__ */ X("p", {
|
|
879
|
+
className: "text-muted-foreground text-xs",
|
|
880
|
+
children: [
|
|
881
|
+
"Max ",
|
|
882
|
+
r,
|
|
883
|
+
" files ∙ Up to ",
|
|
884
|
+
x
|
|
885
|
+
]
|
|
886
|
+
}),
|
|
887
|
+
/* @__PURE__ */ X($, {
|
|
888
|
+
className: "mt-4",
|
|
889
|
+
disabled: o,
|
|
890
|
+
onClick: _,
|
|
891
|
+
variant: "outline",
|
|
892
|
+
children: [/* @__PURE__ */ Y(V, {
|
|
893
|
+
"aria-hidden": "true",
|
|
894
|
+
className: "-ms-1 opacity-60"
|
|
895
|
+
}), "Select files"]
|
|
896
|
+
})
|
|
897
|
+
]
|
|
898
|
+
})]
|
|
899
|
+
}), S]
|
|
900
|
+
});
|
|
901
|
+
}
|
|
489
902
|
//#endregion
|
|
490
903
|
//#region src/components/ui/dialog.tsx
|
|
491
|
-
function
|
|
492
|
-
return /* @__PURE__ */
|
|
904
|
+
function yt({ ...e }) {
|
|
905
|
+
return /* @__PURE__ */ Y(G.Root, {
|
|
493
906
|
"data-slot": "dialog",
|
|
494
907
|
...e
|
|
495
908
|
});
|
|
496
909
|
}
|
|
497
|
-
function
|
|
498
|
-
return /* @__PURE__ */
|
|
910
|
+
function bt({ ...e }) {
|
|
911
|
+
return /* @__PURE__ */ Y(G.Trigger, {
|
|
499
912
|
"data-slot": "dialog-trigger",
|
|
500
913
|
...e
|
|
501
914
|
});
|
|
502
915
|
}
|
|
503
|
-
function
|
|
504
|
-
return /* @__PURE__ */
|
|
916
|
+
function xt({ ...e }) {
|
|
917
|
+
return /* @__PURE__ */ Y(G.Portal, {
|
|
505
918
|
"data-slot": "dialog-portal",
|
|
506
919
|
...e
|
|
507
920
|
});
|
|
508
921
|
}
|
|
509
|
-
function
|
|
510
|
-
return /* @__PURE__ */
|
|
922
|
+
function St({ ...e }) {
|
|
923
|
+
return /* @__PURE__ */ Y(G.Close, {
|
|
511
924
|
"data-slot": "dialog-close",
|
|
512
925
|
...e
|
|
513
926
|
});
|
|
514
927
|
}
|
|
515
|
-
function
|
|
516
|
-
return /* @__PURE__ */
|
|
928
|
+
function Ct({ className: e, ...t }) {
|
|
929
|
+
return /* @__PURE__ */ Y(G.Overlay, {
|
|
517
930
|
"data-slot": "dialog-overlay",
|
|
518
|
-
className:
|
|
931
|
+
className: Q("fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", e),
|
|
519
932
|
...t
|
|
520
933
|
});
|
|
521
934
|
}
|
|
522
|
-
function
|
|
523
|
-
return /* @__PURE__ */
|
|
935
|
+
function wt({ className: e, children: t, showCloseButton: n = !0, ...r }) {
|
|
936
|
+
return /* @__PURE__ */ X(xt, { children: [/* @__PURE__ */ Y(Ct, {}), /* @__PURE__ */ X(G.Content, {
|
|
524
937
|
"data-slot": "dialog-content",
|
|
525
|
-
className:
|
|
938
|
+
className: Q("fixed top-1/2 left-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
526
939
|
...r,
|
|
527
|
-
children: [t, n && /* @__PURE__ */
|
|
940
|
+
children: [t, n && /* @__PURE__ */ Y(G.Close, {
|
|
528
941
|
"data-slot": "dialog-close",
|
|
529
942
|
asChild: !0,
|
|
530
|
-
children: /* @__PURE__ */
|
|
943
|
+
children: /* @__PURE__ */ X($, {
|
|
531
944
|
variant: "ghost",
|
|
532
945
|
className: "absolute top-2 right-2",
|
|
533
946
|
size: "icon-sm",
|
|
534
|
-
children: [/* @__PURE__ */
|
|
947
|
+
children: [/* @__PURE__ */ Y(de, {}), /* @__PURE__ */ Y("span", {
|
|
535
948
|
className: "sr-only",
|
|
536
949
|
children: "Close"
|
|
537
950
|
})]
|
|
@@ -539,71 +952,71 @@ function at({ className: e, children: t, showCloseButton: n = !0, ...r }) {
|
|
|
539
952
|
})]
|
|
540
953
|
})] });
|
|
541
954
|
}
|
|
542
|
-
function
|
|
543
|
-
return /* @__PURE__ */
|
|
955
|
+
function Tt({ className: e, ...t }) {
|
|
956
|
+
return /* @__PURE__ */ Y("div", {
|
|
544
957
|
"data-slot": "dialog-header",
|
|
545
|
-
className:
|
|
958
|
+
className: Q("flex flex-col gap-2", e),
|
|
546
959
|
...t
|
|
547
960
|
});
|
|
548
961
|
}
|
|
549
|
-
function
|
|
550
|
-
return /* @__PURE__ */
|
|
962
|
+
function Et({ className: e, showCloseButton: t = !1, children: n, ...r }) {
|
|
963
|
+
return /* @__PURE__ */ X("div", {
|
|
551
964
|
"data-slot": "dialog-footer",
|
|
552
|
-
className:
|
|
965
|
+
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end", e),
|
|
553
966
|
...r,
|
|
554
|
-
children: [n, t && /* @__PURE__ */
|
|
967
|
+
children: [n, t && /* @__PURE__ */ Y(G.Close, {
|
|
555
968
|
asChild: !0,
|
|
556
|
-
children: /* @__PURE__ */
|
|
969
|
+
children: /* @__PURE__ */ Y($, {
|
|
557
970
|
variant: "outline",
|
|
558
971
|
children: "Close"
|
|
559
972
|
})
|
|
560
973
|
})]
|
|
561
974
|
});
|
|
562
975
|
}
|
|
563
|
-
function
|
|
564
|
-
return /* @__PURE__ */
|
|
976
|
+
function Dt({ className: e, ...t }) {
|
|
977
|
+
return /* @__PURE__ */ Y(G.Title, {
|
|
565
978
|
"data-slot": "dialog-title",
|
|
566
|
-
className:
|
|
979
|
+
className: Q("text-base leading-none font-medium", e),
|
|
567
980
|
...t
|
|
568
981
|
});
|
|
569
982
|
}
|
|
570
|
-
function
|
|
571
|
-
return /* @__PURE__ */
|
|
983
|
+
function Ot({ className: e, ...t }) {
|
|
984
|
+
return /* @__PURE__ */ Y(G.Description, {
|
|
572
985
|
"data-slot": "dialog-description",
|
|
573
|
-
className:
|
|
986
|
+
className: Q("text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", e),
|
|
574
987
|
...t
|
|
575
988
|
});
|
|
576
989
|
}
|
|
577
990
|
//#endregion
|
|
578
991
|
//#region src/components/ui/input.tsx
|
|
579
|
-
function
|
|
580
|
-
return /* @__PURE__ */
|
|
992
|
+
function kt({ className: e, type: t, ...n }) {
|
|
993
|
+
return /* @__PURE__ */ Y("input", {
|
|
581
994
|
type: t,
|
|
582
995
|
"data-slot": "input",
|
|
583
|
-
className:
|
|
996
|
+
className: Q("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", e),
|
|
584
997
|
...n
|
|
585
998
|
});
|
|
586
999
|
}
|
|
587
1000
|
//#endregion
|
|
588
1001
|
//#region src/components/ui/textarea.tsx
|
|
589
|
-
function
|
|
590
|
-
return /* @__PURE__ */
|
|
1002
|
+
function At({ className: e, ...t }) {
|
|
1003
|
+
return /* @__PURE__ */ Y("textarea", {
|
|
591
1004
|
"data-slot": "textarea",
|
|
592
|
-
className:
|
|
1005
|
+
className: Q("flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", e),
|
|
593
1006
|
...t
|
|
594
1007
|
});
|
|
595
1008
|
}
|
|
596
1009
|
//#endregion
|
|
597
1010
|
//#region src/components/ui/input-group.tsx
|
|
598
|
-
function
|
|
599
|
-
return /* @__PURE__ */
|
|
1011
|
+
function jt({ className: e, ...t }) {
|
|
1012
|
+
return /* @__PURE__ */ Y("div", {
|
|
600
1013
|
"data-slot": "input-group",
|
|
601
1014
|
role: "group",
|
|
602
|
-
className:
|
|
1015
|
+
className: Q("group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input transition-colors outline-none in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:border-destructive has-[[data-slot][aria-invalid=true]]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:h-auto has-[>[data-align=block-start]]:flex-col has-[>textarea]:h-auto dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=inline-start]]:[&>input]:pl-1.5", e),
|
|
603
1016
|
...t
|
|
604
1017
|
});
|
|
605
1018
|
}
|
|
606
|
-
var
|
|
1019
|
+
var Mt = H("flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm font-medium text-muted-foreground select-none group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4", {
|
|
607
1020
|
variants: { align: {
|
|
608
1021
|
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
609
1022
|
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
@@ -612,19 +1025,19 @@ var pt = P("flex h-auto cursor-text items-center justify-center gap-2 py-1.5 tex
|
|
|
612
1025
|
} },
|
|
613
1026
|
defaultVariants: { align: "inline-start" }
|
|
614
1027
|
});
|
|
615
|
-
function
|
|
616
|
-
return /* @__PURE__ */
|
|
1028
|
+
function Nt({ className: e, align: t = "inline-start", ...n }) {
|
|
1029
|
+
return /* @__PURE__ */ Y("div", {
|
|
617
1030
|
role: "group",
|
|
618
1031
|
"data-slot": "input-group-addon",
|
|
619
1032
|
"data-align": t,
|
|
620
|
-
className:
|
|
1033
|
+
className: Q(Mt({ align: t }), e),
|
|
621
1034
|
onClick: (e) => {
|
|
622
1035
|
e.target.closest("button") || e.currentTarget.parentElement?.querySelector("input")?.focus();
|
|
623
1036
|
},
|
|
624
1037
|
...n
|
|
625
1038
|
});
|
|
626
1039
|
}
|
|
627
|
-
var
|
|
1040
|
+
var Pt = H("flex items-center gap-2 text-sm shadow-none", {
|
|
628
1041
|
variants: { size: {
|
|
629
1042
|
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
630
1043
|
sm: "",
|
|
@@ -633,179 +1046,179 @@ var ht = P("flex items-center gap-2 text-sm shadow-none", {
|
|
|
633
1046
|
} },
|
|
634
1047
|
defaultVariants: { size: "xs" }
|
|
635
1048
|
});
|
|
636
|
-
function
|
|
637
|
-
return /* @__PURE__ */
|
|
1049
|
+
function Ft({ className: e, type: t = "button", variant: n = "ghost", size: r = "xs", ...i }) {
|
|
1050
|
+
return /* @__PURE__ */ Y($, {
|
|
638
1051
|
type: t,
|
|
639
1052
|
"data-size": r,
|
|
640
1053
|
variant: n,
|
|
641
|
-
className:
|
|
1054
|
+
className: Q(Pt({ size: r }), e),
|
|
642
1055
|
...i
|
|
643
1056
|
});
|
|
644
1057
|
}
|
|
645
|
-
function
|
|
646
|
-
return /* @__PURE__ */
|
|
647
|
-
className:
|
|
1058
|
+
function It({ className: e, ...t }) {
|
|
1059
|
+
return /* @__PURE__ */ Y("span", {
|
|
1060
|
+
className: Q("flex items-center gap-2 text-sm text-muted-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", e),
|
|
648
1061
|
...t
|
|
649
1062
|
});
|
|
650
1063
|
}
|
|
651
|
-
function
|
|
652
|
-
return /* @__PURE__ */
|
|
1064
|
+
function Lt({ className: e, ...t }) {
|
|
1065
|
+
return /* @__PURE__ */ Y(kt, {
|
|
653
1066
|
"data-slot": "input-group-control",
|
|
654
|
-
className:
|
|
1067
|
+
className: Q("flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent", e),
|
|
655
1068
|
...t
|
|
656
1069
|
});
|
|
657
1070
|
}
|
|
658
|
-
function
|
|
659
|
-
return /* @__PURE__ */
|
|
1071
|
+
function Rt({ className: e, ...t }) {
|
|
1072
|
+
return /* @__PURE__ */ Y(At, {
|
|
660
1073
|
"data-slot": "input-group-control",
|
|
661
|
-
className:
|
|
1074
|
+
className: Q("flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent", e),
|
|
662
1075
|
...t
|
|
663
1076
|
});
|
|
664
1077
|
}
|
|
665
1078
|
//#endregion
|
|
666
1079
|
//#region src/components/ui/command.tsx
|
|
667
|
-
function
|
|
668
|
-
return /* @__PURE__ */
|
|
1080
|
+
function zt({ className: e, ...t }) {
|
|
1081
|
+
return /* @__PURE__ */ Y(Z, {
|
|
669
1082
|
"data-slot": "command",
|
|
670
|
-
className:
|
|
1083
|
+
className: Q("flex size-full flex-col overflow-hidden rounded-xl! bg-popover p-1 text-popover-foreground", e),
|
|
671
1084
|
...t
|
|
672
1085
|
});
|
|
673
1086
|
}
|
|
674
|
-
function
|
|
675
|
-
return /* @__PURE__ */
|
|
1087
|
+
function Bt({ title: e = "Command Palette", description: t = "Search for a command to run...", children: n, className: r, showCloseButton: i = !1, ...a }) {
|
|
1088
|
+
return /* @__PURE__ */ X(yt, {
|
|
676
1089
|
...a,
|
|
677
|
-
children: [/* @__PURE__ */
|
|
1090
|
+
children: [/* @__PURE__ */ X(Tt, {
|
|
678
1091
|
className: "sr-only",
|
|
679
|
-
children: [/* @__PURE__ */
|
|
680
|
-
}), /* @__PURE__ */
|
|
681
|
-
className:
|
|
1092
|
+
children: [/* @__PURE__ */ Y(Dt, { children: e }), /* @__PURE__ */ Y(Ot, { children: t })]
|
|
1093
|
+
}), /* @__PURE__ */ Y(wt, {
|
|
1094
|
+
className: Q("top-1/3 translate-y-0 overflow-hidden rounded-xl! p-0", r),
|
|
682
1095
|
showCloseButton: i,
|
|
683
1096
|
children: n
|
|
684
1097
|
})]
|
|
685
1098
|
});
|
|
686
1099
|
}
|
|
687
|
-
function
|
|
688
|
-
return /* @__PURE__ */
|
|
1100
|
+
function Vt({ className: e, ...t }) {
|
|
1101
|
+
return /* @__PURE__ */ Y("div", {
|
|
689
1102
|
"data-slot": "command-input-wrapper",
|
|
690
1103
|
className: "p-1 pb-0",
|
|
691
|
-
children: /* @__PURE__ */
|
|
1104
|
+
children: /* @__PURE__ */ X(jt, {
|
|
692
1105
|
className: "h-8! rounded-lg! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!",
|
|
693
|
-
children: [/* @__PURE__ */
|
|
1106
|
+
children: [/* @__PURE__ */ Y(Z.Input, {
|
|
694
1107
|
"data-slot": "command-input",
|
|
695
|
-
className:
|
|
1108
|
+
className: Q("w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
696
1109
|
...t
|
|
697
|
-
}), /* @__PURE__ */
|
|
1110
|
+
}), /* @__PURE__ */ Y(Nt, { children: /* @__PURE__ */ Y(se, { className: "size-4 shrink-0 opacity-50" }) })]
|
|
698
1111
|
})
|
|
699
1112
|
});
|
|
700
1113
|
}
|
|
701
|
-
function
|
|
702
|
-
return /* @__PURE__ */
|
|
1114
|
+
function Ht({ className: e, ...t }) {
|
|
1115
|
+
return /* @__PURE__ */ Y(Z.List, {
|
|
703
1116
|
"data-slot": "command-list",
|
|
704
|
-
className:
|
|
1117
|
+
className: Q("no-scrollbar max-h-72 scroll-py-1 overflow-x-hidden overflow-y-auto outline-none", e),
|
|
705
1118
|
...t
|
|
706
1119
|
});
|
|
707
1120
|
}
|
|
708
|
-
function
|
|
709
|
-
return /* @__PURE__ */
|
|
1121
|
+
function Ut({ className: e, ...t }) {
|
|
1122
|
+
return /* @__PURE__ */ Y(Z.Empty, {
|
|
710
1123
|
"data-slot": "command-empty",
|
|
711
|
-
className:
|
|
1124
|
+
className: Q("py-6 text-center text-sm", e),
|
|
712
1125
|
...t
|
|
713
1126
|
});
|
|
714
1127
|
}
|
|
715
|
-
function
|
|
716
|
-
return /* @__PURE__ */
|
|
1128
|
+
function Wt({ className: e, ...t }) {
|
|
1129
|
+
return /* @__PURE__ */ Y(Z.Group, {
|
|
717
1130
|
"data-slot": "command-group",
|
|
718
|
-
className:
|
|
1131
|
+
className: Q("overflow-hidden p-1 text-foreground **:[[cmdk-group-heading]]:px-2 **:[[cmdk-group-heading]]:py-1.5 **:[[cmdk-group-heading]]:text-xs **:[[cmdk-group-heading]]:font-medium **:[[cmdk-group-heading]]:text-muted-foreground", e),
|
|
719
1132
|
...t
|
|
720
1133
|
});
|
|
721
1134
|
}
|
|
722
|
-
function
|
|
723
|
-
return /* @__PURE__ */
|
|
1135
|
+
function Gt({ className: e, ...t }) {
|
|
1136
|
+
return /* @__PURE__ */ Y(Z.Separator, {
|
|
724
1137
|
"data-slot": "command-separator",
|
|
725
|
-
className:
|
|
1138
|
+
className: Q("-mx-1 h-px bg-border", e),
|
|
726
1139
|
...t
|
|
727
1140
|
});
|
|
728
1141
|
}
|
|
729
|
-
function
|
|
730
|
-
return /* @__PURE__ */
|
|
1142
|
+
function Kt({ className: e, children: t, ...n }) {
|
|
1143
|
+
return /* @__PURE__ */ X(Z.Item, {
|
|
731
1144
|
"data-slot": "command-item",
|
|
732
|
-
className:
|
|
1145
|
+
className: Q("group/command-item relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none in-data-[slot=dialog-content]:rounded-lg! data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 data-selected:bg-muted data-selected:text-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-selected:*:[svg]:text-foreground", e),
|
|
733
1146
|
...n,
|
|
734
|
-
children: [t, /* @__PURE__ */
|
|
1147
|
+
children: [t, /* @__PURE__ */ Y(g, { className: "ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })]
|
|
735
1148
|
});
|
|
736
1149
|
}
|
|
737
|
-
function
|
|
738
|
-
return /* @__PURE__ */
|
|
1150
|
+
function qt({ className: e, ...t }) {
|
|
1151
|
+
return /* @__PURE__ */ Y("span", {
|
|
739
1152
|
"data-slot": "command-shortcut",
|
|
740
|
-
className:
|
|
1153
|
+
className: Q("ml-auto text-xs tracking-widest text-muted-foreground group-data-selected/command-item:text-foreground", e),
|
|
741
1154
|
...t
|
|
742
1155
|
});
|
|
743
1156
|
}
|
|
744
1157
|
//#endregion
|
|
745
1158
|
//#region src/components/ui/popover.tsx
|
|
746
|
-
function
|
|
747
|
-
return /* @__PURE__ */
|
|
1159
|
+
function Jt({ ...e }) {
|
|
1160
|
+
return /* @__PURE__ */ Y(me.Root, {
|
|
748
1161
|
"data-slot": "popover",
|
|
749
1162
|
...e
|
|
750
1163
|
});
|
|
751
1164
|
}
|
|
752
|
-
function
|
|
753
|
-
return /* @__PURE__ */
|
|
1165
|
+
function Yt({ ...e }) {
|
|
1166
|
+
return /* @__PURE__ */ Y(me.Trigger, {
|
|
754
1167
|
"data-slot": "popover-trigger",
|
|
755
1168
|
...e
|
|
756
1169
|
});
|
|
757
1170
|
}
|
|
758
|
-
function
|
|
759
|
-
return /* @__PURE__ */
|
|
1171
|
+
function Xt({ className: e, align: t = "center", sideOffset: n = 4, ...r }) {
|
|
1172
|
+
return /* @__PURE__ */ Y(me.Portal, { children: /* @__PURE__ */ Y(me.Content, {
|
|
760
1173
|
"data-slot": "popover-content",
|
|
761
1174
|
align: t,
|
|
762
1175
|
sideOffset: n,
|
|
763
|
-
className:
|
|
1176
|
+
className: Q("z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
764
1177
|
...r
|
|
765
1178
|
}) });
|
|
766
1179
|
}
|
|
767
|
-
function
|
|
768
|
-
return /* @__PURE__ */
|
|
1180
|
+
function Zt({ ...e }) {
|
|
1181
|
+
return /* @__PURE__ */ Y(me.Anchor, {
|
|
769
1182
|
"data-slot": "popover-anchor",
|
|
770
1183
|
...e
|
|
771
1184
|
});
|
|
772
1185
|
}
|
|
773
|
-
function
|
|
774
|
-
return /* @__PURE__ */
|
|
1186
|
+
function Qt({ className: e, ...t }) {
|
|
1187
|
+
return /* @__PURE__ */ Y("div", {
|
|
775
1188
|
"data-slot": "popover-header",
|
|
776
|
-
className:
|
|
1189
|
+
className: Q("flex flex-col gap-0.5 text-sm", e),
|
|
777
1190
|
...t
|
|
778
1191
|
});
|
|
779
1192
|
}
|
|
780
|
-
function
|
|
781
|
-
return /* @__PURE__ */
|
|
1193
|
+
function $t({ className: e, ...t }) {
|
|
1194
|
+
return /* @__PURE__ */ Y("div", {
|
|
782
1195
|
"data-slot": "popover-title",
|
|
783
|
-
className:
|
|
1196
|
+
className: Q("font-medium", e),
|
|
784
1197
|
...t
|
|
785
1198
|
});
|
|
786
1199
|
}
|
|
787
|
-
function
|
|
788
|
-
return /* @__PURE__ */
|
|
1200
|
+
function en({ className: e, ...t }) {
|
|
1201
|
+
return /* @__PURE__ */ Y("p", {
|
|
789
1202
|
"data-slot": "popover-description",
|
|
790
|
-
className:
|
|
1203
|
+
className: Q("text-muted-foreground", e),
|
|
791
1204
|
...t
|
|
792
1205
|
});
|
|
793
1206
|
}
|
|
794
1207
|
//#endregion
|
|
795
1208
|
//#region src/components/custom/advanced-select.tsx
|
|
796
|
-
function
|
|
1209
|
+
function tn(e) {
|
|
797
1210
|
return typeof e == "object" && !!e && "value" in e && "label" in e;
|
|
798
1211
|
}
|
|
799
|
-
function
|
|
800
|
-
let [
|
|
801
|
-
|
|
802
|
-
}, [
|
|
1212
|
+
function nn({ options: e = [], groups: t = [], value: r, onValueChange: i, placeholder: a = "Select option", disabled: o = !1, error: s = !1, errorMessage: c, multiple: l = !1, className: u, size: d = "default", variant: f = "default", searchable: p = !1, clearable: m = !1, getOptionLabel: h, getOptionValue: _, renderOptionLabel: y, label: b, description: x, required: S = !1, onCreateNew: C, createNewLabel: w = "New item", loading: T = !1, compactMultiple: E = !1, formatCompactDisplay: ee, startItem: D, endItem: O, maxSelections: k, defaultOpen: te = !1, onOpenChange: A, onLoadMore: j, hasNextPage: M = !1, isFetchingNextPage: N = !1, allowEmpty: P = !1, showSelectAll: ne = !1, readOnly: I = !1, popoverClassName: re }) {
|
|
1213
|
+
let [L, ie] = n.useState(te), R = n.useRef(!1), z = n.useRef(null), ae = n.useId(), se = n.useCallback((e) => {
|
|
1214
|
+
I && e || (ie(e), A?.(e), e && (R.current = !1));
|
|
1215
|
+
}, [A, I]), [B, ce] = n.useState(l ? Array.isArray(r) ? r : r ? [r] : [] : []);
|
|
803
1216
|
n.useEffect(() => {
|
|
804
|
-
l &&
|
|
1217
|
+
l && ce(Array.isArray(r) ? r : r ? [r] : []);
|
|
805
1218
|
}, [l, r]), n.useEffect(() => {
|
|
806
1219
|
N || (R.current = !1);
|
|
807
1220
|
}, [N]);
|
|
808
|
-
let
|
|
1221
|
+
let V = n.useCallback((e) => typeof e == "string" ? e : _ ? _(e) : tn(e) ? e.value : String(e), [_]), le = n.useCallback((n) => {
|
|
809
1222
|
if (typeof n == "string") {
|
|
810
1223
|
for (let e of t) {
|
|
811
1224
|
let t = e.options.find((e) => e.value === n);
|
|
@@ -813,33 +1226,33 @@ function Lt({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
813
1226
|
}
|
|
814
1227
|
for (let t of e) if (typeof t == "string") {
|
|
815
1228
|
if (t === n) return t;
|
|
816
|
-
} else if (
|
|
1229
|
+
} else if (tn(t) && t.value === n) return t.label;
|
|
817
1230
|
return n;
|
|
818
1231
|
}
|
|
819
|
-
return
|
|
1232
|
+
return h ? h(n) : tn(n) ? n.label : String(n);
|
|
820
1233
|
}, [
|
|
821
|
-
|
|
1234
|
+
h,
|
|
822
1235
|
t,
|
|
823
1236
|
e
|
|
824
|
-
]),
|
|
1237
|
+
]), ue = n.useMemo(() => l || !r ? "" : typeof r == "string" ? r : Array.isArray(r) ? "" : V(r), [
|
|
825
1238
|
l,
|
|
826
1239
|
r,
|
|
827
|
-
|
|
828
|
-
]),
|
|
1240
|
+
V
|
|
1241
|
+
]), H = n.useMemo(() => e.map((e) => typeof e == "string" ? {
|
|
829
1242
|
value: e,
|
|
830
1243
|
label: e
|
|
831
|
-
} :
|
|
832
|
-
value:
|
|
833
|
-
label:
|
|
1244
|
+
} : tn(e) ? e : {
|
|
1245
|
+
value: V(e),
|
|
1246
|
+
label: le(e)
|
|
834
1247
|
}), [
|
|
835
1248
|
e,
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
]),
|
|
839
|
-
let e = [...
|
|
1249
|
+
le,
|
|
1250
|
+
V
|
|
1251
|
+
]), U = n.useCallback((t) => e.find((e) => V(e) === t), [e, V]), W = n.useMemo(() => {
|
|
1252
|
+
let e = [...H];
|
|
840
1253
|
return t.forEach((t) => e.push(...t.options)), e;
|
|
841
|
-
}, [
|
|
842
|
-
let r = e.find((e) =>
|
|
1254
|
+
}, [H, t]), G = (n) => {
|
|
1255
|
+
let r = e.find((e) => V(e) === n);
|
|
843
1256
|
if (r === void 0 && t.length > 0) for (let e of t) {
|
|
844
1257
|
let t = e.options.find((e) => e.value === n);
|
|
845
1258
|
if (t) {
|
|
@@ -848,425 +1261,509 @@ function Lt({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
848
1261
|
}
|
|
849
1262
|
}
|
|
850
1263
|
if (l) {
|
|
851
|
-
let e =
|
|
852
|
-
if (!e &&
|
|
853
|
-
let t = e ?
|
|
854
|
-
|
|
855
|
-
} else i?.(r),
|
|
856
|
-
},
|
|
1264
|
+
let e = B.some((e) => V(e) === n);
|
|
1265
|
+
if (!e && k && B.length >= k || e && B.length === 1 && !P) return;
|
|
1266
|
+
let t = e ? B.filter((e) => V(e) !== n) : [...B, r];
|
|
1267
|
+
ce(t), i?.(t);
|
|
1268
|
+
} else i?.(r), ie(!1);
|
|
1269
|
+
}, K = l && W.length > 0 && W.length === B.length, fe = () => {
|
|
857
1270
|
if (l) {
|
|
858
|
-
if (
|
|
859
|
-
|
|
1271
|
+
if (K) {
|
|
1272
|
+
P && (ce([]), i?.([]));
|
|
860
1273
|
return;
|
|
861
1274
|
}
|
|
862
|
-
|
|
1275
|
+
k && W.length > k || (ce(W), i?.(W));
|
|
863
1276
|
}
|
|
864
|
-
},
|
|
865
|
-
e.stopPropagation(), l ? (
|
|
866
|
-
},
|
|
867
|
-
if (e.stopPropagation(),
|
|
868
|
-
let n =
|
|
869
|
-
|
|
870
|
-
},
|
|
1277
|
+
}, pe = (e) => {
|
|
1278
|
+
e.stopPropagation(), l ? (ce([]), i?.([])) : i?.("");
|
|
1279
|
+
}, me = (e, t) => {
|
|
1280
|
+
if (e.stopPropagation(), B.length === 1 && !P) return;
|
|
1281
|
+
let n = B.filter((e) => V(e) !== V(t));
|
|
1282
|
+
ce(n), i?.(n);
|
|
1283
|
+
}, he = n.useCallback((e) => {
|
|
871
1284
|
let t = e.currentTarget;
|
|
872
|
-
t.scrollHeight - t.scrollTop - t.clientHeight < 100 &&
|
|
1285
|
+
t.scrollHeight - t.scrollTop - t.clientHeight < 100 && j && M && !N && !R.current && (R.current = !0, j());
|
|
873
1286
|
}, [
|
|
1287
|
+
j,
|
|
874
1288
|
M,
|
|
875
|
-
ne,
|
|
876
1289
|
N
|
|
877
|
-
]),
|
|
878
|
-
!o && !
|
|
879
|
-
}, ve = !!(
|
|
880
|
-
className:
|
|
881
|
-
children: l &&
|
|
1290
|
+
]), ge = l ? B.length > 0 : !!ue, q = () => l ? null : W.find((e) => e.value === ue)?.label || a, _e = () => {
|
|
1291
|
+
!o && !I && (z.current?.focus(), ie(!0));
|
|
1292
|
+
}, ve = !!(D || O), J = l && !E, ye = J ? d === "default" ? "min-h-9" : "min-h-7" : d === "default" ? "h-9" : "h-7", be = f === "alt" ? "bg-muted" : "bg-transparent dark:bg-input/30", xe = /* @__PURE__ */ Y("div", {
|
|
1293
|
+
className: Q("flex min-w-0 flex-1 items-center gap-1.5", J ? "py-1" : "overflow-hidden"),
|
|
1294
|
+
children: l && B.length > 0 ? E ? /* @__PURE__ */ Y("span", {
|
|
882
1295
|
className: "min-w-0 truncate",
|
|
883
|
-
children:
|
|
884
|
-
}) : /* @__PURE__ */
|
|
1296
|
+
children: ee ? ee(B) : `${B.length} selected`
|
|
1297
|
+
}) : /* @__PURE__ */ Y("div", {
|
|
885
1298
|
className: "flex flex-wrap items-center gap-1.5",
|
|
886
|
-
children:
|
|
1299
|
+
children: B.map((e, t) => /* @__PURE__ */ X("span", {
|
|
887
1300
|
className: "inline-flex items-center gap-1 rounded-sm bg-primary px-2 py-0.5 text-xs font-normal text-primary-foreground",
|
|
888
|
-
children: [
|
|
1301
|
+
children: [le(e), !o && /* @__PURE__ */ Y("button", {
|
|
889
1302
|
type: "button",
|
|
890
|
-
"aria-label": `Remove ${
|
|
891
|
-
onClick: (t) =>
|
|
1303
|
+
"aria-label": `Remove ${le(e)}`,
|
|
1304
|
+
onClick: (t) => me(t, e),
|
|
892
1305
|
className: "rounded-sm transition-colors hover:bg-primary/80",
|
|
893
|
-
children: /* @__PURE__ */
|
|
1306
|
+
children: /* @__PURE__ */ Y(de, { className: "size-3" })
|
|
894
1307
|
})]
|
|
895
|
-
}, `${
|
|
896
|
-
}) : /* @__PURE__ */
|
|
897
|
-
className:
|
|
898
|
-
children:
|
|
1308
|
+
}, `${V(e)}-${t}`))
|
|
1309
|
+
}) : /* @__PURE__ */ Y("span", {
|
|
1310
|
+
className: Q("block min-w-0 truncate", !ge && "text-muted-foreground"),
|
|
1311
|
+
children: q() || a
|
|
899
1312
|
})
|
|
900
|
-
}),
|
|
1313
|
+
}), Se = /* @__PURE__ */ X("div", {
|
|
901
1314
|
className: "flex shrink-0 items-center gap-1",
|
|
902
|
-
children: [m &&
|
|
1315
|
+
children: [m && ge && !o && /* @__PURE__ */ Y("span", {
|
|
903
1316
|
role: "button",
|
|
904
1317
|
tabIndex: 0,
|
|
905
1318
|
"aria-label": "Clear",
|
|
906
|
-
onClick:
|
|
1319
|
+
onClick: pe,
|
|
907
1320
|
onKeyDown: (e) => {
|
|
908
|
-
(e.key === "Enter" || e.key === " ") && (e.stopPropagation(),
|
|
1321
|
+
(e.key === "Enter" || e.key === " ") && (e.stopPropagation(), pe(e));
|
|
909
1322
|
},
|
|
910
1323
|
className: "cursor-pointer rounded-sm p-0.5 transition-colors hover:bg-accent",
|
|
911
|
-
children: /* @__PURE__ */
|
|
912
|
-
}), /* @__PURE__ */
|
|
1324
|
+
children: /* @__PURE__ */ Y(de, { className: "size-3.5" })
|
|
1325
|
+
}), /* @__PURE__ */ Y(v, {
|
|
913
1326
|
size: 16,
|
|
914
1327
|
className: "shrink-0 opacity-60",
|
|
915
1328
|
"aria-hidden": !0
|
|
916
1329
|
})]
|
|
917
|
-
}),
|
|
918
|
-
let t = l ?
|
|
919
|
-
return /* @__PURE__ */
|
|
1330
|
+
}), Ce = (e) => {
|
|
1331
|
+
let t = l ? B.some((t) => V(t) === e.value) : ue === e.value, n = U(e.value);
|
|
1332
|
+
return /* @__PURE__ */ X(Kt, {
|
|
920
1333
|
value: e.value,
|
|
921
|
-
onSelect: () =>
|
|
1334
|
+
onSelect: () => G(e.value),
|
|
922
1335
|
disabled: e.disabled,
|
|
923
1336
|
children: [
|
|
924
|
-
l ? /* @__PURE__ */
|
|
925
|
-
className:
|
|
926
|
-
children: t && /* @__PURE__ */
|
|
1337
|
+
l ? /* @__PURE__ */ Y("div", {
|
|
1338
|
+
className: Q("flex size-4 shrink-0 items-center justify-center rounded-sm border", t ? "border-primary bg-primary" : "border-input"),
|
|
1339
|
+
children: t && /* @__PURE__ */ Y(g, {
|
|
927
1340
|
size: 12,
|
|
928
1341
|
className: "text-primary-foreground"
|
|
929
1342
|
})
|
|
930
|
-
}) : /* @__PURE__ */
|
|
1343
|
+
}) : /* @__PURE__ */ Y("div", {
|
|
931
1344
|
className: "flex size-4 shrink-0 items-center justify-center",
|
|
932
|
-
children: t && /* @__PURE__ */
|
|
1345
|
+
children: t && /* @__PURE__ */ Y(g, {
|
|
933
1346
|
size: 16,
|
|
934
1347
|
className: "text-primary"
|
|
935
1348
|
})
|
|
936
1349
|
}),
|
|
937
|
-
(e.icon || e.image) && /* @__PURE__ */
|
|
1350
|
+
(e.icon || e.image) && /* @__PURE__ */ Y("div", {
|
|
938
1351
|
className: "flex size-4 shrink-0 items-center justify-center",
|
|
939
|
-
children: e.image ? /* @__PURE__ */
|
|
1352
|
+
children: e.image ? /* @__PURE__ */ Y("img", {
|
|
940
1353
|
src: e.image,
|
|
941
1354
|
alt: e.label,
|
|
942
1355
|
className: "size-4 rounded-sm object-cover"
|
|
943
1356
|
}) : e.icon
|
|
944
1357
|
}),
|
|
945
|
-
/* @__PURE__ */
|
|
1358
|
+
/* @__PURE__ */ X("div", {
|
|
946
1359
|
className: "flex flex-1 items-center justify-between gap-2",
|
|
947
|
-
children: [/* @__PURE__ */
|
|
1360
|
+
children: [/* @__PURE__ */ X("div", {
|
|
948
1361
|
className: "flex flex-col gap-0.5",
|
|
949
|
-
children: [/* @__PURE__ */
|
|
1362
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
950
1363
|
className: "text-sm font-normal",
|
|
951
1364
|
children: y && n ? y(n) : e.label
|
|
952
|
-
}), e.description && /* @__PURE__ */
|
|
1365
|
+
}), e.description && /* @__PURE__ */ Y("span", {
|
|
953
1366
|
className: "text-xs leading-snug text-muted-foreground",
|
|
954
1367
|
children: e.description
|
|
955
1368
|
})]
|
|
956
|
-
}), e.badge && /* @__PURE__ */
|
|
1369
|
+
}), e.badge && /* @__PURE__ */ Y("span", {
|
|
957
1370
|
className: "shrink-0 rounded bg-muted px-1.5 py-0.5 text-[10px] font-medium text-muted-foreground",
|
|
958
1371
|
children: e.badge
|
|
959
1372
|
})]
|
|
960
1373
|
})
|
|
961
1374
|
]
|
|
962
1375
|
}, e.value);
|
|
963
|
-
},
|
|
964
|
-
className:
|
|
1376
|
+
}, Z = /* @__PURE__ */ Y(Xt, {
|
|
1377
|
+
className: Q("w-(--radix-popper-anchor-width) min-w-(--radix-popper-anchor-width) p-0", re),
|
|
965
1378
|
align: "start",
|
|
966
1379
|
onOpenAutoFocus: (e) => {
|
|
967
1380
|
p || e.preventDefault();
|
|
968
1381
|
},
|
|
969
1382
|
onWheel: (e) => e.stopPropagation(),
|
|
970
|
-
children: /* @__PURE__ */
|
|
1383
|
+
children: /* @__PURE__ */ X(zt, { children: [p && /* @__PURE__ */ Y(Vt, {
|
|
971
1384
|
placeholder: `Search ${a.toLowerCase()}...`,
|
|
972
1385
|
autoFocus: !0
|
|
973
|
-
}), /* @__PURE__ */
|
|
974
|
-
onScroll:
|
|
975
|
-
children: T ? /* @__PURE__ */
|
|
1386
|
+
}), /* @__PURE__ */ Y(Ht, {
|
|
1387
|
+
onScroll: he,
|
|
1388
|
+
children: T ? /* @__PURE__ */ Y("div", {
|
|
976
1389
|
className: "flex items-center justify-center py-6",
|
|
977
|
-
children: /* @__PURE__ */
|
|
978
|
-
}) : /* @__PURE__ */
|
|
979
|
-
l &&
|
|
1390
|
+
children: /* @__PURE__ */ Y(F, { className: "size-5 animate-spin text-muted-foreground" })
|
|
1391
|
+
}) : /* @__PURE__ */ X(we, { children: [
|
|
1392
|
+
l && ne && W.length > 0 && /* @__PURE__ */ X(we, { children: [/* @__PURE__ */ Y(Wt, { children: /* @__PURE__ */ X(Kt, {
|
|
980
1393
|
value: "__select_all__",
|
|
981
|
-
onSelect:
|
|
1394
|
+
onSelect: fe,
|
|
982
1395
|
className: "font-medium",
|
|
983
|
-
children: [/* @__PURE__ */
|
|
984
|
-
className:
|
|
985
|
-
children:
|
|
1396
|
+
children: [/* @__PURE__ */ Y("div", {
|
|
1397
|
+
className: Q("flex size-4 shrink-0 items-center justify-center rounded-sm border", K ? "border-primary bg-primary" : "border-input"),
|
|
1398
|
+
children: K && /* @__PURE__ */ Y(g, {
|
|
986
1399
|
size: 12,
|
|
987
1400
|
className: "text-primary-foreground"
|
|
988
1401
|
})
|
|
989
|
-
}), /* @__PURE__ */
|
|
990
|
-
}) }), /* @__PURE__ */
|
|
991
|
-
/* @__PURE__ */
|
|
992
|
-
t.length > 0 ? t.map((e, t) => /* @__PURE__ */
|
|
1402
|
+
}), /* @__PURE__ */ Y("span", { children: "Select all" })]
|
|
1403
|
+
}) }), /* @__PURE__ */ Y(Gt, {})] }),
|
|
1404
|
+
/* @__PURE__ */ Y(Ut, { children: "No results found." }),
|
|
1405
|
+
t.length > 0 ? t.map((e, t) => /* @__PURE__ */ X(n.Fragment, { children: [t > 0 && /* @__PURE__ */ Y(Gt, {}), /* @__PURE__ */ Y(Wt, {
|
|
993
1406
|
heading: e.label,
|
|
994
|
-
children: e.options.map(
|
|
995
|
-
})] }, e.label)) : /* @__PURE__ */
|
|
996
|
-
C && /* @__PURE__ */
|
|
1407
|
+
children: e.options.map(Ce)
|
|
1408
|
+
})] }, e.label)) : /* @__PURE__ */ Y(Wt, { children: H.map(Ce) }),
|
|
1409
|
+
C && /* @__PURE__ */ X(we, { children: [/* @__PURE__ */ Y(Gt, {}), /* @__PURE__ */ Y(Wt, { children: /* @__PURE__ */ X($, {
|
|
997
1410
|
variant: "ghost",
|
|
998
1411
|
className: "w-full justify-start font-normal",
|
|
999
1412
|
onClick: () => {
|
|
1000
|
-
C(),
|
|
1413
|
+
C(), ie(!1);
|
|
1001
1414
|
},
|
|
1002
|
-
children: [/* @__PURE__ */
|
|
1415
|
+
children: [/* @__PURE__ */ Y(oe, {
|
|
1003
1416
|
size: 16,
|
|
1004
1417
|
className: "-ms-1 opacity-60",
|
|
1005
1418
|
"aria-hidden": !0
|
|
1006
1419
|
}), w]
|
|
1007
1420
|
}) })] }),
|
|
1008
|
-
N && /* @__PURE__ */
|
|
1421
|
+
N && /* @__PURE__ */ Y("div", {
|
|
1009
1422
|
className: "flex items-center justify-center py-3",
|
|
1010
|
-
children: /* @__PURE__ */
|
|
1423
|
+
children: /* @__PURE__ */ Y(F, { className: "size-4 animate-spin text-muted-foreground" })
|
|
1011
1424
|
})
|
|
1012
1425
|
] })
|
|
1013
1426
|
})] })
|
|
1014
|
-
}),
|
|
1427
|
+
}), Te = S ? /* @__PURE__ */ Y("span", {
|
|
1015
1428
|
"aria-hidden": !0,
|
|
1016
1429
|
className: "ml-0.5 text-destructive",
|
|
1017
1430
|
children: "*"
|
|
1018
1431
|
}) : null;
|
|
1019
|
-
return /* @__PURE__ */
|
|
1432
|
+
return /* @__PURE__ */ X("div", {
|
|
1020
1433
|
className: "space-y-1.5",
|
|
1021
1434
|
children: [
|
|
1022
|
-
b && /* @__PURE__ */
|
|
1023
|
-
htmlFor:
|
|
1435
|
+
b && /* @__PURE__ */ X(ct, {
|
|
1436
|
+
htmlFor: ae,
|
|
1024
1437
|
onClick: _e,
|
|
1025
|
-
className:
|
|
1026
|
-
children: [b,
|
|
1438
|
+
className: Q("cursor-pointer", o && "text-muted-foreground"),
|
|
1439
|
+
children: [b, Te]
|
|
1027
1440
|
}),
|
|
1028
|
-
ve ? /* @__PURE__ */
|
|
1029
|
-
open:
|
|
1030
|
-
onOpenChange:
|
|
1441
|
+
ve ? /* @__PURE__ */ X(Jt, {
|
|
1442
|
+
open: L,
|
|
1443
|
+
onOpenChange: se,
|
|
1031
1444
|
modal: !1,
|
|
1032
|
-
children: [/* @__PURE__ */
|
|
1445
|
+
children: [/* @__PURE__ */ Y(Yt, {
|
|
1033
1446
|
asChild: !0,
|
|
1034
|
-
children: /* @__PURE__ */
|
|
1447
|
+
children: /* @__PURE__ */ X("div", {
|
|
1035
1448
|
"aria-invalid": s,
|
|
1036
|
-
className:
|
|
1449
|
+
className: Q("flex rounded-md border border-input transition-colors", J ? "items-stretch" : "items-center overflow-hidden", be, ye, L && "border-ring ring-3 ring-ring/50", "aria-[invalid=true]:border-destructive aria-[invalid=true]:ring-3 aria-[invalid=true]:ring-destructive/20", o && "pointer-events-none cursor-not-allowed opacity-50"),
|
|
1037
1450
|
children: [
|
|
1038
|
-
|
|
1451
|
+
D && /* @__PURE__ */ Y("div", {
|
|
1039
1452
|
className: "flex h-full shrink-0 items-center justify-center border-r border-input bg-muted/40 px-3 text-sm text-muted-foreground [&_svg]:size-4",
|
|
1040
|
-
children:
|
|
1453
|
+
children: D
|
|
1041
1454
|
}),
|
|
1042
|
-
/* @__PURE__ */
|
|
1043
|
-
id:
|
|
1455
|
+
/* @__PURE__ */ X($, {
|
|
1456
|
+
id: ae,
|
|
1044
1457
|
type: "button",
|
|
1045
1458
|
disabled: o,
|
|
1046
1459
|
ref: z,
|
|
1047
1460
|
variant: "ghost",
|
|
1048
1461
|
role: "combobox",
|
|
1049
|
-
"aria-expanded":
|
|
1462
|
+
"aria-expanded": L,
|
|
1050
1463
|
onClick: (e) => {
|
|
1051
|
-
|
|
1464
|
+
I && (e.preventDefault(), e.stopPropagation());
|
|
1052
1465
|
},
|
|
1053
|
-
className:
|
|
1054
|
-
children: [
|
|
1466
|
+
className: Q("h-full flex-1 justify-between rounded-none border-0 px-3 py-1 font-normal text-foreground shadow-none hover:bg-transparent focus-visible:ring-0", J ? "items-start" : "items-center", u),
|
|
1467
|
+
children: [xe, Se]
|
|
1055
1468
|
}),
|
|
1056
|
-
|
|
1469
|
+
O && /* @__PURE__ */ Y("div", {
|
|
1057
1470
|
className: "flex h-full shrink-0 items-center justify-center border-l border-input bg-muted/40 px-3 text-sm text-foreground [&_svg]:size-4",
|
|
1058
|
-
children:
|
|
1471
|
+
children: O
|
|
1059
1472
|
})
|
|
1060
1473
|
]
|
|
1061
1474
|
})
|
|
1062
|
-
}),
|
|
1063
|
-
}) : /* @__PURE__ */
|
|
1064
|
-
open:
|
|
1065
|
-
onOpenChange:
|
|
1475
|
+
}), Z]
|
|
1476
|
+
}) : /* @__PURE__ */ X(Jt, {
|
|
1477
|
+
open: L,
|
|
1478
|
+
onOpenChange: se,
|
|
1066
1479
|
modal: !1,
|
|
1067
|
-
children: [/* @__PURE__ */
|
|
1480
|
+
children: [/* @__PURE__ */ Y(Yt, {
|
|
1068
1481
|
asChild: !0,
|
|
1069
|
-
children: /* @__PURE__ */
|
|
1070
|
-
id:
|
|
1482
|
+
children: /* @__PURE__ */ X($, {
|
|
1483
|
+
id: ae,
|
|
1071
1484
|
type: "button",
|
|
1072
1485
|
disabled: o,
|
|
1073
1486
|
ref: z,
|
|
1074
1487
|
variant: "outline",
|
|
1075
1488
|
role: "combobox",
|
|
1076
|
-
"aria-expanded":
|
|
1489
|
+
"aria-expanded": L,
|
|
1077
1490
|
"aria-invalid": s,
|
|
1078
1491
|
onClick: (e) => {
|
|
1079
|
-
|
|
1492
|
+
I && (e.preventDefault(), e.stopPropagation());
|
|
1080
1493
|
},
|
|
1081
|
-
className:
|
|
1082
|
-
children: [
|
|
1494
|
+
className: Q("h-auto w-full justify-between px-3 py-1 font-normal text-foreground", ye, J ? "items-start" : "items-center", be, L && "border-ring ring-3 ring-ring/50", u),
|
|
1495
|
+
children: [xe, Se]
|
|
1083
1496
|
})
|
|
1084
|
-
}),
|
|
1497
|
+
}), Z]
|
|
1085
1498
|
}),
|
|
1086
|
-
s && c && /* @__PURE__ */
|
|
1499
|
+
s && c && /* @__PURE__ */ Y("p", {
|
|
1087
1500
|
className: "text-xs leading-5 text-destructive",
|
|
1088
1501
|
children: c
|
|
1089
1502
|
}),
|
|
1090
|
-
x && /* @__PURE__ */
|
|
1503
|
+
x && /* @__PURE__ */ Y(ut, { children: x })
|
|
1091
1504
|
]
|
|
1092
1505
|
});
|
|
1093
1506
|
}
|
|
1094
1507
|
//#endregion
|
|
1095
1508
|
//#region src/components/ui/checkbox.tsx
|
|
1096
|
-
function
|
|
1097
|
-
return /* @__PURE__ */
|
|
1509
|
+
function rn({ className: e, ...t }) {
|
|
1510
|
+
return /* @__PURE__ */ Y(W.Root, {
|
|
1098
1511
|
"data-slot": "checkbox",
|
|
1099
|
-
className:
|
|
1512
|
+
className: Q("peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary", e),
|
|
1100
1513
|
...t,
|
|
1101
|
-
children: /* @__PURE__ */
|
|
1514
|
+
children: /* @__PURE__ */ Y(W.Indicator, {
|
|
1102
1515
|
"data-slot": "checkbox-indicator",
|
|
1103
1516
|
className: "grid place-content-center text-current transition-none [&>svg]:size-3.5",
|
|
1104
|
-
children: /* @__PURE__ */
|
|
1517
|
+
children: /* @__PURE__ */ Y(g, {})
|
|
1105
1518
|
})
|
|
1106
1519
|
});
|
|
1107
1520
|
}
|
|
1108
1521
|
//#endregion
|
|
1109
1522
|
//#region src/components/ui/table.tsx
|
|
1110
|
-
function
|
|
1111
|
-
return /* @__PURE__ */
|
|
1523
|
+
function an({ className: e, ...t }) {
|
|
1524
|
+
return /* @__PURE__ */ Y("div", {
|
|
1112
1525
|
"data-slot": "table-container",
|
|
1113
1526
|
className: "relative w-full overflow-x-auto",
|
|
1114
|
-
children: /* @__PURE__ */
|
|
1527
|
+
children: /* @__PURE__ */ Y("table", {
|
|
1115
1528
|
"data-slot": "table",
|
|
1116
|
-
className:
|
|
1529
|
+
className: Q("w-full caption-bottom text-sm", e),
|
|
1117
1530
|
...t
|
|
1118
1531
|
})
|
|
1119
1532
|
});
|
|
1120
1533
|
}
|
|
1121
|
-
function
|
|
1122
|
-
return /* @__PURE__ */
|
|
1534
|
+
function on({ className: e, ...t }) {
|
|
1535
|
+
return /* @__PURE__ */ Y("thead", {
|
|
1123
1536
|
"data-slot": "table-header",
|
|
1124
|
-
className:
|
|
1537
|
+
className: Q("[&_tr]:border-b", e),
|
|
1125
1538
|
...t
|
|
1126
1539
|
});
|
|
1127
1540
|
}
|
|
1128
|
-
function
|
|
1129
|
-
return /* @__PURE__ */
|
|
1541
|
+
function sn({ className: e, ...t }) {
|
|
1542
|
+
return /* @__PURE__ */ Y("tbody", {
|
|
1130
1543
|
"data-slot": "table-body",
|
|
1131
|
-
className:
|
|
1544
|
+
className: Q("[&_tr:last-child]:border-0", e),
|
|
1132
1545
|
...t
|
|
1133
1546
|
});
|
|
1134
1547
|
}
|
|
1135
|
-
function
|
|
1136
|
-
return /* @__PURE__ */
|
|
1548
|
+
function cn({ className: e, ...t }) {
|
|
1549
|
+
return /* @__PURE__ */ Y("tfoot", {
|
|
1137
1550
|
"data-slot": "table-footer",
|
|
1138
|
-
className:
|
|
1551
|
+
className: Q("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0", e),
|
|
1139
1552
|
...t
|
|
1140
1553
|
});
|
|
1141
1554
|
}
|
|
1142
|
-
function
|
|
1143
|
-
return /* @__PURE__ */
|
|
1555
|
+
function ln({ className: e, ...t }) {
|
|
1556
|
+
return /* @__PURE__ */ Y("tr", {
|
|
1144
1557
|
"data-slot": "table-row",
|
|
1145
|
-
className:
|
|
1558
|
+
className: Q("border-b transition-colors hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted", e),
|
|
1146
1559
|
...t
|
|
1147
1560
|
});
|
|
1148
1561
|
}
|
|
1149
|
-
function
|
|
1150
|
-
return /* @__PURE__ */
|
|
1562
|
+
function un({ className: e, ...t }) {
|
|
1563
|
+
return /* @__PURE__ */ Y("th", {
|
|
1151
1564
|
"data-slot": "table-head",
|
|
1152
|
-
className:
|
|
1565
|
+
className: Q("h-10 px-2 text-left align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pr-0", e),
|
|
1153
1566
|
...t
|
|
1154
1567
|
});
|
|
1155
1568
|
}
|
|
1156
|
-
function
|
|
1157
|
-
return /* @__PURE__ */
|
|
1569
|
+
function dn({ className: e, ...t }) {
|
|
1570
|
+
return /* @__PURE__ */ Y("td", {
|
|
1158
1571
|
"data-slot": "table-cell",
|
|
1159
|
-
className:
|
|
1572
|
+
className: Q("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0", e),
|
|
1160
1573
|
...t
|
|
1161
1574
|
});
|
|
1162
1575
|
}
|
|
1163
|
-
function
|
|
1164
|
-
return /* @__PURE__ */
|
|
1576
|
+
function fn({ className: e, ...t }) {
|
|
1577
|
+
return /* @__PURE__ */ Y("caption", {
|
|
1165
1578
|
"data-slot": "table-caption",
|
|
1166
|
-
className:
|
|
1167
|
-
...t
|
|
1168
|
-
});
|
|
1169
|
-
}
|
|
1170
|
-
//#endregion
|
|
1171
|
-
//#region src/components/ui/spinner.tsx
|
|
1172
|
-
function qt({ className: e, ...t }) {
|
|
1173
|
-
return /* @__PURE__ */ J(D, {
|
|
1174
|
-
role: "status",
|
|
1175
|
-
"aria-label": "Loading",
|
|
1176
|
-
className: Z("size-4 animate-spin", e),
|
|
1579
|
+
className: Q("mt-4 text-sm text-muted-foreground", e),
|
|
1177
1580
|
...t
|
|
1178
1581
|
});
|
|
1179
1582
|
}
|
|
1180
1583
|
//#endregion
|
|
1181
1584
|
//#region src/components/custom/data-table.tsx
|
|
1182
|
-
var
|
|
1585
|
+
var pn = {
|
|
1183
1586
|
left: "text-left",
|
|
1184
1587
|
center: "text-center",
|
|
1185
1588
|
right: "text-right"
|
|
1186
1589
|
};
|
|
1187
|
-
function
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1590
|
+
function mn({ columns: e, data: t, getRowId: r = (e, t) => String(t), selectable: i = !1, selectedIds: a, onSelectionChange: o, rowActions: s, loading: c = !1, emptyMessage: l = "No results.", pagination: u = !1, pageSize: d = 25, pageSizeOptions: f = [
|
|
1591
|
+
25,
|
|
1592
|
+
50,
|
|
1593
|
+
100,
|
|
1594
|
+
200
|
|
1595
|
+
], striped: p = !0, stickyHeader: m = !1, maxHeight: h, onRowClick: g, className: _ }) {
|
|
1596
|
+
let v = n.useMemo(() => t.map((e, t) => r(e, t)), [t, r]), [x, w] = n.useState([]), T = a ?? x, E = (e) => {
|
|
1597
|
+
a === void 0 && w(e), o?.(e);
|
|
1598
|
+
}, ee = v.length > 0 && v.every((e) => T.includes(e)), D = T.length > 0 && !ee, O = () => E(ee ? [] : v), k = (e) => E(T.includes(e) ? T.filter((t) => t !== e) : [...T, e]), te = e.length + +!!i + +!!s, [A, j] = n.useState(d), [M, N] = n.useState(0), P = u ? Math.max(1, Math.ceil(t.length / A)) : 1, F = Math.min(M, P - 1), ne = n.useMemo(() => {
|
|
1599
|
+
let e = t.map((e, t) => ({
|
|
1600
|
+
row: e,
|
|
1601
|
+
index: t
|
|
1602
|
+
}));
|
|
1603
|
+
if (!u) return e;
|
|
1604
|
+
let n = F * A;
|
|
1605
|
+
return e.slice(n, n + A);
|
|
1606
|
+
}, [
|
|
1607
|
+
t,
|
|
1608
|
+
u,
|
|
1609
|
+
F,
|
|
1610
|
+
A
|
|
1611
|
+
]), I = "px-4 py-3 first:pl-5 last:pr-5", re = "px-4 first:pl-5 last:pr-5";
|
|
1612
|
+
return /* @__PURE__ */ X("div", {
|
|
1613
|
+
className: Q("rounded-lg border", _),
|
|
1614
|
+
children: [/* @__PURE__ */ Y("div", {
|
|
1615
|
+
className: Q("overflow-hidden rounded-lg", h === void 0 ? "overflow-hidden" : "overflow-auto", u && "rounded-b-none"),
|
|
1616
|
+
style: h === void 0 ? void 0 : { maxHeight: typeof h == "number" ? `${h}px` : h },
|
|
1617
|
+
children: /* @__PURE__ */ X(an, { children: [/* @__PURE__ */ Y(on, {
|
|
1618
|
+
className: Q("bg-muted/60", m && "sticky top-0 z-10 [&_th]:bg-muted/95 [&_th]:backdrop-blur supports-backdrop-filter:[&_th]:bg-muted/80"),
|
|
1619
|
+
children: /* @__PURE__ */ X(ln, {
|
|
1620
|
+
className: "hover:bg-transparent",
|
|
1621
|
+
children: [
|
|
1622
|
+
i && /* @__PURE__ */ Y(un, {
|
|
1623
|
+
className: Q("w-10", re),
|
|
1624
|
+
children: /* @__PURE__ */ Y(rn, {
|
|
1625
|
+
"aria-label": "Select all rows",
|
|
1626
|
+
checked: ee ? !0 : D ? "indeterminate" : !1,
|
|
1627
|
+
onCheckedChange: O
|
|
1628
|
+
})
|
|
1629
|
+
}),
|
|
1630
|
+
e.map((e) => /* @__PURE__ */ Y(un, {
|
|
1631
|
+
style: e.width ? { width: e.width } : void 0,
|
|
1632
|
+
className: Q("h-11 text-xs font-semibold tracking-wide text-foreground uppercase", re, e.align && pn[e.align], e.className, e.headerClassName),
|
|
1633
|
+
children: e.header
|
|
1634
|
+
}, e.key)),
|
|
1635
|
+
s && /* @__PURE__ */ Y(un, { className: "w-12" })
|
|
1636
|
+
]
|
|
1637
|
+
})
|
|
1638
|
+
}), /* @__PURE__ */ Y(sn, { children: c ? /* @__PURE__ */ Y(ln, {
|
|
1197
1639
|
className: "hover:bg-transparent",
|
|
1198
|
-
children:
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
})
|
|
1206
|
-
}),
|
|
1207
|
-
e.map((e) => /* @__PURE__ */ J(Wt, {
|
|
1208
|
-
style: e.width ? { width: e.width } : void 0,
|
|
1209
|
-
className: Z("h-11 text-xs font-semibold tracking-wide text-foreground uppercase", E, e.align && Jt[e.align], e.className, e.headerClassName),
|
|
1210
|
-
children: e.header
|
|
1211
|
-
}, e.key)),
|
|
1212
|
-
s && /* @__PURE__ */ J(Wt, { className: "w-12" })
|
|
1213
|
-
]
|
|
1214
|
-
})
|
|
1215
|
-
}), /* @__PURE__ */ J(Vt, { children: c ? /* @__PURE__ */ J(Ut, {
|
|
1216
|
-
className: "hover:bg-transparent",
|
|
1217
|
-
children: /* @__PURE__ */ J(Gt, {
|
|
1218
|
-
colSpan: w,
|
|
1219
|
-
className: "h-28 text-center",
|
|
1220
|
-
children: /* @__PURE__ */ Y("span", {
|
|
1221
|
-
className: "inline-flex items-center gap-2 text-muted-foreground",
|
|
1222
|
-
children: [/* @__PURE__ */ J(qt, { className: "size-4" }), " Loading…"]
|
|
1640
|
+
children: /* @__PURE__ */ Y(dn, {
|
|
1641
|
+
colSpan: te,
|
|
1642
|
+
className: "h-28 text-center",
|
|
1643
|
+
children: /* @__PURE__ */ X("span", {
|
|
1644
|
+
className: "inline-flex items-center gap-2 text-muted-foreground",
|
|
1645
|
+
children: [/* @__PURE__ */ Y(Pe, { className: "size-4" }), " Loading…"]
|
|
1646
|
+
})
|
|
1223
1647
|
})
|
|
1224
|
-
})
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
})
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1648
|
+
}) : t.length === 0 ? /* @__PURE__ */ Y(ln, {
|
|
1649
|
+
className: "hover:bg-transparent",
|
|
1650
|
+
children: /* @__PURE__ */ Y(dn, {
|
|
1651
|
+
colSpan: te,
|
|
1652
|
+
className: "h-28 text-center text-muted-foreground",
|
|
1653
|
+
children: l
|
|
1654
|
+
})
|
|
1655
|
+
}) : ne.map(({ row: t, index: n }) => {
|
|
1656
|
+
let r = v[n], a = T.includes(r);
|
|
1657
|
+
return /* @__PURE__ */ X(ln, {
|
|
1658
|
+
"data-state": a ? "selected" : void 0,
|
|
1659
|
+
onClick: g ? () => g(t) : void 0,
|
|
1660
|
+
className: Q(p && !a && "odd:bg-muted/40", a && "bg-primary/10 shadow-[inset_3px_0_0_0_var(--primary)] hover:bg-primary/15", g && "cursor-pointer"),
|
|
1661
|
+
children: [
|
|
1662
|
+
i && /* @__PURE__ */ Y(dn, {
|
|
1663
|
+
className: Q("w-10", I),
|
|
1664
|
+
onClick: (e) => e.stopPropagation(),
|
|
1665
|
+
children: /* @__PURE__ */ Y(rn, {
|
|
1666
|
+
"aria-label": "Select row",
|
|
1667
|
+
checked: a,
|
|
1668
|
+
onCheckedChange: () => k(r)
|
|
1669
|
+
})
|
|
1670
|
+
}),
|
|
1671
|
+
e.map((e) => /* @__PURE__ */ Y(dn, {
|
|
1672
|
+
style: e.width ? { width: e.width } : void 0,
|
|
1673
|
+
className: Q(I, e.align && pn[e.align], e.className),
|
|
1674
|
+
children: e.cell ? e.cell(t, n) : String(t[e.key] ?? "")
|
|
1675
|
+
}, e.key)),
|
|
1676
|
+
s && /* @__PURE__ */ Y(dn, {
|
|
1677
|
+
className: "w-12 pr-3 text-right",
|
|
1678
|
+
onClick: (e) => e.stopPropagation(),
|
|
1679
|
+
children: /* @__PURE__ */ Y($e, { items: s(t) })
|
|
1246
1680
|
})
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1681
|
+
]
|
|
1682
|
+
}, r);
|
|
1683
|
+
}) })] })
|
|
1684
|
+
}), u && /* @__PURE__ */ X("div", {
|
|
1685
|
+
className: "flex flex-wrap items-center justify-between gap-3 border-t px-4 py-3 text-sm",
|
|
1686
|
+
children: [/* @__PURE__ */ X("p", {
|
|
1687
|
+
className: "text-muted-foreground",
|
|
1688
|
+
children: [
|
|
1689
|
+
"Page ",
|
|
1690
|
+
t.length === 0 ? 0 : F + 1,
|
|
1691
|
+
" of ",
|
|
1692
|
+
P,
|
|
1693
|
+
" (",
|
|
1694
|
+
t.length,
|
|
1695
|
+
" total ",
|
|
1696
|
+
t.length === 1 ? "item" : "items",
|
|
1697
|
+
")"
|
|
1258
1698
|
]
|
|
1259
|
-
},
|
|
1260
|
-
|
|
1699
|
+
}), /* @__PURE__ */ X("div", {
|
|
1700
|
+
className: "flex items-center gap-4",
|
|
1701
|
+
children: [f && f.length > 0 && /* @__PURE__ */ X("div", {
|
|
1702
|
+
className: "flex items-center gap-2 text-muted-foreground",
|
|
1703
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
1704
|
+
className: "whitespace-nowrap",
|
|
1705
|
+
children: "Rows per page"
|
|
1706
|
+
}), /* @__PURE__ */ Y(nn, {
|
|
1707
|
+
size: "sm",
|
|
1708
|
+
className: "w-20",
|
|
1709
|
+
value: String(A),
|
|
1710
|
+
onValueChange: (e) => {
|
|
1711
|
+
let t = typeof e == "object" && e && "value" in e ? e.value : e;
|
|
1712
|
+
j(Number(t)), N(0);
|
|
1713
|
+
},
|
|
1714
|
+
options: f.map((e) => ({
|
|
1715
|
+
value: String(e),
|
|
1716
|
+
label: String(e)
|
|
1717
|
+
}))
|
|
1718
|
+
})]
|
|
1719
|
+
}), /* @__PURE__ */ X("div", {
|
|
1720
|
+
className: "flex items-center gap-1",
|
|
1721
|
+
children: [
|
|
1722
|
+
/* @__PURE__ */ Y($, {
|
|
1723
|
+
variant: "outline",
|
|
1724
|
+
size: "icon-sm",
|
|
1725
|
+
"aria-label": "First page",
|
|
1726
|
+
disabled: F <= 0,
|
|
1727
|
+
onClick: () => N(0),
|
|
1728
|
+
children: /* @__PURE__ */ Y(S, {})
|
|
1729
|
+
}),
|
|
1730
|
+
/* @__PURE__ */ Y($, {
|
|
1731
|
+
variant: "outline",
|
|
1732
|
+
size: "icon-sm",
|
|
1733
|
+
"aria-label": "Previous page",
|
|
1734
|
+
disabled: F <= 0,
|
|
1735
|
+
onClick: () => N(Math.max(0, F - 1)),
|
|
1736
|
+
children: /* @__PURE__ */ Y(y, {})
|
|
1737
|
+
}),
|
|
1738
|
+
/* @__PURE__ */ Y($, {
|
|
1739
|
+
variant: "outline",
|
|
1740
|
+
size: "icon-sm",
|
|
1741
|
+
"aria-label": "Next page",
|
|
1742
|
+
disabled: F >= P - 1,
|
|
1743
|
+
onClick: () => N(Math.min(P - 1, F + 1)),
|
|
1744
|
+
children: /* @__PURE__ */ Y(b, {})
|
|
1745
|
+
}),
|
|
1746
|
+
/* @__PURE__ */ Y($, {
|
|
1747
|
+
variant: "outline",
|
|
1748
|
+
size: "icon-sm",
|
|
1749
|
+
"aria-label": "Last page",
|
|
1750
|
+
disabled: F >= P - 1,
|
|
1751
|
+
onClick: () => N(P - 1),
|
|
1752
|
+
children: /* @__PURE__ */ Y(C, {})
|
|
1753
|
+
})
|
|
1754
|
+
]
|
|
1755
|
+
})]
|
|
1756
|
+
})]
|
|
1757
|
+
})]
|
|
1261
1758
|
});
|
|
1262
1759
|
}
|
|
1263
1760
|
//#endregion
|
|
1264
1761
|
//#region src/components/ui/calendar.tsx
|
|
1265
|
-
function
|
|
1266
|
-
let l =
|
|
1267
|
-
return /* @__PURE__ */
|
|
1762
|
+
function hn({ className: e, classNames: t, showOutsideDays: n = !0, captionLayout: r = "label", buttonVariant: i = "ghost", locale: a, formatters: o, components: s, ...c }) {
|
|
1763
|
+
let l = Ee();
|
|
1764
|
+
return /* @__PURE__ */ Y(Te, {
|
|
1268
1765
|
showOutsideDays: n,
|
|
1269
|
-
className:
|
|
1766
|
+
className: Q("group/calendar bg-background p-2 [--cell-radius:var(--radius-md)] [--cell-size:--spacing(7)] in-data-[slot=card-content]:bg-transparent in-data-[slot=popover-content]:bg-transparent", String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`, String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`, e),
|
|
1270
1767
|
captionLayout: r,
|
|
1271
1768
|
locale: a,
|
|
1272
1769
|
formatters: {
|
|
@@ -1274,51 +1771,51 @@ function Xt({ className: e, classNames: t, showOutsideDays: n = !0, captionLayou
|
|
|
1274
1771
|
...o
|
|
1275
1772
|
},
|
|
1276
1773
|
classNames: {
|
|
1277
|
-
root:
|
|
1278
|
-
months:
|
|
1279
|
-
month:
|
|
1280
|
-
nav:
|
|
1281
|
-
button_previous:
|
|
1282
|
-
button_next:
|
|
1283
|
-
month_caption:
|
|
1284
|
-
dropdowns:
|
|
1285
|
-
dropdown_root:
|
|
1286
|
-
dropdown:
|
|
1287
|
-
caption_label:
|
|
1774
|
+
root: Q("w-fit", l.root),
|
|
1775
|
+
months: Q("relative flex flex-col gap-4 md:flex-row", l.months),
|
|
1776
|
+
month: Q("flex w-full flex-col gap-4", l.month),
|
|
1777
|
+
nav: Q("absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1", l.nav),
|
|
1778
|
+
button_previous: Q(Fe({ variant: i }), "size-(--cell-size) p-0 select-none aria-disabled:opacity-50", l.button_previous),
|
|
1779
|
+
button_next: Q(Fe({ variant: i }), "size-(--cell-size) p-0 select-none aria-disabled:opacity-50", l.button_next),
|
|
1780
|
+
month_caption: Q("flex h-(--cell-size) w-full items-center justify-center px-(--cell-size)", l.month_caption),
|
|
1781
|
+
dropdowns: Q("flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-medium", l.dropdowns),
|
|
1782
|
+
dropdown_root: Q("relative rounded-(--cell-radius)", l.dropdown_root),
|
|
1783
|
+
dropdown: Q("absolute inset-0 bg-popover opacity-0", l.dropdown),
|
|
1784
|
+
caption_label: Q("font-medium select-none", r === "label" ? "text-sm" : "flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground", l.caption_label),
|
|
1288
1785
|
table: "w-full border-collapse",
|
|
1289
|
-
weekdays:
|
|
1290
|
-
weekday:
|
|
1291
|
-
week:
|
|
1292
|
-
week_number_header:
|
|
1293
|
-
week_number:
|
|
1294
|
-
day:
|
|
1295
|
-
range_start:
|
|
1296
|
-
range_middle:
|
|
1297
|
-
range_end:
|
|
1298
|
-
today:
|
|
1299
|
-
outside:
|
|
1300
|
-
disabled:
|
|
1301
|
-
hidden:
|
|
1786
|
+
weekdays: Q("flex", l.weekdays),
|
|
1787
|
+
weekday: Q("flex-1 rounded-(--cell-radius) text-[0.8rem] font-normal text-muted-foreground select-none", l.weekday),
|
|
1788
|
+
week: Q("mt-2 flex w-full", l.week),
|
|
1789
|
+
week_number_header: Q("w-(--cell-size) select-none", l.week_number_header),
|
|
1790
|
+
week_number: Q("text-[0.8rem] text-muted-foreground select-none", l.week_number),
|
|
1791
|
+
day: Q("group/day relative aspect-square h-full w-full rounded-(--cell-radius) p-0 text-center select-none [&:last-child[data-selected=true]_button]:rounded-r-(--cell-radius)", c.showWeekNumber ? "[&:nth-child(2)[data-selected=true]_button]:rounded-l-(--cell-radius)" : "[&:first-child[data-selected=true]_button]:rounded-l-(--cell-radius)", l.day),
|
|
1792
|
+
range_start: Q("relative isolate z-0 rounded-l-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:right-0 after:w-4 after:bg-muted", l.range_start),
|
|
1793
|
+
range_middle: Q("rounded-none", l.range_middle),
|
|
1794
|
+
range_end: Q("relative isolate z-0 rounded-r-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:left-0 after:w-4 after:bg-muted", l.range_end),
|
|
1795
|
+
today: Q("rounded-(--cell-radius) bg-muted text-foreground data-[selected=true]:rounded-none", l.today),
|
|
1796
|
+
outside: Q("text-muted-foreground aria-selected:text-muted-foreground", l.outside),
|
|
1797
|
+
disabled: Q("text-muted-foreground opacity-50", l.disabled),
|
|
1798
|
+
hidden: Q("invisible", l.hidden),
|
|
1302
1799
|
...t
|
|
1303
1800
|
},
|
|
1304
1801
|
components: {
|
|
1305
|
-
Root: ({ className: e, rootRef: t, ...n }) => /* @__PURE__ */
|
|
1802
|
+
Root: ({ className: e, rootRef: t, ...n }) => /* @__PURE__ */ Y("div", {
|
|
1306
1803
|
"data-slot": "calendar",
|
|
1307
1804
|
ref: t,
|
|
1308
|
-
className:
|
|
1805
|
+
className: Q(e),
|
|
1309
1806
|
...n
|
|
1310
1807
|
}),
|
|
1311
|
-
Chevron: ({ className: e, orientation: t, ...n }) =>
|
|
1312
|
-
className:
|
|
1808
|
+
Chevron: ({ className: e, orientation: t, ...n }) => Y(t === "left" ? y : t === "right" ? b : v, {
|
|
1809
|
+
className: Q("size-4", e),
|
|
1313
1810
|
...n
|
|
1314
1811
|
}),
|
|
1315
|
-
DayButton: ({ ...e }) => /* @__PURE__ */
|
|
1812
|
+
DayButton: ({ ...e }) => /* @__PURE__ */ Y(gn, {
|
|
1316
1813
|
locale: a,
|
|
1317
1814
|
...e
|
|
1318
1815
|
}),
|
|
1319
|
-
WeekNumber: ({ children: e, ...t }) => /* @__PURE__ */
|
|
1816
|
+
WeekNumber: ({ children: e, ...t }) => /* @__PURE__ */ Y("td", {
|
|
1320
1817
|
...t,
|
|
1321
|
-
children: /* @__PURE__ */
|
|
1818
|
+
children: /* @__PURE__ */ Y("div", {
|
|
1322
1819
|
className: "flex size-(--cell-size) items-center justify-center text-center",
|
|
1323
1820
|
children: e
|
|
1324
1821
|
})
|
|
@@ -1328,11 +1825,11 @@ function Xt({ className: e, classNames: t, showOutsideDays: n = !0, captionLayou
|
|
|
1328
1825
|
...c
|
|
1329
1826
|
});
|
|
1330
1827
|
}
|
|
1331
|
-
function
|
|
1332
|
-
let o =
|
|
1828
|
+
function gn({ className: e, day: t, modifiers: r, locale: i, ...a }) {
|
|
1829
|
+
let o = Ee(), s = n.useRef(null);
|
|
1333
1830
|
return n.useEffect(() => {
|
|
1334
1831
|
r.focused && s.current?.focus();
|
|
1335
|
-
}, [r.focused]), /* @__PURE__ */
|
|
1832
|
+
}, [r.focused]), /* @__PURE__ */ Y($, {
|
|
1336
1833
|
ref: s,
|
|
1337
1834
|
variant: "ghost",
|
|
1338
1835
|
size: "icon",
|
|
@@ -1341,16 +1838,16 @@ function Zt({ className: e, day: t, modifiers: r, locale: i, ...a }) {
|
|
|
1341
1838
|
"data-range-start": r.range_start,
|
|
1342
1839
|
"data-range-end": r.range_end,
|
|
1343
1840
|
"data-range-middle": r.range_middle,
|
|
1344
|
-
className:
|
|
1841
|
+
className: Q("relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-size) flex-col gap-1 border-0 leading-none font-normal group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring group-data-[focused=true]/day:ring-[3px] group-data-[focused=true]/day:ring-ring/50 data-[range-end=true]:rounded-(--cell-radius) data-[range-end=true]:rounded-r-(--cell-radius) data-[range-end=true]:bg-primary data-[range-end=true]:text-primary-foreground data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-muted data-[range-middle=true]:text-foreground data-[range-start=true]:rounded-(--cell-radius) data-[range-start=true]:rounded-l-(--cell-radius) data-[range-start=true]:bg-primary data-[range-start=true]:text-primary-foreground data-[selected-single=true]:bg-primary data-[selected-single=true]:text-primary-foreground dark:hover:text-foreground [&>span]:text-xs [&>span]:opacity-70", o.day, e),
|
|
1345
1842
|
...a
|
|
1346
1843
|
});
|
|
1347
1844
|
}
|
|
1348
1845
|
//#endregion
|
|
1349
1846
|
//#region src/components/custom/date-time-range-picker-utils.ts
|
|
1350
|
-
function
|
|
1847
|
+
function _n(e) {
|
|
1351
1848
|
return `${e.getUTCFullYear()}-${String(e.getUTCMonth() + 1).padStart(2, "0")}-${String(e.getUTCDate()).padStart(2, "0")}T${String(e.getUTCHours()).padStart(2, "0")}:${String(e.getUTCMinutes()).padStart(2, "0")}:${String(e.getUTCSeconds()).padStart(2, "0")}Z`;
|
|
1352
1849
|
}
|
|
1353
|
-
function
|
|
1850
|
+
function vn(e, t) {
|
|
1354
1851
|
if (!e) return null;
|
|
1355
1852
|
let n = new Date(e);
|
|
1356
1853
|
if (isNaN(n.getTime())) return null;
|
|
@@ -1373,7 +1870,7 @@ function $t(e, t) {
|
|
|
1373
1870
|
s: i("second").padStart(2, "0")
|
|
1374
1871
|
};
|
|
1375
1872
|
}
|
|
1376
|
-
function
|
|
1873
|
+
function yn(e, t, n, r, i, a, o) {
|
|
1377
1874
|
let s = Date.UTC(e, t, n, parseInt(r), parseInt(i), parseInt(a)), c = new Date(s), l = new Intl.DateTimeFormat("en-US", {
|
|
1378
1875
|
year: "numeric",
|
|
1379
1876
|
month: "2-digit",
|
|
@@ -1384,9 +1881,9 @@ function en(e, t, n, r, i, a, o) {
|
|
|
1384
1881
|
hour12: !1,
|
|
1385
1882
|
timeZone: o
|
|
1386
1883
|
}).formatToParts(c), u = (e) => parseInt(l.find((t) => t.type === e)?.value || "0", 10), d = Date.UTC(u("year"), u("month") - 1, u("day"), u("hour"), u("minute"), u("second")) - s;
|
|
1387
|
-
return
|
|
1884
|
+
return _n(new Date(s - d));
|
|
1388
1885
|
}
|
|
1389
|
-
var
|
|
1886
|
+
var bn = [
|
|
1390
1887
|
{
|
|
1391
1888
|
value: "hour",
|
|
1392
1889
|
label: "Hour"
|
|
@@ -1404,8 +1901,8 @@ var tn = [
|
|
|
1404
1901
|
label: "Month"
|
|
1405
1902
|
}
|
|
1406
1903
|
];
|
|
1407
|
-
function
|
|
1408
|
-
let t = /* @__PURE__ */ new Date(), n =
|
|
1904
|
+
function xn(e) {
|
|
1905
|
+
let t = /* @__PURE__ */ new Date(), n = _n(t), r = new Date(t);
|
|
1409
1906
|
switch (e) {
|
|
1410
1907
|
case "hour":
|
|
1411
1908
|
r.setUTCHours(r.getUTCHours() - 1);
|
|
@@ -1421,20 +1918,20 @@ function nn(e) {
|
|
|
1421
1918
|
break;
|
|
1422
1919
|
}
|
|
1423
1920
|
return {
|
|
1424
|
-
from:
|
|
1921
|
+
from: _n(r),
|
|
1425
1922
|
to: n
|
|
1426
1923
|
};
|
|
1427
1924
|
}
|
|
1428
|
-
function
|
|
1925
|
+
function Sn(e, t) {
|
|
1429
1926
|
let n = new Date(e.from).getTime(), r = new Date(e.to).getTime(), i = r - n, a = t === "prev" ? -i : i;
|
|
1430
1927
|
return {
|
|
1431
1928
|
preset: e.preset,
|
|
1432
|
-
from:
|
|
1433
|
-
to:
|
|
1929
|
+
from: _n(new Date(n + a)),
|
|
1930
|
+
to: _n(new Date(r + a))
|
|
1434
1931
|
};
|
|
1435
1932
|
}
|
|
1436
|
-
function
|
|
1437
|
-
if (e.preset) return
|
|
1933
|
+
function Cn(e, t) {
|
|
1934
|
+
if (e.preset) return bn.find((t) => t.value === e.preset)?.label ?? e.preset;
|
|
1438
1935
|
if (e.from && e.to) {
|
|
1439
1936
|
let n = (e) => new Date(e).toLocaleString("en-US", {
|
|
1440
1937
|
year: "numeric",
|
|
@@ -1451,7 +1948,7 @@ function an(e, t) {
|
|
|
1451
1948
|
}
|
|
1452
1949
|
//#endregion
|
|
1453
1950
|
//#region src/components/custom/date-time-range-picker.tsx
|
|
1454
|
-
function
|
|
1951
|
+
function wn({ value: e, max: t, onChange: r }) {
|
|
1455
1952
|
let [i, a] = n.useState(e);
|
|
1456
1953
|
n.useEffect(() => {
|
|
1457
1954
|
a(e);
|
|
@@ -1463,7 +1960,7 @@ function on({ value: e, max: t, onChange: r }) {
|
|
|
1463
1960
|
let n = Math.min(Math.max(parseInt(i || "0", 10) + e, 0), t), o = String(n).padStart(2, "0");
|
|
1464
1961
|
a(o), r(o);
|
|
1465
1962
|
};
|
|
1466
|
-
return /* @__PURE__ */
|
|
1963
|
+
return /* @__PURE__ */ Y("input", {
|
|
1467
1964
|
type: "number",
|
|
1468
1965
|
min: 0,
|
|
1469
1966
|
max: t,
|
|
@@ -1473,21 +1970,21 @@ function on({ value: e, max: t, onChange: r }) {
|
|
|
1473
1970
|
onKeyDown: (e) => {
|
|
1474
1971
|
e.key === "Enter" && o(e.target.value), e.key === "ArrowUp" && (e.preventDefault(), s(1)), e.key === "ArrowDown" && (e.preventDefault(), s(-1));
|
|
1475
1972
|
},
|
|
1476
|
-
className:
|
|
1973
|
+
className: Q("h-8 w-12 rounded-md border border-input bg-transparent text-center text-sm font-medium dark:bg-input/30", "focus:border-ring focus:ring-3 focus:ring-ring/50 focus:outline-none", "[appearance:textfield] [&::-webkit-inner-spin-button]:appearance-none [&::-webkit-outer-spin-button]:appearance-none")
|
|
1477
1974
|
});
|
|
1478
1975
|
}
|
|
1479
|
-
function
|
|
1480
|
-
let [c, l] = n.useState(!1), u = a || "UTC", d =
|
|
1976
|
+
function Tn({ isoValue: e, onChange: t, label: r, placeholder: i = "Select date & time", timezone: a, minDate: o, maxDate: s }) {
|
|
1977
|
+
let [c, l] = n.useState(!1), u = a || "UTC", d = vn(e, u), [f, p] = n.useState(d?.h ?? "00"), [h, g] = n.useState(d?.m ?? "00"), [_, v] = n.useState(d?.s ?? "00");
|
|
1481
1978
|
n.useEffect(() => {
|
|
1482
|
-
let t =
|
|
1483
|
-
|
|
1979
|
+
let t = vn(e, u);
|
|
1980
|
+
p(t?.h ?? "00"), g(t?.m ?? "00"), v(t?.s ?? "00");
|
|
1484
1981
|
}, [e, u]);
|
|
1485
|
-
let y = d ? new Date(d.year, d.month, d.day) : void 0, b = (e, n, r, i, a, o) => t(
|
|
1982
|
+
let y = d ? new Date(d.year, d.month, d.day) : void 0, b = (e, n, r, i, a, o) => t(yn(e, n, r, i, a, o, u)), x = (e) => {
|
|
1486
1983
|
e && b(e.getFullYear(), e.getMonth(), e.getDate(), f, h, _);
|
|
1487
|
-
},
|
|
1984
|
+
}, S = (e, t) => {
|
|
1488
1985
|
let n = e === "h" ? t : f, r = e === "m" ? t : h, i = e === "s" ? t : _;
|
|
1489
|
-
e === "h" &&
|
|
1490
|
-
},
|
|
1986
|
+
e === "h" && p(t), e === "m" && g(t), e === "s" && v(t), d && b(d.year, d.month, d.day, n, r, i);
|
|
1987
|
+
}, C = (e) => {
|
|
1491
1988
|
if (o) {
|
|
1492
1989
|
let t = new Date(o);
|
|
1493
1990
|
if (t.setHours(0, 0, 0, 0), e < t) return !0;
|
|
@@ -1497,7 +1994,7 @@ function sn({ isoValue: e, onChange: t, label: r, placeholder: i = "Select date
|
|
|
1497
1994
|
if (t.setHours(23, 59, 59, 999), e > t) return !0;
|
|
1498
1995
|
}
|
|
1499
1996
|
return !1;
|
|
1500
|
-
},
|
|
1997
|
+
}, w = d ? new Date(e).toLocaleString("en-US", {
|
|
1501
1998
|
year: "numeric",
|
|
1502
1999
|
month: "short",
|
|
1503
2000
|
day: "2-digit",
|
|
@@ -1507,62 +2004,62 @@ function sn({ isoValue: e, onChange: t, label: r, placeholder: i = "Select date
|
|
|
1507
2004
|
hour12: !1,
|
|
1508
2005
|
timeZone: u
|
|
1509
2006
|
}) : i;
|
|
1510
|
-
return /* @__PURE__ */
|
|
2007
|
+
return /* @__PURE__ */ X("div", {
|
|
1511
2008
|
className: "flex flex-col gap-1",
|
|
1512
|
-
children: [/* @__PURE__ */
|
|
2009
|
+
children: [/* @__PURE__ */ Y("label", {
|
|
1513
2010
|
className: "px-0.5 text-xs text-muted-foreground",
|
|
1514
2011
|
children: r
|
|
1515
|
-
}), /* @__PURE__ */
|
|
2012
|
+
}), /* @__PURE__ */ X(Jt, {
|
|
1516
2013
|
open: c,
|
|
1517
2014
|
onOpenChange: l,
|
|
1518
2015
|
modal: !1,
|
|
1519
|
-
children: [/* @__PURE__ */
|
|
2016
|
+
children: [/* @__PURE__ */ Y(Yt, {
|
|
1520
2017
|
asChild: !0,
|
|
1521
|
-
children: /* @__PURE__ */
|
|
2018
|
+
children: /* @__PURE__ */ X("button", {
|
|
1522
2019
|
type: "button",
|
|
1523
|
-
className:
|
|
1524
|
-
children: [/* @__PURE__ */
|
|
2020
|
+
className: Q("flex h-8 w-full items-center justify-between gap-2 rounded-md border border-input bg-transparent px-3 py-1 text-sm transition-colors outline-none dark:bg-input/30", "hover:bg-accent/50 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", c && "border-ring ring-3 ring-ring/50", !d && "text-muted-foreground"),
|
|
2021
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
1525
2022
|
className: "truncate",
|
|
1526
|
-
children:
|
|
1527
|
-
}), /* @__PURE__ */
|
|
2023
|
+
children: w
|
|
2024
|
+
}), /* @__PURE__ */ Y(m, { className: "size-3.5 shrink-0 opacity-60" })]
|
|
1528
2025
|
})
|
|
1529
|
-
}), /* @__PURE__ */
|
|
2026
|
+
}), /* @__PURE__ */ X(Xt, {
|
|
1530
2027
|
className: "w-auto p-0",
|
|
1531
2028
|
align: "start",
|
|
1532
2029
|
sideOffset: 4,
|
|
1533
|
-
children: [/* @__PURE__ */
|
|
2030
|
+
children: [/* @__PURE__ */ Y(hn, {
|
|
1534
2031
|
mode: "single",
|
|
1535
2032
|
selected: y,
|
|
1536
2033
|
onSelect: x,
|
|
1537
|
-
disabled:
|
|
2034
|
+
disabled: C,
|
|
1538
2035
|
defaultMonth: y,
|
|
1539
2036
|
autoFocus: !0
|
|
1540
|
-
}), /* @__PURE__ */
|
|
2037
|
+
}), /* @__PURE__ */ X("div", {
|
|
1541
2038
|
className: "flex items-center gap-2 border-t px-3 py-2.5",
|
|
1542
2039
|
children: [
|
|
1543
|
-
/* @__PURE__ */
|
|
1544
|
-
/* @__PURE__ */
|
|
2040
|
+
/* @__PURE__ */ Y(T, { className: "size-4 shrink-0 text-muted-foreground" }),
|
|
2041
|
+
/* @__PURE__ */ Y(wn, {
|
|
1545
2042
|
value: f,
|
|
1546
2043
|
max: 23,
|
|
1547
|
-
onChange: (e) =>
|
|
2044
|
+
onChange: (e) => S("h", e)
|
|
1548
2045
|
}),
|
|
1549
|
-
/* @__PURE__ */
|
|
2046
|
+
/* @__PURE__ */ Y("span", {
|
|
1550
2047
|
className: "text-sm font-medium text-muted-foreground",
|
|
1551
2048
|
children: ":"
|
|
1552
2049
|
}),
|
|
1553
|
-
/* @__PURE__ */
|
|
2050
|
+
/* @__PURE__ */ Y(wn, {
|
|
1554
2051
|
value: h,
|
|
1555
2052
|
max: 59,
|
|
1556
|
-
onChange: (e) =>
|
|
2053
|
+
onChange: (e) => S("m", e)
|
|
1557
2054
|
}),
|
|
1558
|
-
/* @__PURE__ */
|
|
2055
|
+
/* @__PURE__ */ Y("span", {
|
|
1559
2056
|
className: "text-sm font-medium text-muted-foreground",
|
|
1560
2057
|
children: ":"
|
|
1561
2058
|
}),
|
|
1562
|
-
/* @__PURE__ */
|
|
2059
|
+
/* @__PURE__ */ Y(wn, {
|
|
1563
2060
|
value: _,
|
|
1564
2061
|
max: 59,
|
|
1565
|
-
onChange: (e) =>
|
|
2062
|
+
onChange: (e) => S("s", e)
|
|
1566
2063
|
})
|
|
1567
2064
|
]
|
|
1568
2065
|
})]
|
|
@@ -1570,78 +2067,78 @@ function sn({ isoValue: e, onChange: t, label: r, placeholder: i = "Select date
|
|
|
1570
2067
|
})]
|
|
1571
2068
|
});
|
|
1572
2069
|
}
|
|
1573
|
-
var
|
|
1574
|
-
let c = a ??
|
|
2070
|
+
var En = n.forwardRef(function({ value: e, onChange: t, className: r, timezone: i, presets: a, maxRangeDays: o }, s) {
|
|
2071
|
+
let c = a ?? bn, [l, u] = n.useState(!1), [d, f] = n.useState(e.from), [p, h] = n.useState(e.to);
|
|
1575
2072
|
n.useEffect(() => {
|
|
1576
2073
|
f(e.from), h(e.to);
|
|
1577
2074
|
}, [e]);
|
|
1578
|
-
let
|
|
2075
|
+
let g = (e) => {
|
|
1579
2076
|
if (f(e), o && e) {
|
|
1580
2077
|
let t = new Date(new Date(e).getTime() + o * 864e5);
|
|
1581
|
-
new Date(
|
|
2078
|
+
new Date(p) > t && h(t.toISOString());
|
|
1582
2079
|
}
|
|
1583
2080
|
}, v = (e) => {
|
|
1584
2081
|
t({
|
|
1585
2082
|
preset: e,
|
|
1586
|
-
...
|
|
2083
|
+
...xn(e)
|
|
1587
2084
|
}), u(!1);
|
|
1588
2085
|
};
|
|
1589
|
-
return /* @__PURE__ */
|
|
2086
|
+
return /* @__PURE__ */ X(Jt, {
|
|
1590
2087
|
open: l,
|
|
1591
2088
|
onOpenChange: u,
|
|
1592
|
-
children: [/* @__PURE__ */
|
|
2089
|
+
children: [/* @__PURE__ */ Y(Yt, {
|
|
1593
2090
|
asChild: !0,
|
|
1594
|
-
children: /* @__PURE__ */
|
|
2091
|
+
children: /* @__PURE__ */ X("button", {
|
|
1595
2092
|
ref: s,
|
|
1596
2093
|
type: "button",
|
|
1597
|
-
className:
|
|
2094
|
+
className: Q("flex h-9 items-center justify-between gap-1.5 rounded-md border border-input bg-transparent px-3 py-1 text-sm transition-colors outline-none dark:bg-input/30", "hover:bg-accent/50 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50", l && "border-ring ring-3 ring-ring/50", r),
|
|
1598
2095
|
children: [
|
|
1599
|
-
/* @__PURE__ */
|
|
1600
|
-
/* @__PURE__ */
|
|
2096
|
+
/* @__PURE__ */ Y(m, { className: "size-3.5 shrink-0 opacity-60" }),
|
|
2097
|
+
/* @__PURE__ */ Y("span", {
|
|
1601
2098
|
className: "truncate",
|
|
1602
|
-
children:
|
|
2099
|
+
children: Cn(e, i)
|
|
1603
2100
|
}),
|
|
1604
|
-
/* @__PURE__ */
|
|
2101
|
+
/* @__PURE__ */ Y(_, { className: Q("size-3.5 shrink-0 opacity-60 transition-transform", l && "rotate-180") })
|
|
1605
2102
|
]
|
|
1606
2103
|
})
|
|
1607
|
-
}), /* @__PURE__ */
|
|
2104
|
+
}), /* @__PURE__ */ Y(Xt, {
|
|
1608
2105
|
align: "end",
|
|
1609
2106
|
sideOffset: 4,
|
|
1610
2107
|
className: "w-auto p-0",
|
|
1611
|
-
children: /* @__PURE__ */
|
|
2108
|
+
children: /* @__PURE__ */ X("div", {
|
|
1612
2109
|
className: "flex min-w-60 flex-col",
|
|
1613
|
-
children: [/* @__PURE__ */
|
|
2110
|
+
children: [/* @__PURE__ */ X("div", {
|
|
1614
2111
|
className: "border-b p-2",
|
|
1615
|
-
children: [/* @__PURE__ */
|
|
2112
|
+
children: [/* @__PURE__ */ Y("p", {
|
|
1616
2113
|
className: "mb-2 px-0.5 text-sm text-muted-foreground",
|
|
1617
2114
|
children: "Presets"
|
|
1618
|
-
}), /* @__PURE__ */
|
|
2115
|
+
}), /* @__PURE__ */ Y("div", {
|
|
1619
2116
|
className: "grid gap-1",
|
|
1620
2117
|
style: { gridTemplateColumns: `repeat(${c.length}, minmax(0, 1fr))` },
|
|
1621
|
-
children: c.map((t) => /* @__PURE__ */
|
|
2118
|
+
children: c.map((t) => /* @__PURE__ */ Y("button", {
|
|
1622
2119
|
type: "button",
|
|
1623
2120
|
onClick: () => v(t.value),
|
|
1624
|
-
className:
|
|
2121
|
+
className: Q("rounded-md px-2 py-1.5 text-center text-xs font-medium transition-colors", e.preset === t.value ? "bg-primary text-primary-foreground" : "bg-accent/50 text-foreground hover:bg-accent"),
|
|
1625
2122
|
children: t.label
|
|
1626
2123
|
}, t.value))
|
|
1627
2124
|
})]
|
|
1628
|
-
}), /* @__PURE__ */
|
|
2125
|
+
}), /* @__PURE__ */ X("div", {
|
|
1629
2126
|
className: "flex flex-col gap-3 p-2",
|
|
1630
2127
|
children: [
|
|
1631
|
-
/* @__PURE__ */
|
|
2128
|
+
/* @__PURE__ */ Y("p", {
|
|
1632
2129
|
className: "px-0.5 text-sm text-muted-foreground",
|
|
1633
2130
|
children: "Custom range"
|
|
1634
2131
|
}),
|
|
1635
|
-
/* @__PURE__ */
|
|
2132
|
+
/* @__PURE__ */ Y(Tn, {
|
|
1636
2133
|
isoValue: d,
|
|
1637
|
-
onChange:
|
|
2134
|
+
onChange: g,
|
|
1638
2135
|
label: "From",
|
|
1639
2136
|
placeholder: "Start date & time",
|
|
1640
2137
|
timezone: i,
|
|
1641
2138
|
maxDate: (/* @__PURE__ */ new Date()).toISOString()
|
|
1642
2139
|
}),
|
|
1643
|
-
/* @__PURE__ */
|
|
1644
|
-
isoValue:
|
|
2140
|
+
/* @__PURE__ */ Y(Tn, {
|
|
2141
|
+
isoValue: p,
|
|
1645
2142
|
onChange: h,
|
|
1646
2143
|
label: "To",
|
|
1647
2144
|
placeholder: "End date & time",
|
|
@@ -1656,16 +2153,16 @@ var cn = n.forwardRef(function({ value: e, onChange: t, className: r, timezone:
|
|
|
1656
2153
|
return e;
|
|
1657
2154
|
})()
|
|
1658
2155
|
}),
|
|
1659
|
-
/* @__PURE__ */
|
|
2156
|
+
/* @__PURE__ */ Y($, {
|
|
1660
2157
|
type: "button",
|
|
1661
2158
|
size: "sm",
|
|
1662
2159
|
className: "w-full",
|
|
1663
|
-
disabled: !d || !
|
|
2160
|
+
disabled: !d || !p,
|
|
1664
2161
|
onClick: () => {
|
|
1665
|
-
!d || !
|
|
2162
|
+
!d || !p || (t({
|
|
1666
2163
|
preset: null,
|
|
1667
|
-
from: d <=
|
|
1668
|
-
to: d <=
|
|
2164
|
+
from: d <= p ? d : p,
|
|
2165
|
+
to: d <= p ? p : d
|
|
1669
2166
|
}), u(!1));
|
|
1670
2167
|
},
|
|
1671
2168
|
children: "Apply"
|
|
@@ -1675,139 +2172,139 @@ var cn = n.forwardRef(function({ value: e, onChange: t, className: r, timezone:
|
|
|
1675
2172
|
})
|
|
1676
2173
|
})]
|
|
1677
2174
|
});
|
|
1678
|
-
}),
|
|
2175
|
+
}), Dn = H("group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-data-[slot=alert-action]:relative has-data-[slot=alert-action]:pr-18 has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4", {
|
|
1679
2176
|
variants: { variant: {
|
|
1680
2177
|
default: "bg-card text-card-foreground",
|
|
1681
2178
|
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
1682
2179
|
} },
|
|
1683
2180
|
defaultVariants: { variant: "default" }
|
|
1684
2181
|
});
|
|
1685
|
-
function
|
|
1686
|
-
return /* @__PURE__ */
|
|
2182
|
+
function On({ className: e, variant: t, ...n }) {
|
|
2183
|
+
return /* @__PURE__ */ Y("div", {
|
|
1687
2184
|
"data-slot": "alert",
|
|
1688
2185
|
role: "alert",
|
|
1689
|
-
className:
|
|
2186
|
+
className: Q(Dn({ variant: t }), e),
|
|
1690
2187
|
...n
|
|
1691
2188
|
});
|
|
1692
2189
|
}
|
|
1693
|
-
function
|
|
1694
|
-
return /* @__PURE__ */
|
|
2190
|
+
function kn({ className: e, ...t }) {
|
|
2191
|
+
return /* @__PURE__ */ Y("div", {
|
|
1695
2192
|
"data-slot": "alert-title",
|
|
1696
|
-
className:
|
|
2193
|
+
className: Q("font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground", e),
|
|
1697
2194
|
...t
|
|
1698
2195
|
});
|
|
1699
2196
|
}
|
|
1700
|
-
function
|
|
1701
|
-
return /* @__PURE__ */
|
|
2197
|
+
function An({ className: e, ...t }) {
|
|
2198
|
+
return /* @__PURE__ */ Y("div", {
|
|
1702
2199
|
"data-slot": "alert-description",
|
|
1703
|
-
className:
|
|
2200
|
+
className: Q("text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4", e),
|
|
1704
2201
|
...t
|
|
1705
2202
|
});
|
|
1706
2203
|
}
|
|
1707
|
-
function
|
|
1708
|
-
return /* @__PURE__ */
|
|
2204
|
+
function jn({ className: e, ...t }) {
|
|
2205
|
+
return /* @__PURE__ */ Y("div", {
|
|
1709
2206
|
"data-slot": "alert-action",
|
|
1710
|
-
className:
|
|
2207
|
+
className: Q("absolute top-2 right-2", e),
|
|
1711
2208
|
...t
|
|
1712
2209
|
});
|
|
1713
2210
|
}
|
|
1714
2211
|
//#endregion
|
|
1715
2212
|
//#region src/components/ui/alert-dialog.tsx
|
|
1716
|
-
function
|
|
1717
|
-
return /* @__PURE__ */
|
|
2213
|
+
function Mn({ ...e }) {
|
|
2214
|
+
return /* @__PURE__ */ Y(U.Root, {
|
|
1718
2215
|
"data-slot": "alert-dialog",
|
|
1719
2216
|
...e
|
|
1720
2217
|
});
|
|
1721
2218
|
}
|
|
1722
|
-
function
|
|
1723
|
-
return /* @__PURE__ */
|
|
2219
|
+
function Nn({ ...e }) {
|
|
2220
|
+
return /* @__PURE__ */ Y(U.Trigger, {
|
|
1724
2221
|
"data-slot": "alert-dialog-trigger",
|
|
1725
2222
|
...e
|
|
1726
2223
|
});
|
|
1727
2224
|
}
|
|
1728
|
-
function
|
|
1729
|
-
return /* @__PURE__ */
|
|
2225
|
+
function Pn({ ...e }) {
|
|
2226
|
+
return /* @__PURE__ */ Y(U.Portal, {
|
|
1730
2227
|
"data-slot": "alert-dialog-portal",
|
|
1731
2228
|
...e
|
|
1732
2229
|
});
|
|
1733
2230
|
}
|
|
1734
|
-
function
|
|
1735
|
-
return /* @__PURE__ */
|
|
2231
|
+
function Fn({ className: e, ...t }) {
|
|
2232
|
+
return /* @__PURE__ */ Y(U.Overlay, {
|
|
1736
2233
|
"data-slot": "alert-dialog-overlay",
|
|
1737
|
-
className:
|
|
2234
|
+
className: Q("fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", e),
|
|
1738
2235
|
...t
|
|
1739
2236
|
});
|
|
1740
2237
|
}
|
|
1741
|
-
function
|
|
1742
|
-
return /* @__PURE__ */
|
|
2238
|
+
function In({ className: e, size: t = "default", ...n }) {
|
|
2239
|
+
return /* @__PURE__ */ X(Pn, { children: [/* @__PURE__ */ Y(Fn, {}), /* @__PURE__ */ Y(U.Content, {
|
|
1743
2240
|
"data-slot": "alert-dialog-content",
|
|
1744
2241
|
"data-size": t,
|
|
1745
|
-
className:
|
|
2242
|
+
className: Q("group/alert-dialog-content fixed top-1/2 left-1/2 z-50 grid w-full -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
1746
2243
|
...n
|
|
1747
2244
|
})] });
|
|
1748
2245
|
}
|
|
1749
|
-
function
|
|
1750
|
-
return /* @__PURE__ */
|
|
2246
|
+
function Ln({ className: e, ...t }) {
|
|
2247
|
+
return /* @__PURE__ */ Y("div", {
|
|
1751
2248
|
"data-slot": "alert-dialog-header",
|
|
1752
|
-
className:
|
|
2249
|
+
className: Q("grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-left sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]", e),
|
|
1753
2250
|
...t
|
|
1754
2251
|
});
|
|
1755
2252
|
}
|
|
1756
|
-
function
|
|
1757
|
-
return /* @__PURE__ */
|
|
2253
|
+
function Rn({ className: e, ...t }) {
|
|
2254
|
+
return /* @__PURE__ */ Y("div", {
|
|
1758
2255
|
"data-slot": "alert-dialog-footer",
|
|
1759
|
-
className:
|
|
2256
|
+
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end", e),
|
|
1760
2257
|
...t
|
|
1761
2258
|
});
|
|
1762
2259
|
}
|
|
1763
|
-
function
|
|
1764
|
-
return /* @__PURE__ */
|
|
2260
|
+
function zn({ className: e, ...t }) {
|
|
2261
|
+
return /* @__PURE__ */ Y("div", {
|
|
1765
2262
|
"data-slot": "alert-dialog-media",
|
|
1766
|
-
className:
|
|
2263
|
+
className: Q("mb-2 inline-flex size-10 items-center justify-center rounded-md bg-muted sm:group-data-[size=default]/alert-dialog-content:row-span-2 *:[svg:not([class*='size-'])]:size-6", e),
|
|
1767
2264
|
...t
|
|
1768
2265
|
});
|
|
1769
2266
|
}
|
|
1770
|
-
function
|
|
1771
|
-
return /* @__PURE__ */
|
|
2267
|
+
function Bn({ className: e, ...t }) {
|
|
2268
|
+
return /* @__PURE__ */ Y(U.Title, {
|
|
1772
2269
|
"data-slot": "alert-dialog-title",
|
|
1773
|
-
className:
|
|
2270
|
+
className: Q("text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2", e),
|
|
1774
2271
|
...t
|
|
1775
2272
|
});
|
|
1776
2273
|
}
|
|
1777
|
-
function
|
|
1778
|
-
return /* @__PURE__ */
|
|
2274
|
+
function Vn({ className: e, ...t }) {
|
|
2275
|
+
return /* @__PURE__ */ Y(U.Description, {
|
|
1779
2276
|
"data-slot": "alert-dialog-description",
|
|
1780
|
-
className:
|
|
2277
|
+
className: Q("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", e),
|
|
1781
2278
|
...t
|
|
1782
2279
|
});
|
|
1783
2280
|
}
|
|
1784
|
-
function
|
|
1785
|
-
return /* @__PURE__ */
|
|
2281
|
+
function Hn({ className: e, variant: t = "default", size: n = "default", ...r }) {
|
|
2282
|
+
return /* @__PURE__ */ Y($, {
|
|
1786
2283
|
variant: t,
|
|
1787
2284
|
size: n,
|
|
1788
2285
|
asChild: !0,
|
|
1789
|
-
children: /* @__PURE__ */
|
|
2286
|
+
children: /* @__PURE__ */ Y(U.Action, {
|
|
1790
2287
|
"data-slot": "alert-dialog-action",
|
|
1791
|
-
className:
|
|
2288
|
+
className: Q(e),
|
|
1792
2289
|
...r
|
|
1793
2290
|
})
|
|
1794
2291
|
});
|
|
1795
2292
|
}
|
|
1796
|
-
function
|
|
1797
|
-
return /* @__PURE__ */
|
|
2293
|
+
function Un({ className: e, variant: t = "outline", size: n = "default", ...r }) {
|
|
2294
|
+
return /* @__PURE__ */ Y($, {
|
|
1798
2295
|
variant: t,
|
|
1799
2296
|
size: n,
|
|
1800
2297
|
asChild: !0,
|
|
1801
|
-
children: /* @__PURE__ */
|
|
2298
|
+
children: /* @__PURE__ */ Y(U.Cancel, {
|
|
1802
2299
|
"data-slot": "alert-dialog-cancel",
|
|
1803
|
-
className:
|
|
2300
|
+
className: Q(e),
|
|
1804
2301
|
...r
|
|
1805
2302
|
})
|
|
1806
2303
|
});
|
|
1807
2304
|
}
|
|
1808
2305
|
//#endregion
|
|
1809
2306
|
//#region src/components/ui/badge.tsx
|
|
1810
|
-
var
|
|
2307
|
+
var Wn = H("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-md border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!", {
|
|
1811
2308
|
variants: { variant: {
|
|
1812
2309
|
default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
|
|
1813
2310
|
secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
|
|
@@ -1828,134 +2325,134 @@ var En = P("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-cent
|
|
|
1828
2325
|
} },
|
|
1829
2326
|
defaultVariants: { variant: "default" }
|
|
1830
2327
|
});
|
|
1831
|
-
function
|
|
1832
|
-
return /* @__PURE__ */
|
|
2328
|
+
function Gn({ className: e, variant: t = "default", asChild: n = !1, ...r }) {
|
|
2329
|
+
return /* @__PURE__ */ Y(n ? J.Root : "span", {
|
|
1833
2330
|
"data-slot": "badge",
|
|
1834
2331
|
"data-variant": t,
|
|
1835
|
-
className:
|
|
2332
|
+
className: Q(Wn({ variant: t }), e),
|
|
1836
2333
|
...r
|
|
1837
2334
|
});
|
|
1838
2335
|
}
|
|
1839
2336
|
//#endregion
|
|
1840
2337
|
//#region src/components/ui/button-group.tsx
|
|
1841
|
-
var
|
|
2338
|
+
var Kn = H("group/button-group flex w-fit items-stretch *:focus-visible:relative *:focus-visible:z-10 has-[>[data-slot=button-group]]:gap-2 has-[select[aria-hidden=true]:last-child]:[&>[data-slot=select-trigger]:last-of-type]:rounded-r-lg [&>[data-slot=select-trigger]:not([class*='w-'])]:w-fit [&>input]:flex-1", {
|
|
1842
2339
|
variants: { orientation: {
|
|
1843
2340
|
horizontal: "[&>*:not(:first-child)]:rounded-l-none [&>*:not(:first-child)]:border-l-0 [&>*:not(:last-child)]:rounded-r-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-r-lg!",
|
|
1844
2341
|
vertical: "flex-col [&>*:not(:first-child)]:rounded-t-none [&>*:not(:first-child)]:border-t-0 [&>*:not(:last-child)]:rounded-b-none [&>[data-slot]:not(:has(~[data-slot]))]:rounded-b-lg!"
|
|
1845
2342
|
} },
|
|
1846
2343
|
defaultVariants: { orientation: "horizontal" }
|
|
1847
2344
|
});
|
|
1848
|
-
function
|
|
1849
|
-
return /* @__PURE__ */
|
|
2345
|
+
function qn({ className: e, orientation: t, ...n }) {
|
|
2346
|
+
return /* @__PURE__ */ Y("div", {
|
|
1850
2347
|
role: "group",
|
|
1851
2348
|
"data-slot": "button-group",
|
|
1852
2349
|
"data-orientation": t,
|
|
1853
|
-
className:
|
|
2350
|
+
className: Q(Kn({ orientation: t }), e),
|
|
1854
2351
|
...n
|
|
1855
2352
|
});
|
|
1856
2353
|
}
|
|
1857
|
-
function
|
|
1858
|
-
return /* @__PURE__ */
|
|
1859
|
-
className:
|
|
2354
|
+
function Jn({ className: e, asChild: t = !1, ...n }) {
|
|
2355
|
+
return /* @__PURE__ */ Y(t ? J.Root : "div", {
|
|
2356
|
+
className: Q("flex items-center gap-2 rounded-lg border bg-muted px-2.5 text-sm font-medium [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4", e),
|
|
1860
2357
|
...n
|
|
1861
2358
|
});
|
|
1862
2359
|
}
|
|
1863
|
-
function
|
|
1864
|
-
return /* @__PURE__ */
|
|
2360
|
+
function Yn({ className: e, orientation: t = "vertical", ...n }) {
|
|
2361
|
+
return /* @__PURE__ */ Y(tt, {
|
|
1865
2362
|
"data-slot": "button-group-separator",
|
|
1866
2363
|
orientation: t,
|
|
1867
|
-
className:
|
|
2364
|
+
className: Q("relative self-stretch bg-input data-horizontal:mx-px data-horizontal:w-auto data-vertical:my-px data-vertical:h-auto", e),
|
|
1868
2365
|
...n
|
|
1869
2366
|
});
|
|
1870
2367
|
}
|
|
1871
2368
|
//#endregion
|
|
1872
2369
|
//#region src/components/ui/card.tsx
|
|
1873
|
-
function
|
|
1874
|
-
return /* @__PURE__ */
|
|
2370
|
+
function Xn({ className: e, size: t = "default", ...n }) {
|
|
2371
|
+
return /* @__PURE__ */ Y("div", {
|
|
1875
2372
|
"data-slot": "card",
|
|
1876
2373
|
"data-size": t,
|
|
1877
|
-
className:
|
|
2374
|
+
className: Q("group/card flex flex-col gap-4 overflow-hidden rounded-xl bg-card py-4 text-sm text-card-foreground ring-1 ring-foreground/10 has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl", e),
|
|
1878
2375
|
...n
|
|
1879
2376
|
});
|
|
1880
2377
|
}
|
|
1881
|
-
function
|
|
1882
|
-
return /* @__PURE__ */
|
|
2378
|
+
function Zn({ className: e, ...t }) {
|
|
2379
|
+
return /* @__PURE__ */ Y("div", {
|
|
1883
2380
|
"data-slot": "card-header",
|
|
1884
|
-
className:
|
|
2381
|
+
className: Q("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3", e),
|
|
1885
2382
|
...t
|
|
1886
2383
|
});
|
|
1887
2384
|
}
|
|
1888
|
-
function
|
|
1889
|
-
return /* @__PURE__ */
|
|
2385
|
+
function Qn({ className: e, ...t }) {
|
|
2386
|
+
return /* @__PURE__ */ Y("div", {
|
|
1890
2387
|
"data-slot": "card-title",
|
|
1891
|
-
className:
|
|
2388
|
+
className: Q("text-base leading-snug font-medium group-data-[size=sm]/card:text-sm", e),
|
|
1892
2389
|
...t
|
|
1893
2390
|
});
|
|
1894
2391
|
}
|
|
1895
|
-
function
|
|
1896
|
-
return /* @__PURE__ */
|
|
2392
|
+
function $n({ className: e, ...t }) {
|
|
2393
|
+
return /* @__PURE__ */ Y("div", {
|
|
1897
2394
|
"data-slot": "card-description",
|
|
1898
|
-
className:
|
|
2395
|
+
className: Q("text-sm text-muted-foreground", e),
|
|
1899
2396
|
...t
|
|
1900
2397
|
});
|
|
1901
2398
|
}
|
|
1902
|
-
function
|
|
1903
|
-
return /* @__PURE__ */
|
|
2399
|
+
function er({ className: e, ...t }) {
|
|
2400
|
+
return /* @__PURE__ */ Y("div", {
|
|
1904
2401
|
"data-slot": "card-action",
|
|
1905
|
-
className:
|
|
2402
|
+
className: Q("col-start-2 row-span-2 row-start-1 self-start justify-self-end", e),
|
|
1906
2403
|
...t
|
|
1907
2404
|
});
|
|
1908
2405
|
}
|
|
1909
|
-
function
|
|
1910
|
-
return /* @__PURE__ */
|
|
2406
|
+
function tr({ className: e, ...t }) {
|
|
2407
|
+
return /* @__PURE__ */ Y("div", {
|
|
1911
2408
|
"data-slot": "card-content",
|
|
1912
|
-
className:
|
|
2409
|
+
className: Q("px-4 group-data-[size=sm]/card:px-3", e),
|
|
1913
2410
|
...t
|
|
1914
2411
|
});
|
|
1915
2412
|
}
|
|
1916
|
-
function
|
|
1917
|
-
return /* @__PURE__ */
|
|
2413
|
+
function nr({ className: e, ...t }) {
|
|
2414
|
+
return /* @__PURE__ */ Y("div", {
|
|
1918
2415
|
"data-slot": "card-footer",
|
|
1919
|
-
className:
|
|
2416
|
+
className: Q("flex items-center rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/card:p-3", e),
|
|
1920
2417
|
...t
|
|
1921
2418
|
});
|
|
1922
2419
|
}
|
|
1923
2420
|
//#endregion
|
|
1924
2421
|
//#region src/components/ui/chart.tsx
|
|
1925
|
-
var
|
|
2422
|
+
var rr = {
|
|
1926
2423
|
light: "",
|
|
1927
2424
|
dark: ".dark"
|
|
1928
|
-
},
|
|
2425
|
+
}, ir = {
|
|
1929
2426
|
width: 320,
|
|
1930
2427
|
height: 200
|
|
1931
|
-
},
|
|
1932
|
-
function
|
|
1933
|
-
let e = n.useContext(
|
|
2428
|
+
}, ar = n.createContext(null);
|
|
2429
|
+
function or() {
|
|
2430
|
+
let e = n.useContext(ar);
|
|
1934
2431
|
if (!e) throw Error("useChart must be used within a <ChartContainer />");
|
|
1935
2432
|
return e;
|
|
1936
2433
|
}
|
|
1937
|
-
function
|
|
2434
|
+
function sr({ id: e, className: t, children: r, config: i, initialDimension: a = ir, ...o }) {
|
|
1938
2435
|
let s = n.useId(), c = `chart-${e ?? s.replace(/:/g, "")}`;
|
|
1939
|
-
return /* @__PURE__ */
|
|
2436
|
+
return /* @__PURE__ */ Y(ar.Provider, {
|
|
1940
2437
|
value: { config: i },
|
|
1941
|
-
children: /* @__PURE__ */
|
|
2438
|
+
children: /* @__PURE__ */ X("div", {
|
|
1942
2439
|
"data-slot": "chart",
|
|
1943
2440
|
"data-chart": c,
|
|
1944
|
-
className:
|
|
2441
|
+
className: Q("flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector]:outline-hidden [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-surface]:outline-hidden", t),
|
|
1945
2442
|
...o,
|
|
1946
|
-
children: [/* @__PURE__ */
|
|
2443
|
+
children: [/* @__PURE__ */ Y(cr, {
|
|
1947
2444
|
id: c,
|
|
1948
2445
|
config: i
|
|
1949
|
-
}), /* @__PURE__ */
|
|
2446
|
+
}), /* @__PURE__ */ Y(De.ResponsiveContainer, {
|
|
1950
2447
|
initialDimension: a,
|
|
1951
2448
|
children: r
|
|
1952
2449
|
})]
|
|
1953
2450
|
})
|
|
1954
2451
|
});
|
|
1955
2452
|
}
|
|
1956
|
-
var
|
|
2453
|
+
var cr = ({ id: e, config: t }) => {
|
|
1957
2454
|
let n = Object.entries(t).filter(([, e]) => e.theme ?? e.color);
|
|
1958
|
-
return n.length ? /* @__PURE__ */
|
|
2455
|
+
return n.length ? /* @__PURE__ */ Y("style", { dangerouslySetInnerHTML: { __html: Object.entries(rr).map(([t, r]) => `
|
|
1959
2456
|
${r} [data-chart=${e}] {
|
|
1960
2457
|
${n.map(([e, n]) => {
|
|
1961
2458
|
let r = n.theme?.[t] ?? n.color;
|
|
@@ -1963,16 +2460,16 @@ ${n.map(([e, n]) => {
|
|
|
1963
2460
|
}).join("\n")}
|
|
1964
2461
|
}
|
|
1965
2462
|
`).join("\n") } }) : null;
|
|
1966
|
-
},
|
|
1967
|
-
function
|
|
1968
|
-
let { config: m } =
|
|
2463
|
+
}, lr = De.Tooltip;
|
|
2464
|
+
function ur({ active: e, payload: t, className: r, indicator: i = "dot", hideLabel: a = !1, hideIndicator: o = !1, label: s, labelFormatter: c, labelClassName: l, formatter: u, color: d, nameKey: f, labelKey: p }) {
|
|
2465
|
+
let { config: m } = or(), h = n.useMemo(() => {
|
|
1969
2466
|
if (a || !t?.length) return null;
|
|
1970
|
-
let [e] = t, n =
|
|
1971
|
-
return c ? /* @__PURE__ */
|
|
1972
|
-
className:
|
|
2467
|
+
let [e] = t, n = pr(m, e, `${p ?? e?.dataKey ?? e?.name ?? "value"}`), r = !p && typeof s == "string" ? m[s]?.label ?? s : n?.label;
|
|
2468
|
+
return c ? /* @__PURE__ */ Y("div", {
|
|
2469
|
+
className: Q("font-medium", l),
|
|
1973
2470
|
children: c(r, t)
|
|
1974
|
-
}) : r ? /* @__PURE__ */
|
|
1975
|
-
className:
|
|
2471
|
+
}) : r ? /* @__PURE__ */ Y("div", {
|
|
2472
|
+
className: Q("font-medium", l),
|
|
1976
2473
|
children: r
|
|
1977
2474
|
}) : null;
|
|
1978
2475
|
}, [
|
|
@@ -1986,16 +2483,16 @@ function Kn({ active: e, payload: t, className: r, indicator: i = "dot", hideLab
|
|
|
1986
2483
|
]);
|
|
1987
2484
|
if (!e || !t?.length) return null;
|
|
1988
2485
|
let g = t.length === 1 && i !== "dot";
|
|
1989
|
-
return /* @__PURE__ */
|
|
1990
|
-
className:
|
|
1991
|
-
children: [g ? null : h, /* @__PURE__ */
|
|
2486
|
+
return /* @__PURE__ */ X("div", {
|
|
2487
|
+
className: Q("grid min-w-32 items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl", r),
|
|
2488
|
+
children: [g ? null : h, /* @__PURE__ */ Y("div", {
|
|
1992
2489
|
className: "grid gap-1.5",
|
|
1993
2490
|
children: t.filter((e) => e.type !== "none").map((e, t) => {
|
|
1994
|
-
let n =
|
|
1995
|
-
return /* @__PURE__ */
|
|
1996
|
-
className:
|
|
1997
|
-
children: u && e?.value !== void 0 && e.name ? u(e.value, e.name, e, t, e.payload) : /* @__PURE__ */
|
|
1998
|
-
className:
|
|
2491
|
+
let n = pr(m, e, `${f ?? e.name ?? e.dataKey ?? "value"}`), r = d ?? e.payload?.fill ?? e.color;
|
|
2492
|
+
return /* @__PURE__ */ Y("div", {
|
|
2493
|
+
className: Q("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground", i === "dot" && "items-center"),
|
|
2494
|
+
children: u && e?.value !== void 0 && e.name ? u(e.value, e.name, e, t, e.payload) : /* @__PURE__ */ X(we, { children: [n?.icon ? /* @__PURE__ */ Y(n.icon, {}) : !o && /* @__PURE__ */ Y("div", {
|
|
2495
|
+
className: Q("shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)", {
|
|
1999
2496
|
"h-2.5 w-2.5": i === "dot",
|
|
2000
2497
|
"w-1": i === "line",
|
|
2001
2498
|
"w-0 border-[1.5px] border-dashed bg-transparent": i === "dashed",
|
|
@@ -2005,15 +2502,15 @@ function Kn({ active: e, payload: t, className: r, indicator: i = "dot", hideLab
|
|
|
2005
2502
|
"--color-bg": r,
|
|
2006
2503
|
"--color-border": r
|
|
2007
2504
|
}
|
|
2008
|
-
}), /* @__PURE__ */
|
|
2009
|
-
className:
|
|
2010
|
-
children: [/* @__PURE__ */
|
|
2505
|
+
}), /* @__PURE__ */ X("div", {
|
|
2506
|
+
className: Q("flex flex-1 justify-between leading-none", g ? "items-end" : "items-center"),
|
|
2507
|
+
children: [/* @__PURE__ */ X("div", {
|
|
2011
2508
|
className: "grid gap-1.5",
|
|
2012
|
-
children: [g ? h : null, /* @__PURE__ */
|
|
2509
|
+
children: [g ? h : null, /* @__PURE__ */ Y("span", {
|
|
2013
2510
|
className: "text-muted-foreground",
|
|
2014
2511
|
children: n?.label ?? e.name
|
|
2015
2512
|
})]
|
|
2016
|
-
}), e.value != null && /* @__PURE__ */
|
|
2513
|
+
}), e.value != null && /* @__PURE__ */ Y("span", {
|
|
2017
2514
|
className: "font-mono font-medium text-foreground tabular-nums",
|
|
2018
2515
|
children: typeof e.value == "number" ? e.value.toLocaleString() : String(e.value)
|
|
2019
2516
|
})]
|
|
@@ -2023,16 +2520,16 @@ function Kn({ active: e, payload: t, className: r, indicator: i = "dot", hideLab
|
|
|
2023
2520
|
})]
|
|
2024
2521
|
});
|
|
2025
2522
|
}
|
|
2026
|
-
var
|
|
2027
|
-
function
|
|
2028
|
-
let { config: a } =
|
|
2029
|
-
return n?.length ? /* @__PURE__ */
|
|
2030
|
-
className:
|
|
2523
|
+
var dr = De.Legend;
|
|
2524
|
+
function fr({ className: e, hideIcon: t = !1, payload: n, verticalAlign: r = "bottom", nameKey: i }) {
|
|
2525
|
+
let { config: a } = or();
|
|
2526
|
+
return n?.length ? /* @__PURE__ */ Y("div", {
|
|
2527
|
+
className: Q("flex items-center justify-center gap-4", r === "top" ? "pb-3" : "pt-3", e),
|
|
2031
2528
|
children: n.filter((e) => e.type !== "none").map((e, n) => {
|
|
2032
|
-
let r =
|
|
2033
|
-
return /* @__PURE__ */
|
|
2034
|
-
className:
|
|
2035
|
-
children: [r?.icon && !t ? /* @__PURE__ */
|
|
2529
|
+
let r = pr(a, e, `${i ?? e.dataKey ?? "value"}`);
|
|
2530
|
+
return /* @__PURE__ */ X("div", {
|
|
2531
|
+
className: Q("flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground"),
|
|
2532
|
+
children: [r?.icon && !t ? /* @__PURE__ */ Y(r.icon, {}) : /* @__PURE__ */ Y("div", {
|
|
2036
2533
|
className: "h-2 w-2 shrink-0 rounded-[2px]",
|
|
2037
2534
|
style: { backgroundColor: e.color }
|
|
2038
2535
|
}), r?.label]
|
|
@@ -2040,56 +2537,56 @@ function Jn({ className: e, hideIcon: t = !1, payload: n, verticalAlign: r = "bo
|
|
|
2040
2537
|
})
|
|
2041
2538
|
}) : null;
|
|
2042
2539
|
}
|
|
2043
|
-
function
|
|
2540
|
+
function pr(e, t, n) {
|
|
2044
2541
|
if (typeof t != "object" || !t) return;
|
|
2045
2542
|
let r = "payload" in t && typeof t.payload == "object" && t.payload !== null ? t.payload : void 0, i = n;
|
|
2046
2543
|
return n in t && typeof t[n] == "string" ? i = t[n] : r && n in r && typeof r[n] == "string" && (i = r[n]), i in e ? e[i] : e[n];
|
|
2047
2544
|
}
|
|
2048
2545
|
//#endregion
|
|
2049
2546
|
//#region src/components/ui/hover-card.tsx
|
|
2050
|
-
function
|
|
2051
|
-
return /* @__PURE__ */
|
|
2547
|
+
function mr({ ...e }) {
|
|
2548
|
+
return /* @__PURE__ */ Y(fe.Root, {
|
|
2052
2549
|
"data-slot": "hover-card",
|
|
2053
2550
|
...e
|
|
2054
2551
|
});
|
|
2055
2552
|
}
|
|
2056
|
-
function
|
|
2057
|
-
return /* @__PURE__ */
|
|
2553
|
+
function hr({ ...e }) {
|
|
2554
|
+
return /* @__PURE__ */ Y(fe.Trigger, {
|
|
2058
2555
|
"data-slot": "hover-card-trigger",
|
|
2059
2556
|
...e
|
|
2060
2557
|
});
|
|
2061
2558
|
}
|
|
2062
|
-
function
|
|
2063
|
-
return /* @__PURE__ */
|
|
2559
|
+
function gr({ className: e, align: t = "center", sideOffset: n = 4, ...r }) {
|
|
2560
|
+
return /* @__PURE__ */ Y(fe.Portal, {
|
|
2064
2561
|
"data-slot": "hover-card-portal",
|
|
2065
|
-
children: /* @__PURE__ */
|
|
2562
|
+
children: /* @__PURE__ */ Y(fe.Content, {
|
|
2066
2563
|
"data-slot": "hover-card-content",
|
|
2067
2564
|
align: t,
|
|
2068
2565
|
sideOffset: n,
|
|
2069
|
-
className:
|
|
2566
|
+
className: Q("z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
2070
2567
|
...r
|
|
2071
2568
|
})
|
|
2072
2569
|
});
|
|
2073
2570
|
}
|
|
2074
2571
|
//#endregion
|
|
2075
2572
|
//#region src/components/ui/item.tsx
|
|
2076
|
-
function
|
|
2077
|
-
return /* @__PURE__ */
|
|
2573
|
+
function _r({ className: e, ...t }) {
|
|
2574
|
+
return /* @__PURE__ */ Y("div", {
|
|
2078
2575
|
role: "list",
|
|
2079
2576
|
"data-slot": "item-group",
|
|
2080
|
-
className:
|
|
2577
|
+
className: Q("group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2", e),
|
|
2081
2578
|
...t
|
|
2082
2579
|
});
|
|
2083
2580
|
}
|
|
2084
|
-
function
|
|
2085
|
-
return /* @__PURE__ */
|
|
2581
|
+
function vr({ className: e, ...t }) {
|
|
2582
|
+
return /* @__PURE__ */ Y(tt, {
|
|
2086
2583
|
"data-slot": "item-separator",
|
|
2087
2584
|
orientation: "horizontal",
|
|
2088
|
-
className:
|
|
2585
|
+
className: Q("my-2", e),
|
|
2089
2586
|
...t
|
|
2090
2587
|
});
|
|
2091
2588
|
}
|
|
2092
|
-
var
|
|
2589
|
+
var yr = H("group/item flex w-full flex-wrap items-center rounded-lg border text-sm transition-colors duration-100 outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 [a]:transition-colors [a]:hover:bg-muted", {
|
|
2093
2590
|
variants: {
|
|
2094
2591
|
variant: {
|
|
2095
2592
|
default: "border-transparent",
|
|
@@ -2107,12 +2604,12 @@ var tr = P("group/item flex w-full flex-wrap items-center rounded-lg border text
|
|
|
2107
2604
|
size: "default"
|
|
2108
2605
|
}
|
|
2109
2606
|
});
|
|
2110
|
-
function
|
|
2111
|
-
return /* @__PURE__ */
|
|
2607
|
+
function br({ className: e, variant: t = "default", size: n = "default", asChild: r = !1, ...i }) {
|
|
2608
|
+
return /* @__PURE__ */ Y(r ? J.Root : "div", {
|
|
2112
2609
|
"data-slot": "item",
|
|
2113
2610
|
"data-variant": t,
|
|
2114
2611
|
"data-size": n,
|
|
2115
|
-
className:
|
|
2612
|
+
className: Q(yr({
|
|
2116
2613
|
variant: t,
|
|
2117
2614
|
size: n,
|
|
2118
2615
|
className: e
|
|
@@ -2120,7 +2617,7 @@ function nr({ className: e, variant: t = "default", size: n = "default", asChild
|
|
|
2120
2617
|
...i
|
|
2121
2618
|
});
|
|
2122
2619
|
}
|
|
2123
|
-
var
|
|
2620
|
+
var xr = H("flex shrink-0 items-center justify-center gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start [&_svg]:pointer-events-none", {
|
|
2124
2621
|
variants: { variant: {
|
|
2125
2622
|
default: "bg-transparent",
|
|
2126
2623
|
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
@@ -2128,65 +2625,65 @@ var rr = P("flex shrink-0 items-center justify-center gap-2 group-has-data-[slot
|
|
|
2128
2625
|
} },
|
|
2129
2626
|
defaultVariants: { variant: "default" }
|
|
2130
2627
|
});
|
|
2131
|
-
function
|
|
2132
|
-
return /* @__PURE__ */
|
|
2628
|
+
function Sr({ className: e, variant: t = "default", ...n }) {
|
|
2629
|
+
return /* @__PURE__ */ Y("div", {
|
|
2133
2630
|
"data-slot": "item-media",
|
|
2134
2631
|
"data-variant": t,
|
|
2135
|
-
className:
|
|
2632
|
+
className: Q(xr({
|
|
2136
2633
|
variant: t,
|
|
2137
2634
|
className: e
|
|
2138
2635
|
})),
|
|
2139
2636
|
...n
|
|
2140
2637
|
});
|
|
2141
2638
|
}
|
|
2142
|
-
function
|
|
2143
|
-
return /* @__PURE__ */
|
|
2639
|
+
function Cr({ className: e, ...t }) {
|
|
2640
|
+
return /* @__PURE__ */ Y("div", {
|
|
2144
2641
|
"data-slot": "item-content",
|
|
2145
|
-
className:
|
|
2642
|
+
className: Q("flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none", e),
|
|
2146
2643
|
...t
|
|
2147
2644
|
});
|
|
2148
2645
|
}
|
|
2149
|
-
function
|
|
2150
|
-
return /* @__PURE__ */
|
|
2646
|
+
function wr({ className: e, ...t }) {
|
|
2647
|
+
return /* @__PURE__ */ Y("div", {
|
|
2151
2648
|
"data-slot": "item-title",
|
|
2152
|
-
className:
|
|
2649
|
+
className: Q("line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4", e),
|
|
2153
2650
|
...t
|
|
2154
2651
|
});
|
|
2155
2652
|
}
|
|
2156
|
-
function
|
|
2157
|
-
return /* @__PURE__ */
|
|
2653
|
+
function Tr({ className: e, ...t }) {
|
|
2654
|
+
return /* @__PURE__ */ Y("p", {
|
|
2158
2655
|
"data-slot": "item-description",
|
|
2159
|
-
className:
|
|
2656
|
+
className: Q("line-clamp-2 text-left text-sm leading-normal font-normal text-muted-foreground group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4 [&>a:hover]:text-primary", e),
|
|
2160
2657
|
...t
|
|
2161
2658
|
});
|
|
2162
2659
|
}
|
|
2163
|
-
function
|
|
2164
|
-
return /* @__PURE__ */
|
|
2660
|
+
function Er({ className: e, ...t }) {
|
|
2661
|
+
return /* @__PURE__ */ Y("div", {
|
|
2165
2662
|
"data-slot": "item-actions",
|
|
2166
|
-
className:
|
|
2663
|
+
className: Q("flex items-center gap-2", e),
|
|
2167
2664
|
...t
|
|
2168
2665
|
});
|
|
2169
2666
|
}
|
|
2170
|
-
function
|
|
2171
|
-
return /* @__PURE__ */
|
|
2667
|
+
function Dr({ className: e, ...t }) {
|
|
2668
|
+
return /* @__PURE__ */ Y("div", {
|
|
2172
2669
|
"data-slot": "item-header",
|
|
2173
|
-
className:
|
|
2670
|
+
className: Q("flex basis-full items-center justify-between gap-2", e),
|
|
2174
2671
|
...t
|
|
2175
2672
|
});
|
|
2176
2673
|
}
|
|
2177
|
-
function
|
|
2178
|
-
return /* @__PURE__ */
|
|
2674
|
+
function Or({ className: e, ...t }) {
|
|
2675
|
+
return /* @__PURE__ */ Y("div", {
|
|
2179
2676
|
"data-slot": "item-footer",
|
|
2180
|
-
className:
|
|
2677
|
+
className: Q("flex basis-full items-center justify-between gap-2", e),
|
|
2181
2678
|
...t
|
|
2182
2679
|
});
|
|
2183
2680
|
}
|
|
2184
2681
|
//#endregion
|
|
2185
2682
|
//#region src/components/ui/map.tsx
|
|
2186
|
-
var
|
|
2683
|
+
var kr = {
|
|
2187
2684
|
dark: "https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json",
|
|
2188
2685
|
light: "https://basemaps.cartocdn.com/gl/positron-gl-style/style.json"
|
|
2189
|
-
},
|
|
2686
|
+
}, Ar = [
|
|
2190
2687
|
{
|
|
2191
2688
|
label: "Light",
|
|
2192
2689
|
url: "https://basemaps.cartocdn.com/gl/positron-gl-style/style.json"
|
|
@@ -2199,26 +2696,26 @@ var dr = {
|
|
|
2199
2696
|
label: "Dark",
|
|
2200
2697
|
url: "https://basemaps.cartocdn.com/gl/dark-matter-gl-style/style.json"
|
|
2201
2698
|
}
|
|
2202
|
-
],
|
|
2203
|
-
function
|
|
2204
|
-
let e = o(
|
|
2699
|
+
], jr = r(null);
|
|
2700
|
+
function Mr() {
|
|
2701
|
+
let e = o(jr);
|
|
2205
2702
|
if (!e) throw Error("useMap must be used within a Map component");
|
|
2206
2703
|
return e;
|
|
2207
2704
|
}
|
|
2208
|
-
function
|
|
2209
|
-
return /* @__PURE__ */
|
|
2705
|
+
function Nr() {
|
|
2706
|
+
return /* @__PURE__ */ Y("div", {
|
|
2210
2707
|
className: "bg-background/50 absolute inset-0 z-10 flex items-center justify-center backdrop-blur-xs",
|
|
2211
|
-
children: /* @__PURE__ */
|
|
2708
|
+
children: /* @__PURE__ */ X("div", {
|
|
2212
2709
|
className: "flex gap-1",
|
|
2213
2710
|
children: [
|
|
2214
|
-
/* @__PURE__ */
|
|
2215
|
-
/* @__PURE__ */
|
|
2216
|
-
/* @__PURE__ */
|
|
2711
|
+
/* @__PURE__ */ Y("span", { className: "bg-muted-foreground/60 size-1.5 animate-pulse rounded-full" }),
|
|
2712
|
+
/* @__PURE__ */ Y("span", { className: "bg-muted-foreground/60 size-1.5 animate-pulse rounded-full [animation-delay:150ms]" }),
|
|
2713
|
+
/* @__PURE__ */ Y("span", { className: "bg-muted-foreground/60 size-1.5 animate-pulse rounded-full [animation-delay:300ms]" })
|
|
2217
2714
|
]
|
|
2218
2715
|
})
|
|
2219
2716
|
});
|
|
2220
2717
|
}
|
|
2221
|
-
function
|
|
2718
|
+
function Pr(e) {
|
|
2222
2719
|
let t = e.getCenter();
|
|
2223
2720
|
return {
|
|
2224
2721
|
center: [t.lng, t.lat],
|
|
@@ -2227,12 +2724,12 @@ function hr(e) {
|
|
|
2227
2724
|
pitch: e.getPitch()
|
|
2228
2725
|
};
|
|
2229
2726
|
}
|
|
2230
|
-
var
|
|
2231
|
-
let v = h === !1 ? [] : h, y = d(null), [b, x] = f(null), [S, C] = f(!1), [w, T] = f(!1), [E, ee] = f(0), D = d(null), O = d(null), k = d(!1),
|
|
2232
|
-
|
|
2727
|
+
var Fr = i(function({ children: e, className: t, theme: n, styles: r, projection: i, viewport: o, onViewportChange: c, loading: p = !1, controls: m = !0, tiles: h = Ar, ...g }, _) {
|
|
2728
|
+
let v = h === !1 ? [] : h, y = d(null), [b, x] = f(null), [S, C] = f(!1), [w, T] = f(!1), [E, ee] = f(0), D = d(null), O = d(null), k = d(!1), te = o !== void 0 && c !== void 0, A = d(c);
|
|
2729
|
+
A.current = c;
|
|
2233
2730
|
let j = u(() => ({
|
|
2234
|
-
dark: r?.dark ??
|
|
2235
|
-
light: r?.light ??
|
|
2731
|
+
dark: r?.dark ?? kr.dark,
|
|
2732
|
+
light: r?.light ?? kr.light
|
|
2236
2733
|
}), [r]);
|
|
2237
2734
|
l(_, () => b, [b]);
|
|
2238
2735
|
let M = a(() => {
|
|
@@ -2242,7 +2739,7 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2242
2739
|
if (!y.current) return;
|
|
2243
2740
|
let e = v[0]?.url ?? j.light;
|
|
2244
2741
|
D.current = e;
|
|
2245
|
-
let t = new
|
|
2742
|
+
let t = new Oe.Map({
|
|
2246
2743
|
container: y.current,
|
|
2247
2744
|
style: e,
|
|
2248
2745
|
renderWorldCopies: !1,
|
|
@@ -2254,14 +2751,14 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2254
2751
|
T(!0), i && t.setProjection(i);
|
|
2255
2752
|
}, 100);
|
|
2256
2753
|
}, r = () => C(!0), a = () => {
|
|
2257
|
-
k.current ||
|
|
2754
|
+
k.current || A.current?.(Pr(t));
|
|
2258
2755
|
};
|
|
2259
2756
|
return t.on("load", r), t.on("styledata", n), t.on("move", a), x(t), () => {
|
|
2260
2757
|
M(), t.off("load", r), t.off("styledata", n), t.off("move", a), t.remove(), C(!1), T(!1), x(null);
|
|
2261
2758
|
};
|
|
2262
2759
|
}, []), s(() => {
|
|
2263
|
-
if (!b || !
|
|
2264
|
-
let e =
|
|
2760
|
+
if (!b || !te || !o || b.isMoving()) return;
|
|
2761
|
+
let e = Pr(b), t = {
|
|
2265
2762
|
center: o.center ?? e.center,
|
|
2266
2763
|
zoom: o.zoom ?? e.zoom,
|
|
2267
2764
|
bearing: o.bearing ?? e.bearing,
|
|
@@ -2270,7 +2767,7 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2270
2767
|
t.center[0] === e.center[0] && t.center[1] === e.center[1] && t.zoom === e.zoom && t.bearing === e.bearing && t.pitch === e.pitch || (k.current = !0, b.jumpTo(t), k.current = !1);
|
|
2271
2768
|
}, [
|
|
2272
2769
|
b,
|
|
2273
|
-
|
|
2770
|
+
te,
|
|
2274
2771
|
o
|
|
2275
2772
|
]), s(() => {
|
|
2276
2773
|
if (!b) return;
|
|
@@ -2283,7 +2780,7 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2283
2780
|
j,
|
|
2284
2781
|
M
|
|
2285
2782
|
]);
|
|
2286
|
-
let
|
|
2783
|
+
let N = u(() => ({
|
|
2287
2784
|
map: b,
|
|
2288
2785
|
isLoaded: S && w
|
|
2289
2786
|
}), [
|
|
@@ -2291,12 +2788,12 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2291
2788
|
S,
|
|
2292
2789
|
w
|
|
2293
2790
|
]);
|
|
2294
|
-
return /* @__PURE__ */
|
|
2295
|
-
value:
|
|
2296
|
-
children: /* @__PURE__ */
|
|
2791
|
+
return /* @__PURE__ */ Y(jr.Provider, {
|
|
2792
|
+
value: N,
|
|
2793
|
+
children: /* @__PURE__ */ X("div", {
|
|
2297
2794
|
ref: y,
|
|
2298
|
-
className:
|
|
2299
|
-
children: [(!S || p) && /* @__PURE__ */
|
|
2795
|
+
className: Q("relative h-full w-full", t),
|
|
2796
|
+
children: [(!S || p) && /* @__PURE__ */ Y(Nr, {}), b && /* @__PURE__ */ X(we, { children: [m && /* @__PURE__ */ Y(Yr, {
|
|
2300
2797
|
position: "top-right",
|
|
2301
2798
|
tiles: v,
|
|
2302
2799
|
tileIndex: E,
|
|
@@ -2304,14 +2801,14 @@ var gr = i(function({ children: e, className: t, theme: n, styles: r, projection
|
|
|
2304
2801
|
}), e] })]
|
|
2305
2802
|
})
|
|
2306
2803
|
});
|
|
2307
|
-
}),
|
|
2308
|
-
function
|
|
2309
|
-
let e = o(
|
|
2804
|
+
}), Ir = r(null);
|
|
2805
|
+
function Lr() {
|
|
2806
|
+
let e = o(Ir);
|
|
2310
2807
|
if (!e) throw Error("Marker components must be used within MapMarker");
|
|
2311
2808
|
return e;
|
|
2312
2809
|
}
|
|
2313
|
-
function
|
|
2314
|
-
let { map: m } =
|
|
2810
|
+
function Rr({ longitude: e, latitude: t, children: n, onClick: r, onMouseEnter: i, onMouseLeave: a, onDragStart: o, onDrag: c, onDragEnd: l, draggable: f = !1, ...p }) {
|
|
2811
|
+
let { map: m } = Mr(), h = d({
|
|
2315
2812
|
onClick: r,
|
|
2316
2813
|
onMouseEnter: i,
|
|
2317
2814
|
onMouseLeave: a,
|
|
@@ -2328,7 +2825,7 @@ function yr({ longitude: e, latitude: t, children: n, onClick: r, onMouseEnter:
|
|
|
2328
2825
|
onDragEnd: l
|
|
2329
2826
|
};
|
|
2330
2827
|
let g = u(() => {
|
|
2331
|
-
let n = new
|
|
2828
|
+
let n = new Oe.Marker({
|
|
2332
2829
|
...p,
|
|
2333
2830
|
element: document.createElement("div"),
|
|
2334
2831
|
draggable: f
|
|
@@ -2359,7 +2856,7 @@ function yr({ longitude: e, latitude: t, children: n, onClick: r, onMouseEnter:
|
|
|
2359
2856
|
};
|
|
2360
2857
|
}, [m]), (g.getLngLat().lng !== e || g.getLngLat().lat !== t) && g.setLngLat([e, t]), g.isDraggable() !== f && g.setDraggable(f);
|
|
2361
2858
|
let _ = g.getOffset(), v = p.offset ?? [0, 0], [y, b] = Array.isArray(v) ? v : [v.x, v.y];
|
|
2362
|
-
return (_.x !== y || _.y !== b) && g.setOffset(v), g.getRotation() !== p.rotation && g.setRotation(p.rotation ?? 0), g.getRotationAlignment() !== p.rotationAlignment && g.setRotationAlignment(p.rotationAlignment ?? "auto"), g.getPitchAlignment() !== p.pitchAlignment && g.setPitchAlignment(p.pitchAlignment ?? "auto"), /* @__PURE__ */
|
|
2859
|
+
return (_.x !== y || _.y !== b) && g.setOffset(v), g.getRotation() !== p.rotation && g.setRotation(p.rotation ?? 0), g.getRotationAlignment() !== p.rotationAlignment && g.setRotationAlignment(p.rotationAlignment ?? "auto"), g.getPitchAlignment() !== p.pitchAlignment && g.setPitchAlignment(p.pitchAlignment ?? "auto"), /* @__PURE__ */ Y(Ir.Provider, {
|
|
2363
2860
|
value: {
|
|
2364
2861
|
marker: g,
|
|
2365
2862
|
map: m
|
|
@@ -2367,27 +2864,27 @@ function yr({ longitude: e, latitude: t, children: n, onClick: r, onMouseEnter:
|
|
|
2367
2864
|
children: n
|
|
2368
2865
|
});
|
|
2369
2866
|
}
|
|
2370
|
-
function
|
|
2371
|
-
let { marker: n } =
|
|
2372
|
-
return
|
|
2373
|
-
className:
|
|
2374
|
-
children: e || /* @__PURE__ */
|
|
2867
|
+
function zr({ children: e, className: t }) {
|
|
2868
|
+
let { marker: n } = Lr();
|
|
2869
|
+
return ke(/* @__PURE__ */ Y("div", {
|
|
2870
|
+
className: Q("relative cursor-pointer", t),
|
|
2871
|
+
children: e || /* @__PURE__ */ Y(Br, {})
|
|
2375
2872
|
}), n.getElement());
|
|
2376
2873
|
}
|
|
2377
|
-
function
|
|
2378
|
-
return /* @__PURE__ */
|
|
2874
|
+
function Br() {
|
|
2875
|
+
return /* @__PURE__ */ Y("div", { className: "relative h-4 w-4 rounded-full border-2 border-white bg-blue-500 shadow-lg" });
|
|
2379
2876
|
}
|
|
2380
|
-
function
|
|
2381
|
-
return /* @__PURE__ */
|
|
2877
|
+
function Vr({ onClick: e }) {
|
|
2878
|
+
return /* @__PURE__ */ Y("button", {
|
|
2382
2879
|
type: "button",
|
|
2383
2880
|
onClick: e,
|
|
2384
2881
|
"aria-label": "Close popup",
|
|
2385
2882
|
className: "focus-visible:ring-ring hover:bg-muted text-foreground absolute top-0.5 right-0.5 z-10 inline-flex size-5 cursor-pointer items-center justify-center rounded-sm transition-colors focus:outline-none focus-visible:ring-2",
|
|
2386
|
-
children: /* @__PURE__ */
|
|
2883
|
+
children: /* @__PURE__ */ Y(ue, { className: "size-3.5" })
|
|
2387
2884
|
});
|
|
2388
2885
|
}
|
|
2389
|
-
function
|
|
2390
|
-
let { marker: i, map: a } =
|
|
2886
|
+
function Hr({ children: e, className: t, closeButton: n = !1, ...r }) {
|
|
2887
|
+
let { marker: i, map: a } = Lr(), o = u(() => document.createElement("div"), []), c = d(r), l = u(() => new Oe.Popup({
|
|
2391
2888
|
offset: 16,
|
|
2392
2889
|
...r,
|
|
2393
2890
|
closeButton: !1
|
|
@@ -2400,13 +2897,13 @@ function Cr({ children: e, className: t, closeButton: n = !1, ...r }) {
|
|
|
2400
2897
|
let e = c.current;
|
|
2401
2898
|
e.offset !== r.offset && l.setOffset(r.offset ?? 16), e.maxWidth !== r.maxWidth && r.maxWidth && l.setMaxWidth(r.maxWidth ?? "none"), c.current = r;
|
|
2402
2899
|
}
|
|
2403
|
-
return
|
|
2404
|
-
className:
|
|
2405
|
-
children: [n && /* @__PURE__ */
|
|
2900
|
+
return ke(/* @__PURE__ */ X("div", {
|
|
2901
|
+
className: Q("bg-popover text-popover-foreground relative max-w-62 rounded-md border p-3 shadow-md", "animate-in fade-in-0 zoom-in-95 duration-200 ease-out", t),
|
|
2902
|
+
children: [n && /* @__PURE__ */ Y(Vr, { onClick: () => l.remove() }), e]
|
|
2406
2903
|
}), o);
|
|
2407
2904
|
}
|
|
2408
|
-
function
|
|
2409
|
-
let { marker: r, map: i } =
|
|
2905
|
+
function Ur({ children: e, className: t, ...n }) {
|
|
2906
|
+
let { marker: r, map: i } = Lr(), a = u(() => document.createElement("div"), []), o = d(n), c = u(() => new Oe.Popup({
|
|
2410
2907
|
offset: 16,
|
|
2411
2908
|
...n,
|
|
2412
2909
|
closeOnClick: !0,
|
|
@@ -2425,43 +2922,43 @@ function wr({ children: e, className: t, ...n }) {
|
|
|
2425
2922
|
let e = o.current;
|
|
2426
2923
|
e.offset !== n.offset && c.setOffset(n.offset ?? 16), e.maxWidth !== n.maxWidth && n.maxWidth && c.setMaxWidth(n.maxWidth ?? "none"), o.current = n;
|
|
2427
2924
|
}
|
|
2428
|
-
return
|
|
2429
|
-
className:
|
|
2925
|
+
return ke(/* @__PURE__ */ Y("div", {
|
|
2926
|
+
className: Q("bg-foreground text-background pointer-events-none rounded-md px-2 py-1 text-xs text-balance shadow-md", "animate-in fade-in-0 zoom-in-95 duration-200 ease-out", t),
|
|
2430
2927
|
children: e
|
|
2431
2928
|
}), a);
|
|
2432
2929
|
}
|
|
2433
|
-
function
|
|
2434
|
-
return /* @__PURE__ */
|
|
2435
|
-
className:
|
|
2930
|
+
function Wr({ children: e, className: t, position: n = "top" }) {
|
|
2931
|
+
return /* @__PURE__ */ Y("div", {
|
|
2932
|
+
className: Q("absolute left-1/2 -translate-x-1/2 whitespace-nowrap", "text-foreground text-[10px] font-medium", {
|
|
2436
2933
|
top: "bottom-full mb-1",
|
|
2437
2934
|
bottom: "top-full mt-1"
|
|
2438
2935
|
}[n], t),
|
|
2439
2936
|
children: e
|
|
2440
2937
|
});
|
|
2441
2938
|
}
|
|
2442
|
-
var
|
|
2939
|
+
var Gr = {
|
|
2443
2940
|
"top-left": "top-2 left-2",
|
|
2444
2941
|
"top-right": "top-2 right-2",
|
|
2445
2942
|
"bottom-left": "bottom-2 left-2",
|
|
2446
2943
|
"bottom-right": "bottom-10 right-2"
|
|
2447
2944
|
};
|
|
2448
|
-
function
|
|
2449
|
-
return /* @__PURE__ */
|
|
2945
|
+
function Kr({ children: e }) {
|
|
2946
|
+
return /* @__PURE__ */ Y("div", {
|
|
2450
2947
|
className: "border-border bg-background [&>button:not(:last-child)]:border-border flex flex-col overflow-hidden rounded-md border shadow-sm [&>button:not(:last-child)]:border-b",
|
|
2451
2948
|
children: e
|
|
2452
2949
|
});
|
|
2453
2950
|
}
|
|
2454
|
-
function
|
|
2455
|
-
return /* @__PURE__ */
|
|
2951
|
+
function qr({ onClick: e, label: t, children: n, disabled: r = !1 }) {
|
|
2952
|
+
return /* @__PURE__ */ Y("button", {
|
|
2456
2953
|
onClick: e,
|
|
2457
2954
|
"aria-label": t,
|
|
2458
2955
|
type: "button",
|
|
2459
|
-
className:
|
|
2956
|
+
className: Q("flex size-8 items-center justify-center transition-all", "first:rounded-t-md last:rounded-b-md", "hover:bg-accent dark:hover:bg-accent/40", "focus-visible:ring-ring focus-visible:ring-2 focus-visible:outline-none focus-visible:ring-inset", "disabled:pointer-events-none disabled:opacity-50"),
|
|
2460
2957
|
disabled: r,
|
|
2461
2958
|
children: n
|
|
2462
2959
|
});
|
|
2463
2960
|
}
|
|
2464
|
-
function
|
|
2961
|
+
function Jr({ tiles: e, tileIndex: t, onTileChange: n, openLeft: r }) {
|
|
2465
2962
|
let [i, a] = f(!1), o = d(null);
|
|
2466
2963
|
return s(() => {
|
|
2467
2964
|
if (!i) return;
|
|
@@ -2473,32 +2970,32 @@ function kr({ tiles: e, tileIndex: t, onTileChange: n, openLeft: r }) {
|
|
|
2473
2970
|
return document.addEventListener("pointerdown", e), document.addEventListener("keydown", t), () => {
|
|
2474
2971
|
document.removeEventListener("pointerdown", e), document.removeEventListener("keydown", t);
|
|
2475
2972
|
};
|
|
2476
|
-
}, [i]), /* @__PURE__ */
|
|
2973
|
+
}, [i]), /* @__PURE__ */ X("div", {
|
|
2477
2974
|
ref: o,
|
|
2478
2975
|
className: "relative",
|
|
2479
|
-
children: [/* @__PURE__ */
|
|
2976
|
+
children: [/* @__PURE__ */ Y(Kr, { children: /* @__PURE__ */ Y(qr, {
|
|
2480
2977
|
onClick: () => a((e) => !e),
|
|
2481
2978
|
label: `Basemap: ${e[t]?.label ?? ""}`,
|
|
2482
|
-
children: /* @__PURE__ */
|
|
2483
|
-
}) }), i && /* @__PURE__ */
|
|
2979
|
+
children: /* @__PURE__ */ Y(P, { className: "size-4" })
|
|
2980
|
+
}) }), i && /* @__PURE__ */ Y("div", {
|
|
2484
2981
|
role: "listbox",
|
|
2485
2982
|
"aria-label": "Basemap",
|
|
2486
|
-
className:
|
|
2487
|
-
children: e.map((e, r) => /* @__PURE__ */
|
|
2983
|
+
className: Q("border-border bg-background absolute top-0 z-20 min-w-32 overflow-hidden rounded-md border p-1 shadow-md", r ? "right-9" : "left-9"),
|
|
2984
|
+
children: e.map((e, r) => /* @__PURE__ */ X("button", {
|
|
2488
2985
|
type: "button",
|
|
2489
2986
|
role: "option",
|
|
2490
2987
|
"aria-selected": r === t,
|
|
2491
2988
|
onClick: () => {
|
|
2492
2989
|
n?.(r), a(!1);
|
|
2493
2990
|
},
|
|
2494
|
-
className:
|
|
2495
|
-
children: [e.label, r === t && /* @__PURE__ */
|
|
2991
|
+
className: Q("flex w-full items-center justify-between gap-3 rounded-sm px-2 py-1.5 text-left text-xs font-medium transition-colors", r === t ? "bg-accent text-accent-foreground" : "hover:bg-accent/50"),
|
|
2992
|
+
children: [e.label, r === t && /* @__PURE__ */ Y(h, { className: "size-3.5 shrink-0" })]
|
|
2496
2993
|
}, e.label))
|
|
2497
2994
|
})]
|
|
2498
2995
|
});
|
|
2499
2996
|
}
|
|
2500
|
-
function
|
|
2501
|
-
let { map: d } =
|
|
2997
|
+
function Yr({ position: e = "bottom-right", showZoom: t = !0, showCompass: n = !1, showLocate: r = !1, showFullscreen: i = !1, className: o, onLocate: s, tiles: c = [], tileIndex: l = 0, onTileChange: u }) {
|
|
2998
|
+
let { map: d } = Mr(), [p, m] = f(!1), h = a(() => {
|
|
2502
2999
|
d?.zoomTo(d.getZoom() + 1, { duration: 300 });
|
|
2503
3000
|
}, [d]), g = a(() => {
|
|
2504
3001
|
d?.zoomTo(d.getZoom() - 1, { duration: 300 });
|
|
@@ -2522,41 +3019,41 @@ function Ar({ position: e = "bottom-right", showZoom: t = !0, showCompass: n = !
|
|
|
2522
3019
|
let e = d?.getContainer();
|
|
2523
3020
|
e && (document.fullscreenElement ? document.exitFullscreen() : e.requestFullscreen());
|
|
2524
3021
|
}, [d]);
|
|
2525
|
-
return /* @__PURE__ */
|
|
2526
|
-
className:
|
|
3022
|
+
return /* @__PURE__ */ X("div", {
|
|
3023
|
+
className: Q("absolute z-10 flex flex-col gap-1.5", Gr[e], o),
|
|
2527
3024
|
children: [
|
|
2528
|
-
t && /* @__PURE__ */
|
|
3025
|
+
t && /* @__PURE__ */ X(Kr, { children: [/* @__PURE__ */ Y(qr, {
|
|
2529
3026
|
onClick: h,
|
|
2530
3027
|
label: "Zoom in",
|
|
2531
|
-
children: /* @__PURE__ */
|
|
2532
|
-
}), /* @__PURE__ */
|
|
3028
|
+
children: /* @__PURE__ */ Y(ae, { className: "size-4" })
|
|
3029
|
+
}), /* @__PURE__ */ Y(qr, {
|
|
2533
3030
|
onClick: g,
|
|
2534
3031
|
label: "Zoom out",
|
|
2535
|
-
children: /* @__PURE__ */
|
|
3032
|
+
children: /* @__PURE__ */ Y(ie, { className: "size-4" })
|
|
2536
3033
|
})] }),
|
|
2537
|
-
c.length > 1 && /* @__PURE__ */
|
|
3034
|
+
c.length > 1 && /* @__PURE__ */ Y(Jr, {
|
|
2538
3035
|
tiles: c,
|
|
2539
3036
|
tileIndex: l,
|
|
2540
3037
|
onTileChange: u,
|
|
2541
3038
|
openLeft: e.endsWith("right")
|
|
2542
3039
|
}),
|
|
2543
|
-
n && /* @__PURE__ */
|
|
2544
|
-
r && /* @__PURE__ */
|
|
3040
|
+
n && /* @__PURE__ */ Y(Kr, { children: /* @__PURE__ */ Y(Xr, { onClick: _ }) }),
|
|
3041
|
+
r && /* @__PURE__ */ Y(Kr, { children: /* @__PURE__ */ Y(qr, {
|
|
2545
3042
|
onClick: v,
|
|
2546
3043
|
label: "Find my location",
|
|
2547
3044
|
disabled: p,
|
|
2548
|
-
children: p ? /* @__PURE__ */
|
|
3045
|
+
children: p ? /* @__PURE__ */ Y(F, { className: "size-4 animate-spin" }) : /* @__PURE__ */ Y(re, { className: "size-4" })
|
|
2549
3046
|
}) }),
|
|
2550
|
-
i && /* @__PURE__ */
|
|
3047
|
+
i && /* @__PURE__ */ Y(Kr, { children: /* @__PURE__ */ Y(qr, {
|
|
2551
3048
|
onClick: y,
|
|
2552
3049
|
label: "Toggle fullscreen",
|
|
2553
|
-
children: /* @__PURE__ */
|
|
3050
|
+
children: /* @__PURE__ */ Y(L, { className: "size-4" })
|
|
2554
3051
|
}) })
|
|
2555
3052
|
]
|
|
2556
3053
|
});
|
|
2557
3054
|
}
|
|
2558
|
-
function
|
|
2559
|
-
let { map: t } =
|
|
3055
|
+
function Xr({ onClick: e }) {
|
|
3056
|
+
let { map: t } = Mr(), n = d(null);
|
|
2560
3057
|
return s(() => {
|
|
2561
3058
|
if (!t || !n.current) return;
|
|
2562
3059
|
let e = n.current, r = () => {
|
|
@@ -2566,28 +3063,28 @@ function jr({ onClick: e }) {
|
|
|
2566
3063
|
return t.on("rotate", r), t.on("pitch", r), r(), () => {
|
|
2567
3064
|
t.off("rotate", r), t.off("pitch", r);
|
|
2568
3065
|
};
|
|
2569
|
-
}, [t]), /* @__PURE__ */
|
|
3066
|
+
}, [t]), /* @__PURE__ */ Y(qr, {
|
|
2570
3067
|
onClick: e,
|
|
2571
3068
|
label: "Reset bearing to north",
|
|
2572
|
-
children: /* @__PURE__ */
|
|
3069
|
+
children: /* @__PURE__ */ X("svg", {
|
|
2573
3070
|
ref: n,
|
|
2574
3071
|
viewBox: "0 0 24 24",
|
|
2575
3072
|
className: "size-5 transition-transform duration-200",
|
|
2576
3073
|
style: { transformStyle: "preserve-3d" },
|
|
2577
3074
|
children: [
|
|
2578
|
-
/* @__PURE__ */
|
|
3075
|
+
/* @__PURE__ */ Y("path", {
|
|
2579
3076
|
d: "M12 2L16 12H12V2Z",
|
|
2580
3077
|
className: "fill-red-500"
|
|
2581
3078
|
}),
|
|
2582
|
-
/* @__PURE__ */
|
|
3079
|
+
/* @__PURE__ */ Y("path", {
|
|
2583
3080
|
d: "M12 2L8 12H12V2Z",
|
|
2584
3081
|
className: "fill-red-300"
|
|
2585
3082
|
}),
|
|
2586
|
-
/* @__PURE__ */
|
|
3083
|
+
/* @__PURE__ */ Y("path", {
|
|
2587
3084
|
d: "M12 22L16 12H12V22Z",
|
|
2588
3085
|
className: "fill-muted-foreground/60"
|
|
2589
3086
|
}),
|
|
2590
|
-
/* @__PURE__ */
|
|
3087
|
+
/* @__PURE__ */ Y("path", {
|
|
2591
3088
|
d: "M12 22L8 12H12V22Z",
|
|
2592
3089
|
className: "fill-muted-foreground/30"
|
|
2593
3090
|
})
|
|
@@ -2595,10 +3092,10 @@ function jr({ onClick: e }) {
|
|
|
2595
3092
|
})
|
|
2596
3093
|
});
|
|
2597
3094
|
}
|
|
2598
|
-
function
|
|
2599
|
-
let { map: c } =
|
|
3095
|
+
function Zr({ longitude: e, latitude: t, onClose: n, children: r, className: i, closeButton: a = !1, ...o }) {
|
|
3096
|
+
let { map: c } = Mr(), l = d(o), f = d(n);
|
|
2600
3097
|
f.current = n;
|
|
2601
|
-
let p = u(() => document.createElement("div"), []), m = u(() => new
|
|
3098
|
+
let p = u(() => document.createElement("div"), []), m = u(() => new Oe.Popup({
|
|
2602
3099
|
offset: 16,
|
|
2603
3100
|
...o,
|
|
2604
3101
|
closeButton: !1
|
|
@@ -2613,15 +3110,15 @@ function Mr({ longitude: e, latitude: t, onClose: n, children: r, className: i,
|
|
|
2613
3110
|
let n = l.current;
|
|
2614
3111
|
(m.getLngLat().lng !== e || m.getLngLat().lat !== t) && m.setLngLat([e, t]), n.offset !== o.offset && m.setOffset(o.offset ?? 16), n.maxWidth !== o.maxWidth && o.maxWidth && m.setMaxWidth(o.maxWidth ?? "none"), l.current = o;
|
|
2615
3112
|
}
|
|
2616
|
-
return
|
|
2617
|
-
className:
|
|
2618
|
-
children: [a && /* @__PURE__ */
|
|
3113
|
+
return ke(/* @__PURE__ */ X("div", {
|
|
3114
|
+
className: Q("bg-popover text-popover-foreground relative max-w-62 rounded-md border p-3 shadow-md", "animate-in fade-in-0 zoom-in-95 duration-200 ease-out", i),
|
|
3115
|
+
children: [a && /* @__PURE__ */ Y(Vr, { onClick: () => {
|
|
2619
3116
|
m.remove();
|
|
2620
3117
|
} }), r]
|
|
2621
3118
|
}), p);
|
|
2622
3119
|
}
|
|
2623
|
-
function
|
|
2624
|
-
let { map: f, isLoaded: p } =
|
|
3120
|
+
function Qr({ id: e, coordinates: t, color: n = "#4285F4", width: r = 3, opacity: i = .8, dashArray: a, onClick: o, onMouseEnter: l, onMouseLeave: u, interactive: d = !0 }) {
|
|
3121
|
+
let { map: f, isLoaded: p } = Mr(), m = c(), h = e ?? m, g = `route-source-${h}`, _ = `route-layer-${h}`;
|
|
2625
3122
|
return s(() => {
|
|
2626
3123
|
if (!(!p || !f)) return f.addSource(g, {
|
|
2627
3124
|
type: "geojson",
|
|
@@ -2700,15 +3197,15 @@ function Nr({ id: e, coordinates: t, color: n = "#4285F4", width: r = 3, opacity
|
|
|
2700
3197
|
d
|
|
2701
3198
|
]), null;
|
|
2702
3199
|
}
|
|
2703
|
-
var
|
|
3200
|
+
var $r = .2, ei = 64, ti = 12, ni = 6, ri = {
|
|
2704
3201
|
"line-color": "#4285F4",
|
|
2705
3202
|
"line-width": 2,
|
|
2706
3203
|
"line-opacity": .85
|
|
2707
|
-
},
|
|
3204
|
+
}, ii = {
|
|
2708
3205
|
"line-join": "round",
|
|
2709
3206
|
"line-cap": "round"
|
|
2710
3207
|
};
|
|
2711
|
-
function
|
|
3208
|
+
function ai(e, t) {
|
|
2712
3209
|
if (!t) return e;
|
|
2713
3210
|
let n = { ...e };
|
|
2714
3211
|
for (let [e, r] of Object.entries(t)) {
|
|
@@ -2727,7 +3224,7 @@ function Br(e, t) {
|
|
|
2727
3224
|
}
|
|
2728
3225
|
return n;
|
|
2729
3226
|
}
|
|
2730
|
-
function
|
|
3227
|
+
function oi(e, t, n, r) {
|
|
2731
3228
|
let [i, a] = e, [o, s] = t, c = o - i, l = s - a, u = Math.hypot(c, l);
|
|
2732
3229
|
if (u === 0 || n === 0) return [e, t];
|
|
2733
3230
|
let d = (i + o) / 2, f = (a + s) / 2, p = -l / u, m = c / u, h = u * n, g = d + p * h, _ = f + m * h, v = [], y = Math.max(2, Math.floor(r));
|
|
@@ -2737,16 +3234,16 @@ function Vr(e, t, n, r) {
|
|
|
2737
3234
|
}
|
|
2738
3235
|
return v;
|
|
2739
3236
|
}
|
|
2740
|
-
function
|
|
2741
|
-
let { map: h, isLoaded: g } =
|
|
2742
|
-
...
|
|
3237
|
+
function si({ data: e, id: t, curvature: n = $r, samples: r = ei, paint: i, layout: a, hoverPaint: o, onClick: l, onHover: f, interactive: p = !0, beforeId: m }) {
|
|
3238
|
+
let { map: h, isLoaded: g } = Mr(), _ = c(), v = t ?? _, y = `arc-source-${v}`, b = `arc-layer-${v}`, x = `arc-hit-layer-${v}`, S = u(() => ai({
|
|
3239
|
+
...ri,
|
|
2743
3240
|
...i
|
|
2744
3241
|
}, o), [i, o]), C = u(() => ({
|
|
2745
|
-
...
|
|
3242
|
+
...ii,
|
|
2746
3243
|
...a
|
|
2747
3244
|
}), [a]), w = u(() => {
|
|
2748
|
-
let e = i?.["line-width"] ??
|
|
2749
|
-
return Math.max((typeof e == "number" ? e :
|
|
3245
|
+
let e = i?.["line-width"] ?? ri["line-width"];
|
|
3246
|
+
return Math.max((typeof e == "number" ? e : ti) + ni, ti);
|
|
2750
3247
|
}, [i]), T = u(() => ({
|
|
2751
3248
|
type: "FeatureCollection",
|
|
2752
3249
|
features: e.map((e) => {
|
|
@@ -2756,7 +3253,7 @@ function Hr({ data: e, id: t, curvature: n = Pr, samples: r = Fr, paint: i, layo
|
|
|
2756
3253
|
properties: a,
|
|
2757
3254
|
geometry: {
|
|
2758
3255
|
type: "LineString",
|
|
2759
|
-
coordinates:
|
|
3256
|
+
coordinates: oi(t, i, n, r)
|
|
2760
3257
|
}
|
|
2761
3258
|
};
|
|
2762
3259
|
})
|
|
@@ -2782,7 +3279,7 @@ function Hr({ data: e, id: t, curvature: n = Pr, samples: r = Fr, paint: i, layo
|
|
|
2782
3279
|
id: x,
|
|
2783
3280
|
type: "line",
|
|
2784
3281
|
source: y,
|
|
2785
|
-
layout:
|
|
3282
|
+
layout: ii,
|
|
2786
3283
|
paint: {
|
|
2787
3284
|
"line-color": "rgba(0, 0, 0, 0)",
|
|
2788
3285
|
"line-width": w,
|
|
@@ -2865,12 +3362,12 @@ function Hr({ data: e, id: t, curvature: n = Pr, samples: r = Fr, paint: i, layo
|
|
|
2865
3362
|
p
|
|
2866
3363
|
]), null;
|
|
2867
3364
|
}
|
|
2868
|
-
function
|
|
3365
|
+
function ci({ data: e, clusterMaxZoom: t = 14, clusterRadius: n = 50, clusterColors: r = [
|
|
2869
3366
|
"#22c55e",
|
|
2870
3367
|
"#eab308",
|
|
2871
3368
|
"#ef4444"
|
|
2872
3369
|
], clusterThresholds: i = [100, 750], pointColor: a = "#3b82f6", onPointClick: o, onClusterClick: l }) {
|
|
2873
|
-
let { map: u, isLoaded: f } =
|
|
3370
|
+
let { map: u, isLoaded: f } = Mr(), p = c(), m = `cluster-source-${p}`, h = `clusters-${p}`, g = `cluster-count-${p}`, _ = `unclustered-point-${p}`, v = d({
|
|
2874
3371
|
clusterColors: r,
|
|
2875
3372
|
clusterThresholds: i,
|
|
2876
3373
|
pointColor: a
|
|
@@ -3025,12 +3522,12 @@ function Ur({ data: e, clusterMaxZoom: t = 14, clusterRadius: n = 50, clusterCol
|
|
|
3025
3522
|
}
|
|
3026
3523
|
//#endregion
|
|
3027
3524
|
//#region src/components/ui/progress.tsx
|
|
3028
|
-
function
|
|
3029
|
-
return /* @__PURE__ */
|
|
3525
|
+
function li({ className: e, value: t, ...n }) {
|
|
3526
|
+
return /* @__PURE__ */ Y(he.Root, {
|
|
3030
3527
|
"data-slot": "progress",
|
|
3031
|
-
className:
|
|
3528
|
+
className: Q("relative flex h-1 w-full items-center overflow-x-hidden rounded-full bg-muted", e),
|
|
3032
3529
|
...n,
|
|
3033
|
-
children: /* @__PURE__ */
|
|
3530
|
+
children: /* @__PURE__ */ Y(he.Indicator, {
|
|
3034
3531
|
"data-slot": "progress-indicator",
|
|
3035
3532
|
className: "size-full flex-1 bg-primary transition-all",
|
|
3036
3533
|
style: { transform: `translateX(-${100 - (t || 0)}%)` }
|
|
@@ -3039,165 +3536,165 @@ function Wr({ className: e, value: t, ...n }) {
|
|
|
3039
3536
|
}
|
|
3040
3537
|
//#endregion
|
|
3041
3538
|
//#region src/components/ui/radio-group.tsx
|
|
3042
|
-
function
|
|
3043
|
-
return /* @__PURE__ */
|
|
3539
|
+
function ui({ className: e, ...t }) {
|
|
3540
|
+
return /* @__PURE__ */ Y(ge.Root, {
|
|
3044
3541
|
"data-slot": "radio-group",
|
|
3045
|
-
className:
|
|
3542
|
+
className: Q("grid w-full gap-2", e),
|
|
3046
3543
|
...t
|
|
3047
3544
|
});
|
|
3048
3545
|
}
|
|
3049
|
-
function
|
|
3050
|
-
return /* @__PURE__ */
|
|
3546
|
+
function di({ className: e, ...t }) {
|
|
3547
|
+
return /* @__PURE__ */ Y(ge.Item, {
|
|
3051
3548
|
"data-slot": "radio-group-item",
|
|
3052
|
-
className:
|
|
3549
|
+
className: Q("group/radio-group-item peer relative flex aspect-square size-4 shrink-0 rounded-full border border-input outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary", e),
|
|
3053
3550
|
...t,
|
|
3054
|
-
children: /* @__PURE__ */
|
|
3551
|
+
children: /* @__PURE__ */ Y(ge.Indicator, {
|
|
3055
3552
|
"data-slot": "radio-group-indicator",
|
|
3056
3553
|
className: "flex size-4 items-center justify-center",
|
|
3057
|
-
children: /* @__PURE__ */
|
|
3554
|
+
children: /* @__PURE__ */ Y("span", { className: "absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2 rounded-full bg-primary-foreground" })
|
|
3058
3555
|
})
|
|
3059
3556
|
});
|
|
3060
3557
|
}
|
|
3061
3558
|
//#endregion
|
|
3062
3559
|
//#region src/components/ui/select.tsx
|
|
3063
|
-
function
|
|
3064
|
-
return /* @__PURE__ */
|
|
3560
|
+
function fi({ ...e }) {
|
|
3561
|
+
return /* @__PURE__ */ Y(q.Root, {
|
|
3065
3562
|
"data-slot": "select",
|
|
3066
3563
|
...e
|
|
3067
3564
|
});
|
|
3068
3565
|
}
|
|
3069
|
-
function
|
|
3070
|
-
return /* @__PURE__ */
|
|
3566
|
+
function pi({ className: e, ...t }) {
|
|
3567
|
+
return /* @__PURE__ */ Y(q.Group, {
|
|
3071
3568
|
"data-slot": "select-group",
|
|
3072
|
-
className:
|
|
3569
|
+
className: Q("scroll-my-1 p-1", e),
|
|
3073
3570
|
...t
|
|
3074
3571
|
});
|
|
3075
3572
|
}
|
|
3076
|
-
function
|
|
3077
|
-
return /* @__PURE__ */
|
|
3573
|
+
function mi({ ...e }) {
|
|
3574
|
+
return /* @__PURE__ */ Y(q.Value, {
|
|
3078
3575
|
"data-slot": "select-value",
|
|
3079
3576
|
...e
|
|
3080
3577
|
});
|
|
3081
3578
|
}
|
|
3082
|
-
function
|
|
3083
|
-
return /* @__PURE__ */
|
|
3579
|
+
function hi({ className: e, size: t = "default", children: n, ...r }) {
|
|
3580
|
+
return /* @__PURE__ */ X(q.Trigger, {
|
|
3084
3581
|
"data-slot": "select-trigger",
|
|
3085
3582
|
"data-size": t,
|
|
3086
|
-
className:
|
|
3583
|
+
className: Q("flex w-fit items-center justify-between gap-1.5 rounded-lg border border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", e),
|
|
3087
3584
|
...r,
|
|
3088
|
-
children: [n, /* @__PURE__ */
|
|
3585
|
+
children: [n, /* @__PURE__ */ Y(q.Icon, {
|
|
3089
3586
|
asChild: !0,
|
|
3090
|
-
children: /* @__PURE__ */
|
|
3587
|
+
children: /* @__PURE__ */ Y(v, { className: "pointer-events-none size-4 text-muted-foreground" })
|
|
3091
3588
|
})]
|
|
3092
3589
|
});
|
|
3093
3590
|
}
|
|
3094
|
-
function
|
|
3095
|
-
return /* @__PURE__ */
|
|
3591
|
+
function gi({ className: e, children: t, position: n = "item-aligned", align: r = "center", ...i }) {
|
|
3592
|
+
return /* @__PURE__ */ Y(q.Portal, { children: /* @__PURE__ */ X(q.Content, {
|
|
3096
3593
|
"data-slot": "select-content",
|
|
3097
3594
|
"data-align-trigger": n === "item-aligned",
|
|
3098
|
-
className:
|
|
3595
|
+
className: Q("relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", n === "popper" && "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1", e),
|
|
3099
3596
|
position: n,
|
|
3100
3597
|
align: r,
|
|
3101
3598
|
...i,
|
|
3102
3599
|
children: [
|
|
3103
|
-
/* @__PURE__ */
|
|
3104
|
-
/* @__PURE__ */
|
|
3600
|
+
/* @__PURE__ */ Y(bi, {}),
|
|
3601
|
+
/* @__PURE__ */ Y(q.Viewport, {
|
|
3105
3602
|
"data-position": n,
|
|
3106
|
-
className:
|
|
3603
|
+
className: Q("data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)", n === "popper" && ""),
|
|
3107
3604
|
children: t
|
|
3108
3605
|
}),
|
|
3109
|
-
/* @__PURE__ */
|
|
3606
|
+
/* @__PURE__ */ Y(xi, {})
|
|
3110
3607
|
]
|
|
3111
3608
|
}) });
|
|
3112
3609
|
}
|
|
3113
|
-
function
|
|
3114
|
-
return /* @__PURE__ */
|
|
3610
|
+
function _i({ className: e, ...t }) {
|
|
3611
|
+
return /* @__PURE__ */ Y(q.Label, {
|
|
3115
3612
|
"data-slot": "select-label",
|
|
3116
|
-
className:
|
|
3613
|
+
className: Q("px-1.5 py-1 text-xs text-muted-foreground", e),
|
|
3117
3614
|
...t
|
|
3118
3615
|
});
|
|
3119
3616
|
}
|
|
3120
|
-
function
|
|
3121
|
-
return /* @__PURE__ */
|
|
3617
|
+
function vi({ className: e, children: t, ...n }) {
|
|
3618
|
+
return /* @__PURE__ */ X(q.Item, {
|
|
3122
3619
|
"data-slot": "select-item",
|
|
3123
|
-
className:
|
|
3620
|
+
className: Q("relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2", e),
|
|
3124
3621
|
...n,
|
|
3125
|
-
children: [/* @__PURE__ */
|
|
3622
|
+
children: [/* @__PURE__ */ Y("span", {
|
|
3126
3623
|
className: "pointer-events-none absolute right-2 flex size-4 items-center justify-center",
|
|
3127
|
-
children: /* @__PURE__ */
|
|
3128
|
-
}), /* @__PURE__ */
|
|
3624
|
+
children: /* @__PURE__ */ Y(q.ItemIndicator, { children: /* @__PURE__ */ Y(g, { className: "pointer-events-none" }) })
|
|
3625
|
+
}), /* @__PURE__ */ Y(q.ItemText, { children: t })]
|
|
3129
3626
|
});
|
|
3130
3627
|
}
|
|
3131
|
-
function
|
|
3132
|
-
return /* @__PURE__ */
|
|
3628
|
+
function yi({ className: e, ...t }) {
|
|
3629
|
+
return /* @__PURE__ */ Y(q.Separator, {
|
|
3133
3630
|
"data-slot": "select-separator",
|
|
3134
|
-
className:
|
|
3631
|
+
className: Q("pointer-events-none -mx-1 my-1 h-px bg-border", e),
|
|
3135
3632
|
...t
|
|
3136
3633
|
});
|
|
3137
3634
|
}
|
|
3138
|
-
function
|
|
3139
|
-
return /* @__PURE__ */
|
|
3635
|
+
function bi({ className: e, ...t }) {
|
|
3636
|
+
return /* @__PURE__ */ Y(q.ScrollUpButton, {
|
|
3140
3637
|
"data-slot": "select-scroll-up-button",
|
|
3141
|
-
className:
|
|
3638
|
+
className: Q("z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4", e),
|
|
3142
3639
|
...t,
|
|
3143
|
-
children: /* @__PURE__ */
|
|
3640
|
+
children: /* @__PURE__ */ Y(x, {})
|
|
3144
3641
|
});
|
|
3145
3642
|
}
|
|
3146
|
-
function
|
|
3147
|
-
return /* @__PURE__ */
|
|
3643
|
+
function xi({ className: e, ...t }) {
|
|
3644
|
+
return /* @__PURE__ */ Y(q.ScrollDownButton, {
|
|
3148
3645
|
"data-slot": "select-scroll-down-button",
|
|
3149
|
-
className:
|
|
3646
|
+
className: Q("z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4", e),
|
|
3150
3647
|
...t,
|
|
3151
|
-
children: /* @__PURE__ */
|
|
3648
|
+
children: /* @__PURE__ */ Y(v, {})
|
|
3152
3649
|
});
|
|
3153
3650
|
}
|
|
3154
3651
|
//#endregion
|
|
3155
3652
|
//#region src/components/ui/sheet.tsx
|
|
3156
|
-
function
|
|
3157
|
-
return /* @__PURE__ */
|
|
3653
|
+
function Si({ ...e }) {
|
|
3654
|
+
return /* @__PURE__ */ Y(G.Root, {
|
|
3158
3655
|
"data-slot": "sheet",
|
|
3159
3656
|
...e
|
|
3160
3657
|
});
|
|
3161
3658
|
}
|
|
3162
|
-
function
|
|
3163
|
-
return /* @__PURE__ */
|
|
3659
|
+
function Ci({ ...e }) {
|
|
3660
|
+
return /* @__PURE__ */ Y(G.Trigger, {
|
|
3164
3661
|
"data-slot": "sheet-trigger",
|
|
3165
3662
|
...e
|
|
3166
3663
|
});
|
|
3167
3664
|
}
|
|
3168
|
-
function
|
|
3169
|
-
return /* @__PURE__ */
|
|
3665
|
+
function wi({ ...e }) {
|
|
3666
|
+
return /* @__PURE__ */ Y(G.Close, {
|
|
3170
3667
|
"data-slot": "sheet-close",
|
|
3171
3668
|
...e
|
|
3172
3669
|
});
|
|
3173
3670
|
}
|
|
3174
|
-
function
|
|
3175
|
-
return /* @__PURE__ */
|
|
3671
|
+
function Ti({ ...e }) {
|
|
3672
|
+
return /* @__PURE__ */ Y(G.Portal, {
|
|
3176
3673
|
"data-slot": "sheet-portal",
|
|
3177
3674
|
...e
|
|
3178
3675
|
});
|
|
3179
3676
|
}
|
|
3180
|
-
function
|
|
3181
|
-
return /* @__PURE__ */
|
|
3677
|
+
function Ei({ className: e, ...t }) {
|
|
3678
|
+
return /* @__PURE__ */ Y(G.Overlay, {
|
|
3182
3679
|
"data-slot": "sheet-overlay",
|
|
3183
|
-
className:
|
|
3680
|
+
className: Q("fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0", e),
|
|
3184
3681
|
...t
|
|
3185
3682
|
});
|
|
3186
3683
|
}
|
|
3187
|
-
function
|
|
3188
|
-
return /* @__PURE__ */
|
|
3684
|
+
function Di({ className: e, children: t, side: n = "right", showCloseButton: r = !0, ...i }) {
|
|
3685
|
+
return /* @__PURE__ */ X(Ti, { children: [/* @__PURE__ */ Y(Ei, {}), /* @__PURE__ */ X(G.Content, {
|
|
3189
3686
|
"data-slot": "sheet-content",
|
|
3190
3687
|
"data-side": n,
|
|
3191
|
-
className:
|
|
3688
|
+
className: Q("fixed z-50 flex flex-col gap-4 bg-popover bg-clip-padding text-sm text-popover-foreground shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10", e),
|
|
3192
3689
|
...i,
|
|
3193
|
-
children: [t, r && /* @__PURE__ */
|
|
3690
|
+
children: [t, r && /* @__PURE__ */ Y(G.Close, {
|
|
3194
3691
|
"data-slot": "sheet-close",
|
|
3195
3692
|
asChild: !0,
|
|
3196
|
-
children: /* @__PURE__ */
|
|
3693
|
+
children: /* @__PURE__ */ X($, {
|
|
3197
3694
|
variant: "ghost",
|
|
3198
3695
|
className: "absolute top-3 right-3",
|
|
3199
3696
|
size: "icon-sm",
|
|
3200
|
-
children: [/* @__PURE__ */
|
|
3697
|
+
children: [/* @__PURE__ */ Y(de, {}), /* @__PURE__ */ Y("span", {
|
|
3201
3698
|
className: "sr-only",
|
|
3202
3699
|
children: "Close"
|
|
3203
3700
|
})]
|
|
@@ -3205,59 +3702,59 @@ function ci({ className: e, children: t, side: n = "right", showCloseButton: r =
|
|
|
3205
3702
|
})]
|
|
3206
3703
|
})] });
|
|
3207
3704
|
}
|
|
3208
|
-
function
|
|
3209
|
-
return /* @__PURE__ */
|
|
3705
|
+
function Oi({ className: e, ...t }) {
|
|
3706
|
+
return /* @__PURE__ */ Y("div", {
|
|
3210
3707
|
"data-slot": "sheet-header",
|
|
3211
|
-
className:
|
|
3708
|
+
className: Q("flex flex-col gap-0.5 p-4", e),
|
|
3212
3709
|
...t
|
|
3213
3710
|
});
|
|
3214
3711
|
}
|
|
3215
|
-
function
|
|
3216
|
-
return /* @__PURE__ */
|
|
3712
|
+
function ki({ className: e, ...t }) {
|
|
3713
|
+
return /* @__PURE__ */ Y("div", {
|
|
3217
3714
|
"data-slot": "sheet-footer",
|
|
3218
|
-
className:
|
|
3715
|
+
className: Q("mt-auto flex flex-col gap-2 p-4", e),
|
|
3219
3716
|
...t
|
|
3220
3717
|
});
|
|
3221
3718
|
}
|
|
3222
|
-
function
|
|
3223
|
-
return /* @__PURE__ */
|
|
3719
|
+
function Ai({ className: e, ...t }) {
|
|
3720
|
+
return /* @__PURE__ */ Y(G.Title, {
|
|
3224
3721
|
"data-slot": "sheet-title",
|
|
3225
|
-
className:
|
|
3722
|
+
className: Q("text-base font-medium text-foreground", e),
|
|
3226
3723
|
...t
|
|
3227
3724
|
});
|
|
3228
3725
|
}
|
|
3229
|
-
function
|
|
3230
|
-
return /* @__PURE__ */
|
|
3726
|
+
function ji({ className: e, ...t }) {
|
|
3727
|
+
return /* @__PURE__ */ Y(G.Description, {
|
|
3231
3728
|
"data-slot": "sheet-description",
|
|
3232
|
-
className:
|
|
3729
|
+
className: Q("text-sm text-muted-foreground", e),
|
|
3233
3730
|
...t
|
|
3234
3731
|
});
|
|
3235
3732
|
}
|
|
3236
3733
|
//#endregion
|
|
3237
3734
|
//#region src/components/ui/slider.tsx
|
|
3238
|
-
function
|
|
3735
|
+
function Mi({ className: e, defaultValue: t, value: r, min: i = 0, max: a = 100, ...o }) {
|
|
3239
3736
|
let s = n.useMemo(() => Array.isArray(r) ? r : Array.isArray(t) ? t : [i, a], [
|
|
3240
3737
|
r,
|
|
3241
3738
|
t,
|
|
3242
3739
|
i,
|
|
3243
3740
|
a
|
|
3244
3741
|
]);
|
|
3245
|
-
return /* @__PURE__ */
|
|
3742
|
+
return /* @__PURE__ */ X(ve.Root, {
|
|
3246
3743
|
"data-slot": "slider",
|
|
3247
3744
|
defaultValue: t,
|
|
3248
3745
|
value: r,
|
|
3249
3746
|
min: i,
|
|
3250
3747
|
max: a,
|
|
3251
|
-
className:
|
|
3748
|
+
className: Q("relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-vertical:h-full data-vertical:min-h-40 data-vertical:w-auto data-vertical:flex-col", e),
|
|
3252
3749
|
...o,
|
|
3253
|
-
children: [/* @__PURE__ */
|
|
3750
|
+
children: [/* @__PURE__ */ Y(ve.Track, {
|
|
3254
3751
|
"data-slot": "slider-track",
|
|
3255
3752
|
className: "relative grow overflow-hidden rounded-full bg-muted data-horizontal:h-1 data-horizontal:w-full data-vertical:h-full data-vertical:w-1",
|
|
3256
|
-
children: /* @__PURE__ */
|
|
3753
|
+
children: /* @__PURE__ */ Y(ve.Range, {
|
|
3257
3754
|
"data-slot": "slider-range",
|
|
3258
3755
|
className: "absolute bg-primary select-none data-horizontal:h-full data-vertical:w-full"
|
|
3259
3756
|
})
|
|
3260
|
-
}), Array.from({ length: s.length }, (e, t) => /* @__PURE__ */
|
|
3757
|
+
}), Array.from({ length: s.length }, (e, t) => /* @__PURE__ */ Y(ve.Thumb, {
|
|
3261
3758
|
"data-slot": "slider-thumb",
|
|
3262
3759
|
className: "relative block size-3 shrink-0 rounded-full border border-ring bg-white ring-ring/50 transition-[color,box-shadow] select-none after:absolute after:-inset-2 hover:ring-3 focus-visible:ring-3 focus-visible:outline-hidden active:ring-3 disabled:pointer-events-none disabled:opacity-50"
|
|
3263
3760
|
}, t))]
|
|
@@ -3265,17 +3762,17 @@ function pi({ className: e, defaultValue: t, value: r, min: i = 0, max: a = 100,
|
|
|
3265
3762
|
}
|
|
3266
3763
|
//#endregion
|
|
3267
3764
|
//#region src/components/ui/sonner.tsx
|
|
3268
|
-
var
|
|
3269
|
-
let { theme: t = "system" } =
|
|
3270
|
-
return /* @__PURE__ */
|
|
3765
|
+
var Ni = ({ ...e }) => {
|
|
3766
|
+
let { theme: t = "system" } = Ae();
|
|
3767
|
+
return /* @__PURE__ */ Y(je, {
|
|
3271
3768
|
theme: t,
|
|
3272
3769
|
className: "toaster group",
|
|
3273
3770
|
icons: {
|
|
3274
|
-
success: /* @__PURE__ */
|
|
3275
|
-
info: /* @__PURE__ */
|
|
3276
|
-
warning: /* @__PURE__ */
|
|
3277
|
-
error: /* @__PURE__ */
|
|
3278
|
-
loading: /* @__PURE__ */
|
|
3771
|
+
success: /* @__PURE__ */ Y(w, { className: "size-4" }),
|
|
3772
|
+
info: /* @__PURE__ */ Y(N, { className: "size-4" }),
|
|
3773
|
+
warning: /* @__PURE__ */ Y(ce, { className: "size-4" }),
|
|
3774
|
+
error: /* @__PURE__ */ Y(z, { className: "size-4" }),
|
|
3775
|
+
loading: /* @__PURE__ */ Y(ne, { className: "size-4 animate-spin" })
|
|
3279
3776
|
},
|
|
3280
3777
|
style: {
|
|
3281
3778
|
"--normal-bg": "var(--popover)",
|
|
@@ -3286,44 +3783,44 @@ var mi = ({ ...e }) => {
|
|
|
3286
3783
|
toastOptions: { classNames: { toast: "cn-toast" } },
|
|
3287
3784
|
...e
|
|
3288
3785
|
});
|
|
3289
|
-
},
|
|
3290
|
-
let e = o(
|
|
3786
|
+
}, Pi = r(void 0), Fi = r(void 0), Ii = () => {
|
|
3787
|
+
let e = o(Pi);
|
|
3291
3788
|
if (!e) throw Error("useStepper must be used within a Stepper");
|
|
3292
3789
|
return e;
|
|
3293
|
-
},
|
|
3294
|
-
let e = o(
|
|
3790
|
+
}, Li = () => {
|
|
3791
|
+
let e = o(Fi);
|
|
3295
3792
|
if (!e) throw Error("useStepItem must be used within a StepperItem");
|
|
3296
3793
|
return e;
|
|
3297
3794
|
};
|
|
3298
|
-
function
|
|
3795
|
+
function Ri({ defaultValue: e = 0, value: t, onValueChange: r, orientation: i = "horizontal", className: a, ...o }) {
|
|
3299
3796
|
let [s, c] = n.useState(e), l = n.useCallback((e) => {
|
|
3300
3797
|
t === void 0 && c(e), r?.(e);
|
|
3301
3798
|
}, [t, r]), u = t ?? s;
|
|
3302
|
-
return /* @__PURE__ */
|
|
3799
|
+
return /* @__PURE__ */ Y(Pi.Provider, {
|
|
3303
3800
|
value: {
|
|
3304
3801
|
activeStep: u,
|
|
3305
3802
|
orientation: i,
|
|
3306
3803
|
setActiveStep: l
|
|
3307
3804
|
},
|
|
3308
|
-
children: /* @__PURE__ */
|
|
3309
|
-
className:
|
|
3805
|
+
children: /* @__PURE__ */ Y("div", {
|
|
3806
|
+
className: Q("group/stepper inline-flex data-[orientation=horizontal]:w-full data-[orientation=horizontal]:flex-row data-[orientation=vertical]:flex-col", a),
|
|
3310
3807
|
"data-orientation": i,
|
|
3311
3808
|
"data-slot": "stepper",
|
|
3312
3809
|
...o
|
|
3313
3810
|
})
|
|
3314
3811
|
});
|
|
3315
3812
|
}
|
|
3316
|
-
function
|
|
3317
|
-
let { activeStep: s } =
|
|
3318
|
-
return /* @__PURE__ */
|
|
3813
|
+
function zi({ step: e, completed: t = !1, disabled: n = !1, loading: r = !1, className: i, children: a, ...o }) {
|
|
3814
|
+
let { activeStep: s } = Ii(), c = t || e < s ? "completed" : s === e ? "active" : "inactive", l = r && e === s;
|
|
3815
|
+
return /* @__PURE__ */ Y(Fi.Provider, {
|
|
3319
3816
|
value: {
|
|
3320
3817
|
isDisabled: n,
|
|
3321
3818
|
isLoading: l,
|
|
3322
3819
|
state: c,
|
|
3323
3820
|
step: e
|
|
3324
3821
|
},
|
|
3325
|
-
children: /* @__PURE__ */
|
|
3326
|
-
className:
|
|
3822
|
+
children: /* @__PURE__ */ Y("div", {
|
|
3823
|
+
className: Q("group/step flex items-center group-data-[orientation=horizontal]/stepper:flex-row group-data-[orientation=vertical]/stepper:flex-col", i),
|
|
3327
3824
|
"data-slot": "stepper-item",
|
|
3328
3825
|
"data-state": c,
|
|
3329
3826
|
...l ? { "data-loading": !0 } : {},
|
|
@@ -3332,14 +3829,14 @@ function bi({ step: e, completed: t = !1, disabled: n = !1, loading: r = !1, cla
|
|
|
3332
3829
|
})
|
|
3333
3830
|
});
|
|
3334
3831
|
}
|
|
3335
|
-
function
|
|
3336
|
-
let { setActiveStep: i } =
|
|
3337
|
-
return e ? /* @__PURE__ */
|
|
3832
|
+
function Bi({ asChild: e = !1, className: t, children: n, ...r }) {
|
|
3833
|
+
let { setActiveStep: i } = Ii(), { step: a, isDisabled: o } = Li();
|
|
3834
|
+
return e ? /* @__PURE__ */ Y(e ? J.Root : "span", {
|
|
3338
3835
|
className: t,
|
|
3339
3836
|
"data-slot": "stepper-trigger",
|
|
3340
3837
|
children: n
|
|
3341
|
-
}) : /* @__PURE__ */
|
|
3342
|
-
className:
|
|
3838
|
+
}) : /* @__PURE__ */ Y("button", {
|
|
3839
|
+
className: Q("inline-flex items-center gap-3 rounded-full outline-none focus-visible:z-10 focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50", t),
|
|
3343
3840
|
"data-slot": "stepper-trigger",
|
|
3344
3841
|
disabled: o,
|
|
3345
3842
|
onClick: () => i(a),
|
|
@@ -3348,26 +3845,26 @@ function xi({ asChild: e = !1, className: t, children: n, ...r }) {
|
|
|
3348
3845
|
children: n
|
|
3349
3846
|
});
|
|
3350
3847
|
}
|
|
3351
|
-
function
|
|
3352
|
-
let { state: i, step: a, isLoading: o } =
|
|
3353
|
-
return /* @__PURE__ */
|
|
3354
|
-
className:
|
|
3848
|
+
function Vi({ asChild: e = !1, className: t, children: n, ...r }) {
|
|
3849
|
+
let { state: i, step: a, isLoading: o } = Li();
|
|
3850
|
+
return /* @__PURE__ */ Y("span", {
|
|
3851
|
+
className: Q("relative flex size-6 shrink-0 items-center justify-center rounded-full bg-muted font-medium text-muted-foreground text-xs data-[state=active]:bg-primary data-[state=completed]:bg-primary data-[state=active]:text-primary-foreground data-[state=completed]:text-primary-foreground", t),
|
|
3355
3852
|
"data-slot": "stepper-indicator",
|
|
3356
3853
|
"data-state": i,
|
|
3357
3854
|
...r,
|
|
3358
|
-
children: e ? n : /* @__PURE__ */
|
|
3359
|
-
/* @__PURE__ */
|
|
3855
|
+
children: e ? n : /* @__PURE__ */ X(we, { children: [
|
|
3856
|
+
/* @__PURE__ */ Y("span", {
|
|
3360
3857
|
className: "transition-all group-data-[state=completed]/step:scale-0 group-data-loading/step:scale-0 group-data-[state=completed]/step:opacity-0 group-data-loading/step:opacity-0 group-data-loading/step:transition-none",
|
|
3361
3858
|
children: a
|
|
3362
3859
|
}),
|
|
3363
|
-
/* @__PURE__ */
|
|
3860
|
+
/* @__PURE__ */ Y(g, {
|
|
3364
3861
|
"aria-hidden": "true",
|
|
3365
3862
|
className: "absolute scale-0 opacity-0 transition-all group-data-[state=completed]/step:scale-100 group-data-[state=completed]/step:opacity-100",
|
|
3366
3863
|
size: 16
|
|
3367
3864
|
}),
|
|
3368
|
-
o && /* @__PURE__ */
|
|
3865
|
+
o && /* @__PURE__ */ Y("span", {
|
|
3369
3866
|
className: "absolute transition-all",
|
|
3370
|
-
children: /* @__PURE__ */
|
|
3867
|
+
children: /* @__PURE__ */ Y(I, {
|
|
3371
3868
|
"aria-hidden": "true",
|
|
3372
3869
|
className: "animate-spin",
|
|
3373
3870
|
size: 14
|
|
@@ -3376,36 +3873,36 @@ function Si({ asChild: e = !1, className: t, children: n, ...r }) {
|
|
|
3376
3873
|
] })
|
|
3377
3874
|
});
|
|
3378
3875
|
}
|
|
3379
|
-
function
|
|
3380
|
-
return /* @__PURE__ */
|
|
3381
|
-
className:
|
|
3876
|
+
function Hi({ className: e, ...t }) {
|
|
3877
|
+
return /* @__PURE__ */ Y("h3", {
|
|
3878
|
+
className: Q("font-medium text-sm", e),
|
|
3382
3879
|
"data-slot": "stepper-title",
|
|
3383
3880
|
...t
|
|
3384
3881
|
});
|
|
3385
3882
|
}
|
|
3386
|
-
function
|
|
3387
|
-
return /* @__PURE__ */
|
|
3388
|
-
className:
|
|
3883
|
+
function Ui({ className: e, ...t }) {
|
|
3884
|
+
return /* @__PURE__ */ Y("p", {
|
|
3885
|
+
className: Q("text-muted-foreground text-sm", e),
|
|
3389
3886
|
"data-slot": "stepper-description",
|
|
3390
3887
|
...t
|
|
3391
3888
|
});
|
|
3392
3889
|
}
|
|
3393
|
-
function
|
|
3394
|
-
return /* @__PURE__ */
|
|
3395
|
-
className:
|
|
3890
|
+
function Wi({ className: e, ...t }) {
|
|
3891
|
+
return /* @__PURE__ */ Y("div", {
|
|
3892
|
+
className: Q("m-0.5 bg-muted group-data-[orientation=horizontal]/stepper:h-0.5 group-data-[orientation=vertical]/stepper:h-12 group-data-[orientation=horizontal]/stepper:w-full group-data-[orientation=vertical]/stepper:w-0.5 group-data-[orientation=horizontal]/stepper:flex-1 group-data-[state=completed]/step:bg-primary", e),
|
|
3396
3893
|
"data-slot": "stepper-separator",
|
|
3397
3894
|
...t
|
|
3398
3895
|
});
|
|
3399
3896
|
}
|
|
3400
3897
|
//#endregion
|
|
3401
3898
|
//#region src/components/ui/switch.tsx
|
|
3402
|
-
function
|
|
3403
|
-
return /* @__PURE__ */
|
|
3899
|
+
function Gi({ className: e, size: t = "default", ...n }) {
|
|
3900
|
+
return /* @__PURE__ */ Y(ye.Root, {
|
|
3404
3901
|
"data-slot": "switch",
|
|
3405
3902
|
"data-size": t,
|
|
3406
|
-
className:
|
|
3903
|
+
className: Q("peer group/switch relative inline-flex shrink-0 items-center rounded-full border border-transparent transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-[size=default]:h-[18.4px] data-[size=default]:w-[32px] data-[size=sm]:h-[14px] data-[size=sm]:w-[24px] dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:bg-primary data-unchecked:bg-input dark:data-unchecked:bg-input/80 data-disabled:cursor-not-allowed data-disabled:opacity-50", e),
|
|
3407
3904
|
...n,
|
|
3408
|
-
children: /* @__PURE__ */
|
|
3905
|
+
children: /* @__PURE__ */ Y(ye.Thumb, {
|
|
3409
3906
|
"data-slot": "switch-thumb",
|
|
3410
3907
|
className: "pointer-events-none block rounded-full bg-background ring-0 transition-transform group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[calc(100%-2px)] group-data-[size=sm]/switch:data-checked:translate-x-[calc(100%-2px)] dark:data-checked:bg-primary-foreground group-data-[size=default]/switch:data-unchecked:translate-x-0 group-data-[size=sm]/switch:data-unchecked:translate-x-0 dark:data-unchecked:bg-foreground"
|
|
3411
3908
|
})
|
|
@@ -3413,124 +3910,124 @@ function Ei({ className: e, size: t = "default", ...n }) {
|
|
|
3413
3910
|
}
|
|
3414
3911
|
//#endregion
|
|
3415
3912
|
//#region src/components/ui/tabs.tsx
|
|
3416
|
-
function
|
|
3417
|
-
return /* @__PURE__ */
|
|
3913
|
+
function Ki({ className: e, orientation: t = "horizontal", ...n }) {
|
|
3914
|
+
return /* @__PURE__ */ Y(be.Root, {
|
|
3418
3915
|
"data-slot": "tabs",
|
|
3419
3916
|
"data-orientation": t,
|
|
3420
|
-
className:
|
|
3917
|
+
className: Q("group/tabs flex gap-2 data-horizontal:flex-col", e),
|
|
3421
3918
|
...n
|
|
3422
3919
|
});
|
|
3423
3920
|
}
|
|
3424
|
-
var
|
|
3921
|
+
var qi = H("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-horizontal/tabs:h-8 group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col data-[variant=line]:rounded-none", {
|
|
3425
3922
|
variants: { variant: {
|
|
3426
3923
|
default: "bg-muted",
|
|
3427
3924
|
line: "gap-1 bg-transparent"
|
|
3428
3925
|
} },
|
|
3429
3926
|
defaultVariants: { variant: "default" }
|
|
3430
3927
|
});
|
|
3431
|
-
function
|
|
3432
|
-
return /* @__PURE__ */
|
|
3928
|
+
function Ji({ className: e, variant: t = "default", ...n }) {
|
|
3929
|
+
return /* @__PURE__ */ Y(be.List, {
|
|
3433
3930
|
"data-slot": "tabs-list",
|
|
3434
3931
|
"data-variant": t,
|
|
3435
|
-
className:
|
|
3932
|
+
className: Q(qi({ variant: t }), e),
|
|
3436
3933
|
...n
|
|
3437
3934
|
});
|
|
3438
3935
|
}
|
|
3439
|
-
function
|
|
3440
|
-
return /* @__PURE__ */
|
|
3936
|
+
function Yi({ className: e, ...t }) {
|
|
3937
|
+
return /* @__PURE__ */ Y(be.Trigger, {
|
|
3441
3938
|
"data-slot": "tabs-trigger",
|
|
3442
|
-
className:
|
|
3939
|
+
className: Q("relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium whitespace-nowrap text-foreground/60 transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 has-data-[icon=inline-end]:pr-1 has-data-[icon=inline-start]:pl-1 dark:text-muted-foreground dark:hover:text-foreground group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", "group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent", "data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground", "after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100", e),
|
|
3443
3940
|
...t
|
|
3444
3941
|
});
|
|
3445
3942
|
}
|
|
3446
|
-
function
|
|
3447
|
-
return /* @__PURE__ */
|
|
3943
|
+
function Xi({ className: e, ...t }) {
|
|
3944
|
+
return /* @__PURE__ */ Y(be.Content, {
|
|
3448
3945
|
"data-slot": "tabs-content",
|
|
3449
|
-
className:
|
|
3946
|
+
className: Q("flex-1 text-sm outline-none", e),
|
|
3450
3947
|
...t
|
|
3451
3948
|
});
|
|
3452
3949
|
}
|
|
3453
3950
|
//#endregion
|
|
3454
3951
|
//#region src/components/ui/timeline.tsx
|
|
3455
|
-
var
|
|
3456
|
-
let e = n.useContext(
|
|
3952
|
+
var Zi = n.createContext(void 0), Qi = () => {
|
|
3953
|
+
let e = n.useContext(Zi);
|
|
3457
3954
|
if (!e) throw Error("useTimeline must be used within a Timeline");
|
|
3458
3955
|
return e;
|
|
3459
3956
|
};
|
|
3460
|
-
function
|
|
3957
|
+
function $i({ defaultValue: e = 1, value: t, onValueChange: r, orientation: i = "vertical", className: a, ...o }) {
|
|
3461
3958
|
let [s, c] = n.useState(e), l = n.useCallback((e) => {
|
|
3462
3959
|
t === void 0 && c(e), r?.(e);
|
|
3463
3960
|
}, [t, r]), u = t ?? s;
|
|
3464
|
-
return /* @__PURE__ */
|
|
3961
|
+
return /* @__PURE__ */ Y(Zi.Provider, {
|
|
3465
3962
|
value: {
|
|
3466
3963
|
activeStep: u,
|
|
3467
3964
|
setActiveStep: l
|
|
3468
3965
|
},
|
|
3469
|
-
children: /* @__PURE__ */
|
|
3470
|
-
className:
|
|
3966
|
+
children: /* @__PURE__ */ Y("div", {
|
|
3967
|
+
className: Q("group/timeline flex data-[orientation=horizontal]:w-full data-[orientation=horizontal]:flex-row data-[orientation=vertical]:flex-col", a),
|
|
3471
3968
|
"data-orientation": i,
|
|
3472
3969
|
"data-slot": "timeline",
|
|
3473
3970
|
...o
|
|
3474
3971
|
})
|
|
3475
3972
|
});
|
|
3476
3973
|
}
|
|
3477
|
-
function
|
|
3478
|
-
return /* @__PURE__ */
|
|
3479
|
-
className:
|
|
3974
|
+
function ea({ className: e, ...t }) {
|
|
3975
|
+
return /* @__PURE__ */ Y("div", {
|
|
3976
|
+
className: Q("text-muted-foreground text-sm", e),
|
|
3480
3977
|
"data-slot": "timeline-content",
|
|
3481
3978
|
...t
|
|
3482
3979
|
});
|
|
3483
3980
|
}
|
|
3484
|
-
function
|
|
3485
|
-
return /* @__PURE__ */
|
|
3486
|
-
className:
|
|
3981
|
+
function ta({ asChild: e = !1, className: t, ...n }) {
|
|
3982
|
+
return /* @__PURE__ */ Y(e ? J.Root : "time", {
|
|
3983
|
+
className: Q("mb-1 block font-medium text-muted-foreground text-xs group-data-[orientation=vertical]/timeline:max-sm:h-4", t),
|
|
3487
3984
|
"data-slot": "timeline-date",
|
|
3488
3985
|
...n
|
|
3489
3986
|
});
|
|
3490
3987
|
}
|
|
3491
|
-
function
|
|
3492
|
-
return /* @__PURE__ */
|
|
3493
|
-
className:
|
|
3988
|
+
function na({ className: e, ...t }) {
|
|
3989
|
+
return /* @__PURE__ */ Y("div", {
|
|
3990
|
+
className: Q(e),
|
|
3494
3991
|
"data-slot": "timeline-header",
|
|
3495
3992
|
...t
|
|
3496
3993
|
});
|
|
3497
3994
|
}
|
|
3498
|
-
function
|
|
3499
|
-
return /* @__PURE__ */
|
|
3995
|
+
function ra({ className: e, children: t, ...n }) {
|
|
3996
|
+
return /* @__PURE__ */ Y("div", {
|
|
3500
3997
|
"aria-hidden": "true",
|
|
3501
|
-
className:
|
|
3998
|
+
className: Q("group-data-[orientation=horizontal]/timeline:-top-6 group-data-[orientation=horizontal]/timeline:-translate-y-1/2 group-data-[orientation=vertical]/timeline:-left-6 group-data-[orientation=vertical]/timeline:-translate-x-1/2 absolute size-4 rounded-full border-2 border-primary/20 group-data-[orientation=vertical]/timeline:top-0 group-data-[orientation=horizontal]/timeline:left-0 group-data-completed/timeline-item:border-primary", e),
|
|
3502
3999
|
"data-slot": "timeline-indicator",
|
|
3503
4000
|
...n,
|
|
3504
4001
|
children: t
|
|
3505
4002
|
});
|
|
3506
4003
|
}
|
|
3507
|
-
function
|
|
3508
|
-
let { activeStep: r } =
|
|
3509
|
-
return /* @__PURE__ */
|
|
3510
|
-
className:
|
|
4004
|
+
function ia({ step: e, className: t, ...n }) {
|
|
4005
|
+
let { activeStep: r } = Qi();
|
|
4006
|
+
return /* @__PURE__ */ Y("div", {
|
|
4007
|
+
className: Q("group/timeline-item relative flex flex-1 flex-col gap-0.5 group-data-[orientation=vertical]/timeline:ms-8 group-data-[orientation=horizontal]/timeline:mt-8 group-data-[orientation=horizontal]/timeline:not-last:pe-8 group-data-[orientation=vertical]/timeline:not-last:pb-12 has-[+[data-completed]]:[&_[data-slot=timeline-separator]]:bg-primary", t),
|
|
3511
4008
|
"data-completed": e <= r || void 0,
|
|
3512
4009
|
"data-slot": "timeline-item",
|
|
3513
4010
|
...n
|
|
3514
4011
|
});
|
|
3515
4012
|
}
|
|
3516
|
-
function
|
|
3517
|
-
return /* @__PURE__ */
|
|
4013
|
+
function aa({ className: e, ...t }) {
|
|
4014
|
+
return /* @__PURE__ */ Y("div", {
|
|
3518
4015
|
"aria-hidden": "true",
|
|
3519
|
-
className:
|
|
4016
|
+
className: Q("group-data-[orientation=horizontal]/timeline:-top-6 group-data-[orientation=horizontal]/timeline:-translate-y-1/2 group-data-[orientation=vertical]/timeline:-left-6 group-data-[orientation=vertical]/timeline:-translate-x-1/2 absolute self-start bg-primary/10 group-last/timeline-item:hidden group-data-[orientation=horizontal]/timeline:h-0.5 group-data-[orientation=vertical]/timeline:h-[calc(100%-1rem-0.25rem)] group-data-[orientation=horizontal]/timeline:w-[calc(100%-1rem-0.25rem)] group-data-[orientation=vertical]/timeline:w-0.5 group-data-[orientation=horizontal]/timeline:translate-x-4.5 group-data-[orientation=vertical]/timeline:translate-y-4.5", e),
|
|
3520
4017
|
"data-slot": "timeline-separator",
|
|
3521
4018
|
...t
|
|
3522
4019
|
});
|
|
3523
4020
|
}
|
|
3524
|
-
function
|
|
3525
|
-
return /* @__PURE__ */
|
|
3526
|
-
className:
|
|
4021
|
+
function oa({ className: e, ...t }) {
|
|
4022
|
+
return /* @__PURE__ */ Y("h3", {
|
|
4023
|
+
className: Q("font-medium text-sm", e),
|
|
3527
4024
|
"data-slot": "timeline-title",
|
|
3528
4025
|
...t
|
|
3529
4026
|
});
|
|
3530
4027
|
}
|
|
3531
4028
|
//#endregion
|
|
3532
4029
|
//#region src/components/ui/toggle.tsx
|
|
3533
|
-
var
|
|
4030
|
+
var sa = H("group/toggle inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", {
|
|
3534
4031
|
variants: {
|
|
3535
4032
|
variant: {
|
|
3536
4033
|
default: "bg-transparent",
|
|
@@ -3547,10 +4044,10 @@ var Hi = P("group/toggle inline-flex items-center justify-center gap-1 rounded-l
|
|
|
3547
4044
|
size: "default"
|
|
3548
4045
|
}
|
|
3549
4046
|
});
|
|
3550
|
-
function
|
|
3551
|
-
return /* @__PURE__ */
|
|
4047
|
+
function ca({ className: e, variant: t = "default", size: n = "default", ...r }) {
|
|
4048
|
+
return /* @__PURE__ */ Y(xe.Root, {
|
|
3552
4049
|
"data-slot": "toggle",
|
|
3553
|
-
className:
|
|
4050
|
+
className: Q(sa({
|
|
3554
4051
|
variant: t,
|
|
3555
4052
|
size: n,
|
|
3556
4053
|
className: e
|
|
@@ -3560,23 +4057,23 @@ function Ui({ className: e, variant: t = "default", size: n = "default", ...r })
|
|
|
3560
4057
|
}
|
|
3561
4058
|
//#endregion
|
|
3562
4059
|
//#region src/components/ui/toggle-group.tsx
|
|
3563
|
-
var
|
|
4060
|
+
var la = n.createContext({
|
|
3564
4061
|
size: "default",
|
|
3565
4062
|
variant: "default",
|
|
3566
4063
|
spacing: 2,
|
|
3567
4064
|
orientation: "horizontal"
|
|
3568
4065
|
});
|
|
3569
|
-
function
|
|
3570
|
-
return /* @__PURE__ */
|
|
4066
|
+
function ua({ className: e, variant: t, size: n, spacing: r = 2, orientation: i = "horizontal", children: a, ...o }) {
|
|
4067
|
+
return /* @__PURE__ */ Y(Se.Root, {
|
|
3571
4068
|
"data-slot": "toggle-group",
|
|
3572
4069
|
"data-variant": t,
|
|
3573
4070
|
"data-size": n,
|
|
3574
4071
|
"data-spacing": r,
|
|
3575
4072
|
"data-orientation": i,
|
|
3576
4073
|
style: { "--gap": r },
|
|
3577
|
-
className:
|
|
4074
|
+
className: Q("group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch", e),
|
|
3578
4075
|
...o,
|
|
3579
|
-
children: /* @__PURE__ */
|
|
4076
|
+
children: /* @__PURE__ */ Y(la.Provider, {
|
|
3580
4077
|
value: {
|
|
3581
4078
|
variant: t,
|
|
3582
4079
|
size: n,
|
|
@@ -3587,14 +4084,14 @@ function Gi({ className: e, variant: t, size: n, spacing: r = 2, orientation: i
|
|
|
3587
4084
|
})
|
|
3588
4085
|
});
|
|
3589
4086
|
}
|
|
3590
|
-
function
|
|
3591
|
-
let o = n.useContext(
|
|
3592
|
-
return /* @__PURE__ */
|
|
4087
|
+
function da({ className: e, children: t, variant: r = "default", size: i = "default", ...a }) {
|
|
4088
|
+
let o = n.useContext(la);
|
|
4089
|
+
return /* @__PURE__ */ Y(Se.Item, {
|
|
3593
4090
|
"data-slot": "toggle-group-item",
|
|
3594
4091
|
"data-variant": o.variant || r,
|
|
3595
4092
|
"data-size": o.size || i,
|
|
3596
4093
|
"data-spacing": o.spacing,
|
|
3597
|
-
className:
|
|
4094
|
+
className: Q("shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t", sa({
|
|
3598
4095
|
variant: o.variant || r,
|
|
3599
4096
|
size: o.size || i
|
|
3600
4097
|
}), e),
|
|
@@ -3604,35 +4101,35 @@ function Ki({ className: e, children: t, variant: r = "default", size: i = "defa
|
|
|
3604
4101
|
}
|
|
3605
4102
|
//#endregion
|
|
3606
4103
|
//#region src/components/ui/tooltip.tsx
|
|
3607
|
-
function
|
|
3608
|
-
return /* @__PURE__ */
|
|
4104
|
+
function fa({ delayDuration: e = 0, ...t }) {
|
|
4105
|
+
return /* @__PURE__ */ Y(Ce.Provider, {
|
|
3609
4106
|
"data-slot": "tooltip-provider",
|
|
3610
4107
|
delayDuration: e,
|
|
3611
4108
|
...t
|
|
3612
4109
|
});
|
|
3613
4110
|
}
|
|
3614
|
-
function
|
|
3615
|
-
return /* @__PURE__ */
|
|
4111
|
+
function pa({ ...e }) {
|
|
4112
|
+
return /* @__PURE__ */ Y(Ce.Root, {
|
|
3616
4113
|
"data-slot": "tooltip",
|
|
3617
4114
|
...e
|
|
3618
4115
|
});
|
|
3619
4116
|
}
|
|
3620
|
-
function
|
|
3621
|
-
return /* @__PURE__ */
|
|
4117
|
+
function ma({ ...e }) {
|
|
4118
|
+
return /* @__PURE__ */ Y(Ce.Trigger, {
|
|
3622
4119
|
"data-slot": "tooltip-trigger",
|
|
3623
4120
|
...e
|
|
3624
4121
|
});
|
|
3625
4122
|
}
|
|
3626
|
-
function
|
|
3627
|
-
return /* @__PURE__ */
|
|
4123
|
+
function ha({ className: e, sideOffset: t = 0, children: n, ...r }) {
|
|
4124
|
+
return /* @__PURE__ */ Y(Ce.Portal, { children: /* @__PURE__ */ X(Ce.Content, {
|
|
3628
4125
|
"data-slot": "tooltip-content",
|
|
3629
4126
|
sideOffset: t,
|
|
3630
|
-
className:
|
|
4127
|
+
className: Q("z-50 inline-flex w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", e),
|
|
3631
4128
|
...r,
|
|
3632
|
-
children: [n, /* @__PURE__ */
|
|
4129
|
+
children: [n, /* @__PURE__ */ Y(Ce.Arrow, { className: "z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground" })]
|
|
3633
4130
|
}) });
|
|
3634
4131
|
}
|
|
3635
4132
|
//#endregion
|
|
3636
|
-
export {
|
|
4133
|
+
export { $e as ActionsMenu, mt as AdvancedInput, nn as AdvancedSelect, On as Alert, jn as AlertAction, An as AlertDescription, Mn as AlertDialog, Hn as AlertDialogAction, Un as AlertDialogCancel, In as AlertDialogContent, Vn as AlertDialogDescription, Rn as AlertDialogFooter, Ln as AlertDialogHeader, zn as AlertDialogMedia, Fn as AlertDialogOverlay, Pn as AlertDialogPortal, Bn as AlertDialogTitle, Nn as AlertDialogTrigger, kn as AlertTitle, Gn as Badge, $ as Button, qn as ButtonGroup, Yn as ButtonGroupSeparator, Jn as ButtonGroupText, hn as Calendar, gn as CalendarDayButton, Xn as Card, er as CardAction, tr as CardContent, $n as CardDescription, nr as CardFooter, Zn as CardHeader, Qn as CardTitle, sr as ChartContainer, dr as ChartLegend, fr as ChartLegendContent, cr as ChartStyle, lr as ChartTooltip, ur as ChartTooltipContent, rn as Checkbox, zt as Command, Bt as CommandDialog, Ut as CommandEmpty, Wt as CommandGroup, Vt as CommandInput, Kt as CommandItem, Ht as CommandList, Gt as CommandSeparator, qt as CommandShortcut, mn as DataTable, En as DateTimeRangePicker, yt as Dialog, St as DialogClose, wt as DialogContent, Ot as DialogDescription, Et as DialogFooter, Tt as DialogHeader, Ct as DialogOverlay, xt as DialogPortal, Dt as DialogTitle, bt as DialogTrigger, Ie as DropdownMenu, He as DropdownMenuCheckboxItem, ze as DropdownMenuContent, Be as DropdownMenuGroup, Ve as DropdownMenuItem, Ge as DropdownMenuLabel, Le as DropdownMenuPortal, Ue as DropdownMenuRadioGroup, We as DropdownMenuRadioItem, Ke as DropdownMenuSeparator, qe as DropdownMenuShortcut, Je as DropdownMenuSub, Xe as DropdownMenuSubContent, Ye as DropdownMenuSubTrigger, Re as DropdownMenuTrigger, ot as Field, st as FieldContent, ut as FieldDescription, ft as FieldError, it as FieldGroup, ct as FieldLabel, rt as FieldLegend, dt as FieldSeparator, nt as FieldSet, lt as FieldTitle, vt as FileUpload, mr as HoverCard, gr as HoverCardContent, hr as HoverCardTrigger, kt as Input, jt as InputGroup, Nt as InputGroupAddon, Ft as InputGroupButton, Lt as InputGroupInput, It as InputGroupText, Rt as InputGroupTextarea, br as Item, Er as ItemActions, Cr as ItemContent, Tr as ItemDescription, Or as ItemFooter, _r as ItemGroup, Dr as ItemHeader, Sr as ItemMedia, vr as ItemSeparator, wr as ItemTitle, et as Label, Fr as Map, si as MapArc, ci as MapClusterLayer, Yr as MapControls, Rr as MapMarker, Zr as MapPopup, Qr as MapRoute, zr as MarkerContent, Wr as MarkerLabel, Hr as MarkerPopup, Ur as MarkerTooltip, Jt as Popover, Zt as PopoverAnchor, Xt as PopoverContent, en as PopoverDescription, Qt as PopoverHeader, $t as PopoverTitle, Yt as PopoverTrigger, li as Progress, ui as RadioGroup, di as RadioGroupItem, fi as Select, gi as SelectContent, pi as SelectGroup, vi as SelectItem, _i as SelectLabel, xi as SelectScrollDownButton, bi as SelectScrollUpButton, yi as SelectSeparator, hi as SelectTrigger, mi as SelectValue, tt as Separator, Si as Sheet, wi as SheetClose, Di as SheetContent, ji as SheetDescription, ki as SheetFooter, Oi as SheetHeader, Ai as SheetTitle, Ci as SheetTrigger, Mi as Slider, Pe as Spinner, Ri as Stepper, Ui as StepperDescription, Vi as StepperIndicator, zi as StepperItem, Wi as StepperSeparator, Hi as StepperTitle, Bi as StepperTrigger, Gi as Switch, an as Table, sn as TableBody, fn as TableCaption, dn as TableCell, cn as TableFooter, un as TableHead, on as TableHeader, ln as TableRow, Ki as Tabs, Xi as TabsContent, Ji as TabsList, Yi as TabsTrigger, At as Textarea, $i as Timeline, ea as TimelineContent, ta as TimelineDate, na as TimelineHeader, ra as TimelineIndicator, ia as TimelineItem, aa as TimelineSeparator, oa as TimelineTitle, Ni as Toaster, ca as Toggle, ua as ToggleGroup, da as ToggleGroupItem, pa as Tooltip, ha as TooltipContent, fa as TooltipProvider, ma as TooltipTrigger, Wn as badgeVariants, Kn as buttonGroupVariants, Fe as buttonVariants, Q as cn, Me as formatBytes, Sn as navigateRange, xn as presetToRange, qi as tabsListVariants, sa as toggleVariants, Ne as useFileUpload, Mr as useMap };
|
|
3637
4134
|
|
|
3638
4135
|
//# sourceMappingURL=index.js.map
|