@windrun-huaiin/base-ui 3.3.0 → 3.5.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.
Files changed (60) hide show
  1. package/dist/index.d.mts +2 -38
  2. package/dist/index.d.ts +2 -38
  3. package/dist/index.js +187 -4263
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.mjs +184 -4037
  6. package/dist/index.mjs.map +1 -1
  7. package/dist/ui/index.d.mts +37 -711
  8. package/dist/ui/index.d.ts +37 -711
  9. package/dist/ui/index.js +172 -4248
  10. package/dist/ui/index.js.map +1 -1
  11. package/dist/ui/index.mjs +171 -4024
  12. package/dist/ui/index.mjs.map +1 -1
  13. package/package.json +2 -36
  14. package/src/ui/index.ts +2 -48
  15. package/src/ui/accordion.tsx +0 -58
  16. package/src/ui/alert.tsx +0 -59
  17. package/src/ui/aspect-ratio.tsx +0 -7
  18. package/src/ui/avatar.tsx +0 -50
  19. package/src/ui/badge.tsx +0 -36
  20. package/src/ui/breadcrumb.tsx +0 -115
  21. package/src/ui/calendar.tsx +0 -66
  22. package/src/ui/card.tsx +0 -79
  23. package/src/ui/carousel.tsx +0 -262
  24. package/src/ui/chart.tsx +0 -365
  25. package/src/ui/checkbox.tsx +0 -30
  26. package/src/ui/collapsible.tsx +0 -11
  27. package/src/ui/command.tsx +0 -153
  28. package/src/ui/context-menu.tsx +0 -200
  29. package/src/ui/dialog.tsx +0 -122
  30. package/src/ui/drawer.tsx +0 -118
  31. package/src/ui/form.tsx +0 -178
  32. package/src/ui/hover-card.tsx +0 -29
  33. package/src/ui/input-otp.tsx +0 -71
  34. package/src/ui/input.tsx +0 -22
  35. package/src/ui/menubar.tsx +0 -236
  36. package/src/ui/navigation-menu.tsx +0 -128
  37. package/src/ui/pagination.tsx +0 -117
  38. package/src/ui/popover.tsx +0 -31
  39. package/src/ui/progress.tsx +0 -28
  40. package/src/ui/radio-group.tsx +0 -44
  41. package/src/ui/resizable.tsx +0 -45
  42. package/src/ui/scroll-area.tsx +0 -48
  43. package/src/ui/select.tsx +0 -160
  44. package/src/ui/separator.tsx +0 -31
  45. package/src/ui/sheet.tsx +0 -140
  46. package/src/ui/sidebar.tsx +0 -763
  47. package/src/ui/skeleton.tsx +0 -15
  48. package/src/ui/slider.tsx +0 -28
  49. package/src/ui/sonner.tsx +0 -31
  50. package/src/ui/switch.tsx +0 -29
  51. package/src/ui/table.tsx +0 -117
  52. package/src/ui/tabs.tsx +0 -55
  53. package/src/ui/textarea.tsx +0 -22
  54. package/src/ui/toast.tsx +0 -129
  55. package/src/ui/toaster.tsx +0 -35
  56. package/src/ui/toggle-group.tsx +0 -61
  57. package/src/ui/toggle.tsx +0 -45
  58. package/src/ui/tooltip.tsx +0 -30
  59. package/src/ui/use-mobile.tsx +0 -19
  60. package/src/ui/use-toast.ts +0 -194
package/dist/ui/index.mjs CHANGED
@@ -34,9 +34,21 @@ var __export = (target, all) => {
34
34
  __defProp(target, name, { get: all[name], enumerable: true });
35
35
  };
36
36
 
37
- // src/ui/accordion.tsx
37
+ // src/ui/alert-dialog.tsx
38
+ import * as React31 from "react";
39
+ import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
40
+
41
+ // ../lib/src/utils.ts
42
+ import { clsx } from "clsx";
43
+ import { twMerge } from "tailwind-merge";
44
+ function cn(...inputs) {
45
+ return twMerge(clsx(inputs));
46
+ }
47
+
48
+ // src/ui/button.tsx
38
49
  import * as React30 from "react";
39
- import * as AccordionPrimitive from "@radix-ui/react-accordion";
50
+ import { Slot } from "@radix-ui/react-slot";
51
+ import { cva } from "class-variance-authority";
40
52
 
41
53
  // src/assets/github.tsx
42
54
  import React from "react";
@@ -1303,69 +1315,8 @@ for (const [iconName, IconComponent] of Object.entries(BUILTIN_ICON_COMPONENTS))
1303
1315
  var wrappedBuiltinIconsPart = tempWrappedBuiltinIcons;
1304
1316
  var globalLucideIcons = __spreadValues(__spreadValues({}, styledLimitedIconsPart), wrappedBuiltinIconsPart);
1305
1317
 
1306
- // ../lib/src/utils.ts
1307
- import { clsx } from "clsx";
1308
- import { twMerge } from "tailwind-merge";
1309
- function cn(...inputs) {
1310
- return twMerge(clsx(inputs));
1311
- }
1312
-
1313
- // src/ui/accordion.tsx
1314
- import { jsx as jsx30, jsxs as jsxs7 } from "react/jsx-runtime";
1315
- var Accordion = AccordionPrimitive.Root;
1316
- var AccordionItem = React30.forwardRef((_a, ref) => {
1317
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1318
- return /* @__PURE__ */ jsx30(
1319
- AccordionPrimitive.Item,
1320
- __spreadValues({
1321
- ref,
1322
- className: cn("border-b", className)
1323
- }, props)
1324
- );
1325
- });
1326
- AccordionItem.displayName = "AccordionItem";
1327
- var AccordionTrigger = React30.forwardRef((_a, ref) => {
1328
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
1329
- return /* @__PURE__ */ jsx30(AccordionPrimitive.Header, { className: "flex", children: /* @__PURE__ */ jsxs7(
1330
- AccordionPrimitive.Trigger,
1331
- __spreadProps(__spreadValues({
1332
- ref,
1333
- className: cn(
1334
- "flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",
1335
- className
1336
- )
1337
- }, props), {
1338
- children: [
1339
- children,
1340
- /* @__PURE__ */ jsx30(globalLucideIcons.ChevronDown, { className: "h-4 w-4 shrink-0 transition-transform duration-200" })
1341
- ]
1342
- })
1343
- ) });
1344
- });
1345
- AccordionTrigger.displayName = AccordionPrimitive.Trigger.displayName;
1346
- var AccordionContent = React30.forwardRef((_a, ref) => {
1347
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
1348
- return /* @__PURE__ */ jsx30(
1349
- AccordionPrimitive.Content,
1350
- __spreadProps(__spreadValues({
1351
- ref,
1352
- className: "overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down"
1353
- }, props), {
1354
- children: /* @__PURE__ */ jsx30("div", { className: cn("pb-4 pt-0", className), children })
1355
- })
1356
- );
1357
- });
1358
- AccordionContent.displayName = AccordionPrimitive.Content.displayName;
1359
-
1360
- // src/ui/alert-dialog.tsx
1361
- import * as React32 from "react";
1362
- import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog";
1363
-
1364
1318
  // src/ui/button.tsx
1365
- import * as React31 from "react";
1366
- import { Slot } from "@radix-ui/react-slot";
1367
- import { cva } from "class-variance-authority";
1368
- import { jsx as jsx31, jsxs as jsxs8 } from "react/jsx-runtime";
1319
+ import { jsx as jsx30, jsxs as jsxs7 } from "react/jsx-runtime";
1369
1320
  var buttonVariants = cva(
1370
1321
  "inline-flex items-center gap-2 whitespace-nowrap rounded-md text-sm ring-offset-background transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
1371
1322
  {
@@ -1391,12 +1342,12 @@ var buttonVariants = cva(
1391
1342
  }
1392
1343
  }
1393
1344
  );
1394
- var Button = React31.forwardRef(
1345
+ var Button = React30.forwardRef(
1395
1346
  (_a, ref) => {
1396
1347
  var _b = _a, { className, variant, size, asChild = false, loading = false, children } = _b, props = __objRest(_b, ["className", "variant", "size", "asChild", "loading", "children"]);
1397
1348
  const Comp = asChild ? Slot : "button";
1398
1349
  if (asChild) {
1399
- return /* @__PURE__ */ jsx31(
1350
+ return /* @__PURE__ */ jsx30(
1400
1351
  Comp,
1401
1352
  __spreadProps(__spreadValues({
1402
1353
  className: cn(buttonVariants({ variant, size, className })),
@@ -1407,7 +1358,7 @@ var Button = React31.forwardRef(
1407
1358
  })
1408
1359
  );
1409
1360
  }
1410
- return /* @__PURE__ */ jsxs8(
1361
+ return /* @__PURE__ */ jsxs7(
1411
1362
  Comp,
1412
1363
  __spreadProps(__spreadValues({
1413
1364
  className: cn(buttonVariants({ variant, size, className })),
@@ -1416,7 +1367,7 @@ var Button = React31.forwardRef(
1416
1367
  }, props), {
1417
1368
  children: [
1418
1369
  children,
1419
- loading && /* @__PURE__ */ jsx31(globalLucideIcons.Loader2, { className: "ml-2 h-4 w-4 animate-spin" })
1370
+ loading && /* @__PURE__ */ jsx30(globalLucideIcons.Loader2, { className: "ml-2 h-4 w-4 animate-spin" })
1420
1371
  ]
1421
1372
  })
1422
1373
  );
@@ -1425,13 +1376,13 @@ var Button = React31.forwardRef(
1425
1376
  Button.displayName = "Button";
1426
1377
 
1427
1378
  // src/ui/alert-dialog.tsx
1428
- import { jsx as jsx32, jsxs as jsxs9 } from "react/jsx-runtime";
1379
+ import { jsx as jsx31, jsxs as jsxs8 } from "react/jsx-runtime";
1429
1380
  var AlertDialog = AlertDialogPrimitive.Root;
1430
1381
  var AlertDialogTrigger = AlertDialogPrimitive.Trigger;
1431
1382
  var AlertDialogPortal = AlertDialogPrimitive.Portal;
1432
- var AlertDialogOverlay = React32.forwardRef((_a, ref) => {
1383
+ var AlertDialogOverlay = React31.forwardRef((_a, ref) => {
1433
1384
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1434
- return /* @__PURE__ */ jsx32(
1385
+ return /* @__PURE__ */ jsx31(
1435
1386
  AlertDialogPrimitive.Overlay,
1436
1387
  __spreadProps(__spreadValues({
1437
1388
  className: cn(
@@ -1444,11 +1395,11 @@ var AlertDialogOverlay = React32.forwardRef((_a, ref) => {
1444
1395
  );
1445
1396
  });
1446
1397
  AlertDialogOverlay.displayName = AlertDialogPrimitive.Overlay.displayName;
1447
- var AlertDialogContent = React32.forwardRef((_a, ref) => {
1398
+ var AlertDialogContent = React31.forwardRef((_a, ref) => {
1448
1399
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1449
- return /* @__PURE__ */ jsxs9(AlertDialogPortal, { children: [
1450
- /* @__PURE__ */ jsx32(AlertDialogOverlay, {}),
1451
- /* @__PURE__ */ jsx32(
1400
+ return /* @__PURE__ */ jsxs8(AlertDialogPortal, { children: [
1401
+ /* @__PURE__ */ jsx31(AlertDialogOverlay, {}),
1402
+ /* @__PURE__ */ jsx31(
1452
1403
  AlertDialogPrimitive.Content,
1453
1404
  __spreadValues({
1454
1405
  ref,
@@ -1467,7 +1418,7 @@ var AlertDialogHeader = (_a) => {
1467
1418
  } = _b, props = __objRest(_b, [
1468
1419
  "className"
1469
1420
  ]);
1470
- return /* @__PURE__ */ jsx32(
1421
+ return /* @__PURE__ */ jsx31(
1471
1422
  "div",
1472
1423
  __spreadValues({
1473
1424
  className: cn(
@@ -1484,7 +1435,7 @@ var AlertDialogFooter = (_a) => {
1484
1435
  } = _b, props = __objRest(_b, [
1485
1436
  "className"
1486
1437
  ]);
1487
- return /* @__PURE__ */ jsx32(
1438
+ return /* @__PURE__ */ jsx31(
1488
1439
  "div",
1489
1440
  __spreadValues({
1490
1441
  className: cn(
@@ -1495,9 +1446,9 @@ var AlertDialogFooter = (_a) => {
1495
1446
  );
1496
1447
  };
1497
1448
  AlertDialogFooter.displayName = "AlertDialogFooter";
1498
- var AlertDialogTitle = React32.forwardRef((_a, ref) => {
1449
+ var AlertDialogTitle = React31.forwardRef((_a, ref) => {
1499
1450
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1500
- return /* @__PURE__ */ jsx32(
1451
+ return /* @__PURE__ */ jsx31(
1501
1452
  AlertDialogPrimitive.Title,
1502
1453
  __spreadValues({
1503
1454
  ref,
@@ -1506,9 +1457,9 @@ var AlertDialogTitle = React32.forwardRef((_a, ref) => {
1506
1457
  );
1507
1458
  });
1508
1459
  AlertDialogTitle.displayName = AlertDialogPrimitive.Title.displayName;
1509
- var AlertDialogDescription = React32.forwardRef((_a, ref) => {
1460
+ var AlertDialogDescription = React31.forwardRef((_a, ref) => {
1510
1461
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1511
- return /* @__PURE__ */ jsx32(
1462
+ return /* @__PURE__ */ jsx31(
1512
1463
  AlertDialogPrimitive.Description,
1513
1464
  __spreadValues({
1514
1465
  ref,
@@ -1517,9 +1468,9 @@ var AlertDialogDescription = React32.forwardRef((_a, ref) => {
1517
1468
  );
1518
1469
  });
1519
1470
  AlertDialogDescription.displayName = AlertDialogPrimitive.Description.displayName;
1520
- var AlertDialogAction = React32.forwardRef((_a, ref) => {
1471
+ var AlertDialogAction = React31.forwardRef((_a, ref) => {
1521
1472
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1522
- return /* @__PURE__ */ jsx32(
1473
+ return /* @__PURE__ */ jsx31(
1523
1474
  AlertDialogPrimitive.Action,
1524
1475
  __spreadValues({
1525
1476
  ref,
@@ -1528,9 +1479,9 @@ var AlertDialogAction = React32.forwardRef((_a, ref) => {
1528
1479
  );
1529
1480
  });
1530
1481
  AlertDialogAction.displayName = AlertDialogPrimitive.Action.displayName;
1531
- var AlertDialogCancel = React32.forwardRef((_a, ref) => {
1482
+ var AlertDialogCancel = React31.forwardRef((_a, ref) => {
1532
1483
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1533
- return /* @__PURE__ */ jsx32(
1484
+ return /* @__PURE__ */ jsx31(
1534
1485
  AlertDialogPrimitive.Cancel,
1535
1486
  __spreadValues({
1536
1487
  ref,
@@ -1544,3791 +1495,208 @@ var AlertDialogCancel = React32.forwardRef((_a, ref) => {
1544
1495
  });
1545
1496
  AlertDialogCancel.displayName = AlertDialogPrimitive.Cancel.displayName;
1546
1497
 
1547
- // src/ui/alert.tsx
1548
- import * as React33 from "react";
1549
- import { cva as cva2 } from "class-variance-authority";
1550
- import { jsx as jsx33 } from "react/jsx-runtime";
1551
- var alertVariants = cva2(
1552
- "relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground",
1553
- {
1554
- variants: {
1555
- variant: {
1556
- default: "bg-background text-foreground",
1557
- destructive: "border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"
1558
- }
1559
- },
1560
- defaultVariants: {
1561
- variant: "default"
1562
- }
1563
- }
1564
- );
1565
- var Alert = React33.forwardRef((_a, ref) => {
1566
- var _b = _a, { className, variant } = _b, props = __objRest(_b, ["className", "variant"]);
1567
- return /* @__PURE__ */ jsx33(
1568
- "div",
1569
- __spreadValues({
1498
+ // src/ui/dropdown-menu.tsx
1499
+ import * as React32 from "react";
1500
+ import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
1501
+ import { jsx as jsx32, jsxs as jsxs9 } from "react/jsx-runtime";
1502
+ var DropdownMenu = DropdownMenuPrimitive.Root;
1503
+ var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
1504
+ var DropdownMenuGroup = DropdownMenuPrimitive.Group;
1505
+ var DropdownMenuPortal = DropdownMenuPrimitive.Portal;
1506
+ var DropdownMenuSub = DropdownMenuPrimitive.Sub;
1507
+ var DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;
1508
+ var DropdownMenuSubTrigger = React32.forwardRef((_a, ref) => {
1509
+ var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
1510
+ return /* @__PURE__ */ jsxs9(
1511
+ DropdownMenuPrimitive.SubTrigger,
1512
+ __spreadProps(__spreadValues({
1570
1513
  ref,
1571
- role: "alert",
1572
- className: cn(alertVariants({ variant }), className)
1573
- }, props)
1514
+ className: cn(
1515
+ "flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
1516
+ inset && "pl-8",
1517
+ className
1518
+ )
1519
+ }, props), {
1520
+ children: [
1521
+ children,
1522
+ /* @__PURE__ */ jsx32(globalLucideIcons.ChevronRight, { className: "ml-auto" })
1523
+ ]
1524
+ })
1574
1525
  );
1575
1526
  });
1576
- Alert.displayName = "Alert";
1577
- var AlertTitle = React33.forwardRef((_a, ref) => {
1527
+ DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;
1528
+ var DropdownMenuSubContent = React32.forwardRef((_a, ref) => {
1578
1529
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1579
- return /* @__PURE__ */ jsx33(
1580
- "h5",
1530
+ return /* @__PURE__ */ jsx32(
1531
+ DropdownMenuPrimitive.SubContent,
1581
1532
  __spreadValues({
1582
1533
  ref,
1583
- className: cn("mb-1 font-medium leading-none tracking-tight", className)
1534
+ className: cn(
1535
+ "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg 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",
1536
+ className
1537
+ )
1584
1538
  }, props)
1585
1539
  );
1586
1540
  });
1587
- AlertTitle.displayName = "AlertTitle";
1588
- var AlertDescription = React33.forwardRef((_a, ref) => {
1589
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1590
- return /* @__PURE__ */ jsx33(
1591
- "div",
1541
+ DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
1542
+ var DropdownMenuContent = React32.forwardRef((_a, ref) => {
1543
+ var _b = _a, { className, sideOffset = 4 } = _b, props = __objRest(_b, ["className", "sideOffset"]);
1544
+ return /* @__PURE__ */ jsx32(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx32(
1545
+ DropdownMenuPrimitive.Content,
1592
1546
  __spreadValues({
1593
1547
  ref,
1594
- className: cn("text-sm [&_p]:leading-relaxed", className)
1548
+ sideOffset,
1549
+ className: cn(
1550
+ "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md 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",
1551
+ className
1552
+ )
1595
1553
  }, props)
1596
- );
1554
+ ) });
1597
1555
  });
1598
- AlertDescription.displayName = "AlertDescription";
1599
-
1600
- // src/ui/aspect-ratio.tsx
1601
- import * as AspectRatioPrimitive from "@radix-ui/react-aspect-ratio";
1602
- var AspectRatio = AspectRatioPrimitive.Root;
1603
-
1604
- // src/ui/avatar.tsx
1605
- import * as React34 from "react";
1606
- import * as AvatarPrimitive from "@radix-ui/react-avatar";
1607
- import { jsx as jsx34 } from "react/jsx-runtime";
1608
- var Avatar = React34.forwardRef((_a, ref) => {
1609
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1610
- return /* @__PURE__ */ jsx34(
1611
- AvatarPrimitive.Root,
1556
+ DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
1557
+ var DropdownMenuItem = React32.forwardRef((_a, ref) => {
1558
+ var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
1559
+ return /* @__PURE__ */ jsx32(
1560
+ DropdownMenuPrimitive.Item,
1612
1561
  __spreadValues({
1613
1562
  ref,
1614
1563
  className: cn(
1615
- "relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",
1564
+ "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
1565
+ inset && "pl-8",
1616
1566
  className
1617
1567
  )
1618
1568
  }, props)
1619
1569
  );
1620
1570
  });
1621
- Avatar.displayName = AvatarPrimitive.Root.displayName;
1622
- var AvatarImage = React34.forwardRef((_a, ref) => {
1623
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1624
- return /* @__PURE__ */ jsx34(
1625
- AvatarPrimitive.Image,
1626
- __spreadValues({
1571
+ DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
1572
+ var DropdownMenuCheckboxItem = React32.forwardRef((_a, ref) => {
1573
+ var _b = _a, { className, children, checked } = _b, props = __objRest(_b, ["className", "children", "checked"]);
1574
+ return /* @__PURE__ */ jsxs9(
1575
+ DropdownMenuPrimitive.CheckboxItem,
1576
+ __spreadProps(__spreadValues({
1627
1577
  ref,
1628
- className: cn("aspect-square h-full w-full", className)
1629
- }, props)
1578
+ className: cn(
1579
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
1580
+ className
1581
+ ),
1582
+ checked
1583
+ }, props), {
1584
+ children: [
1585
+ /* @__PURE__ */ jsx32("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx32(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx32(globalLucideIcons.Check, { className: "h-4 w-4" }) }) }),
1586
+ children
1587
+ ]
1588
+ })
1630
1589
  );
1631
1590
  });
1632
- AvatarImage.displayName = AvatarPrimitive.Image.displayName;
1633
- var AvatarFallback = React34.forwardRef((_a, ref) => {
1634
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1635
- return /* @__PURE__ */ jsx34(
1636
- AvatarPrimitive.Fallback,
1637
- __spreadValues({
1591
+ DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;
1592
+ var DropdownMenuRadioItem = React32.forwardRef((_a, ref) => {
1593
+ var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
1594
+ return /* @__PURE__ */ jsxs9(
1595
+ DropdownMenuPrimitive.RadioItem,
1596
+ __spreadProps(__spreadValues({
1638
1597
  ref,
1639
1598
  className: cn(
1640
- "flex h-full w-full items-center justify-center rounded-full bg-muted",
1599
+ "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
1641
1600
  className
1642
1601
  )
1643
- }, props)
1602
+ }, props), {
1603
+ children: [
1604
+ /* @__PURE__ */ jsx32("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx32(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx32(globalLucideIcons.Circle, { className: "h-2 w-2 fill-current" }) }) }),
1605
+ children
1606
+ ]
1607
+ })
1644
1608
  );
1645
1609
  });
1646
- AvatarFallback.displayName = AvatarPrimitive.Fallback.displayName;
1647
-
1648
- // src/ui/badge.tsx
1649
- import { cva as cva3 } from "class-variance-authority";
1650
- import { jsx as jsx35 } from "react/jsx-runtime";
1651
- var badgeVariants = cva3(
1652
- "inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2",
1653
- {
1654
- variants: {
1655
- variant: {
1656
- default: "border-transparent bg-primary text-primary-foreground hover:bg-primary/80",
1657
- secondary: "border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",
1658
- destructive: "border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",
1659
- outline: "text-foreground"
1660
- }
1661
- },
1662
- defaultVariants: {
1663
- variant: "default"
1664
- }
1665
- }
1666
- );
1667
- function Badge(_a) {
1668
- var _b = _a, { className, variant } = _b, props = __objRest(_b, ["className", "variant"]);
1669
- return /* @__PURE__ */ jsx35("div", __spreadValues({ className: cn(badgeVariants({ variant }), className) }, props));
1670
- }
1671
-
1672
- // src/ui/breadcrumb.tsx
1673
- import * as React35 from "react";
1674
- import { Slot as Slot2 } from "@radix-ui/react-slot";
1675
- import { jsx as jsx36, jsxs as jsxs10 } from "react/jsx-runtime";
1676
- var Breadcrumb = React35.forwardRef((_a, ref) => {
1677
- var props = __objRest(_a, []);
1678
- return /* @__PURE__ */ jsx36("nav", __spreadValues({ ref, "aria-label": "breadcrumb" }, props));
1679
- });
1680
- Breadcrumb.displayName = "Breadcrumb";
1681
- var BreadcrumbList = React35.forwardRef((_a, ref) => {
1682
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1683
- return /* @__PURE__ */ jsx36(
1684
- "ol",
1610
+ DropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;
1611
+ var DropdownMenuLabel = React32.forwardRef((_a, ref) => {
1612
+ var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
1613
+ return /* @__PURE__ */ jsx32(
1614
+ DropdownMenuPrimitive.Label,
1685
1615
  __spreadValues({
1686
1616
  ref,
1687
1617
  className: cn(
1688
- "flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",
1618
+ "px-2 py-1.5 text-sm font-semibold",
1619
+ inset && "pl-8",
1689
1620
  className
1690
1621
  )
1691
1622
  }, props)
1692
1623
  );
1693
1624
  });
1694
- BreadcrumbList.displayName = "BreadcrumbList";
1695
- var BreadcrumbItem = React35.forwardRef((_a, ref) => {
1696
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1697
- return /* @__PURE__ */ jsx36(
1698
- "li",
1699
- __spreadValues({
1700
- ref,
1701
- className: cn("inline-flex items-center gap-1.5", className)
1702
- }, props)
1703
- );
1704
- });
1705
- BreadcrumbItem.displayName = "BreadcrumbItem";
1706
- var BreadcrumbLink = React35.forwardRef((_a, ref) => {
1707
- var _b = _a, { asChild, className } = _b, props = __objRest(_b, ["asChild", "className"]);
1708
- const Comp = asChild ? Slot2 : "a";
1709
- return /* @__PURE__ */ jsx36(
1710
- Comp,
1711
- __spreadValues({
1712
- ref,
1713
- className: cn("transition-colors hover:text-foreground", className)
1714
- }, props)
1715
- );
1716
- });
1717
- BreadcrumbLink.displayName = "BreadcrumbLink";
1718
- var BreadcrumbPage = React35.forwardRef((_a, ref) => {
1625
+ DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
1626
+ var DropdownMenuSeparator = React32.forwardRef((_a, ref) => {
1719
1627
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1720
- return /* @__PURE__ */ jsx36(
1721
- "span",
1628
+ return /* @__PURE__ */ jsx32(
1629
+ DropdownMenuPrimitive.Separator,
1722
1630
  __spreadValues({
1723
1631
  ref,
1724
- role: "link",
1725
- "aria-disabled": "true",
1726
- "aria-current": "page",
1727
- className: cn("font-normal text-foreground", className)
1632
+ className: cn("-mx-1 my-1 h-px bg-muted", className)
1728
1633
  }, props)
1729
1634
  );
1730
1635
  });
1731
- BreadcrumbPage.displayName = "BreadcrumbPage";
1732
- var BreadcrumbSeparator = (_a) => {
1733
- var _b = _a, {
1734
- children,
1735
- className
1736
- } = _b, props = __objRest(_b, [
1737
- "children",
1738
- "className"
1739
- ]);
1740
- return /* @__PURE__ */ jsx36(
1741
- "li",
1742
- __spreadProps(__spreadValues({
1743
- role: "presentation",
1744
- "aria-hidden": "true",
1745
- className: cn("[&>svg]:w-3.5 [&>svg]:h-3.5", className)
1746
- }, props), {
1747
- children: children != null ? children : /* @__PURE__ */ jsx36(globalLucideIcons.ChevronRight, {})
1748
- })
1749
- );
1750
- };
1751
- BreadcrumbSeparator.displayName = "BreadcrumbSeparator";
1752
- var BreadcrumbEllipsis = (_a) => {
1636
+ DropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;
1637
+ var DropdownMenuShortcut = (_a) => {
1753
1638
  var _b = _a, {
1754
1639
  className
1755
1640
  } = _b, props = __objRest(_b, [
1756
1641
  "className"
1757
1642
  ]);
1758
- return /* @__PURE__ */ jsxs10(
1643
+ return /* @__PURE__ */ jsx32(
1759
1644
  "span",
1760
- __spreadProps(__spreadValues({
1761
- role: "presentation",
1762
- "aria-hidden": "true",
1763
- className: cn("flex h-9 w-9 items-center justify-center", className)
1764
- }, props), {
1765
- children: [
1766
- /* @__PURE__ */ jsx36(globalLucideIcons.MoreHorizontal, { className: "h-4 w-4" }),
1767
- /* @__PURE__ */ jsx36("span", { className: "sr-only", children: "More" })
1768
- ]
1769
- })
1770
- );
1771
- };
1772
- BreadcrumbEllipsis.displayName = "BreadcrumbElipssis";
1773
-
1774
- // src/ui/calendar.tsx
1775
- import { DayPicker } from "react-day-picker";
1776
- import { jsx as jsx37 } from "react/jsx-runtime";
1777
- function Calendar(_a) {
1778
- var _b = _a, {
1779
- className,
1780
- classNames,
1781
- showOutsideDays = true
1782
- } = _b, props = __objRest(_b, [
1783
- "className",
1784
- "classNames",
1785
- "showOutsideDays"
1786
- ]);
1787
- return /* @__PURE__ */ jsx37(
1788
- DayPicker,
1789
1645
  __spreadValues({
1790
- showOutsideDays,
1791
- className: cn("p-3", className),
1792
- classNames: __spreadValues({
1793
- months: "flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",
1794
- month: "space-y-4",
1795
- caption: "flex justify-center pt-1 relative items-center",
1796
- caption_label: "text-sm font-medium",
1797
- nav: "space-x-1 flex items-center",
1798
- nav_button: cn(
1799
- buttonVariants({ variant: "outline" }),
1800
- "h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"
1801
- ),
1802
- nav_button_previous: "absolute left-1",
1803
- nav_button_next: "absolute right-1",
1804
- table: "w-full border-collapse space-y-1",
1805
- head_row: "flex",
1806
- head_cell: "text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",
1807
- row: "flex w-full mt-2",
1808
- cell: "h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",
1809
- day: cn(
1810
- buttonVariants({ variant: "ghost" }),
1811
- "h-9 w-9 p-0 font-normal aria-selected:opacity-100"
1812
- ),
1813
- day_range_end: "day-range-end",
1814
- day_selected: "bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",
1815
- day_today: "bg-accent text-accent-foreground",
1816
- day_outside: "day-outside text-muted-foreground aria-selected:bg-accent/50 aria-selected:text-muted-foreground",
1817
- day_disabled: "text-muted-foreground opacity-50",
1818
- day_range_middle: "aria-selected:bg-accent aria-selected:text-accent-foreground",
1819
- day_hidden: "invisible"
1820
- }, classNames),
1821
- components: {
1822
- IconLeft: (_a2) => {
1823
- var _props = __objRest(_a2, []);
1824
- return /* @__PURE__ */ jsx37(globalLucideIcons.ChevronLeft, { className: "h-4 w-4" });
1825
- },
1826
- IconRight: (_b2) => {
1827
- var _props = __objRest(_b2, []);
1828
- return /* @__PURE__ */ jsx37(globalLucideIcons.ChevronRight, { className: "h-4 w-4" });
1829
- }
1830
- }
1646
+ className: cn("ml-auto text-xs tracking-widest opacity-60", className)
1831
1647
  }, props)
1832
1648
  );
1833
- }
1834
- Calendar.displayName = "Calendar";
1649
+ };
1650
+ DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
1835
1651
 
1836
- // src/ui/card.tsx
1837
- import * as React36 from "react";
1838
- import { jsx as jsx38 } from "react/jsx-runtime";
1839
- var Card = React36.forwardRef((_a, ref) => {
1840
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1841
- return /* @__PURE__ */ jsx38(
1842
- "div",
1843
- __spreadValues({
1844
- ref,
1845
- className: cn(
1846
- "rounded-lg border bg-card text-card-foreground shadow-xs",
1847
- className
1848
- )
1849
- }, props)
1850
- );
1851
- });
1852
- Card.displayName = "Card";
1853
- var CardHeader = React36.forwardRef((_a, ref) => {
1652
+ // src/ui/label.tsx
1653
+ import * as React33 from "react";
1654
+ import * as LabelPrimitive from "@radix-ui/react-label";
1655
+ import { cva as cva2 } from "class-variance-authority";
1656
+ import { jsx as jsx33 } from "react/jsx-runtime";
1657
+ var labelVariants = cva2(
1658
+ "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
1659
+ );
1660
+ var Label2 = React33.forwardRef((_a, ref) => {
1854
1661
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1855
- return /* @__PURE__ */ jsx38(
1856
- "div",
1662
+ return /* @__PURE__ */ jsx33(
1663
+ LabelPrimitive.Root,
1857
1664
  __spreadValues({
1858
1665
  ref,
1859
- className: cn("flex flex-col space-y-1.5 p-6", className)
1666
+ className: cn(labelVariants(), className)
1860
1667
  }, props)
1861
1668
  );
1862
1669
  });
1863
- CardHeader.displayName = "CardHeader";
1864
- var CardTitle = React36.forwardRef((_a, ref) => {
1865
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1866
- return /* @__PURE__ */ jsx38(
1867
- "div",
1868
- __spreadValues({
1869
- ref,
1870
- className: cn(
1871
- "text-2xl font-semibold leading-none tracking-tight",
1872
- className
1873
- )
1874
- }, props)
1875
- );
1876
- });
1877
- CardTitle.displayName = "CardTitle";
1878
- var CardDescription = React36.forwardRef((_a, ref) => {
1879
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1880
- return /* @__PURE__ */ jsx38(
1881
- "div",
1882
- __spreadValues({
1883
- ref,
1884
- className: cn("text-sm text-muted-foreground", className)
1885
- }, props)
1886
- );
1887
- });
1888
- CardDescription.displayName = "CardDescription";
1889
- var CardContent = React36.forwardRef((_a, ref) => {
1890
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1891
- return /* @__PURE__ */ jsx38("div", __spreadValues({ ref, className: cn("p-6 pt-0", className) }, props));
1892
- });
1893
- CardContent.displayName = "CardContent";
1894
- var CardFooter = React36.forwardRef((_a, ref) => {
1895
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
1896
- return /* @__PURE__ */ jsx38(
1897
- "div",
1898
- __spreadValues({
1899
- ref,
1900
- className: cn("flex items-center p-6 pt-0", className)
1901
- }, props)
1902
- );
1903
- });
1904
- CardFooter.displayName = "CardFooter";
1670
+ Label2.displayName = LabelPrimitive.Root.displayName;
1905
1671
 
1906
- // src/ui/carousel.tsx
1907
- import * as React37 from "react";
1908
- import useEmblaCarousel from "embla-carousel-react";
1909
- import { jsx as jsx39, jsxs as jsxs11 } from "react/jsx-runtime";
1910
- var CarouselContext = React37.createContext(null);
1911
- function useCarousel() {
1912
- const context = React37.useContext(CarouselContext);
1913
- if (!context) {
1914
- throw new Error("useCarousel must be used within a <Carousel />");
1915
- }
1916
- return context;
1917
- }
1918
- var Carousel = React37.forwardRef(
1672
+ // src/ui/language-button.tsx
1673
+ import * as React34 from "react";
1674
+ import { jsx as jsx34 } from "react/jsx-runtime";
1675
+ var LanguageButton = React34.forwardRef(
1919
1676
  (_a, ref) => {
1920
- var _b = _a, {
1921
- orientation = "horizontal",
1922
- opts,
1923
- setApi,
1924
- plugins,
1925
- className,
1926
- children
1927
- } = _b, props = __objRest(_b, [
1928
- "orientation",
1929
- "opts",
1930
- "setApi",
1931
- "plugins",
1932
- "className",
1933
- "children"
1934
- ]);
1935
- const [carouselRef, api] = useEmblaCarousel(
1936
- __spreadProps(__spreadValues({}, opts), {
1937
- axis: orientation === "horizontal" ? "x" : "y"
1938
- }),
1939
- plugins
1940
- );
1941
- const [canScrollPrev, setCanScrollPrev] = React37.useState(false);
1942
- const [canScrollNext, setCanScrollNext] = React37.useState(false);
1943
- const onSelect = React37.useCallback((api2) => {
1944
- if (!api2) {
1945
- return;
1946
- }
1947
- setCanScrollPrev(api2.canScrollPrev());
1948
- setCanScrollNext(api2.canScrollNext());
1949
- }, []);
1950
- const scrollPrev = React37.useCallback(() => {
1951
- api == null ? void 0 : api.scrollPrev();
1952
- }, [api]);
1953
- const scrollNext = React37.useCallback(() => {
1954
- api == null ? void 0 : api.scrollNext();
1955
- }, [api]);
1956
- const handleKeyDown = React37.useCallback(
1957
- (event) => {
1958
- if (event.key === "ArrowLeft") {
1959
- event.preventDefault();
1960
- scrollPrev();
1961
- } else if (event.key === "ArrowRight") {
1962
- event.preventDefault();
1963
- scrollNext();
1964
- }
1965
- },
1966
- [scrollPrev, scrollNext]
1967
- );
1968
- React37.useEffect(() => {
1969
- if (!api || !setApi) {
1970
- return;
1971
- }
1972
- setApi(api);
1973
- }, [api, setApi]);
1974
- React37.useEffect(() => {
1975
- if (!api) {
1976
- return;
1977
- }
1978
- onSelect(api);
1979
- api.on("reInit", onSelect);
1980
- api.on("select", onSelect);
1981
- return () => {
1982
- api == null ? void 0 : api.off("select", onSelect);
1983
- };
1984
- }, [api, onSelect]);
1985
- return /* @__PURE__ */ jsx39(
1986
- CarouselContext.Provider,
1987
- {
1988
- value: {
1989
- carouselRef,
1990
- api,
1991
- opts,
1992
- orientation: orientation || ((opts == null ? void 0 : opts.axis) === "y" ? "vertical" : "horizontal"),
1993
- scrollPrev,
1994
- scrollNext,
1995
- canScrollPrev,
1996
- canScrollNext
1997
- },
1998
- children: /* @__PURE__ */ jsx39(
1999
- "div",
2000
- __spreadProps(__spreadValues({
2001
- ref,
2002
- onKeyDownCapture: handleKeyDown,
2003
- className: cn("relative", className),
2004
- role: "region",
2005
- "aria-roledescription": "carousel"
2006
- }, props), {
2007
- children
2008
- })
2009
- )
2010
- }
2011
- );
2012
- }
2013
- );
2014
- Carousel.displayName = "Carousel";
2015
- var CarouselContent = React37.forwardRef((_a, ref) => {
2016
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2017
- const { carouselRef, orientation } = useCarousel();
2018
- return /* @__PURE__ */ jsx39("div", { ref: carouselRef, className: "overflow-hidden", children: /* @__PURE__ */ jsx39(
2019
- "div",
2020
- __spreadValues({
2021
- ref,
2022
- className: cn(
2023
- "flex",
2024
- orientation === "horizontal" ? "-ml-4" : "-mt-4 flex-col",
2025
- className
2026
- )
2027
- }, props)
2028
- ) });
2029
- });
2030
- CarouselContent.displayName = "CarouselContent";
2031
- var CarouselItem = React37.forwardRef((_a, ref) => {
2032
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2033
- const { orientation } = useCarousel();
2034
- return /* @__PURE__ */ jsx39(
2035
- "div",
2036
- __spreadValues({
2037
- ref,
2038
- role: "group",
2039
- "aria-roledescription": "slide",
2040
- className: cn(
2041
- "min-w-0 shrink-0 grow-0 basis-full",
2042
- orientation === "horizontal" ? "pl-4" : "pt-4",
2043
- className
2044
- )
2045
- }, props)
2046
- );
2047
- });
2048
- CarouselItem.displayName = "CarouselItem";
2049
- var CarouselPrevious = React37.forwardRef((_a, ref) => {
2050
- var _b = _a, { className, variant = "outline", size = "icon" } = _b, props = __objRest(_b, ["className", "variant", "size"]);
2051
- const { orientation, scrollPrev, canScrollPrev } = useCarousel();
2052
- return /* @__PURE__ */ jsxs11(
2053
- Button,
2054
- __spreadProps(__spreadValues({
2055
- ref,
2056
- variant,
2057
- size,
2058
- className: cn(
2059
- "absolute h-8 w-8 rounded-full",
2060
- orientation === "horizontal" ? "-left-12 top-1/2 -translate-y-1/2" : "-top-12 left-1/2 -translate-x-1/2 rotate-90",
2061
- className
2062
- ),
2063
- disabled: !canScrollPrev,
2064
- onClick: scrollPrev
2065
- }, props), {
2066
- children: [
2067
- /* @__PURE__ */ jsx39(globalLucideIcons.ArrowLeft, { className: "h-4 w-4" }),
2068
- /* @__PURE__ */ jsx39("span", { className: "sr-only", children: "Previous slide" })
2069
- ]
2070
- })
2071
- );
2072
- });
2073
- CarouselPrevious.displayName = "CarouselPrevious";
2074
- var CarouselNext = React37.forwardRef((_a, ref) => {
2075
- var _b = _a, { className, variant = "outline", size = "icon" } = _b, props = __objRest(_b, ["className", "variant", "size"]);
2076
- const { orientation, scrollNext, canScrollNext } = useCarousel();
2077
- return /* @__PURE__ */ jsxs11(
2078
- Button,
2079
- __spreadProps(__spreadValues({
2080
- ref,
2081
- variant,
2082
- size,
2083
- className: cn(
2084
- "absolute h-8 w-8 rounded-full",
2085
- orientation === "horizontal" ? "-right-12 top-1/2 -translate-y-1/2" : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90",
2086
- className
2087
- ),
2088
- disabled: !canScrollNext,
2089
- onClick: scrollNext
2090
- }, props), {
2091
- children: [
2092
- /* @__PURE__ */ jsx39(globalLucideIcons.ArrowRight, { className: "h-4 w-4" }),
2093
- /* @__PURE__ */ jsx39("span", { className: "sr-only", children: "Next slide" })
2094
- ]
2095
- })
2096
- );
2097
- });
2098
- CarouselNext.displayName = "CarouselNext";
2099
-
2100
- // src/ui/chart.tsx
2101
- import * as React38 from "react";
2102
- import * as RechartsPrimitive from "recharts";
2103
- import { Fragment, jsx as jsx40, jsxs as jsxs12 } from "react/jsx-runtime";
2104
- var THEMES = { light: "", dark: ".dark" };
2105
- var ChartContext = React38.createContext(null);
2106
- function useChart() {
2107
- const context = React38.useContext(ChartContext);
2108
- if (!context) {
2109
- throw new Error("useChart must be used within a <ChartContainer />");
2110
- }
2111
- return context;
2112
- }
2113
- var ChartContainer = React38.forwardRef((_a, ref) => {
2114
- var _b = _a, { id, className, children, config } = _b, props = __objRest(_b, ["id", "className", "children", "config"]);
2115
- const uniqueId = React38.useId();
2116
- const chartId = `chart-${id || uniqueId.replace(/:/g, "")}`;
2117
- return /* @__PURE__ */ jsx40(ChartContext.Provider, { value: { config }, children: /* @__PURE__ */ jsxs12(
2118
- "div",
2119
- __spreadProps(__spreadValues({
2120
- "data-chart": chartId,
2121
- ref,
2122
- className: cn(
2123
- "flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-hidden [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-sector]:outline-hidden [&_.recharts-surface]:outline-hidden",
2124
- className
2125
- )
2126
- }, props), {
2127
- children: [
2128
- /* @__PURE__ */ jsx40(ChartStyle, { id: chartId, config }),
2129
- /* @__PURE__ */ jsx40(RechartsPrimitive.ResponsiveContainer, { children })
2130
- ]
2131
- })
2132
- ) });
2133
- });
2134
- ChartContainer.displayName = "Chart";
2135
- var ChartStyle = ({ id, config }) => {
2136
- const colorConfig = Object.entries(config).filter(
2137
- ([_, config2]) => config2.theme || config2.color
2138
- );
2139
- if (!colorConfig.length) {
2140
- return null;
2141
- }
2142
- return /* @__PURE__ */ jsx40(
2143
- "style",
2144
- {
2145
- dangerouslySetInnerHTML: {
2146
- __html: Object.entries(THEMES).map(
2147
- ([theme, prefix]) => `
2148
- ${prefix} [data-chart=${id}] {
2149
- ${colorConfig.map(([key, itemConfig]) => {
2150
- var _a;
2151
- const color = ((_a = itemConfig.theme) == null ? void 0 : _a[theme]) || itemConfig.color;
2152
- return color ? ` --color-${key}: ${color};` : null;
2153
- }).join("\n")}
2154
- }
2155
- `
2156
- ).join("\n")
2157
- }
2158
- }
2159
- );
2160
- };
2161
- var ChartTooltip = RechartsPrimitive.Tooltip;
2162
- var ChartTooltipContent = React38.forwardRef(
2163
- ({
2164
- active,
2165
- payload,
2166
- className,
2167
- indicator = "dot",
2168
- hideLabel = false,
2169
- hideIndicator = false,
2170
- label,
2171
- labelFormatter,
2172
- labelClassName,
2173
- formatter,
2174
- color,
2175
- nameKey,
2176
- labelKey
2177
- }, ref) => {
2178
- const { config } = useChart();
2179
- const tooltipLabel = React38.useMemo(() => {
2180
- var _a;
2181
- if (hideLabel || !(payload == null ? void 0 : payload.length)) {
2182
- return null;
2183
- }
2184
- const [item] = payload;
2185
- const key = `${labelKey || item.dataKey || item.name || "value"}`;
2186
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
2187
- const value = !labelKey && typeof label === "string" ? ((_a = config[label]) == null ? void 0 : _a.label) || label : itemConfig == null ? void 0 : itemConfig.label;
2188
- if (labelFormatter) {
2189
- return /* @__PURE__ */ jsx40("div", { className: cn("font-medium", labelClassName), children: labelFormatter(value, payload) });
2190
- }
2191
- if (!value) {
2192
- return null;
2193
- }
2194
- return /* @__PURE__ */ jsx40("div", { className: cn("font-medium", labelClassName), children: value });
2195
- }, [
2196
- label,
2197
- labelFormatter,
2198
- payload,
2199
- hideLabel,
2200
- labelClassName,
2201
- config,
2202
- labelKey
2203
- ]);
2204
- if (!active || !(payload == null ? void 0 : payload.length)) {
2205
- return null;
2206
- }
2207
- const nestLabel = payload.length === 1 && indicator !== "dot";
2208
- return /* @__PURE__ */ jsxs12(
2209
- "div",
2210
- {
2211
- ref,
2212
- className: cn(
2213
- "grid min-w-[8rem] items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl",
2214
- className
2215
- ),
2216
- children: [
2217
- !nestLabel ? tooltipLabel : null,
2218
- /* @__PURE__ */ jsx40("div", { className: "grid gap-1.5", children: payload.map((item, index) => {
2219
- const key = `${nameKey || item.name || item.dataKey || "value"}`;
2220
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
2221
- const indicatorColor = color || item.payload.fill || item.color;
2222
- return /* @__PURE__ */ jsx40(
2223
- "div",
2224
- {
2225
- className: cn(
2226
- "flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground",
2227
- indicator === "dot" && "items-center"
2228
- ),
2229
- children: formatter && (item == null ? void 0 : item.value) !== void 0 && item.name ? formatter(item.value, item.name, item, index, item.payload) : /* @__PURE__ */ jsxs12(Fragment, { children: [
2230
- (itemConfig == null ? void 0 : itemConfig.icon) ? /* @__PURE__ */ jsx40(itemConfig.icon, {}) : !hideIndicator && /* @__PURE__ */ jsx40(
2231
- "div",
2232
- {
2233
- className: cn(
2234
- "shrink-0 rounded-[2px] border-(--color-border) bg-(--color-bg)",
2235
- {
2236
- "h-2.5 w-2.5": indicator === "dot",
2237
- "w-1": indicator === "line",
2238
- "w-0 border-[1.5px] border-dashed bg-transparent": indicator === "dashed",
2239
- "my-0.5": nestLabel && indicator === "dashed"
2240
- }
2241
- ),
2242
- style: {
2243
- "--color-bg": indicatorColor,
2244
- "--color-border": indicatorColor
2245
- }
2246
- }
2247
- ),
2248
- /* @__PURE__ */ jsxs12(
2249
- "div",
2250
- {
2251
- className: cn(
2252
- "flex flex-1 justify-between leading-none",
2253
- nestLabel ? "items-end" : "items-center"
2254
- ),
2255
- children: [
2256
- /* @__PURE__ */ jsxs12("div", { className: "grid gap-1.5", children: [
2257
- nestLabel ? tooltipLabel : null,
2258
- /* @__PURE__ */ jsx40("span", { className: "text-muted-foreground", children: (itemConfig == null ? void 0 : itemConfig.label) || item.name })
2259
- ] }),
2260
- item.value && /* @__PURE__ */ jsx40("span", { className: "font-mono font-medium tabular-nums text-foreground", children: item.value.toLocaleString() })
2261
- ]
2262
- }
2263
- )
2264
- ] })
2265
- },
2266
- item.dataKey
2267
- );
2268
- }) })
2269
- ]
2270
- }
2271
- );
2272
- }
2273
- );
2274
- ChartTooltipContent.displayName = "ChartTooltip";
2275
- var ChartLegend = RechartsPrimitive.Legend;
2276
- var ChartLegendContent = React38.forwardRef(
2277
- ({ className, hideIcon = false, payload, verticalAlign = "bottom", nameKey }, ref) => {
2278
- const { config } = useChart();
2279
- if (!(payload == null ? void 0 : payload.length)) {
2280
- return null;
2281
- }
2282
- return /* @__PURE__ */ jsx40(
2283
- "div",
2284
- {
2285
- ref,
1677
+ var _b = _a, { className, variant = "default", size = "default" } = _b, props = __objRest(_b, ["className", "variant", "size"]);
1678
+ return /* @__PURE__ */ jsx34(
1679
+ "button",
1680
+ __spreadValues({
2286
1681
  className: cn(
2287
- "flex items-center justify-center gap-4",
2288
- verticalAlign === "top" ? "pb-3" : "pt-3",
1682
+ "inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none ring-offset-background",
1683
+ {
1684
+ "bg-primary text-primary-foreground hover:bg-primary/90": variant === "default",
1685
+ "hover:bg-accent hover:text-accent-foreground": variant === "ghost",
1686
+ "h-10 px-4 py-2": size === "default",
1687
+ "h-9 px-3": size === "sm",
1688
+ "h-11 px-8": size === "lg",
1689
+ "h-10 w-10": size === "icon"
1690
+ },
2289
1691
  className
2290
1692
  ),
2291
- children: payload.map((item) => {
2292
- const key = `${nameKey || item.dataKey || "value"}`;
2293
- const itemConfig = getPayloadConfigFromPayload(config, item, key);
2294
- return /* @__PURE__ */ jsxs12(
2295
- "div",
2296
- {
2297
- className: cn(
2298
- "flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground"
2299
- ),
2300
- children: [
2301
- (itemConfig == null ? void 0 : itemConfig.icon) && !hideIcon ? /* @__PURE__ */ jsx40(itemConfig.icon, {}) : /* @__PURE__ */ jsx40(
2302
- "div",
2303
- {
2304
- className: "h-2 w-2 shrink-0 rounded-[2px]",
2305
- style: {
2306
- backgroundColor: item.color
2307
- }
2308
- }
2309
- ),
2310
- itemConfig == null ? void 0 : itemConfig.label
2311
- ]
2312
- },
2313
- item.value
2314
- );
2315
- })
2316
- }
1693
+ ref
1694
+ }, props)
2317
1695
  );
2318
1696
  }
2319
1697
  );
2320
- ChartLegendContent.displayName = "ChartLegend";
2321
- function getPayloadConfigFromPayload(config, payload, key) {
2322
- if (typeof payload !== "object" || payload === null) {
2323
- return void 0;
2324
- }
2325
- const payloadPayload = "payload" in payload && typeof payload.payload === "object" && payload.payload !== null ? payload.payload : void 0;
2326
- let configLabelKey = key;
2327
- if (key in payload && typeof payload[key] === "string") {
2328
- configLabelKey = payload[key];
2329
- } else if (payloadPayload && key in payloadPayload && typeof payloadPayload[key] === "string") {
2330
- configLabelKey = payloadPayload[key];
2331
- }
2332
- return configLabelKey in config ? config[configLabelKey] : config[key];
2333
- }
2334
-
2335
- // src/ui/checkbox.tsx
2336
- import * as React39 from "react";
2337
- import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
2338
- import { jsx as jsx41 } from "react/jsx-runtime";
2339
- var Checkbox = React39.forwardRef((_a, ref) => {
2340
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2341
- return /* @__PURE__ */ jsx41(
2342
- CheckboxPrimitive.Root,
2343
- __spreadProps(__spreadValues({
2344
- ref,
2345
- className: cn(
2346
- "peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",
2347
- className
2348
- )
2349
- }, props), {
2350
- children: /* @__PURE__ */ jsx41(
2351
- CheckboxPrimitive.Indicator,
2352
- {
2353
- className: cn("flex items-center justify-center text-current"),
2354
- children: /* @__PURE__ */ jsx41(globalLucideIcons.Check, { className: "h-4 w-4" })
2355
- }
2356
- )
2357
- })
2358
- );
2359
- });
2360
- Checkbox.displayName = CheckboxPrimitive.Root.displayName;
2361
-
2362
- // src/ui/collapsible.tsx
2363
- import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
2364
- var Collapsible = CollapsiblePrimitive.Root;
2365
- var CollapsibleTrigger2 = CollapsiblePrimitive.CollapsibleTrigger;
2366
- var CollapsibleContent2 = CollapsiblePrimitive.CollapsibleContent;
2367
-
2368
- // src/ui/command.tsx
2369
- import * as React41 from "react";
2370
- import { Command as CommandPrimitive } from "cmdk";
2371
-
2372
- // src/ui/dialog.tsx
2373
- import * as React40 from "react";
2374
- import * as DialogPrimitive from "@radix-ui/react-dialog";
2375
- import { jsx as jsx42, jsxs as jsxs13 } from "react/jsx-runtime";
2376
- var Dialog = DialogPrimitive.Root;
2377
- var DialogTrigger = DialogPrimitive.Trigger;
2378
- var DialogPortal = DialogPrimitive.Portal;
2379
- var DialogClose = DialogPrimitive.Close;
2380
- var DialogOverlay = React40.forwardRef((_a, ref) => {
2381
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2382
- return /* @__PURE__ */ jsx42(
2383
- DialogPrimitive.Overlay,
2384
- __spreadValues({
2385
- ref,
2386
- className: cn(
2387
- "fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
2388
- className
2389
- )
2390
- }, props)
2391
- );
2392
- });
2393
- DialogOverlay.displayName = DialogPrimitive.Overlay.displayName;
2394
- var DialogContent = React40.forwardRef((_a, ref) => {
2395
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
2396
- return /* @__PURE__ */ jsxs13(DialogPortal, { children: [
2397
- /* @__PURE__ */ jsx42(DialogOverlay, {}),
2398
- /* @__PURE__ */ jsxs13(
2399
- DialogPrimitive.Content,
2400
- __spreadProps(__spreadValues({
2401
- ref,
2402
- className: cn(
2403
- "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 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-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",
2404
- className
2405
- )
2406
- }, props), {
2407
- children: [
2408
- children,
2409
- /* @__PURE__ */ jsxs13(DialogPrimitive.Close, { className: "absolute right-4 top-4 rounded-sm 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-accent data-[state=open]:text-muted-foreground", children: [
2410
- /* @__PURE__ */ jsx42(globalLucideIcons.X, { className: "h-4 w-4" }),
2411
- /* @__PURE__ */ jsx42("span", { className: "sr-only", children: "Close" })
2412
- ] })
2413
- ]
2414
- })
2415
- )
2416
- ] });
2417
- });
2418
- DialogContent.displayName = DialogPrimitive.Content.displayName;
2419
- var DialogHeader = (_a) => {
2420
- var _b = _a, {
2421
- className
2422
- } = _b, props = __objRest(_b, [
2423
- "className"
2424
- ]);
2425
- return /* @__PURE__ */ jsx42(
2426
- "div",
2427
- __spreadValues({
2428
- className: cn(
2429
- "flex flex-col space-y-1.5 text-center sm:text-left",
2430
- className
2431
- )
2432
- }, props)
2433
- );
2434
- };
2435
- DialogHeader.displayName = "DialogHeader";
2436
- var DialogFooter = (_a) => {
2437
- var _b = _a, {
2438
- className
2439
- } = _b, props = __objRest(_b, [
2440
- "className"
2441
- ]);
2442
- return /* @__PURE__ */ jsx42(
2443
- "div",
2444
- __spreadValues({
2445
- className: cn(
2446
- "flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
2447
- className
2448
- )
2449
- }, props)
2450
- );
2451
- };
2452
- DialogFooter.displayName = "DialogFooter";
2453
- var DialogTitle = React40.forwardRef((_a, ref) => {
2454
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2455
- return /* @__PURE__ */ jsx42(
2456
- DialogPrimitive.Title,
2457
- __spreadValues({
2458
- ref,
2459
- className: cn(
2460
- "text-lg font-semibold leading-none tracking-tight",
2461
- className
2462
- )
2463
- }, props)
2464
- );
2465
- });
2466
- DialogTitle.displayName = DialogPrimitive.Title.displayName;
2467
- var DialogDescription = React40.forwardRef((_a, ref) => {
2468
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2469
- return /* @__PURE__ */ jsx42(
2470
- DialogPrimitive.Description,
2471
- __spreadValues({
2472
- ref,
2473
- className: cn("text-sm text-muted-foreground", className)
2474
- }, props)
2475
- );
2476
- });
2477
- DialogDescription.displayName = DialogPrimitive.Description.displayName;
2478
-
2479
- // src/ui/command.tsx
2480
- import { jsx as jsx43, jsxs as jsxs14 } from "react/jsx-runtime";
2481
- var Command = React41.forwardRef((_a, ref) => {
2482
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2483
- return /* @__PURE__ */ jsx43(
2484
- CommandPrimitive,
2485
- __spreadValues({
2486
- ref,
2487
- className: cn(
2488
- "flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",
2489
- className
2490
- )
2491
- }, props)
2492
- );
2493
- });
2494
- Command.displayName = CommandPrimitive.displayName;
2495
- var CommandDialog = (_a) => {
2496
- var _b = _a, { children } = _b, props = __objRest(_b, ["children"]);
2497
- return /* @__PURE__ */ jsx43(Dialog, __spreadProps(__spreadValues({}, props), { children: /* @__PURE__ */ jsx43(DialogContent, { className: "overflow-hidden p-0 shadow-lg", children: /* @__PURE__ */ jsx43(Command, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children }) }) }));
2498
- };
2499
- var CommandInput = React41.forwardRef((_a, ref) => {
2500
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2501
- return /* @__PURE__ */ jsxs14("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
2502
- /* @__PURE__ */ jsx43(globalLucideIcons.Search, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
2503
- /* @__PURE__ */ jsx43(
2504
- CommandPrimitive.Input,
2505
- __spreadValues({
2506
- ref,
2507
- className: cn(
2508
- "flex h-11 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",
2509
- className
2510
- )
2511
- }, props)
2512
- )
2513
- ] });
2514
- });
2515
- CommandInput.displayName = CommandPrimitive.Input.displayName;
2516
- var CommandList = React41.forwardRef((_a, ref) => {
2517
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2518
- return /* @__PURE__ */ jsx43(
2519
- CommandPrimitive.List,
2520
- __spreadValues({
2521
- ref,
2522
- className: cn("max-h-[300px] overflow-y-auto overflow-x-hidden", className)
2523
- }, props)
2524
- );
2525
- });
2526
- CommandList.displayName = CommandPrimitive.List.displayName;
2527
- var CommandEmpty = React41.forwardRef((props, ref) => /* @__PURE__ */ jsx43(
2528
- CommandPrimitive.Empty,
2529
- __spreadValues({
2530
- ref,
2531
- className: "py-6 text-center text-sm"
2532
- }, props)
2533
- ));
2534
- CommandEmpty.displayName = CommandPrimitive.Empty.displayName;
2535
- var CommandGroup = React41.forwardRef((_a, ref) => {
2536
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2537
- return /* @__PURE__ */ jsx43(
2538
- CommandPrimitive.Group,
2539
- __spreadValues({
2540
- ref,
2541
- className: cn(
2542
- "overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",
2543
- className
2544
- )
2545
- }, props)
2546
- );
2547
- });
2548
- CommandGroup.displayName = CommandPrimitive.Group.displayName;
2549
- var CommandSeparator = React41.forwardRef((_a, ref) => {
2550
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2551
- return /* @__PURE__ */ jsx43(
2552
- CommandPrimitive.Separator,
2553
- __spreadValues({
2554
- ref,
2555
- className: cn("-mx-1 h-px bg-border", className)
2556
- }, props)
2557
- );
2558
- });
2559
- CommandSeparator.displayName = CommandPrimitive.Separator.displayName;
2560
- var CommandItem = React41.forwardRef((_a, ref) => {
2561
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2562
- return /* @__PURE__ */ jsx43(
2563
- CommandPrimitive.Item,
2564
- __spreadValues({
2565
- ref,
2566
- className: cn(
2567
- "relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden data-[disabled=true]:pointer-events-none data-[selected='true']:bg-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
2568
- className
2569
- )
2570
- }, props)
2571
- );
2572
- });
2573
- CommandItem.displayName = CommandPrimitive.Item.displayName;
2574
- var CommandShortcut = (_a) => {
2575
- var _b = _a, {
2576
- className
2577
- } = _b, props = __objRest(_b, [
2578
- "className"
2579
- ]);
2580
- return /* @__PURE__ */ jsx43(
2581
- "span",
2582
- __spreadValues({
2583
- className: cn(
2584
- "ml-auto text-xs tracking-widest text-muted-foreground",
2585
- className
2586
- )
2587
- }, props)
2588
- );
2589
- };
2590
- CommandShortcut.displayName = "CommandShortcut";
2591
-
2592
- // src/ui/context-menu.tsx
2593
- import * as React42 from "react";
2594
- import * as ContextMenuPrimitive from "@radix-ui/react-context-menu";
2595
- import { jsx as jsx44, jsxs as jsxs15 } from "react/jsx-runtime";
2596
- var ContextMenu = ContextMenuPrimitive.Root;
2597
- var ContextMenuTrigger = ContextMenuPrimitive.Trigger;
2598
- var ContextMenuGroup = ContextMenuPrimitive.Group;
2599
- var ContextMenuPortal = ContextMenuPrimitive.Portal;
2600
- var ContextMenuSub = ContextMenuPrimitive.Sub;
2601
- var ContextMenuRadioGroup = ContextMenuPrimitive.RadioGroup;
2602
- var ContextMenuSubTrigger = React42.forwardRef((_a, ref) => {
2603
- var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
2604
- return /* @__PURE__ */ jsxs15(
2605
- ContextMenuPrimitive.SubTrigger,
2606
- __spreadProps(__spreadValues({
2607
- ref,
2608
- className: cn(
2609
- "flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
2610
- inset && "pl-8",
2611
- className
2612
- )
2613
- }, props), {
2614
- children: [
2615
- children,
2616
- /* @__PURE__ */ jsx44(globalLucideIcons.ChevronRight, { className: "ml-auto h-4 w-4" })
2617
- ]
2618
- })
2619
- );
2620
- });
2621
- ContextMenuSubTrigger.displayName = ContextMenuPrimitive.SubTrigger.displayName;
2622
- var ContextMenuSubContent = React42.forwardRef((_a, ref) => {
2623
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2624
- return /* @__PURE__ */ jsx44(
2625
- ContextMenuPrimitive.SubContent,
2626
- __spreadValues({
2627
- ref,
2628
- className: cn(
2629
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md 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",
2630
- className
2631
- )
2632
- }, props)
2633
- );
2634
- });
2635
- ContextMenuSubContent.displayName = ContextMenuPrimitive.SubContent.displayName;
2636
- var ContextMenuContent = React42.forwardRef((_a, ref) => {
2637
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2638
- return /* @__PURE__ */ jsx44(ContextMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx44(
2639
- ContextMenuPrimitive.Content,
2640
- __spreadValues({
2641
- ref,
2642
- className: cn(
2643
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md animate-in fade-in-80 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",
2644
- className
2645
- )
2646
- }, props)
2647
- ) });
2648
- });
2649
- ContextMenuContent.displayName = ContextMenuPrimitive.Content.displayName;
2650
- var ContextMenuItem = React42.forwardRef((_a, ref) => {
2651
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
2652
- return /* @__PURE__ */ jsx44(
2653
- ContextMenuPrimitive.Item,
2654
- __spreadValues({
2655
- ref,
2656
- className: cn(
2657
- "relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2658
- inset && "pl-8",
2659
- className
2660
- )
2661
- }, props)
2662
- );
2663
- });
2664
- ContextMenuItem.displayName = ContextMenuPrimitive.Item.displayName;
2665
- var ContextMenuCheckboxItem = React42.forwardRef((_a, ref) => {
2666
- var _b = _a, { className, children, checked } = _b, props = __objRest(_b, ["className", "children", "checked"]);
2667
- return /* @__PURE__ */ jsxs15(
2668
- ContextMenuPrimitive.CheckboxItem,
2669
- __spreadProps(__spreadValues({
2670
- ref,
2671
- className: cn(
2672
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2673
- className
2674
- ),
2675
- checked
2676
- }, props), {
2677
- children: [
2678
- /* @__PURE__ */ jsx44("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx44(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx44(globalLucideIcons.Check, { className: "h-4 w-4" }) }) }),
2679
- children
2680
- ]
2681
- })
2682
- );
2683
- });
2684
- ContextMenuCheckboxItem.displayName = ContextMenuPrimitive.CheckboxItem.displayName;
2685
- var ContextMenuRadioItem = React42.forwardRef((_a, ref) => {
2686
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
2687
- return /* @__PURE__ */ jsxs15(
2688
- ContextMenuPrimitive.RadioItem,
2689
- __spreadProps(__spreadValues({
2690
- ref,
2691
- className: cn(
2692
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2693
- className
2694
- )
2695
- }, props), {
2696
- children: [
2697
- /* @__PURE__ */ jsx44("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx44(ContextMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx44(globalLucideIcons.Circle, { className: "h-2 w-2 fill-current" }) }) }),
2698
- children
2699
- ]
2700
- })
2701
- );
2702
- });
2703
- ContextMenuRadioItem.displayName = ContextMenuPrimitive.RadioItem.displayName;
2704
- var ContextMenuLabel = React42.forwardRef((_a, ref) => {
2705
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
2706
- return /* @__PURE__ */ jsx44(
2707
- ContextMenuPrimitive.Label,
2708
- __spreadValues({
2709
- ref,
2710
- className: cn(
2711
- "px-2 py-1.5 text-sm font-semibold text-foreground",
2712
- inset && "pl-8",
2713
- className
2714
- )
2715
- }, props)
2716
- );
2717
- });
2718
- ContextMenuLabel.displayName = ContextMenuPrimitive.Label.displayName;
2719
- var ContextMenuSeparator = React42.forwardRef((_a, ref) => {
2720
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2721
- return /* @__PURE__ */ jsx44(
2722
- ContextMenuPrimitive.Separator,
2723
- __spreadValues({
2724
- ref,
2725
- className: cn("-mx-1 my-1 h-px bg-border", className)
2726
- }, props)
2727
- );
2728
- });
2729
- ContextMenuSeparator.displayName = ContextMenuPrimitive.Separator.displayName;
2730
- var ContextMenuShortcut = (_a) => {
2731
- var _b = _a, {
2732
- className
2733
- } = _b, props = __objRest(_b, [
2734
- "className"
2735
- ]);
2736
- return /* @__PURE__ */ jsx44(
2737
- "span",
2738
- __spreadValues({
2739
- className: cn(
2740
- "ml-auto text-xs tracking-widest text-muted-foreground",
2741
- className
2742
- )
2743
- }, props)
2744
- );
2745
- };
2746
- ContextMenuShortcut.displayName = "ContextMenuShortcut";
2747
-
2748
- // src/ui/drawer.tsx
2749
- import * as React43 from "react";
2750
- import { Drawer as DrawerPrimitive } from "vaul";
2751
- import { jsx as jsx45, jsxs as jsxs16 } from "react/jsx-runtime";
2752
- var Drawer = (_a) => {
2753
- var _b = _a, {
2754
- shouldScaleBackground = true
2755
- } = _b, props = __objRest(_b, [
2756
- "shouldScaleBackground"
2757
- ]);
2758
- return /* @__PURE__ */ jsx45(
2759
- DrawerPrimitive.Root,
2760
- __spreadValues({
2761
- shouldScaleBackground
2762
- }, props)
2763
- );
2764
- };
2765
- Drawer.displayName = "Drawer";
2766
- var DrawerTrigger = DrawerPrimitive.Trigger;
2767
- var DrawerPortal = DrawerPrimitive.Portal;
2768
- var DrawerClose = DrawerPrimitive.Close;
2769
- var DrawerOverlay = React43.forwardRef((_a, ref) => {
2770
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2771
- return /* @__PURE__ */ jsx45(
2772
- DrawerPrimitive.Overlay,
2773
- __spreadValues({
2774
- ref,
2775
- className: cn("fixed inset-0 z-50 bg-black/80", className)
2776
- }, props)
2777
- );
2778
- });
2779
- DrawerOverlay.displayName = DrawerPrimitive.Overlay.displayName;
2780
- var DrawerContent = React43.forwardRef((_a, ref) => {
2781
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
2782
- return /* @__PURE__ */ jsxs16(DrawerPortal, { children: [
2783
- /* @__PURE__ */ jsx45(DrawerOverlay, {}),
2784
- /* @__PURE__ */ jsxs16(
2785
- DrawerPrimitive.Content,
2786
- __spreadProps(__spreadValues({
2787
- ref,
2788
- className: cn(
2789
- "fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",
2790
- className
2791
- )
2792
- }, props), {
2793
- children: [
2794
- /* @__PURE__ */ jsx45("div", { className: "mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted" }),
2795
- children
2796
- ]
2797
- })
2798
- )
2799
- ] });
2800
- });
2801
- DrawerContent.displayName = "DrawerContent";
2802
- var DrawerHeader = (_a) => {
2803
- var _b = _a, {
2804
- className
2805
- } = _b, props = __objRest(_b, [
2806
- "className"
2807
- ]);
2808
- return /* @__PURE__ */ jsx45(
2809
- "div",
2810
- __spreadValues({
2811
- className: cn("grid gap-1.5 p-4 text-center sm:text-left", className)
2812
- }, props)
2813
- );
2814
- };
2815
- DrawerHeader.displayName = "DrawerHeader";
2816
- var DrawerFooter = (_a) => {
2817
- var _b = _a, {
2818
- className
2819
- } = _b, props = __objRest(_b, [
2820
- "className"
2821
- ]);
2822
- return /* @__PURE__ */ jsx45(
2823
- "div",
2824
- __spreadValues({
2825
- className: cn("mt-auto flex flex-col gap-2 p-4", className)
2826
- }, props)
2827
- );
2828
- };
2829
- DrawerFooter.displayName = "DrawerFooter";
2830
- var DrawerTitle = React43.forwardRef((_a, ref) => {
2831
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2832
- return /* @__PURE__ */ jsx45(
2833
- DrawerPrimitive.Title,
2834
- __spreadValues({
2835
- ref,
2836
- className: cn(
2837
- "text-lg font-semibold leading-none tracking-tight",
2838
- className
2839
- )
2840
- }, props)
2841
- );
2842
- });
2843
- DrawerTitle.displayName = DrawerPrimitive.Title.displayName;
2844
- var DrawerDescription = React43.forwardRef((_a, ref) => {
2845
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2846
- return /* @__PURE__ */ jsx45(
2847
- DrawerPrimitive.Description,
2848
- __spreadValues({
2849
- ref,
2850
- className: cn("text-sm text-muted-foreground", className)
2851
- }, props)
2852
- );
2853
- });
2854
- DrawerDescription.displayName = DrawerPrimitive.Description.displayName;
2855
-
2856
- // src/ui/dropdown-menu.tsx
2857
- import * as React44 from "react";
2858
- import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
2859
- import { jsx as jsx46, jsxs as jsxs17 } from "react/jsx-runtime";
2860
- var DropdownMenu = DropdownMenuPrimitive.Root;
2861
- var DropdownMenuTrigger = DropdownMenuPrimitive.Trigger;
2862
- var DropdownMenuGroup = DropdownMenuPrimitive.Group;
2863
- var DropdownMenuPortal = DropdownMenuPrimitive.Portal;
2864
- var DropdownMenuSub = DropdownMenuPrimitive.Sub;
2865
- var DropdownMenuRadioGroup = DropdownMenuPrimitive.RadioGroup;
2866
- var DropdownMenuSubTrigger = React44.forwardRef((_a, ref) => {
2867
- var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
2868
- return /* @__PURE__ */ jsxs17(
2869
- DropdownMenuPrimitive.SubTrigger,
2870
- __spreadProps(__spreadValues({
2871
- ref,
2872
- className: cn(
2873
- "flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
2874
- inset && "pl-8",
2875
- className
2876
- )
2877
- }, props), {
2878
- children: [
2879
- children,
2880
- /* @__PURE__ */ jsx46(globalLucideIcons.ChevronRight, { className: "ml-auto" })
2881
- ]
2882
- })
2883
- );
2884
- });
2885
- DropdownMenuSubTrigger.displayName = DropdownMenuPrimitive.SubTrigger.displayName;
2886
- var DropdownMenuSubContent = React44.forwardRef((_a, ref) => {
2887
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2888
- return /* @__PURE__ */ jsx46(
2889
- DropdownMenuPrimitive.SubContent,
2890
- __spreadValues({
2891
- ref,
2892
- className: cn(
2893
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg 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",
2894
- className
2895
- )
2896
- }, props)
2897
- );
2898
- });
2899
- DropdownMenuSubContent.displayName = DropdownMenuPrimitive.SubContent.displayName;
2900
- var DropdownMenuContent = React44.forwardRef((_a, ref) => {
2901
- var _b = _a, { className, sideOffset = 4 } = _b, props = __objRest(_b, ["className", "sideOffset"]);
2902
- return /* @__PURE__ */ jsx46(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx46(
2903
- DropdownMenuPrimitive.Content,
2904
- __spreadValues({
2905
- ref,
2906
- sideOffset,
2907
- className: cn(
2908
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md 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",
2909
- className
2910
- )
2911
- }, props)
2912
- ) });
2913
- });
2914
- DropdownMenuContent.displayName = DropdownMenuPrimitive.Content.displayName;
2915
- var DropdownMenuItem = React44.forwardRef((_a, ref) => {
2916
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
2917
- return /* @__PURE__ */ jsx46(
2918
- DropdownMenuPrimitive.Item,
2919
- __spreadValues({
2920
- ref,
2921
- className: cn(
2922
- "relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",
2923
- inset && "pl-8",
2924
- className
2925
- )
2926
- }, props)
2927
- );
2928
- });
2929
- DropdownMenuItem.displayName = DropdownMenuPrimitive.Item.displayName;
2930
- var DropdownMenuCheckboxItem = React44.forwardRef((_a, ref) => {
2931
- var _b = _a, { className, children, checked } = _b, props = __objRest(_b, ["className", "children", "checked"]);
2932
- return /* @__PURE__ */ jsxs17(
2933
- DropdownMenuPrimitive.CheckboxItem,
2934
- __spreadProps(__spreadValues({
2935
- ref,
2936
- className: cn(
2937
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2938
- className
2939
- ),
2940
- checked
2941
- }, props), {
2942
- children: [
2943
- /* @__PURE__ */ jsx46("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx46(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx46(globalLucideIcons.Check, { className: "h-4 w-4" }) }) }),
2944
- children
2945
- ]
2946
- })
2947
- );
2948
- });
2949
- DropdownMenuCheckboxItem.displayName = DropdownMenuPrimitive.CheckboxItem.displayName;
2950
- var DropdownMenuRadioItem = React44.forwardRef((_a, ref) => {
2951
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
2952
- return /* @__PURE__ */ jsxs17(
2953
- DropdownMenuPrimitive.RadioItem,
2954
- __spreadProps(__spreadValues({
2955
- ref,
2956
- className: cn(
2957
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden transition-colors focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
2958
- className
2959
- )
2960
- }, props), {
2961
- children: [
2962
- /* @__PURE__ */ jsx46("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx46(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx46(globalLucideIcons.Circle, { className: "h-2 w-2 fill-current" }) }) }),
2963
- children
2964
- ]
2965
- })
2966
- );
2967
- });
2968
- DropdownMenuRadioItem.displayName = DropdownMenuPrimitive.RadioItem.displayName;
2969
- var DropdownMenuLabel = React44.forwardRef((_a, ref) => {
2970
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
2971
- return /* @__PURE__ */ jsx46(
2972
- DropdownMenuPrimitive.Label,
2973
- __spreadValues({
2974
- ref,
2975
- className: cn(
2976
- "px-2 py-1.5 text-sm font-semibold",
2977
- inset && "pl-8",
2978
- className
2979
- )
2980
- }, props)
2981
- );
2982
- });
2983
- DropdownMenuLabel.displayName = DropdownMenuPrimitive.Label.displayName;
2984
- var DropdownMenuSeparator = React44.forwardRef((_a, ref) => {
2985
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
2986
- return /* @__PURE__ */ jsx46(
2987
- DropdownMenuPrimitive.Separator,
2988
- __spreadValues({
2989
- ref,
2990
- className: cn("-mx-1 my-1 h-px bg-muted", className)
2991
- }, props)
2992
- );
2993
- });
2994
- DropdownMenuSeparator.displayName = DropdownMenuPrimitive.Separator.displayName;
2995
- var DropdownMenuShortcut = (_a) => {
2996
- var _b = _a, {
2997
- className
2998
- } = _b, props = __objRest(_b, [
2999
- "className"
3000
- ]);
3001
- return /* @__PURE__ */ jsx46(
3002
- "span",
3003
- __spreadValues({
3004
- className: cn("ml-auto text-xs tracking-widest opacity-60", className)
3005
- }, props)
3006
- );
3007
- };
3008
- DropdownMenuShortcut.displayName = "DropdownMenuShortcut";
3009
-
3010
- // src/ui/form.tsx
3011
- import * as React46 from "react";
3012
- import { Slot as Slot3 } from "@radix-ui/react-slot";
3013
- import {
3014
- Controller,
3015
- FormProvider,
3016
- useFormContext
3017
- } from "react-hook-form";
3018
-
3019
- // src/ui/label.tsx
3020
- import * as React45 from "react";
3021
- import * as LabelPrimitive from "@radix-ui/react-label";
3022
- import { cva as cva4 } from "class-variance-authority";
3023
- import { jsx as jsx47 } from "react/jsx-runtime";
3024
- var labelVariants = cva4(
3025
- "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"
3026
- );
3027
- var Label3 = React45.forwardRef((_a, ref) => {
3028
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3029
- return /* @__PURE__ */ jsx47(
3030
- LabelPrimitive.Root,
3031
- __spreadValues({
3032
- ref,
3033
- className: cn(labelVariants(), className)
3034
- }, props)
3035
- );
3036
- });
3037
- Label3.displayName = LabelPrimitive.Root.displayName;
3038
-
3039
- // src/ui/form.tsx
3040
- import { jsx as jsx48 } from "react/jsx-runtime";
3041
- var Form = FormProvider;
3042
- var FormFieldContext = React46.createContext(
3043
- {}
3044
- );
3045
- var FormField = (_a) => {
3046
- var props = __objRest(_a, []);
3047
- return /* @__PURE__ */ jsx48(FormFieldContext.Provider, { value: { name: props.name }, children: /* @__PURE__ */ jsx48(Controller, __spreadValues({}, props)) });
3048
- };
3049
- var useFormField = () => {
3050
- const fieldContext = React46.useContext(FormFieldContext);
3051
- const itemContext = React46.useContext(FormItemContext);
3052
- const { getFieldState, formState } = useFormContext();
3053
- const fieldState = getFieldState(fieldContext.name, formState);
3054
- if (!fieldContext) {
3055
- throw new Error("useFormField should be used within <FormField>");
3056
- }
3057
- const { id } = itemContext;
3058
- return __spreadValues({
3059
- id,
3060
- name: fieldContext.name,
3061
- formItemId: `${id}-form-item`,
3062
- formDescriptionId: `${id}-form-item-description`,
3063
- formMessageId: `${id}-form-item-message`
3064
- }, fieldState);
3065
- };
3066
- var FormItemContext = React46.createContext(
3067
- {}
3068
- );
3069
- var FormItem = React46.forwardRef((_a, ref) => {
3070
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3071
- const id = React46.useId();
3072
- return /* @__PURE__ */ jsx48(FormItemContext.Provider, { value: { id }, children: /* @__PURE__ */ jsx48("div", __spreadValues({ ref, className: cn("space-y-2", className) }, props)) });
3073
- });
3074
- FormItem.displayName = "FormItem";
3075
- var FormLabel = React46.forwardRef((_a, ref) => {
3076
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3077
- const { error, formItemId } = useFormField();
3078
- return /* @__PURE__ */ jsx48(
3079
- Label3,
3080
- __spreadValues({
3081
- ref,
3082
- className: cn(error && "text-destructive", className),
3083
- htmlFor: formItemId
3084
- }, props)
3085
- );
3086
- });
3087
- FormLabel.displayName = "FormLabel";
3088
- var FormControl = React46.forwardRef((_a, ref) => {
3089
- var props = __objRest(_a, []);
3090
- const { error, formItemId, formDescriptionId, formMessageId } = useFormField();
3091
- return /* @__PURE__ */ jsx48(
3092
- Slot3,
3093
- __spreadValues({
3094
- ref,
3095
- id: formItemId,
3096
- "aria-describedby": !error ? `${formDescriptionId}` : `${formDescriptionId} ${formMessageId}`,
3097
- "aria-invalid": !!error
3098
- }, props)
3099
- );
3100
- });
3101
- FormControl.displayName = "FormControl";
3102
- var FormDescription = React46.forwardRef((_a, ref) => {
3103
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3104
- const { formDescriptionId } = useFormField();
3105
- return /* @__PURE__ */ jsx48(
3106
- "p",
3107
- __spreadValues({
3108
- ref,
3109
- id: formDescriptionId,
3110
- className: cn("text-sm text-muted-foreground", className)
3111
- }, props)
3112
- );
3113
- });
3114
- FormDescription.displayName = "FormDescription";
3115
- var FormMessage = React46.forwardRef((_a, ref) => {
3116
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3117
- const { error, formMessageId } = useFormField();
3118
- const body = error ? String(error == null ? void 0 : error.message) : children;
3119
- if (!body) {
3120
- return null;
3121
- }
3122
- return /* @__PURE__ */ jsx48(
3123
- "p",
3124
- __spreadProps(__spreadValues({
3125
- ref,
3126
- id: formMessageId,
3127
- className: cn("text-sm font-medium text-destructive", className)
3128
- }, props), {
3129
- children: body
3130
- })
3131
- );
3132
- });
3133
- FormMessage.displayName = "FormMessage";
3134
-
3135
- // src/ui/hover-card.tsx
3136
- import * as React47 from "react";
3137
- import * as HoverCardPrimitive from "@radix-ui/react-hover-card";
3138
- import { jsx as jsx49 } from "react/jsx-runtime";
3139
- var HoverCard = HoverCardPrimitive.Root;
3140
- var HoverCardTrigger = HoverCardPrimitive.Trigger;
3141
- var HoverCardContent = React47.forwardRef((_a, ref) => {
3142
- var _b = _a, { className, align = "center", sideOffset = 4 } = _b, props = __objRest(_b, ["className", "align", "sideOffset"]);
3143
- return /* @__PURE__ */ jsx49(
3144
- HoverCardPrimitive.Content,
3145
- __spreadValues({
3146
- ref,
3147
- align,
3148
- sideOffset,
3149
- className: cn(
3150
- "z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden 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",
3151
- className
3152
- )
3153
- }, props)
3154
- );
3155
- });
3156
- HoverCardContent.displayName = HoverCardPrimitive.Content.displayName;
3157
-
3158
- // src/ui/input-otp.tsx
3159
- import * as React48 from "react";
3160
- import { OTPInput, OTPInputContext } from "input-otp";
3161
- import { jsx as jsx50, jsxs as jsxs18 } from "react/jsx-runtime";
3162
- var InputOTP = React48.forwardRef((_a, ref) => {
3163
- var _b = _a, { className, containerClassName } = _b, props = __objRest(_b, ["className", "containerClassName"]);
3164
- return /* @__PURE__ */ jsx50(
3165
- OTPInput,
3166
- __spreadValues({
3167
- ref,
3168
- containerClassName: cn(
3169
- "flex items-center gap-2 has-disabled:opacity-50",
3170
- containerClassName
3171
- ),
3172
- className: cn("disabled:cursor-not-allowed", className)
3173
- }, props)
3174
- );
3175
- });
3176
- InputOTP.displayName = "InputOTP";
3177
- var InputOTPGroup = React48.forwardRef((_a, ref) => {
3178
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3179
- return /* @__PURE__ */ jsx50("div", __spreadValues({ ref, className: cn("flex items-center", className) }, props));
3180
- });
3181
- InputOTPGroup.displayName = "InputOTPGroup";
3182
- var InputOTPSlot = React48.forwardRef((_a, ref) => {
3183
- var _b = _a, { index, className } = _b, props = __objRest(_b, ["index", "className"]);
3184
- const inputOTPContext = React48.useContext(OTPInputContext);
3185
- const { char, hasFakeCaret, isActive } = inputOTPContext.slots[index];
3186
- return /* @__PURE__ */ jsxs18(
3187
- "div",
3188
- __spreadProps(__spreadValues({
3189
- ref,
3190
- className: cn(
3191
- "relative flex h-10 w-10 items-center justify-center border-y border-r border-input text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md",
3192
- isActive && "z-10 ring-2 ring-ring ring-offset-background",
3193
- className
3194
- )
3195
- }, props), {
3196
- children: [
3197
- char,
3198
- hasFakeCaret && /* @__PURE__ */ jsx50("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx50("div", { className: "h-4 w-px animate-caret-blink bg-foreground duration-1000" }) })
3199
- ]
3200
- })
3201
- );
3202
- });
3203
- InputOTPSlot.displayName = "InputOTPSlot";
3204
- var InputOTPSeparator = React48.forwardRef((_a, ref) => {
3205
- var props = __objRest(_a, []);
3206
- return /* @__PURE__ */ jsx50("div", __spreadProps(__spreadValues({ ref, role: "separator" }, props), { children: /* @__PURE__ */ jsx50(globalLucideIcons.Dot, {}) }));
3207
- });
3208
- InputOTPSeparator.displayName = "InputOTPSeparator";
3209
-
3210
- // src/ui/input.tsx
3211
- import * as React49 from "react";
3212
- import { jsx as jsx51 } from "react/jsx-runtime";
3213
- var Input = React49.forwardRef(
3214
- (_a, ref) => {
3215
- var _b = _a, { className, type } = _b, props = __objRest(_b, ["className", "type"]);
3216
- return /* @__PURE__ */ jsx51(
3217
- "input",
3218
- __spreadValues({
3219
- type,
3220
- className: cn(
3221
- "flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
3222
- className
3223
- ),
3224
- ref
3225
- }, props)
3226
- );
3227
- }
3228
- );
3229
- Input.displayName = "Input";
3230
-
3231
- // src/ui/language-button.tsx
3232
- import * as React50 from "react";
3233
- import { jsx as jsx52 } from "react/jsx-runtime";
3234
- var LanguageButton = React50.forwardRef(
3235
- (_a, ref) => {
3236
- var _b = _a, { className, variant = "default", size = "default" } = _b, props = __objRest(_b, ["className", "variant", "size"]);
3237
- return /* @__PURE__ */ jsx52(
3238
- "button",
3239
- __spreadValues({
3240
- className: cn(
3241
- "inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none ring-offset-background",
3242
- {
3243
- "bg-primary text-primary-foreground hover:bg-primary/90": variant === "default",
3244
- "hover:bg-accent hover:text-accent-foreground": variant === "ghost",
3245
- "h-10 px-4 py-2": size === "default",
3246
- "h-9 px-3": size === "sm",
3247
- "h-11 px-8": size === "lg",
3248
- "h-10 w-10": size === "icon"
3249
- },
3250
- className
3251
- ),
3252
- ref
3253
- }, props)
3254
- );
3255
- }
3256
- );
3257
- LanguageButton.displayName = "Button";
3258
-
3259
- // src/ui/menubar.tsx
3260
- import * as React51 from "react";
3261
- import * as MenubarPrimitive from "@radix-ui/react-menubar";
3262
- import { jsx as jsx53, jsxs as jsxs19 } from "react/jsx-runtime";
3263
- var MenubarMenu = MenubarPrimitive.Menu;
3264
- var MenubarGroup = MenubarPrimitive.Group;
3265
- var MenubarPortal = MenubarPrimitive.Portal;
3266
- var MenubarSub = MenubarPrimitive.Sub;
3267
- var MenubarRadioGroup = MenubarPrimitive.RadioGroup;
3268
- var Menubar = React51.forwardRef((_a, ref) => {
3269
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3270
- return /* @__PURE__ */ jsx53(
3271
- MenubarPrimitive.Root,
3272
- __spreadValues({
3273
- ref,
3274
- className: cn(
3275
- "flex h-10 items-center space-x-1 rounded-md border bg-background p-1",
3276
- className
3277
- )
3278
- }, props)
3279
- );
3280
- });
3281
- Menubar.displayName = MenubarPrimitive.Root.displayName;
3282
- var MenubarTrigger = React51.forwardRef((_a, ref) => {
3283
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3284
- return /* @__PURE__ */ jsx53(
3285
- MenubarPrimitive.Trigger,
3286
- __spreadValues({
3287
- ref,
3288
- className: cn(
3289
- "flex cursor-default select-none items-center rounded-sm px-3 py-1.5 text-sm font-medium outline-hidden focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
3290
- className
3291
- )
3292
- }, props)
3293
- );
3294
- });
3295
- MenubarTrigger.displayName = MenubarPrimitive.Trigger.displayName;
3296
- var MenubarSubTrigger = React51.forwardRef((_a, ref) => {
3297
- var _b = _a, { className, inset, children } = _b, props = __objRest(_b, ["className", "inset", "children"]);
3298
- return /* @__PURE__ */ jsxs19(
3299
- MenubarPrimitive.SubTrigger,
3300
- __spreadProps(__spreadValues({
3301
- ref,
3302
- className: cn(
3303
- "flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",
3304
- inset && "pl-8",
3305
- className
3306
- )
3307
- }, props), {
3308
- children: [
3309
- children,
3310
- /* @__PURE__ */ jsx53(globalLucideIcons.ChevronRight, { className: "ml-auto h-4 w-4" })
3311
- ]
3312
- })
3313
- );
3314
- });
3315
- MenubarSubTrigger.displayName = MenubarPrimitive.SubTrigger.displayName;
3316
- var MenubarSubContent = React51.forwardRef((_a, ref) => {
3317
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3318
- return /* @__PURE__ */ jsx53(
3319
- MenubarPrimitive.SubContent,
3320
- __spreadValues({
3321
- ref,
3322
- className: cn(
3323
- "z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 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",
3324
- className
3325
- )
3326
- }, props)
3327
- );
3328
- });
3329
- MenubarSubContent.displayName = MenubarPrimitive.SubContent.displayName;
3330
- var MenubarContent = React51.forwardRef(
3331
- (_a, ref) => {
3332
- var _b = _a, { className, align = "start", alignOffset = -4, sideOffset = 8 } = _b, props = __objRest(_b, ["className", "align", "alignOffset", "sideOffset"]);
3333
- return /* @__PURE__ */ jsx53(MenubarPrimitive.Portal, { children: /* @__PURE__ */ jsx53(
3334
- MenubarPrimitive.Content,
3335
- __spreadValues({
3336
- ref,
3337
- align,
3338
- alignOffset,
3339
- sideOffset,
3340
- className: cn(
3341
- "z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in 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",
3342
- className
3343
- )
3344
- }, props)
3345
- ) });
3346
- }
3347
- );
3348
- MenubarContent.displayName = MenubarPrimitive.Content.displayName;
3349
- var MenubarItem = React51.forwardRef((_a, ref) => {
3350
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
3351
- return /* @__PURE__ */ jsx53(
3352
- MenubarPrimitive.Item,
3353
- __spreadValues({
3354
- ref,
3355
- className: cn(
3356
- "relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
3357
- inset && "pl-8",
3358
- className
3359
- )
3360
- }, props)
3361
- );
3362
- });
3363
- MenubarItem.displayName = MenubarPrimitive.Item.displayName;
3364
- var MenubarCheckboxItem = React51.forwardRef((_a, ref) => {
3365
- var _b = _a, { className, children, checked } = _b, props = __objRest(_b, ["className", "children", "checked"]);
3366
- return /* @__PURE__ */ jsxs19(
3367
- MenubarPrimitive.CheckboxItem,
3368
- __spreadProps(__spreadValues({
3369
- ref,
3370
- className: cn(
3371
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
3372
- className
3373
- ),
3374
- checked
3375
- }, props), {
3376
- children: [
3377
- /* @__PURE__ */ jsx53("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx53(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx53(globalLucideIcons.Check, { className: "h-4 w-4" }) }) }),
3378
- children
3379
- ]
3380
- })
3381
- );
3382
- });
3383
- MenubarCheckboxItem.displayName = MenubarPrimitive.CheckboxItem.displayName;
3384
- var MenubarRadioItem = React51.forwardRef((_a, ref) => {
3385
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3386
- return /* @__PURE__ */ jsxs19(
3387
- MenubarPrimitive.RadioItem,
3388
- __spreadProps(__spreadValues({
3389
- ref,
3390
- className: cn(
3391
- "relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
3392
- className
3393
- )
3394
- }, props), {
3395
- children: [
3396
- /* @__PURE__ */ jsx53("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx53(MenubarPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx53(globalLucideIcons.Circle, { className: "h-2 w-2 fill-current" }) }) }),
3397
- children
3398
- ]
3399
- })
3400
- );
3401
- });
3402
- MenubarRadioItem.displayName = MenubarPrimitive.RadioItem.displayName;
3403
- var MenubarLabel = React51.forwardRef((_a, ref) => {
3404
- var _b = _a, { className, inset } = _b, props = __objRest(_b, ["className", "inset"]);
3405
- return /* @__PURE__ */ jsx53(
3406
- MenubarPrimitive.Label,
3407
- __spreadValues({
3408
- ref,
3409
- className: cn(
3410
- "px-2 py-1.5 text-sm font-semibold",
3411
- inset && "pl-8",
3412
- className
3413
- )
3414
- }, props)
3415
- );
3416
- });
3417
- MenubarLabel.displayName = MenubarPrimitive.Label.displayName;
3418
- var MenubarSeparator = React51.forwardRef((_a, ref) => {
3419
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3420
- return /* @__PURE__ */ jsx53(
3421
- MenubarPrimitive.Separator,
3422
- __spreadValues({
3423
- ref,
3424
- className: cn("-mx-1 my-1 h-px bg-muted", className)
3425
- }, props)
3426
- );
3427
- });
3428
- MenubarSeparator.displayName = MenubarPrimitive.Separator.displayName;
3429
- var MenubarShortcut = (_a) => {
3430
- var _b = _a, {
3431
- className
3432
- } = _b, props = __objRest(_b, [
3433
- "className"
3434
- ]);
3435
- return /* @__PURE__ */ jsx53(
3436
- "span",
3437
- __spreadValues({
3438
- className: cn(
3439
- "ml-auto text-xs tracking-widest text-muted-foreground",
3440
- className
3441
- )
3442
- }, props)
3443
- );
3444
- };
3445
- MenubarShortcut.displayName = "MenubarShortcut";
3446
-
3447
- // src/ui/navigation-menu.tsx
3448
- import * as React52 from "react";
3449
- import * as NavigationMenuPrimitive from "@radix-ui/react-navigation-menu";
3450
- import { cva as cva5 } from "class-variance-authority";
3451
- import { jsx as jsx54, jsxs as jsxs20 } from "react/jsx-runtime";
3452
- var NavigationMenu = React52.forwardRef((_a, ref) => {
3453
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3454
- return /* @__PURE__ */ jsxs20(
3455
- NavigationMenuPrimitive.Root,
3456
- __spreadProps(__spreadValues({
3457
- ref,
3458
- className: cn(
3459
- "relative z-10 flex max-w-max flex-1 items-center justify-center",
3460
- className
3461
- )
3462
- }, props), {
3463
- children: [
3464
- children,
3465
- /* @__PURE__ */ jsx54(NavigationMenuViewport, {})
3466
- ]
3467
- })
3468
- );
3469
- });
3470
- NavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;
3471
- var NavigationMenuList = React52.forwardRef((_a, ref) => {
3472
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3473
- return /* @__PURE__ */ jsx54(
3474
- NavigationMenuPrimitive.List,
3475
- __spreadValues({
3476
- ref,
3477
- className: cn(
3478
- "group flex flex-1 list-none items-center justify-center space-x-1",
3479
- className
3480
- )
3481
- }, props)
3482
- );
3483
- });
3484
- NavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;
3485
- var NavigationMenuItem = NavigationMenuPrimitive.Item;
3486
- var navigationMenuTriggerStyle = cva5(
3487
- "group inline-flex h-10 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-hidden disabled:pointer-events-none disabled:opacity-50 data-active:bg-accent/50 data-[state=open]:bg-accent/50"
3488
- );
3489
- var NavigationMenuTrigger = React52.forwardRef((_a, ref) => {
3490
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3491
- return /* @__PURE__ */ jsxs20(
3492
- NavigationMenuPrimitive.Trigger,
3493
- __spreadProps(__spreadValues({
3494
- ref,
3495
- className: cn(navigationMenuTriggerStyle(), "group", className)
3496
- }, props), {
3497
- children: [
3498
- children,
3499
- " ",
3500
- /* @__PURE__ */ jsx54(
3501
- globalLucideIcons.ChevronDown,
3502
- {
3503
- className: "relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180",
3504
- "aria-hidden": "true"
3505
- }
3506
- )
3507
- ]
3508
- })
3509
- );
3510
- });
3511
- NavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;
3512
- var NavigationMenuContent = React52.forwardRef((_a, ref) => {
3513
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3514
- return /* @__PURE__ */ jsx54(
3515
- NavigationMenuPrimitive.Content,
3516
- __spreadValues({
3517
- ref,
3518
- className: cn(
3519
- "left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto ",
3520
- className
3521
- )
3522
- }, props)
3523
- );
3524
- });
3525
- NavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;
3526
- var NavigationMenuLink = NavigationMenuPrimitive.Link;
3527
- var NavigationMenuViewport = React52.forwardRef((_a, ref) => {
3528
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3529
- return /* @__PURE__ */ jsx54("div", { className: cn("absolute left-0 top-full flex justify-center"), children: /* @__PURE__ */ jsx54(
3530
- NavigationMenuPrimitive.Viewport,
3531
- __spreadValues({
3532
- className: cn(
3533
- "origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",
3534
- className
3535
- ),
3536
- ref
3537
- }, props)
3538
- ) });
3539
- });
3540
- NavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;
3541
- var NavigationMenuIndicator = React52.forwardRef((_a, ref) => {
3542
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3543
- return /* @__PURE__ */ jsx54(
3544
- NavigationMenuPrimitive.Indicator,
3545
- __spreadProps(__spreadValues({
3546
- ref,
3547
- className: cn(
3548
- "top-full z-1 flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",
3549
- className
3550
- )
3551
- }, props), {
3552
- children: /* @__PURE__ */ jsx54("div", { className: "relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md" })
3553
- })
3554
- );
3555
- });
3556
- NavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;
3557
-
3558
- // src/ui/pagination.tsx
3559
- import * as React53 from "react";
3560
- import { jsx as jsx55, jsxs as jsxs21 } from "react/jsx-runtime";
3561
- var Pagination = (_a) => {
3562
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3563
- return /* @__PURE__ */ jsx55(
3564
- "nav",
3565
- __spreadValues({
3566
- role: "navigation",
3567
- "aria-label": "pagination",
3568
- className: cn("mx-auto flex w-full justify-center", className)
3569
- }, props)
3570
- );
3571
- };
3572
- Pagination.displayName = "Pagination";
3573
- var PaginationContent = React53.forwardRef((_a, ref) => {
3574
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3575
- return /* @__PURE__ */ jsx55(
3576
- "ul",
3577
- __spreadValues({
3578
- ref,
3579
- className: cn("flex flex-row items-center gap-1", className)
3580
- }, props)
3581
- );
3582
- });
3583
- PaginationContent.displayName = "PaginationContent";
3584
- var PaginationItem = React53.forwardRef((_a, ref) => {
3585
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3586
- return /* @__PURE__ */ jsx55("li", __spreadValues({ ref, className: cn("", className) }, props));
3587
- });
3588
- PaginationItem.displayName = "PaginationItem";
3589
- var PaginationLink = (_a) => {
3590
- var _b = _a, {
3591
- className,
3592
- isActive,
3593
- size = "icon"
3594
- } = _b, props = __objRest(_b, [
3595
- "className",
3596
- "isActive",
3597
- "size"
3598
- ]);
3599
- return /* @__PURE__ */ jsx55(
3600
- "a",
3601
- __spreadValues({
3602
- "aria-current": isActive ? "page" : void 0,
3603
- className: cn(
3604
- buttonVariants({
3605
- variant: isActive ? "outline" : "ghost",
3606
- size
3607
- }),
3608
- className
3609
- )
3610
- }, props)
3611
- );
3612
- };
3613
- PaginationLink.displayName = "PaginationLink";
3614
- var PaginationPrevious = (_a) => {
3615
- var _b = _a, {
3616
- className
3617
- } = _b, props = __objRest(_b, [
3618
- "className"
3619
- ]);
3620
- return /* @__PURE__ */ jsxs21(
3621
- PaginationLink,
3622
- __spreadProps(__spreadValues({
3623
- "aria-label": "Go to previous page",
3624
- size: "default",
3625
- className: cn("gap-1 pl-2.5", className)
3626
- }, props), {
3627
- children: [
3628
- /* @__PURE__ */ jsx55(globalLucideIcons.ChevronLeft, { className: "h-4 w-4" }),
3629
- /* @__PURE__ */ jsx55("span", { children: "Previous" })
3630
- ]
3631
- })
3632
- );
3633
- };
3634
- PaginationPrevious.displayName = "PaginationPrevious";
3635
- var PaginationNext = (_a) => {
3636
- var _b = _a, {
3637
- className
3638
- } = _b, props = __objRest(_b, [
3639
- "className"
3640
- ]);
3641
- return /* @__PURE__ */ jsxs21(
3642
- PaginationLink,
3643
- __spreadProps(__spreadValues({
3644
- "aria-label": "Go to next page",
3645
- size: "default",
3646
- className: cn("gap-1 pr-2.5", className)
3647
- }, props), {
3648
- children: [
3649
- /* @__PURE__ */ jsx55("span", { children: "Next" }),
3650
- /* @__PURE__ */ jsx55(globalLucideIcons.ChevronRight, { className: "h-4 w-4" })
3651
- ]
3652
- })
3653
- );
3654
- };
3655
- PaginationNext.displayName = "PaginationNext";
3656
- var PaginationEllipsis = (_a) => {
3657
- var _b = _a, {
3658
- className
3659
- } = _b, props = __objRest(_b, [
3660
- "className"
3661
- ]);
3662
- return /* @__PURE__ */ jsxs21(
3663
- "span",
3664
- __spreadProps(__spreadValues({
3665
- "aria-hidden": true,
3666
- className: cn("flex h-9 w-9 items-center justify-center", className)
3667
- }, props), {
3668
- children: [
3669
- /* @__PURE__ */ jsx55(globalLucideIcons.MoreHorizontal, { className: "h-4 w-4" }),
3670
- /* @__PURE__ */ jsx55("span", { className: "sr-only", children: "More pages" })
3671
- ]
3672
- })
3673
- );
3674
- };
3675
- PaginationEllipsis.displayName = "PaginationEllipsis";
3676
-
3677
- // src/ui/popover.tsx
3678
- import * as React54 from "react";
3679
- import * as PopoverPrimitive from "@radix-ui/react-popover";
3680
- import { jsx as jsx56 } from "react/jsx-runtime";
3681
- var Popover = PopoverPrimitive.Root;
3682
- var PopoverTrigger = PopoverPrimitive.Trigger;
3683
- var PopoverContent = React54.forwardRef((_a, ref) => {
3684
- var _b = _a, { className, align = "center", sideOffset = 4 } = _b, props = __objRest(_b, ["className", "align", "sideOffset"]);
3685
- return /* @__PURE__ */ jsx56(PopoverPrimitive.Portal, { children: /* @__PURE__ */ jsx56(
3686
- PopoverPrimitive.Content,
3687
- __spreadValues({
3688
- ref,
3689
- align,
3690
- sideOffset,
3691
- className: cn(
3692
- "z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-hidden 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",
3693
- className
3694
- )
3695
- }, props)
3696
- ) });
3697
- });
3698
- PopoverContent.displayName = PopoverPrimitive.Content.displayName;
3699
-
3700
- // src/ui/progress.tsx
3701
- import * as React55 from "react";
3702
- import * as ProgressPrimitive from "@radix-ui/react-progress";
3703
- import { jsx as jsx57 } from "react/jsx-runtime";
3704
- var Progress = React55.forwardRef((_a, ref) => {
3705
- var _b = _a, { className, value } = _b, props = __objRest(_b, ["className", "value"]);
3706
- return /* @__PURE__ */ jsx57(
3707
- ProgressPrimitive.Root,
3708
- __spreadProps(__spreadValues({
3709
- ref,
3710
- className: cn(
3711
- "relative h-4 w-full overflow-hidden rounded-full bg-secondary",
3712
- className
3713
- )
3714
- }, props), {
3715
- children: /* @__PURE__ */ jsx57(
3716
- ProgressPrimitive.Indicator,
3717
- {
3718
- className: "h-full w-full flex-1 bg-primary transition-all",
3719
- style: { transform: `translateX(-${100 - (value || 0)}%)` }
3720
- }
3721
- )
3722
- })
3723
- );
3724
- });
3725
- Progress.displayName = ProgressPrimitive.Root.displayName;
3726
-
3727
- // src/ui/radio-group.tsx
3728
- import * as React56 from "react";
3729
- import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
3730
- import { jsx as jsx58 } from "react/jsx-runtime";
3731
- var RadioGroup4 = React56.forwardRef((_a, ref) => {
3732
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3733
- return /* @__PURE__ */ jsx58(
3734
- RadioGroupPrimitive.Root,
3735
- __spreadProps(__spreadValues({
3736
- className: cn("grid gap-2", className)
3737
- }, props), {
3738
- ref
3739
- })
3740
- );
3741
- });
3742
- RadioGroup4.displayName = RadioGroupPrimitive.Root.displayName;
3743
- var RadioGroupItem = React56.forwardRef((_a, ref) => {
3744
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3745
- return /* @__PURE__ */ jsx58(
3746
- RadioGroupPrimitive.Item,
3747
- __spreadProps(__spreadValues({
3748
- ref,
3749
- className: cn(
3750
- "aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
3751
- className
3752
- )
3753
- }, props), {
3754
- children: /* @__PURE__ */ jsx58(RadioGroupPrimitive.Indicator, { className: "flex items-center justify-center", children: /* @__PURE__ */ jsx58(globalLucideIcons.Circle, { className: "h-2.5 w-2.5 fill-current text-current" }) })
3755
- })
3756
- );
3757
- });
3758
- RadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;
3759
-
3760
- // src/ui/resizable.tsx
3761
- import * as ResizablePrimitive from "react-resizable-panels";
3762
- import { jsx as jsx59 } from "react/jsx-runtime";
3763
- var ResizablePanelGroup = (_a) => {
3764
- var _b = _a, {
3765
- className
3766
- } = _b, props = __objRest(_b, [
3767
- "className"
3768
- ]);
3769
- return /* @__PURE__ */ jsx59(
3770
- ResizablePrimitive.PanelGroup,
3771
- __spreadValues({
3772
- className: cn(
3773
- "flex h-full w-full data-[panel-group-direction=vertical]:flex-col",
3774
- className
3775
- )
3776
- }, props)
3777
- );
3778
- };
3779
- var ResizablePanel = ResizablePrimitive.Panel;
3780
- var ResizableHandle = (_a) => {
3781
- var _b = _a, {
3782
- withHandle,
3783
- className
3784
- } = _b, props = __objRest(_b, [
3785
- "withHandle",
3786
- "className"
3787
- ]);
3788
- return /* @__PURE__ */ jsx59(
3789
- ResizablePrimitive.PanelResizeHandle,
3790
- __spreadProps(__spreadValues({
3791
- className: cn(
3792
- "relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 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-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",
3793
- className
3794
- )
3795
- }, props), {
3796
- children: withHandle && /* @__PURE__ */ jsx59("div", { className: "z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border", children: /* @__PURE__ */ jsx59(globalLucideIcons.GripVertical, { className: "h-2.5 w-2.5" }) })
3797
- })
3798
- );
3799
- };
3800
-
3801
- // src/ui/scroll-area.tsx
3802
- import * as React57 from "react";
3803
- import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
3804
- import { jsx as jsx60, jsxs as jsxs22 } from "react/jsx-runtime";
3805
- var ScrollArea = React57.forwardRef((_a, ref) => {
3806
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3807
- return /* @__PURE__ */ jsxs22(
3808
- ScrollAreaPrimitive.Root,
3809
- __spreadProps(__spreadValues({
3810
- ref,
3811
- className: cn("relative overflow-hidden", className)
3812
- }, props), {
3813
- children: [
3814
- /* @__PURE__ */ jsx60(ScrollAreaPrimitive.Viewport, { className: "h-full w-full rounded-[inherit]", children }),
3815
- /* @__PURE__ */ jsx60(ScrollBar, {}),
3816
- /* @__PURE__ */ jsx60(ScrollAreaPrimitive.Corner, {})
3817
- ]
3818
- })
3819
- );
3820
- });
3821
- ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
3822
- var ScrollBar = React57.forwardRef((_a, ref) => {
3823
- var _b = _a, { className, orientation = "vertical" } = _b, props = __objRest(_b, ["className", "orientation"]);
3824
- return /* @__PURE__ */ jsx60(
3825
- ScrollAreaPrimitive.ScrollAreaScrollbar,
3826
- __spreadProps(__spreadValues({
3827
- ref,
3828
- orientation,
3829
- className: cn(
3830
- "flex touch-none select-none transition-colors",
3831
- orientation === "vertical" && "h-full w-2.5 border-l border-l-transparent p-[1px]",
3832
- orientation === "horizontal" && "h-2.5 flex-col border-t border-t-transparent p-[1px]",
3833
- className
3834
- )
3835
- }, props), {
3836
- children: /* @__PURE__ */ jsx60(ScrollAreaPrimitive.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
3837
- })
3838
- );
3839
- });
3840
- ScrollBar.displayName = ScrollAreaPrimitive.ScrollAreaScrollbar.displayName;
3841
-
3842
- // src/ui/select.tsx
3843
- import * as React58 from "react";
3844
- import * as SelectPrimitive from "@radix-ui/react-select";
3845
- import { jsx as jsx61, jsxs as jsxs23 } from "react/jsx-runtime";
3846
- var Select = SelectPrimitive.Root;
3847
- var SelectGroup = SelectPrimitive.Group;
3848
- var SelectValue = SelectPrimitive.Value;
3849
- var SelectTrigger = React58.forwardRef((_a, ref) => {
3850
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3851
- return /* @__PURE__ */ jsxs23(
3852
- SelectPrimitive.Trigger,
3853
- __spreadProps(__spreadValues({
3854
- ref,
3855
- className: cn(
3856
- "flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",
3857
- className
3858
- )
3859
- }, props), {
3860
- children: [
3861
- children,
3862
- /* @__PURE__ */ jsx61(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx61(globalLucideIcons.ChevronDown, { className: "h-4 w-4 opacity-50" }) })
3863
- ]
3864
- })
3865
- );
3866
- });
3867
- SelectTrigger.displayName = SelectPrimitive.Trigger.displayName;
3868
- var SelectScrollUpButton = React58.forwardRef((_a, ref) => {
3869
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3870
- return /* @__PURE__ */ jsx61(
3871
- SelectPrimitive.ScrollUpButton,
3872
- __spreadProps(__spreadValues({
3873
- ref,
3874
- className: cn(
3875
- "flex cursor-default items-center justify-center py-1",
3876
- className
3877
- )
3878
- }, props), {
3879
- children: /* @__PURE__ */ jsx61(globalLucideIcons.ChevronUp, { className: "h-4 w-4" })
3880
- })
3881
- );
3882
- });
3883
- SelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;
3884
- var SelectScrollDownButton = React58.forwardRef((_a, ref) => {
3885
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3886
- return /* @__PURE__ */ jsx61(
3887
- SelectPrimitive.ScrollDownButton,
3888
- __spreadProps(__spreadValues({
3889
- ref,
3890
- className: cn(
3891
- "flex cursor-default items-center justify-center py-1",
3892
- className
3893
- )
3894
- }, props), {
3895
- children: /* @__PURE__ */ jsx61(globalLucideIcons.ChevronDown, { className: "h-4 w-4" })
3896
- })
3897
- );
3898
- });
3899
- SelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;
3900
- var SelectContent = React58.forwardRef((_a, ref) => {
3901
- var _b = _a, { className, children, position = "popper" } = _b, props = __objRest(_b, ["className", "children", "position"]);
3902
- return /* @__PURE__ */ jsx61(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs23(
3903
- SelectPrimitive.Content,
3904
- __spreadProps(__spreadValues({
3905
- ref,
3906
- className: cn(
3907
- "relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md 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",
3908
- position === "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",
3909
- className
3910
- ),
3911
- position
3912
- }, props), {
3913
- children: [
3914
- /* @__PURE__ */ jsx61(SelectScrollUpButton, {}),
3915
- /* @__PURE__ */ jsx61(
3916
- SelectPrimitive.Viewport,
3917
- {
3918
- className: cn(
3919
- "p-1",
3920
- position === "popper" && "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"
3921
- ),
3922
- children
3923
- }
3924
- ),
3925
- /* @__PURE__ */ jsx61(SelectScrollDownButton, {})
3926
- ]
3927
- })
3928
- ) });
3929
- });
3930
- SelectContent.displayName = SelectPrimitive.Content.displayName;
3931
- var SelectLabel = React58.forwardRef((_a, ref) => {
3932
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3933
- return /* @__PURE__ */ jsx61(
3934
- SelectPrimitive.Label,
3935
- __spreadValues({
3936
- ref,
3937
- className: cn("py-1.5 pl-8 pr-2 text-sm font-semibold", className)
3938
- }, props)
3939
- );
3940
- });
3941
- SelectLabel.displayName = SelectPrimitive.Label.displayName;
3942
- var SelectItem = React58.forwardRef((_a, ref) => {
3943
- var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
3944
- return /* @__PURE__ */ jsxs23(
3945
- SelectPrimitive.Item,
3946
- __spreadProps(__spreadValues({
3947
- ref,
3948
- className: cn(
3949
- "relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50",
3950
- className
3951
- )
3952
- }, props), {
3953
- children: [
3954
- /* @__PURE__ */ jsx61("span", { className: "absolute left-2 flex h-3.5 w-3.5 items-center justify-center", children: /* @__PURE__ */ jsx61(SelectPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx61(globalLucideIcons.Check, { className: "h-4 w-4" }) }) }),
3955
- /* @__PURE__ */ jsx61(SelectPrimitive.ItemText, { children })
3956
- ]
3957
- })
3958
- );
3959
- });
3960
- SelectItem.displayName = SelectPrimitive.Item.displayName;
3961
- var SelectSeparator = React58.forwardRef((_a, ref) => {
3962
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3963
- return /* @__PURE__ */ jsx61(
3964
- SelectPrimitive.Separator,
3965
- __spreadValues({
3966
- ref,
3967
- className: cn("-mx-1 my-1 h-px bg-muted", className)
3968
- }, props)
3969
- );
3970
- });
3971
- SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
3972
-
3973
- // src/ui/separator.tsx
3974
- import * as React59 from "react";
3975
- import * as SeparatorPrimitive from "@radix-ui/react-separator";
3976
- import { jsx as jsx62 } from "react/jsx-runtime";
3977
- var Separator5 = React59.forwardRef(
3978
- (_a, ref) => {
3979
- var _b = _a, { className, orientation = "horizontal", decorative = true } = _b, props = __objRest(_b, ["className", "orientation", "decorative"]);
3980
- return /* @__PURE__ */ jsx62(
3981
- SeparatorPrimitive.Root,
3982
- __spreadValues({
3983
- ref,
3984
- decorative,
3985
- orientation,
3986
- className: cn(
3987
- "shrink-0 bg-border",
3988
- orientation === "horizontal" ? "h-[1px] w-full" : "h-full w-[1px]",
3989
- className
3990
- )
3991
- }, props)
3992
- );
3993
- }
3994
- );
3995
- Separator5.displayName = SeparatorPrimitive.Root.displayName;
3996
-
3997
- // src/ui/sheet.tsx
3998
- import * as React60 from "react";
3999
- import * as SheetPrimitive from "@radix-ui/react-dialog";
4000
- import { cva as cva6 } from "class-variance-authority";
4001
- import { jsx as jsx63, jsxs as jsxs24 } from "react/jsx-runtime";
4002
- var Sheet = SheetPrimitive.Root;
4003
- var SheetTrigger = SheetPrimitive.Trigger;
4004
- var SheetClose = SheetPrimitive.Close;
4005
- var SheetPortal = SheetPrimitive.Portal;
4006
- var SheetOverlay = React60.forwardRef((_a, ref) => {
4007
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4008
- return /* @__PURE__ */ jsx63(
4009
- SheetPrimitive.Overlay,
4010
- __spreadProps(__spreadValues({
4011
- className: cn(
4012
- "fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
4013
- className
4014
- )
4015
- }, props), {
4016
- ref
4017
- })
4018
- );
4019
- });
4020
- SheetOverlay.displayName = SheetPrimitive.Overlay.displayName;
4021
- var sheetVariants = cva6(
4022
- "fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",
4023
- {
4024
- variants: {
4025
- side: {
4026
- top: "inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",
4027
- bottom: "inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",
4028
- left: "inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",
4029
- right: "inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"
4030
- }
4031
- },
4032
- defaultVariants: {
4033
- side: "right"
4034
- }
4035
- }
4036
- );
4037
- var SheetContent = React60.forwardRef((_a, ref) => {
4038
- var _b = _a, { side = "right", className, children } = _b, props = __objRest(_b, ["side", "className", "children"]);
4039
- return /* @__PURE__ */ jsxs24(SheetPortal, { children: [
4040
- /* @__PURE__ */ jsx63(SheetOverlay, {}),
4041
- /* @__PURE__ */ jsxs24(
4042
- SheetPrimitive.Content,
4043
- __spreadProps(__spreadValues({
4044
- ref,
4045
- className: cn(sheetVariants({ side }), className)
4046
- }, props), {
4047
- children: [
4048
- children,
4049
- /* @__PURE__ */ jsxs24(SheetPrimitive.Close, { className: "absolute right-4 top-4 rounded-sm 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: [
4050
- /* @__PURE__ */ jsx63(globalLucideIcons.X, { className: "h-4 w-4" }),
4051
- /* @__PURE__ */ jsx63("span", { className: "sr-only", children: "Close" })
4052
- ] })
4053
- ]
4054
- })
4055
- )
4056
- ] });
4057
- });
4058
- SheetContent.displayName = SheetPrimitive.Content.displayName;
4059
- var SheetHeader = (_a) => {
4060
- var _b = _a, {
4061
- className
4062
- } = _b, props = __objRest(_b, [
4063
- "className"
4064
- ]);
4065
- return /* @__PURE__ */ jsx63(
4066
- "div",
4067
- __spreadValues({
4068
- className: cn(
4069
- "flex flex-col space-y-2 text-center sm:text-left",
4070
- className
4071
- )
4072
- }, props)
4073
- );
4074
- };
4075
- SheetHeader.displayName = "SheetHeader";
4076
- var SheetFooter = (_a) => {
4077
- var _b = _a, {
4078
- className
4079
- } = _b, props = __objRest(_b, [
4080
- "className"
4081
- ]);
4082
- return /* @__PURE__ */ jsx63(
4083
- "div",
4084
- __spreadValues({
4085
- className: cn(
4086
- "flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
4087
- className
4088
- )
4089
- }, props)
4090
- );
4091
- };
4092
- SheetFooter.displayName = "SheetFooter";
4093
- var SheetTitle = React60.forwardRef((_a, ref) => {
4094
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4095
- return /* @__PURE__ */ jsx63(
4096
- SheetPrimitive.Title,
4097
- __spreadValues({
4098
- ref,
4099
- className: cn("text-lg font-semibold text-foreground", className)
4100
- }, props)
4101
- );
4102
- });
4103
- SheetTitle.displayName = SheetPrimitive.Title.displayName;
4104
- var SheetDescription = React60.forwardRef((_a, ref) => {
4105
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4106
- return /* @__PURE__ */ jsx63(
4107
- SheetPrimitive.Description,
4108
- __spreadValues({
4109
- ref,
4110
- className: cn("text-sm text-muted-foreground", className)
4111
- }, props)
4112
- );
4113
- });
4114
- SheetDescription.displayName = SheetPrimitive.Description.displayName;
4115
-
4116
- // src/ui/sidebar.tsx
4117
- import * as React63 from "react";
4118
- import { Slot as Slot4 } from "@radix-ui/react-slot";
4119
- import { cva as cva7 } from "class-variance-authority";
4120
-
4121
- // src/ui/use-mobile.tsx
4122
- import * as React61 from "react";
4123
- var MOBILE_BREAKPOINT = 768;
4124
- function useIsMobile() {
4125
- const [isMobile, setIsMobile] = React61.useState(void 0);
4126
- React61.useEffect(() => {
4127
- const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);
4128
- const onChange = () => {
4129
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
4130
- };
4131
- mql.addEventListener("change", onChange);
4132
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
4133
- return () => mql.removeEventListener("change", onChange);
4134
- }, []);
4135
- return !!isMobile;
4136
- }
4137
-
4138
- // src/ui/skeleton.tsx
4139
- import { jsx as jsx64 } from "react/jsx-runtime";
4140
- function Skeleton(_a) {
4141
- var _b = _a, {
4142
- className
4143
- } = _b, props = __objRest(_b, [
4144
- "className"
4145
- ]);
4146
- return /* @__PURE__ */ jsx64(
4147
- "div",
4148
- __spreadValues({
4149
- className: cn("animate-pulse rounded-md bg-muted", className)
4150
- }, props)
4151
- );
4152
- }
4153
-
4154
- // src/ui/tooltip.tsx
4155
- import * as React62 from "react";
4156
- import * as TooltipPrimitive from "@radix-ui/react-tooltip";
4157
- import { jsx as jsx65 } from "react/jsx-runtime";
4158
- var TooltipProvider = TooltipPrimitive.Provider;
4159
- var Tooltip2 = TooltipPrimitive.Root;
4160
- var TooltipTrigger = TooltipPrimitive.Trigger;
4161
- var TooltipContent = React62.forwardRef((_a, ref) => {
4162
- var _b = _a, { className, sideOffset = 4 } = _b, props = __objRest(_b, ["className", "sideOffset"]);
4163
- return /* @__PURE__ */ jsx65(
4164
- TooltipPrimitive.Content,
4165
- __spreadValues({
4166
- ref,
4167
- sideOffset,
4168
- className: cn(
4169
- "z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md 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",
4170
- className
4171
- )
4172
- }, props)
4173
- );
4174
- });
4175
- TooltipContent.displayName = TooltipPrimitive.Content.displayName;
4176
-
4177
- // src/ui/sidebar.tsx
4178
- import { jsx as jsx66, jsxs as jsxs25 } from "react/jsx-runtime";
4179
- var SIDEBAR_COOKIE_NAME = "sidebar:state";
4180
- var SIDEBAR_COOKIE_MAX_AGE = 60 * 60 * 24 * 7;
4181
- var SIDEBAR_WIDTH = "16rem";
4182
- var SIDEBAR_WIDTH_MOBILE = "18rem";
4183
- var SIDEBAR_WIDTH_ICON = "3rem";
4184
- var SIDEBAR_KEYBOARD_SHORTCUT = "b";
4185
- var SidebarContext = React63.createContext(null);
4186
- function useSidebar() {
4187
- const context = React63.useContext(SidebarContext);
4188
- if (!context) {
4189
- throw new Error("useSidebar must be used within a SidebarProvider.");
4190
- }
4191
- return context;
4192
- }
4193
- var SidebarProvider = React63.forwardRef(
4194
- (_a, ref) => {
4195
- var _b = _a, {
4196
- defaultOpen = true,
4197
- open: openProp,
4198
- onOpenChange: setOpenProp,
4199
- className,
4200
- style,
4201
- children
4202
- } = _b, props = __objRest(_b, [
4203
- "defaultOpen",
4204
- "open",
4205
- "onOpenChange",
4206
- "className",
4207
- "style",
4208
- "children"
4209
- ]);
4210
- const isMobile = useIsMobile();
4211
- const [openMobile, setOpenMobile] = React63.useState(false);
4212
- const [_open, _setOpen] = React63.useState(defaultOpen);
4213
- const open = openProp != null ? openProp : _open;
4214
- const setOpen = React63.useCallback(
4215
- (value) => {
4216
- const openState = typeof value === "function" ? value(open) : value;
4217
- if (setOpenProp) {
4218
- setOpenProp(openState);
4219
- } else {
4220
- _setOpen(openState);
4221
- }
4222
- document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=${SIDEBAR_COOKIE_MAX_AGE}`;
4223
- },
4224
- [setOpenProp, open]
4225
- );
4226
- const toggleSidebar = React63.useCallback(() => {
4227
- return isMobile ? setOpenMobile((open2) => !open2) : setOpen((open2) => !open2);
4228
- }, [isMobile, setOpen, setOpenMobile]);
4229
- React63.useEffect(() => {
4230
- const handleKeyDown = (event) => {
4231
- if (event.key === SIDEBAR_KEYBOARD_SHORTCUT && (event.metaKey || event.ctrlKey)) {
4232
- event.preventDefault();
4233
- toggleSidebar();
4234
- }
4235
- };
4236
- window.addEventListener("keydown", handleKeyDown);
4237
- return () => window.removeEventListener("keydown", handleKeyDown);
4238
- }, [toggleSidebar]);
4239
- const state = open ? "expanded" : "collapsed";
4240
- const contextValue = React63.useMemo(
4241
- () => ({
4242
- state,
4243
- open,
4244
- setOpen,
4245
- isMobile,
4246
- openMobile,
4247
- setOpenMobile,
4248
- toggleSidebar
4249
- }),
4250
- [state, open, setOpen, isMobile, openMobile, setOpenMobile, toggleSidebar]
4251
- );
4252
- return /* @__PURE__ */ jsx66(SidebarContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx66(TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ jsx66(
4253
- "div",
4254
- __spreadProps(__spreadValues({
4255
- style: __spreadValues({
4256
- "--sidebar-width": SIDEBAR_WIDTH,
4257
- "--sidebar-width-icon": SIDEBAR_WIDTH_ICON
4258
- }, style),
4259
- className: cn(
4260
- "group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar",
4261
- className
4262
- ),
4263
- ref
4264
- }, props), {
4265
- children
4266
- })
4267
- ) }) });
4268
- }
4269
- );
4270
- SidebarProvider.displayName = "SidebarProvider";
4271
- var Sidebar = React63.forwardRef(
4272
- (_a, ref) => {
4273
- var _b = _a, {
4274
- side = "left",
4275
- variant = "sidebar",
4276
- collapsible = "offcanvas",
4277
- className,
4278
- children
4279
- } = _b, props = __objRest(_b, [
4280
- "side",
4281
- "variant",
4282
- "collapsible",
4283
- "className",
4284
- "children"
4285
- ]);
4286
- const { isMobile, state, openMobile, setOpenMobile } = useSidebar();
4287
- if (collapsible === "none") {
4288
- return /* @__PURE__ */ jsx66(
4289
- "div",
4290
- __spreadProps(__spreadValues({
4291
- className: cn(
4292
- "flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground",
4293
- className
4294
- ),
4295
- ref
4296
- }, props), {
4297
- children
4298
- })
4299
- );
4300
- }
4301
- if (isMobile) {
4302
- return /* @__PURE__ */ jsx66(Sheet, __spreadProps(__spreadValues({ open: openMobile, onOpenChange: setOpenMobile }, props), { children: /* @__PURE__ */ jsx66(
4303
- SheetContent,
4304
- {
4305
- "data-sidebar": "sidebar",
4306
- "data-mobile": "true",
4307
- className: "w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",
4308
- style: {
4309
- "--sidebar-width": SIDEBAR_WIDTH_MOBILE
4310
- },
4311
- side,
4312
- children: /* @__PURE__ */ jsx66("div", { className: "flex h-full w-full flex-col", children })
4313
- }
4314
- ) }));
4315
- }
4316
- return /* @__PURE__ */ jsxs25(
4317
- "div",
4318
- {
4319
- ref,
4320
- className: "group peer hidden md:block text-sidebar-foreground",
4321
- "data-state": state,
4322
- "data-collapsible": state === "collapsed" ? collapsible : "",
4323
- "data-variant": variant,
4324
- "data-side": side,
4325
- children: [
4326
- /* @__PURE__ */ jsx66(
4327
- "div",
4328
- {
4329
- className: cn(
4330
- "duration-200 relative h-svh w-(--sidebar-width) bg-transparent transition-[width] ease-linear",
4331
- "group-data-[collapsible=offcanvas]:w-0",
4332
- "group-data-[side=right]:rotate-180",
4333
- variant === "floating" || variant === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]" : "group-data-[collapsible=icon]:w-(--sidebar-width-icon)"
4334
- )
4335
- }
4336
- ),
4337
- /* @__PURE__ */ jsx66(
4338
- "div",
4339
- __spreadProps(__spreadValues({
4340
- className: cn(
4341
- "duration-200 fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] ease-linear md:flex",
4342
- side === "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)]",
4343
- // Adjust the padding for floating and inset variants.
4344
- variant === "floating" || variant === "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",
4345
- className
4346
- )
4347
- }, props), {
4348
- children: /* @__PURE__ */ jsx66(
4349
- "div",
4350
- {
4351
- "data-sidebar": "sidebar",
4352
- className: "flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow-sm",
4353
- children
4354
- }
4355
- )
4356
- })
4357
- )
4358
- ]
4359
- }
4360
- );
4361
- }
4362
- );
4363
- Sidebar.displayName = "Sidebar";
4364
- var SidebarTrigger = React63.forwardRef((_a, ref) => {
4365
- var _b = _a, { className, onClick } = _b, props = __objRest(_b, ["className", "onClick"]);
4366
- const { toggleSidebar } = useSidebar();
4367
- return /* @__PURE__ */ jsxs25(
4368
- Button,
4369
- __spreadProps(__spreadValues({
4370
- ref,
4371
- "data-sidebar": "trigger",
4372
- variant: "ghost",
4373
- size: "icon",
4374
- className: cn("h-7 w-7", className),
4375
- onClick: (event) => {
4376
- onClick == null ? void 0 : onClick(event);
4377
- toggleSidebar();
4378
- }
4379
- }, props), {
4380
- children: [
4381
- /* @__PURE__ */ jsx66(globalLucideIcons.PanelLeft, {}),
4382
- /* @__PURE__ */ jsx66("span", { className: "sr-only", children: "Toggle Sidebar" })
4383
- ]
4384
- })
4385
- );
4386
- });
4387
- SidebarTrigger.displayName = "SidebarTrigger";
4388
- var SidebarRail = React63.forwardRef((_a, ref) => {
4389
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4390
- const { toggleSidebar } = useSidebar();
4391
- return /* @__PURE__ */ jsx66(
4392
- "button",
4393
- __spreadValues({
4394
- ref,
4395
- "data-sidebar": "rail",
4396
- "aria-label": "Toggle Sidebar",
4397
- tabIndex: -1,
4398
- onClick: toggleSidebar,
4399
- title: "Toggle Sidebar",
4400
- className: cn(
4401
- "absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex",
4402
- "in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize",
4403
- "[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize",
4404
- "group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full hover:group-data-[collapsible=offcanvas]:bg-sidebar",
4405
- "[[data-side=left][data-collapsible=offcanvas]_&]:-right-2",
4406
- "[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",
4407
- className
4408
- )
4409
- }, props)
4410
- );
4411
- });
4412
- SidebarRail.displayName = "SidebarRail";
4413
- var SidebarInset = React63.forwardRef((_a, ref) => {
4414
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4415
- return /* @__PURE__ */ jsx66(
4416
- "main",
4417
- __spreadValues({
4418
- ref,
4419
- className: cn(
4420
- "relative flex min-h-svh flex-1 flex-col bg-background",
4421
- "peer-data-[variant=inset]:min-h-[calc(100svh-(--spacing(4)))] md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm",
4422
- className
4423
- )
4424
- }, props)
4425
- );
4426
- });
4427
- SidebarInset.displayName = "SidebarInset";
4428
- var SidebarInput = React63.forwardRef((_a, ref) => {
4429
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4430
- return /* @__PURE__ */ jsx66(
4431
- Input,
4432
- __spreadValues({
4433
- ref,
4434
- "data-sidebar": "input",
4435
- className: cn(
4436
- "h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",
4437
- className
4438
- )
4439
- }, props)
4440
- );
4441
- });
4442
- SidebarInput.displayName = "SidebarInput";
4443
- var SidebarHeader = React63.forwardRef((_a, ref) => {
4444
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4445
- return /* @__PURE__ */ jsx66(
4446
- "div",
4447
- __spreadValues({
4448
- ref,
4449
- "data-sidebar": "header",
4450
- className: cn("flex flex-col gap-2 p-2", className)
4451
- }, props)
4452
- );
4453
- });
4454
- SidebarHeader.displayName = "SidebarHeader";
4455
- var SidebarFooter = React63.forwardRef((_a, ref) => {
4456
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4457
- return /* @__PURE__ */ jsx66(
4458
- "div",
4459
- __spreadValues({
4460
- ref,
4461
- "data-sidebar": "footer",
4462
- className: cn("flex flex-col gap-2 p-2", className)
4463
- }, props)
4464
- );
4465
- });
4466
- SidebarFooter.displayName = "SidebarFooter";
4467
- var SidebarSeparator = React63.forwardRef((_a, ref) => {
4468
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4469
- return /* @__PURE__ */ jsx66(
4470
- Separator5,
4471
- __spreadValues({
4472
- ref,
4473
- "data-sidebar": "separator",
4474
- className: cn("mx-2 w-auto bg-sidebar-border", className)
4475
- }, props)
4476
- );
4477
- });
4478
- SidebarSeparator.displayName = "SidebarSeparator";
4479
- var SidebarContent = React63.forwardRef((_a, ref) => {
4480
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4481
- return /* @__PURE__ */ jsx66(
4482
- "div",
4483
- __spreadValues({
4484
- ref,
4485
- "data-sidebar": "content",
4486
- className: cn(
4487
- "flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",
4488
- className
4489
- )
4490
- }, props)
4491
- );
4492
- });
4493
- SidebarContent.displayName = "SidebarContent";
4494
- var SidebarGroup = React63.forwardRef((_a, ref) => {
4495
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4496
- return /* @__PURE__ */ jsx66(
4497
- "div",
4498
- __spreadValues({
4499
- ref,
4500
- "data-sidebar": "group",
4501
- className: cn("relative flex w-full min-w-0 flex-col p-2", className)
4502
- }, props)
4503
- );
4504
- });
4505
- SidebarGroup.displayName = "SidebarGroup";
4506
- var SidebarGroupLabel = React63.forwardRef((_a, ref) => {
4507
- var _b = _a, { className, asChild = false } = _b, props = __objRest(_b, ["className", "asChild"]);
4508
- const Comp = asChild ? Slot4 : "div";
4509
- return /* @__PURE__ */ jsx66(
4510
- Comp,
4511
- __spreadValues({
4512
- ref,
4513
- "data-sidebar": "group-label",
4514
- className: cn(
4515
- "duration-200 flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-hidden ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
4516
- "group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",
4517
- className
4518
- )
4519
- }, props)
4520
- );
4521
- });
4522
- SidebarGroupLabel.displayName = "SidebarGroupLabel";
4523
- var SidebarGroupAction = React63.forwardRef((_a, ref) => {
4524
- var _b = _a, { className, asChild = false } = _b, props = __objRest(_b, ["className", "asChild"]);
4525
- const Comp = asChild ? Slot4 : "button";
4526
- return /* @__PURE__ */ jsx66(
4527
- Comp,
4528
- __spreadValues({
4529
- ref,
4530
- "data-sidebar": "group-action",
4531
- className: cn(
4532
- "absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0",
4533
- // Increases the hit area of the button on mobile.
4534
- "after:absolute after:-inset-2 md:after:hidden",
4535
- "group-data-[collapsible=icon]:hidden",
4536
- className
4537
- )
4538
- }, props)
4539
- );
4540
- });
4541
- SidebarGroupAction.displayName = "SidebarGroupAction";
4542
- var SidebarGroupContent = React63.forwardRef((_a, ref) => {
4543
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4544
- return /* @__PURE__ */ jsx66(
4545
- "div",
4546
- __spreadValues({
4547
- ref,
4548
- "data-sidebar": "group-content",
4549
- className: cn("w-full text-sm", className)
4550
- }, props)
4551
- );
4552
- });
4553
- SidebarGroupContent.displayName = "SidebarGroupContent";
4554
- var SidebarMenu = React63.forwardRef((_a, ref) => {
4555
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4556
- return /* @__PURE__ */ jsx66(
4557
- "ul",
4558
- __spreadValues({
4559
- ref,
4560
- "data-sidebar": "menu",
4561
- className: cn("flex w-full min-w-0 flex-col gap-1", className)
4562
- }, props)
4563
- );
4564
- });
4565
- SidebarMenu.displayName = "SidebarMenu";
4566
- var SidebarMenuItem = React63.forwardRef((_a, ref) => {
4567
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4568
- return /* @__PURE__ */ jsx66(
4569
- "li",
4570
- __spreadValues({
4571
- ref,
4572
- "data-sidebar": "menu-item",
4573
- className: cn("group/menu-item relative", className)
4574
- }, props)
4575
- );
4576
- });
4577
- SidebarMenuItem.displayName = "SidebarMenuItem";
4578
- var sidebarMenuButtonVariants = cva7(
4579
- "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",
4580
- {
4581
- variants: {
4582
- variant: {
4583
- default: "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",
4584
- outline: "bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"
4585
- },
4586
- size: {
4587
- default: "h-8 text-sm",
4588
- sm: "h-7 text-xs",
4589
- lg: "h-12 text-sm group-data-[collapsible=icon]:p-0!"
4590
- }
4591
- },
4592
- defaultVariants: {
4593
- variant: "default",
4594
- size: "default"
4595
- }
4596
- }
4597
- );
4598
- var SidebarMenuButton = React63.forwardRef(
4599
- (_a, ref) => {
4600
- var _b = _a, {
4601
- asChild = false,
4602
- isActive = false,
4603
- variant = "default",
4604
- size = "default",
4605
- tooltip,
4606
- className
4607
- } = _b, props = __objRest(_b, [
4608
- "asChild",
4609
- "isActive",
4610
- "variant",
4611
- "size",
4612
- "tooltip",
4613
- "className"
4614
- ]);
4615
- const Comp = asChild ? Slot4 : "button";
4616
- const { isMobile, state } = useSidebar();
4617
- const button = /* @__PURE__ */ jsx66(
4618
- Comp,
4619
- __spreadValues({
4620
- ref,
4621
- "data-sidebar": "menu-button",
4622
- "data-size": size,
4623
- "data-active": isActive,
4624
- className: cn(sidebarMenuButtonVariants({ variant, size }), className)
4625
- }, props)
4626
- );
4627
- if (!tooltip) {
4628
- return button;
4629
- }
4630
- if (typeof tooltip === "string") {
4631
- tooltip = {
4632
- children: tooltip
4633
- };
4634
- }
4635
- return /* @__PURE__ */ jsxs25(Tooltip2, { children: [
4636
- /* @__PURE__ */ jsx66(TooltipTrigger, { asChild: true, children: button }),
4637
- /* @__PURE__ */ jsx66(
4638
- TooltipContent,
4639
- __spreadValues({
4640
- side: "right",
4641
- align: "center",
4642
- hidden: state !== "collapsed" || isMobile
4643
- }, tooltip)
4644
- )
4645
- ] });
4646
- }
4647
- );
4648
- SidebarMenuButton.displayName = "SidebarMenuButton";
4649
- var SidebarMenuAction = React63.forwardRef((_a, ref) => {
4650
- var _b = _a, { className, asChild = false, showOnHover = false } = _b, props = __objRest(_b, ["className", "asChild", "showOnHover"]);
4651
- const Comp = asChild ? Slot4 : "button";
4652
- return /* @__PURE__ */ jsx66(
4653
- Comp,
4654
- __spreadValues({
4655
- ref,
4656
- "data-sidebar": "menu-action",
4657
- className: cn(
4658
- "absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0",
4659
- // Increases the hit area of the button on mobile.
4660
- "after:absolute after:-inset-2 md:after:hidden",
4661
- "peer-data-[size=sm]/menu-button:top-1",
4662
- "peer-data-[size=default]/menu-button:top-1.5",
4663
- "peer-data-[size=lg]/menu-button:top-2.5",
4664
- "group-data-[collapsible=icon]:hidden",
4665
- showOnHover && "group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",
4666
- className
4667
- )
4668
- }, props)
4669
- );
4670
- });
4671
- SidebarMenuAction.displayName = "SidebarMenuAction";
4672
- var SidebarMenuBadge = React63.forwardRef((_a, ref) => {
4673
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4674
- return /* @__PURE__ */ jsx66(
4675
- "div",
4676
- __spreadValues({
4677
- ref,
4678
- "data-sidebar": "menu-badge",
4679
- className: cn(
4680
- "absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground select-none pointer-events-none",
4681
- "peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground",
4682
- "peer-data-[size=sm]/menu-button:top-1",
4683
- "peer-data-[size=default]/menu-button:top-1.5",
4684
- "peer-data-[size=lg]/menu-button:top-2.5",
4685
- "group-data-[collapsible=icon]:hidden",
4686
- className
4687
- )
4688
- }, props)
4689
- );
4690
- });
4691
- SidebarMenuBadge.displayName = "SidebarMenuBadge";
4692
- var SidebarMenuSkeleton = React63.forwardRef((_a, ref) => {
4693
- var _b = _a, { className, showIcon = false } = _b, props = __objRest(_b, ["className", "showIcon"]);
4694
- const width = React63.useMemo(() => {
4695
- return `${Math.floor(Math.random() * 40) + 50}%`;
4696
- }, []);
4697
- return /* @__PURE__ */ jsxs25(
4698
- "div",
4699
- __spreadProps(__spreadValues({
4700
- ref,
4701
- "data-sidebar": "menu-skeleton",
4702
- className: cn("rounded-md h-8 flex gap-2 px-2 items-center", className)
4703
- }, props), {
4704
- children: [
4705
- showIcon && /* @__PURE__ */ jsx66(
4706
- Skeleton,
4707
- {
4708
- className: "size-4 rounded-md",
4709
- "data-sidebar": "menu-skeleton-icon"
4710
- }
4711
- ),
4712
- /* @__PURE__ */ jsx66(
4713
- Skeleton,
4714
- {
4715
- className: "h-4 flex-1 max-w-(--skeleton-width)",
4716
- "data-sidebar": "menu-skeleton-text",
4717
- style: {
4718
- "--skeleton-width": width
4719
- }
4720
- }
4721
- )
4722
- ]
4723
- })
4724
- );
4725
- });
4726
- SidebarMenuSkeleton.displayName = "SidebarMenuSkeleton";
4727
- var SidebarMenuSub = React63.forwardRef((_a, ref) => {
4728
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4729
- return /* @__PURE__ */ jsx66(
4730
- "ul",
4731
- __spreadValues({
4732
- ref,
4733
- "data-sidebar": "menu-sub",
4734
- className: cn(
4735
- "mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5",
4736
- "group-data-[collapsible=icon]:hidden",
4737
- className
4738
- )
4739
- }, props)
4740
- );
4741
- });
4742
- SidebarMenuSub.displayName = "SidebarMenuSub";
4743
- var SidebarMenuSubItem = React63.forwardRef((_a, ref) => {
4744
- var props = __objRest(_a, []);
4745
- return /* @__PURE__ */ jsx66("li", __spreadValues({ ref }, props));
4746
- });
4747
- SidebarMenuSubItem.displayName = "SidebarMenuSubItem";
4748
- var SidebarMenuSubButton = React63.forwardRef((_a, ref) => {
4749
- var _b = _a, { asChild = false, size = "md", isActive, className } = _b, props = __objRest(_b, ["asChild", "size", "isActive", "className"]);
4750
- const Comp = asChild ? Slot4 : "a";
4751
- return /* @__PURE__ */ jsx66(
4752
- Comp,
4753
- __spreadValues({
4754
- ref,
4755
- "data-sidebar": "menu-sub-button",
4756
- "data-size": size,
4757
- "data-active": isActive,
4758
- className: cn(
4759
- "flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-hidden ring-sidebar-ring 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 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground",
4760
- "data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",
4761
- size === "sm" && "text-xs",
4762
- size === "md" && "text-sm",
4763
- "group-data-[collapsible=icon]:hidden",
4764
- className
4765
- )
4766
- }, props)
4767
- );
4768
- });
4769
- SidebarMenuSubButton.displayName = "SidebarMenuSubButton";
4770
-
4771
- // src/ui/slider.tsx
4772
- import * as React64 from "react";
4773
- import * as SliderPrimitive from "@radix-ui/react-slider";
4774
- import { jsx as jsx67, jsxs as jsxs26 } from "react/jsx-runtime";
4775
- var Slider = React64.forwardRef((_a, ref) => {
4776
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4777
- return /* @__PURE__ */ jsxs26(
4778
- SliderPrimitive.Root,
4779
- __spreadProps(__spreadValues({
4780
- ref,
4781
- className: cn(
4782
- "relative flex w-full touch-none select-none items-center",
4783
- className
4784
- )
4785
- }, props), {
4786
- children: [
4787
- /* @__PURE__ */ jsx67(SliderPrimitive.Track, { className: "relative h-2 w-full grow overflow-hidden rounded-full bg-secondary", children: /* @__PURE__ */ jsx67(SliderPrimitive.Range, { className: "absolute h-full bg-primary" }) }),
4788
- /* @__PURE__ */ jsx67(SliderPrimitive.Thumb, { className: "block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50" })
4789
- ]
4790
- })
4791
- );
4792
- });
4793
- Slider.displayName = SliderPrimitive.Root.displayName;
4794
-
4795
- // src/ui/sonner.tsx
4796
- import { useTheme } from "next-themes";
4797
- import { Toaster as Sonner } from "sonner";
4798
- import { jsx as jsx68 } from "react/jsx-runtime";
4799
- var Toaster = (_a) => {
4800
- var props = __objRest(_a, []);
4801
- const { theme = "system" } = useTheme();
4802
- return /* @__PURE__ */ jsx68(
4803
- Sonner,
4804
- __spreadValues({
4805
- theme,
4806
- className: "toaster group",
4807
- toastOptions: {
4808
- classNames: {
4809
- toast: "group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",
4810
- description: "group-[.toast]:text-muted-foreground",
4811
- actionButton: "group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",
4812
- cancelButton: "group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"
4813
- }
4814
- }
4815
- }, props)
4816
- );
4817
- };
4818
-
4819
- // src/ui/switch.tsx
4820
- import * as React65 from "react";
4821
- import * as SwitchPrimitives from "@radix-ui/react-switch";
4822
- import { jsx as jsx69 } from "react/jsx-runtime";
4823
- var Switch = React65.forwardRef((_a, ref) => {
4824
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4825
- return /* @__PURE__ */ jsx69(
4826
- SwitchPrimitives.Root,
4827
- __spreadProps(__spreadValues({
4828
- className: cn(
4829
- "peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",
4830
- className
4831
- )
4832
- }, props), {
4833
- ref,
4834
- children: /* @__PURE__ */ jsx69(
4835
- SwitchPrimitives.Thumb,
4836
- {
4837
- className: cn(
4838
- "pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0"
4839
- )
4840
- }
4841
- )
4842
- })
4843
- );
4844
- });
4845
- Switch.displayName = SwitchPrimitives.Root.displayName;
4846
-
4847
- // src/ui/table.tsx
4848
- import * as React66 from "react";
4849
- import { jsx as jsx70 } from "react/jsx-runtime";
4850
- var Table = React66.forwardRef((_a, ref) => {
4851
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4852
- return /* @__PURE__ */ jsx70("div", { className: "relative w-full overflow-auto", children: /* @__PURE__ */ jsx70(
4853
- "table",
4854
- __spreadValues({
4855
- ref,
4856
- className: cn("w-full caption-bottom text-sm", className)
4857
- }, props)
4858
- ) });
4859
- });
4860
- Table.displayName = "Table";
4861
- var TableHeader = React66.forwardRef((_a, ref) => {
4862
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4863
- return /* @__PURE__ */ jsx70("thead", __spreadValues({ ref, className: cn("[&_tr]:border-b", className) }, props));
4864
- });
4865
- TableHeader.displayName = "TableHeader";
4866
- var TableBody = React66.forwardRef((_a, ref) => {
4867
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4868
- return /* @__PURE__ */ jsx70(
4869
- "tbody",
4870
- __spreadValues({
4871
- ref,
4872
- className: cn("[&_tr:last-child]:border-0", className)
4873
- }, props)
4874
- );
4875
- });
4876
- TableBody.displayName = "TableBody";
4877
- var TableFooter = React66.forwardRef((_a, ref) => {
4878
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4879
- return /* @__PURE__ */ jsx70(
4880
- "tfoot",
4881
- __spreadValues({
4882
- ref,
4883
- className: cn(
4884
- "border-t bg-muted/50 font-medium last:[&>tr]:border-b-0",
4885
- className
4886
- )
4887
- }, props)
4888
- );
4889
- });
4890
- TableFooter.displayName = "TableFooter";
4891
- var TableRow = React66.forwardRef((_a, ref) => {
4892
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4893
- return /* @__PURE__ */ jsx70(
4894
- "tr",
4895
- __spreadValues({
4896
- ref,
4897
- className: cn(
4898
- "border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",
4899
- className
4900
- )
4901
- }, props)
4902
- );
4903
- });
4904
- TableRow.displayName = "TableRow";
4905
- var TableHead = React66.forwardRef((_a, ref) => {
4906
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4907
- return /* @__PURE__ */ jsx70(
4908
- "th",
4909
- __spreadValues({
4910
- ref,
4911
- className: cn(
4912
- "h-12 px-4 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",
4913
- className
4914
- )
4915
- }, props)
4916
- );
4917
- });
4918
- TableHead.displayName = "TableHead";
4919
- var TableCell = React66.forwardRef((_a, ref) => {
4920
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4921
- return /* @__PURE__ */ jsx70(
4922
- "td",
4923
- __spreadValues({
4924
- ref,
4925
- className: cn("p-4 align-middle [&:has([role=checkbox])]:pr-0", className)
4926
- }, props)
4927
- );
4928
- });
4929
- TableCell.displayName = "TableCell";
4930
- var TableCaption = React66.forwardRef((_a, ref) => {
4931
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4932
- return /* @__PURE__ */ jsx70(
4933
- "caption",
4934
- __spreadValues({
4935
- ref,
4936
- className: cn("mt-4 text-sm text-muted-foreground", className)
4937
- }, props)
4938
- );
4939
- });
4940
- TableCaption.displayName = "TableCaption";
4941
-
4942
- // src/ui/tabs.tsx
4943
- import * as React67 from "react";
4944
- import * as TabsPrimitive from "@radix-ui/react-tabs";
4945
- import { jsx as jsx71 } from "react/jsx-runtime";
4946
- var Tabs = TabsPrimitive.Root;
4947
- var TabsList = React67.forwardRef((_a, ref) => {
4948
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4949
- return /* @__PURE__ */ jsx71(
4950
- TabsPrimitive.List,
4951
- __spreadValues({
4952
- ref,
4953
- className: cn(
4954
- "inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",
4955
- className
4956
- )
4957
- }, props)
4958
- );
4959
- });
4960
- TabsList.displayName = TabsPrimitive.List.displayName;
4961
- var TabsTrigger = React67.forwardRef((_a, ref) => {
4962
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4963
- return /* @__PURE__ */ jsx71(
4964
- TabsPrimitive.Trigger,
4965
- __spreadValues({
4966
- ref,
4967
- className: cn(
4968
- "inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-xs",
4969
- className
4970
- )
4971
- }, props)
4972
- );
4973
- });
4974
- TabsTrigger.displayName = TabsPrimitive.Trigger.displayName;
4975
- var TabsContent = React67.forwardRef((_a, ref) => {
4976
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4977
- return /* @__PURE__ */ jsx71(
4978
- TabsPrimitive.Content,
4979
- __spreadValues({
4980
- ref,
4981
- className: cn(
4982
- "mt-2 ring-offset-background focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
4983
- className
4984
- )
4985
- }, props)
4986
- );
4987
- });
4988
- TabsContent.displayName = TabsPrimitive.Content.displayName;
4989
-
4990
- // src/ui/textarea.tsx
4991
- import * as React68 from "react";
4992
- import { jsx as jsx72 } from "react/jsx-runtime";
4993
- var Textarea = React68.forwardRef((_a, ref) => {
4994
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4995
- return /* @__PURE__ */ jsx72(
4996
- "textarea",
4997
- __spreadValues({
4998
- className: cn(
4999
- "flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background placeholder:text-muted-foreground focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
5000
- className
5001
- ),
5002
- ref
5003
- }, props)
5004
- );
5005
- });
5006
- Textarea.displayName = "Textarea";
5007
-
5008
- // src/ui/toast.tsx
5009
- import * as React69 from "react";
5010
- import * as ToastPrimitives from "@radix-ui/react-toast";
5011
- import { cva as cva8 } from "class-variance-authority";
5012
- import { jsx as jsx73 } from "react/jsx-runtime";
5013
- var ToastProvider = ToastPrimitives.Provider;
5014
- var ToastViewport = React69.forwardRef((_a, ref) => {
5015
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
5016
- return /* @__PURE__ */ jsx73(
5017
- ToastPrimitives.Viewport,
5018
- __spreadValues({
5019
- ref,
5020
- className: cn(
5021
- "fixed top-0 z-100 flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",
5022
- className
5023
- )
5024
- }, props)
5025
- );
5026
- });
5027
- ToastViewport.displayName = ToastPrimitives.Viewport.displayName;
5028
- var toastVariants = cva8(
5029
- "group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full sm:data-[state=open]:slide-in-from-bottom-full",
5030
- {
5031
- variants: {
5032
- variant: {
5033
- default: "border bg-background text-foreground",
5034
- destructive: "destructive group border-destructive bg-destructive text-destructive-foreground"
5035
- }
5036
- },
5037
- defaultVariants: {
5038
- variant: "default"
5039
- }
5040
- }
5041
- );
5042
- var Toast = React69.forwardRef((_a, ref) => {
5043
- var _b = _a, { className, variant } = _b, props = __objRest(_b, ["className", "variant"]);
5044
- return /* @__PURE__ */ jsx73(
5045
- ToastPrimitives.Root,
5046
- __spreadValues({
5047
- ref,
5048
- className: cn(toastVariants({ variant }), className)
5049
- }, props)
5050
- );
5051
- });
5052
- Toast.displayName = ToastPrimitives.Root.displayName;
5053
- var ToastAction = React69.forwardRef((_a, ref) => {
5054
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
5055
- return /* @__PURE__ */ jsx73(
5056
- ToastPrimitives.Action,
5057
- __spreadValues({
5058
- ref,
5059
- className: cn(
5060
- "inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors hover:bg-secondary focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 hover:group-[.destructive]:border-destructive/30 hover:group-[.destructive]:bg-destructive hover:group-[.destructive]:text-destructive-foreground focus:group-[.destructive]:ring-destructive",
5061
- className
5062
- )
5063
- }, props)
5064
- );
5065
- });
5066
- ToastAction.displayName = ToastPrimitives.Action.displayName;
5067
- var ToastClose = React69.forwardRef((_a, ref) => {
5068
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
5069
- return /* @__PURE__ */ jsx73(
5070
- ToastPrimitives.Close,
5071
- __spreadProps(__spreadValues({
5072
- ref,
5073
- className: cn(
5074
- "absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-hidden focus:ring-2 group-hover:opacity-100 group-[.destructive]:text-red-300 hover:group-[.destructive]:text-red-50 focus:group-[.destructive]:ring-red-400 focus:group-[.destructive]:ring-offset-red-600",
5075
- className
5076
- ),
5077
- "toast-close": ""
5078
- }, props), {
5079
- children: /* @__PURE__ */ jsx73(globalLucideIcons.X, { className: "h-4 w-4" })
5080
- })
5081
- );
5082
- });
5083
- ToastClose.displayName = ToastPrimitives.Close.displayName;
5084
- var ToastTitle = React69.forwardRef((_a, ref) => {
5085
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
5086
- return /* @__PURE__ */ jsx73(
5087
- ToastPrimitives.Title,
5088
- __spreadValues({
5089
- ref,
5090
- className: cn("text-sm font-semibold", className)
5091
- }, props)
5092
- );
5093
- });
5094
- ToastTitle.displayName = ToastPrimitives.Title.displayName;
5095
- var ToastDescription = React69.forwardRef((_a, ref) => {
5096
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
5097
- return /* @__PURE__ */ jsx73(
5098
- ToastPrimitives.Description,
5099
- __spreadValues({
5100
- ref,
5101
- className: cn("text-sm opacity-90", className)
5102
- }, props)
5103
- );
5104
- });
5105
- ToastDescription.displayName = ToastPrimitives.Description.displayName;
5106
-
5107
- // src/ui/use-toast.ts
5108
- import * as React70 from "react";
5109
- var TOAST_LIMIT = 1;
5110
- var TOAST_REMOVE_DELAY = 1e6;
5111
- var ACTIONS = {
5112
- ADD_TOAST: "ADD_TOAST",
5113
- UPDATE_TOAST: "UPDATE_TOAST",
5114
- DISMISS_TOAST: "DISMISS_TOAST",
5115
- REMOVE_TOAST: "REMOVE_TOAST"
5116
- };
5117
- var count = 0;
5118
- function genId() {
5119
- count = (count + 1) % Number.MAX_SAFE_INTEGER;
5120
- return count.toString();
5121
- }
5122
- var toastTimeouts = /* @__PURE__ */ new Map();
5123
- var addToRemoveQueue = (toastId) => {
5124
- if (toastTimeouts.has(toastId)) {
5125
- return;
5126
- }
5127
- const timeout = setTimeout(() => {
5128
- toastTimeouts.delete(toastId);
5129
- dispatch({
5130
- type: ACTIONS.REMOVE_TOAST,
5131
- toastId
5132
- });
5133
- }, TOAST_REMOVE_DELAY);
5134
- toastTimeouts.set(toastId, timeout);
5135
- };
5136
- var reducer = (state, action) => {
5137
- switch (action.type) {
5138
- case "ADD_TOAST":
5139
- return __spreadProps(__spreadValues({}, state), {
5140
- toasts: [action.toast, ...state.toasts].slice(0, TOAST_LIMIT)
5141
- });
5142
- case "UPDATE_TOAST":
5143
- return __spreadProps(__spreadValues({}, state), {
5144
- toasts: state.toasts.map(
5145
- (t) => t.id === action.toast.id ? __spreadValues(__spreadValues({}, t), action.toast) : t
5146
- )
5147
- });
5148
- case "DISMISS_TOAST": {
5149
- const { toastId } = action;
5150
- if (toastId) {
5151
- addToRemoveQueue(toastId);
5152
- } else {
5153
- state.toasts.forEach((toast2) => {
5154
- addToRemoveQueue(toast2.id);
5155
- });
5156
- }
5157
- return __spreadProps(__spreadValues({}, state), {
5158
- toasts: state.toasts.map(
5159
- (t) => t.id === toastId || toastId === void 0 ? __spreadProps(__spreadValues({}, t), {
5160
- open: false
5161
- }) : t
5162
- )
5163
- });
5164
- }
5165
- case "REMOVE_TOAST":
5166
- if (action.toastId === void 0) {
5167
- return __spreadProps(__spreadValues({}, state), {
5168
- toasts: []
5169
- });
5170
- }
5171
- return __spreadProps(__spreadValues({}, state), {
5172
- toasts: state.toasts.filter((t) => t.id !== action.toastId)
5173
- });
5174
- }
5175
- };
5176
- var listeners = [];
5177
- var memoryState = { toasts: [] };
5178
- function dispatch(action) {
5179
- memoryState = reducer(memoryState, action);
5180
- listeners.forEach((listener) => {
5181
- listener(memoryState);
5182
- });
5183
- }
5184
- function toast(_a) {
5185
- var props = __objRest(_a, []);
5186
- const id = genId();
5187
- const update = (props2) => dispatch({
5188
- type: "UPDATE_TOAST",
5189
- toast: __spreadProps(__spreadValues({}, props2), { id })
5190
- });
5191
- const dismiss = () => dispatch({ type: "DISMISS_TOAST", toastId: id });
5192
- dispatch({
5193
- type: "ADD_TOAST",
5194
- toast: __spreadProps(__spreadValues({}, props), {
5195
- id,
5196
- open: true,
5197
- onOpenChange: (open) => {
5198
- if (!open) dismiss();
5199
- }
5200
- })
5201
- });
5202
- return {
5203
- id,
5204
- dismiss,
5205
- update
5206
- };
5207
- }
5208
- function useToast() {
5209
- const [state, setState] = React70.useState(memoryState);
5210
- React70.useEffect(() => {
5211
- listeners.push(setState);
5212
- return () => {
5213
- const index = listeners.indexOf(setState);
5214
- if (index > -1) {
5215
- listeners.splice(index, 1);
5216
- }
5217
- };
5218
- }, [state]);
5219
- return __spreadProps(__spreadValues({}, state), {
5220
- toast,
5221
- dismiss: (toastId) => dispatch({ type: "DISMISS_TOAST", toastId })
5222
- });
5223
- }
5224
-
5225
- // src/ui/toaster.tsx
5226
- import { jsx as jsx74, jsxs as jsxs27 } from "react/jsx-runtime";
5227
- function Toaster2() {
5228
- const { toasts } = useToast();
5229
- return /* @__PURE__ */ jsxs27(ToastProvider, { children: [
5230
- toasts.map(function(_a) {
5231
- var _b = _a, { id, title, description, action } = _b, props = __objRest(_b, ["id", "title", "description", "action"]);
5232
- return /* @__PURE__ */ jsxs27(Toast, __spreadProps(__spreadValues({}, props), { children: [
5233
- /* @__PURE__ */ jsxs27("div", { className: "grid gap-1", children: [
5234
- title && /* @__PURE__ */ jsx74(ToastTitle, { children: title }),
5235
- description && /* @__PURE__ */ jsx74(ToastDescription, { children: description })
5236
- ] }),
5237
- action,
5238
- /* @__PURE__ */ jsx74(ToastClose, {})
5239
- ] }), id);
5240
- }),
5241
- /* @__PURE__ */ jsx74(ToastViewport, {})
5242
- ] });
5243
- }
5244
-
5245
- // src/ui/toggle-group.tsx
5246
- import * as React72 from "react";
5247
- import * as ToggleGroupPrimitive from "@radix-ui/react-toggle-group";
5248
-
5249
- // src/ui/toggle.tsx
5250
- import * as React71 from "react";
5251
- import * as TogglePrimitive from "@radix-ui/react-toggle";
5252
- import { cva as cva9 } from "class-variance-authority";
5253
- import { jsx as jsx75 } from "react/jsx-runtime";
5254
- var toggleVariants = cva9(
5255
- "inline-flex items-center justify-center rounded-md text-sm font-medium ring-offset-background transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0 gap-2",
5256
- {
5257
- variants: {
5258
- variant: {
5259
- default: "bg-transparent",
5260
- outline: "border border-input bg-transparent hover:bg-accent hover:text-accent-foreground"
5261
- },
5262
- size: {
5263
- default: "h-10 px-3 min-w-10",
5264
- sm: "h-9 px-2.5 min-w-9",
5265
- lg: "h-11 px-5 min-w-11"
5266
- }
5267
- },
5268
- defaultVariants: {
5269
- variant: "default",
5270
- size: "default"
5271
- }
5272
- }
5273
- );
5274
- var Toggle = React71.forwardRef((_a, ref) => {
5275
- var _b = _a, { className, variant, size } = _b, props = __objRest(_b, ["className", "variant", "size"]);
5276
- return /* @__PURE__ */ jsx75(
5277
- TogglePrimitive.Root,
5278
- __spreadValues({
5279
- ref,
5280
- className: cn(toggleVariants({ variant, size, className }))
5281
- }, props)
5282
- );
5283
- });
5284
- Toggle.displayName = TogglePrimitive.Root.displayName;
5285
-
5286
- // src/ui/toggle-group.tsx
5287
- import { jsx as jsx76 } from "react/jsx-runtime";
5288
- var ToggleGroupContext = React72.createContext({
5289
- size: "default",
5290
- variant: "default"
5291
- });
5292
- var ToggleGroup = React72.forwardRef((_a, ref) => {
5293
- var _b = _a, { className, variant, size, children } = _b, props = __objRest(_b, ["className", "variant", "size", "children"]);
5294
- return /* @__PURE__ */ jsx76(
5295
- ToggleGroupPrimitive.Root,
5296
- __spreadProps(__spreadValues({
5297
- ref,
5298
- className: cn("flex items-center justify-center gap-1", className)
5299
- }, props), {
5300
- children: /* @__PURE__ */ jsx76(ToggleGroupContext.Provider, { value: { variant, size }, children })
5301
- })
5302
- );
5303
- });
5304
- ToggleGroup.displayName = ToggleGroupPrimitive.Root.displayName;
5305
- var ToggleGroupItem = React72.forwardRef((_a, ref) => {
5306
- var _b = _a, { className, children, variant, size } = _b, props = __objRest(_b, ["className", "children", "variant", "size"]);
5307
- const context = React72.useContext(ToggleGroupContext);
5308
- return /* @__PURE__ */ jsx76(
5309
- ToggleGroupPrimitive.Item,
5310
- __spreadProps(__spreadValues({
5311
- ref,
5312
- className: cn(
5313
- toggleVariants({
5314
- variant: context.variant || variant,
5315
- size: context.size || size
5316
- }),
5317
- className
5318
- )
5319
- }, props), {
5320
- children
5321
- })
5322
- );
5323
- });
5324
- ToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;
1698
+ LanguageButton.displayName = "Button";
5325
1699
  export {
5326
- Accordion,
5327
- AccordionContent,
5328
- AccordionItem,
5329
- AccordionTrigger,
5330
- Alert,
5331
- AlertDescription,
5332
1700
  AlertDialog,
5333
1701
  AlertDialogAction,
5334
1702
  AlertDialogCancel,
@@ -5340,86 +1708,7 @@ export {
5340
1708
  AlertDialogPortal,
5341
1709
  AlertDialogTitle,
5342
1710
  AlertDialogTrigger,
5343
- AlertTitle,
5344
- AspectRatio,
5345
- Avatar,
5346
- AvatarFallback,
5347
- AvatarImage,
5348
- Badge,
5349
- Breadcrumb,
5350
- BreadcrumbEllipsis,
5351
- BreadcrumbItem,
5352
- BreadcrumbLink,
5353
- BreadcrumbList,
5354
- BreadcrumbPage,
5355
- BreadcrumbSeparator,
5356
1711
  Button,
5357
- Calendar,
5358
- Card,
5359
- CardContent,
5360
- CardDescription,
5361
- CardFooter,
5362
- CardHeader,
5363
- CardTitle,
5364
- Carousel,
5365
- CarouselContent,
5366
- CarouselItem,
5367
- CarouselNext,
5368
- CarouselPrevious,
5369
- ChartContainer,
5370
- ChartLegend,
5371
- ChartLegendContent,
5372
- ChartStyle,
5373
- ChartTooltip,
5374
- ChartTooltipContent,
5375
- Checkbox,
5376
- Collapsible,
5377
- CollapsibleContent2 as CollapsibleContent,
5378
- CollapsibleTrigger2 as CollapsibleTrigger,
5379
- Command,
5380
- CommandDialog,
5381
- CommandEmpty,
5382
- CommandGroup,
5383
- CommandInput,
5384
- CommandItem,
5385
- CommandList,
5386
- CommandSeparator,
5387
- CommandShortcut,
5388
- ContextMenu,
5389
- ContextMenuCheckboxItem,
5390
- ContextMenuContent,
5391
- ContextMenuGroup,
5392
- ContextMenuItem,
5393
- ContextMenuLabel,
5394
- ContextMenuPortal,
5395
- ContextMenuRadioGroup,
5396
- ContextMenuRadioItem,
5397
- ContextMenuSeparator,
5398
- ContextMenuShortcut,
5399
- ContextMenuSub,
5400
- ContextMenuSubContent,
5401
- ContextMenuSubTrigger,
5402
- ContextMenuTrigger,
5403
- Dialog,
5404
- DialogClose,
5405
- DialogContent,
5406
- DialogDescription,
5407
- DialogFooter,
5408
- DialogHeader,
5409
- DialogOverlay,
5410
- DialogPortal,
5411
- DialogTitle,
5412
- DialogTrigger,
5413
- Drawer,
5414
- DrawerClose,
5415
- DrawerContent,
5416
- DrawerDescription,
5417
- DrawerFooter,
5418
- DrawerHeader,
5419
- DrawerOverlay,
5420
- DrawerPortal,
5421
- DrawerTitle,
5422
- DrawerTrigger,
5423
1712
  DropdownMenu,
5424
1713
  DropdownMenuCheckboxItem,
5425
1714
  DropdownMenuContent,
@@ -5435,151 +1724,9 @@ export {
5435
1724
  DropdownMenuSubContent,
5436
1725
  DropdownMenuSubTrigger,
5437
1726
  DropdownMenuTrigger,
5438
- Form,
5439
- FormControl,
5440
- FormDescription,
5441
- FormField,
5442
- FormItem,
5443
- FormLabel,
5444
- FormMessage,
5445
- HoverCard,
5446
- HoverCardContent,
5447
- HoverCardTrigger,
5448
- Input,
5449
- InputOTP,
5450
- InputOTPGroup,
5451
- InputOTPSeparator,
5452
- InputOTPSlot,
5453
- Label3 as Label,
1727
+ Label2 as Label,
5454
1728
  LanguageButton,
5455
- Menubar,
5456
- MenubarCheckboxItem,
5457
- MenubarContent,
5458
- MenubarGroup,
5459
- MenubarItem,
5460
- MenubarLabel,
5461
- MenubarMenu,
5462
- MenubarPortal,
5463
- MenubarRadioGroup,
5464
- MenubarRadioItem,
5465
- MenubarSeparator,
5466
- MenubarShortcut,
5467
- MenubarSub,
5468
- MenubarSubContent,
5469
- MenubarSubTrigger,
5470
- MenubarTrigger,
5471
- NavigationMenu,
5472
- NavigationMenuContent,
5473
- NavigationMenuIndicator,
5474
- NavigationMenuItem,
5475
- NavigationMenuLink,
5476
- NavigationMenuList,
5477
- NavigationMenuTrigger,
5478
- NavigationMenuViewport,
5479
- Pagination,
5480
- PaginationContent,
5481
- PaginationEllipsis,
5482
- PaginationItem,
5483
- PaginationLink,
5484
- PaginationNext,
5485
- PaginationPrevious,
5486
- Popover,
5487
- PopoverContent,
5488
- PopoverTrigger,
5489
- Progress,
5490
- RadioGroup4 as RadioGroup,
5491
- RadioGroupItem,
5492
- ResizableHandle,
5493
- ResizablePanel,
5494
- ResizablePanelGroup,
5495
- ScrollArea,
5496
- ScrollBar,
5497
- Select,
5498
- SelectContent,
5499
- SelectGroup,
5500
- SelectItem,
5501
- SelectLabel,
5502
- SelectScrollDownButton,
5503
- SelectScrollUpButton,
5504
- SelectSeparator,
5505
- SelectTrigger,
5506
- SelectValue,
5507
- Separator5 as Separator,
5508
- Sheet,
5509
- SheetClose,
5510
- SheetContent,
5511
- SheetDescription,
5512
- SheetFooter,
5513
- SheetHeader,
5514
- SheetOverlay,
5515
- SheetPortal,
5516
- SheetTitle,
5517
- SheetTrigger,
5518
- Sidebar,
5519
- SidebarContent,
5520
- SidebarFooter,
5521
- SidebarGroup,
5522
- SidebarGroupAction,
5523
- SidebarGroupContent,
5524
- SidebarGroupLabel,
5525
- SidebarHeader,
5526
- SidebarInput,
5527
- SidebarInset,
5528
- SidebarMenu,
5529
- SidebarMenuAction,
5530
- SidebarMenuBadge,
5531
- SidebarMenuButton,
5532
- SidebarMenuItem,
5533
- SidebarMenuSkeleton,
5534
- SidebarMenuSub,
5535
- SidebarMenuSubButton,
5536
- SidebarMenuSubItem,
5537
- SidebarProvider,
5538
- SidebarRail,
5539
- SidebarSeparator,
5540
- SidebarTrigger,
5541
- Skeleton,
5542
- Slider,
5543
- Toaster as SonnerToaster,
5544
- Switch,
5545
- Table,
5546
- TableBody,
5547
- TableCaption,
5548
- TableCell,
5549
- TableFooter,
5550
- TableHead,
5551
- TableHeader,
5552
- TableRow,
5553
- Tabs,
5554
- TabsContent,
5555
- TabsList,
5556
- TabsTrigger,
5557
- Textarea,
5558
- Toast,
5559
- ToastAction,
5560
- ToastClose,
5561
- ToastDescription,
5562
- ToastProvider,
5563
- ToastTitle,
5564
- Toaster2 as ToastToaster,
5565
- ToastViewport,
5566
- Toggle,
5567
- ToggleGroup,
5568
- ToggleGroupItem,
5569
- Tooltip2 as Tooltip,
5570
- TooltipContent,
5571
- TooltipProvider,
5572
- TooltipTrigger,
5573
- badgeVariants,
5574
- buttonVariants,
5575
- navigationMenuTriggerStyle,
5576
- reducer,
5577
- toast,
5578
- toggleVariants,
5579
- useFormField,
5580
- useIsMobile,
5581
- useSidebar,
5582
- useToast
1729
+ buttonVariants
5583
1730
  };
5584
1731
  /**
5585
1732
  * @license