@clidey/ux 0.11.0 → 0.12.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 CHANGED
@@ -1,29 +1,58 @@
1
- import { jsx as r, jsxs as h, Fragment as De } from "react/jsx-runtime";
2
- import * as l from "react";
3
- import { createContext as Ie, useState as Le, useEffect as Oe, useContext as Be } from "react";
4
- import { Slot as E, createSlot as He } from "@radix-ui/react-slot";
5
- import { cva as oe } from "class-variance-authority";
6
- import { clsx as We } from "clsx";
7
- import { twMerge as Ue } from "tailwind-merge";
8
- import * as S from "@radix-ui/react-context-menu";
9
- import { CheckIcon as ne, CircleIcon as me, ChevronRightIcon as ie, MoreHorizontalIcon as Ve, ChevronLeftIcon as je, ChevronRight as Fe, ChevronDownIcon as pe, ChevronUpIcon as Xe, XIcon as Ye, PanelLeftIcon as $e, Sun as Ge, Moon as Ke } from "lucide-react";
10
- import { Drawer as M } from "vaul";
11
- import * as y from "@radix-ui/react-dropdown-menu";
12
- import * as qe from "@radix-ui/react-label";
13
- import * as $ from "@radix-ui/react-popover";
14
- import { useTheme as Je } from "next-themes";
15
- import { Toaster as Qe } from "sonner";
16
- import { toast as lo } from "sonner";
17
- import * as q from "@radix-ui/react-tabs";
18
- import * as O from "@radix-ui/react-tooltip";
19
- import * as N from "@radix-ui/react-select";
20
- import * as Ze from "@radix-ui/react-separator";
21
- import * as k from "@radix-ui/react-dialog";
1
+ import { jsx as a, jsxs as l, Fragment as W } from "react/jsx-runtime";
2
+ import * as u from "react";
3
+ import I, { Fragment as Se, createContext as Ce, useState as ze, useEffect as _e, useContext as Te } from "react";
4
+ import { Slot as R, createSlot as Me } from "@radix-ui/react-slot";
5
+ import { cva as O } from "class-variance-authority";
6
+ import { clsx as Ie } from "clsx";
7
+ import { twMerge as Pe } from "tailwind-merge";
8
+ import * as k from "@radix-ui/react-context-menu";
9
+ import { CheckIcon as $, CircleIcon as re, ChevronRightIcon as K, Search as Re, MoreHorizontalIcon as De, ChevronLeftIcon as Ee, ChevronRight as oe, XIcon as ne, SearchIcon as Be, ChevronDownIcon as q, ChevronsUpDownIcon as Le, ChevronUpIcon as Ae, PanelLeftIcon as $e, GripVerticalIcon as je, Sun as J, Moon as Q, Monitor as Oe } from "lucide-react";
10
+ import { Drawer as D } from "vaul";
11
+ import * as S from "@radix-ui/react-dropdown-menu";
12
+ import * as He from "@radix-ui/react-label";
13
+ import * as j from "@radix-ui/react-popover";
14
+ import { useTheme as Ge } from "next-themes";
15
+ import { Toaster as Ve } from "sonner";
16
+ import { toast as Do } from "sonner";
17
+ import { FixedSizeList as Fe } from "react-window";
18
+ import * as H from "@radix-ui/react-tabs";
19
+ import * as E from "@radix-ui/react-tooltip";
20
+ import { Command as B } from "cmdk";
21
+ import * as N from "@radix-ui/react-dialog";
22
+ import * as z from "@radix-ui/react-select";
23
+ import * as Ue from "@radix-ui/react-separator";
24
+ import * as A from "@radix-ui/react-scroll-area";
25
+ import * as Z from "@radix-ui/react-checkbox";
26
+ import * as T from "@radix-ui/react-accordion";
27
+ import We from "use-resize-observer";
28
+ import * as X from "react-resizable-panels";
22
29
  import "react-dom";
23
- function i(...e) {
24
- return Ue(We(e));
25
- }
26
- const et = oe(
30
+ function o(...e) {
31
+ return Pe(Ie(e));
32
+ }
33
+ function pa(e) {
34
+ return e.replace(/_/g, " ").replace(/\w\S*/g, (t) => t.charAt(0).toUpperCase() + t.slice(1).toLowerCase());
35
+ }
36
+ function ga(e) {
37
+ const r = (/* @__PURE__ */ new Date()).getTime() - e.getTime(), n = Math.floor(r / 1e3);
38
+ if (n < 60)
39
+ return "just now";
40
+ const i = Math.floor(n / 60);
41
+ if (i < 60)
42
+ return `${i} minute${i === 1 ? "" : "s"} ago`;
43
+ const s = Math.floor(i / 60);
44
+ if (s < 24)
45
+ return `${s} hour${s === 1 ? "" : "s"} ago`;
46
+ const c = Math.floor(s / 24);
47
+ if (c < 30)
48
+ return `${c} day${c === 1 ? "" : "s"} ago`;
49
+ const d = Math.floor(c / 30);
50
+ if (d < 12)
51
+ return `${d} month${d === 1 ? "" : "s"} ago`;
52
+ const m = Math.floor(d / 12);
53
+ return `${m} year${m === 1 ? "" : "s"} ago`;
54
+ }
55
+ const Ke = O(
27
56
  "inline-flex items-center justify-center rounded-md border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden",
28
57
  {
29
58
  variants: {
@@ -39,22 +68,22 @@ const et = oe(
39
68
  }
40
69
  }
41
70
  );
42
- function mr({
71
+ function ba({
43
72
  className: e,
44
73
  variant: t,
45
- asChild: a = !1,
46
- ...o
74
+ asChild: r = !1,
75
+ ...n
47
76
  }) {
48
- return /* @__PURE__ */ r(
49
- a ? E : "span",
77
+ return /* @__PURE__ */ a(
78
+ r ? R : "span",
50
79
  {
51
80
  "data-slot": "badge",
52
- className: i(et({ variant: t }), e),
53
- ...o
81
+ className: o(Ke({ variant: t }), e),
82
+ ...n
54
83
  }
55
84
  );
56
85
  }
57
- const be = oe(
86
+ const ie = O(
58
87
  "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
59
88
  {
60
89
  variants: {
@@ -79,28 +108,28 @@ const be = oe(
79
108
  }
80
109
  }
81
110
  );
82
- function ge({
111
+ function Y({
83
112
  className: e,
84
113
  variant: t,
85
- size: a,
86
- asChild: o = !1,
87
- ...n
114
+ size: r,
115
+ asChild: n = !1,
116
+ ...i
88
117
  }) {
89
- return /* @__PURE__ */ r(
90
- o ? E : "button",
118
+ return /* @__PURE__ */ a(
119
+ n ? R : "button",
91
120
  {
92
121
  "data-slot": "button",
93
- className: i(be({ variant: t, size: a, className: e })),
94
- ...n
122
+ className: o(ie({ variant: t, size: r, className: e })),
123
+ ...i
95
124
  }
96
125
  );
97
126
  }
98
- function pr({ className: e, ...t }) {
99
- return /* @__PURE__ */ r(
127
+ function ha({ className: e, ...t }) {
128
+ return /* @__PURE__ */ a(
100
129
  "div",
101
130
  {
102
131
  "data-slot": "card",
103
- className: i(
132
+ className: o(
104
133
  "bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",
105
134
  e
106
135
  ),
@@ -108,12 +137,12 @@ function pr({ className: e, ...t }) {
108
137
  }
109
138
  );
110
139
  }
111
- function br({ className: e, ...t }) {
112
- return /* @__PURE__ */ r(
140
+ function va({ className: e, ...t }) {
141
+ return /* @__PURE__ */ a(
113
142
  "div",
114
143
  {
115
144
  "data-slot": "card-header",
116
- className: i(
145
+ className: o(
117
146
  "@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",
118
147
  e
119
148
  ),
@@ -121,104 +150,104 @@ function br({ className: e, ...t }) {
121
150
  }
122
151
  );
123
152
  }
124
- function gr({ className: e, ...t }) {
125
- return /* @__PURE__ */ r(
153
+ function xa({ className: e, ...t }) {
154
+ return /* @__PURE__ */ a(
126
155
  "div",
127
156
  {
128
157
  "data-slot": "card-title",
129
- className: i("leading-none font-semibold", e),
158
+ className: o("leading-none font-semibold", e),
130
159
  ...t
131
160
  }
132
161
  );
133
162
  }
134
- function hr({ className: e, ...t }) {
135
- return /* @__PURE__ */ r(
163
+ function wa({ className: e, ...t }) {
164
+ return /* @__PURE__ */ a(
136
165
  "div",
137
166
  {
138
167
  "data-slot": "card-description",
139
- className: i("text-muted-foreground text-sm", e),
168
+ className: o("text-muted-foreground text-sm", e),
140
169
  ...t
141
170
  }
142
171
  );
143
172
  }
144
- function vr({ className: e, ...t }) {
145
- return /* @__PURE__ */ r(
173
+ function ya({ className: e, ...t }) {
174
+ return /* @__PURE__ */ a(
146
175
  "div",
147
176
  {
148
177
  "data-slot": "card-content",
149
- className: i("px-6", e),
178
+ className: o("px-6", e),
150
179
  ...t
151
180
  }
152
181
  );
153
182
  }
154
- function xr({ className: e, ...t }) {
155
- return /* @__PURE__ */ r(
183
+ function Na({ className: e, ...t }) {
184
+ return /* @__PURE__ */ a(
156
185
  "div",
157
186
  {
158
187
  "data-slot": "card-footer",
159
- className: i("flex items-center px-6 [.border-t]:pt-6", e),
188
+ className: o("flex items-center px-6 [.border-t]:pt-6", e),
160
189
  ...t
161
190
  }
162
191
  );
163
192
  }
164
- function wr({
193
+ function ka({
165
194
  ...e
166
195
  }) {
167
- return /* @__PURE__ */ r(S.Root, { "data-slot": "context-menu", ...e });
196
+ return /* @__PURE__ */ a(k.Root, { "data-slot": "context-menu", ...e });
168
197
  }
169
- function Sr({
198
+ function Sa({
170
199
  ...e
171
200
  }) {
172
- return /* @__PURE__ */ r(S.Trigger, { "data-slot": "context-menu-trigger", ...e });
201
+ return /* @__PURE__ */ a(k.Trigger, { "data-slot": "context-menu-trigger", ...e });
173
202
  }
174
- function yr({
203
+ function Ca({
175
204
  ...e
176
205
  }) {
177
- return /* @__PURE__ */ r(S.Sub, { "data-slot": "context-menu-sub", ...e });
206
+ return /* @__PURE__ */ a(k.Sub, { "data-slot": "context-menu-sub", ...e });
178
207
  }
179
- function Nr({
208
+ function za({
180
209
  ...e
181
210
  }) {
182
- return /* @__PURE__ */ r(
183
- S.RadioGroup,
211
+ return /* @__PURE__ */ a(
212
+ k.RadioGroup,
184
213
  {
185
214
  "data-slot": "context-menu-radio-group",
186
215
  ...e
187
216
  }
188
217
  );
189
218
  }
190
- function Cr({
219
+ function _a({
191
220
  className: e,
192
221
  inset: t,
193
- children: a,
194
- ...o
222
+ children: r,
223
+ ...n
195
224
  }) {
196
- return /* @__PURE__ */ h(
197
- S.SubTrigger,
225
+ return /* @__PURE__ */ l(
226
+ k.SubTrigger,
198
227
  {
199
228
  "data-slot": "context-menu-sub-trigger",
200
229
  "data-inset": t,
201
- className: i(
230
+ className: o(
202
231
  "focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
203
232
  e
204
233
  ),
205
- ...o,
234
+ ...n,
206
235
  children: [
207
- a,
208
- /* @__PURE__ */ r(ie, { className: "ml-auto" })
236
+ r,
237
+ /* @__PURE__ */ a(K, { className: "ml-auto" })
209
238
  ]
210
239
  }
211
240
  );
212
241
  }
213
- function Tr({
242
+ function Ta({
214
243
  className: e,
215
244
  ...t
216
245
  }) {
217
- return /* @__PURE__ */ r(
218
- S.SubContent,
246
+ return /* @__PURE__ */ a(
247
+ k.SubContent,
219
248
  {
220
249
  "data-slot": "context-menu-sub-content",
221
- className: i(
250
+ className: o(
222
251
  "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 z-50 min-w-[8rem] origin-(--radix-context-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
223
252
  e
224
253
  ),
@@ -226,15 +255,15 @@ function Tr({
226
255
  }
227
256
  );
228
257
  }
229
- function Pr({
258
+ function Ma({
230
259
  className: e,
231
260
  ...t
232
261
  }) {
233
- return /* @__PURE__ */ r(S.Portal, { children: /* @__PURE__ */ r(
234
- S.Content,
262
+ return /* @__PURE__ */ a(k.Portal, { children: /* @__PURE__ */ a(
263
+ k.Content,
235
264
  {
236
265
  "data-slot": "context-menu-content",
237
- className: i(
266
+ className: o(
238
267
  "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 z-50 max-h-(--radix-context-menu-content-available-height) min-w-[8rem] origin-(--radix-context-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",
239
268
  e
240
269
  ),
@@ -242,110 +271,110 @@ function Pr({
242
271
  }
243
272
  ) });
244
273
  }
245
- function zr({
274
+ function Ia({
246
275
  className: e,
247
276
  inset: t,
248
- variant: a = "default",
249
- ...o
277
+ variant: r = "default",
278
+ ...n
250
279
  }) {
251
- return /* @__PURE__ */ r(
252
- S.Item,
280
+ return /* @__PURE__ */ a(
281
+ k.Item,
253
282
  {
254
283
  "data-slot": "context-menu-item",
255
284
  "data-inset": t,
256
- "data-variant": a,
257
- className: i(
285
+ "data-variant": r,
286
+ className: o(
258
287
  "focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
259
288
  e
260
289
  ),
261
- ...o
290
+ ...n
262
291
  }
263
292
  );
264
293
  }
265
- function _r({
294
+ function Pa({
266
295
  className: e,
267
296
  children: t,
268
- checked: a,
269
- ...o
297
+ checked: r,
298
+ ...n
270
299
  }) {
271
- return /* @__PURE__ */ h(
272
- S.CheckboxItem,
300
+ return /* @__PURE__ */ l(
301
+ k.CheckboxItem,
273
302
  {
274
303
  "data-slot": "context-menu-checkbox-item",
275
- className: i(
304
+ className: o(
276
305
  "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
277
306
  e
278
307
  ),
279
- checked: a,
280
- ...o,
308
+ checked: r,
309
+ ...n,
281
310
  children: [
282
- /* @__PURE__ */ r("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ r(S.ItemIndicator, { children: /* @__PURE__ */ r(ne, { className: "size-4" }) }) }),
311
+ /* @__PURE__ */ a("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ a(k.ItemIndicator, { children: /* @__PURE__ */ a($, { className: "size-4" }) }) }),
283
312
  t
284
313
  ]
285
314
  }
286
315
  );
287
316
  }
288
- function Rr({
317
+ function Ra({
289
318
  className: e,
290
319
  children: t,
291
- ...a
320
+ ...r
292
321
  }) {
293
- return /* @__PURE__ */ h(
294
- S.RadioItem,
322
+ return /* @__PURE__ */ l(
323
+ k.RadioItem,
295
324
  {
296
325
  "data-slot": "context-menu-radio-item",
297
- className: i(
326
+ className: o(
298
327
  "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
299
328
  e
300
329
  ),
301
- ...a,
330
+ ...r,
302
331
  children: [
303
- /* @__PURE__ */ r("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ r(S.ItemIndicator, { children: /* @__PURE__ */ r(me, { className: "size-2 fill-current" }) }) }),
332
+ /* @__PURE__ */ a("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ a(k.ItemIndicator, { children: /* @__PURE__ */ a(re, { className: "size-2 fill-current" }) }) }),
304
333
  t
305
334
  ]
306
335
  }
307
336
  );
308
337
  }
309
- function kr({
338
+ function Da({
310
339
  className: e,
311
340
  inset: t,
312
- ...a
341
+ ...r
313
342
  }) {
314
- return /* @__PURE__ */ r(
315
- S.Label,
343
+ return /* @__PURE__ */ a(
344
+ k.Label,
316
345
  {
317
346
  "data-slot": "context-menu-label",
318
347
  "data-inset": t,
319
- className: i(
348
+ className: o(
320
349
  "text-foreground px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
321
350
  e
322
351
  ),
323
- ...a
352
+ ...r
324
353
  }
325
354
  );
326
355
  }
327
- function Er({
356
+ function Ea({
328
357
  className: e,
329
358
  ...t
330
359
  }) {
331
- return /* @__PURE__ */ r(
332
- S.Separator,
360
+ return /* @__PURE__ */ a(
361
+ k.Separator,
333
362
  {
334
363
  "data-slot": "context-menu-separator",
335
- className: i("bg-border -mx-1 my-1 h-px", e),
364
+ className: o("bg-border -mx-1 my-1 h-px", e),
336
365
  ...t
337
366
  }
338
367
  );
339
368
  }
340
- function Mr({
369
+ function Ba({
341
370
  className: e,
342
371
  ...t
343
372
  }) {
344
- return /* @__PURE__ */ r(
373
+ return /* @__PURE__ */ a(
345
374
  "span",
346
375
  {
347
376
  "data-slot": "context-menu-shortcut",
348
- className: i(
377
+ className: o(
349
378
  "text-muted-foreground ml-auto text-xs tracking-widest",
350
379
  e
351
380
  ),
@@ -353,76 +382,71 @@ function Mr({
353
382
  }
354
383
  );
355
384
  }
356
- function Ar({
357
- ...e
358
- }) {
359
- return /* @__PURE__ */ r(M.Root, { "data-slot": "drawer", ...e });
360
- }
361
- function Dr({
385
+ function La({
362
386
  ...e
363
387
  }) {
364
- return /* @__PURE__ */ r(M.Trigger, { "data-slot": "drawer-trigger", ...e });
388
+ return /* @__PURE__ */ a(D.Root, { "data-slot": "drawer", ...e });
365
389
  }
366
- function tt({
390
+ function Aa({
367
391
  ...e
368
392
  }) {
369
- return /* @__PURE__ */ r(M.Portal, { "data-slot": "drawer-portal", ...e });
393
+ return /* @__PURE__ */ a(D.Trigger, { "data-slot": "drawer-trigger", ...e });
370
394
  }
371
- function Ir({
395
+ function $a({
372
396
  ...e
373
397
  }) {
374
- return /* @__PURE__ */ r(M.Close, { "data-slot": "drawer-close", ...e });
398
+ return /* @__PURE__ */ a(D.Close, { "data-slot": "drawer-close", ...e });
375
399
  }
376
- function rt({
400
+ function qe({
377
401
  className: e,
378
402
  ...t
379
403
  }) {
380
- return /* @__PURE__ */ r(
381
- M.Overlay,
404
+ return /* @__PURE__ */ a(
405
+ D.Overlay,
382
406
  {
383
407
  "data-slot": "drawer-overlay",
384
- className: i(
385
- "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
408
+ className: o(
409
+ "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 absolute inset-0 z-50 bg-black/50",
386
410
  e
387
411
  ),
388
412
  ...t
389
413
  }
390
414
  );
391
415
  }
392
- function Lr({
416
+ function ja({
393
417
  className: e,
394
418
  children: t,
395
- ...a
419
+ ...r
396
420
  }) {
397
- return /* @__PURE__ */ h(tt, { "data-slot": "drawer-portal", children: [
398
- /* @__PURE__ */ r(rt, {}),
399
- /* @__PURE__ */ h(
400
- M.Content,
421
+ return /* @__PURE__ */ l(W, { children: [
422
+ /* @__PURE__ */ a(qe, {}),
423
+ /* @__PURE__ */ l(
424
+ D.Content,
401
425
  {
402
426
  "data-slot": "drawer-content",
403
- className: i(
404
- "group/drawer-content bg-background fixed z-50 flex h-auto flex-col",
427
+ className: o(
428
+ "group/drawer-content bg-background absolute z-50 flex h-auto flex-col",
405
429
  "data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=top]:rounded-b-lg data-[vaul-drawer-direction=top]:border-b",
406
430
  "data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=bottom]:rounded-t-lg data-[vaul-drawer-direction=bottom]:border-t",
407
431
  "data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=right]:sm:max-w-sm",
408
432
  "data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=left]:sm:max-w-sm",
409
433
  e
410
434
  ),
411
- ...a,
435
+ ...r,
412
436
  children: [
413
- /* @__PURE__ */ r("div", { className: "bg-muted mx-auto mt-4 hidden h-2 w-[100px] shrink-0 rounded-full group-data-[vaul-drawer-direction=bottom]/drawer-content:block" }),
437
+ /* @__PURE__ */ a("div", { className: "bg-muted mx-auto mt-4 hidden h-2 w-[100px] shrink-0 rounded-full group-data-[vaul-drawer-direction=bottom]/drawer-content:block" }),
414
438
  t
415
439
  ]
416
440
  }
417
441
  )
418
442
  ] });
419
443
  }
420
- function Or({ className: e, ...t }) {
421
- return /* @__PURE__ */ r(
444
+ function Oa({ className: e, ...t }) {
445
+ return /* @__PURE__ */ a(
422
446
  "div",
423
447
  {
424
448
  "data-slot": "drawer-header",
425
- className: i(
449
+ className: o(
426
450
  "flex flex-col gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-1.5 md:text-left",
427
451
  e
428
452
  ),
@@ -430,191 +454,191 @@ function Or({ className: e, ...t }) {
430
454
  }
431
455
  );
432
456
  }
433
- function Br({ className: e, ...t }) {
434
- return /* @__PURE__ */ r(
457
+ function Ha({ className: e, ...t }) {
458
+ return /* @__PURE__ */ a(
435
459
  "div",
436
460
  {
437
461
  "data-slot": "drawer-footer",
438
- className: i("mt-auto flex flex-col gap-2 p-4", e),
462
+ className: o("mt-auto flex flex-col gap-2 p-4", e),
439
463
  ...t
440
464
  }
441
465
  );
442
466
  }
443
- function Hr({
467
+ function Ga({
444
468
  className: e,
445
469
  ...t
446
470
  }) {
447
- return /* @__PURE__ */ r(
448
- M.Title,
471
+ return /* @__PURE__ */ a(
472
+ D.Title,
449
473
  {
450
474
  "data-slot": "drawer-title",
451
- className: i("text-foreground font-semibold", e),
475
+ className: o("text-foreground font-semibold", e),
452
476
  ...t
453
477
  }
454
478
  );
455
479
  }
456
- function Wr({
480
+ function Va({
457
481
  className: e,
458
482
  ...t
459
483
  }) {
460
- return /* @__PURE__ */ r(
461
- M.Description,
484
+ return /* @__PURE__ */ a(
485
+ D.Description,
462
486
  {
463
487
  "data-slot": "drawer-description",
464
- className: i("text-muted-foreground text-sm", e),
488
+ className: o("text-muted-foreground text-sm", e),
465
489
  ...t
466
490
  }
467
491
  );
468
492
  }
469
- function at({
493
+ function Xe({
470
494
  ...e
471
495
  }) {
472
- return /* @__PURE__ */ r(y.Root, { "data-slot": "dropdown-menu", ...e });
496
+ return /* @__PURE__ */ a(S.Root, { "data-slot": "dropdown-menu", ...e });
473
497
  }
474
- function ot({
498
+ function Ye({
475
499
  ...e
476
500
  }) {
477
- return /* @__PURE__ */ r(
478
- y.Trigger,
501
+ return /* @__PURE__ */ a(
502
+ S.Trigger,
479
503
  {
480
504
  "data-slot": "dropdown-menu-trigger",
481
505
  ...e
482
506
  }
483
507
  );
484
508
  }
485
- function nt({
509
+ function Je({
486
510
  className: e,
487
511
  sideOffset: t = 4,
488
- ...a
512
+ ...r
489
513
  }) {
490
- return /* @__PURE__ */ r(y.Portal, { children: /* @__PURE__ */ r(
491
- y.Content,
514
+ return /* @__PURE__ */ a(S.Portal, { children: /* @__PURE__ */ a(
515
+ S.Content,
492
516
  {
493
517
  "data-slot": "dropdown-menu-content",
494
518
  sideOffset: t,
495
- className: i(
519
+ className: o(
496
520
  "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",
497
521
  e
498
522
  ),
499
- ...a
523
+ ...r
500
524
  }
501
525
  ) });
502
526
  }
503
- function te({
527
+ function F({
504
528
  className: e,
505
529
  inset: t,
506
- variant: a = "default",
507
- ...o
530
+ variant: r = "default",
531
+ ...n
508
532
  }) {
509
- return /* @__PURE__ */ r(
510
- y.Item,
533
+ return /* @__PURE__ */ a(
534
+ S.Item,
511
535
  {
512
536
  "data-slot": "dropdown-menu-item",
513
537
  "data-inset": t,
514
- "data-variant": a,
515
- className: i(
538
+ "data-variant": r,
539
+ className: o(
516
540
  "focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
517
541
  e
518
542
  ),
519
- ...o
543
+ ...n
520
544
  }
521
545
  );
522
546
  }
523
- function Ur({
547
+ function Fa({
524
548
  className: e,
525
549
  children: t,
526
- checked: a,
527
- ...o
550
+ checked: r,
551
+ ...n
528
552
  }) {
529
- return /* @__PURE__ */ h(
530
- y.CheckboxItem,
553
+ return /* @__PURE__ */ l(
554
+ S.CheckboxItem,
531
555
  {
532
556
  "data-slot": "dropdown-menu-checkbox-item",
533
- className: i(
557
+ className: o(
534
558
  "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
535
559
  e
536
560
  ),
537
- checked: a,
538
- ...o,
561
+ checked: r,
562
+ ...n,
539
563
  children: [
540
- /* @__PURE__ */ r("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ r(y.ItemIndicator, { children: /* @__PURE__ */ r(ne, { className: "size-4" }) }) }),
564
+ /* @__PURE__ */ a("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ a(S.ItemIndicator, { children: /* @__PURE__ */ a($, { className: "size-4" }) }) }),
541
565
  t
542
566
  ]
543
567
  }
544
568
  );
545
569
  }
546
- function Vr({
570
+ function Ua({
547
571
  ...e
548
572
  }) {
549
- return /* @__PURE__ */ r(
550
- y.RadioGroup,
573
+ return /* @__PURE__ */ a(
574
+ S.RadioGroup,
551
575
  {
552
576
  "data-slot": "dropdown-menu-radio-group",
553
577
  ...e
554
578
  }
555
579
  );
556
580
  }
557
- function jr({
581
+ function Wa({
558
582
  className: e,
559
583
  children: t,
560
- ...a
584
+ ...r
561
585
  }) {
562
- return /* @__PURE__ */ h(
563
- y.RadioItem,
586
+ return /* @__PURE__ */ l(
587
+ S.RadioItem,
564
588
  {
565
589
  "data-slot": "dropdown-menu-radio-item",
566
- className: i(
590
+ className: o(
567
591
  "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
568
592
  e
569
593
  ),
570
- ...a,
594
+ ...r,
571
595
  children: [
572
- /* @__PURE__ */ r("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ r(y.ItemIndicator, { children: /* @__PURE__ */ r(me, { className: "size-2 fill-current" }) }) }),
596
+ /* @__PURE__ */ a("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ a(S.ItemIndicator, { children: /* @__PURE__ */ a(re, { className: "size-2 fill-current" }) }) }),
573
597
  t
574
598
  ]
575
599
  }
576
600
  );
577
601
  }
578
- function Fr({
602
+ function Ka({
579
603
  className: e,
580
604
  inset: t,
581
- ...a
605
+ ...r
582
606
  }) {
583
- return /* @__PURE__ */ r(
584
- y.Label,
607
+ return /* @__PURE__ */ a(
608
+ S.Label,
585
609
  {
586
610
  "data-slot": "dropdown-menu-label",
587
611
  "data-inset": t,
588
- className: i(
612
+ className: o(
589
613
  "px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",
590
614
  e
591
615
  ),
592
- ...a
616
+ ...r
593
617
  }
594
618
  );
595
619
  }
596
- function Xr({
620
+ function qa({
597
621
  className: e,
598
622
  ...t
599
623
  }) {
600
- return /* @__PURE__ */ r(
601
- y.Separator,
624
+ return /* @__PURE__ */ a(
625
+ S.Separator,
602
626
  {
603
627
  "data-slot": "dropdown-menu-separator",
604
- className: i("bg-border -mx-1 my-1 h-px", e),
628
+ className: o("bg-border -mx-1 my-1 h-px", e),
605
629
  ...t
606
630
  }
607
631
  );
608
632
  }
609
- function Yr({
633
+ function Xa({
610
634
  className: e,
611
635
  ...t
612
636
  }) {
613
- return /* @__PURE__ */ r(
637
+ return /* @__PURE__ */ a(
614
638
  "span",
615
639
  {
616
640
  "data-slot": "dropdown-menu-shortcut",
617
- className: i(
641
+ className: o(
618
642
  "text-muted-foreground ml-auto text-xs tracking-widest",
619
643
  e
620
644
  ),
@@ -622,43 +646,43 @@ function Yr({
622
646
  }
623
647
  );
624
648
  }
625
- function $r({
649
+ function Ya({
626
650
  ...e
627
651
  }) {
628
- return /* @__PURE__ */ r(y.Sub, { "data-slot": "dropdown-menu-sub", ...e });
652
+ return /* @__PURE__ */ a(S.Sub, { "data-slot": "dropdown-menu-sub", ...e });
629
653
  }
630
- function Gr({
654
+ function Ja({
631
655
  className: e,
632
656
  inset: t,
633
- children: a,
634
- ...o
657
+ children: r,
658
+ ...n
635
659
  }) {
636
- return /* @__PURE__ */ h(
637
- y.SubTrigger,
660
+ return /* @__PURE__ */ l(
661
+ S.SubTrigger,
638
662
  {
639
663
  "data-slot": "dropdown-menu-sub-trigger",
640
664
  "data-inset": t,
641
- className: i(
665
+ className: o(
642
666
  "focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8",
643
667
  e
644
668
  ),
645
- ...o,
669
+ ...n,
646
670
  children: [
647
- a,
648
- /* @__PURE__ */ r(ie, { className: "ml-auto size-4" })
671
+ r,
672
+ /* @__PURE__ */ a(K, { className: "ml-auto size-4" })
649
673
  ]
650
674
  }
651
675
  );
652
676
  }
653
- function Kr({
677
+ function Qa({
654
678
  className: e,
655
679
  ...t
656
680
  }) {
657
- return /* @__PURE__ */ r(
658
- y.SubContent,
681
+ return /* @__PURE__ */ a(
682
+ S.SubContent,
659
683
  {
660
684
  "data-slot": "dropdown-menu-sub-content",
661
- className: i(
685
+ className: o(
662
686
  "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",
663
687
  e
664
688
  ),
@@ -666,31 +690,61 @@ function Kr({
666
690
  }
667
691
  );
668
692
  }
669
- function it({ className: e, type: t, ...a }) {
670
- return /* @__PURE__ */ r(
693
+ function Qe({ className: e, type: t, ...r }) {
694
+ return /* @__PURE__ */ a(
671
695
  "input",
672
696
  {
673
697
  type: t,
674
698
  "data-slot": "input",
675
- className: i(
699
+ className: o(
676
700
  "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input flex h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
677
701
  "focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",
678
702
  "aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
679
703
  e
680
704
  ),
681
- ...a
705
+ ...r
706
+ }
707
+ );
708
+ }
709
+ function Za({
710
+ className: e,
711
+ ...t
712
+ }) {
713
+ return /* @__PURE__ */ l(
714
+ "div",
715
+ {
716
+ className: o(
717
+ "flex items-center h-9 w-full min-w-0 rounded-md border border-input bg-transparent shadow-xs transition-[color,box-shadow] outline-none px-2 dark:bg-input/30",
718
+ "focus-within:border-ring focus-within:ring-ring/50 focus-within:ring-[3px]",
719
+ "aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
720
+ e
721
+ ),
722
+ "data-slot": "search-input-wrapper",
723
+ children: [
724
+ /* @__PURE__ */ a(Re, { className: "size-4 text-muted-foreground mr-2" }),
725
+ /* @__PURE__ */ a(
726
+ "input",
727
+ {
728
+ "data-slot": "search-input",
729
+ className: o(
730
+ "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground bg-transparent flex-1 border-0 outline-none px-0 py-1 text-base file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm"
731
+ ),
732
+ ...t
733
+ }
734
+ )
735
+ ]
682
736
  }
683
737
  );
684
738
  }
685
- function qr({
739
+ function er({
686
740
  className: e,
687
741
  ...t
688
742
  }) {
689
- return /* @__PURE__ */ r(
690
- qe.Root,
743
+ return /* @__PURE__ */ a(
744
+ He.Root,
691
745
  {
692
746
  "data-slot": "label",
693
- className: i(
747
+ className: o(
694
748
  "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",
695
749
  e
696
750
  ),
@@ -698,155 +752,155 @@ function qr({
698
752
  }
699
753
  );
700
754
  }
701
- function Jr({ className: e, ...t }) {
702
- return /* @__PURE__ */ r(
755
+ function tr({ className: e, ...t }) {
756
+ return /* @__PURE__ */ a(
703
757
  "nav",
704
758
  {
705
759
  role: "navigation",
706
760
  "aria-label": "pagination",
707
761
  "data-slot": "pagination",
708
- className: i("mx-auto flex w-full justify-center", e),
762
+ className: o("mx-auto flex w-full justify-center", e),
709
763
  ...t
710
764
  }
711
765
  );
712
766
  }
713
- function Qr({
767
+ function ar({
714
768
  className: e,
715
769
  ...t
716
770
  }) {
717
- return /* @__PURE__ */ r(
771
+ return /* @__PURE__ */ a(
718
772
  "ul",
719
773
  {
720
774
  "data-slot": "pagination-content",
721
- className: i("flex flex-row items-center gap-1", e),
775
+ className: o("flex flex-row items-center gap-1", e),
722
776
  ...t
723
777
  }
724
778
  );
725
779
  }
726
- function Zr({ ...e }) {
727
- return /* @__PURE__ */ r("li", { "data-slot": "pagination-item", ...e });
780
+ function rr({ ...e }) {
781
+ return /* @__PURE__ */ a("li", { "data-slot": "pagination-item", ...e });
728
782
  }
729
- function he({
783
+ function se({
730
784
  className: e,
731
785
  isActive: t,
732
- size: a = "icon",
733
- ...o
786
+ size: r = "icon",
787
+ ...n
734
788
  }) {
735
- return /* @__PURE__ */ r(
789
+ return /* @__PURE__ */ a(
736
790
  "a",
737
791
  {
738
792
  "aria-current": t ? "page" : void 0,
739
793
  "data-slot": "pagination-link",
740
794
  "data-active": t,
741
- className: i(
742
- be({
795
+ className: o(
796
+ ie({
743
797
  variant: t ? "outline" : "ghost",
744
- size: a
798
+ size: r
745
799
  }),
746
800
  e
747
801
  ),
748
- ...o
802
+ ...n
749
803
  }
750
804
  );
751
805
  }
752
- function ea({
806
+ function or({
753
807
  className: e,
754
808
  ...t
755
809
  }) {
756
- return /* @__PURE__ */ h(
757
- he,
810
+ return /* @__PURE__ */ l(
811
+ se,
758
812
  {
759
813
  "aria-label": "Go to previous page",
760
814
  size: "default",
761
- className: i("gap-1 px-2.5 sm:pl-2.5", e),
815
+ className: o("gap-1 px-2.5 sm:pl-2.5", e),
762
816
  ...t,
763
817
  children: [
764
- /* @__PURE__ */ r(je, {}),
765
- /* @__PURE__ */ r("span", { className: "hidden sm:block", children: "Previous" })
818
+ /* @__PURE__ */ a(Ee, {}),
819
+ /* @__PURE__ */ a("span", { className: "hidden sm:block", children: "Previous" })
766
820
  ]
767
821
  }
768
822
  );
769
823
  }
770
- function ta({
824
+ function nr({
771
825
  className: e,
772
826
  ...t
773
827
  }) {
774
- return /* @__PURE__ */ h(
775
- he,
828
+ return /* @__PURE__ */ l(
829
+ se,
776
830
  {
777
831
  "aria-label": "Go to next page",
778
832
  size: "default",
779
- className: i("gap-1 px-2.5 sm:pr-2.5", e),
833
+ className: o("gap-1 px-2.5 sm:pr-2.5", e),
780
834
  ...t,
781
835
  children: [
782
- /* @__PURE__ */ r("span", { className: "hidden sm:block", children: "Next" }),
783
- /* @__PURE__ */ r(ie, {})
836
+ /* @__PURE__ */ a("span", { className: "hidden sm:block", children: "Next" }),
837
+ /* @__PURE__ */ a(K, {})
784
838
  ]
785
839
  }
786
840
  );
787
841
  }
788
- function ra({
842
+ function ir({
789
843
  className: e,
790
844
  ...t
791
845
  }) {
792
- return /* @__PURE__ */ h(
846
+ return /* @__PURE__ */ l(
793
847
  "span",
794
848
  {
795
849
  "aria-hidden": !0,
796
850
  "data-slot": "pagination-ellipsis",
797
- className: i("flex size-9 items-center justify-center", e),
851
+ className: o("flex size-9 items-center justify-center", e),
798
852
  ...t,
799
853
  children: [
800
- /* @__PURE__ */ r(Ve, { className: "size-4" }),
801
- /* @__PURE__ */ r("span", { className: "sr-only", children: "More pages" })
854
+ /* @__PURE__ */ a(De, { className: "size-4" }),
855
+ /* @__PURE__ */ a("span", { className: "sr-only", children: "More pages" })
802
856
  ]
803
857
  }
804
858
  );
805
859
  }
806
- function aa({
860
+ function Ze({
807
861
  ...e
808
862
  }) {
809
- return /* @__PURE__ */ r($.Root, { "data-slot": "popover", ...e });
863
+ return /* @__PURE__ */ a(j.Root, { "data-slot": "popover", ...e });
810
864
  }
811
- function oa({
865
+ function et({
812
866
  ...e
813
867
  }) {
814
- return /* @__PURE__ */ r($.Trigger, { "data-slot": "popover-trigger", ...e });
868
+ return /* @__PURE__ */ a(j.Trigger, { "data-slot": "popover-trigger", ...e });
815
869
  }
816
- function na({
870
+ function tt({
817
871
  className: e,
818
872
  align: t = "center",
819
- sideOffset: a = 4,
820
- ...o
873
+ sideOffset: r = 4,
874
+ ...n
821
875
  }) {
822
- return /* @__PURE__ */ r($.Portal, { children: /* @__PURE__ */ r(
823
- $.Content,
876
+ return /* @__PURE__ */ a(j.Portal, { children: /* @__PURE__ */ a(
877
+ j.Content,
824
878
  {
825
879
  "data-slot": "popover-content",
826
880
  align: t,
827
- sideOffset: a,
828
- className: i(
881
+ sideOffset: r,
882
+ className: o(
829
883
  "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",
830
884
  e
831
885
  ),
832
- ...o
886
+ ...n
833
887
  }
834
888
  ) });
835
889
  }
836
- function ce({ className: e, ...t }) {
837
- return /* @__PURE__ */ r(
890
+ function ee({ className: e, ...t }) {
891
+ return /* @__PURE__ */ a(
838
892
  "div",
839
893
  {
840
894
  "data-slot": "skeleton",
841
- className: i("bg-accent animate-pulse rounded-md", e),
895
+ className: o("bg-accent animate-pulse rounded-md", e),
842
896
  ...t
843
897
  }
844
898
  );
845
899
  }
846
- const ia = ({ ...e }) => {
847
- const { theme: t = "system" } = Je();
848
- return /* @__PURE__ */ r(
849
- Qe,
900
+ const sr = ({ ...e }) => {
901
+ const { theme: t = "system" } = Ge();
902
+ return /* @__PURE__ */ a(
903
+ Ve,
850
904
  {
851
905
  theme: t,
852
906
  className: "toaster group",
@@ -859,117 +913,145 @@ const ia = ({ ...e }) => {
859
913
  }
860
914
  );
861
915
  };
862
- function sa({ className: e, ...t }) {
863
- return /* @__PURE__ */ r(
916
+ function dr({
917
+ rowCount: e,
918
+ rowHeight: t = 48,
919
+ height: r = 400,
920
+ className: n,
921
+ children: i
922
+ }) {
923
+ return /* @__PURE__ */ a(
924
+ Fe,
925
+ {
926
+ className: o("w-full relative block", n),
927
+ height: r,
928
+ itemCount: e,
929
+ itemSize: t,
930
+ width: "100%",
931
+ outerElementType: at,
932
+ innerElementType: Se,
933
+ children: ({ index: s, style: c }) => /* @__PURE__ */ a(rt, { style: c, children: i(s, c) }, s)
934
+ }
935
+ );
936
+ }
937
+ function lr({ className: e, ...t }) {
938
+ return /* @__PURE__ */ a(
864
939
  "div",
865
940
  {
866
941
  "data-slot": "table-container",
867
- className: "relative w-full overflow-x-auto",
868
- children: /* @__PURE__ */ r(
942
+ className: "w-full overflow-x-auto h-full",
943
+ children: /* @__PURE__ */ a(
869
944
  "table",
870
945
  {
871
946
  "data-slot": "table",
872
- className: i("w-full caption-bottom text-sm", e),
947
+ className: o("w-full caption-bottom text-sm", e),
873
948
  ...t
874
949
  }
875
950
  )
876
951
  }
877
952
  );
878
953
  }
879
- function la({ className: e, ...t }) {
880
- return /* @__PURE__ */ r(
954
+ function cr({ className: e, ...t }) {
955
+ return /* @__PURE__ */ a(
881
956
  "thead",
882
957
  {
883
958
  "data-slot": "table-header",
884
- className: i("[&_tr]:border-b", e),
959
+ className: o("[&_tr]:border-b", e),
885
960
  ...t
886
961
  }
887
962
  );
888
963
  }
889
- function da({ className: e, ...t }) {
890
- return /* @__PURE__ */ r(
964
+ function at({ className: e, ...t }) {
965
+ return /* @__PURE__ */ a(
891
966
  "tbody",
892
967
  {
893
968
  "data-slot": "table-body",
894
- className: i("[&_tr:last-child]:border-0", e),
969
+ className: o("[&_tr:last-child]:border-0", e),
895
970
  ...t
896
971
  }
897
972
  );
898
973
  }
899
- function ca({ className: e, ...t }) {
900
- return /* @__PURE__ */ r(
974
+ function rt({ className: e, style: t, ...r }) {
975
+ return /* @__PURE__ */ a(
901
976
  "tr",
902
977
  {
903
978
  "data-slot": "table-row",
904
- className: i(
905
- "hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",
979
+ className: o(
980
+ "hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors flex items-center",
906
981
  e
907
982
  ),
908
- ...t
983
+ style: t,
984
+ ...r
909
985
  }
910
986
  );
911
987
  }
912
- function ua({ className: e, ...t }) {
913
- return /* @__PURE__ */ r(
988
+ function ur({ className: e, ...t }) {
989
+ const { icon: r, ...n } = t, { children: i } = n;
990
+ return /* @__PURE__ */ l(
914
991
  "th",
915
992
  {
916
993
  "data-slot": "table-head",
917
- className: i(
918
- "text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
994
+ className: o(
995
+ r && "gap-2",
996
+ "text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px] w-full flex items-center",
919
997
  e
920
998
  ),
921
- ...t
999
+ ...n,
1000
+ children: [
1001
+ r,
1002
+ i
1003
+ ]
922
1004
  }
923
1005
  );
924
1006
  }
925
- function fa({ className: e, ...t }) {
926
- return /* @__PURE__ */ r(
1007
+ function fr({ className: e, ...t }) {
1008
+ return /* @__PURE__ */ a(
927
1009
  "td",
928
1010
  {
929
1011
  "data-slot": "table-cell",
930
- className: i(
931
- "p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",
1012
+ className: o(
1013
+ "p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px] w-full flex items-center",
932
1014
  e
933
1015
  ),
934
1016
  ...t
935
1017
  }
936
1018
  );
937
1019
  }
938
- function ma({
1020
+ function mr({
939
1021
  className: e,
940
1022
  ...t
941
1023
  }) {
942
- return /* @__PURE__ */ r(
1024
+ return /* @__PURE__ */ a(
943
1025
  "caption",
944
1026
  {
945
1027
  "data-slot": "table-caption",
946
- className: i("text-muted-foreground mt-4 text-sm", e),
1028
+ className: o("text-muted-foreground mt-4 text-sm", e),
947
1029
  ...t
948
1030
  }
949
1031
  );
950
1032
  }
951
- function pa({
1033
+ function pr({
952
1034
  className: e,
953
1035
  ...t
954
1036
  }) {
955
- return /* @__PURE__ */ r(
956
- q.Root,
1037
+ return /* @__PURE__ */ a(
1038
+ H.Root,
957
1039
  {
958
1040
  "data-slot": "tabs",
959
- className: i("flex flex-col gap-2", e),
1041
+ className: o("flex flex-col gap-2", e),
960
1042
  ...t
961
1043
  }
962
1044
  );
963
1045
  }
964
- function ba({
1046
+ function gr({
965
1047
  className: e,
966
1048
  ...t
967
1049
  }) {
968
- return /* @__PURE__ */ r(
969
- q.List,
1050
+ return /* @__PURE__ */ a(
1051
+ H.List,
970
1052
  {
971
1053
  "data-slot": "tabs-list",
972
- className: i(
1054
+ className: o(
973
1055
  "bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",
974
1056
  e
975
1057
  ),
@@ -977,15 +1059,15 @@ function ba({
977
1059
  }
978
1060
  );
979
1061
  }
980
- function ga({
1062
+ function br({
981
1063
  className: e,
982
1064
  ...t
983
1065
  }) {
984
- return /* @__PURE__ */ r(
985
- q.Trigger,
1066
+ return /* @__PURE__ */ a(
1067
+ H.Trigger,
986
1068
  {
987
1069
  "data-slot": "tabs-trigger",
988
- className: i(
1070
+ className: o(
989
1071
  "data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
990
1072
  e
991
1073
  ),
@@ -993,25 +1075,25 @@ function ga({
993
1075
  }
994
1076
  );
995
1077
  }
996
- function ha({
1078
+ function hr({
997
1079
  className: e,
998
1080
  ...t
999
1081
  }) {
1000
- return /* @__PURE__ */ r(
1001
- q.Content,
1082
+ return /* @__PURE__ */ a(
1083
+ H.Content,
1002
1084
  {
1003
1085
  "data-slot": "tabs-content",
1004
- className: i("flex-1 outline-none", e),
1086
+ className: o("flex-1 outline-none", e),
1005
1087
  ...t
1006
1088
  }
1007
1089
  );
1008
1090
  }
1009
- function ve({
1091
+ function de({
1010
1092
  delayDuration: e = 0,
1011
1093
  ...t
1012
1094
  }) {
1013
- return /* @__PURE__ */ r(
1014
- O.Provider,
1095
+ return /* @__PURE__ */ a(
1096
+ E.Provider,
1015
1097
  {
1016
1098
  "data-slot": "tooltip-provider",
1017
1099
  delayDuration: e,
@@ -1019,48 +1101,48 @@ function ve({
1019
1101
  }
1020
1102
  );
1021
1103
  }
1022
- function st({
1104
+ function ot({
1023
1105
  ...e
1024
1106
  }) {
1025
- return /* @__PURE__ */ r(ve, { children: /* @__PURE__ */ r(O.Root, { "data-slot": "tooltip", ...e }) });
1107
+ return /* @__PURE__ */ a(de, { children: /* @__PURE__ */ a(E.Root, { "data-slot": "tooltip", ...e }) });
1026
1108
  }
1027
- function lt({
1109
+ function nt({
1028
1110
  ...e
1029
1111
  }) {
1030
- return /* @__PURE__ */ r(O.Trigger, { "data-slot": "tooltip-trigger", ...e });
1112
+ return /* @__PURE__ */ a(E.Trigger, { "data-slot": "tooltip-trigger", ...e });
1031
1113
  }
1032
- function dt({
1114
+ function it({
1033
1115
  className: e,
1034
1116
  sideOffset: t = 0,
1035
- children: a,
1036
- ...o
1117
+ children: r,
1118
+ ...n
1037
1119
  }) {
1038
- return /* @__PURE__ */ r(O.Portal, { children: /* @__PURE__ */ h(
1039
- O.Content,
1120
+ return /* @__PURE__ */ a(E.Portal, { children: /* @__PURE__ */ l(
1121
+ E.Content,
1040
1122
  {
1041
1123
  "data-slot": "tooltip-content",
1042
1124
  sideOffset: t,
1043
- className: i(
1125
+ className: o(
1044
1126
  "bg-primary text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 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 z-50 w-fit origin-(--radix-tooltip-content-transform-origin) rounded-md px-3 py-1.5 text-xs text-balance",
1045
1127
  e
1046
1128
  ),
1047
- ...o,
1129
+ ...n,
1048
1130
  children: [
1049
- a,
1050
- /* @__PURE__ */ r(O.Arrow, { className: "bg-primary fill-primary z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]" })
1131
+ r,
1132
+ /* @__PURE__ */ a(E.Arrow, { className: "bg-primary fill-primary z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px]" })
1051
1133
  ]
1052
1134
  }
1053
1135
  ) });
1054
1136
  }
1055
- function va({ ...e }) {
1056
- return /* @__PURE__ */ r("nav", { "aria-label": "breadcrumb", "data-slot": "breadcrumb", ...e });
1137
+ function vr({ ...e }) {
1138
+ return /* @__PURE__ */ a("nav", { "aria-label": "breadcrumb", "data-slot": "breadcrumb", ...e });
1057
1139
  }
1058
- function xa({ className: e, ...t }) {
1059
- return /* @__PURE__ */ r(
1140
+ function xr({ className: e, ...t }) {
1141
+ return /* @__PURE__ */ a(
1060
1142
  "ol",
1061
1143
  {
1062
1144
  "data-slot": "breadcrumb-list",
1063
- className: i(
1145
+ className: o(
1064
1146
  "text-muted-foreground flex flex-wrap items-center gap-1.5 text-sm break-words sm:gap-2.5",
1065
1147
  e
1066
1148
  ),
@@ -1068,450 +1150,756 @@ function xa({ className: e, ...t }) {
1068
1150
  }
1069
1151
  );
1070
1152
  }
1071
- function wa({ className: e, ...t }) {
1072
- return /* @__PURE__ */ r(
1153
+ function wr({ className: e, ...t }) {
1154
+ return /* @__PURE__ */ a(
1073
1155
  "li",
1074
1156
  {
1075
1157
  "data-slot": "breadcrumb-item",
1076
- className: i("inline-flex items-center gap-1.5", e),
1158
+ className: o("inline-flex items-center gap-1.5", e),
1077
1159
  ...t
1078
1160
  }
1079
1161
  );
1080
1162
  }
1081
- function Sa({
1163
+ function yr({
1082
1164
  asChild: e,
1083
1165
  className: t,
1084
- ...a
1166
+ ...r
1085
1167
  }) {
1086
- return /* @__PURE__ */ r(
1087
- e ? E : "a",
1168
+ return /* @__PURE__ */ a(
1169
+ e ? R : "a",
1088
1170
  {
1089
1171
  "data-slot": "breadcrumb-link",
1090
- className: i("hover:text-foreground transition-colors", t),
1091
- ...a
1172
+ className: o("hover:text-foreground transition-colors", t),
1173
+ ...r
1092
1174
  }
1093
1175
  );
1094
1176
  }
1095
- function ya({ className: e, ...t }) {
1096
- return /* @__PURE__ */ r(
1177
+ function Nr({ className: e, ...t }) {
1178
+ return /* @__PURE__ */ a(
1097
1179
  "span",
1098
1180
  {
1099
1181
  "data-slot": "breadcrumb-page",
1100
1182
  role: "link",
1101
1183
  "aria-disabled": "true",
1102
1184
  "aria-current": "page",
1103
- className: i("text-foreground font-normal", e),
1185
+ className: o("text-foreground font-normal", e),
1104
1186
  ...t
1105
1187
  }
1106
1188
  );
1107
1189
  }
1108
- function Na({
1190
+ function kr({
1109
1191
  children: e,
1110
1192
  className: t,
1111
- ...a
1193
+ ...r
1112
1194
  }) {
1113
- return /* @__PURE__ */ r(
1195
+ return /* @__PURE__ */ a(
1114
1196
  "li",
1115
1197
  {
1116
1198
  "data-slot": "breadcrumb-separator",
1117
1199
  role: "presentation",
1118
1200
  "aria-hidden": "true",
1119
- className: i("[&>svg]:size-3.5", t),
1120
- ...a,
1121
- children: e ?? /* @__PURE__ */ r(Fe, {})
1201
+ className: o("[&>svg]:size-3.5", t),
1202
+ ...r,
1203
+ children: e ?? /* @__PURE__ */ a(oe, {})
1122
1204
  }
1123
1205
  );
1124
1206
  }
1125
- function Ca({
1207
+ function Sr({
1126
1208
  ...e
1127
1209
  }) {
1128
- return /* @__PURE__ */ r(N.Root, { "data-slot": "select", ...e });
1210
+ return /* @__PURE__ */ a(N.Root, { "data-slot": "dialog", ...e });
1129
1211
  }
1130
- function Ta({
1212
+ function Cr({
1131
1213
  ...e
1132
1214
  }) {
1133
- return /* @__PURE__ */ r(N.Group, { "data-slot": "select-group", ...e });
1215
+ return /* @__PURE__ */ a(N.Trigger, { "data-slot": "dialog-trigger", ...e });
1134
1216
  }
1135
- function Pa({
1217
+ function st({
1136
1218
  ...e
1137
1219
  }) {
1138
- return /* @__PURE__ */ r(N.Value, { "data-slot": "select-value", ...e });
1220
+ return /* @__PURE__ */ a(N.Portal, { "data-slot": "dialog-portal", ...e });
1139
1221
  }
1140
- function za({
1222
+ function dt({
1141
1223
  className: e,
1142
- size: t = "default",
1143
- children: a,
1144
- ...o
1224
+ ...t
1145
1225
  }) {
1146
- return /* @__PURE__ */ h(
1147
- N.Trigger,
1226
+ return /* @__PURE__ */ a(
1227
+ N.Overlay,
1148
1228
  {
1149
- "data-slot": "select-trigger",
1150
- "data-size": t,
1151
- className: i(
1152
- "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
1229
+ "data-slot": "dialog-overlay",
1230
+ className: o(
1231
+ "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
1153
1232
  e
1154
1233
  ),
1155
- ...o,
1156
- children: [
1157
- a,
1158
- /* @__PURE__ */ r(N.Icon, { asChild: !0, children: /* @__PURE__ */ r(pe, { className: "size-4 opacity-50" }) })
1159
- ]
1234
+ ...t
1160
1235
  }
1161
1236
  );
1162
1237
  }
1163
- function _a({
1238
+ function zr({
1164
1239
  className: e,
1165
1240
  children: t,
1166
- position: a = "popper",
1167
- ...o
1241
+ showCloseButton: r = !0,
1242
+ ...n
1168
1243
  }) {
1169
- return /* @__PURE__ */ r(N.Portal, { children: /* @__PURE__ */ h(
1170
- N.Content,
1244
+ return /* @__PURE__ */ l(st, { "data-slot": "dialog-portal", children: [
1245
+ /* @__PURE__ */ a(dt, {}),
1246
+ /* @__PURE__ */ l(
1247
+ N.Content,
1248
+ {
1249
+ "data-slot": "dialog-content",
1250
+ className: o(
1251
+ "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",
1252
+ e
1253
+ ),
1254
+ ...n,
1255
+ children: [
1256
+ t,
1257
+ r && /* @__PURE__ */ l(
1258
+ N.Close,
1259
+ {
1260
+ "data-slot": "dialog-close",
1261
+ className: "ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
1262
+ children: [
1263
+ /* @__PURE__ */ a(ne, {}),
1264
+ /* @__PURE__ */ a("span", { className: "sr-only", children: "Close" })
1265
+ ]
1266
+ }
1267
+ )
1268
+ ]
1269
+ }
1270
+ )
1271
+ ] });
1272
+ }
1273
+ function _r({ className: e, ...t }) {
1274
+ return /* @__PURE__ */ a(
1275
+ "div",
1171
1276
  {
1172
- "data-slot": "select-content",
1173
- className: i(
1174
- "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",
1175
- a === "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",
1277
+ "data-slot": "dialog-header",
1278
+ className: o("flex flex-col gap-2 text-center sm:text-left", e),
1279
+ ...t
1280
+ }
1281
+ );
1282
+ }
1283
+ function Tr({ className: e, ...t }) {
1284
+ return /* @__PURE__ */ a(
1285
+ "div",
1286
+ {
1287
+ "data-slot": "dialog-footer",
1288
+ className: o(
1289
+ "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",
1176
1290
  e
1177
1291
  ),
1178
- position: a,
1179
- ...o,
1180
- children: [
1181
- /* @__PURE__ */ r(ct, {}),
1182
- /* @__PURE__ */ r(
1183
- N.Viewport,
1184
- {
1185
- className: i(
1186
- "p-1",
1187
- a === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"
1188
- ),
1189
- children: t
1190
- }
1191
- ),
1192
- /* @__PURE__ */ r(ut, {})
1193
- ]
1292
+ ...t
1194
1293
  }
1195
- ) });
1294
+ );
1196
1295
  }
1197
- function Ra({
1296
+ function Mr({
1198
1297
  className: e,
1199
1298
  ...t
1200
1299
  }) {
1201
- return /* @__PURE__ */ r(
1202
- N.Label,
1300
+ return /* @__PURE__ */ a(
1301
+ N.Title,
1203
1302
  {
1204
- "data-slot": "select-label",
1205
- className: i("text-muted-foreground px-2 py-1.5 text-xs", e),
1303
+ "data-slot": "dialog-title",
1304
+ className: o("text-lg leading-none font-semibold", e),
1206
1305
  ...t
1207
1306
  }
1208
1307
  );
1209
1308
  }
1210
- function ka({
1309
+ function Ir({
1211
1310
  className: e,
1212
- children: t,
1213
- ...a
1311
+ ...t
1214
1312
  }) {
1215
- return /* @__PURE__ */ h(
1216
- N.Item,
1313
+ return /* @__PURE__ */ a(
1314
+ N.Description,
1217
1315
  {
1218
- "data-slot": "select-item",
1219
- className: i(
1220
- "focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none 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",
1221
- e
1222
- ),
1223
- ...a,
1224
- children: [
1225
- /* @__PURE__ */ r("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ r(N.ItemIndicator, { children: /* @__PURE__ */ r(ne, { className: "size-4" }) }) }),
1226
- /* @__PURE__ */ r(N.ItemText, { children: t })
1227
- ]
1316
+ "data-slot": "dialog-description",
1317
+ className: o("text-muted-foreground text-sm", e),
1318
+ ...t
1228
1319
  }
1229
1320
  );
1230
1321
  }
1231
- function ct({
1322
+ function lt({
1232
1323
  className: e,
1233
1324
  ...t
1234
1325
  }) {
1235
- return /* @__PURE__ */ r(
1236
- N.ScrollUpButton,
1326
+ return /* @__PURE__ */ a(
1327
+ B,
1237
1328
  {
1238
- "data-slot": "select-scroll-up-button",
1239
- className: i(
1240
- "flex cursor-default items-center justify-center py-1",
1329
+ "data-slot": "command",
1330
+ className: o(
1331
+ "bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",
1241
1332
  e
1242
1333
  ),
1243
- ...t,
1244
- children: /* @__PURE__ */ r(Xe, { className: "size-4" })
1334
+ ...t
1245
1335
  }
1246
1336
  );
1247
1337
  }
1248
- function ut({
1338
+ function ct({
1249
1339
  className: e,
1250
1340
  ...t
1251
1341
  }) {
1252
- return /* @__PURE__ */ r(
1253
- N.ScrollDownButton,
1342
+ return /* @__PURE__ */ l(
1343
+ "div",
1254
1344
  {
1255
- "data-slot": "select-scroll-down-button",
1256
- className: i(
1257
- "flex cursor-default items-center justify-center py-1",
1258
- e
1259
- ),
1260
- ...t,
1261
- children: /* @__PURE__ */ r(pe, { className: "size-4" })
1345
+ "data-slot": "command-input-wrapper",
1346
+ className: "flex h-9 items-center gap-2 border-b px-3",
1347
+ children: [
1348
+ /* @__PURE__ */ a(Be, { className: "size-4 shrink-0 opacity-50" }),
1349
+ /* @__PURE__ */ a(
1350
+ B.Input,
1351
+ {
1352
+ "data-slot": "command-input",
1353
+ className: o(
1354
+ "placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",
1355
+ e
1356
+ ),
1357
+ ...t
1358
+ }
1359
+ )
1360
+ ]
1262
1361
  }
1263
1362
  );
1264
1363
  }
1265
- const re = 768;
1266
- function ft() {
1267
- const [e, t] = l.useState(void 0);
1268
- return l.useEffect(() => {
1269
- const a = window.matchMedia(`(max-width: ${re - 1}px)`), o = () => {
1270
- t(window.innerWidth < re);
1271
- };
1272
- return a.addEventListener("change", o), t(window.innerWidth < re), () => a.removeEventListener("change", o);
1273
- }, []), !!e;
1274
- }
1275
- function mt({
1364
+ function ut({
1276
1365
  className: e,
1277
- orientation: t = "horizontal",
1278
- decorative: a = !0,
1279
- ...o
1366
+ ...t
1280
1367
  }) {
1281
- return /* @__PURE__ */ r(
1282
- Ze.Root,
1368
+ return /* @__PURE__ */ a(
1369
+ B.List,
1283
1370
  {
1284
- "data-slot": "separator",
1285
- decorative: a,
1286
- orientation: t,
1287
- className: i(
1288
- "bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
1371
+ "data-slot": "command-list",
1372
+ className: o(
1373
+ "max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",
1289
1374
  e
1290
1375
  ),
1291
- ...o
1376
+ ...t
1292
1377
  }
1293
1378
  );
1294
1379
  }
1295
- function pt({ ...e }) {
1296
- return /* @__PURE__ */ r(k.Root, { "data-slot": "sheet", ...e });
1297
- }
1298
- function Ea({
1299
- ...e
1300
- }) {
1301
- return /* @__PURE__ */ r(k.Trigger, { "data-slot": "sheet-trigger", ...e });
1302
- }
1303
- function bt({
1380
+ function ft({
1304
1381
  ...e
1305
1382
  }) {
1306
- return /* @__PURE__ */ r(k.Portal, { "data-slot": "sheet-portal", ...e });
1383
+ return /* @__PURE__ */ a(
1384
+ B.Empty,
1385
+ {
1386
+ "data-slot": "command-empty",
1387
+ className: "py-6 text-center text-sm",
1388
+ ...e
1389
+ }
1390
+ );
1307
1391
  }
1308
- function gt({
1392
+ function mt({
1309
1393
  className: e,
1310
1394
  ...t
1311
1395
  }) {
1312
- return /* @__PURE__ */ r(
1313
- k.Overlay,
1396
+ return /* @__PURE__ */ a(
1397
+ B.Group,
1314
1398
  {
1315
- "data-slot": "sheet-overlay",
1316
- className: i(
1317
- "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
1399
+ "data-slot": "command-group",
1400
+ className: o(
1401
+ "text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",
1318
1402
  e
1319
1403
  ),
1320
1404
  ...t
1321
1405
  }
1322
1406
  );
1323
1407
  }
1324
- function ht({
1408
+ function pt({
1325
1409
  className: e,
1326
- children: t,
1327
- side: a = "right",
1328
- ...o
1410
+ ...t
1329
1411
  }) {
1330
- return /* @__PURE__ */ h(bt, { children: [
1331
- /* @__PURE__ */ r(gt, {}),
1332
- /* @__PURE__ */ h(
1333
- k.Content,
1412
+ return /* @__PURE__ */ a(
1413
+ B.Item,
1414
+ {
1415
+ "data-slot": "command-item",
1416
+ className: o(
1417
+ "data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
1418
+ e
1419
+ ),
1420
+ ...t
1421
+ }
1422
+ );
1423
+ }
1424
+ function Pr({
1425
+ ...e
1426
+ }) {
1427
+ return /* @__PURE__ */ a(z.Root, { "data-slot": "select", ...e });
1428
+ }
1429
+ function Rr({
1430
+ ...e
1431
+ }) {
1432
+ return /* @__PURE__ */ a(z.Group, { "data-slot": "select-group", ...e });
1433
+ }
1434
+ function Dr({
1435
+ ...e
1436
+ }) {
1437
+ return /* @__PURE__ */ a(z.Value, { "data-slot": "select-value", ...e });
1438
+ }
1439
+ function Er({
1440
+ className: e,
1441
+ size: t = "default",
1442
+ children: r,
1443
+ ...n
1444
+ }) {
1445
+ return /* @__PURE__ */ l(
1446
+ z.Trigger,
1447
+ {
1448
+ "data-slot": "select-trigger",
1449
+ "data-size": t,
1450
+ className: o(
1451
+ "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
1452
+ e
1453
+ ),
1454
+ ...n,
1455
+ children: [
1456
+ r,
1457
+ /* @__PURE__ */ a(z.Icon, { asChild: !0, children: /* @__PURE__ */ a(q, { className: "size-4 opacity-50" }) })
1458
+ ]
1459
+ }
1460
+ );
1461
+ }
1462
+ function Br({
1463
+ className: e,
1464
+ children: t,
1465
+ position: r = "popper",
1466
+ ...n
1467
+ }) {
1468
+ return /* @__PURE__ */ a(z.Portal, { children: /* @__PURE__ */ l(
1469
+ z.Content,
1470
+ {
1471
+ "data-slot": "select-content",
1472
+ className: o(
1473
+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border shadow-md",
1474
+ r === "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",
1475
+ e
1476
+ ),
1477
+ position: r,
1478
+ ...n,
1479
+ children: [
1480
+ /* @__PURE__ */ a(gt, {}),
1481
+ /* @__PURE__ */ a(
1482
+ z.Viewport,
1483
+ {
1484
+ className: o(
1485
+ "p-1",
1486
+ r === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"
1487
+ ),
1488
+ children: t
1489
+ }
1490
+ ),
1491
+ /* @__PURE__ */ a(bt, {})
1492
+ ]
1493
+ }
1494
+ ) });
1495
+ }
1496
+ function Lr({
1497
+ className: e,
1498
+ ...t
1499
+ }) {
1500
+ return /* @__PURE__ */ a(
1501
+ z.Label,
1502
+ {
1503
+ "data-slot": "select-label",
1504
+ className: o("text-muted-foreground px-2 py-1.5 text-xs", e),
1505
+ ...t
1506
+ }
1507
+ );
1508
+ }
1509
+ function Ar({
1510
+ className: e,
1511
+ children: t,
1512
+ ...r
1513
+ }) {
1514
+ return /* @__PURE__ */ l(
1515
+ z.Item,
1516
+ {
1517
+ "data-slot": "select-item",
1518
+ className: o(
1519
+ "focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none 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",
1520
+ e
1521
+ ),
1522
+ ...r,
1523
+ children: [
1524
+ /* @__PURE__ */ a("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ a(z.ItemIndicator, { children: /* @__PURE__ */ a($, { className: "size-4" }) }) }),
1525
+ /* @__PURE__ */ a(z.ItemText, { children: t })
1526
+ ]
1527
+ }
1528
+ );
1529
+ }
1530
+ function gt({
1531
+ className: e,
1532
+ ...t
1533
+ }) {
1534
+ return /* @__PURE__ */ a(
1535
+ z.ScrollUpButton,
1536
+ {
1537
+ "data-slot": "select-scroll-up-button",
1538
+ className: o(
1539
+ "flex cursor-default items-center justify-center py-1",
1540
+ e
1541
+ ),
1542
+ ...t,
1543
+ children: /* @__PURE__ */ a(Ae, { className: "size-4" })
1544
+ }
1545
+ );
1546
+ }
1547
+ function bt({
1548
+ className: e,
1549
+ ...t
1550
+ }) {
1551
+ return /* @__PURE__ */ a(
1552
+ z.ScrollDownButton,
1553
+ {
1554
+ "data-slot": "select-scroll-down-button",
1555
+ className: o(
1556
+ "flex cursor-default items-center justify-center py-1",
1557
+ e
1558
+ ),
1559
+ ...t,
1560
+ children: /* @__PURE__ */ a(q, { className: "size-4" })
1561
+ }
1562
+ );
1563
+ }
1564
+ function $r({
1565
+ options: e,
1566
+ placeholder: t = "Select option...",
1567
+ searchPlaceholder: r = "Search...",
1568
+ value: n,
1569
+ onChange: i,
1570
+ buttonClassName: s,
1571
+ contentClassName: c,
1572
+ disabled: d = !1,
1573
+ extraOptions: m,
1574
+ side: f = "bottom",
1575
+ align: p = "start",
1576
+ onlyIcon: b = !1
1577
+ }) {
1578
+ const [h, x] = u.useState(!1), [w, _] = u.useState(""), y = n ?? w, [g, v] = u.useState(""), M = u.useMemo(
1579
+ () => e.filter(
1580
+ (C) => C.label.toLowerCase().includes(g.toLowerCase())
1581
+ ),
1582
+ [e, g]
1583
+ ), P = (C) => {
1584
+ n === void 0 && _(C === y ? "" : C), i?.(C === y ? "" : C), x(!1);
1585
+ }, L = e.find((C) => C.value === y);
1586
+ return /* @__PURE__ */ l(Ze, { open: h, onOpenChange: x, children: [
1587
+ /* @__PURE__ */ a(et, { children: /* @__PURE__ */ l(
1588
+ Y,
1589
+ {
1590
+ variant: "outline",
1591
+ role: "combobox",
1592
+ "aria-expanded": h,
1593
+ className: o("w-full justify-between", s, {
1594
+ "has-[>svg]:px-2 px-2": b
1595
+ }),
1596
+ disabled: d,
1597
+ children: [
1598
+ /* @__PURE__ */ a(
1599
+ "span",
1600
+ {
1601
+ className: o("flex items-center gap-2", {
1602
+ "text-muted-foreground": !L && !!t
1603
+ }),
1604
+ children: L ? /* @__PURE__ */ a(W, { children: b ? L.icon : /* @__PURE__ */ l(W, { children: [
1605
+ L.icon,
1606
+ L.label
1607
+ ] }) }) : t
1608
+ }
1609
+ ),
1610
+ /* @__PURE__ */ a(Le, { className: "ml-2 h-4 w-4 shrink-0 opacity-50" })
1611
+ ]
1612
+ }
1613
+ ) }),
1614
+ /* @__PURE__ */ a(tt, { className: o("p-0", c), side: f, align: p, children: /* @__PURE__ */ l(lt, { children: [
1615
+ /* @__PURE__ */ a(
1616
+ ct,
1617
+ {
1618
+ placeholder: r,
1619
+ value: g,
1620
+ onValueChange: v
1621
+ }
1622
+ ),
1623
+ /* @__PURE__ */ l(ut, { children: [
1624
+ /* @__PURE__ */ a(ft, { children: "No option found." }),
1625
+ /* @__PURE__ */ l(mt, { children: [
1626
+ M.map((C) => /* @__PURE__ */ l(
1627
+ pt,
1628
+ {
1629
+ value: C.value,
1630
+ onSelect: (ke) => P(ke),
1631
+ children: [
1632
+ /* @__PURE__ */ a(
1633
+ $,
1634
+ {
1635
+ className: o(
1636
+ "mr-2 h-4 w-4",
1637
+ y === C.value ? "opacity-100" : "opacity-0"
1638
+ )
1639
+ }
1640
+ ),
1641
+ C.icon,
1642
+ C.label
1643
+ ]
1644
+ },
1645
+ C.value
1646
+ )),
1647
+ m
1648
+ ] })
1649
+ ] })
1650
+ ] }) })
1651
+ ] });
1652
+ }
1653
+ const U = 768;
1654
+ function ht() {
1655
+ const [e, t] = u.useState(void 0);
1656
+ return u.useEffect(() => {
1657
+ const r = window.matchMedia(`(max-width: ${U - 1}px)`), n = () => {
1658
+ t(window.innerWidth < U);
1659
+ };
1660
+ return r.addEventListener("change", n), t(window.innerWidth < U), () => r.removeEventListener("change", n);
1661
+ }, []), !!e;
1662
+ }
1663
+ function le({
1664
+ className: e,
1665
+ orientation: t = "horizontal",
1666
+ decorative: r = !0,
1667
+ ...n
1668
+ }) {
1669
+ return /* @__PURE__ */ a(
1670
+ Ue.Root,
1671
+ {
1672
+ "data-slot": "separator",
1673
+ decorative: r,
1674
+ orientation: t,
1675
+ className: o(
1676
+ "bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
1677
+ e
1678
+ ),
1679
+ ...n
1680
+ }
1681
+ );
1682
+ }
1683
+ function vt({ ...e }) {
1684
+ return /* @__PURE__ */ a(N.Root, { "data-slot": "sheet", ...e });
1685
+ }
1686
+ function jr({
1687
+ ...e
1688
+ }) {
1689
+ return /* @__PURE__ */ a(N.Trigger, { "data-slot": "sheet-trigger", ...e });
1690
+ }
1691
+ function xt({
1692
+ ...e
1693
+ }) {
1694
+ return /* @__PURE__ */ a(N.Portal, { "data-slot": "sheet-portal", ...e });
1695
+ }
1696
+ function wt({
1697
+ className: e,
1698
+ ...t
1699
+ }) {
1700
+ return /* @__PURE__ */ a(
1701
+ N.Overlay,
1702
+ {
1703
+ "data-slot": "sheet-overlay",
1704
+ className: o(
1705
+ "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",
1706
+ e
1707
+ ),
1708
+ ...t
1709
+ }
1710
+ );
1711
+ }
1712
+ function yt({
1713
+ className: e,
1714
+ children: t,
1715
+ side: r = "right",
1716
+ ...n
1717
+ }) {
1718
+ return /* @__PURE__ */ l(xt, { children: [
1719
+ /* @__PURE__ */ a(wt, {}),
1720
+ /* @__PURE__ */ l(
1721
+ N.Content,
1334
1722
  {
1335
1723
  "data-slot": "sheet-content",
1336
- className: i(
1724
+ className: o(
1337
1725
  "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",
1338
- a === "right" && "data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",
1339
- a === "left" && "data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",
1340
- a === "top" && "data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",
1341
- a === "bottom" && "data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",
1726
+ r === "right" && "data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",
1727
+ r === "left" && "data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",
1728
+ r === "top" && "data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",
1729
+ r === "bottom" && "data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",
1342
1730
  e
1343
1731
  ),
1344
- ...o,
1732
+ ...n,
1345
1733
  children: [
1346
1734
  t,
1347
- /* @__PURE__ */ h(k.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none", children: [
1348
- /* @__PURE__ */ r(Ye, { className: "size-4" }),
1349
- /* @__PURE__ */ r("span", { className: "sr-only", children: "Close" })
1735
+ /* @__PURE__ */ l(N.Close, { className: "ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none", children: [
1736
+ /* @__PURE__ */ a(ne, { className: "size-4" }),
1737
+ /* @__PURE__ */ a("span", { className: "sr-only", children: "Close" })
1350
1738
  ] })
1351
1739
  ]
1352
1740
  }
1353
1741
  )
1354
1742
  ] });
1355
1743
  }
1356
- function vt({ className: e, ...t }) {
1357
- return /* @__PURE__ */ r(
1744
+ function Nt({ className: e, ...t }) {
1745
+ return /* @__PURE__ */ a(
1358
1746
  "div",
1359
1747
  {
1360
1748
  "data-slot": "sheet-header",
1361
- className: i("flex flex-col gap-1.5 p-4", e),
1749
+ className: o("flex flex-col gap-1.5 p-4", e),
1362
1750
  ...t
1363
1751
  }
1364
1752
  );
1365
1753
  }
1366
- function Ma({ className: e, ...t }) {
1367
- return /* @__PURE__ */ r(
1754
+ function Or({ className: e, ...t }) {
1755
+ return /* @__PURE__ */ a(
1368
1756
  "div",
1369
1757
  {
1370
1758
  "data-slot": "sheet-footer",
1371
- className: i("mt-auto flex flex-col gap-2 p-4", e),
1759
+ className: o("mt-auto flex flex-col gap-2 p-4", e),
1372
1760
  ...t
1373
1761
  }
1374
1762
  );
1375
1763
  }
1376
- function xt({
1764
+ function kt({
1377
1765
  className: e,
1378
1766
  ...t
1379
1767
  }) {
1380
- return /* @__PURE__ */ r(
1381
- k.Title,
1768
+ return /* @__PURE__ */ a(
1769
+ N.Title,
1382
1770
  {
1383
1771
  "data-slot": "sheet-title",
1384
- className: i("text-foreground font-semibold", e),
1772
+ className: o("text-foreground font-semibold", e),
1385
1773
  ...t
1386
1774
  }
1387
1775
  );
1388
1776
  }
1389
- function wt({
1777
+ function St({
1390
1778
  className: e,
1391
1779
  ...t
1392
1780
  }) {
1393
- return /* @__PURE__ */ r(
1394
- k.Description,
1781
+ return /* @__PURE__ */ a(
1782
+ N.Description,
1395
1783
  {
1396
1784
  "data-slot": "sheet-description",
1397
- className: i("text-muted-foreground text-sm", e),
1785
+ className: o("text-muted-foreground text-sm", e),
1398
1786
  ...t
1399
1787
  }
1400
1788
  );
1401
1789
  }
1402
- const St = "sidebar_state", yt = 3600 * 24 * 7, Nt = "16rem", Ct = "18rem", Tt = "3rem", Pt = "b", xe = l.createContext(null);
1403
- function J() {
1404
- const e = l.useContext(xe);
1790
+ const Ct = "sidebar_state", zt = 3600 * 24 * 7, _t = "16rem", Tt = "18rem", Mt = "3rem", It = "b", ce = u.createContext(null);
1791
+ function G() {
1792
+ const e = u.useContext(ce);
1405
1793
  if (!e)
1406
1794
  throw new Error("useSidebar must be used within a SidebarProvider.");
1407
1795
  return e;
1408
1796
  }
1409
- function Aa({
1797
+ function Hr({
1410
1798
  defaultOpen: e = !0,
1411
1799
  open: t,
1412
- onOpenChange: a,
1413
- className: o,
1414
- style: n,
1800
+ onOpenChange: r,
1801
+ className: n,
1802
+ style: i,
1415
1803
  children: s,
1416
1804
  ...c
1417
1805
  }) {
1418
- const d = ft(), [u, f] = l.useState(!1), [m, b] = l.useState(e), p = t ?? m, g = l.useCallback(
1419
- (x) => {
1420
- const C = typeof x == "function" ? x(p) : x;
1421
- a ? a(C) : b(C), document.cookie = `${St}=${C}; path=/; max-age=${yt}`;
1806
+ const d = ht(), [m, f] = u.useState(!1), [p, b] = u.useState(e), h = t ?? p, x = u.useCallback(
1807
+ (g) => {
1808
+ const v = typeof g == "function" ? g(h) : g;
1809
+ r ? r(v) : b(v), document.cookie = `${Ct}=${v}; path=/; max-age=${zt}`;
1422
1810
  },
1423
- [a, p]
1424
- ), v = l.useCallback(() => d ? f((x) => !x) : g((x) => !x), [d, g, f]);
1425
- l.useEffect(() => {
1426
- const x = (C) => {
1427
- C.key === Pt && (C.metaKey || C.ctrlKey) && (C.preventDefault(), v());
1811
+ [r, h]
1812
+ ), w = u.useCallback(() => d ? f((g) => !g) : x((g) => !g), [d, x, f]);
1813
+ u.useEffect(() => {
1814
+ const g = (v) => {
1815
+ v.key === It && (v.metaKey || v.ctrlKey) && (v.preventDefault(), w());
1428
1816
  };
1429
- return window.addEventListener("keydown", x), () => window.removeEventListener("keydown", x);
1430
- }, [v]);
1431
- const T = p ? "expanded" : "collapsed", R = l.useMemo(
1817
+ return window.addEventListener("keydown", g), () => window.removeEventListener("keydown", g);
1818
+ }, [w]);
1819
+ const _ = h ? "expanded" : "collapsed", y = u.useMemo(
1432
1820
  () => ({
1433
- state: T,
1434
- open: p,
1435
- setOpen: g,
1821
+ state: _,
1822
+ open: h,
1823
+ setOpen: x,
1436
1824
  isMobile: d,
1437
- openMobile: u,
1825
+ openMobile: m,
1438
1826
  setOpenMobile: f,
1439
- toggleSidebar: v
1827
+ toggleSidebar: w
1440
1828
  }),
1441
- [T, p, g, d, u, f, v]
1829
+ [_, h, x, d, m, f, w]
1442
1830
  );
1443
- return /* @__PURE__ */ r(xe.Provider, { value: R, children: /* @__PURE__ */ r(ve, { delayDuration: 0, children: /* @__PURE__ */ r(
1831
+ return /* @__PURE__ */ a(ce.Provider, { value: y, children: /* @__PURE__ */ a(de, { delayDuration: 0, children: /* @__PURE__ */ a(
1444
1832
  "div",
1445
1833
  {
1446
1834
  "data-slot": "sidebar-wrapper",
1447
1835
  style: {
1448
- "--sidebar-width": Nt,
1449
- "--sidebar-width-icon": Tt,
1450
- ...n
1836
+ "--sidebar-width": _t,
1837
+ "--sidebar-width-icon": Mt,
1838
+ ...i
1451
1839
  },
1452
- className: i(
1840
+ className: o(
1453
1841
  "group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",
1454
- o
1842
+ n
1455
1843
  ),
1456
1844
  ...c,
1457
1845
  children: s
1458
1846
  }
1459
1847
  ) }) });
1460
1848
  }
1461
- function Da({
1849
+ function Gr({
1462
1850
  side: e = "left",
1463
1851
  variant: t = "sidebar",
1464
- collapsible: a = "offcanvas",
1465
- className: o,
1466
- children: n,
1852
+ collapsible: r = "offcanvas",
1853
+ className: n,
1854
+ children: i,
1467
1855
  ...s
1468
1856
  }) {
1469
- const { isMobile: c, state: d, openMobile: u, setOpenMobile: f } = J();
1470
- return a === "none" ? /* @__PURE__ */ r(
1857
+ const { isMobile: c, state: d, openMobile: m, setOpenMobile: f } = G();
1858
+ return r === "none" ? /* @__PURE__ */ a(
1471
1859
  "div",
1472
1860
  {
1473
1861
  "data-slot": "sidebar",
1474
- className: i(
1862
+ className: o(
1475
1863
  "bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",
1476
- o
1864
+ n
1477
1865
  ),
1478
1866
  ...s,
1479
- children: n
1867
+ children: i
1480
1868
  }
1481
- ) : c ? /* @__PURE__ */ r(pt, { open: u, onOpenChange: f, ...s, children: /* @__PURE__ */ h(
1482
- ht,
1869
+ ) : c ? /* @__PURE__ */ a(vt, { open: m, onOpenChange: f, ...s, children: /* @__PURE__ */ l(
1870
+ yt,
1483
1871
  {
1484
1872
  "data-sidebar": "sidebar",
1485
1873
  "data-slot": "sidebar",
1486
1874
  "data-mobile": "true",
1487
1875
  className: "bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",
1488
1876
  style: {
1489
- "--sidebar-width": Ct
1877
+ "--sidebar-width": Tt
1490
1878
  },
1491
1879
  side: e,
1492
1880
  children: [
1493
- /* @__PURE__ */ h(vt, { className: "sr-only", children: [
1494
- /* @__PURE__ */ r(xt, { children: "Sidebar" }),
1495
- /* @__PURE__ */ r(wt, { children: "Displays the mobile sidebar." })
1881
+ /* @__PURE__ */ l(Nt, { className: "sr-only", children: [
1882
+ /* @__PURE__ */ a(kt, { children: "Sidebar" }),
1883
+ /* @__PURE__ */ a(St, { children: "Displays the mobile sidebar." })
1496
1884
  ] }),
1497
- /* @__PURE__ */ r("div", { className: "flex h-full w-full flex-col", children: n })
1885
+ /* @__PURE__ */ a("div", { className: "flex h-full w-full flex-col", children: i })
1498
1886
  ]
1499
1887
  }
1500
- ) }) : /* @__PURE__ */ h(
1888
+ ) }) : /* @__PURE__ */ l(
1501
1889
  "div",
1502
1890
  {
1503
1891
  className: "group peer text-sidebar-foreground hidden md:block",
1504
1892
  "data-state": d,
1505
- "data-collapsible": d === "collapsed" ? a : "",
1893
+ "data-collapsible": d === "collapsed" ? r : "",
1506
1894
  "data-variant": t,
1507
1895
  "data-side": e,
1508
1896
  "data-slot": "sidebar",
1509
1897
  children: [
1510
- /* @__PURE__ */ r(
1898
+ /* @__PURE__ */ a(
1511
1899
  "div",
1512
1900
  {
1513
1901
  "data-slot": "sidebar-gap",
1514
- className: i(
1902
+ className: o(
1515
1903
  "relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear",
1516
1904
  "group-data-[collapsible=offcanvas]:w-0",
1517
1905
  "group-data-[side=right]:rotate-180",
@@ -1519,25 +1907,29 @@ function Da({
1519
1907
  )
1520
1908
  }
1521
1909
  ),
1522
- /* @__PURE__ */ r(
1910
+ /* @__PURE__ */ a(
1523
1911
  "div",
1524
1912
  {
1525
1913
  "data-slot": "sidebar-container",
1526
- className: i(
1914
+ className: o(
1527
1915
  "fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",
1528
1916
  e === "left" ? "left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]" : "right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",
1529
1917
  // Adjust the padding for floating and inset variants.
1530
- t === "floating" || t === "inset" ? "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",
1531
- o
1918
+ {
1919
+ "p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]": t === "floating" || t === "inset",
1920
+ "group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l": t !== "floating" && t !== "inset",
1921
+ static: t === "embed"
1922
+ },
1923
+ n
1532
1924
  ),
1533
1925
  ...s,
1534
- children: /* @__PURE__ */ r(
1926
+ children: /* @__PURE__ */ a(
1535
1927
  "div",
1536
1928
  {
1537
1929
  "data-sidebar": "sidebar",
1538
1930
  "data-slot": "sidebar-inner",
1539
1931
  className: "bg-sidebar group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",
1540
- children: n
1932
+ children: i
1541
1933
  }
1542
1934
  )
1543
1935
  }
@@ -1546,43 +1938,43 @@ function Da({
1546
1938
  }
1547
1939
  );
1548
1940
  }
1549
- function Ia({
1941
+ function Vr({
1550
1942
  className: e,
1551
1943
  onClick: t,
1552
- ...a
1944
+ ...r
1553
1945
  }) {
1554
- const { toggleSidebar: o } = J();
1555
- return /* @__PURE__ */ h(
1556
- ge,
1946
+ const { toggleSidebar: n } = G();
1947
+ return /* @__PURE__ */ l(
1948
+ Y,
1557
1949
  {
1558
1950
  "data-sidebar": "trigger",
1559
1951
  "data-slot": "sidebar-trigger",
1560
1952
  variant: "ghost",
1561
1953
  size: "icon",
1562
- className: i("size-7", e),
1563
- onClick: (n) => {
1564
- t?.(n), o();
1954
+ className: o("size-7", e),
1955
+ onClick: (i) => {
1956
+ t?.(i), n();
1565
1957
  },
1566
- ...a,
1958
+ ...r,
1567
1959
  children: [
1568
- /* @__PURE__ */ r($e, {}),
1569
- /* @__PURE__ */ r("span", { className: "sr-only", children: "Toggle Sidebar" })
1960
+ /* @__PURE__ */ a($e, {}),
1961
+ /* @__PURE__ */ a("span", { className: "sr-only", children: "Toggle Sidebar" })
1570
1962
  ]
1571
1963
  }
1572
1964
  );
1573
1965
  }
1574
- function La({ className: e, ...t }) {
1575
- const { toggleSidebar: a } = J();
1576
- return /* @__PURE__ */ r(
1966
+ function Fr({ className: e, ...t }) {
1967
+ const { toggleSidebar: r } = G();
1968
+ return /* @__PURE__ */ a(
1577
1969
  "button",
1578
1970
  {
1579
1971
  "data-sidebar": "rail",
1580
1972
  "data-slot": "sidebar-rail",
1581
1973
  "aria-label": "Toggle Sidebar",
1582
1974
  tabIndex: -1,
1583
- onClick: a,
1975
+ onClick: r,
1584
1976
  title: "Toggle Sidebar",
1585
- className: i(
1977
+ className: o(
1586
1978
  "hover:after:bg-sidebar-border absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] sm:flex",
1587
1979
  "in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize",
1588
1980
  "[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize",
@@ -1595,12 +1987,12 @@ function La({ className: e, ...t }) {
1595
1987
  }
1596
1988
  );
1597
1989
  }
1598
- function Oa({ className: e, ...t }) {
1599
- return /* @__PURE__ */ r(
1990
+ function Ur({ className: e, ...t }) {
1991
+ return /* @__PURE__ */ a(
1600
1992
  "main",
1601
1993
  {
1602
1994
  "data-slot": "sidebar-inset",
1603
- className: i(
1995
+ className: o(
1604
1996
  "bg-background relative flex w-full flex-1 flex-col",
1605
1997
  "md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",
1606
1998
  e
@@ -1609,63 +2001,63 @@ function Oa({ className: e, ...t }) {
1609
2001
  }
1610
2002
  );
1611
2003
  }
1612
- function Ba({
2004
+ function Wr({
1613
2005
  className: e,
1614
2006
  ...t
1615
2007
  }) {
1616
- return /* @__PURE__ */ r(
1617
- it,
2008
+ return /* @__PURE__ */ a(
2009
+ Qe,
1618
2010
  {
1619
2011
  "data-slot": "sidebar-input",
1620
2012
  "data-sidebar": "input",
1621
- className: i("bg-background h-8 w-full shadow-none", e),
2013
+ className: o("bg-background h-8 w-full shadow-none", e),
1622
2014
  ...t
1623
2015
  }
1624
2016
  );
1625
2017
  }
1626
- function Ha({ className: e, ...t }) {
1627
- return /* @__PURE__ */ r(
2018
+ function Kr({ className: e, ...t }) {
2019
+ return /* @__PURE__ */ a(
1628
2020
  "div",
1629
2021
  {
1630
2022
  "data-slot": "sidebar-header",
1631
2023
  "data-sidebar": "header",
1632
- className: i("flex flex-col gap-2 p-2", e),
2024
+ className: o("flex flex-col gap-2 p-2", e),
1633
2025
  ...t
1634
2026
  }
1635
2027
  );
1636
2028
  }
1637
- function Wa({ className: e, ...t }) {
1638
- return /* @__PURE__ */ r(
2029
+ function qr({ className: e, ...t }) {
2030
+ return /* @__PURE__ */ a(
1639
2031
  "div",
1640
2032
  {
1641
2033
  "data-slot": "sidebar-footer",
1642
2034
  "data-sidebar": "footer",
1643
- className: i("flex flex-col gap-2 p-2", e),
2035
+ className: o("flex flex-col gap-2 p-2", e),
1644
2036
  ...t
1645
2037
  }
1646
2038
  );
1647
2039
  }
1648
- function Ua({
2040
+ function Xr({
1649
2041
  className: e,
1650
2042
  ...t
1651
2043
  }) {
1652
- return /* @__PURE__ */ r(
1653
- mt,
2044
+ return /* @__PURE__ */ a(
2045
+ le,
1654
2046
  {
1655
2047
  "data-slot": "sidebar-separator",
1656
2048
  "data-sidebar": "separator",
1657
- className: i("bg-sidebar-border mx-2 w-auto", e),
2049
+ className: o("bg-sidebar-border mx-2 w-auto", e),
1658
2050
  ...t
1659
2051
  }
1660
2052
  );
1661
2053
  }
1662
- function Va({ className: e, ...t }) {
1663
- return /* @__PURE__ */ r(
2054
+ function Yr({ className: e, ...t }) {
2055
+ return /* @__PURE__ */ a(
1664
2056
  "div",
1665
2057
  {
1666
2058
  "data-slot": "sidebar-content",
1667
2059
  "data-sidebar": "content",
1668
- className: i(
2060
+ className: o(
1669
2061
  "flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",
1670
2062
  e
1671
2063
  ),
@@ -1673,94 +2065,94 @@ function Va({ className: e, ...t }) {
1673
2065
  }
1674
2066
  );
1675
2067
  }
1676
- function ja({ className: e, ...t }) {
1677
- return /* @__PURE__ */ r(
2068
+ function Jr({ className: e, ...t }) {
2069
+ return /* @__PURE__ */ a(
1678
2070
  "div",
1679
2071
  {
1680
2072
  "data-slot": "sidebar-group",
1681
2073
  "data-sidebar": "group",
1682
- className: i("relative flex w-full min-w-0 flex-col p-2", e),
2074
+ className: o("relative flex w-full min-w-0 flex-col p-2", e),
1683
2075
  ...t
1684
2076
  }
1685
2077
  );
1686
2078
  }
1687
- function Fa({
2079
+ function Qr({
1688
2080
  className: e,
1689
2081
  asChild: t = !1,
1690
- ...a
2082
+ ...r
1691
2083
  }) {
1692
- return /* @__PURE__ */ r(
1693
- t ? E : "div",
2084
+ return /* @__PURE__ */ a(
2085
+ t ? R : "div",
1694
2086
  {
1695
2087
  "data-slot": "sidebar-group-label",
1696
2088
  "data-sidebar": "group-label",
1697
- className: i(
2089
+ className: o(
1698
2090
  "text-sidebar-foreground/70 ring-sidebar-ring flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium outline-hidden transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
1699
2091
  "group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",
1700
2092
  e
1701
2093
  ),
1702
- ...a
2094
+ ...r
1703
2095
  }
1704
2096
  );
1705
2097
  }
1706
- function Xa({
2098
+ function Zr({
1707
2099
  className: e,
1708
2100
  asChild: t = !1,
1709
- ...a
2101
+ ...r
1710
2102
  }) {
1711
- return /* @__PURE__ */ r(
1712
- t ? E : "button",
2103
+ return /* @__PURE__ */ a(
2104
+ t ? R : "button",
1713
2105
  {
1714
2106
  "data-slot": "sidebar-group-action",
1715
2107
  "data-sidebar": "group-action",
1716
- className: i(
2108
+ className: o(
1717
2109
  "text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
1718
2110
  // Increases the hit area of the button on mobile.
1719
2111
  "after:absolute after:-inset-2 md:after:hidden",
1720
2112
  "group-data-[collapsible=icon]:hidden",
1721
2113
  e
1722
2114
  ),
1723
- ...a
2115
+ ...r
1724
2116
  }
1725
2117
  );
1726
2118
  }
1727
- function Ya({
2119
+ function eo({
1728
2120
  className: e,
1729
2121
  ...t
1730
2122
  }) {
1731
- return /* @__PURE__ */ r(
2123
+ return /* @__PURE__ */ a(
1732
2124
  "div",
1733
2125
  {
1734
2126
  "data-slot": "sidebar-group-content",
1735
2127
  "data-sidebar": "group-content",
1736
- className: i("w-full text-sm", e),
2128
+ className: o("w-full text-sm", e),
1737
2129
  ...t
1738
2130
  }
1739
2131
  );
1740
2132
  }
1741
- function $a({ className: e, ...t }) {
1742
- return /* @__PURE__ */ r(
2133
+ function to({ className: e, ...t }) {
2134
+ return /* @__PURE__ */ a(
1743
2135
  "ul",
1744
2136
  {
1745
2137
  "data-slot": "sidebar-menu",
1746
2138
  "data-sidebar": "menu",
1747
- className: i("flex w-full min-w-0 flex-col gap-1", e),
2139
+ className: o("flex w-full min-w-0 flex-col gap-1", e),
1748
2140
  ...t
1749
2141
  }
1750
2142
  );
1751
2143
  }
1752
- function Ga({ className: e, ...t }) {
1753
- return /* @__PURE__ */ r(
2144
+ function ao({ className: e, ...t }) {
2145
+ return /* @__PURE__ */ a(
1754
2146
  "li",
1755
2147
  {
1756
2148
  "data-slot": "sidebar-menu-item",
1757
2149
  "data-sidebar": "menu-item",
1758
- className: i("group/menu-item relative", e),
2150
+ className: o("group/menu-item relative", e),
1759
2151
  ...t
1760
2152
  }
1761
2153
  );
1762
2154
  }
1763
- const zt = oe(
2155
+ const Pt = O(
1764
2156
  "peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",
1765
2157
  {
1766
2158
  variants: {
@@ -1780,53 +2172,53 @@ const zt = oe(
1780
2172
  }
1781
2173
  }
1782
2174
  );
1783
- function Ka({
2175
+ function ro({
1784
2176
  asChild: e = !1,
1785
2177
  isActive: t = !1,
1786
- variant: a = "default",
1787
- size: o = "default",
1788
- tooltip: n,
2178
+ variant: r = "default",
2179
+ size: n = "default",
2180
+ tooltip: i,
1789
2181
  className: s,
1790
2182
  ...c
1791
2183
  }) {
1792
- const d = e ? E : "button", { isMobile: u, state: f } = J(), m = /* @__PURE__ */ r(
2184
+ const d = e ? R : "button", { isMobile: m, state: f } = G(), p = /* @__PURE__ */ a(
1793
2185
  d,
1794
2186
  {
1795
2187
  "data-slot": "sidebar-menu-button",
1796
2188
  "data-sidebar": "menu-button",
1797
- "data-size": o,
2189
+ "data-size": n,
1798
2190
  "data-active": t,
1799
- className: i(zt({ variant: a, size: o }), s),
2191
+ className: o(Pt({ variant: r, size: n }), s),
1800
2192
  ...c
1801
2193
  }
1802
2194
  );
1803
- return n ? (typeof n == "string" && (n = {
1804
- children: n
1805
- }), /* @__PURE__ */ h(st, { children: [
1806
- /* @__PURE__ */ r(lt, { asChild: !0, children: m }),
1807
- /* @__PURE__ */ r(
1808
- dt,
2195
+ return i ? (typeof i == "string" && (i = {
2196
+ children: i
2197
+ }), /* @__PURE__ */ l(ot, { children: [
2198
+ /* @__PURE__ */ a(nt, { asChild: !0, children: p }),
2199
+ /* @__PURE__ */ a(
2200
+ it,
1809
2201
  {
1810
2202
  side: "right",
1811
2203
  align: "center",
1812
- hidden: f !== "collapsed" || u,
1813
- ...n
2204
+ hidden: f !== "collapsed" || m,
2205
+ ...i
1814
2206
  }
1815
2207
  )
1816
- ] })) : m;
2208
+ ] })) : p;
1817
2209
  }
1818
- function qa({
2210
+ function oo({
1819
2211
  className: e,
1820
2212
  asChild: t = !1,
1821
- showOnHover: a = !1,
1822
- ...o
2213
+ showOnHover: r = !1,
2214
+ ...n
1823
2215
  }) {
1824
- return /* @__PURE__ */ r(
1825
- t ? E : "button",
2216
+ return /* @__PURE__ */ a(
2217
+ t ? R : "button",
1826
2218
  {
1827
2219
  "data-slot": "sidebar-menu-action",
1828
2220
  "data-sidebar": "menu-action",
1829
- className: i(
2221
+ className: o(
1830
2222
  "text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground peer-hover/menu-button:text-sidebar-accent-foreground absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
1831
2223
  // Increases the hit area of the button on mobile.
1832
2224
  "after:absolute after:-inset-2 md:after:hidden",
@@ -1834,23 +2226,23 @@ function qa({
1834
2226
  "peer-data-[size=default]/menu-button:top-1.5",
1835
2227
  "peer-data-[size=lg]/menu-button:top-2.5",
1836
2228
  "group-data-[collapsible=icon]:hidden",
1837
- a && "peer-data-[active=true]/menu-button:text-sidebar-accent-foreground group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 md:opacity-0",
2229
+ r && "peer-data-[active=true]/menu-button:text-sidebar-accent-foreground group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 md:opacity-0",
1838
2230
  e
1839
2231
  ),
1840
- ...o
2232
+ ...n
1841
2233
  }
1842
2234
  );
1843
2235
  }
1844
- function Ja({
2236
+ function no({
1845
2237
  className: e,
1846
2238
  ...t
1847
2239
  }) {
1848
- return /* @__PURE__ */ r(
2240
+ return /* @__PURE__ */ a(
1849
2241
  "div",
1850
2242
  {
1851
2243
  "data-slot": "sidebar-menu-badge",
1852
2244
  "data-sidebar": "menu-badge",
1853
- className: i(
2245
+ className: o(
1854
2246
  "text-sidebar-foreground pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums select-none",
1855
2247
  "peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground",
1856
2248
  "peer-data-[size=sm]/menu-button:top-1",
@@ -1863,34 +2255,34 @@ function Ja({
1863
2255
  }
1864
2256
  );
1865
2257
  }
1866
- function Qa({
2258
+ function io({
1867
2259
  className: e,
1868
2260
  showIcon: t = !1,
1869
- ...a
2261
+ ...r
1870
2262
  }) {
1871
- const o = l.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []);
1872
- return /* @__PURE__ */ h(
2263
+ const n = u.useMemo(() => `${Math.floor(Math.random() * 40) + 50}%`, []);
2264
+ return /* @__PURE__ */ l(
1873
2265
  "div",
1874
2266
  {
1875
2267
  "data-slot": "sidebar-menu-skeleton",
1876
2268
  "data-sidebar": "menu-skeleton",
1877
- className: i("flex h-8 items-center gap-2 rounded-md px-2", e),
1878
- ...a,
2269
+ className: o("flex h-8 items-center gap-2 rounded-md px-2", e),
2270
+ ...r,
1879
2271
  children: [
1880
- t && /* @__PURE__ */ r(
1881
- ce,
2272
+ t && /* @__PURE__ */ a(
2273
+ ee,
1882
2274
  {
1883
2275
  className: "size-4 rounded-md",
1884
2276
  "data-sidebar": "menu-skeleton-icon"
1885
2277
  }
1886
2278
  ),
1887
- /* @__PURE__ */ r(
1888
- ce,
2279
+ /* @__PURE__ */ a(
2280
+ ee,
1889
2281
  {
1890
2282
  className: "h-4 max-w-(--skeleton-width) flex-1",
1891
2283
  "data-sidebar": "menu-skeleton-text",
1892
2284
  style: {
1893
- "--skeleton-width": o
2285
+ "--skeleton-width": n
1894
2286
  }
1895
2287
  }
1896
2288
  )
@@ -1898,13 +2290,13 @@ function Qa({
1898
2290
  }
1899
2291
  );
1900
2292
  }
1901
- function Za({ className: e, ...t }) {
1902
- return /* @__PURE__ */ r(
2293
+ function so({ className: e, ...t }) {
2294
+ return /* @__PURE__ */ a(
1903
2295
  "ul",
1904
2296
  {
1905
2297
  "data-slot": "sidebar-menu-sub",
1906
2298
  "data-sidebar": "menu-sub",
1907
- className: i(
2299
+ className: o(
1908
2300
  "border-sidebar-border mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l px-2.5 py-0.5",
1909
2301
  "group-data-[collapsible=icon]:hidden",
1910
2302
  e
@@ -1913,963 +2305,1022 @@ function Za({ className: e, ...t }) {
1913
2305
  }
1914
2306
  );
1915
2307
  }
1916
- function eo({
2308
+ function lo({
1917
2309
  className: e,
1918
2310
  ...t
1919
2311
  }) {
1920
- return /* @__PURE__ */ r(
2312
+ return /* @__PURE__ */ a(
1921
2313
  "li",
1922
2314
  {
1923
2315
  "data-slot": "sidebar-menu-sub-item",
1924
2316
  "data-sidebar": "menu-sub-item",
1925
- className: i("group/menu-sub-item relative", e),
2317
+ className: o("group/menu-sub-item relative", e),
1926
2318
  ...t
1927
2319
  }
1928
2320
  );
1929
2321
  }
1930
- function to({
2322
+ function co({
1931
2323
  asChild: e = !1,
1932
2324
  size: t = "md",
1933
- isActive: a = !1,
1934
- className: o,
1935
- ...n
2325
+ isActive: r = !1,
2326
+ className: n,
2327
+ ...i
1936
2328
  }) {
1937
- return /* @__PURE__ */ r(
1938
- e ? E : "a",
2329
+ return /* @__PURE__ */ a(
2330
+ e ? R : "a",
1939
2331
  {
1940
2332
  "data-slot": "sidebar-menu-sub-button",
1941
2333
  "data-sidebar": "menu-sub-button",
1942
2334
  "data-size": t,
1943
- "data-active": a,
1944
- className: i(
2335
+ "data-active": r,
2336
+ className: o(
1945
2337
  "text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden focus-visible:ring-2 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",
1946
2338
  "data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",
1947
2339
  t === "sm" && "text-xs",
1948
2340
  t === "md" && "text-sm",
1949
2341
  "group-data-[collapsible=icon]:hidden",
1950
- o
2342
+ n
1951
2343
  ),
1952
- ...n
2344
+ ...i
1953
2345
  }
1954
2346
  );
1955
2347
  }
1956
- var _t = [
1957
- "a",
1958
- "button",
1959
- "div",
1960
- "form",
1961
- "h2",
1962
- "h3",
1963
- "img",
1964
- "input",
1965
- "label",
1966
- "li",
1967
- "nav",
1968
- "ol",
1969
- "p",
1970
- "select",
1971
- "span",
1972
- "svg",
1973
- "ul"
1974
- ], W = _t.reduce((e, t) => {
1975
- const a = He(`Primitive.${t}`), o = l.forwardRef((n, s) => {
1976
- const { asChild: c, ...d } = n, u = c ? a : t;
1977
- return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ r(u, { ...d, ref: s });
1978
- });
1979
- return o.displayName = `Primitive.${t}`, { ...e, [t]: o };
1980
- }, {});
1981
- function ue(e, t) {
1982
- if (typeof e == "function")
1983
- return e(t);
1984
- e != null && (e.current = t);
2348
+ function Rt({
2349
+ className: e,
2350
+ children: t,
2351
+ ...r
2352
+ }) {
2353
+ return /* @__PURE__ */ l(
2354
+ A.Root,
2355
+ {
2356
+ "data-slot": "scroll-area",
2357
+ className: o("relative", e),
2358
+ ...r,
2359
+ children: [
2360
+ /* @__PURE__ */ a(
2361
+ A.Viewport,
2362
+ {
2363
+ "data-slot": "scroll-area-viewport",
2364
+ className: "focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",
2365
+ children: t
2366
+ }
2367
+ ),
2368
+ /* @__PURE__ */ a(Dt, {}),
2369
+ /* @__PURE__ */ a(A.Corner, {})
2370
+ ]
2371
+ }
2372
+ );
1985
2373
  }
1986
- function Rt(...e) {
1987
- return (t) => {
1988
- let a = !1;
1989
- const o = e.map((n) => {
1990
- const s = ue(n, t);
1991
- return !a && typeof s == "function" && (a = !0), s;
1992
- });
1993
- if (a)
1994
- return () => {
1995
- for (let n = 0; n < o.length; n++) {
1996
- const s = o[n];
1997
- typeof s == "function" ? s() : ue(e[n], null);
2374
+ function Dt({
2375
+ className: e,
2376
+ orientation: t = "vertical",
2377
+ ...r
2378
+ }) {
2379
+ return /* @__PURE__ */ a(
2380
+ A.ScrollAreaScrollbar,
2381
+ {
2382
+ "data-slot": "scroll-area-scrollbar",
2383
+ orientation: t,
2384
+ className: o(
2385
+ "flex touch-none p-px transition-colors select-none",
2386
+ t === "vertical" && "h-full w-2.5 border-l border-l-transparent",
2387
+ t === "horizontal" && "h-2.5 flex-col border-t border-t-transparent",
2388
+ e
2389
+ ),
2390
+ ...r,
2391
+ children: /* @__PURE__ */ a(
2392
+ A.ScrollAreaThumb,
2393
+ {
2394
+ "data-slot": "scroll-area-thumb",
2395
+ className: "bg-border relative flex-1 rounded-full"
1998
2396
  }
1999
- };
2000
- };
2001
- }
2002
- function I(...e) {
2003
- return l.useCallback(Rt(...e), e);
2397
+ )
2398
+ }
2399
+ );
2004
2400
  }
2005
- var ae = globalThis?.document ? l.useLayoutEffect : () => {
2006
- };
2007
- function kt(e, t) {
2008
- return l.useReducer((a, o) => t[a][o] ?? a, e);
2401
+ function uo({
2402
+ item: e,
2403
+ children: t,
2404
+ keyClassName: r = "font-semibold min-w-1/2",
2405
+ valueClassName: n = "ml-4",
2406
+ rowClassName: i = "flex flex-row items-center text-lg py-3",
2407
+ itemClassName: s = "flex flex-col"
2408
+ }) {
2409
+ return /* @__PURE__ */ a("div", { className: s, children: /* @__PURE__ */ l("div", { className: i, children: [
2410
+ /* @__PURE__ */ a("span", { className: r, children: e }),
2411
+ /* @__PURE__ */ a("span", { className: n, children: t })
2412
+ ] }) });
2009
2413
  }
2010
- var U = (e) => {
2011
- const { present: t, children: a } = e, o = Et(t), n = typeof a == "function" ? a({ present: o.isPresent }) : l.Children.only(a), s = I(o.ref, Mt(n));
2012
- return typeof a == "function" || o.isPresent ? l.cloneElement(n, { ref: s }) : null;
2013
- };
2014
- U.displayName = "Presence";
2015
- function Et(e) {
2016
- const [t, a] = l.useState(), o = l.useRef(null), n = l.useRef(e), s = l.useRef("none"), c = e ? "mounted" : "unmounted", [d, u] = kt(c, {
2017
- mounted: {
2018
- UNMOUNT: "unmounted",
2019
- ANIMATION_OUT: "unmountSuspended"
2020
- },
2021
- unmountSuspended: {
2022
- MOUNT: "mounted",
2023
- ANIMATION_END: "unmounted"
2414
+ function fo({
2415
+ children: e,
2416
+ separatorClassName: t = "w-full"
2417
+ }) {
2418
+ const r = I.Children.toArray(e);
2419
+ return /* @__PURE__ */ a("div", { className: "flex flex-col", children: r.map((n, i) => /* @__PURE__ */ l(I.Fragment, { children: [
2420
+ n,
2421
+ i !== r.length - 1 && /* @__PURE__ */ a(le, { className: t })
2422
+ ] }, i)) });
2423
+ }
2424
+ function mo({
2425
+ className: e,
2426
+ ...t
2427
+ }) {
2428
+ return /* @__PURE__ */ a(
2429
+ Z.Root,
2430
+ {
2431
+ "data-slot": "checkbox",
2432
+ className: o(
2433
+ "peer border-input dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",
2434
+ e
2435
+ ),
2436
+ ...t,
2437
+ children: /* @__PURE__ */ a(
2438
+ Z.Indicator,
2439
+ {
2440
+ "data-slot": "checkbox-indicator",
2441
+ className: "flex items-center justify-center text-current transition-none",
2442
+ children: /* @__PURE__ */ a($, { className: "size-3.5" })
2443
+ }
2444
+ )
2445
+ }
2446
+ );
2447
+ }
2448
+ const po = ({
2449
+ className: e,
2450
+ title: t,
2451
+ description: r,
2452
+ icon: n,
2453
+ children: i
2454
+ }) => /* @__PURE__ */ a("div", { className: o("flex justify-center items-center w-full h-full grow", e), children: /* @__PURE__ */ l(
2455
+ "div",
2456
+ {
2457
+ className: o(
2458
+ "flex flex-col gap-4 items-center w-[400px] p-8"
2459
+ ),
2460
+ children: [
2461
+ n,
2462
+ /* @__PURE__ */ a("h1", { className: "text-2xl font-bold", children: t }),
2463
+ /* @__PURE__ */ a("p", { className: "text-sm text-muted-foreground text-center", children: r }),
2464
+ i
2465
+ ]
2466
+ }
2467
+ ) }), go = I.forwardRef(({
2468
+ data: e,
2469
+ initialSelectedItemId: t,
2470
+ onSelectChange: r,
2471
+ expandAll: n,
2472
+ folderIcon: i,
2473
+ itemIcon: s,
2474
+ className: c,
2475
+ ...d
2476
+ }, m) => {
2477
+ const [f, p] = I.useState(t), b = I.useCallback((y) => {
2478
+ p(y?.id), r && r(y);
2479
+ }, [r]), h = I.useMemo(() => {
2480
+ if (!t)
2481
+ return [];
2482
+ const y = [];
2483
+ function g(v, M) {
2484
+ if (v instanceof Array)
2485
+ for (let P = 0; P < v.length; P++) {
2486
+ if (y.push(v[P].id), g(v[P], M) && !n)
2487
+ return !0;
2488
+ n || y.pop();
2489
+ }
2490
+ else {
2491
+ if (!n && v.id === M)
2492
+ return !0;
2493
+ if (v.children)
2494
+ return g(v.children, M);
2495
+ }
2496
+ }
2497
+ return g(e, t), y;
2498
+ }, [e, t, n]), { ref: x, width: w, height: _ } = We();
2499
+ return /* @__PURE__ */ a("div", { ref: x, className: o("overflow-hidden", c), children: /* @__PURE__ */ a(Rt, { style: { width: w, height: _ }, children: /* @__PURE__ */ a("div", { className: "relative p-2", children: /* @__PURE__ */ a(
2500
+ ue,
2501
+ {
2502
+ data: e,
2503
+ ref: m,
2504
+ selectedItemId: f,
2505
+ handleSelectChange: b,
2506
+ expandedItemIds: h,
2507
+ FolderIcon: i,
2508
+ ItemIcon: s,
2509
+ ...d
2510
+ }
2511
+ ) }) }) });
2512
+ }), ue = I.forwardRef(({ className: e, data: t, selectedItemId: r, handleSelectChange: n, expandedItemIds: i, FolderIcon: s, ItemIcon: c, ...d }, m) => /* @__PURE__ */ a("div", { ref: m, role: "tree", className: e, ...d, children: /* @__PURE__ */ a("ul", { children: t instanceof Array ? t.map((f) => /* @__PURE__ */ a("li", { children: f.children ? /* @__PURE__ */ a(T.Root, { type: "multiple", defaultValue: i, children: /* @__PURE__ */ l(T.Item, { value: f.id, children: [
2513
+ /* @__PURE__ */ l(
2514
+ fe,
2515
+ {
2516
+ className: o(
2517
+ "px-2 hover:before:opacity-100 before:absolute before:left-0 before:w-full before:opacity-0 before:bg-muted/80 before:h-[1.75rem] before:-z-10",
2518
+ r === f.id && "before:opacity-100 before:bg-accent text-accent-foreground before:border-l-2 before:border-l-accent-foreground/50 dark:before:border-0"
2519
+ ),
2520
+ onClick: () => n(f),
2521
+ children: [
2522
+ f.icon && /* @__PURE__ */ a(
2523
+ f.icon,
2524
+ {
2525
+ className: "h-4 w-4 shrink-0 mr-2 text-accent-foreground/50",
2526
+ "aria-hidden": "true"
2527
+ }
2528
+ ),
2529
+ !f.icon && s && /* @__PURE__ */ a(
2530
+ s,
2531
+ {
2532
+ className: "h-4 w-4 shrink-0 mr-2 text-accent-foreground/50",
2533
+ "aria-hidden": "true"
2534
+ }
2535
+ ),
2536
+ /* @__PURE__ */ a("span", { className: "text-sm truncate", children: f.name })
2537
+ ]
2538
+ }
2539
+ ),
2540
+ /* @__PURE__ */ a(me, { className: "pl-6", children: /* @__PURE__ */ a(
2541
+ ue,
2542
+ {
2543
+ data: f.children ? f.children : f,
2544
+ selectedItemId: r,
2545
+ handleSelectChange: n,
2546
+ expandedItemIds: i,
2547
+ FolderIcon: s,
2548
+ ItemIcon: c
2549
+ }
2550
+ ) })
2551
+ ] }) }) : /* @__PURE__ */ a(
2552
+ te,
2553
+ {
2554
+ item: f,
2555
+ isSelected: r === f.id,
2556
+ onClick: () => n(f),
2557
+ Icon: c
2558
+ }
2559
+ ) }, f.id)) : /* @__PURE__ */ a("li", { children: /* @__PURE__ */ a(
2560
+ te,
2561
+ {
2562
+ item: t,
2563
+ isSelected: r === t.id,
2564
+ onClick: () => n(t),
2565
+ Icon: c
2566
+ }
2567
+ ) }) }) })), te = I.forwardRef(({ className: e, item: t, isSelected: r, Icon: n, ...i }, s) => /* @__PURE__ */ l(
2568
+ "div",
2569
+ {
2570
+ ref: s,
2571
+ className: o(
2572
+ "flex items-center py-2 px-2 cursor-pointer hover:before:opacity-100 before:absolute before:left-0 before:right-1 before:w-full before:opacity-0 before:bg-muted/80 before:h-[1.75rem] before:-z-10",
2573
+ e,
2574
+ r && "before:opacity-100 before:bg-accent text-accent-foreground before:border-l-2 before:border-l-accent-foreground/50 dark:before:border-0"
2575
+ ),
2576
+ ...i,
2577
+ children: [
2578
+ t.icon && /* @__PURE__ */ a(t.icon, { className: "h-4 w-4 shrink-0 mr-2 text-accent-foreground/50", "aria-hidden": "true" }),
2579
+ !t.icon && n && /* @__PURE__ */ a(n, { className: "h-4 w-4 shrink-0 mr-2 text-accent-foreground/50", "aria-hidden": "true" }),
2580
+ /* @__PURE__ */ a("span", { className: "flex-grow text-sm truncate", children: t.name })
2581
+ ]
2582
+ }
2583
+ )), fe = I.forwardRef(({ className: e, children: t, ...r }, n) => /* @__PURE__ */ a(T.Header, { children: /* @__PURE__ */ l(
2584
+ T.Trigger,
2585
+ {
2586
+ ref: n,
2587
+ className: o(
2588
+ "flex flex-1 w-full items-center py-2 transition-all last:[&[data-state=open]>svg]:rotate-90",
2589
+ e
2590
+ ),
2591
+ ...r,
2592
+ children: [
2593
+ t,
2594
+ /* @__PURE__ */ a(oe, { className: "h-4 w-4 shrink-0 transition-transform duration-200 text-accent-foreground/50 ml-auto" })
2595
+ ]
2596
+ }
2597
+ ) }));
2598
+ fe.displayName = T.Trigger.displayName;
2599
+ const me = I.forwardRef(({ className: e, children: t, ...r }, n) => /* @__PURE__ */ a(
2600
+ T.Content,
2601
+ {
2602
+ ref: n,
2603
+ className: o(
2604
+ "overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",
2605
+ e
2606
+ ),
2607
+ ...r,
2608
+ children: /* @__PURE__ */ a("div", { className: "pb-1 pt-0", children: t })
2609
+ }
2610
+ ));
2611
+ me.displayName = T.Content.displayName;
2612
+ function bo({
2613
+ ...e
2614
+ }) {
2615
+ return /* @__PURE__ */ a(T.Root, { "data-slot": "accordion", ...e });
2616
+ }
2617
+ function ho({
2618
+ className: e,
2619
+ ...t
2620
+ }) {
2621
+ return /* @__PURE__ */ a(
2622
+ T.Item,
2623
+ {
2624
+ "data-slot": "accordion-item",
2625
+ className: o("border-b last:border-b-0", e),
2626
+ ...t
2627
+ }
2628
+ );
2629
+ }
2630
+ function vo({
2631
+ className: e,
2632
+ children: t,
2633
+ ...r
2634
+ }) {
2635
+ return /* @__PURE__ */ a(T.Header, { className: "flex", children: /* @__PURE__ */ l(
2636
+ T.Trigger,
2637
+ {
2638
+ "data-slot": "accordion-trigger",
2639
+ className: o(
2640
+ "focus-visible:border-ring focus-visible:ring-ring/50 flex flex-1 items-start justify-between gap-4 rounded-md py-4 text-left text-sm font-medium transition-all outline-none hover:underline focus-visible:ring-[3px] disabled:pointer-events-none disabled:opacity-50 [&[data-state=open]>svg]:rotate-180",
2641
+ e
2642
+ ),
2643
+ ...r,
2644
+ children: [
2645
+ t,
2646
+ /* @__PURE__ */ a(q, { className: "text-muted-foreground pointer-events-none size-4 shrink-0 translate-y-0.5 transition-transform duration-200" })
2647
+ ]
2648
+ }
2649
+ ) });
2650
+ }
2651
+ function xo({
2652
+ className: e,
2653
+ children: t,
2654
+ ...r
2655
+ }) {
2656
+ return /* @__PURE__ */ a(
2657
+ T.Content,
2658
+ {
2659
+ "data-slot": "accordion-content",
2660
+ className: "data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down overflow-hidden text-sm",
2661
+ ...r,
2662
+ children: /* @__PURE__ */ a("div", { className: o("pt-0 pb-4", e), children: t })
2663
+ }
2664
+ );
2665
+ }
2666
+ function wo({
2667
+ className: e,
2668
+ ...t
2669
+ }) {
2670
+ return /* @__PURE__ */ a(
2671
+ X.PanelGroup,
2672
+ {
2673
+ "data-slot": "resizable-panel-group",
2674
+ className: o(
2675
+ "flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
2676
+ e
2677
+ ),
2678
+ ...t
2679
+ }
2680
+ );
2681
+ }
2682
+ function yo({
2683
+ ...e
2684
+ }) {
2685
+ return /* @__PURE__ */ a(X.Panel, { "data-slot": "resizable-panel", ...e });
2686
+ }
2687
+ function No({
2688
+ withHandle: e,
2689
+ className: t,
2690
+ ...r
2691
+ }) {
2692
+ return /* @__PURE__ */ a(
2693
+ X.PanelResizeHandle,
2694
+ {
2695
+ "data-slot": "resizable-handle",
2696
+ className: o(
2697
+ "bg-border focus-visible:ring-ring relative flex w-px items-center justify-center after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-offset-1 focus-visible:outline-hidden data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:translate-x-0 data-[panel-group-direction=vertical]:after:-translate-y-1/2 [&[data-panel-group-direction=vertical]>div]:rotate-90",
2698
+ t
2699
+ ),
2700
+ ...r,
2701
+ children: e && /* @__PURE__ */ a("div", { className: "bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border", children: /* @__PURE__ */ a(je, { className: "size-2.5" }) })
2702
+ }
2703
+ );
2704
+ }
2705
+ const Et = O(
2706
+ "relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",
2707
+ {
2708
+ variants: {
2709
+ variant: {
2710
+ default: "bg-card text-card-foreground",
2711
+ destructive: "text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90"
2712
+ }
2024
2713
  },
2025
- unmounted: {
2026
- MOUNT: "mounted"
2714
+ defaultVariants: {
2715
+ variant: "default"
2027
2716
  }
2028
- });
2029
- return l.useEffect(() => {
2030
- const f = Y(o.current);
2031
- s.current = d === "mounted" ? f : "none";
2032
- }, [d]), ae(() => {
2033
- const f = o.current, m = n.current;
2034
- if (m !== e) {
2035
- const p = s.current, g = Y(f);
2036
- e ? u("MOUNT") : g === "none" || f?.display === "none" ? u("UNMOUNT") : u(m && p !== g ? "ANIMATION_OUT" : "UNMOUNT"), n.current = e;
2037
- }
2038
- }, [e, u]), ae(() => {
2039
- if (t) {
2040
- let f;
2041
- const m = t.ownerDocument.defaultView ?? window, b = (g) => {
2042
- const T = Y(o.current).includes(g.animationName);
2043
- if (g.target === t && T && (u("ANIMATION_END"), !n.current)) {
2044
- const R = t.style.animationFillMode;
2045
- t.style.animationFillMode = "forwards", f = m.setTimeout(() => {
2046
- t.style.animationFillMode === "forwards" && (t.style.animationFillMode = R);
2047
- });
2717
+ }
2718
+ );
2719
+ function ko({
2720
+ className: e,
2721
+ variant: t,
2722
+ ...r
2723
+ }) {
2724
+ return /* @__PURE__ */ a(
2725
+ "div",
2726
+ {
2727
+ "data-slot": "alert",
2728
+ role: "alert",
2729
+ className: o(Et({ variant: t }), e),
2730
+ ...r
2731
+ }
2732
+ );
2733
+ }
2734
+ function So({ className: e, ...t }) {
2735
+ return /* @__PURE__ */ a(
2736
+ "div",
2737
+ {
2738
+ "data-slot": "alert-title",
2739
+ className: o(
2740
+ "col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",
2741
+ e
2742
+ ),
2743
+ ...t
2744
+ }
2745
+ );
2746
+ }
2747
+ function Co({
2748
+ className: e,
2749
+ ...t
2750
+ }) {
2751
+ return /* @__PURE__ */ a(
2752
+ "div",
2753
+ {
2754
+ "data-slot": "alert-description",
2755
+ className: o(
2756
+ "text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",
2757
+ e
2758
+ ),
2759
+ ...t
2760
+ }
2761
+ );
2762
+ }
2763
+ function zo({
2764
+ icon: e,
2765
+ size: t = 24,
2766
+ className: r,
2767
+ ...n
2768
+ }) {
2769
+ return /* @__PURE__ */ a(
2770
+ "span",
2771
+ {
2772
+ className: o(
2773
+ "inline-flex items-center justify-center rounded-md bg-icon dark:bg-icon",
2774
+ r
2775
+ ),
2776
+ ...n,
2777
+ children: u.cloneElement(e, {
2778
+ width: t,
2779
+ height: t,
2780
+ className: o(
2781
+ "stroke-icon-foreground dark:stroke-icon-foreground",
2782
+ e.props.className
2783
+ ),
2784
+ "aria-hidden": !0,
2785
+ focusable: !1
2786
+ })
2787
+ }
2788
+ );
2789
+ }
2790
+ function Bt(e, t, { checkForDefaultPrevented: r = !0 } = {}) {
2791
+ return function(i) {
2792
+ if (e?.(i), r === !1 || !i.defaultPrevented)
2793
+ return t?.(i);
2794
+ };
2795
+ }
2796
+ function ae(e, t) {
2797
+ if (typeof e == "function")
2798
+ return e(t);
2799
+ e != null && (e.current = t);
2800
+ }
2801
+ function Lt(...e) {
2802
+ return (t) => {
2803
+ let r = !1;
2804
+ const n = e.map((i) => {
2805
+ const s = ae(i, t);
2806
+ return !r && typeof s == "function" && (r = !0), s;
2807
+ });
2808
+ if (r)
2809
+ return () => {
2810
+ for (let i = 0; i < n.length; i++) {
2811
+ const s = n[i];
2812
+ typeof s == "function" ? s() : ae(e[i], null);
2048
2813
  }
2049
- }, p = (g) => {
2050
- g.target === t && (s.current = Y(o.current));
2051
2814
  };
2052
- return t.addEventListener("animationstart", p), t.addEventListener("animationcancel", b), t.addEventListener("animationend", b), () => {
2053
- m.clearTimeout(f), t.removeEventListener("animationstart", p), t.removeEventListener("animationcancel", b), t.removeEventListener("animationend", b);
2054
- };
2055
- } else
2056
- u("ANIMATION_END");
2057
- }, [t, u]), {
2058
- isPresent: ["mounted", "unmountSuspended"].includes(d),
2059
- ref: l.useCallback((f) => {
2060
- o.current = f ? getComputedStyle(f) : null, a(f);
2061
- }, [])
2062
2815
  };
2063
2816
  }
2064
- function Y(e) {
2065
- return e?.animationName || "none";
2066
- }
2067
- function Mt(e) {
2068
- let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, a = t && "isReactWarning" in t && t.isReactWarning;
2069
- return a ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, a = t && "isReactWarning" in t && t.isReactWarning, a ? e.props.ref : e.props.ref || e.ref);
2817
+ function pe(...e) {
2818
+ return u.useCallback(Lt(...e), e);
2070
2819
  }
2071
2820
  function At(e, t = []) {
2072
- let a = [];
2073
- function o(s, c) {
2074
- const d = l.createContext(c), u = a.length;
2075
- a = [...a, c];
2821
+ let r = [];
2822
+ function n(s, c) {
2823
+ const d = u.createContext(c), m = r.length;
2824
+ r = [...r, c];
2076
2825
  const f = (b) => {
2077
- const { scope: p, children: g, ...v } = b, T = p?.[e]?.[u] || d, R = l.useMemo(() => v, Object.values(v));
2078
- return /* @__PURE__ */ r(T.Provider, { value: R, children: g });
2826
+ const { scope: h, children: x, ...w } = b, _ = h?.[e]?.[m] || d, y = u.useMemo(() => w, Object.values(w));
2827
+ return /* @__PURE__ */ a(_.Provider, { value: y, children: x });
2079
2828
  };
2080
2829
  f.displayName = s + "Provider";
2081
- function m(b, p) {
2082
- const g = p?.[e]?.[u] || d, v = l.useContext(g);
2083
- if (v) return v;
2830
+ function p(b, h) {
2831
+ const x = h?.[e]?.[m] || d, w = u.useContext(x);
2832
+ if (w) return w;
2084
2833
  if (c !== void 0) return c;
2085
2834
  throw new Error(`\`${b}\` must be used within \`${s}\``);
2086
2835
  }
2087
- return [f, m];
2836
+ return [f, p];
2088
2837
  }
2089
- const n = () => {
2090
- const s = a.map((c) => l.createContext(c));
2838
+ const i = () => {
2839
+ const s = r.map((c) => u.createContext(c));
2091
2840
  return function(d) {
2092
- const u = d?.[e] || s;
2093
- return l.useMemo(
2094
- () => ({ [`__scope${e}`]: { ...d, [e]: u } }),
2095
- [d, u]
2841
+ const m = d?.[e] || s;
2842
+ return u.useMemo(
2843
+ () => ({ [`__scope${e}`]: { ...d, [e]: m } }),
2844
+ [d, m]
2096
2845
  );
2097
2846
  };
2098
2847
  };
2099
- return n.scopeName = e, [o, Dt(n, ...t)];
2848
+ return i.scopeName = e, [n, $t(i, ...t)];
2100
2849
  }
2101
- function Dt(...e) {
2850
+ function $t(...e) {
2102
2851
  const t = e[0];
2103
2852
  if (e.length === 1) return t;
2104
- const a = () => {
2105
- const o = e.map((n) => ({
2106
- useScope: n(),
2107
- scopeName: n.scopeName
2853
+ const r = () => {
2854
+ const n = e.map((i) => ({
2855
+ useScope: i(),
2856
+ scopeName: i.scopeName
2108
2857
  }));
2109
2858
  return function(s) {
2110
- const c = o.reduce((d, { useScope: u, scopeName: f }) => {
2111
- const b = u(s)[`__scope${f}`];
2859
+ const c = n.reduce((d, { useScope: m, scopeName: f }) => {
2860
+ const b = m(s)[`__scope${f}`];
2112
2861
  return { ...d, ...b };
2113
2862
  }, {});
2114
- return l.useMemo(() => ({ [`__scope${t.scopeName}`]: c }), [c]);
2863
+ return u.useMemo(() => ({ [`__scope${t.scopeName}`]: c }), [c]);
2115
2864
  };
2116
2865
  };
2117
- return a.scopeName = t.scopeName, a;
2118
- }
2119
- function A(e) {
2120
- const t = l.useRef(e);
2121
- return l.useEffect(() => {
2122
- t.current = e;
2123
- }), l.useMemo(() => (...a) => t.current?.(...a), []);
2124
- }
2125
- var It = l.createContext(void 0);
2126
- function Lt(e) {
2127
- const t = l.useContext(It);
2128
- return e || t || "ltr";
2129
- }
2130
- function Ot(e, [t, a]) {
2131
- return Math.min(a, Math.max(t, e));
2132
- }
2133
- function D(e, t, { checkForDefaultPrevented: a = !0 } = {}) {
2134
- return function(n) {
2135
- if (e?.(n), a === !1 || !n.defaultPrevented)
2136
- return t?.(n);
2137
- };
2866
+ return r.scopeName = t.scopeName, r;
2867
+ }
2868
+ var ge = globalThis?.document ? u.useLayoutEffect : () => {
2869
+ }, jt = u[" useInsertionEffect ".trim().toString()] || ge;
2870
+ function Ot({
2871
+ prop: e,
2872
+ defaultProp: t,
2873
+ onChange: r = () => {
2874
+ },
2875
+ caller: n
2876
+ }) {
2877
+ const [i, s, c] = Ht({
2878
+ defaultProp: t,
2879
+ onChange: r
2880
+ }), d = e !== void 0, m = d ? e : i;
2881
+ {
2882
+ const p = u.useRef(e !== void 0);
2883
+ u.useEffect(() => {
2884
+ const b = p.current;
2885
+ b !== d && console.warn(
2886
+ `${n} is changing from ${b ? "controlled" : "uncontrolled"} to ${d ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
2887
+ ), p.current = d;
2888
+ }, [d, n]);
2889
+ }
2890
+ const f = u.useCallback(
2891
+ (p) => {
2892
+ if (d) {
2893
+ const b = Gt(p) ? p(e) : p;
2894
+ b !== e && c.current?.(b);
2895
+ } else
2896
+ s(p);
2897
+ },
2898
+ [d, e, s, c]
2899
+ );
2900
+ return [m, f];
2901
+ }
2902
+ function Ht({
2903
+ defaultProp: e,
2904
+ onChange: t
2905
+ }) {
2906
+ const [r, n] = u.useState(e), i = u.useRef(r), s = u.useRef(t);
2907
+ return jt(() => {
2908
+ s.current = t;
2909
+ }, [t]), u.useEffect(() => {
2910
+ i.current !== r && (s.current?.(r), i.current = r);
2911
+ }, [r, i]), [r, n, s];
2138
2912
  }
2139
- function Bt(e, t) {
2140
- return l.useReducer((a, o) => t[a][o] ?? a, e);
2913
+ function Gt(e) {
2914
+ return typeof e == "function";
2141
2915
  }
2142
- var se = "ScrollArea", [we, ro] = At(se), [Ht, P] = we(se), Se = l.forwardRef(
2916
+ function Vt(e) {
2917
+ const t = u.useRef({ value: e, previous: e });
2918
+ return u.useMemo(() => (t.current.value !== e && (t.current.previous = t.current.value, t.current.value = e), t.current.previous), [e]);
2919
+ }
2920
+ function Ft(e) {
2921
+ const [t, r] = u.useState(void 0);
2922
+ return ge(() => {
2923
+ if (e) {
2924
+ r({ width: e.offsetWidth, height: e.offsetHeight });
2925
+ const n = new ResizeObserver((i) => {
2926
+ if (!Array.isArray(i) || !i.length)
2927
+ return;
2928
+ const s = i[0];
2929
+ let c, d;
2930
+ if ("borderBoxSize" in s) {
2931
+ const m = s.borderBoxSize, f = Array.isArray(m) ? m[0] : m;
2932
+ c = f.inlineSize, d = f.blockSize;
2933
+ } else
2934
+ c = e.offsetWidth, d = e.offsetHeight;
2935
+ r({ width: c, height: d });
2936
+ });
2937
+ return n.observe(e, { box: "border-box" }), () => n.unobserve(e);
2938
+ } else
2939
+ r(void 0);
2940
+ }, [e]), t;
2941
+ }
2942
+ var Ut = [
2943
+ "a",
2944
+ "button",
2945
+ "div",
2946
+ "form",
2947
+ "h2",
2948
+ "h3",
2949
+ "img",
2950
+ "input",
2951
+ "label",
2952
+ "li",
2953
+ "nav",
2954
+ "ol",
2955
+ "p",
2956
+ "select",
2957
+ "span",
2958
+ "svg",
2959
+ "ul"
2960
+ ], be = Ut.reduce((e, t) => {
2961
+ const r = Me(`Primitive.${t}`), n = u.forwardRef((i, s) => {
2962
+ const { asChild: c, ...d } = i, m = c ? r : t;
2963
+ return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ a(m, { ...d, ref: s });
2964
+ });
2965
+ return n.displayName = `Primitive.${t}`, { ...e, [t]: n };
2966
+ }, {}), V = "Switch", [Wt, _o] = At(V), [Kt, qt] = Wt(V), he = u.forwardRef(
2143
2967
  (e, t) => {
2144
2968
  const {
2145
- __scopeScrollArea: a,
2146
- type: o = "hover",
2147
- dir: n,
2148
- scrollHideDelay: s = 600,
2149
- ...c
2150
- } = e, [d, u] = l.useState(null), [f, m] = l.useState(null), [b, p] = l.useState(null), [g, v] = l.useState(null), [T, R] = l.useState(null), [x, C] = l.useState(0), [ee, V] = l.useState(0), [j, H] = l.useState(!1), [F, X] = l.useState(!1), w = I(t, (L) => u(L)), z = Lt(n);
2151
- return /* @__PURE__ */ r(
2152
- Ht,
2153
- {
2154
- scope: a,
2155
- type: o,
2156
- dir: z,
2157
- scrollHideDelay: s,
2158
- scrollArea: d,
2159
- viewport: f,
2160
- onViewportChange: m,
2161
- content: b,
2162
- onContentChange: p,
2163
- scrollbarX: g,
2164
- onScrollbarXChange: v,
2165
- scrollbarXEnabled: j,
2166
- onScrollbarXEnabledChange: H,
2167
- scrollbarY: T,
2168
- onScrollbarYChange: R,
2169
- scrollbarYEnabled: F,
2170
- onScrollbarYEnabledChange: X,
2171
- onCornerWidthChange: C,
2172
- onCornerHeightChange: V,
2173
- children: /* @__PURE__ */ r(
2174
- W.div,
2175
- {
2176
- dir: z,
2177
- ...c,
2178
- ref: w,
2179
- style: {
2180
- position: "relative",
2181
- // Pass corner sizes as CSS vars to reduce re-renders of context consumers
2182
- "--radix-scroll-area-corner-width": x + "px",
2183
- "--radix-scroll-area-corner-height": ee + "px",
2184
- ...e.style
2185
- }
2186
- }
2187
- )
2188
- }
2189
- );
2190
- }
2191
- );
2192
- Se.displayName = se;
2193
- var ye = "ScrollAreaViewport", Ne = l.forwardRef(
2194
- (e, t) => {
2195
- const { __scopeScrollArea: a, children: o, nonce: n, ...s } = e, c = P(ye, a), d = l.useRef(null), u = I(t, d, c.onViewportChange);
2196
- return /* @__PURE__ */ h(De, { children: [
2197
- /* @__PURE__ */ r(
2198
- "style",
2969
+ __scopeSwitch: r,
2970
+ name: n,
2971
+ checked: i,
2972
+ defaultChecked: s,
2973
+ required: c,
2974
+ disabled: d,
2975
+ value: m = "on",
2976
+ onCheckedChange: f,
2977
+ form: p,
2978
+ ...b
2979
+ } = e, [h, x] = u.useState(null), w = pe(t, (M) => x(M)), _ = u.useRef(!1), y = h ? p || !!h.closest("form") : !0, [g, v] = Ot({
2980
+ prop: i,
2981
+ defaultProp: s ?? !1,
2982
+ onChange: f,
2983
+ caller: V
2984
+ });
2985
+ return /* @__PURE__ */ l(Kt, { scope: r, checked: g, disabled: d, children: [
2986
+ /* @__PURE__ */ a(
2987
+ be.button,
2199
2988
  {
2200
- dangerouslySetInnerHTML: {
2201
- __html: "[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"
2202
- },
2203
- nonce: n
2989
+ type: "button",
2990
+ role: "switch",
2991
+ "aria-checked": g,
2992
+ "aria-required": c,
2993
+ "data-state": ye(g),
2994
+ "data-disabled": d ? "" : void 0,
2995
+ disabled: d,
2996
+ value: m,
2997
+ ...b,
2998
+ ref: w,
2999
+ onClick: Bt(e.onClick, (M) => {
3000
+ v((P) => !P), y && (_.current = M.isPropagationStopped(), _.current || M.stopPropagation());
3001
+ })
2204
3002
  }
2205
3003
  ),
2206
- /* @__PURE__ */ r(
2207
- W.div,
3004
+ y && /* @__PURE__ */ a(
3005
+ we,
2208
3006
  {
2209
- "data-radix-scroll-area-viewport": "",
2210
- ...s,
2211
- ref: u,
2212
- style: {
2213
- /**
2214
- * We don't support `visible` because the intention is to have at least one scrollbar
2215
- * if this component is used and `visible` will behave like `auto` in that case
2216
- * https://developer.mozilla.org/en-US/docs/Web/CSS/overflow#description
2217
- *
2218
- * We don't handle `auto` because the intention is for the native implementation
2219
- * to be hidden if using this component. We just want to ensure the node is scrollable
2220
- * so could have used either `scroll` or `auto` here. We picked `scroll` to prevent
2221
- * the browser from having to work out whether to render native scrollbars or not,
2222
- * we tell it to with the intention of hiding them in CSS.
2223
- */
2224
- overflowX: c.scrollbarXEnabled ? "scroll" : "hidden",
2225
- overflowY: c.scrollbarYEnabled ? "scroll" : "hidden",
2226
- ...e.style
2227
- },
2228
- children: /* @__PURE__ */ r("div", { ref: c.onContentChange, style: { minWidth: "100%", display: "table" }, children: o })
3007
+ control: h,
3008
+ bubbles: !_.current,
3009
+ name: n,
3010
+ value: m,
3011
+ checked: g,
3012
+ required: c,
3013
+ disabled: d,
3014
+ form: p,
3015
+ style: { transform: "translateX(-100%)" }
2229
3016
  }
2230
3017
  )
2231
3018
  ] });
2232
3019
  }
2233
3020
  );
2234
- Ne.displayName = ye;
2235
- var _ = "ScrollAreaScrollbar", Ce = l.forwardRef(
3021
+ he.displayName = V;
3022
+ var ve = "SwitchThumb", xe = u.forwardRef(
2236
3023
  (e, t) => {
2237
- const { forceMount: a, ...o } = e, n = P(_, e.__scopeScrollArea), { onScrollbarXEnabledChange: s, onScrollbarYEnabledChange: c } = n, d = e.orientation === "horizontal";
2238
- return l.useEffect(() => (d ? s(!0) : c(!0), () => {
2239
- d ? s(!1) : c(!1);
2240
- }), [d, s, c]), n.type === "hover" ? /* @__PURE__ */ r(Wt, { ...o, ref: t, forceMount: a }) : n.type === "scroll" ? /* @__PURE__ */ r(Ut, { ...o, ref: t, forceMount: a }) : n.type === "auto" ? /* @__PURE__ */ r(Te, { ...o, ref: t, forceMount: a }) : n.type === "always" ? /* @__PURE__ */ r(le, { ...o, ref: t }) : null;
2241
- }
2242
- );
2243
- Ce.displayName = _;
2244
- var Wt = l.forwardRef((e, t) => {
2245
- const { forceMount: a, ...o } = e, n = P(_, e.__scopeScrollArea), [s, c] = l.useState(!1);
2246
- return l.useEffect(() => {
2247
- const d = n.scrollArea;
2248
- let u = 0;
2249
- if (d) {
2250
- const f = () => {
2251
- window.clearTimeout(u), c(!0);
2252
- }, m = () => {
2253
- u = window.setTimeout(() => c(!1), n.scrollHideDelay);
2254
- };
2255
- return d.addEventListener("pointerenter", f), d.addEventListener("pointerleave", m), () => {
2256
- window.clearTimeout(u), d.removeEventListener("pointerenter", f), d.removeEventListener("pointerleave", m);
2257
- };
2258
- }
2259
- }, [n.scrollArea, n.scrollHideDelay]), /* @__PURE__ */ r(U, { present: a || s, children: /* @__PURE__ */ r(
2260
- Te,
2261
- {
2262
- "data-state": s ? "visible" : "hidden",
2263
- ...o,
2264
- ref: t
2265
- }
2266
- ) });
2267
- }), Ut = l.forwardRef((e, t) => {
2268
- const { forceMount: a, ...o } = e, n = P(_, e.__scopeScrollArea), s = e.orientation === "horizontal", c = Z(() => u("SCROLL_END"), 100), [d, u] = Bt("hidden", {
2269
- hidden: {
2270
- SCROLL: "scrolling"
2271
- },
2272
- scrolling: {
2273
- SCROLL_END: "idle",
2274
- POINTER_ENTER: "interacting"
2275
- },
2276
- interacting: {
2277
- SCROLL: "interacting",
2278
- POINTER_LEAVE: "idle"
2279
- },
2280
- idle: {
2281
- HIDE: "hidden",
2282
- SCROLL: "scrolling",
2283
- POINTER_ENTER: "interacting"
2284
- }
2285
- });
2286
- return l.useEffect(() => {
2287
- if (d === "idle") {
2288
- const f = window.setTimeout(() => u("HIDE"), n.scrollHideDelay);
2289
- return () => window.clearTimeout(f);
2290
- }
2291
- }, [d, n.scrollHideDelay, u]), l.useEffect(() => {
2292
- const f = n.viewport, m = s ? "scrollLeft" : "scrollTop";
2293
- if (f) {
2294
- let b = f[m];
2295
- const p = () => {
2296
- const g = f[m];
2297
- b !== g && (u("SCROLL"), c()), b = g;
2298
- };
2299
- return f.addEventListener("scroll", p), () => f.removeEventListener("scroll", p);
2300
- }
2301
- }, [n.viewport, s, u, c]), /* @__PURE__ */ r(U, { present: a || d !== "hidden", children: /* @__PURE__ */ r(
2302
- le,
2303
- {
2304
- "data-state": d === "hidden" ? "hidden" : "visible",
2305
- ...o,
2306
- ref: t,
2307
- onPointerEnter: D(e.onPointerEnter, () => u("POINTER_ENTER")),
2308
- onPointerLeave: D(e.onPointerLeave, () => u("POINTER_LEAVE"))
2309
- }
2310
- ) });
2311
- }), Te = l.forwardRef((e, t) => {
2312
- const a = P(_, e.__scopeScrollArea), { forceMount: o, ...n } = e, [s, c] = l.useState(!1), d = e.orientation === "horizontal", u = Z(() => {
2313
- if (a.viewport) {
2314
- const f = a.viewport.offsetWidth < a.viewport.scrollWidth, m = a.viewport.offsetHeight < a.viewport.scrollHeight;
2315
- c(d ? f : m);
2316
- }
2317
- }, 10);
2318
- return B(a.viewport, u), B(a.content, u), /* @__PURE__ */ r(U, { present: o || s, children: /* @__PURE__ */ r(
2319
- le,
2320
- {
2321
- "data-state": s ? "visible" : "hidden",
2322
- ...n,
2323
- ref: t
2324
- }
2325
- ) });
2326
- }), le = l.forwardRef((e, t) => {
2327
- const { orientation: a = "vertical", ...o } = e, n = P(_, e.__scopeScrollArea), s = l.useRef(null), c = l.useRef(0), [d, u] = l.useState({
2328
- content: 0,
2329
- viewport: 0,
2330
- scrollbar: { size: 0, paddingStart: 0, paddingEnd: 0 }
2331
- }), f = ke(d.viewport, d.content), m = {
2332
- ...o,
2333
- sizes: d,
2334
- onSizesChange: u,
2335
- hasThumb: f > 0 && f < 1,
2336
- onThumbChange: (p) => s.current = p,
2337
- onThumbPointerUp: () => c.current = 0,
2338
- onThumbPointerDown: (p) => c.current = p
2339
- };
2340
- function b(p, g) {
2341
- return $t(p, c.current, d, g);
2342
- }
2343
- return a === "horizontal" ? /* @__PURE__ */ r(
2344
- Vt,
2345
- {
2346
- ...m,
2347
- ref: t,
2348
- onThumbPositionChange: () => {
2349
- if (n.viewport && s.current) {
2350
- const p = n.viewport.scrollLeft, g = fe(p, d, n.dir);
2351
- s.current.style.transform = `translate3d(${g}px, 0, 0)`;
2352
- }
2353
- },
2354
- onWheelScroll: (p) => {
2355
- n.viewport && (n.viewport.scrollLeft = p);
2356
- },
2357
- onDragScroll: (p) => {
2358
- n.viewport && (n.viewport.scrollLeft = b(p, n.dir));
2359
- }
2360
- }
2361
- ) : a === "vertical" ? /* @__PURE__ */ r(
2362
- jt,
2363
- {
2364
- ...m,
2365
- ref: t,
2366
- onThumbPositionChange: () => {
2367
- if (n.viewport && s.current) {
2368
- const p = n.viewport.scrollTop, g = fe(p, d);
2369
- s.current.style.transform = `translate3d(0, ${g}px, 0)`;
2370
- }
2371
- },
2372
- onWheelScroll: (p) => {
2373
- n.viewport && (n.viewport.scrollTop = p);
2374
- },
2375
- onDragScroll: (p) => {
2376
- n.viewport && (n.viewport.scrollTop = b(p));
2377
- }
2378
- }
2379
- ) : null;
2380
- }), Vt = l.forwardRef((e, t) => {
2381
- const { sizes: a, onSizesChange: o, ...n } = e, s = P(_, e.__scopeScrollArea), [c, d] = l.useState(), u = l.useRef(null), f = I(t, u, s.onScrollbarXChange);
2382
- return l.useEffect(() => {
2383
- u.current && d(getComputedStyle(u.current));
2384
- }, [u]), /* @__PURE__ */ r(
2385
- ze,
2386
- {
2387
- "data-orientation": "horizontal",
2388
- ...n,
2389
- ref: f,
2390
- sizes: a,
2391
- style: {
2392
- bottom: 0,
2393
- left: s.dir === "rtl" ? "var(--radix-scroll-area-corner-width)" : 0,
2394
- right: s.dir === "ltr" ? "var(--radix-scroll-area-corner-width)" : 0,
2395
- "--radix-scroll-area-thumb-width": Q(a) + "px",
2396
- ...e.style
2397
- },
2398
- onThumbPointerDown: (m) => e.onThumbPointerDown(m.x),
2399
- onDragScroll: (m) => e.onDragScroll(m.x),
2400
- onWheelScroll: (m, b) => {
2401
- if (s.viewport) {
2402
- const p = s.viewport.scrollLeft + m.deltaX;
2403
- e.onWheelScroll(p), Me(p, b) && m.preventDefault();
2404
- }
2405
- },
2406
- onResize: () => {
2407
- u.current && s.viewport && c && o({
2408
- content: s.viewport.scrollWidth,
2409
- viewport: s.viewport.offsetWidth,
2410
- scrollbar: {
2411
- size: u.current.clientWidth,
2412
- paddingStart: K(c.paddingLeft),
2413
- paddingEnd: K(c.paddingRight)
2414
- }
2415
- });
2416
- }
2417
- }
2418
- );
2419
- }), jt = l.forwardRef((e, t) => {
2420
- const { sizes: a, onSizesChange: o, ...n } = e, s = P(_, e.__scopeScrollArea), [c, d] = l.useState(), u = l.useRef(null), f = I(t, u, s.onScrollbarYChange);
2421
- return l.useEffect(() => {
2422
- u.current && d(getComputedStyle(u.current));
2423
- }, [u]), /* @__PURE__ */ r(
2424
- ze,
2425
- {
2426
- "data-orientation": "vertical",
2427
- ...n,
2428
- ref: f,
2429
- sizes: a,
2430
- style: {
2431
- top: 0,
2432
- right: s.dir === "ltr" ? 0 : void 0,
2433
- left: s.dir === "rtl" ? 0 : void 0,
2434
- bottom: "var(--radix-scroll-area-corner-height)",
2435
- "--radix-scroll-area-thumb-height": Q(a) + "px",
2436
- ...e.style
2437
- },
2438
- onThumbPointerDown: (m) => e.onThumbPointerDown(m.y),
2439
- onDragScroll: (m) => e.onDragScroll(m.y),
2440
- onWheelScroll: (m, b) => {
2441
- if (s.viewport) {
2442
- const p = s.viewport.scrollTop + m.deltaY;
2443
- e.onWheelScroll(p), Me(p, b) && m.preventDefault();
2444
- }
2445
- },
2446
- onResize: () => {
2447
- u.current && s.viewport && c && o({
2448
- content: s.viewport.scrollHeight,
2449
- viewport: s.viewport.offsetHeight,
2450
- scrollbar: {
2451
- size: u.current.clientHeight,
2452
- paddingStart: K(c.paddingTop),
2453
- paddingEnd: K(c.paddingBottom)
2454
- }
2455
- });
3024
+ const { __scopeSwitch: r, ...n } = e, i = qt(ve, r);
3025
+ return /* @__PURE__ */ a(
3026
+ be.span,
3027
+ {
3028
+ "data-state": ye(i.checked),
3029
+ "data-disabled": i.disabled ? "" : void 0,
3030
+ ...n,
3031
+ ref: t
2456
3032
  }
2457
- }
2458
- );
2459
- }), [Ft, Pe] = we(_), ze = l.forwardRef((e, t) => {
2460
- const {
2461
- __scopeScrollArea: a,
2462
- sizes: o,
2463
- hasThumb: n,
2464
- onThumbChange: s,
2465
- onThumbPointerUp: c,
2466
- onThumbPointerDown: d,
2467
- onThumbPositionChange: u,
2468
- onDragScroll: f,
2469
- onWheelScroll: m,
2470
- onResize: b,
2471
- ...p
2472
- } = e, g = P(_, a), [v, T] = l.useState(null), R = I(t, (w) => T(w)), x = l.useRef(null), C = l.useRef(""), ee = g.viewport, V = o.content - o.viewport, j = A(m), H = A(u), F = Z(b, 10);
2473
- function X(w) {
2474
- if (x.current) {
2475
- const z = w.clientX - x.current.left, L = w.clientY - x.current.top;
2476
- f({ x: z, y: L });
2477
- }
2478
- }
2479
- return l.useEffect(() => {
2480
- const w = (z) => {
2481
- const L = z.target;
2482
- v?.contains(L) && j(z, V);
2483
- };
2484
- return document.addEventListener("wheel", w, { passive: !1 }), () => document.removeEventListener("wheel", w, { passive: !1 });
2485
- }, [ee, v, V, j]), l.useEffect(H, [o, H]), B(v, F), B(g.content, F), /* @__PURE__ */ r(
2486
- Ft,
2487
- {
2488
- scope: a,
2489
- scrollbar: v,
2490
- hasThumb: n,
2491
- onThumbChange: A(s),
2492
- onThumbPointerUp: A(c),
2493
- onThumbPositionChange: H,
2494
- onThumbPointerDown: A(d),
2495
- children: /* @__PURE__ */ r(
2496
- W.div,
2497
- {
2498
- ...p,
2499
- ref: R,
2500
- style: { position: "absolute", ...p.style },
2501
- onPointerDown: D(e.onPointerDown, (w) => {
2502
- w.button === 0 && (w.target.setPointerCapture(w.pointerId), x.current = v.getBoundingClientRect(), C.current = document.body.style.webkitUserSelect, document.body.style.webkitUserSelect = "none", g.viewport && (g.viewport.style.scrollBehavior = "auto"), X(w));
2503
- }),
2504
- onPointerMove: D(e.onPointerMove, X),
2505
- onPointerUp: D(e.onPointerUp, (w) => {
2506
- const z = w.target;
2507
- z.hasPointerCapture(w.pointerId) && z.releasePointerCapture(w.pointerId), document.body.style.webkitUserSelect = C.current, g.viewport && (g.viewport.style.scrollBehavior = ""), x.current = null;
2508
- })
2509
- }
2510
- )
2511
- }
2512
- );
2513
- }), G = "ScrollAreaThumb", _e = l.forwardRef(
2514
- (e, t) => {
2515
- const { forceMount: a, ...o } = e, n = Pe(G, e.__scopeScrollArea);
2516
- return /* @__PURE__ */ r(U, { present: a || n.hasThumb, children: /* @__PURE__ */ r(Xt, { ref: t, ...o }) });
3033
+ );
2517
3034
  }
2518
- ), Xt = l.forwardRef(
2519
- (e, t) => {
2520
- const { __scopeScrollArea: a, style: o, ...n } = e, s = P(G, a), c = Pe(G, a), { onThumbPositionChange: d } = c, u = I(
2521
- t,
2522
- (b) => c.onThumbChange(b)
2523
- ), f = l.useRef(void 0), m = Z(() => {
2524
- f.current && (f.current(), f.current = void 0);
2525
- }, 100);
2526
- return l.useEffect(() => {
2527
- const b = s.viewport;
2528
- if (b) {
2529
- const p = () => {
2530
- if (m(), !f.current) {
2531
- const g = Gt(b, d);
2532
- f.current = g, d();
2533
- }
2534
- };
2535
- return d(), b.addEventListener("scroll", p), () => b.removeEventListener("scroll", p);
3035
+ );
3036
+ xe.displayName = ve;
3037
+ var Xt = "SwitchBubbleInput", we = u.forwardRef(
3038
+ ({
3039
+ __scopeSwitch: e,
3040
+ control: t,
3041
+ checked: r,
3042
+ bubbles: n = !0,
3043
+ ...i
3044
+ }, s) => {
3045
+ const c = u.useRef(null), d = pe(c, s), m = Vt(r), f = Ft(t);
3046
+ return u.useEffect(() => {
3047
+ const p = c.current;
3048
+ if (!p) return;
3049
+ const b = window.HTMLInputElement.prototype, x = Object.getOwnPropertyDescriptor(
3050
+ b,
3051
+ "checked"
3052
+ ).set;
3053
+ if (m !== r && x) {
3054
+ const w = new Event("click", { bubbles: n });
3055
+ x.call(p, r), p.dispatchEvent(w);
2536
3056
  }
2537
- }, [s.viewport, m, d]), /* @__PURE__ */ r(
2538
- W.div,
3057
+ }, [m, r, n]), /* @__PURE__ */ a(
3058
+ "input",
2539
3059
  {
2540
- "data-state": c.hasThumb ? "visible" : "hidden",
2541
- ...n,
2542
- ref: u,
3060
+ type: "checkbox",
3061
+ "aria-hidden": !0,
3062
+ defaultChecked: r,
3063
+ ...i,
3064
+ tabIndex: -1,
3065
+ ref: d,
2543
3066
  style: {
2544
- width: "var(--radix-scroll-area-thumb-width)",
2545
- height: "var(--radix-scroll-area-thumb-height)",
2546
- ...o
2547
- },
2548
- onPointerDownCapture: D(e.onPointerDownCapture, (b) => {
2549
- const g = b.target.getBoundingClientRect(), v = b.clientX - g.left, T = b.clientY - g.top;
2550
- c.onThumbPointerDown({ x: v, y: T });
2551
- }),
2552
- onPointerUp: D(e.onPointerUp, c.onThumbPointerUp)
3067
+ ...i.style,
3068
+ ...f,
3069
+ position: "absolute",
3070
+ pointerEvents: "none",
3071
+ opacity: 0,
3072
+ margin: 0
3073
+ }
2553
3074
  }
2554
3075
  );
2555
3076
  }
2556
3077
  );
2557
- _e.displayName = G;
2558
- var de = "ScrollAreaCorner", Re = l.forwardRef(
2559
- (e, t) => {
2560
- const a = P(de, e.__scopeScrollArea), o = !!(a.scrollbarX && a.scrollbarY);
2561
- return a.type !== "scroll" && o ? /* @__PURE__ */ r(Yt, { ...e, ref: t }) : null;
2562
- }
2563
- );
2564
- Re.displayName = de;
2565
- var Yt = l.forwardRef((e, t) => {
2566
- const { __scopeScrollArea: a, ...o } = e, n = P(de, a), [s, c] = l.useState(0), [d, u] = l.useState(0), f = !!(s && d);
2567
- return B(n.scrollbarX, () => {
2568
- const m = n.scrollbarX?.offsetHeight || 0;
2569
- n.onCornerHeightChange(m), u(m);
2570
- }), B(n.scrollbarY, () => {
2571
- const m = n.scrollbarY?.offsetWidth || 0;
2572
- n.onCornerWidthChange(m), c(m);
2573
- }), f ? /* @__PURE__ */ r(
2574
- W.div,
2575
- {
2576
- ...o,
2577
- ref: t,
2578
- style: {
2579
- width: s,
2580
- height: d,
2581
- position: "absolute",
2582
- right: n.dir === "ltr" ? 0 : void 0,
2583
- left: n.dir === "rtl" ? 0 : void 0,
2584
- bottom: 0,
2585
- ...e.style
2586
- }
2587
- }
2588
- ) : null;
2589
- });
2590
- function K(e) {
2591
- return e ? parseInt(e, 10) : 0;
2592
- }
2593
- function ke(e, t) {
2594
- const a = e / t;
2595
- return isNaN(a) ? 0 : a;
3078
+ we.displayName = Xt;
3079
+ function ye(e) {
3080
+ return e ? "checked" : "unchecked";
2596
3081
  }
2597
- function Q(e) {
2598
- const t = ke(e.viewport, e.content), a = e.scrollbar.paddingStart + e.scrollbar.paddingEnd, o = (e.scrollbar.size - a) * t;
2599
- return Math.max(o, 18);
2600
- }
2601
- function $t(e, t, a, o = "ltr") {
2602
- const n = Q(a), s = n / 2, c = t || s, d = n - c, u = a.scrollbar.paddingStart + c, f = a.scrollbar.size - a.scrollbar.paddingEnd - d, m = a.content - a.viewport, b = o === "ltr" ? [0, m] : [m * -1, 0];
2603
- return Ee([u, f], b)(e);
2604
- }
2605
- function fe(e, t, a = "ltr") {
2606
- const o = Q(t), n = t.scrollbar.paddingStart + t.scrollbar.paddingEnd, s = t.scrollbar.size - n, c = t.content - t.viewport, d = s - o, u = a === "ltr" ? [0, c] : [c * -1, 0], f = Ot(e, u);
2607
- return Ee([0, c], [0, d])(f);
2608
- }
2609
- function Ee(e, t) {
2610
- return (a) => {
2611
- if (e[0] === e[1] || t[0] === t[1]) return t[0];
2612
- const o = (t[1] - t[0]) / (e[1] - e[0]);
2613
- return t[0] + o * (a - e[0]);
2614
- };
2615
- }
2616
- function Me(e, t) {
2617
- return e > 0 && e < t;
2618
- }
2619
- var Gt = (e, t = () => {
2620
- }) => {
2621
- let a = { left: e.scrollLeft, top: e.scrollTop }, o = 0;
2622
- return function n() {
2623
- const s = { left: e.scrollLeft, top: e.scrollTop }, c = a.left !== s.left, d = a.top !== s.top;
2624
- (c || d) && t(), a = s, o = window.requestAnimationFrame(n);
2625
- }(), () => window.cancelAnimationFrame(o);
2626
- };
2627
- function Z(e, t) {
2628
- const a = A(e), o = l.useRef(0);
2629
- return l.useEffect(() => () => window.clearTimeout(o.current), []), l.useCallback(() => {
2630
- window.clearTimeout(o.current), o.current = window.setTimeout(a, t);
2631
- }, [a, t]);
2632
- }
2633
- function B(e, t) {
2634
- const a = A(t);
2635
- ae(() => {
2636
- let o = 0;
2637
- if (e) {
2638
- const n = new ResizeObserver(() => {
2639
- cancelAnimationFrame(o), o = window.requestAnimationFrame(a);
2640
- });
2641
- return n.observe(e), () => {
2642
- window.cancelAnimationFrame(o), n.unobserve(e);
2643
- };
2644
- }
2645
- }, [e, a]);
2646
- }
2647
- var Kt = Se, qt = Ne, Jt = Re;
2648
- function ao({
2649
- className: e,
2650
- children: t,
2651
- ...a
2652
- }) {
2653
- return /* @__PURE__ */ h(
2654
- Kt,
2655
- {
2656
- "data-slot": "scroll-area",
2657
- className: i("relative", e),
2658
- ...a,
2659
- children: [
2660
- /* @__PURE__ */ r(
2661
- qt,
2662
- {
2663
- "data-slot": "scroll-area-viewport",
2664
- className: "focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",
2665
- children: t
2666
- }
2667
- ),
2668
- /* @__PURE__ */ r(Qt, {}),
2669
- /* @__PURE__ */ r(Jt, {})
2670
- ]
2671
- }
2672
- );
2673
- }
2674
- function Qt({
3082
+ var Yt = he, Jt = xe;
3083
+ function To({
2675
3084
  className: e,
2676
- orientation: t = "vertical",
2677
- ...a
3085
+ ...t
2678
3086
  }) {
2679
- return /* @__PURE__ */ r(
2680
- Ce,
3087
+ return /* @__PURE__ */ a(
3088
+ Yt,
2681
3089
  {
2682
- "data-slot": "scroll-area-scrollbar",
2683
- orientation: t,
2684
- className: i(
2685
- "flex touch-none p-px transition-colors select-none",
2686
- t === "vertical" && "h-full w-2.5 border-l border-l-transparent",
2687
- t === "horizontal" && "h-2.5 flex-col border-t border-t-transparent",
3090
+ "data-slot": "switch",
3091
+ className: o(
3092
+ "peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/50 dark:data-[state=unchecked]:bg-input/80 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",
2688
3093
  e
2689
3094
  ),
2690
- ...a,
2691
- children: /* @__PURE__ */ r(
2692
- _e,
3095
+ ...t,
3096
+ children: /* @__PURE__ */ a(
3097
+ Jt,
2693
3098
  {
2694
- "data-slot": "scroll-area-thumb",
2695
- className: "bg-border relative flex-1 rounded-full"
3099
+ "data-slot": "switch-thumb",
3100
+ className: o(
3101
+ "bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block size-4 rounded-full ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0"
3102
+ )
2696
3103
  }
2697
3104
  )
2698
3105
  }
2699
3106
  );
2700
3107
  }
2701
- const Zt = {
3108
+ const Qt = {
2702
3109
  theme: "system",
2703
3110
  setTheme: () => null
2704
- }, Ae = Ie(Zt);
2705
- function oo({
3111
+ }, Ne = Ce(Qt);
3112
+ function Mo({
2706
3113
  children: e,
2707
3114
  defaultTheme: t = "system",
2708
- storageKey: a = "vite-ui-theme",
2709
- ...o
3115
+ storageKey: r = "@clidey/ux/theme",
3116
+ ...n
2710
3117
  }) {
2711
- const [n, s] = Le(
2712
- () => localStorage.getItem(a) || t
3118
+ const [i, s] = ze(
3119
+ () => localStorage.getItem(r) || t
2713
3120
  );
2714
- Oe(() => {
3121
+ _e(() => {
2715
3122
  const d = window.document.documentElement;
2716
- if (d.classList.remove("light", "dark"), n === "system") {
2717
- const u = window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
2718
- d.classList.add(u);
3123
+ if (d.classList.remove("light", "dark"), i === "system") {
3124
+ const m = window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
3125
+ d.classList.add(m);
2719
3126
  return;
2720
3127
  }
2721
- d.classList.add(n);
2722
- }, [n]);
3128
+ d.classList.add(i);
3129
+ }, [i]);
2723
3130
  const c = {
2724
- theme: n,
3131
+ theme: i,
2725
3132
  setTheme: (d) => {
2726
- localStorage.setItem(a, d), s(d);
3133
+ localStorage.setItem(r, d), s(d);
2727
3134
  }
2728
3135
  };
2729
- return /* @__PURE__ */ r(Ae.Provider, { ...o, value: c, children: e });
3136
+ return /* @__PURE__ */ a(Ne.Provider, { ...n, value: c, children: e });
2730
3137
  }
2731
- const er = () => {
2732
- const e = Be(Ae);
3138
+ const Zt = () => {
3139
+ const e = Te(Ne);
2733
3140
  if (e === void 0)
2734
3141
  throw new Error("useTheme must be used within a ThemeProvider");
2735
3142
  return e;
2736
3143
  };
2737
- function no() {
2738
- const { setTheme: e } = er();
2739
- return /* @__PURE__ */ h(at, { children: [
2740
- /* @__PURE__ */ r(ot, { asChild: !0, children: /* @__PURE__ */ h(ge, { variant: "outline", size: "icon", children: [
2741
- /* @__PURE__ */ r(Ge, { className: "h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all dark:scale-0 dark:-rotate-90" }),
2742
- /* @__PURE__ */ r(Ke, { className: "absolute h-[1.2rem] w-[1.2rem] scale-0 rotate-90 transition-all dark:scale-100 dark:rotate-0" }),
2743
- /* @__PURE__ */ r("span", { className: "sr-only", children: "Toggle theme" })
3144
+ function Io() {
3145
+ const { setTheme: e } = Zt();
3146
+ return /* @__PURE__ */ l(Xe, { children: [
3147
+ /* @__PURE__ */ a(Ye, { children: /* @__PURE__ */ l(Y, { variant: "outline", size: "icon", children: [
3148
+ /* @__PURE__ */ a(J, { className: "h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all dark:scale-0 dark:-rotate-90" }),
3149
+ /* @__PURE__ */ a(Q, { className: "absolute h-[1.2rem] w-[1.2rem] scale-0 rotate-90 transition-all dark:scale-100 dark:rotate-0" }),
3150
+ /* @__PURE__ */ a("span", { className: "sr-only", children: "Toggle theme" })
2744
3151
  ] }) }),
2745
- /* @__PURE__ */ h(nt, { align: "end", children: [
2746
- /* @__PURE__ */ r(te, { onClick: () => e("light"), children: "Light" }),
2747
- /* @__PURE__ */ r(te, { onClick: () => e("dark"), children: "Dark" }),
2748
- /* @__PURE__ */ r(te, { onClick: () => e("system"), children: "System" })
3152
+ /* @__PURE__ */ l(Je, { align: "end", children: [
3153
+ /* @__PURE__ */ l(F, { onClick: () => e("light"), children: [
3154
+ /* @__PURE__ */ a(J, { className: "size-4" }),
3155
+ "Light"
3156
+ ] }),
3157
+ /* @__PURE__ */ l(F, { onClick: () => e("dark"), children: [
3158
+ /* @__PURE__ */ a(Q, { className: "size-4" }),
3159
+ "Dark"
3160
+ ] }),
3161
+ /* @__PURE__ */ l(F, { onClick: () => e("system"), children: [
3162
+ /* @__PURE__ */ a(Oe, { className: "size-4" }),
3163
+ "System"
3164
+ ] })
2749
3165
  ] })
2750
3166
  ] });
2751
3167
  }
2752
3168
  export {
2753
- mr as Badge,
2754
- va as Breadcrumb,
2755
- wa as BreadcrumbItem,
2756
- Sa as BreadcrumbLink,
2757
- xa as BreadcrumbList,
2758
- ya as BreadcrumbPage,
2759
- Na as BreadcrumbSeparator,
2760
- ge as Button,
2761
- pr as Card,
2762
- vr as CardContent,
2763
- hr as CardDescription,
2764
- xr as CardFooter,
2765
- br as CardHeader,
2766
- gr as CardTitle,
2767
- wr as ContextMenu,
2768
- _r as ContextMenuCheckboxItem,
2769
- Pr as ContextMenuContent,
2770
- zr as ContextMenuItem,
2771
- kr as ContextMenuLabel,
2772
- Nr as ContextMenuRadioGroup,
2773
- Rr as ContextMenuRadioItem,
2774
- Er as ContextMenuSeparator,
2775
- Mr as ContextMenuShortcut,
2776
- yr as ContextMenuSub,
2777
- Tr as ContextMenuSubContent,
2778
- Cr as ContextMenuSubTrigger,
2779
- Sr as ContextMenuTrigger,
2780
- Ar as Drawer,
2781
- Ir as DrawerClose,
2782
- Lr as DrawerContent,
2783
- Wr as DrawerDescription,
2784
- Br as DrawerFooter,
2785
- Or as DrawerHeader,
2786
- Hr as DrawerTitle,
2787
- Dr as DrawerTrigger,
2788
- at as DropdownMenu,
2789
- Ur as DropdownMenuCheckboxItem,
2790
- nt as DropdownMenuContent,
2791
- te as DropdownMenuItem,
2792
- Fr as DropdownMenuLabel,
2793
- Vr as DropdownMenuRadioGroup,
2794
- jr as DropdownMenuRadioItem,
2795
- Xr as DropdownMenuSeparator,
2796
- Yr as DropdownMenuShortcut,
2797
- $r as DropdownMenuSub,
2798
- Kr as DropdownMenuSubContent,
2799
- Gr as DropdownMenuSubTrigger,
2800
- ot as DropdownMenuTrigger,
2801
- it as Input,
2802
- qr as Label,
2803
- no as ModeToggle,
2804
- Jr as Pagination,
2805
- Qr as PaginationContent,
2806
- ra as PaginationEllipsis,
2807
- Zr as PaginationItem,
2808
- he as PaginationLink,
2809
- ta as PaginationNext,
2810
- ea as PaginationPrevious,
2811
- aa as Popover,
2812
- na as PopoverContent,
2813
- oa as PopoverTrigger,
2814
- ao as ScrollArea,
2815
- Ca as Select,
2816
- _a as SelectContent,
2817
- Ta as SelectGroup,
2818
- ka as SelectItem,
2819
- Ra as SelectLabel,
2820
- za as SelectTrigger,
2821
- Pa as SelectValue,
2822
- mt as Separator,
2823
- pt as Sheet,
2824
- ht as SheetContent,
2825
- wt as SheetDescription,
2826
- Ma as SheetFooter,
2827
- vt as SheetHeader,
2828
- xt as SheetTitle,
2829
- Ea as SheetTrigger,
2830
- Da as Sidebar,
2831
- Va as SidebarContent,
2832
- Wa as SidebarFooter,
2833
- ja as SidebarGroup,
2834
- Xa as SidebarGroupAction,
2835
- Ya as SidebarGroupContent,
2836
- Fa as SidebarGroupLabel,
2837
- Ha as SidebarHeader,
2838
- Ba as SidebarInput,
2839
- Oa as SidebarInset,
2840
- $a as SidebarMenu,
2841
- qa as SidebarMenuAction,
2842
- Ja as SidebarMenuBadge,
2843
- Ka as SidebarMenuButton,
2844
- Ga as SidebarMenuItem,
2845
- Qa as SidebarMenuSkeleton,
2846
- Za as SidebarMenuSub,
2847
- to as SidebarMenuSubButton,
2848
- eo as SidebarMenuSubItem,
2849
- Aa as SidebarProvider,
2850
- La as SidebarRail,
2851
- Ua as SidebarSeparator,
2852
- Ia as SidebarTrigger,
2853
- ce as Skeleton,
2854
- sa as Table,
2855
- da as TableBody,
2856
- ma as TableCaption,
2857
- fa as TableCell,
2858
- ua as TableHead,
2859
- la as TableHeader,
2860
- ca as TableRow,
2861
- pa as Tabs,
2862
- ha as TabsContent,
2863
- ba as TabsList,
2864
- ga as TabsTrigger,
2865
- oo as ThemeProvider,
2866
- ia as Toaster,
2867
- st as Tooltip,
2868
- dt as TooltipContent,
2869
- ve as TooltipProvider,
2870
- lt as TooltipTrigger,
2871
- i as cn,
2872
- lo as toast,
2873
- J as useSidebar,
2874
- er as useTheme
3169
+ bo as Accordion,
3170
+ xo as AccordionContent,
3171
+ ho as AccordionItem,
3172
+ vo as AccordionTrigger,
3173
+ ko as Alert,
3174
+ Co as AlertDescription,
3175
+ So as AlertTitle,
3176
+ ba as Badge,
3177
+ vr as Breadcrumb,
3178
+ wr as BreadcrumbItem,
3179
+ yr as BreadcrumbLink,
3180
+ xr as BreadcrumbList,
3181
+ Nr as BreadcrumbPage,
3182
+ kr as BreadcrumbSeparator,
3183
+ Y as Button,
3184
+ ha as Card,
3185
+ ya as CardContent,
3186
+ wa as CardDescription,
3187
+ Na as CardFooter,
3188
+ va as CardHeader,
3189
+ xa as CardTitle,
3190
+ mo as Checkbox,
3191
+ lt as Command,
3192
+ ft as CommandEmpty,
3193
+ mt as CommandGroup,
3194
+ ct as CommandInput,
3195
+ pt as CommandItem,
3196
+ ut as CommandList,
3197
+ ka as ContextMenu,
3198
+ Pa as ContextMenuCheckboxItem,
3199
+ Ma as ContextMenuContent,
3200
+ Ia as ContextMenuItem,
3201
+ Da as ContextMenuLabel,
3202
+ za as ContextMenuRadioGroup,
3203
+ Ra as ContextMenuRadioItem,
3204
+ Ea as ContextMenuSeparator,
3205
+ Ba as ContextMenuShortcut,
3206
+ Ca as ContextMenuSub,
3207
+ Ta as ContextMenuSubContent,
3208
+ _a as ContextMenuSubTrigger,
3209
+ Sa as ContextMenuTrigger,
3210
+ Sr as Dialog,
3211
+ zr as DialogContent,
3212
+ Ir as DialogDescription,
3213
+ Tr as DialogFooter,
3214
+ _r as DialogHeader,
3215
+ Mr as DialogTitle,
3216
+ Cr as DialogTrigger,
3217
+ La as Drawer,
3218
+ $a as DrawerClose,
3219
+ ja as DrawerContent,
3220
+ Va as DrawerDescription,
3221
+ Ha as DrawerFooter,
3222
+ Oa as DrawerHeader,
3223
+ Ga as DrawerTitle,
3224
+ Aa as DrawerTrigger,
3225
+ Xe as DropdownMenu,
3226
+ Fa as DropdownMenuCheckboxItem,
3227
+ Je as DropdownMenuContent,
3228
+ F as DropdownMenuItem,
3229
+ Ka as DropdownMenuLabel,
3230
+ Ua as DropdownMenuRadioGroup,
3231
+ Wa as DropdownMenuRadioItem,
3232
+ qa as DropdownMenuSeparator,
3233
+ Xa as DropdownMenuShortcut,
3234
+ Ya as DropdownMenuSub,
3235
+ Qa as DropdownMenuSubContent,
3236
+ Ja as DropdownMenuSubTrigger,
3237
+ Ye as DropdownMenuTrigger,
3238
+ po as EmptyState,
3239
+ zo as Icon,
3240
+ Qe as Input,
3241
+ er as Label,
3242
+ Io as ModeToggle,
3243
+ tr as Pagination,
3244
+ ar as PaginationContent,
3245
+ ir as PaginationEllipsis,
3246
+ rr as PaginationItem,
3247
+ se as PaginationLink,
3248
+ nr as PaginationNext,
3249
+ or as PaginationPrevious,
3250
+ Ze as Popover,
3251
+ tt as PopoverContent,
3252
+ et as PopoverTrigger,
3253
+ No as ResizableHandle,
3254
+ yo as ResizablePanel,
3255
+ wo as ResizablePanelGroup,
3256
+ Rt as ScrollArea,
3257
+ Za as SearchInput,
3258
+ $r as SearchSelect,
3259
+ Pr as Select,
3260
+ Br as SelectContent,
3261
+ Rr as SelectGroup,
3262
+ Ar as SelectItem,
3263
+ Lr as SelectLabel,
3264
+ Er as SelectTrigger,
3265
+ Dr as SelectValue,
3266
+ le as Separator,
3267
+ vt as Sheet,
3268
+ yt as SheetContent,
3269
+ St as SheetDescription,
3270
+ Or as SheetFooter,
3271
+ Nt as SheetHeader,
3272
+ kt as SheetTitle,
3273
+ jr as SheetTrigger,
3274
+ Gr as Sidebar,
3275
+ Yr as SidebarContent,
3276
+ qr as SidebarFooter,
3277
+ Jr as SidebarGroup,
3278
+ Zr as SidebarGroupAction,
3279
+ eo as SidebarGroupContent,
3280
+ Qr as SidebarGroupLabel,
3281
+ Kr as SidebarHeader,
3282
+ Wr as SidebarInput,
3283
+ Ur as SidebarInset,
3284
+ to as SidebarMenu,
3285
+ oo as SidebarMenuAction,
3286
+ no as SidebarMenuBadge,
3287
+ ro as SidebarMenuButton,
3288
+ ao as SidebarMenuItem,
3289
+ io as SidebarMenuSkeleton,
3290
+ so as SidebarMenuSub,
3291
+ co as SidebarMenuSubButton,
3292
+ lo as SidebarMenuSubItem,
3293
+ Hr as SidebarProvider,
3294
+ Fr as SidebarRail,
3295
+ Xr as SidebarSeparator,
3296
+ Vr as SidebarTrigger,
3297
+ ee as Skeleton,
3298
+ fo as StackList,
3299
+ uo as StackListItem,
3300
+ To as Switch,
3301
+ lr as Table,
3302
+ at as TableBody,
3303
+ mr as TableCaption,
3304
+ fr as TableCell,
3305
+ ur as TableHead,
3306
+ cr as TableHeader,
3307
+ rt as TableRow,
3308
+ pr as Tabs,
3309
+ hr as TabsContent,
3310
+ gr as TabsList,
3311
+ br as TabsTrigger,
3312
+ Mo as ThemeProvider,
3313
+ sr as Toaster,
3314
+ ot as Tooltip,
3315
+ it as TooltipContent,
3316
+ de as TooltipProvider,
3317
+ nt as TooltipTrigger,
3318
+ go as Tree,
3319
+ dr as VirtualizedTableBody,
3320
+ o as cn,
3321
+ ga as formatDate,
3322
+ pa as toTitleCase,
3323
+ Do as toast,
3324
+ G as useSidebar,
3325
+ Zt as useTheme
2875
3326
  };