@arcadeai/design-system 0.7.3 → 0.7.5

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.
@@ -1,15 +1,16 @@
1
1
  import { jsx as e, jsxs as n } from "react/jsx-runtime";
2
- import { R as d, T as c, C as r, a as u, X as m, b as f, D as h, P as g, O as p } from "../../../index-DLfXSskr.js";
2
+ import { R as d, T as c, C as r, a as m, b as u, D as f, P as h, O as g } from "../../../index-toVHZ337.js";
3
+ import { XIcon as p } from "lucide-react";
3
4
  import { c as o } from "../../../utils-CRiPKpXj.js";
4
- function N({ ...t }) {
5
+ function v({ ...t }) {
5
6
  return /* @__PURE__ */ e(d, { "data-slot": "sheet", ...t });
6
7
  }
7
- function v({
8
+ function C({
8
9
  ...t
9
10
  }) {
10
11
  return /* @__PURE__ */ e(c, { "data-slot": "sheet-trigger", ...t });
11
12
  }
12
- function C({
13
+ function T({
13
14
  ...t
14
15
  }) {
15
16
  return /* @__PURE__ */ e(r, { "data-slot": "sheet-close", ...t });
@@ -17,14 +18,14 @@ function C({
17
18
  function x({
18
19
  ...t
19
20
  }) {
20
- return /* @__PURE__ */ e(g, { "data-slot": "sheet-portal", ...t });
21
+ return /* @__PURE__ */ e(h, { "data-slot": "sheet-portal", ...t });
21
22
  }
22
23
  function b({
23
24
  className: t,
24
25
  ...a
25
26
  }) {
26
27
  return /* @__PURE__ */ e(
27
- p,
28
+ g,
28
29
  {
29
30
  className: o(
30
31
  "data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=open]:animate-in",
@@ -35,7 +36,7 @@ function b({
35
36
  }
36
37
  );
37
38
  }
38
- function T({
39
+ function k({
39
40
  className: t,
40
41
  children: a,
41
42
  side: s = "right",
@@ -45,7 +46,7 @@ function T({
45
46
  return /* @__PURE__ */ n(x, { children: [
46
47
  /* @__PURE__ */ e(b, {}),
47
48
  /* @__PURE__ */ n(
48
- u,
49
+ m,
49
50
  {
50
51
  className: o(
51
52
  "fixed z-50 flex flex-col gap-4 bg-background shadow-lg transition ease-in-out data-[state=closed]:animate-out data-[state=open]:animate-in data-[state=closed]:duration-300 data-[state=open]:duration-500",
@@ -61,7 +62,7 @@ function T({
61
62
  children: [
62
63
  a,
63
64
  /* @__PURE__ */ n(r, { className: "absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary", children: [
64
- /* @__PURE__ */ e(m, { className: "size-4" }),
65
+ /* @__PURE__ */ e(p, { className: "size-4" }),
65
66
  /* @__PURE__ */ e("span", { className: "sr-only", children: "Close" })
66
67
  ] })
67
68
  ]
@@ -69,7 +70,7 @@ function T({
69
70
  )
70
71
  ] });
71
72
  }
72
- function k({ className: t, ...a }) {
73
+ function z({ className: t, ...a }) {
73
74
  return /* @__PURE__ */ e(
74
75
  "div",
75
76
  {
@@ -79,7 +80,7 @@ function k({ className: t, ...a }) {
79
80
  }
80
81
  );
81
82
  }
82
- function z({ className: t, ...a }) {
83
+ function D({ className: t, ...a }) {
83
84
  return /* @__PURE__ */ e(
84
85
  "div",
85
86
  {
@@ -89,12 +90,12 @@ function z({ className: t, ...a }) {
89
90
  }
90
91
  );
91
92
  }
92
- function D({
93
+ function O({
93
94
  className: t,
94
95
  ...a
95
96
  }) {
96
97
  return /* @__PURE__ */ e(
97
- f,
98
+ u,
98
99
  {
99
100
  className: o("font-semibold text-foreground", t),
100
101
  "data-slot": "sheet-title",
@@ -102,12 +103,12 @@ function D({
102
103
  }
103
104
  );
104
105
  }
105
- function O({
106
+ function P({
106
107
  className: t,
107
108
  ...a
108
109
  }) {
109
110
  return /* @__PURE__ */ e(
110
- h,
111
+ f,
111
112
  {
112
113
  className: o("text-muted-foreground text-sm", t),
113
114
  "data-slot": "sheet-description",
@@ -116,12 +117,12 @@ function O({
116
117
  );
117
118
  }
118
119
  export {
119
- N as Sheet,
120
- C as SheetClose,
121
- T as SheetContent,
122
- O as SheetDescription,
123
- z as SheetFooter,
124
- k as SheetHeader,
125
- D as SheetTitle,
126
- v as SheetTrigger
120
+ v as Sheet,
121
+ T as SheetClose,
122
+ k as SheetContent,
123
+ P as SheetDescription,
124
+ D as SheetFooter,
125
+ z as SheetHeader,
126
+ O as SheetTitle,
127
+ C as SheetTrigger
127
128
  };
@@ -1,33 +1,24 @@
1
1
  import { jsx as t, jsxs as p } from "react/jsx-runtime";
2
2
  import { S as h } from "../../../index-5Bhkapwi.js";
3
3
  import { c as M } from "../../../index-CQhYMnjT.js";
4
+ import { PanelLeftIcon as z } from "lucide-react";
4
5
  import * as l from "react";
5
- import { Button as z } from "./button.js";
6
- import { Input as I } from "./input.js";
7
- import { Separator as E } from "./separator.js";
8
- import { Sheet as D, SheetContent as T, SheetHeader as B, SheetTitle as A, SheetDescription as O } from "./sheet.js";
9
- import { Skeleton as N } from "./skeleton.js";
10
- import { Tooltip as R, TooltipTrigger as H, TooltipContent as K, TooltipProvider as L } from "./tooltip.js";
11
- import { useIsMobile as j } from "../../../hooks/use-mobile.js";
6
+ import { Button as I } from "./button.js";
7
+ import { Input as E } from "./input.js";
8
+ import { Separator as D } from "./separator.js";
9
+ import { Sheet as T, SheetContent as B, SheetHeader as A, SheetTitle as O, SheetDescription as R } from "./sheet.js";
10
+ import { Skeleton as y } from "./skeleton.js";
11
+ import { Tooltip as H, TooltipTrigger as K, TooltipContent as j, TooltipProvider as G } from "./tooltip.js";
12
+ import { useIsMobile as L } from "../../../hooks/use-mobile.js";
12
13
  import { c as r } from "../../../utils-CRiPKpXj.js";
13
- import { c as G } from "../../../createLucideIcon-XRdN60yz.js";
14
- /**
15
- * @license lucide-react v0.525.0 - ISC
16
- *
17
- * This source code is licensed under the ISC license.
18
- * See the LICENSE file in the root directory of this source tree.
19
- */
20
- const $ = [
21
- ["rect", { width: "18", height: "18", x: "3", y: "3", rx: "2", key: "afitv7" }],
22
- ["path", { d: "M9 3v18", key: "fh3hqa" }]
23
- ], q = G("panel-left", $), P = "sidebar_state", V = 60 * 60 * 24 * 7, W = "16rem", F = "18rem", U = "3rem", X = "b", _ = l.createContext(null);
14
+ const $ = "sidebar_state", P = 60 * 60 * 24 * 7, V = "16rem", W = "18rem", q = "3rem", F = "b", C = l.createContext(null);
24
15
  function S() {
25
- const a = l.useContext(_);
16
+ const a = l.useContext(C);
26
17
  if (!a)
27
18
  throw new Error("useSidebar must be used within a SidebarProvider.");
28
19
  return a;
29
20
  }
30
- function le({
21
+ function de({
31
22
  defaultOpen: a = !0,
32
23
  open: e,
33
24
  onOpenChange: i,
@@ -36,22 +27,22 @@ function le({
36
27
  children: c,
37
28
  ...m
38
29
  }) {
39
- const s = j(), [b, f] = l.useState(!1), [v, k] = l.useState(a), g = e ?? v, x = l.useCallback(
30
+ const s = L(), [b, f] = l.useState(!1), [v, _] = l.useState(a), g = e ?? v, x = l.useCallback(
40
31
  (d) => {
41
32
  const u = typeof d == "function" ? d(g) : d;
42
- i ? i(u) : k(u), document.cookie = `${P}=${u}; path=/; max-age=${V}`;
33
+ i ? i(u) : _(u), document.cookie = `${$}=${u}; path=/; max-age=${P}`;
43
34
  },
44
35
  [i, g]
45
36
  ), w = l.useCallback(() => s ? f((d) => !d) : x((d) => !d), [s, x]);
46
37
  l.useEffect(() => {
47
38
  const d = (u) => {
48
- u.key === X && (u.metaKey || u.ctrlKey) && (u.preventDefault(), w());
39
+ u.key === F && (u.metaKey || u.ctrlKey) && (u.preventDefault(), w());
49
40
  };
50
41
  return window.addEventListener("keydown", d), () => window.removeEventListener("keydown", d);
51
42
  }, [w]);
52
- const y = g ? "expanded" : "collapsed", C = l.useMemo(
43
+ const N = g ? "expanded" : "collapsed", k = l.useMemo(
53
44
  () => ({
54
- state: y,
45
+ state: N,
55
46
  open: g,
56
47
  setOpen: x,
57
48
  isMobile: s,
@@ -59,9 +50,9 @@ function le({
59
50
  setOpenMobile: f,
60
51
  toggleSidebar: w
61
52
  }),
62
- [y, g, x, s, b, w]
53
+ [N, g, x, s, b, w]
63
54
  );
64
- return /* @__PURE__ */ t(_.Provider, { value: C, children: /* @__PURE__ */ t(L, { delayDuration: 0, children: /* @__PURE__ */ t(
55
+ return /* @__PURE__ */ t(C.Provider, { value: k, children: /* @__PURE__ */ t(G, { delayDuration: 0, children: /* @__PURE__ */ t(
65
56
  "div",
66
57
  {
67
58
  className: r(
@@ -70,8 +61,8 @@ function le({
70
61
  ),
71
62
  "data-slot": "sidebar-wrapper",
72
63
  style: {
73
- "--sidebar-width": W,
74
- "--sidebar-width-icon": U,
64
+ "--sidebar-width": V,
65
+ "--sidebar-width-icon": q,
75
66
  ...o
76
67
  },
77
68
  ...m,
@@ -79,7 +70,7 @@ function le({
79
70
  }
80
71
  ) }) });
81
72
  }
82
- function ce({
73
+ function se({
83
74
  side: a = "left",
84
75
  variant: e = "sidebar",
85
76
  collapsible: i = "offcanvas",
@@ -99,8 +90,8 @@ function ce({
99
90
  ...c,
100
91
  children: o
101
92
  }
102
- ) : m ? /* @__PURE__ */ t(D, { onOpenChange: f, open: b, ...c, children: /* @__PURE__ */ p(
103
- T,
93
+ ) : m ? /* @__PURE__ */ t(T, { onOpenChange: f, open: b, ...c, children: /* @__PURE__ */ p(
94
+ B,
104
95
  {
105
96
  className: "w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",
106
97
  "data-mobile": "true",
@@ -108,12 +99,12 @@ function ce({
108
99
  "data-slot": "sidebar",
109
100
  side: a,
110
101
  style: {
111
- "--sidebar-width": F
102
+ "--sidebar-width": W
112
103
  },
113
104
  children: [
114
- /* @__PURE__ */ p(B, { className: "sr-only", children: [
115
- /* @__PURE__ */ t(A, { children: "Sidebar" }),
116
- /* @__PURE__ */ t(O, { children: "Displays the mobile sidebar." })
105
+ /* @__PURE__ */ p(A, { className: "sr-only", children: [
106
+ /* @__PURE__ */ t(O, { children: "Sidebar" }),
107
+ /* @__PURE__ */ t(R, { children: "Displays the mobile sidebar." })
117
108
  ] }),
118
109
  /* @__PURE__ */ t("div", { className: "flex h-full w-full flex-col", children: o })
119
110
  ]
@@ -167,14 +158,14 @@ function ce({
167
158
  }
168
159
  );
169
160
  }
170
- function ue({
161
+ function le({
171
162
  className: a,
172
163
  onClick: e,
173
164
  ...i
174
165
  }) {
175
166
  const { toggleSidebar: n } = S();
176
167
  return /* @__PURE__ */ p(
177
- z,
168
+ I,
178
169
  {
179
170
  className: r("size-7", a),
180
171
  "data-sidebar": "trigger",
@@ -186,13 +177,13 @@ function ue({
186
177
  variant: "ghost",
187
178
  ...i,
188
179
  children: [
189
- /* @__PURE__ */ t(q, {}),
180
+ /* @__PURE__ */ t(z, {}),
190
181
  /* @__PURE__ */ t("span", { className: "sr-only", children: "Toggle Sidebar" })
191
182
  ]
192
183
  }
193
184
  );
194
185
  }
195
- function be({ className: a, ...e }) {
186
+ function ce({ className: a, ...e }) {
196
187
  const { toggleSidebar: i } = S();
197
188
  return /* @__PURE__ */ t(
198
189
  "button",
@@ -216,7 +207,7 @@ function be({ className: a, ...e }) {
216
207
  }
217
208
  );
218
209
  }
219
- function fe({ className: a, ...e }) {
210
+ function ue({ className: a, ...e }) {
220
211
  return /* @__PURE__ */ t(
221
212
  "main",
222
213
  {
@@ -230,12 +221,12 @@ function fe({ className: a, ...e }) {
230
221
  }
231
222
  );
232
223
  }
233
- function pe({
224
+ function be({
234
225
  className: a,
235
226
  ...e
236
227
  }) {
237
228
  return /* @__PURE__ */ t(
238
- I,
229
+ E,
239
230
  {
240
231
  className: r("h-8 w-full bg-background shadow-none", a),
241
232
  "data-sidebar": "input",
@@ -244,7 +235,7 @@ function pe({
244
235
  }
245
236
  );
246
237
  }
247
- function me({ className: a, ...e }) {
238
+ function fe({ className: a, ...e }) {
248
239
  return /* @__PURE__ */ t(
249
240
  "div",
250
241
  {
@@ -255,7 +246,7 @@ function me({ className: a, ...e }) {
255
246
  }
256
247
  );
257
248
  }
258
- function ge({ className: a, ...e }) {
249
+ function pe({ className: a, ...e }) {
259
250
  return /* @__PURE__ */ t(
260
251
  "div",
261
252
  {
@@ -266,12 +257,12 @@ function ge({ className: a, ...e }) {
266
257
  }
267
258
  );
268
259
  }
269
- function he({
260
+ function me({
270
261
  className: a,
271
262
  ...e
272
263
  }) {
273
264
  return /* @__PURE__ */ t(
274
- E,
265
+ D,
275
266
  {
276
267
  className: r("mx-2 w-auto bg-sidebar-border", a),
277
268
  "data-sidebar": "separator",
@@ -280,7 +271,7 @@ function he({
280
271
  }
281
272
  );
282
273
  }
283
- function ve({ className: a, ...e }) {
274
+ function ge({ className: a, ...e }) {
284
275
  return /* @__PURE__ */ t(
285
276
  "div",
286
277
  {
@@ -294,7 +285,7 @@ function ve({ className: a, ...e }) {
294
285
  }
295
286
  );
296
287
  }
297
- function xe({ className: a, ...e }) {
288
+ function he({ className: a, ...e }) {
298
289
  return /* @__PURE__ */ t(
299
290
  "div",
300
291
  {
@@ -305,7 +296,7 @@ function xe({ className: a, ...e }) {
305
296
  }
306
297
  );
307
298
  }
308
- function we({
299
+ function ve({
309
300
  className: a,
310
301
  asChild: e = !1,
311
302
  ...i
@@ -324,7 +315,7 @@ function we({
324
315
  }
325
316
  );
326
317
  }
327
- function Se({
318
+ function xe({
328
319
  className: a,
329
320
  asChild: e = !1,
330
321
  ...i
@@ -345,7 +336,7 @@ function Se({
345
336
  }
346
337
  );
347
338
  }
348
- function ye({
339
+ function we({
349
340
  className: a,
350
341
  ...e
351
342
  }) {
@@ -359,7 +350,7 @@ function ye({
359
350
  }
360
351
  );
361
352
  }
362
- function Ne({ className: a, ...e }) {
353
+ function Se({ className: a, ...e }) {
363
354
  return /* @__PURE__ */ t(
364
355
  "ul",
365
356
  {
@@ -370,7 +361,7 @@ function Ne({ className: a, ...e }) {
370
361
  }
371
362
  );
372
363
  }
373
- function _e({ className: a, ...e }) {
364
+ function Ne({ className: a, ...e }) {
374
365
  return /* @__PURE__ */ t(
375
366
  "li",
376
367
  {
@@ -381,7 +372,7 @@ function _e({ className: a, ...e }) {
381
372
  }
382
373
  );
383
374
  }
384
- const Y = M(
375
+ const U = M(
385
376
  "peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sidebar-primary-foreground 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",
386
377
  {
387
378
  variants: {
@@ -401,7 +392,7 @@ const Y = M(
401
392
  }
402
393
  }
403
394
  );
404
- function ke({
395
+ function ye({
405
396
  asChild: a = !1,
406
397
  isActive: e = !1,
407
398
  variant: i = "default",
@@ -413,7 +404,7 @@ function ke({
413
404
  const s = a ? h : "button", { isMobile: b, state: f } = S(), v = /* @__PURE__ */ t(
414
405
  s,
415
406
  {
416
- className: r(Y({ variant: i, size: n }), c),
407
+ className: r(U({ variant: i, size: n }), c),
417
408
  "data-active": e,
418
409
  "data-sidebar": "menu-button",
419
410
  "data-size": n,
@@ -423,10 +414,10 @@ function ke({
423
414
  );
424
415
  return o ? (typeof o == "string" && (o = {
425
416
  children: o
426
- }), /* @__PURE__ */ p(R, { children: [
427
- /* @__PURE__ */ t(H, { asChild: !0, children: v }),
417
+ }), /* @__PURE__ */ p(H, { children: [
418
+ /* @__PURE__ */ t(K, { asChild: !0, children: v }),
428
419
  /* @__PURE__ */ t(
429
- K,
420
+ j,
430
421
  {
431
422
  align: "center",
432
423
  hidden: f !== "collapsed" || b,
@@ -462,7 +453,7 @@ function Ce({
462
453
  }
463
454
  );
464
455
  }
465
- function Me({
456
+ function _e({
466
457
  className: a,
467
458
  ...e
468
459
  }) {
@@ -484,7 +475,7 @@ function Me({
484
475
  }
485
476
  );
486
477
  }
487
- function ze({
478
+ function ke({
488
479
  className: a,
489
480
  showIcon: e = !1,
490
481
  ...i
@@ -499,14 +490,14 @@ function ze({
499
490
  ...i,
500
491
  children: [
501
492
  e && /* @__PURE__ */ t(
502
- N,
493
+ y,
503
494
  {
504
495
  className: "size-4 rounded-md",
505
496
  "data-sidebar": "menu-skeleton-icon"
506
497
  }
507
498
  ),
508
499
  /* @__PURE__ */ t(
509
- N,
500
+ y,
510
501
  {
511
502
  className: "h-4 max-w-(--skeleton-width) flex-1",
512
503
  "data-sidebar": "menu-skeleton-text",
@@ -519,7 +510,7 @@ function ze({
519
510
  }
520
511
  );
521
512
  }
522
- function Ie({ className: a, ...e }) {
513
+ function Me({ className: a, ...e }) {
523
514
  return /* @__PURE__ */ t(
524
515
  "ul",
525
516
  {
@@ -534,7 +525,7 @@ function Ie({ className: a, ...e }) {
534
525
  }
535
526
  );
536
527
  }
537
- function Ee({
528
+ function ze({
538
529
  className: a,
539
530
  ...e
540
531
  }) {
@@ -548,7 +539,7 @@ function Ee({
548
539
  }
549
540
  );
550
541
  }
551
- function De({
542
+ function Ie({
552
543
  asChild: a = !1,
553
544
  size: e = "md",
554
545
  isActive: i = !1,
@@ -575,28 +566,28 @@ function De({
575
566
  );
576
567
  }
577
568
  export {
578
- ce as Sidebar,
579
- ve as SidebarContent,
580
- ge as SidebarFooter,
581
- xe as SidebarGroup,
582
- Se as SidebarGroupAction,
583
- ye as SidebarGroupContent,
584
- we as SidebarGroupLabel,
585
- me as SidebarHeader,
586
- pe as SidebarInput,
587
- fe as SidebarInset,
588
- Ne as SidebarMenu,
569
+ se as Sidebar,
570
+ ge as SidebarContent,
571
+ pe as SidebarFooter,
572
+ he as SidebarGroup,
573
+ xe as SidebarGroupAction,
574
+ we as SidebarGroupContent,
575
+ ve as SidebarGroupLabel,
576
+ fe as SidebarHeader,
577
+ be as SidebarInput,
578
+ ue as SidebarInset,
579
+ Se as SidebarMenu,
589
580
  Ce as SidebarMenuAction,
590
- Me as SidebarMenuBadge,
591
- ke as SidebarMenuButton,
592
- _e as SidebarMenuItem,
593
- ze as SidebarMenuSkeleton,
594
- Ie as SidebarMenuSub,
595
- De as SidebarMenuSubButton,
596
- Ee as SidebarMenuSubItem,
597
- le as SidebarProvider,
598
- be as SidebarRail,
599
- he as SidebarSeparator,
600
- ue as SidebarTrigger,
581
+ _e as SidebarMenuBadge,
582
+ ye as SidebarMenuButton,
583
+ Ne as SidebarMenuItem,
584
+ ke as SidebarMenuSkeleton,
585
+ Me as SidebarMenuSub,
586
+ Ie as SidebarMenuSubButton,
587
+ ze as SidebarMenuSubItem,
588
+ de as SidebarProvider,
589
+ ce as SidebarRail,
590
+ me as SidebarSeparator,
591
+ le as SidebarTrigger,
601
592
  S as useSidebar
602
593
  };
@@ -5,7 +5,7 @@ import { u as S, a as K } from "../../../index-5Bhkapwi.js";
5
5
  import { c as W } from "../../../index-DFZozV_h.js";
6
6
  import { P as J, D as Q } from "../../../index-DYHsXnnS.js";
7
7
  import { u as Z } from "../../../index-Cv867SGx.js";
8
- import { c as G, R as ee, A as te, a as oe, C as re } from "../../../index-f0YS5Ufh.js";
8
+ import { c as G, R as ee, A as te, a as oe, C as re } from "../../../index-PlrlSrPo.js";
9
9
  import { P as j } from "../../../index-C8_QusYl.js";
10
10
  import { P as ne } from "../../../index-CpDnqHCm.js";
11
11
  import { u as ae } from "../../../index-437EL2iq.js";