florixui 1.13.0 → 1.14.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/dist/index.js +220 -220
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -2,9 +2,9 @@ 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 { AlertCircleIcon as p, AlertTriangle as m, ArrowLeftIcon as h, Calendar as g, Check as _, CheckIcon as v, ChevronDown as y, ChevronDownIcon as b, ChevronLeftIcon as x, ChevronRightIcon as S, ChevronUpIcon as C, ChevronsLeftIcon as w, ChevronsRightIcon as T, CircleCheckIcon as E, CircleDotIcon as D, CircleXIcon as O, Clock as k, Eye as A, EyeOff as j, FileArchiveIcon as M, FileIcon as N, FileSpreadsheetIcon as P, FileTextIcon as F, HeadphonesIcon as I, HomeIcon as ee, ImageIcon as te, ImageUpIcon as
|
|
6
|
-
import { cva as
|
|
7
|
-
import { AlertDialog as
|
|
5
|
+
import { AlertCircleIcon as p, AlertTriangle as m, ArrowLeftIcon as h, Calendar as g, Check as _, CheckIcon as v, ChevronDown as y, ChevronDownIcon as b, ChevronLeftIcon as x, ChevronRightIcon as S, ChevronUpIcon as C, ChevronsLeftIcon as w, ChevronsRightIcon as T, CircleCheckIcon as E, CircleDotIcon as D, CircleXIcon as O, Clock as k, Eye as A, EyeOff as j, FileArchiveIcon as M, FileIcon as N, FileSpreadsheetIcon as P, FileTextIcon as F, HeadphonesIcon as I, HomeIcon as ee, ImageIcon as te, ImageUpIcon as L, InboxIcon as R, InfoIcon as z, Layers as B, Loader2 as ne, Loader2Icon as V, LoaderCircleIcon as re, Locate as H, Maximize as U, Minus as ie, MoreVertical as W, OctagonXIcon as ae, PaintBucketIcon as oe, Plus as se, PlusCircleIcon as ce, PlusIcon as le, RefreshCwIcon as ue, SearchIcon as de, Trash2Icon as fe, TrendingDownIcon as pe, TrendingUpIcon as me, TriangleAlertIcon as he, UploadIcon as ge, VideoIcon as _e, X as ve, XIcon as ye } from "lucide-react";
|
|
6
|
+
import { cva as G } from "class-variance-authority";
|
|
7
|
+
import { AlertDialog as be, Checkbox as xe, Dialog as K, DropdownMenu as q, HoverCard as Se, Label as Ce, Popover as we, Progress as Te, RadioGroup as Ee, Select as J, Separator as De, Slider as Oe, Slot as ke, Switch as Ae, Tabs as je, Toggle as Me, ToggleGroup as Ne, Tooltip as Pe } from "radix-ui";
|
|
8
8
|
import { Fragment as Y, jsx as X, jsxs as Z } from "react/jsx-runtime";
|
|
9
9
|
import { Command as Fe } from "cmdk";
|
|
10
10
|
import * as Ie from "recharts";
|
|
@@ -191,7 +191,7 @@ var Ke = (e, t = 2) => {
|
|
|
191
191
|
//#endregion
|
|
192
192
|
//#region src/components/ui/spinner.tsx
|
|
193
193
|
function Je({ className: e, ...t }) {
|
|
194
|
-
return /* @__PURE__ */ X(
|
|
194
|
+
return /* @__PURE__ */ X(V, {
|
|
195
195
|
role: "status",
|
|
196
196
|
"aria-label": "Loading",
|
|
197
197
|
className: Q("size-4 animate-spin", e),
|
|
@@ -200,7 +200,7 @@ function Je({ className: e, ...t }) {
|
|
|
200
200
|
}
|
|
201
201
|
//#endregion
|
|
202
202
|
//#region src/components/ui/button.tsx
|
|
203
|
-
var Ye =
|
|
203
|
+
var Ye = G("group/button inline-flex shrink-0 items-center justify-center rounded-sm 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", {
|
|
204
204
|
variants: {
|
|
205
205
|
variant: {
|
|
206
206
|
default: "bg-primary text-primary-foreground hover:bg-primary/80",
|
|
@@ -212,12 +212,12 @@ var Ye = W("group/button inline-flex shrink-0 items-center justify-center rounde
|
|
|
212
212
|
},
|
|
213
213
|
size: {
|
|
214
214
|
default: "h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
215
|
-
xs: "h-6 gap-1 rounded-
|
|
216
|
-
sm: "h-7 gap-1 rounded-
|
|
215
|
+
xs: "h-6 gap-1 rounded-sm px-2 text-xs has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",
|
|
216
|
+
sm: "h-7 gap-1 rounded-sm px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
|
|
217
217
|
lg: "h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
|
|
218
218
|
icon: "size-8",
|
|
219
|
-
"icon-xs": "size-6 rounded-
|
|
220
|
-
"icon-sm": "size-7 rounded-
|
|
219
|
+
"icon-xs": "size-6 rounded-sm [&_svg:not([class*='size-'])]:size-3",
|
|
220
|
+
"icon-sm": "size-7 rounded-sm",
|
|
221
221
|
"icon-lg": "size-9"
|
|
222
222
|
}
|
|
223
223
|
},
|
|
@@ -274,7 +274,7 @@ function $e({ className: e, align: t = "start", sideOffset: n = 4, ...r }) {
|
|
|
274
274
|
"data-slot": "dropdown-menu-content",
|
|
275
275
|
sideOffset: n,
|
|
276
276
|
align: t,
|
|
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-
|
|
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-sm 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),
|
|
278
278
|
...r
|
|
279
279
|
}) });
|
|
280
280
|
}
|
|
@@ -289,7 +289,7 @@ function tt({ className: e, inset: t, variant: n = "default", ...r }) {
|
|
|
289
289
|
"data-slot": "dropdown-menu-item",
|
|
290
290
|
"data-inset": t,
|
|
291
291
|
"data-variant": n,
|
|
292
|
-
className: Q("group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-
|
|
292
|
+
className: Q("group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-sm 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),
|
|
293
293
|
...r
|
|
294
294
|
});
|
|
295
295
|
}
|
|
@@ -297,7 +297,7 @@ function nt({ className: e, children: t, checked: n, inset: r, ...i }) {
|
|
|
297
297
|
return /* @__PURE__ */ Z(q.CheckboxItem, {
|
|
298
298
|
"data-slot": "dropdown-menu-checkbox-item",
|
|
299
299
|
"data-inset": r,
|
|
300
|
-
className: Q("relative flex cursor-default items-center gap-1.5 rounded-
|
|
300
|
+
className: Q("relative flex cursor-default items-center gap-1.5 rounded-sm 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),
|
|
301
301
|
checked: n,
|
|
302
302
|
...i,
|
|
303
303
|
children: [/* @__PURE__ */ X("span", {
|
|
@@ -317,7 +317,7 @@ function it({ className: e, children: t, inset: n, ...r }) {
|
|
|
317
317
|
return /* @__PURE__ */ Z(q.RadioItem, {
|
|
318
318
|
"data-slot": "dropdown-menu-radio-item",
|
|
319
319
|
"data-inset": n,
|
|
320
|
-
className: Q("relative flex cursor-default items-center gap-1.5 rounded-
|
|
320
|
+
className: Q("relative flex cursor-default items-center gap-1.5 rounded-sm 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),
|
|
321
321
|
...r,
|
|
322
322
|
children: [/* @__PURE__ */ X("span", {
|
|
323
323
|
className: "pointer-events-none absolute right-2 flex items-center justify-center",
|
|
@@ -358,7 +358,7 @@ function lt({ className: e, inset: t, children: n, ...r }) {
|
|
|
358
358
|
return /* @__PURE__ */ Z(q.SubTrigger, {
|
|
359
359
|
"data-slot": "dropdown-menu-sub-trigger",
|
|
360
360
|
"data-inset": t,
|
|
361
|
-
className: Q("flex cursor-default items-center gap-1.5 rounded-
|
|
361
|
+
className: Q("flex cursor-default items-center gap-1.5 rounded-sm 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),
|
|
362
362
|
...r,
|
|
363
363
|
children: [n, /* @__PURE__ */ X(S, { className: "ml-auto" })]
|
|
364
364
|
});
|
|
@@ -366,7 +366,7 @@ function lt({ className: e, inset: t, children: n, ...r }) {
|
|
|
366
366
|
function ut({ className: e, ...t }) {
|
|
367
367
|
return /* @__PURE__ */ X(q.SubContent, {
|
|
368
368
|
"data-slot": "dropdown-menu-sub-content",
|
|
369
|
-
className: Q("z-50 min-w-[96px] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-
|
|
369
|
+
className: Q("z-50 min-w-[96px] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-sm 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),
|
|
370
370
|
...t
|
|
371
371
|
});
|
|
372
372
|
}
|
|
@@ -376,7 +376,7 @@ var dt = 16;
|
|
|
376
376
|
function ft(e) {
|
|
377
377
|
return e.type === void 0 || e.type === "action";
|
|
378
378
|
}
|
|
379
|
-
function pt({ items: e, trigger: t, triggerIcon: n =
|
|
379
|
+
function pt({ items: e, trigger: t, triggerIcon: n = W, triggerLabel: r = "Open menu", width: i = "10rem", align: a = "end", className: o, open: s, onOpenChange: c }) {
|
|
380
380
|
return /* @__PURE__ */ Z(Xe, {
|
|
381
381
|
open: s,
|
|
382
382
|
onOpenChange: c,
|
|
@@ -416,7 +416,7 @@ function pt({ items: e, trigger: t, triggerIcon: n = H, triggerLabel: r = "Open
|
|
|
416
416
|
}
|
|
417
417
|
//#endregion
|
|
418
418
|
//#region src/components/ui/badge.tsx
|
|
419
|
-
var mt =
|
|
419
|
+
var mt = G("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full 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!", {
|
|
420
420
|
variants: { variant: {
|
|
421
421
|
default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
|
|
422
422
|
secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
|
|
@@ -489,7 +489,7 @@ function bt({ className: e, ...t }) {
|
|
|
489
489
|
...t
|
|
490
490
|
});
|
|
491
491
|
}
|
|
492
|
-
var xt =
|
|
492
|
+
var xt = G("group/field flex w-full gap-2 data-[invalid=true]:text-destructive", {
|
|
493
493
|
variants: { orientation: {
|
|
494
494
|
vertical: "flex-col *:w-full [&>.sr-only]:w-auto",
|
|
495
495
|
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",
|
|
@@ -516,7 +516,7 @@ function Ct({ className: e, ...t }) {
|
|
|
516
516
|
function wt({ className: e, ...t }) {
|
|
517
517
|
return /* @__PURE__ */ X(gt, {
|
|
518
518
|
"data-slot": "field-label",
|
|
519
|
-
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-
|
|
519
|
+
className: Q("group/field-label peer/field-label flex w-fit gap-2 font-normal text-foreground 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-md 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),
|
|
520
520
|
...t
|
|
521
521
|
});
|
|
522
522
|
}
|
|
@@ -601,7 +601,7 @@ function Nt({ className: e, ...t }) {
|
|
|
601
601
|
function Pt({ className: e, children: t, showCloseButton: n = !0, ...r }) {
|
|
602
602
|
return /* @__PURE__ */ Z(jt, { children: [/* @__PURE__ */ X(Nt, {}), /* @__PURE__ */ Z(K.Content, {
|
|
603
603
|
"data-slot": "dialog-content",
|
|
604
|
-
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-
|
|
604
|
+
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-sm 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),
|
|
605
605
|
...r,
|
|
606
606
|
children: [t, n && /* @__PURE__ */ X(K.Close, {
|
|
607
607
|
"data-slot": "dialog-close",
|
|
@@ -610,7 +610,7 @@ function Pt({ className: e, children: t, showCloseButton: n = !0, ...r }) {
|
|
|
610
610
|
variant: "ghost",
|
|
611
611
|
className: "absolute top-2 right-2",
|
|
612
612
|
size: "icon-sm",
|
|
613
|
-
children: [/* @__PURE__ */ X(
|
|
613
|
+
children: [/* @__PURE__ */ X(ye, {}), /* @__PURE__ */ X("span", {
|
|
614
614
|
className: "sr-only",
|
|
615
615
|
children: "Close"
|
|
616
616
|
})]
|
|
@@ -628,7 +628,7 @@ function Ft({ className: e, ...t }) {
|
|
|
628
628
|
function It({ className: e, showCloseButton: t = !1, children: n, ...r }) {
|
|
629
629
|
return /* @__PURE__ */ Z("div", {
|
|
630
630
|
"data-slot": "dialog-footer",
|
|
631
|
-
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-
|
|
631
|
+
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-sm border-t bg-muted/50 p-4 sm:flex-row sm:justify-end", e),
|
|
632
632
|
...r,
|
|
633
633
|
children: [n, t && /* @__PURE__ */ X(K.Close, {
|
|
634
634
|
asChild: !0,
|
|
@@ -659,7 +659,7 @@ function zt({ className: e, type: t, ...n }) {
|
|
|
659
659
|
return /* @__PURE__ */ X("input", {
|
|
660
660
|
type: t,
|
|
661
661
|
"data-slot": "input",
|
|
662
|
-
className: Q("h-8 w-full min-w-0 rounded-
|
|
662
|
+
className: Q("h-8 w-full min-w-0 rounded-md border border-input bg-transparent px-2.5 py-1 text-sm 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/60 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 dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", e),
|
|
663
663
|
...n
|
|
664
664
|
});
|
|
665
665
|
}
|
|
@@ -682,7 +682,7 @@ function Vt({ className: e, ...t }) {
|
|
|
682
682
|
...t
|
|
683
683
|
});
|
|
684
684
|
}
|
|
685
|
-
var Ht =
|
|
685
|
+
var Ht = G("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", {
|
|
686
686
|
variants: { align: {
|
|
687
687
|
"inline-start": "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",
|
|
688
688
|
"inline-end": "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",
|
|
@@ -703,7 +703,7 @@ function Ut({ className: e, align: t = "inline-start", ...n }) {
|
|
|
703
703
|
...n
|
|
704
704
|
});
|
|
705
705
|
}
|
|
706
|
-
var Wt =
|
|
706
|
+
var Wt = G("flex items-center gap-2 text-sm shadow-none", {
|
|
707
707
|
variants: { size: {
|
|
708
708
|
xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",
|
|
709
709
|
sm: "",
|
|
@@ -746,7 +746,7 @@ function Jt({ className: e, ...t }) {
|
|
|
746
746
|
function Yt({ className: e, ...t }) {
|
|
747
747
|
return /* @__PURE__ */ X(Fe, {
|
|
748
748
|
"data-slot": "command",
|
|
749
|
-
className: Q("flex size-full flex-col overflow-hidden rounded-
|
|
749
|
+
className: Q("flex size-full flex-col overflow-hidden rounded-md! bg-popover p-1 text-popover-foreground", e),
|
|
750
750
|
...t
|
|
751
751
|
});
|
|
752
752
|
}
|
|
@@ -757,7 +757,7 @@ function Xt({ title: e = "Command Palette", description: t = "Search for a comma
|
|
|
757
757
|
className: "sr-only",
|
|
758
758
|
children: [/* @__PURE__ */ X(Lt, { children: e }), /* @__PURE__ */ X(Rt, { children: t })]
|
|
759
759
|
}), /* @__PURE__ */ X(Pt, {
|
|
760
|
-
className: Q("top-1/3 translate-y-0 overflow-hidden rounded-
|
|
760
|
+
className: Q("top-1/3 translate-y-0 overflow-hidden rounded-md! p-0", r),
|
|
761
761
|
showCloseButton: i,
|
|
762
762
|
children: n
|
|
763
763
|
})]
|
|
@@ -768,12 +768,12 @@ function Zt({ className: e, ...t }) {
|
|
|
768
768
|
"data-slot": "command-input-wrapper",
|
|
769
769
|
className: "p-1 pb-0",
|
|
770
770
|
children: /* @__PURE__ */ Z(Vt, {
|
|
771
|
-
className: "h-8! rounded-
|
|
771
|
+
className: "h-8! rounded-md! border-input/30 bg-input/30 shadow-none! *:data-[slot=input-group-addon]:pl-2!",
|
|
772
772
|
children: [/* @__PURE__ */ X(Fe.Input, {
|
|
773
773
|
"data-slot": "command-input",
|
|
774
774
|
className: Q("w-full text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
775
775
|
...t
|
|
776
|
-
}), /* @__PURE__ */ X(Ut, { children: /* @__PURE__ */ X(
|
|
776
|
+
}), /* @__PURE__ */ X(Ut, { children: /* @__PURE__ */ X(de, { className: "size-4 shrink-0 opacity-50" }) })]
|
|
777
777
|
})
|
|
778
778
|
});
|
|
779
779
|
}
|
|
@@ -808,7 +808,7 @@ function tn({ className: e, ...t }) {
|
|
|
808
808
|
function nn({ className: e, children: t, ...n }) {
|
|
809
809
|
return /* @__PURE__ */ Z(Fe.Item, {
|
|
810
810
|
"data-slot": "command-item",
|
|
811
|
-
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-
|
|
811
|
+
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-sm! 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),
|
|
812
812
|
...n,
|
|
813
813
|
children: [t, /* @__PURE__ */ X(v, { className: "ml-auto opacity-0 group-has-data-[slot=command-shortcut]/command-item:hidden group-data-[checked=true]/command-item:opacity-100" })]
|
|
814
814
|
});
|
|
@@ -839,7 +839,7 @@ function sn({ className: e, align: t = "center", sideOffset: n = 4, ...r }) {
|
|
|
839
839
|
"data-slot": "popover-content",
|
|
840
840
|
align: t,
|
|
841
841
|
sideOffset: n,
|
|
842
|
-
className: Q("z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-
|
|
842
|
+
className: Q("z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-md 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),
|
|
843
843
|
...r
|
|
844
844
|
}) });
|
|
845
845
|
}
|
|
@@ -1154,7 +1154,7 @@ var mn = n.forwardRef(function(e, t) {
|
|
|
1154
1154
|
S && s ? D : null,
|
|
1155
1155
|
!S && c ? O : null,
|
|
1156
1156
|
o ? k : null
|
|
1157
|
-
].filter(Boolean).join(" ") || void 0, N = d === "alt" ? "bg-
|
|
1157
|
+
].filter(Boolean).join(" ") || void 0, N = d === "alt" ? "bg-input-background-alt" : "bg-input-background", P = l ? /* @__PURE__ */ X("span", {
|
|
1158
1158
|
"aria-hidden": !0,
|
|
1159
1159
|
className: "ml-0.5 text-destructive",
|
|
1160
1160
|
children: "*"
|
|
@@ -1175,7 +1175,7 @@ var mn = n.forwardRef(function(e, t) {
|
|
|
1175
1175
|
disabled: m,
|
|
1176
1176
|
"aria-invalid": S,
|
|
1177
1177
|
"aria-describedby": M,
|
|
1178
|
-
className: Q("flex min-h-20 w-full rounded-
|
|
1178
|
+
className: Q("flex min-h-20 w-full rounded-sm border border-border px-3 py-2 text-base outline-none transition-[color,box-shadow] placeholder:text-foreground/50 md:text-sm", N, "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),
|
|
1179
1179
|
...e
|
|
1180
1180
|
}),
|
|
1181
1181
|
/* @__PURE__ */ X(pn, {
|
|
@@ -1192,24 +1192,24 @@ var mn = n.forwardRef(function(e, t) {
|
|
|
1192
1192
|
]
|
|
1193
1193
|
});
|
|
1194
1194
|
}
|
|
1195
|
-
let { type: F, onFocus: I, ...ee } = x, te = F ?? "text",
|
|
1195
|
+
let { type: F, onFocus: I, ...ee } = x, te = F ?? "text", L = te === "password", R = L && T ? "text" : te, z = L ? /* @__PURE__ */ X("button", {
|
|
1196
1196
|
type: "button",
|
|
1197
1197
|
onClick: () => E((e) => !e),
|
|
1198
1198
|
"aria-label": T ? "Hide password" : "Show password",
|
|
1199
1199
|
className: "cursor-pointer text-muted-foreground transition-colors hover:text-foreground",
|
|
1200
1200
|
tabIndex: -1,
|
|
1201
1201
|
children: X(T ? j : A, { className: "size-4" })
|
|
1202
|
-
}) : null,
|
|
1203
|
-
|
|
1204
|
-
},
|
|
1202
|
+
}) : null, B = _ ? /* @__PURE__ */ X(ne, { className: "size-4 animate-spin text-muted-foreground" }) : f, V = L ? z : p, re = (e) => {
|
|
1203
|
+
R === "number" && e.target.select(), I?.(e);
|
|
1204
|
+
}, H = !!(h || g), U = /* @__PURE__ */ X("input", {
|
|
1205
1205
|
id: w,
|
|
1206
|
-
type:
|
|
1206
|
+
type: R,
|
|
1207
1207
|
ref: t,
|
|
1208
1208
|
disabled: m,
|
|
1209
1209
|
"aria-invalid": S,
|
|
1210
1210
|
"aria-describedby": M,
|
|
1211
|
-
onFocus:
|
|
1212
|
-
className: Q("w-full min-w-0 bg-transparent text-
|
|
1211
|
+
onFocus: re,
|
|
1212
|
+
className: Q("w-full min-w-0 bg-transparent text-base text-foreground outline-none placeholder:text-foreground/50 disabled:cursor-not-allowed md:text-sm", H ? "h-full border-0 py-1 focus-visible:ring-0" : Q("rounded-sm border border-border pl-3 pr-3 py-1 transition-[color,box-shadow]", N, u === "default" ? "h-8.5" : "h-7", "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", B && "pl-9", V && "pr-9"), H && (h ? "pl-0" : "pl-3"), H && (g ? "pr-0" : "pr-3"), H && B && !h && "pl-9", H && V && !g && "pr-9", H && B && h && "pl-6", H && V && g && "pr-6", r),
|
|
1213
1213
|
...ee
|
|
1214
1214
|
});
|
|
1215
1215
|
return /* @__PURE__ */ Z("div", {
|
|
@@ -1220,44 +1220,44 @@ var mn = n.forwardRef(function(e, t) {
|
|
|
1220
1220
|
className: Q(m && "text-muted-foreground"),
|
|
1221
1221
|
children: [a, P]
|
|
1222
1222
|
}),
|
|
1223
|
-
|
|
1223
|
+
H ? /* @__PURE__ */ Z("div", {
|
|
1224
1224
|
"aria-invalid": S,
|
|
1225
|
-
className: Q("flex items-center overflow-hidden rounded-
|
|
1225
|
+
className: Q("flex items-center overflow-hidden rounded-sm border border-border transition-[color,box-shadow]", N, 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"),
|
|
1226
1226
|
children: [
|
|
1227
1227
|
h && /* @__PURE__ */ X("div", {
|
|
1228
|
-
className: "flex h-full shrink-0 items-center justify-center
|
|
1228
|
+
className: "flex h-full shrink-0 items-center justify-center pl-3 pr-2 text-sm text-muted-foreground [&_svg]:size-4",
|
|
1229
1229
|
children: h
|
|
1230
1230
|
}),
|
|
1231
1231
|
/* @__PURE__ */ Z("div", {
|
|
1232
1232
|
className: "relative flex h-full flex-1 items-center",
|
|
1233
1233
|
children: [
|
|
1234
|
-
|
|
1234
|
+
B && /* @__PURE__ */ X("div", {
|
|
1235
1235
|
className: "pointer-events-none absolute left-3 flex items-center text-muted-foreground [&_svg]:size-4",
|
|
1236
|
-
children:
|
|
1236
|
+
children: B
|
|
1237
1237
|
}),
|
|
1238
|
-
|
|
1239
|
-
|
|
1238
|
+
U,
|
|
1239
|
+
V && /* @__PURE__ */ X("div", {
|
|
1240
1240
|
className: "absolute right-3 z-10 flex items-center",
|
|
1241
|
-
children:
|
|
1241
|
+
children: V
|
|
1242
1242
|
})
|
|
1243
1243
|
]
|
|
1244
1244
|
}),
|
|
1245
1245
|
g && /* @__PURE__ */ X("div", {
|
|
1246
|
-
className: "flex h-full shrink-0 items-center justify-center
|
|
1246
|
+
className: "flex h-full shrink-0 items-center justify-center pl-2 pr-3 text-sm text-foreground [&_svg]:size-4",
|
|
1247
1247
|
children: g
|
|
1248
1248
|
})
|
|
1249
1249
|
]
|
|
1250
1250
|
}) : /* @__PURE__ */ Z("div", {
|
|
1251
1251
|
className: "relative",
|
|
1252
1252
|
children: [
|
|
1253
|
-
|
|
1253
|
+
B && /* @__PURE__ */ X("div", {
|
|
1254
1254
|
className: "pointer-events-none absolute left-3 top-1/2 flex -translate-y-1/2 items-center text-muted-foreground [&_svg]:size-4",
|
|
1255
|
-
children:
|
|
1255
|
+
children: B
|
|
1256
1256
|
}),
|
|
1257
|
-
|
|
1258
|
-
|
|
1257
|
+
U,
|
|
1258
|
+
V && /* @__PURE__ */ X("div", {
|
|
1259
1259
|
className: "absolute right-3 top-1/2 z-10 flex -translate-y-1/2 items-center",
|
|
1260
|
-
children:
|
|
1260
|
+
children: V
|
|
1261
1261
|
})
|
|
1262
1262
|
]
|
|
1263
1263
|
}),
|
|
@@ -1289,12 +1289,12 @@ function hn({ children: e, onRemove: t, disabled: n }) {
|
|
|
1289
1289
|
onClick: t,
|
|
1290
1290
|
tabIndex: -1,
|
|
1291
1291
|
className: "flex size-3.5 items-center justify-center rounded-sm text-primary-foreground/80 transition-colors hover:bg-primary-foreground/20 hover:text-primary-foreground",
|
|
1292
|
-
children: /* @__PURE__ */ X(
|
|
1292
|
+
children: /* @__PURE__ */ X(ye, { className: "size-3" })
|
|
1293
1293
|
})]
|
|
1294
1294
|
});
|
|
1295
1295
|
}
|
|
1296
1296
|
function gn({ value: e, onChange: t, label: r, description: i, errorMessage: a, helperText: o, required: s = !1, size: c = "default", variant: l = "default", disabled: u, placeholder: d = "Add and press Enter…", badgePosition: f = "inside", separators: p = [",", "Enter"], dedupe: m = !0, maxTags: h, error: g, className: _, wrapperClassName: v, id: y }) {
|
|
1297
|
-
let [b, x] = n.useState(""), S = n.useRef(null), C = n.useId(), w = y || C, T = `${w}-error`, E = `${w}-helper`, D = `${w}-description`, O = g ?? !!a, k = l === "alt" ? "bg-
|
|
1297
|
+
let [b, x] = n.useState(""), S = n.useRef(null), C = n.useId(), w = y || C, T = `${w}-error`, E = `${w}-helper`, D = `${w}-description`, O = g ?? !!a, k = l === "alt" ? "bg-input-background-alt" : "bg-input-background", A = f === "inside", j = (n) => {
|
|
1298
1298
|
let r = n.trim();
|
|
1299
1299
|
r && (m && e.some((e) => e.toLowerCase() === r.toLowerCase()) || h != null && e.length >= h || t([...e, r]));
|
|
1300
1300
|
}, M = () => {
|
|
@@ -1315,7 +1315,7 @@ function gn({ value: e, onChange: t, label: r, description: i, errorMessage: a,
|
|
|
1315
1315
|
/* @__PURE__ */ Z("div", {
|
|
1316
1316
|
onClick: () => S.current?.focus(),
|
|
1317
1317
|
"aria-invalid": O,
|
|
1318
|
-
className: Q("flex w-full cursor-text rounded-
|
|
1318
|
+
className: Q("flex w-full cursor-text rounded-sm border border-border transition-[color,box-shadow]", k, "focus-within:border-ring focus-within:ring-3 focus-within:ring-ring/50", "aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40", u && "cursor-not-allowed opacity-50", A ? "min-h-9 flex-wrap items-center gap-1.5 px-2 py-1.5" : Q("items-center px-3", c === "default" ? "h-9" : "h-8"), _),
|
|
1319
1319
|
children: [A && e.map((e, t) => /* @__PURE__ */ X(hn, {
|
|
1320
1320
|
onRemove: () => N(t),
|
|
1321
1321
|
disabled: u,
|
|
@@ -1339,7 +1339,7 @@ function gn({ value: e, onChange: t, label: r, description: i, errorMessage: a,
|
|
|
1339
1339
|
placeholder: e.length === 0 || !A ? d : "",
|
|
1340
1340
|
"aria-invalid": O,
|
|
1341
1341
|
"aria-describedby": O && a ? T : void 0,
|
|
1342
|
-
className: "min-w-24 flex-1 bg-transparent text-
|
|
1342
|
+
className: "min-w-24 flex-1 bg-transparent text-base text-foreground outline-none placeholder:text-foreground/50 disabled:cursor-not-allowed md:text-sm"
|
|
1343
1343
|
})]
|
|
1344
1344
|
}),
|
|
1345
1345
|
!A && e.length > 0 && /* @__PURE__ */ X("div", {
|
|
@@ -1374,7 +1374,7 @@ function _n({ country: e, countries: t, onSelect: r, disabled: i }) {
|
|
|
1374
1374
|
children: /* @__PURE__ */ Z("button", {
|
|
1375
1375
|
type: "button",
|
|
1376
1376
|
disabled: i,
|
|
1377
|
-
className: "-
|
|
1377
|
+
className: "-ml-3 -mr-2 flex h-full items-center gap-1.5 pl-3 pr-2 text-sm text-foreground outline-none transition-colors hover:bg-muted focus-visible:bg-muted disabled:pointer-events-none",
|
|
1378
1378
|
children: [
|
|
1379
1379
|
/* @__PURE__ */ X("span", {
|
|
1380
1380
|
className: "text-base leading-none",
|
|
@@ -1450,14 +1450,14 @@ vn.displayName = "PhoneInput";
|
|
|
1450
1450
|
//#region src/components/custom/alert-card.tsx
|
|
1451
1451
|
var yn = {
|
|
1452
1452
|
info: {
|
|
1453
|
-
icon:
|
|
1453
|
+
icon: z,
|
|
1454
1454
|
badge: "blue",
|
|
1455
1455
|
filled: "border-blue/30 bg-blue/10 text-blue",
|
|
1456
1456
|
iconBox: "bg-blue/10 text-blue",
|
|
1457
1457
|
actionBtn: "bg-blue text-white hover:bg-blue/90"
|
|
1458
1458
|
},
|
|
1459
1459
|
warning: {
|
|
1460
|
-
icon:
|
|
1460
|
+
icon: he,
|
|
1461
1461
|
badge: "orange",
|
|
1462
1462
|
filled: "border-orange/30 bg-orange/10 text-orange",
|
|
1463
1463
|
iconBox: "bg-orange/10 text-orange",
|
|
@@ -1484,7 +1484,7 @@ function bn({ severity: e = "info", variant: t = "filled", icon: n, title: r, de
|
|
|
1484
1484
|
"aria-label": "Dismiss",
|
|
1485
1485
|
onClick: c,
|
|
1486
1486
|
className: "-mr-1 -mt-0.5 flex size-6 shrink-0 items-center justify-center rounded-md text-current/60 transition-colors hover:bg-current/10 hover:text-current",
|
|
1487
|
-
children: /* @__PURE__ */ X(
|
|
1487
|
+
children: /* @__PURE__ */ X(ye, { className: "size-3.5" })
|
|
1488
1488
|
});
|
|
1489
1489
|
return t === "filled" ? /* @__PURE__ */ Z("div", {
|
|
1490
1490
|
role: "alert",
|
|
@@ -1580,7 +1580,7 @@ var Sn = [
|
|
|
1580
1580
|
},
|
|
1581
1581
|
{
|
|
1582
1582
|
match: (e) => e.includes("video/"),
|
|
1583
|
-
Icon:
|
|
1583
|
+
Icon: _e
|
|
1584
1584
|
}
|
|
1585
1585
|
];
|
|
1586
1586
|
function Cn(e) {
|
|
@@ -1644,7 +1644,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1644
1644
|
/* @__PURE__ */ X("div", {
|
|
1645
1645
|
"aria-hidden": "true",
|
|
1646
1646
|
className: "mb-2 flex size-11 shrink-0 items-center justify-center rounded-full border bg-background",
|
|
1647
|
-
children: /* @__PURE__ */ X(
|
|
1647
|
+
children: /* @__PURE__ */ X(L, { className: "size-4 opacity-60" })
|
|
1648
1648
|
}),
|
|
1649
1649
|
/* @__PURE__ */ X("p", {
|
|
1650
1650
|
className: "mb-1.5 font-medium text-sm",
|
|
@@ -1663,7 +1663,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1663
1663
|
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",
|
|
1664
1664
|
onClick: () => t && v(t.id),
|
|
1665
1665
|
type: "button",
|
|
1666
|
-
children: /* @__PURE__ */ X(
|
|
1666
|
+
children: /* @__PURE__ */ X(ye, {
|
|
1667
1667
|
"aria-hidden": "true",
|
|
1668
1668
|
className: "size-4"
|
|
1669
1669
|
})
|
|
@@ -1704,7 +1704,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1704
1704
|
onClick: _,
|
|
1705
1705
|
size: "sm",
|
|
1706
1706
|
variant: "outline",
|
|
1707
|
-
children: [/* @__PURE__ */ X(
|
|
1707
|
+
children: [/* @__PURE__ */ X(ge, {
|
|
1708
1708
|
"aria-hidden": "true",
|
|
1709
1709
|
className: "-ms-0.5 size-3.5 opacity-60"
|
|
1710
1710
|
}), "Add files"]
|
|
@@ -1713,7 +1713,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1713
1713
|
onClick: y,
|
|
1714
1714
|
size: "sm",
|
|
1715
1715
|
variant: "outline",
|
|
1716
|
-
children: [/* @__PURE__ */ X(
|
|
1716
|
+
children: [/* @__PURE__ */ X(fe, {
|
|
1717
1717
|
"aria-hidden": "true",
|
|
1718
1718
|
className: "-ms-0.5 size-3.5 opacity-60"
|
|
1719
1719
|
}), "Remove all"]
|
|
@@ -1730,7 +1730,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1730
1730
|
className: "-top-2 -right-2 absolute size-6 rounded-full border-2 border-background shadow-none focus-visible:border-background",
|
|
1731
1731
|
onClick: () => v(e.id),
|
|
1732
1732
|
size: "icon",
|
|
1733
|
-
children: /* @__PURE__ */ X(
|
|
1733
|
+
children: /* @__PURE__ */ X(ye, { className: "size-3.5" })
|
|
1734
1734
|
}),
|
|
1735
1735
|
/* @__PURE__ */ Z("div", {
|
|
1736
1736
|
className: "flex min-w-0 flex-col gap-0.5 border-t p-3",
|
|
@@ -1771,7 +1771,7 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1771
1771
|
disabled: o,
|
|
1772
1772
|
onClick: _,
|
|
1773
1773
|
variant: "outline",
|
|
1774
|
-
children: [/* @__PURE__ */ X(
|
|
1774
|
+
children: [/* @__PURE__ */ X(ge, {
|
|
1775
1775
|
"aria-hidden": "true",
|
|
1776
1776
|
className: "-ms-1 opacity-60"
|
|
1777
1777
|
}), "Select files"]
|
|
@@ -1786,16 +1786,16 @@ function Tn({ variant: e = "image", accept: t = "image/*", maxSize: n = 5 * 1024
|
|
|
1786
1786
|
function En(e) {
|
|
1787
1787
|
return typeof e == "object" && !!e && "value" in e && "label" in e;
|
|
1788
1788
|
}
|
|
1789
|
-
function Dn({ 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: g, renderOptionLabel: _, label: y, description: x, required: S = !1, onCreateNew: C, createNewLabel: w = "New item", loading: T = !1, compactMultiple: E = !1, formatCompactDisplay: D, startItem: O, endItem: k, maxSelections: A, defaultOpen: j = !1, onOpenChange: M, onLoadMore: N, hasNextPage: P = !1, isFetchingNextPage: F = !1, allowEmpty: I = !1, showSelectAll: ee = !1, readOnly: te = !1, popoverClassName:
|
|
1790
|
-
let [
|
|
1791
|
-
te && e || (
|
|
1792
|
-
}, [M, te]), [
|
|
1789
|
+
function Dn({ 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: g, renderOptionLabel: _, label: y, description: x, required: S = !1, onCreateNew: C, createNewLabel: w = "New item", loading: T = !1, compactMultiple: E = !1, formatCompactDisplay: D, startItem: O, endItem: k, maxSelections: A, defaultOpen: j = !1, onOpenChange: M, onLoadMore: N, hasNextPage: P = !1, isFetchingNextPage: F = !1, allowEmpty: I = !1, showSelectAll: ee = !1, readOnly: te = !1, popoverClassName: L }) {
|
|
1790
|
+
let [R, z] = n.useState(j), B = n.useRef(!1), V = n.useRef(null), re = n.useId(), H = n.useCallback((e) => {
|
|
1791
|
+
te && e || (z(e), M?.(e), e && (B.current = !1));
|
|
1792
|
+
}, [M, te]), [U, ie] = n.useState(l ? Array.isArray(r) ? r : r ? [r] : [] : []);
|
|
1793
1793
|
n.useEffect(() => {
|
|
1794
|
-
l &&
|
|
1794
|
+
l && ie(Array.isArray(r) ? r : r ? [r] : []);
|
|
1795
1795
|
}, [l, r]), n.useEffect(() => {
|
|
1796
|
-
F || (
|
|
1796
|
+
F || (B.current = !1);
|
|
1797
1797
|
}, [F]);
|
|
1798
|
-
let
|
|
1798
|
+
let W = n.useCallback((e) => typeof e == "string" ? e : g ? g(e) : En(e) ? e.value : String(e), [g]), ae = n.useCallback((n) => {
|
|
1799
1799
|
if (typeof n == "string") {
|
|
1800
1800
|
for (let e of t) {
|
|
1801
1801
|
let t = e.options.find((e) => e.value === n);
|
|
@@ -1811,25 +1811,25 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1811
1811
|
h,
|
|
1812
1812
|
t,
|
|
1813
1813
|
e
|
|
1814
|
-
]),
|
|
1814
|
+
]), oe = n.useMemo(() => l || !r ? "" : typeof r == "string" ? r : Array.isArray(r) ? "" : W(r), [
|
|
1815
1815
|
l,
|
|
1816
1816
|
r,
|
|
1817
|
-
|
|
1818
|
-
]),
|
|
1817
|
+
W
|
|
1818
|
+
]), se = n.useMemo(() => e.map((e) => typeof e == "string" ? {
|
|
1819
1819
|
value: e,
|
|
1820
1820
|
label: e
|
|
1821
1821
|
} : En(e) ? e : {
|
|
1822
|
-
value:
|
|
1823
|
-
label:
|
|
1822
|
+
value: W(e),
|
|
1823
|
+
label: ae(e)
|
|
1824
1824
|
}), [
|
|
1825
1825
|
e,
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
]),
|
|
1829
|
-
let e = [...
|
|
1826
|
+
ae,
|
|
1827
|
+
W
|
|
1828
|
+
]), ce = n.useCallback((t) => e.find((e) => W(e) === t), [e, W]), ue = n.useMemo(() => {
|
|
1829
|
+
let e = [...se];
|
|
1830
1830
|
return t.forEach((t) => e.push(...t.options)), e;
|
|
1831
|
-
}, [
|
|
1832
|
-
let r = e.find((e) =>
|
|
1831
|
+
}, [se, t]), de = (n) => {
|
|
1832
|
+
let r = e.find((e) => W(e) === n);
|
|
1833
1833
|
if (r === void 0 && t.length > 0) for (let e of t) {
|
|
1834
1834
|
let t = e.options.find((e) => e.value === n);
|
|
1835
1835
|
if (t) {
|
|
@@ -1838,77 +1838,77 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1838
1838
|
}
|
|
1839
1839
|
}
|
|
1840
1840
|
if (l) {
|
|
1841
|
-
let e =
|
|
1842
|
-
if (!e && A &&
|
|
1843
|
-
let t = e ?
|
|
1844
|
-
|
|
1845
|
-
} else i?.(r),
|
|
1846
|
-
},
|
|
1841
|
+
let e = U.some((e) => W(e) === n);
|
|
1842
|
+
if (!e && A && U.length >= A || e && U.length === 1 && !I) return;
|
|
1843
|
+
let t = e ? U.filter((e) => W(e) !== n) : [...U, r];
|
|
1844
|
+
ie(t), i?.(t);
|
|
1845
|
+
} else i?.(r), z(!1);
|
|
1846
|
+
}, fe = l && ue.length > 0 && ue.length === U.length, pe = () => {
|
|
1847
1847
|
if (l) {
|
|
1848
|
-
if (
|
|
1849
|
-
I && (
|
|
1848
|
+
if (fe) {
|
|
1849
|
+
I && (ie([]), i?.([]));
|
|
1850
1850
|
return;
|
|
1851
1851
|
}
|
|
1852
|
-
A &&
|
|
1852
|
+
A && ue.length > A || (ie(ue), i?.(ue));
|
|
1853
1853
|
}
|
|
1854
|
-
},
|
|
1855
|
-
e.stopPropagation(), l ? (
|
|
1856
|
-
},
|
|
1857
|
-
if (e.stopPropagation(),
|
|
1858
|
-
let n =
|
|
1859
|
-
|
|
1860
|
-
},
|
|
1854
|
+
}, me = (e) => {
|
|
1855
|
+
e.stopPropagation(), l ? (ie([]), i?.([])) : i?.("");
|
|
1856
|
+
}, he = (e, t) => {
|
|
1857
|
+
if (e.stopPropagation(), U.length === 1 && !I) return;
|
|
1858
|
+
let n = U.filter((e) => W(e) !== W(t));
|
|
1859
|
+
ie(n), i?.(n);
|
|
1860
|
+
}, ge = n.useCallback((e) => {
|
|
1861
1861
|
let t = e.currentTarget;
|
|
1862
|
-
t.scrollHeight - t.scrollTop - t.clientHeight < 100 && N && P && !F && !
|
|
1862
|
+
t.scrollHeight - t.scrollTop - t.clientHeight < 100 && N && P && !F && !B.current && (B.current = !0, N());
|
|
1863
1863
|
}, [
|
|
1864
1864
|
N,
|
|
1865
1865
|
P,
|
|
1866
1866
|
F
|
|
1867
|
-
]),
|
|
1868
|
-
!o && !te && (
|
|
1869
|
-
},
|
|
1867
|
+
]), _e = l ? U.length > 0 : !!oe, ve = () => l ? null : ue.find((e) => e.value === oe)?.label || a, G = () => {
|
|
1868
|
+
!o && !te && (V.current?.focus(), z(!0));
|
|
1869
|
+
}, be = !!(O || k), xe = l && !E, K = xe ? d === "default" ? "min-h-9" : "min-h-8" : d === "default" ? "h-9" : "h-8", q = f === "alt" ? "bg-muted" : "bg-transparent dark:bg-input/30", Se = /* @__PURE__ */ X("div", {
|
|
1870
1870
|
className: Q("flex min-w-0 flex-1 items-center gap-1.5", xe ? "py-1" : "overflow-hidden"),
|
|
1871
|
-
children: l &&
|
|
1871
|
+
children: l && U.length > 0 ? E ? /* @__PURE__ */ X("span", {
|
|
1872
1872
|
className: "min-w-0 truncate",
|
|
1873
|
-
children: D ? D(
|
|
1873
|
+
children: D ? D(U) : `${U.length} selected`
|
|
1874
1874
|
}) : /* @__PURE__ */ X("div", {
|
|
1875
1875
|
className: "flex flex-wrap items-center gap-1.5",
|
|
1876
|
-
children:
|
|
1876
|
+
children: U.map((e, t) => /* @__PURE__ */ Z("span", {
|
|
1877
1877
|
className: "inline-flex items-center gap-1 rounded-sm bg-primary px-2 py-0.5 text-xs font-normal text-primary-foreground",
|
|
1878
|
-
children: [
|
|
1878
|
+
children: [ae(e), !o && /* @__PURE__ */ X("button", {
|
|
1879
1879
|
type: "button",
|
|
1880
|
-
"aria-label": `Remove ${
|
|
1881
|
-
onClick: (t) =>
|
|
1880
|
+
"aria-label": `Remove ${ae(e)}`,
|
|
1881
|
+
onClick: (t) => he(t, e),
|
|
1882
1882
|
className: "rounded-sm transition-colors hover:bg-primary/80",
|
|
1883
|
-
children: /* @__PURE__ */ X(
|
|
1883
|
+
children: /* @__PURE__ */ X(ye, { className: "size-3" })
|
|
1884
1884
|
})]
|
|
1885
|
-
}, `${
|
|
1885
|
+
}, `${W(e)}-${t}`))
|
|
1886
1886
|
}) : /* @__PURE__ */ X("span", {
|
|
1887
|
-
className: Q("block min-w-0 truncate", !
|
|
1888
|
-
children:
|
|
1887
|
+
className: Q("block min-w-0 truncate", !_e && "text-muted-foreground/60"),
|
|
1888
|
+
children: ve() || a
|
|
1889
1889
|
})
|
|
1890
1890
|
}), Ce = /* @__PURE__ */ Z("div", {
|
|
1891
1891
|
className: "flex shrink-0 items-center gap-1",
|
|
1892
|
-
children: [m &&
|
|
1892
|
+
children: [m && _e && !o && /* @__PURE__ */ X("span", {
|
|
1893
1893
|
role: "button",
|
|
1894
1894
|
tabIndex: 0,
|
|
1895
1895
|
"aria-label": "Clear",
|
|
1896
|
-
onClick:
|
|
1896
|
+
onClick: me,
|
|
1897
1897
|
onKeyDown: (e) => {
|
|
1898
|
-
(e.key === "Enter" || e.key === " ") && (e.stopPropagation(),
|
|
1898
|
+
(e.key === "Enter" || e.key === " ") && (e.stopPropagation(), me(e));
|
|
1899
1899
|
},
|
|
1900
1900
|
className: "cursor-pointer rounded-sm p-0.5 transition-colors hover:bg-accent",
|
|
1901
|
-
children: /* @__PURE__ */ X(
|
|
1901
|
+
children: /* @__PURE__ */ X(ye, { className: "size-3.5" })
|
|
1902
1902
|
}), /* @__PURE__ */ X(b, {
|
|
1903
1903
|
size: 16,
|
|
1904
1904
|
className: "shrink-0 opacity-60",
|
|
1905
1905
|
"aria-hidden": !0
|
|
1906
1906
|
})]
|
|
1907
1907
|
}), we = (e) => {
|
|
1908
|
-
let t = l ?
|
|
1908
|
+
let t = l ? U.some((t) => W(t) === e.value) : oe === e.value, n = ce(e.value);
|
|
1909
1909
|
return /* @__PURE__ */ Z(nn, {
|
|
1910
1910
|
value: e.value,
|
|
1911
|
-
onSelect: () =>
|
|
1911
|
+
onSelect: () => de(e.value),
|
|
1912
1912
|
disabled: e.disabled,
|
|
1913
1913
|
children: [
|
|
1914
1914
|
l ? /* @__PURE__ */ X("div", {
|
|
@@ -1951,7 +1951,7 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1951
1951
|
]
|
|
1952
1952
|
}, e.value);
|
|
1953
1953
|
}, Te = /* @__PURE__ */ X(sn, {
|
|
1954
|
-
className: Q("w-(--radix-popper-anchor-width) min-w-(--radix-popper-anchor-width) p-0",
|
|
1954
|
+
className: Q("w-(--radix-popper-anchor-width) min-w-(--radix-popper-anchor-width) p-0", L),
|
|
1955
1955
|
align: "start",
|
|
1956
1956
|
onOpenAutoFocus: (e) => {
|
|
1957
1957
|
p || e.preventDefault();
|
|
@@ -1961,18 +1961,18 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1961
1961
|
placeholder: `Search ${a.toLowerCase()}...`,
|
|
1962
1962
|
autoFocus: !0
|
|
1963
1963
|
}), /* @__PURE__ */ X(Qt, {
|
|
1964
|
-
onScroll:
|
|
1964
|
+
onScroll: ge,
|
|
1965
1965
|
children: T ? /* @__PURE__ */ X("div", {
|
|
1966
1966
|
className: "flex items-center justify-center py-6",
|
|
1967
|
-
children: /* @__PURE__ */ X(
|
|
1967
|
+
children: /* @__PURE__ */ X(ne, { className: "size-5 animate-spin text-muted-foreground" })
|
|
1968
1968
|
}) : /* @__PURE__ */ Z(Y, { children: [
|
|
1969
|
-
l && ee &&
|
|
1969
|
+
l && ee && ue.length > 0 && /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(en, { children: /* @__PURE__ */ Z(nn, {
|
|
1970
1970
|
value: "__select_all__",
|
|
1971
|
-
onSelect:
|
|
1971
|
+
onSelect: pe,
|
|
1972
1972
|
className: "font-medium",
|
|
1973
1973
|
children: [/* @__PURE__ */ X("div", {
|
|
1974
|
-
className: Q("flex size-4 shrink-0 items-center justify-center rounded-sm border",
|
|
1975
|
-
children:
|
|
1974
|
+
className: Q("flex size-4 shrink-0 items-center justify-center rounded-sm border", fe ? "border-primary bg-primary" : "border-input"),
|
|
1975
|
+
children: fe && /* @__PURE__ */ X(v, {
|
|
1976
1976
|
size: 12,
|
|
1977
1977
|
className: "text-primary-foreground"
|
|
1978
1978
|
})
|
|
@@ -1982,14 +1982,14 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1982
1982
|
t.length > 0 ? t.map((e, t) => /* @__PURE__ */ Z(n.Fragment, { children: [t > 0 && /* @__PURE__ */ X(tn, {}), /* @__PURE__ */ X(en, {
|
|
1983
1983
|
heading: e.label,
|
|
1984
1984
|
children: e.options.map(we)
|
|
1985
|
-
})] }, e.label)) : /* @__PURE__ */ X(en, { children:
|
|
1985
|
+
})] }, e.label)) : /* @__PURE__ */ X(en, { children: se.map(we) }),
|
|
1986
1986
|
C && /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(tn, {}), /* @__PURE__ */ X(en, { children: /* @__PURE__ */ Z($, {
|
|
1987
1987
|
variant: "ghost",
|
|
1988
1988
|
className: "w-full justify-start font-normal",
|
|
1989
1989
|
onClick: () => {
|
|
1990
|
-
C(),
|
|
1990
|
+
C(), z(!1);
|
|
1991
1991
|
},
|
|
1992
|
-
children: [/* @__PURE__ */ X(
|
|
1992
|
+
children: [/* @__PURE__ */ X(le, {
|
|
1993
1993
|
size: 16,
|
|
1994
1994
|
className: "-ms-1 opacity-60",
|
|
1995
1995
|
"aria-hidden": !0
|
|
@@ -1997,7 +1997,7 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
1997
1997
|
}) })] }),
|
|
1998
1998
|
F && /* @__PURE__ */ X("div", {
|
|
1999
1999
|
className: "flex items-center justify-center py-3",
|
|
2000
|
-
children: /* @__PURE__ */ X(
|
|
2000
|
+
children: /* @__PURE__ */ X(ne, { className: "size-4 animate-spin text-muted-foreground" })
|
|
2001
2001
|
})
|
|
2002
2002
|
] })
|
|
2003
2003
|
})] })
|
|
@@ -2010,33 +2010,33 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
2010
2010
|
className: "space-y-1.5",
|
|
2011
2011
|
children: [
|
|
2012
2012
|
y && /* @__PURE__ */ Z(wt, {
|
|
2013
|
-
htmlFor:
|
|
2014
|
-
onClick:
|
|
2013
|
+
htmlFor: re,
|
|
2014
|
+
onClick: G,
|
|
2015
2015
|
className: Q("cursor-pointer", o && "text-muted-foreground"),
|
|
2016
2016
|
children: [y, Ee]
|
|
2017
2017
|
}),
|
|
2018
|
-
|
|
2019
|
-
open:
|
|
2020
|
-
onOpenChange:
|
|
2018
|
+
be ? /* @__PURE__ */ Z(an, {
|
|
2019
|
+
open: R,
|
|
2020
|
+
onOpenChange: H,
|
|
2021
2021
|
modal: !1,
|
|
2022
2022
|
children: [/* @__PURE__ */ X(on, {
|
|
2023
2023
|
asChild: !0,
|
|
2024
2024
|
children: /* @__PURE__ */ Z("div", {
|
|
2025
2025
|
"aria-invalid": s,
|
|
2026
|
-
className: Q("flex rounded-md border border-input transition-colors", xe ? "items-stretch" : "items-center overflow-hidden", q, K,
|
|
2026
|
+
className: Q("flex rounded-md border border-input transition-colors", xe ? "items-stretch" : "items-center overflow-hidden", q, K, R && "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"),
|
|
2027
2027
|
children: [
|
|
2028
2028
|
O && /* @__PURE__ */ X("div", {
|
|
2029
2029
|
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",
|
|
2030
2030
|
children: O
|
|
2031
2031
|
}),
|
|
2032
2032
|
/* @__PURE__ */ Z($, {
|
|
2033
|
-
id:
|
|
2033
|
+
id: re,
|
|
2034
2034
|
type: "button",
|
|
2035
2035
|
disabled: o,
|
|
2036
|
-
ref:
|
|
2036
|
+
ref: V,
|
|
2037
2037
|
variant: "ghost",
|
|
2038
2038
|
role: "combobox",
|
|
2039
|
-
"aria-expanded":
|
|
2039
|
+
"aria-expanded": R,
|
|
2040
2040
|
onClick: (e) => {
|
|
2041
2041
|
te && (e.preventDefault(), e.stopPropagation());
|
|
2042
2042
|
},
|
|
@@ -2051,24 +2051,24 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
2051
2051
|
})
|
|
2052
2052
|
}), Te]
|
|
2053
2053
|
}) : /* @__PURE__ */ Z(an, {
|
|
2054
|
-
open:
|
|
2055
|
-
onOpenChange:
|
|
2054
|
+
open: R,
|
|
2055
|
+
onOpenChange: H,
|
|
2056
2056
|
modal: !1,
|
|
2057
2057
|
children: [/* @__PURE__ */ X(on, {
|
|
2058
2058
|
asChild: !0,
|
|
2059
2059
|
children: /* @__PURE__ */ Z($, {
|
|
2060
|
-
id:
|
|
2060
|
+
id: re,
|
|
2061
2061
|
type: "button",
|
|
2062
2062
|
disabled: o,
|
|
2063
|
-
ref:
|
|
2063
|
+
ref: V,
|
|
2064
2064
|
variant: "outline",
|
|
2065
2065
|
role: "combobox",
|
|
2066
|
-
"aria-expanded":
|
|
2066
|
+
"aria-expanded": R,
|
|
2067
2067
|
"aria-invalid": s,
|
|
2068
2068
|
onClick: (e) => {
|
|
2069
2069
|
te && (e.preventDefault(), e.stopPropagation());
|
|
2070
2070
|
},
|
|
2071
|
-
className: Q("h-auto w-full justify-between px-3 py-1 font-normal text-foreground", K, xe ? "items-start" : "items-center", q,
|
|
2071
|
+
className: Q("h-auto w-full justify-between px-3 py-1 font-normal text-foreground", K, xe ? "items-start" : "items-center", q, R && "border-ring ring-3 ring-ring/50", u),
|
|
2072
2072
|
children: [Se, Ce]
|
|
2073
2073
|
})
|
|
2074
2074
|
}), Te]
|
|
@@ -2086,7 +2086,7 @@ function Dn({ options: e = [], groups: t = [], value: r, onValueChange: i, place
|
|
|
2086
2086
|
function On({ className: e, ...t }) {
|
|
2087
2087
|
return /* @__PURE__ */ X(xe.Root, {
|
|
2088
2088
|
"data-slot": "checkbox",
|
|
2089
|
-
className: Q("peer relative flex size-4 shrink-0 items-center justify-center rounded-
|
|
2089
|
+
className: Q("peer relative flex size-4 shrink-0 items-center justify-center rounded-sm 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),
|
|
2090
2090
|
...t,
|
|
2091
2091
|
children: /* @__PURE__ */ X(xe.Indicator, {
|
|
2092
2092
|
"data-slot": "checkbox-indicator",
|
|
@@ -2183,30 +2183,30 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2183
2183
|
o === void 0 && O(e), s?.(e);
|
|
2184
2184
|
}, j = E.length > 0 && E.every((e) => k.includes(e)), M = k.length > 0 && !j, N = () => A(j ? k.filter((e) => C[e]) : [...new Set([...k, ...E])]), P = (e) => {
|
|
2185
2185
|
C[e] || A(k.includes(e) ? k.filter((t) => t !== e) : [...k, e]);
|
|
2186
|
-
}, F = e.length + +!!a + +!!c, [I, ee] = n.useState(f), [te,
|
|
2186
|
+
}, F = e.length + +!!a + +!!c, [I, ee] = n.useState(f), [te, L] = n.useState(0), R = d ? Math.max(1, Math.ceil(t.length / I)) : 1, z = Math.min(te, R - 1), B = n.useMemo(() => {
|
|
2187
2187
|
let e = t.map((e, t) => ({
|
|
2188
2188
|
row: e,
|
|
2189
2189
|
index: t
|
|
2190
2190
|
}));
|
|
2191
2191
|
if (!d) return e;
|
|
2192
|
-
let n =
|
|
2192
|
+
let n = z * I;
|
|
2193
2193
|
return e.slice(n, n + I);
|
|
2194
2194
|
}, [
|
|
2195
2195
|
t,
|
|
2196
2196
|
d,
|
|
2197
|
-
|
|
2197
|
+
z,
|
|
2198
2198
|
I
|
|
2199
|
-
]),
|
|
2199
|
+
]), ne = "px-4 py-3 first:pl-5 last:pr-5", V = "px-4 first:pl-5 last:pr-5", re = !_ && g !== void 0 ? typeof g == "number" ? `${g}px` : g : void 0;
|
|
2200
2200
|
return /* @__PURE__ */ Z("div", {
|
|
2201
2201
|
className: Q("overflow-hidden rounded-lg border", d && "rounded-b-none border-b-0", (_ || g !== void 0) && "flex min-h-0 flex-col [&_[data-slot=table-container]]:overflow-y-auto", _ && "min-h-0 flex-1 [&_[data-slot=table-container]]:min-h-0 [&_[data-slot=table-container]]:flex-1", !_ && g !== void 0 && "[&_[data-slot=table-container]]:max-h-(--dt-max-h)", y),
|
|
2202
|
-
style:
|
|
2202
|
+
style: re ? { "--dt-max-h": re } : void 0,
|
|
2203
2203
|
children: [/* @__PURE__ */ Z(kn, { children: [/* @__PURE__ */ X(An, {
|
|
2204
2204
|
className: Q("bg-muted/60", h && Q("sticky top-0 z-10 [&_th]:border-b [&_th]:bg-muted/95 [&_th]:backdrop-blur supports-backdrop-filter:[&_th]:bg-muted/80", "[&_th:first-child]:rounded-tl-lg [&_th:last-child]:rounded-tr-lg")),
|
|
2205
2205
|
children: /* @__PURE__ */ Z(Nn, {
|
|
2206
2206
|
className: "hover:bg-transparent",
|
|
2207
2207
|
children: [
|
|
2208
2208
|
a && /* @__PURE__ */ X(Pn, {
|
|
2209
|
-
className: Q("w-10",
|
|
2209
|
+
className: Q("w-10", V),
|
|
2210
2210
|
children: /* @__PURE__ */ X(On, {
|
|
2211
2211
|
"aria-label": "Select all rows",
|
|
2212
2212
|
checked: j ? !0 : M ? "indeterminate" : !1,
|
|
@@ -2215,7 +2215,7 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2215
2215
|
}),
|
|
2216
2216
|
e.map((e) => /* @__PURE__ */ X(Pn, {
|
|
2217
2217
|
style: e.width ? { width: e.width } : void 0,
|
|
2218
|
-
className: Q("h-11 text-xs font-semibold tracking-wide text-foreground uppercase",
|
|
2218
|
+
className: Q("h-11 text-xs font-semibold tracking-wide text-foreground uppercase", V, e.align && Ln[e.align], e.className, e.headerClassName),
|
|
2219
2219
|
children: e.header
|
|
2220
2220
|
}, e.key)),
|
|
2221
2221
|
c && /* @__PURE__ */ X(Pn, { className: "w-12" })
|
|
@@ -2238,7 +2238,7 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2238
2238
|
className: "h-28 text-center text-muted-foreground",
|
|
2239
2239
|
children: u
|
|
2240
2240
|
})
|
|
2241
|
-
}) :
|
|
2241
|
+
}) : B.map(({ row: t, index: n }) => {
|
|
2242
2242
|
let r = b[n], i = k.includes(r), o = C[r];
|
|
2243
2243
|
return /* @__PURE__ */ Z(Nn, {
|
|
2244
2244
|
"data-state": i ? "selected" : void 0,
|
|
@@ -2248,7 +2248,7 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2248
2248
|
className: Q(m && !i && "odd:bg-muted/40", i && "bg-primary/10 shadow-[inset_3px_0_0_0_var(--primary)] hover:bg-primary/15", v && !o && "cursor-pointer", o && "opacity-50 hover:bg-transparent"),
|
|
2249
2249
|
children: [
|
|
2250
2250
|
a && /* @__PURE__ */ X(Fn, {
|
|
2251
|
-
className: Q("w-10",
|
|
2251
|
+
className: Q("w-10", ne),
|
|
2252
2252
|
onClick: (e) => e.stopPropagation(),
|
|
2253
2253
|
children: /* @__PURE__ */ X(On, {
|
|
2254
2254
|
"aria-label": "Select row",
|
|
@@ -2259,7 +2259,7 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2259
2259
|
}),
|
|
2260
2260
|
e.map((e) => /* @__PURE__ */ X(Fn, {
|
|
2261
2261
|
style: e.width ? { width: e.width } : void 0,
|
|
2262
|
-
className: Q(
|
|
2262
|
+
className: Q(ne, e.align && Ln[e.align], e.className),
|
|
2263
2263
|
children: e.cell ? e.cell(t, n) : String(t[e.key] ?? "")
|
|
2264
2264
|
}, e.key)),
|
|
2265
2265
|
c && /* @__PURE__ */ X(Fn, {
|
|
@@ -2275,9 +2275,9 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2275
2275
|
className: "text-muted-foreground",
|
|
2276
2276
|
children: [
|
|
2277
2277
|
"Page ",
|
|
2278
|
-
t.length === 0 ? 0 :
|
|
2278
|
+
t.length === 0 ? 0 : z + 1,
|
|
2279
2279
|
" of ",
|
|
2280
|
-
|
|
2280
|
+
R,
|
|
2281
2281
|
" (",
|
|
2282
2282
|
t.length,
|
|
2283
2283
|
" total ",
|
|
@@ -2297,7 +2297,7 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2297
2297
|
value: String(I),
|
|
2298
2298
|
onValueChange: (e) => {
|
|
2299
2299
|
let t = typeof e == "object" && e && "value" in e ? e.value : e;
|
|
2300
|
-
ee(Number(t)),
|
|
2300
|
+
ee(Number(t)), L(0);
|
|
2301
2301
|
},
|
|
2302
2302
|
options: p.map((e) => ({
|
|
2303
2303
|
value: String(e),
|
|
@@ -2311,32 +2311,32 @@ function Rn({ columns: e, data: t, getRowId: r = (e, t) => String(t), isRowDisab
|
|
|
2311
2311
|
variant: "outline",
|
|
2312
2312
|
size: "icon-sm",
|
|
2313
2313
|
"aria-label": "First page",
|
|
2314
|
-
disabled:
|
|
2315
|
-
onClick: () =>
|
|
2314
|
+
disabled: z <= 0,
|
|
2315
|
+
onClick: () => L(0),
|
|
2316
2316
|
children: /* @__PURE__ */ X(w, {})
|
|
2317
2317
|
}),
|
|
2318
2318
|
/* @__PURE__ */ X($, {
|
|
2319
2319
|
variant: "outline",
|
|
2320
2320
|
size: "icon-sm",
|
|
2321
2321
|
"aria-label": "Previous page",
|
|
2322
|
-
disabled:
|
|
2323
|
-
onClick: () =>
|
|
2322
|
+
disabled: z <= 0,
|
|
2323
|
+
onClick: () => L(Math.max(0, z - 1)),
|
|
2324
2324
|
children: /* @__PURE__ */ X(x, {})
|
|
2325
2325
|
}),
|
|
2326
2326
|
/* @__PURE__ */ X($, {
|
|
2327
2327
|
variant: "outline",
|
|
2328
2328
|
size: "icon-sm",
|
|
2329
2329
|
"aria-label": "Next page",
|
|
2330
|
-
disabled:
|
|
2331
|
-
onClick: () =>
|
|
2330
|
+
disabled: z >= R - 1,
|
|
2331
|
+
onClick: () => L(Math.min(R - 1, z + 1)),
|
|
2332
2332
|
children: /* @__PURE__ */ X(S, {})
|
|
2333
2333
|
}),
|
|
2334
2334
|
/* @__PURE__ */ X($, {
|
|
2335
2335
|
variant: "outline",
|
|
2336
2336
|
size: "icon-sm",
|
|
2337
2337
|
"aria-label": "Last page",
|
|
2338
|
-
disabled:
|
|
2339
|
-
onClick: () =>
|
|
2338
|
+
disabled: z >= R - 1,
|
|
2339
|
+
onClick: () => L(R - 1),
|
|
2340
2340
|
children: /* @__PURE__ */ X(T, {})
|
|
2341
2341
|
})
|
|
2342
2342
|
]
|
|
@@ -2379,7 +2379,7 @@ function zn({ children: e, title: t, open: n, onClose: r, description: i, notDis
|
|
|
2379
2379
|
onClick: (e) => {
|
|
2380
2380
|
e.preventDefault(), e.stopPropagation(), r();
|
|
2381
2381
|
},
|
|
2382
|
-
children: /* @__PURE__ */ X(
|
|
2382
|
+
children: /* @__PURE__ */ X(ye, {})
|
|
2383
2383
|
})]
|
|
2384
2384
|
})
|
|
2385
2385
|
}),
|
|
@@ -2514,7 +2514,7 @@ function Gn({ value: e, onChange: t, swatches: r = Un, trigger: i = "swatch", pl
|
|
|
2514
2514
|
"aria-label": "Pick a color",
|
|
2515
2515
|
className: Q("flex size-9 items-center justify-center rounded-md border ring-1 ring-foreground/10 outline-none transition-transform hover:scale-105 focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50", s),
|
|
2516
2516
|
style: { background: e || "transparent" },
|
|
2517
|
-
children: !e && /* @__PURE__ */ X(
|
|
2517
|
+
children: !e && /* @__PURE__ */ X(oe, { className: "size-4 text-muted-foreground" })
|
|
2518
2518
|
})
|
|
2519
2519
|
}), /* @__PURE__ */ Z(sn, {
|
|
2520
2520
|
className: "w-64",
|
|
@@ -2555,35 +2555,35 @@ function Gn({ value: e, onChange: t, swatches: r = Un, trigger: i = "swatch", pl
|
|
|
2555
2555
|
//#endregion
|
|
2556
2556
|
//#region src/components/ui/alert-dialog.tsx
|
|
2557
2557
|
function Kn({ ...e }) {
|
|
2558
|
-
return /* @__PURE__ */ X(
|
|
2558
|
+
return /* @__PURE__ */ X(be.Root, {
|
|
2559
2559
|
"data-slot": "alert-dialog",
|
|
2560
2560
|
...e
|
|
2561
2561
|
});
|
|
2562
2562
|
}
|
|
2563
2563
|
function qn({ ...e }) {
|
|
2564
|
-
return /* @__PURE__ */ X(
|
|
2564
|
+
return /* @__PURE__ */ X(be.Trigger, {
|
|
2565
2565
|
"data-slot": "alert-dialog-trigger",
|
|
2566
2566
|
...e
|
|
2567
2567
|
});
|
|
2568
2568
|
}
|
|
2569
2569
|
function Jn({ ...e }) {
|
|
2570
|
-
return /* @__PURE__ */ X(
|
|
2570
|
+
return /* @__PURE__ */ X(be.Portal, {
|
|
2571
2571
|
"data-slot": "alert-dialog-portal",
|
|
2572
2572
|
...e
|
|
2573
2573
|
});
|
|
2574
2574
|
}
|
|
2575
2575
|
function Yn({ className: e, ...t }) {
|
|
2576
|
-
return /* @__PURE__ */ X(
|
|
2576
|
+
return /* @__PURE__ */ X(be.Overlay, {
|
|
2577
2577
|
"data-slot": "alert-dialog-overlay",
|
|
2578
2578
|
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),
|
|
2579
2579
|
...t
|
|
2580
2580
|
});
|
|
2581
2581
|
}
|
|
2582
2582
|
function Xn({ className: e, size: t = "default", ...n }) {
|
|
2583
|
-
return /* @__PURE__ */ Z(Jn, { children: [/* @__PURE__ */ X(Yn, {}), /* @__PURE__ */ X(
|
|
2583
|
+
return /* @__PURE__ */ Z(Jn, { children: [/* @__PURE__ */ X(Yn, {}), /* @__PURE__ */ X(be.Content, {
|
|
2584
2584
|
"data-slot": "alert-dialog-content",
|
|
2585
2585
|
"data-size": t,
|
|
2586
|
-
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-
|
|
2586
|
+
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-sm 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),
|
|
2587
2587
|
...n
|
|
2588
2588
|
})] });
|
|
2589
2589
|
}
|
|
@@ -2597,7 +2597,7 @@ function Zn({ className: e, ...t }) {
|
|
|
2597
2597
|
function Qn({ className: e, ...t }) {
|
|
2598
2598
|
return /* @__PURE__ */ X("div", {
|
|
2599
2599
|
"data-slot": "alert-dialog-footer",
|
|
2600
|
-
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-
|
|
2600
|
+
className: Q("-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-sm 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),
|
|
2601
2601
|
...t
|
|
2602
2602
|
});
|
|
2603
2603
|
}
|
|
@@ -2609,14 +2609,14 @@ function $n({ className: e, ...t }) {
|
|
|
2609
2609
|
});
|
|
2610
2610
|
}
|
|
2611
2611
|
function er({ className: e, ...t }) {
|
|
2612
|
-
return /* @__PURE__ */ X(
|
|
2612
|
+
return /* @__PURE__ */ X(be.Title, {
|
|
2613
2613
|
"data-slot": "alert-dialog-title",
|
|
2614
2614
|
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),
|
|
2615
2615
|
...t
|
|
2616
2616
|
});
|
|
2617
2617
|
}
|
|
2618
2618
|
function tr({ className: e, ...t }) {
|
|
2619
|
-
return /* @__PURE__ */ X(
|
|
2619
|
+
return /* @__PURE__ */ X(be.Description, {
|
|
2620
2620
|
"data-slot": "alert-dialog-description",
|
|
2621
2621
|
className: Q("text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground", e),
|
|
2622
2622
|
...t
|
|
@@ -2627,7 +2627,7 @@ function nr({ className: e, variant: t = "default", size: n = "default", ...r })
|
|
|
2627
2627
|
variant: t,
|
|
2628
2628
|
size: n,
|
|
2629
2629
|
asChild: !0,
|
|
2630
|
-
children: /* @__PURE__ */ X(
|
|
2630
|
+
children: /* @__PURE__ */ X(be.Action, {
|
|
2631
2631
|
"data-slot": "alert-dialog-action",
|
|
2632
2632
|
className: Q(e),
|
|
2633
2633
|
...r
|
|
@@ -2639,7 +2639,7 @@ function rr({ className: e, variant: t = "outline", size: n = "default", ...r })
|
|
|
2639
2639
|
variant: t,
|
|
2640
2640
|
size: n,
|
|
2641
2641
|
asChild: !0,
|
|
2642
|
-
children: /* @__PURE__ */ X(
|
|
2642
|
+
children: /* @__PURE__ */ X(be.Cancel, {
|
|
2643
2643
|
"data-slot": "alert-dialog-cancel",
|
|
2644
2644
|
className: Q(e),
|
|
2645
2645
|
...r
|
|
@@ -2712,7 +2712,7 @@ function ir({ show: e, title: t = "Are you absolutely sure?", message: r = "This
|
|
|
2712
2712
|
onClick: b,
|
|
2713
2713
|
className: Q("bg-red-500 text-white hover:bg-red-600"),
|
|
2714
2714
|
disabled: v,
|
|
2715
|
-
children: _ ? /* @__PURE__ */ X(
|
|
2715
|
+
children: _ ? /* @__PURE__ */ X(ne, { className: "size-4 animate-spin" }) : u
|
|
2716
2716
|
})]
|
|
2717
2717
|
})
|
|
2718
2718
|
]
|
|
@@ -2808,13 +2808,13 @@ function cr({ label: e, value: t, className: n, ...r }) {
|
|
|
2808
2808
|
}
|
|
2809
2809
|
//#endregion
|
|
2810
2810
|
//#region src/components/custom/divider.tsx
|
|
2811
|
-
var lr =
|
|
2811
|
+
var lr = G("flex items-center", {
|
|
2812
2812
|
variants: { orientation: {
|
|
2813
2813
|
horizontal: "w-full",
|
|
2814
2814
|
vertical: "h-full flex-col"
|
|
2815
2815
|
} },
|
|
2816
2816
|
defaultVariants: { orientation: "horizontal" }
|
|
2817
|
-
}), ur =
|
|
2817
|
+
}), ur = G("", {
|
|
2818
2818
|
variants: {
|
|
2819
2819
|
color: {
|
|
2820
2820
|
default: "bg-border",
|
|
@@ -2868,7 +2868,7 @@ var lr = W("flex items-center", {
|
|
|
2868
2868
|
thickness: "thin",
|
|
2869
2869
|
orientation: "horizontal"
|
|
2870
2870
|
}
|
|
2871
|
-
}), dr =
|
|
2871
|
+
}), dr = G("font-medium whitespace-nowrap", {
|
|
2872
2872
|
variants: {
|
|
2873
2873
|
color: {
|
|
2874
2874
|
default: "text-foreground",
|
|
@@ -2885,7 +2885,7 @@ var lr = W("flex items-center", {
|
|
|
2885
2885
|
color: "default",
|
|
2886
2886
|
size: "sm"
|
|
2887
2887
|
}
|
|
2888
|
-
}), fr =
|
|
2888
|
+
}), fr = G("flex items-center justify-center rounded-full text-xs font-medium", {
|
|
2889
2889
|
variants: {
|
|
2890
2890
|
color: {
|
|
2891
2891
|
default: "border border-border bg-background text-foreground",
|
|
@@ -3006,7 +3006,7 @@ function hr({ className: e, ...t }) {
|
|
|
3006
3006
|
...t
|
|
3007
3007
|
});
|
|
3008
3008
|
}
|
|
3009
|
-
var gr =
|
|
3009
|
+
var gr = G("flex shrink-0 items-center justify-center mb-2 [&_svg:not([class*='size-'])]:size-6", {
|
|
3010
3010
|
variants: { variant: {
|
|
3011
3011
|
default: "bg-transparent",
|
|
3012
3012
|
icon: "bg-muted text-foreground flex size-10 shrink-0 items-center justify-center rounded-lg [&_svg:not([class*='size-'])]:size-6"
|
|
@@ -3047,7 +3047,7 @@ function br({ className: e, ...t }) {
|
|
|
3047
3047
|
}
|
|
3048
3048
|
//#endregion
|
|
3049
3049
|
//#region src/components/custom/empty-state.tsx
|
|
3050
|
-
function xr({ icon: e = /* @__PURE__ */ X(
|
|
3050
|
+
function xr({ icon: e = /* @__PURE__ */ X(R, {}), mediaVariant: t = "icon", title: n = "No data", description: r, actions: i, ...a }) {
|
|
3051
3051
|
return /* @__PURE__ */ Z(mr, {
|
|
3052
3052
|
...a,
|
|
3053
3053
|
children: [/* @__PURE__ */ Z(hr, { children: [
|
|
@@ -3078,7 +3078,7 @@ function Sr(e) {
|
|
|
3078
3078
|
variant: "outline",
|
|
3079
3079
|
className: Q("w-fit border-dashed", o),
|
|
3080
3080
|
children: [
|
|
3081
|
-
/* @__PURE__ */ X(
|
|
3081
|
+
/* @__PURE__ */ X(ce, {}),
|
|
3082
3082
|
t,
|
|
3083
3083
|
c.size > 0 && /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(_t, {
|
|
3084
3084
|
orientation: "vertical",
|
|
@@ -3377,7 +3377,7 @@ function Ar({ icon: e, value: t, label: n, className: r, ...i }) {
|
|
|
3377
3377
|
}
|
|
3378
3378
|
//#endregion
|
|
3379
3379
|
//#region src/components/ui/card.tsx
|
|
3380
|
-
var jr =
|
|
3380
|
+
var jr = G("group/card flex flex-col gap-4 overflow-hidden rounded-sm py-4 text-sm ring-1 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-sm *:[img:last-child]:rounded-b-sm", {
|
|
3381
3381
|
variants: { variant: {
|
|
3382
3382
|
default: "bg-card text-card-foreground ring-foreground/10",
|
|
3383
3383
|
alt: "bg-muted/40 text-card-foreground ring-foreground/10",
|
|
@@ -3400,7 +3400,7 @@ function Mr({ className: e, size: t = "default", variant: n = "default", ...r })
|
|
|
3400
3400
|
function Nr({ className: e, ...t }) {
|
|
3401
3401
|
return /* @__PURE__ */ X("div", {
|
|
3402
3402
|
"data-slot": "card-header",
|
|
3403
|
-
className: Q("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-
|
|
3403
|
+
className: Q("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-sm 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),
|
|
3404
3404
|
...t
|
|
3405
3405
|
});
|
|
3406
3406
|
}
|
|
@@ -3435,7 +3435,7 @@ function Lr({ className: e, ...t }) {
|
|
|
3435
3435
|
function Rr({ className: e, ...t }) {
|
|
3436
3436
|
return /* @__PURE__ */ X("div", {
|
|
3437
3437
|
"data-slot": "card-footer",
|
|
3438
|
-
className: Q("flex items-center rounded-b-
|
|
3438
|
+
className: Q("flex items-center rounded-b-sm border-t bg-muted/50 p-4 group-data-[size=sm]/card:p-3", e),
|
|
3439
3439
|
...t
|
|
3440
3440
|
});
|
|
3441
3441
|
}
|
|
@@ -3460,7 +3460,7 @@ var zr = {
|
|
|
3460
3460
|
}
|
|
3461
3461
|
};
|
|
3462
3462
|
function Br({ icon: e, mode: t, description: n, value: r, showAccent: i = !1, colorVariant: a = "primary", accentColorVariant: o, valueColorVariant: s, showPercentSign: c = !0, unit: l, stackedLayout: u = !1, variant: d = "default", onClick: f, onValueClick: p, className: m }) {
|
|
3463
|
-
let h = zr[a], g = zr[o ?? a], _ = s ? zr[s].text : "text-foreground", v = u ? "size-10" : "size-5", y = e ?? (t?.toLowerCase() === "auto" ? /* @__PURE__ */ X(
|
|
3463
|
+
let h = zr[a], g = zr[o ?? a], _ = s ? zr[s].text : "text-foreground", v = u ? "size-10" : "size-5", y = e ?? (t?.toLowerCase() === "auto" ? /* @__PURE__ */ X(ue, { className: Q(v, h.text) }) : /* @__PURE__ */ X(D, { className: Q(v, h.text) })), b = /* @__PURE__ */ Z(Y, { children: [u ? /* @__PURE__ */ Z("div", {
|
|
3464
3464
|
className: "flex items-center gap-3",
|
|
3465
3465
|
children: [y, /* @__PURE__ */ Z("div", {
|
|
3466
3466
|
className: "flex flex-col",
|
|
@@ -3561,7 +3561,7 @@ function Kr({ className: e, children: t, side: n = "right", showCloseButton: r =
|
|
|
3561
3561
|
variant: "ghost",
|
|
3562
3562
|
className: "absolute top-3 right-3",
|
|
3563
3563
|
size: "icon-sm",
|
|
3564
|
-
children: [/* @__PURE__ */ X(
|
|
3564
|
+
children: [/* @__PURE__ */ X(ye, {}), /* @__PURE__ */ X("span", {
|
|
3565
3565
|
className: "sr-only",
|
|
3566
3566
|
children: "Close"
|
|
3567
3567
|
})]
|
|
@@ -3620,7 +3620,7 @@ function Zr({ children: e, title: t, open: n, onClose: r, description: i, side:
|
|
|
3620
3620
|
onClick: (e) => {
|
|
3621
3621
|
e.preventDefault(), e.stopPropagation(), (d ? s : r)();
|
|
3622
3622
|
},
|
|
3623
|
-
children: X(d ? x :
|
|
3623
|
+
children: X(d ? x : ye, {})
|
|
3624
3624
|
}), /* @__PURE__ */ Z("div", {
|
|
3625
3625
|
className: "flex min-w-0 flex-col",
|
|
3626
3626
|
children: [/* @__PURE__ */ X(Yr, {
|
|
@@ -3777,7 +3777,7 @@ function ti({ title: e, value: t, description: n, icon: r, color: i = "primary",
|
|
|
3777
3777
|
className: "mt-1 flex items-center gap-1 text-sm text-muted-foreground",
|
|
3778
3778
|
children: [/* @__PURE__ */ Z("span", {
|
|
3779
3779
|
className: Q("flex items-center gap-1 font-medium", a.direction === "down" ? "text-red" : "text-green"),
|
|
3780
|
-
children: [a.direction === "down" ? /* @__PURE__ */ X(
|
|
3780
|
+
children: [a.direction === "down" ? /* @__PURE__ */ X(pe, { className: "size-4" }) : /* @__PURE__ */ X(me, { className: "size-4" }), a.value]
|
|
3781
3781
|
}), a.label]
|
|
3782
3782
|
}) : n && !c ? /* @__PURE__ */ X("p", {
|
|
3783
3783
|
className: "mt-1 text-sm text-muted-foreground",
|
|
@@ -3993,7 +3993,7 @@ function pi({ className: e, size: t = "default", children: n, ...r }) {
|
|
|
3993
3993
|
return /* @__PURE__ */ Z(J.Trigger, {
|
|
3994
3994
|
"data-slot": "select-trigger",
|
|
3995
3995
|
"data-size": t,
|
|
3996
|
-
className: Q("flex w-fit items-center justify-between gap-1.5 rounded-
|
|
3996
|
+
className: Q("flex w-fit items-center justify-between gap-1.5 rounded-md 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-sm *: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),
|
|
3997
3997
|
...r,
|
|
3998
3998
|
children: [n, /* @__PURE__ */ X(J.Icon, {
|
|
3999
3999
|
asChild: !0,
|
|
@@ -4005,7 +4005,7 @@ function mi({ className: e, children: t, position: n = "item-aligned", align: r
|
|
|
4005
4005
|
return /* @__PURE__ */ X(J.Portal, { children: /* @__PURE__ */ Z(J.Content, {
|
|
4006
4006
|
"data-slot": "select-content",
|
|
4007
4007
|
"data-align-trigger": n === "item-aligned",
|
|
4008
|
-
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-
|
|
4008
|
+
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-md 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),
|
|
4009
4009
|
position: n,
|
|
4010
4010
|
align: r,
|
|
4011
4011
|
...i,
|
|
@@ -4030,7 +4030,7 @@ function hi({ className: e, ...t }) {
|
|
|
4030
4030
|
function gi({ className: e, children: t, ...n }) {
|
|
4031
4031
|
return /* @__PURE__ */ Z(J.Item, {
|
|
4032
4032
|
"data-slot": "select-item",
|
|
4033
|
-
className: Q("relative flex w-full cursor-default items-center gap-1.5 rounded-
|
|
4033
|
+
className: Q("relative flex w-full cursor-default items-center gap-1.5 rounded-sm 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),
|
|
4034
4034
|
...n,
|
|
4035
4035
|
children: [/* @__PURE__ */ X("span", {
|
|
4036
4036
|
className: "pointer-events-none absolute right-2 flex size-4 items-center justify-center",
|
|
@@ -4506,7 +4506,7 @@ var ji = n.forwardRef(function({ value: e, onChange: t, className: r, timezone:
|
|
|
4506
4506
|
})
|
|
4507
4507
|
})]
|
|
4508
4508
|
});
|
|
4509
|
-
}), Mi =
|
|
4509
|
+
}), Mi = G("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", {
|
|
4510
4510
|
variants: { variant: {
|
|
4511
4511
|
default: "bg-card text-card-foreground",
|
|
4512
4512
|
destructive: "bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current"
|
|
@@ -4544,7 +4544,7 @@ function Ii({ className: e, ...t }) {
|
|
|
4544
4544
|
}
|
|
4545
4545
|
//#endregion
|
|
4546
4546
|
//#region src/components/ui/button-group.tsx
|
|
4547
|
-
var Li =
|
|
4547
|
+
var Li = G("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", {
|
|
4548
4548
|
variants: { orientation: {
|
|
4549
4549
|
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!",
|
|
4550
4550
|
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!"
|
|
@@ -4720,7 +4720,7 @@ function ea({ className: e, align: t = "center", sideOffset: n = 4, ...r }) {
|
|
|
4720
4720
|
"data-slot": "hover-card-content",
|
|
4721
4721
|
align: t,
|
|
4722
4722
|
sideOffset: n,
|
|
4723
|
-
className: Q("z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-
|
|
4723
|
+
className: Q("z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-md 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),
|
|
4724
4724
|
...r
|
|
4725
4725
|
})
|
|
4726
4726
|
});
|
|
@@ -4743,7 +4743,7 @@ function na({ className: e, ...t }) {
|
|
|
4743
4743
|
...t
|
|
4744
4744
|
});
|
|
4745
4745
|
}
|
|
4746
|
-
var ra =
|
|
4746
|
+
var ra = G("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", {
|
|
4747
4747
|
variants: {
|
|
4748
4748
|
variant: {
|
|
4749
4749
|
default: "border-transparent",
|
|
@@ -4774,7 +4774,7 @@ function ia({ className: e, variant: t = "default", size: n = "default", asChild
|
|
|
4774
4774
|
...i
|
|
4775
4775
|
});
|
|
4776
4776
|
}
|
|
4777
|
-
var aa =
|
|
4777
|
+
var aa = G("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", {
|
|
4778
4778
|
variants: { variant: {
|
|
4779
4779
|
default: "bg-transparent",
|
|
4780
4780
|
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
@@ -5037,7 +5037,7 @@ function Ta({ onClick: e }) {
|
|
|
5037
5037
|
onClick: e,
|
|
5038
5038
|
"aria-label": "Close popup",
|
|
5039
5039
|
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",
|
|
5040
|
-
children: /* @__PURE__ */ X(
|
|
5040
|
+
children: /* @__PURE__ */ X(ve, { className: "size-3.5" })
|
|
5041
5041
|
});
|
|
5042
5042
|
}
|
|
5043
5043
|
function Ea({ children: e, className: t, closeButton: n = !1, ...r }) {
|
|
@@ -5133,7 +5133,7 @@ function Ma({ tiles: e, tileIndex: t, onTileChange: n, openLeft: r }) {
|
|
|
5133
5133
|
children: [/* @__PURE__ */ X(Aa, { children: /* @__PURE__ */ X(ja, {
|
|
5134
5134
|
onClick: () => a((e) => !e),
|
|
5135
5135
|
label: `Basemap: ${e[t]?.label ?? ""}`,
|
|
5136
|
-
children: /* @__PURE__ */ X(
|
|
5136
|
+
children: /* @__PURE__ */ X(B, { className: "size-4" })
|
|
5137
5137
|
}) }), i && /* @__PURE__ */ X("div", {
|
|
5138
5138
|
role: "listbox",
|
|
5139
5139
|
"aria-label": "Basemap",
|
|
@@ -5182,11 +5182,11 @@ function Na({ position: e = "bottom-right", showZoom: t = !0, showCompass: n = !
|
|
|
5182
5182
|
t && /* @__PURE__ */ Z(Aa, { children: [/* @__PURE__ */ X(ja, {
|
|
5183
5183
|
onClick: h,
|
|
5184
5184
|
label: "Zoom in",
|
|
5185
|
-
children: /* @__PURE__ */ X(
|
|
5185
|
+
children: /* @__PURE__ */ X(se, { className: "size-4" })
|
|
5186
5186
|
}), /* @__PURE__ */ X(ja, {
|
|
5187
5187
|
onClick: g,
|
|
5188
5188
|
label: "Zoom out",
|
|
5189
|
-
children: /* @__PURE__ */ X(
|
|
5189
|
+
children: /* @__PURE__ */ X(ie, { className: "size-4" })
|
|
5190
5190
|
})] }),
|
|
5191
5191
|
c.length > 1 && /* @__PURE__ */ X(Ma, {
|
|
5192
5192
|
tiles: c,
|
|
@@ -5199,12 +5199,12 @@ function Na({ position: e = "bottom-right", showZoom: t = !0, showCompass: n = !
|
|
|
5199
5199
|
onClick: v,
|
|
5200
5200
|
label: "Find my location",
|
|
5201
5201
|
disabled: p,
|
|
5202
|
-
children: p ? /* @__PURE__ */ X(
|
|
5202
|
+
children: p ? /* @__PURE__ */ X(ne, { className: "size-4 animate-spin" }) : /* @__PURE__ */ X(H, { className: "size-4" })
|
|
5203
5203
|
}) }),
|
|
5204
5204
|
i && /* @__PURE__ */ X(Aa, { children: /* @__PURE__ */ X(ja, {
|
|
5205
5205
|
onClick: y,
|
|
5206
5206
|
label: "Toggle fullscreen",
|
|
5207
|
-
children: /* @__PURE__ */ X(
|
|
5207
|
+
children: /* @__PURE__ */ X(U, { className: "size-4" })
|
|
5208
5208
|
}) })
|
|
5209
5209
|
]
|
|
5210
5210
|
});
|
|
@@ -5730,10 +5730,10 @@ var Ya = ({ ...e }) => {
|
|
|
5730
5730
|
className: "toaster group",
|
|
5731
5731
|
icons: {
|
|
5732
5732
|
success: /* @__PURE__ */ X(E, { className: "size-4" }),
|
|
5733
|
-
info: /* @__PURE__ */ X(
|
|
5734
|
-
warning: /* @__PURE__ */ X(
|
|
5735
|
-
error: /* @__PURE__ */ X(
|
|
5736
|
-
loading: /* @__PURE__ */ X(
|
|
5733
|
+
info: /* @__PURE__ */ X(z, { className: "size-4" }),
|
|
5734
|
+
warning: /* @__PURE__ */ X(he, { className: "size-4" }),
|
|
5735
|
+
error: /* @__PURE__ */ X(ae, { className: "size-4" }),
|
|
5736
|
+
loading: /* @__PURE__ */ X(V, { className: "size-4 animate-spin" })
|
|
5737
5737
|
},
|
|
5738
5738
|
style: {
|
|
5739
5739
|
"--normal-bg": "var(--popover)",
|
|
@@ -5825,7 +5825,7 @@ function ro({ asChild: e = !1, className: t, children: n, ...r }) {
|
|
|
5825
5825
|
}),
|
|
5826
5826
|
o && /* @__PURE__ */ X("span", {
|
|
5827
5827
|
className: "absolute transition-all",
|
|
5828
|
-
children: /* @__PURE__ */ X(
|
|
5828
|
+
children: /* @__PURE__ */ X(re, {
|
|
5829
5829
|
"aria-hidden": "true",
|
|
5830
5830
|
className: "animate-spin",
|
|
5831
5831
|
size: 14
|
|
@@ -5879,7 +5879,7 @@ function co({ className: e, orientation: t = "horizontal", ...n }) {
|
|
|
5879
5879
|
...n
|
|
5880
5880
|
});
|
|
5881
5881
|
}
|
|
5882
|
-
var lo =
|
|
5882
|
+
var lo = G("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", {
|
|
5883
5883
|
variants: { variant: {
|
|
5884
5884
|
default: "bg-muted",
|
|
5885
5885
|
line: "gap-1 bg-transparent"
|
|
@@ -5988,7 +5988,7 @@ function Co({ className: e, ...t }) {
|
|
|
5988
5988
|
}
|
|
5989
5989
|
//#endregion
|
|
5990
5990
|
//#region src/components/ui/toggle.tsx
|
|
5991
|
-
var wo =
|
|
5991
|
+
var wo = G("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", {
|
|
5992
5992
|
variants: {
|
|
5993
5993
|
variant: {
|
|
5994
5994
|
default: "bg-transparent",
|