@a2v2ai/uikit 0.0.29 → 0.0.30

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 (74) hide show
  1. package/Alert/Alert.d.ts +1 -1
  2. package/Alert/Alert.js +9 -48
  3. package/AlertDialog/AlertDialog.d.ts +3 -3
  4. package/AlertDialog/AlertDialog.js +19 -69
  5. package/Avatar/Avatar.d.ts +1 -1
  6. package/Avatar/Avatar.js +10 -49
  7. package/Badge/Badge.d.ts +1 -1
  8. package/Badge/Badge.js +7 -10
  9. package/Breadcrumb/Breadcrumb.js +14 -56
  10. package/Button/Button.d.ts +1 -1
  11. package/Button/Button.js +9 -46
  12. package/Calendar/Calendar.js +43 -79
  13. package/Card/Card.d.ts +1 -1
  14. package/Card/Card.js +12 -54
  15. package/Carousel/Carousel.d.ts +5 -5
  16. package/Carousel/Carousel.js +20 -67
  17. package/ChatBubble/ChatBubble.d.ts +2 -2
  18. package/ChatBubble/ChatBubble.js +9 -47
  19. package/Checkbox/Checkbox.d.ts +1 -1
  20. package/Checkbox/Checkbox.js +9 -46
  21. package/DataTable/DataTable.js +4 -8
  22. package/Drawer/Drawer.d.ts +2 -2
  23. package/Drawer/Drawer.js +20 -34
  24. package/DropdownMenu/DropdownMenu.js +15 -65
  25. package/ErrorMessage/ErrorMessage.js +6 -7
  26. package/Flex/Flex.d.ts +1 -1
  27. package/Flex/Flex.js +7 -44
  28. package/IconButton/IconButton.d.ts +1 -1
  29. package/IconButton/IconButton.js +9 -46
  30. package/Input/Input.d.ts +1 -1
  31. package/Input/Input.js +12 -48
  32. package/InputOTP/InputOTP.d.ts +2 -2
  33. package/InputOTP/InputOTP.js +15 -56
  34. package/Label/Label.d.ts +1 -1
  35. package/Label/Label.js +11 -48
  36. package/Loader/Loader.d.ts +1 -1
  37. package/Loader/Loader.js +10 -47
  38. package/Menubar/Menubar.js +22 -71
  39. package/Menubar/index.js +1 -20
  40. package/Popover/Popover.js +6 -45
  41. package/Progress/Progress.d.ts +2 -2
  42. package/Progress/Progress.js +9 -47
  43. package/RadioGroup/RadioGroup.d.ts +1 -1
  44. package/RadioGroup/RadioGroup.js +10 -48
  45. package/ScrollArea/ScrollArea.js +8 -45
  46. package/Select/Select.d.ts +1 -1
  47. package/Select/Select.js +20 -65
  48. package/Separator/Separator.js +6 -42
  49. package/Sidebar/Sidebar.d.ts +2 -2
  50. package/Sidebar/Sidebar.js +22 -67
  51. package/Sidebar/index.js +1 -17
  52. package/Skeleton/Skeleton.js +5 -6
  53. package/Slider/Slider.js +6 -42
  54. package/Spinner/Spinner.d.ts +1 -1
  55. package/Spinner/Spinner.js +7 -44
  56. package/Switch/Switch.d.ts +1 -1
  57. package/Switch/Switch.js +9 -46
  58. package/Table/Table.js +12 -55
  59. package/Tabs/Tabs.d.ts +1 -1
  60. package/Tabs/Tabs.js +10 -50
  61. package/Textarea/Textarea.d.ts +1 -1
  62. package/Textarea/Textarea.js +9 -45
  63. package/Toast/Toast.js +10 -14
  64. package/Tooltip/Tooltip.d.ts +1 -1
  65. package/Tooltip/Tooltip.js +11 -50
  66. package/Typography/Typography.d.ts +1 -1
  67. package/Typography/Typography.js +12 -15
  68. package/helpers.js +4 -12
  69. package/icons.js +1 -17
  70. package/index.js +41 -235
  71. package/lib/typography-types.js +2 -5
  72. package/lib/utils.js +5 -9
  73. package/package.json +2 -1
  74. package/tmpclaude-2407-cwd +1 -0
@@ -1,114 +1,78 @@
1
- "use strict";
2
1
  "use client";
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
15
- Object.defineProperty(o, "default", { enumerable: true, value: v });
16
- }) : function(o, v) {
17
- o["default"] = v;
18
- });
19
- var __importStar = (this && this.__importStar) || (function () {
20
- var ownKeys = function(o) {
21
- ownKeys = Object.getOwnPropertyNames || function (o) {
22
- var ar = [];
23
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
24
- return ar;
25
- };
26
- return ownKeys(o);
27
- };
28
- return function (mod) {
29
- if (mod && mod.__esModule) return mod;
30
- var result = {};
31
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
32
- __setModuleDefault(result, mod);
33
- return result;
34
- };
35
- })();
36
- Object.defineProperty(exports, "__esModule", { value: true });
37
- exports.Calendar = Calendar;
38
- exports.CalendarDayButton = CalendarDayButton;
39
- const jsx_runtime_1 = require("react/jsx-runtime");
40
- const React = __importStar(require("react"));
41
- const lucide_react_1 = require("lucide-react");
42
- const react_day_picker_1 = require("react-day-picker");
43
- const utils_1 = require("../lib/utils");
44
- const Button_1 = require("../Button/Button");
45
- const Typography_1 = require("../Typography/Typography");
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import * as React from "react";
4
+ import { ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, } from "lucide-react";
5
+ import { DayButton, DayPicker, getDefaultClassNames } from "react-day-picker";
6
+ import { cn } from "../lib/utils";
7
+ import { Button, buttonVariants } from "../Button/Button";
8
+ import { Typography } from "../Typography/Typography";
46
9
  function Calendar({ className, classNames, showOutsideDays = true, captionLayout = "label", buttonVariant = "ghost", formatters, components, error, ...props }) {
47
- const defaultClassNames = (0, react_day_picker_1.getDefaultClassNames)();
48
- return ((0, jsx_runtime_1.jsxs)("div", { className: "flex flex-col w-fit", children: [(0, jsx_runtime_1.jsx)(react_day_picker_1.DayPicker, { showOutsideDays: showOutsideDays, className: (0, utils_1.cn)("bg-white group/calendar p-3 rounded-lg border", error ? "border-error-500" : "border-grey-200", className), captionLayout: captionLayout, formatters: {
10
+ const defaultClassNames = getDefaultClassNames();
11
+ return (_jsxs("div", { className: "flex flex-col w-fit", children: [_jsx(DayPicker, { showOutsideDays: showOutsideDays, className: cn("bg-white group/calendar p-3 rounded-lg border", error ? "border-error-500" : "border-grey-200", className), captionLayout: captionLayout, formatters: {
49
12
  formatMonthDropdown: (date) => date.toLocaleString("default", { month: "short" }),
50
13
  ...formatters,
51
14
  }, classNames: {
52
- root: (0, utils_1.cn)("w-fit", defaultClassNames.root),
53
- months: (0, utils_1.cn)("flex gap-4 flex-col md:flex-row relative", defaultClassNames.months),
54
- month: (0, utils_1.cn)("flex flex-col w-full gap-4", defaultClassNames.month),
55
- nav: (0, utils_1.cn)("flex items-center gap-1 w-full absolute top-0 inset-x-0 justify-between", defaultClassNames.nav),
56
- button_previous: (0, utils_1.cn)((0, Button_1.buttonVariants)({ variant: buttonVariant, size: "small" }), "size-8 aria-disabled:opacity-50 p-0 select-none", defaultClassNames.button_previous),
57
- button_next: (0, utils_1.cn)((0, Button_1.buttonVariants)({ variant: buttonVariant, size: "small" }), "size-8 aria-disabled:opacity-50 p-0 select-none", defaultClassNames.button_next),
58
- month_caption: (0, utils_1.cn)("flex items-center justify-center h-8 w-full px-8", defaultClassNames.month_caption),
59
- dropdowns: (0, utils_1.cn)("w-full flex items-center text-sm font-medium justify-center h-8 gap-1.5", defaultClassNames.dropdowns),
60
- dropdown_root: (0, utils_1.cn)("relative has-focus:border-grey-400 border border-grey-300 shadow-xs has-focus:ring-grey-300/50 has-focus:ring-[3px] rounded-md", defaultClassNames.dropdown_root),
61
- dropdown: (0, utils_1.cn)("absolute bg-white inset-0 opacity-0", defaultClassNames.dropdown),
62
- caption_label: (0, utils_1.cn)("select-none font-medium text-main-900", captionLayout === "label"
15
+ root: cn("w-fit", defaultClassNames.root),
16
+ months: cn("flex gap-4 flex-col md:flex-row relative", defaultClassNames.months),
17
+ month: cn("flex flex-col w-full gap-4", defaultClassNames.month),
18
+ nav: cn("flex items-center gap-1 w-full absolute top-0 inset-x-0 justify-between", defaultClassNames.nav),
19
+ button_previous: cn(buttonVariants({ variant: buttonVariant, size: "small" }), "size-8 aria-disabled:opacity-50 p-0 select-none", defaultClassNames.button_previous),
20
+ button_next: cn(buttonVariants({ variant: buttonVariant, size: "small" }), "size-8 aria-disabled:opacity-50 p-0 select-none", defaultClassNames.button_next),
21
+ month_caption: cn("flex items-center justify-center h-8 w-full px-8", defaultClassNames.month_caption),
22
+ dropdowns: cn("w-full flex items-center text-sm font-medium justify-center h-8 gap-1.5", defaultClassNames.dropdowns),
23
+ dropdown_root: cn("relative has-focus:border-grey-400 border border-grey-300 shadow-xs has-focus:ring-grey-300/50 has-focus:ring-[3px] rounded-md", defaultClassNames.dropdown_root),
24
+ dropdown: cn("absolute bg-white inset-0 opacity-0", defaultClassNames.dropdown),
25
+ caption_label: cn("select-none font-medium text-main-900", captionLayout === "label"
63
26
  ? "text-sm"
64
27
  : "rounded-md pl-2 pr-1 flex items-center gap-1 text-sm h-8 [&>svg]:text-main-400 [&>svg]:size-3.5", defaultClassNames.caption_label),
65
28
  table: "w-full border-collapse",
66
- weekdays: (0, utils_1.cn)("flex", defaultClassNames.weekdays),
67
- weekday: (0, utils_1.cn)("text-main-500 rounded-md flex-1 font-normal text-[0.8rem] select-none w-8 h-8 flex items-center justify-center", defaultClassNames.weekday),
68
- week: (0, utils_1.cn)("flex w-full mt-2", defaultClassNames.week),
69
- week_number_header: (0, utils_1.cn)("select-none w-8", defaultClassNames.week_number_header),
70
- week_number: (0, utils_1.cn)("text-[0.8rem] select-none text-main-400", defaultClassNames.week_number),
71
- day: (0, utils_1.cn)("relative w-8 h-8 p-0 text-center [&:last-child[data-selected=true]_button]:rounded-r-md group/day select-none", props.showWeekNumber
29
+ weekdays: cn("flex", defaultClassNames.weekdays),
30
+ weekday: cn("text-main-500 rounded-md flex-1 font-normal text-[0.8rem] select-none w-8 h-8 flex items-center justify-center", defaultClassNames.weekday),
31
+ week: cn("flex w-full mt-2", defaultClassNames.week),
32
+ week_number_header: cn("select-none w-8", defaultClassNames.week_number_header),
33
+ week_number: cn("text-[0.8rem] select-none text-main-400", defaultClassNames.week_number),
34
+ day: cn("relative w-8 h-8 p-0 text-center [&:last-child[data-selected=true]_button]:rounded-r-md group/day select-none", props.showWeekNumber
72
35
  ? "[&:nth-child(2)[data-selected=true]_button]:rounded-l-md"
73
36
  : "[&:first-child[data-selected=true]_button]:rounded-l-md", defaultClassNames.day),
74
- range_start: (0, utils_1.cn)("rounded-l-md bg-main-100", defaultClassNames.range_start),
75
- range_middle: (0, utils_1.cn)("rounded-none", defaultClassNames.range_middle),
76
- range_end: (0, utils_1.cn)("rounded-r-md bg-main-100", defaultClassNames.range_end),
77
- today: (0, utils_1.cn)("bg-main-100 text-main-900 rounded-md data-[selected=true]:rounded-none", defaultClassNames.today),
78
- outside: (0, utils_1.cn)("text-main-300 aria-selected:text-main-400", defaultClassNames.outside),
79
- disabled: (0, utils_1.cn)("text-main-300 opacity-50", defaultClassNames.disabled),
80
- hidden: (0, utils_1.cn)("invisible", defaultClassNames.hidden),
37
+ range_start: cn("rounded-l-md bg-main-100", defaultClassNames.range_start),
38
+ range_middle: cn("rounded-none", defaultClassNames.range_middle),
39
+ range_end: cn("rounded-r-md bg-main-100", defaultClassNames.range_end),
40
+ today: cn("bg-main-100 text-main-900 rounded-md data-[selected=true]:rounded-none", defaultClassNames.today),
41
+ outside: cn("text-main-300 aria-selected:text-main-400", defaultClassNames.outside),
42
+ disabled: cn("text-main-300 opacity-50", defaultClassNames.disabled),
43
+ hidden: cn("invisible", defaultClassNames.hidden),
81
44
  ...classNames,
82
45
  }, components: {
83
46
  Root: ({ className, rootRef, ...props }) => {
84
- return ((0, jsx_runtime_1.jsx)("div", { "data-slot": "calendar", ref: rootRef, className: (0, utils_1.cn)(className), ...props }));
47
+ return (_jsx("div", { "data-slot": "calendar", ref: rootRef, className: cn(className), ...props }));
85
48
  },
86
49
  Chevron: ({ className, orientation, ...props }) => {
87
50
  if (orientation === "left") {
88
- return ((0, jsx_runtime_1.jsx)(lucide_react_1.ChevronLeftIcon, { className: (0, utils_1.cn)("size-4", className), ...props }));
51
+ return (_jsx(ChevronLeftIcon, { className: cn("size-4", className), ...props }));
89
52
  }
90
53
  if (orientation === "right") {
91
- return ((0, jsx_runtime_1.jsx)(lucide_react_1.ChevronRightIcon, { className: (0, utils_1.cn)("size-4", className), ...props }));
54
+ return (_jsx(ChevronRightIcon, { className: cn("size-4", className), ...props }));
92
55
  }
93
- return ((0, jsx_runtime_1.jsx)(lucide_react_1.ChevronDownIcon, { className: (0, utils_1.cn)("size-4", className), ...props }));
56
+ return (_jsx(ChevronDownIcon, { className: cn("size-4", className), ...props }));
94
57
  },
95
58
  DayButton: CalendarDayButton,
96
59
  WeekNumber: ({ children, ...props }) => {
97
- return ((0, jsx_runtime_1.jsx)("td", { ...props, children: (0, jsx_runtime_1.jsx)("div", { className: "flex size-8 items-center justify-center text-center", children: children }) }));
60
+ return (_jsx("td", { ...props, children: _jsx("div", { className: "flex size-8 items-center justify-center text-center", children: children }) }));
98
61
  },
99
62
  ...components,
100
- }, ...props }), error && ((0, jsx_runtime_1.jsx)(Typography_1.Typography, { variant: "caption", color: "error-600", className: "mt-1", children: error }))] }));
63
+ }, ...props }), error && (_jsx(Typography, { variant: "caption", color: "error-600", className: "mt-1", children: error }))] }));
101
64
  }
102
65
  function CalendarDayButton({ className, day, modifiers, ...props }) {
103
- const defaultClassNames = (0, react_day_picker_1.getDefaultClassNames)();
66
+ const defaultClassNames = getDefaultClassNames();
104
67
  const ref = React.useRef(null);
105
68
  React.useEffect(() => {
106
69
  if (modifiers.focused)
107
70
  ref.current?.focus();
108
71
  }, [modifiers.focused]);
109
- return ((0, jsx_runtime_1.jsx)(Button_1.Button, { ref: ref, variant: "ghost", size: "small", "data-day": day.date.toLocaleDateString(), "data-selected-single": modifiers.selected &&
72
+ return (_jsx(Button, { ref: ref, variant: "ghost", size: "small", "data-day": day.date.toLocaleDateString(), "data-selected-single": modifiers.selected &&
110
73
  !modifiers.range_start &&
111
74
  !modifiers.range_end &&
112
- !modifiers.range_middle, "data-range-start": modifiers.range_start, "data-range-end": modifiers.range_end, "data-range-middle": modifiers.range_middle, className: (0, utils_1.cn)("size-8 p-0 font-normal", "data-[selected-single=true]:bg-main-900 data-[selected-single=true]:text-white", "data-[range-middle=true]:bg-main-100 data-[range-middle=true]:text-main-900", "data-[range-start=true]:bg-main-900 data-[range-start=true]:text-white", "data-[range-end=true]:bg-main-900 data-[range-end=true]:text-white", "group-data-[focused=true]/day:border-grey-400 group-data-[focused=true]/day:ring-grey-300/50", "hover:bg-main-100 hover:text-main-900", "group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:ring-[3px]", "data-[range-end=true]:rounded-md data-[range-end=true]:rounded-r-md", "data-[range-middle=true]:rounded-none", "data-[range-start=true]:rounded-md data-[range-start=true]:rounded-l-md", defaultClassNames.day, className), ...props }));
75
+ !modifiers.range_middle, "data-range-start": modifiers.range_start, "data-range-end": modifiers.range_end, "data-range-middle": modifiers.range_middle, className: cn("size-8 p-0 font-normal", "data-[selected-single=true]:bg-main-900 data-[selected-single=true]:text-white", "data-[range-middle=true]:bg-main-100 data-[range-middle=true]:text-main-900", "data-[range-start=true]:bg-main-900 data-[range-start=true]:text-white", "data-[range-end=true]:bg-main-900 data-[range-end=true]:text-white", "group-data-[focused=true]/day:border-grey-400 group-data-[focused=true]/day:ring-grey-300/50", "hover:bg-main-100 hover:text-main-900", "group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:ring-[3px]", "data-[range-end=true]:rounded-md data-[range-end=true]:rounded-r-md", "data-[range-middle=true]:rounded-none", "data-[range-start=true]:rounded-md data-[range-start=true]:rounded-l-md", defaultClassNames.day, className), ...props }));
113
76
  }
114
77
  Calendar.displayName = "Calendar";
78
+ export { Calendar, CalendarDayButton };
package/Card/Card.d.ts CHANGED
@@ -2,7 +2,7 @@ import * as React from "react";
2
2
  type CardVariant = "default" | "outline";
3
3
  declare const cardVariants: (props?: ({
4
4
  variant?: "default" | "outline" | null | undefined;
5
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
5
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
6
  export interface CardProps extends React.HTMLAttributes<HTMLDivElement> {
7
7
  variant?: CardVariant;
8
8
  }
package/Card/Card.js CHANGED
@@ -1,44 +1,8 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.cardVariants = exports.CardContent = exports.CardDescription = exports.CardTitle = exports.CardFooter = exports.CardHeader = exports.Card = void 0;
37
- const jsx_runtime_1 = require("react/jsx-runtime");
38
- const React = __importStar(require("react"));
39
- const class_variance_authority_1 = require("class-variance-authority");
40
- const utils_1 = require("../lib/utils");
41
- const cardVariants = (0, class_variance_authority_1.cva)("rounded-xl border bg-white text-main-950 shadow-sm", {
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ import { cva } from "class-variance-authority";
4
+ import { cn } from "../lib/utils";
5
+ const cardVariants = cva("rounded-xl border bg-white text-main-950 shadow-sm", {
42
6
  variants: {
43
7
  variant: {
44
8
  default: "border-grey-200",
@@ -49,22 +13,16 @@ const cardVariants = (0, class_variance_authority_1.cva)("rounded-xl border bg-w
49
13
  variant: "default",
50
14
  },
51
15
  });
52
- exports.cardVariants = cardVariants;
53
- const Card = React.forwardRef(({ className, variant, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)(cardVariants({ variant }), className), ...props })));
54
- exports.Card = Card;
16
+ const Card = React.forwardRef(({ className, variant, ...props }, ref) => (_jsx("div", { ref: ref, className: cn(cardVariants({ variant }), className), ...props })));
55
17
  Card.displayName = "Card";
56
- const CardHeader = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)("flex flex-col space-y-1.5 p-6", className), ...props })));
57
- exports.CardHeader = CardHeader;
18
+ const CardHeader = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("flex flex-col space-y-1.5 p-6", className), ...props })));
58
19
  CardHeader.displayName = "CardHeader";
59
- const CardTitle = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)("font-semibold leading-none tracking-tight", className), ...props })));
60
- exports.CardTitle = CardTitle;
20
+ const CardTitle = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("font-semibold leading-none tracking-tight", className), ...props })));
61
21
  CardTitle.displayName = "CardTitle";
62
- const CardDescription = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)("text-sm text-grey-500", className), ...props })));
63
- exports.CardDescription = CardDescription;
22
+ const CardDescription = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("text-sm text-grey-500", className), ...props })));
64
23
  CardDescription.displayName = "CardDescription";
65
- const CardContent = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)("p-6 pt-0", className), ...props })));
66
- exports.CardContent = CardContent;
24
+ const CardContent = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("p-6 pt-0", className), ...props })));
67
25
  CardContent.displayName = "CardContent";
68
- const CardFooter = React.forwardRef(({ className, ...props }, ref) => ((0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)("flex items-center p-6 pt-0", className), ...props })));
69
- exports.CardFooter = CardFooter;
26
+ const CardFooter = React.forwardRef(({ className, ...props }, ref) => (_jsx("div", { ref: ref, className: cn("flex items-center p-6 pt-0", className), ...props })));
70
27
  CardFooter.displayName = "CardFooter";
28
+ export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent, cardVariants };
@@ -16,13 +16,13 @@ type CarouselContextProps = {
16
16
  declare function useCarousel(): CarouselContextProps;
17
17
  declare const carouselVariants: (props?: ({
18
18
  orientation?: "horizontal" | "vertical" | null | undefined;
19
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
19
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
20
20
  declare const carouselContentVariants: (props?: ({
21
21
  orientation?: "horizontal" | "vertical" | null | undefined;
22
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
22
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
23
23
  declare const carouselItemVariants: (props?: ({
24
24
  orientation?: "horizontal" | "vertical" | null | undefined;
25
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
25
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
26
26
  interface CarouselProps {
27
27
  opts?: CarouselOptions;
28
28
  plugins?: CarouselPlugin;
@@ -32,6 +32,6 @@ interface CarouselProps {
32
32
  declare const Carousel: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & CarouselProps & React.RefAttributes<HTMLDivElement>>;
33
33
  declare const CarouselContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
34
34
  declare const CarouselItem: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
35
- declare const CarouselPrevious: React.ForwardRefExoticComponent<Omit<import("../Button/Button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
36
- declare const CarouselNext: React.ForwardRefExoticComponent<Omit<import("../Button/Button").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
35
+ declare const CarouselPrevious: React.ForwardRefExoticComponent<Omit<import("..").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
36
+ declare const CarouselNext: React.ForwardRefExoticComponent<Omit<import("..").ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
37
37
  export { Carousel, CarouselContent, CarouselItem, CarouselPrevious, CarouselNext, carouselVariants, carouselContentVariants, carouselItemVariants, useCarousel, type CarouselApi, type CarouselProps, type CarouselOptions, type CarouselPlugin, type CarouselOrientation, };
@@ -1,50 +1,10 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- var __importDefault = (this && this.__importDefault) || function (mod) {
36
- return (mod && mod.__esModule) ? mod : { "default": mod };
37
- };
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.carouselItemVariants = exports.carouselContentVariants = exports.carouselVariants = exports.CarouselNext = exports.CarouselPrevious = exports.CarouselItem = exports.CarouselContent = exports.Carousel = void 0;
40
- exports.useCarousel = useCarousel;
41
- const jsx_runtime_1 = require("react/jsx-runtime");
42
- const React = __importStar(require("react"));
43
- const embla_carousel_react_1 = __importDefault(require("embla-carousel-react"));
44
- const class_variance_authority_1 = require("class-variance-authority");
45
- const lucide_react_1 = require("lucide-react");
46
- const utils_1 = require("../lib/utils");
47
- const Button_1 = require("../Button/Button");
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ import useEmblaCarousel, {} from "embla-carousel-react";
4
+ import { cva } from "class-variance-authority";
5
+ import { ArrowLeft, ArrowRight } from "lucide-react";
6
+ import { cn } from "../lib/utils";
7
+ import { Button } from "../Button/Button";
48
8
  const CarouselContext = React.createContext(null);
49
9
  function useCarousel() {
50
10
  const context = React.useContext(CarouselContext);
@@ -53,7 +13,7 @@ function useCarousel() {
53
13
  }
54
14
  return context;
55
15
  }
56
- const carouselVariants = (0, class_variance_authority_1.cva)("relative", {
16
+ const carouselVariants = cva("relative", {
57
17
  variants: {
58
18
  orientation: {
59
19
  horizontal: "",
@@ -64,8 +24,7 @@ const carouselVariants = (0, class_variance_authority_1.cva)("relative", {
64
24
  orientation: "horizontal",
65
25
  },
66
26
  });
67
- exports.carouselVariants = carouselVariants;
68
- const carouselContentVariants = (0, class_variance_authority_1.cva)("flex", {
27
+ const carouselContentVariants = cva("flex", {
69
28
  variants: {
70
29
  orientation: {
71
30
  horizontal: "-ml-4",
@@ -76,8 +35,7 @@ const carouselContentVariants = (0, class_variance_authority_1.cva)("flex", {
76
35
  orientation: "horizontal",
77
36
  },
78
37
  });
79
- exports.carouselContentVariants = carouselContentVariants;
80
- const carouselItemVariants = (0, class_variance_authority_1.cva)("min-w-0 shrink-0 grow-0 basis-full", {
38
+ const carouselItemVariants = cva("min-w-0 shrink-0 grow-0 basis-full", {
81
39
  variants: {
82
40
  orientation: {
83
41
  horizontal: "pl-4",
@@ -88,9 +46,8 @@ const carouselItemVariants = (0, class_variance_authority_1.cva)("min-w-0 shrink
88
46
  orientation: "horizontal",
89
47
  },
90
48
  });
91
- exports.carouselItemVariants = carouselItemVariants;
92
49
  const Carousel = React.forwardRef(({ orientation = "horizontal", opts, setApi, plugins, className, children, ...props }, ref) => {
93
- const [carouselRef, api] = (0, embla_carousel_react_1.default)({
50
+ const [carouselRef, api] = useEmblaCarousel({
94
51
  ...opts,
95
52
  axis: orientation === "horizontal" ? "x" : "y",
96
53
  }, plugins);
@@ -136,7 +93,7 @@ const Carousel = React.forwardRef(({ orientation = "horizontal", opts, setApi, p
136
93
  api?.off("select", onSelect);
137
94
  };
138
95
  }, [api, onSelect]);
139
- return ((0, jsx_runtime_1.jsx)(CarouselContext.Provider, { value: {
96
+ return (_jsx(CarouselContext.Provider, { value: {
140
97
  carouselRef,
141
98
  api: api,
142
99
  opts,
@@ -145,35 +102,31 @@ const Carousel = React.forwardRef(({ orientation = "horizontal", opts, setApi, p
145
102
  scrollNext,
146
103
  canScrollPrev,
147
104
  canScrollNext,
148
- }, children: (0, jsx_runtime_1.jsx)("div", { ref: ref, onKeyDownCapture: handleKeyDown, className: (0, utils_1.cn)(carouselVariants({ orientation }), className), role: "region", "aria-roledescription": "carousel", ...props, children: children }) }));
105
+ }, children: _jsx("div", { ref: ref, onKeyDownCapture: handleKeyDown, className: cn(carouselVariants({ orientation }), className), role: "region", "aria-roledescription": "carousel", ...props, children: children }) }));
149
106
  });
150
- exports.Carousel = Carousel;
151
107
  Carousel.displayName = "Carousel";
152
108
  const CarouselContent = React.forwardRef(({ className, ...props }, ref) => {
153
109
  const { carouselRef, orientation } = useCarousel();
154
- return ((0, jsx_runtime_1.jsx)("div", { ref: carouselRef, className: "overflow-hidden", children: (0, jsx_runtime_1.jsx)("div", { ref: ref, className: (0, utils_1.cn)(carouselContentVariants({ orientation }), className), ...props }) }));
110
+ return (_jsx("div", { ref: carouselRef, className: "overflow-hidden", children: _jsx("div", { ref: ref, className: cn(carouselContentVariants({ orientation }), className), ...props }) }));
155
111
  });
156
- exports.CarouselContent = CarouselContent;
157
112
  CarouselContent.displayName = "CarouselContent";
158
113
  const CarouselItem = React.forwardRef(({ className, ...props }, ref) => {
159
114
  const { orientation } = useCarousel();
160
- return ((0, jsx_runtime_1.jsx)("div", { ref: ref, role: "group", "aria-roledescription": "slide", className: (0, utils_1.cn)(carouselItemVariants({ orientation }), className), ...props }));
115
+ return (_jsx("div", { ref: ref, role: "group", "aria-roledescription": "slide", className: cn(carouselItemVariants({ orientation }), className), ...props }));
161
116
  });
162
- exports.CarouselItem = CarouselItem;
163
117
  CarouselItem.displayName = "CarouselItem";
164
118
  const CarouselPrevious = React.forwardRef(({ className, variant = "outline", size = "small", ...props }, ref) => {
165
119
  const { orientation, scrollPrev, canScrollPrev } = useCarousel();
166
- return ((0, jsx_runtime_1.jsxs)(Button_1.Button, { ref: ref, variant: variant, size: size, roundness: "round", className: (0, utils_1.cn)("absolute h-8 w-8 p-0", orientation === "horizontal"
120
+ return (_jsxs(Button, { ref: ref, variant: variant, size: size, roundness: "round", className: cn("absolute h-8 w-8 p-0", orientation === "horizontal"
167
121
  ? "-left-12 top-1/2 -translate-y-1/2"
168
- : "-top-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollPrev, onClick: scrollPrev, ...props, children: [(0, jsx_runtime_1.jsx)(lucide_react_1.ArrowLeft, { className: "h-4 w-4" }), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "Previous slide" })] }));
122
+ : "-top-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollPrev, onClick: scrollPrev, ...props, children: [_jsx(ArrowLeft, { className: "h-4 w-4" }), _jsx("span", { className: "sr-only", children: "Previous slide" })] }));
169
123
  });
170
- exports.CarouselPrevious = CarouselPrevious;
171
124
  CarouselPrevious.displayName = "CarouselPrevious";
172
125
  const CarouselNext = React.forwardRef(({ className, variant = "outline", size = "small", ...props }, ref) => {
173
126
  const { orientation, scrollNext, canScrollNext } = useCarousel();
174
- return ((0, jsx_runtime_1.jsxs)(Button_1.Button, { ref: ref, variant: variant, size: size, roundness: "round", className: (0, utils_1.cn)("absolute h-8 w-8 p-0", orientation === "horizontal"
127
+ return (_jsxs(Button, { ref: ref, variant: variant, size: size, roundness: "round", className: cn("absolute h-8 w-8 p-0", orientation === "horizontal"
175
128
  ? "-right-12 top-1/2 -translate-y-1/2"
176
- : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollNext, onClick: scrollNext, ...props, children: [(0, jsx_runtime_1.jsx)(lucide_react_1.ArrowRight, { className: "h-4 w-4" }), (0, jsx_runtime_1.jsx)("span", { className: "sr-only", children: "Next slide" })] }));
129
+ : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90", className), disabled: !canScrollNext, onClick: scrollNext, ...props, children: [_jsx(ArrowRight, { className: "h-4 w-4" }), _jsx("span", { className: "sr-only", children: "Next slide" })] }));
177
130
  });
178
- exports.CarouselNext = CarouselNext;
179
131
  CarouselNext.displayName = "CarouselNext";
132
+ export { Carousel, CarouselContent, CarouselItem, CarouselPrevious, CarouselNext, carouselVariants, carouselContentVariants, carouselItemVariants, useCarousel, };
@@ -5,13 +5,13 @@ type ChatBubbleTheme = "dark" | "light";
5
5
  type ChatBubbleSize = "small" | "medium" | "large" | "xlarge";
6
6
  declare const chatBubbleVariants: (props?: ({
7
7
  side?: "left" | "right" | null | undefined;
8
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
8
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
9
9
  declare const bubbleContentVariants: (props?: ({
10
10
  color?: "blue" | "grey" | "green" | null | undefined;
11
11
  theme?: "dark" | "light" | null | undefined;
12
12
  side?: "left" | "right" | null | undefined;
13
13
  size?: "small" | "large" | "xlarge" | "medium" | null | undefined;
14
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
14
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
15
15
  export interface ChatBubbleProps extends React.HTMLAttributes<HTMLDivElement> {
16
16
  /** The side of the chat bubble (left for received, right for sent) */
17
17
  side?: ChatBubbleSide;
@@ -1,44 +1,8 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.bubbleContentVariants = exports.chatBubbleVariants = exports.ChatBubble = void 0;
37
- const jsx_runtime_1 = require("react/jsx-runtime");
38
- const React = __importStar(require("react"));
39
- const class_variance_authority_1 = require("class-variance-authority");
40
- const utils_1 = require("../lib/utils");
41
- const chatBubbleVariants = (0, class_variance_authority_1.cva)("flex flex-col gap-1.5 w-full", {
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ import { cva } from "class-variance-authority";
4
+ import { cn } from "../lib/utils";
5
+ const chatBubbleVariants = cva("flex flex-col gap-1.5 w-full", {
42
6
  variants: {
43
7
  side: {
44
8
  left: "items-start",
@@ -49,8 +13,7 @@ const chatBubbleVariants = (0, class_variance_authority_1.cva)("flex flex-col ga
49
13
  side: "left",
50
14
  },
51
15
  });
52
- exports.chatBubbleVariants = chatBubbleVariants;
53
- const bubbleContentVariants = (0, class_variance_authority_1.cva)("px-4 py-3 leading-normal max-w-[85%]", {
16
+ const bubbleContentVariants = cva("px-4 py-3 leading-normal max-w-[85%]", {
54
17
  variants: {
55
18
  color: {
56
19
  blue: "bg-blue-500",
@@ -114,8 +77,7 @@ const bubbleContentVariants = (0, class_variance_authority_1.cva)("px-4 py-3 lea
114
77
  size: "small",
115
78
  },
116
79
  });
117
- exports.bubbleContentVariants = bubbleContentVariants;
118
- const labelVariants = (0, class_variance_authority_1.cva)("text-sm text-neutral-400 mb-0.5", {
80
+ const labelVariants = cva("text-sm text-neutral-400 mb-0.5", {
119
81
  variants: {
120
82
  side: {
121
83
  left: "ml-3",
@@ -127,7 +89,7 @@ const labelVariants = (0, class_variance_authority_1.cva)("text-sm text-neutral-
127
89
  },
128
90
  });
129
91
  const ChatBubble = React.forwardRef(({ className, side = "left", color = "blue", theme = "dark", size = "small", children, label, showLabel = true, ...props }, ref) => {
130
- return ((0, jsx_runtime_1.jsxs)("div", { ref: ref, className: (0, utils_1.cn)(chatBubbleVariants({ side, className })), ...props, children: [showLabel && label && ((0, jsx_runtime_1.jsx)("span", { className: (0, utils_1.cn)(labelVariants({ side })), children: label })), (0, jsx_runtime_1.jsx)("div", { className: (0, utils_1.cn)(bubbleContentVariants({ color, theme, side, size })), children: children })] }));
92
+ return (_jsxs("div", { ref: ref, className: cn(chatBubbleVariants({ side, className })), ...props, children: [showLabel && label && (_jsx("span", { className: cn(labelVariants({ side })), children: label })), _jsx("div", { className: cn(bubbleContentVariants({ color, theme, side, size })), children: children })] }));
131
93
  });
132
- exports.ChatBubble = ChatBubble;
133
94
  ChatBubble.displayName = "ChatBubble";
95
+ export { ChatBubble, chatBubbleVariants, bubbleContentVariants };
@@ -3,7 +3,7 @@ import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
3
3
  type CheckboxSize = "small" | "regular";
4
4
  declare const checkboxVariants: (props?: ({
5
5
  size?: "small" | "regular" | null | undefined;
6
- } & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
6
+ } & import("class-variance-authority/types").ClassProp) | undefined) => string;
7
7
  export interface CheckboxProps extends React.ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root> {
8
8
  size?: CheckboxSize;
9
9
  }
@@ -1,46 +1,10 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || (function () {
19
- var ownKeys = function(o) {
20
- ownKeys = Object.getOwnPropertyNames || function (o) {
21
- var ar = [];
22
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
- return ar;
24
- };
25
- return ownKeys(o);
26
- };
27
- return function (mod) {
28
- if (mod && mod.__esModule) return mod;
29
- var result = {};
30
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
- __setModuleDefault(result, mod);
32
- return result;
33
- };
34
- })();
35
- Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.checkboxVariants = exports.Checkbox = void 0;
37
- const jsx_runtime_1 = require("react/jsx-runtime");
38
- const React = __importStar(require("react"));
39
- const CheckboxPrimitive = __importStar(require("@radix-ui/react-checkbox"));
40
- const lucide_react_1 = require("lucide-react");
41
- const class_variance_authority_1 = require("class-variance-authority");
42
- const utils_1 = require("../lib/utils");
43
- const checkboxVariants = (0, class_variance_authority_1.cva)("peer shrink-0 border border-grey-300 bg-white ring-offset-white focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent-600 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-accent-600 data-[state=checked]:border-accent-600 data-[state=checked]:text-white data-[state=indeterminate]:bg-accent-600 data-[state=indeterminate]:border-accent-600 data-[state=indeterminate]:text-white", {
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
4
+ import { Check, Minus } from "lucide-react";
5
+ import { cva } from "class-variance-authority";
6
+ import { cn } from "../lib/utils";
7
+ const checkboxVariants = cva("peer shrink-0 border border-grey-300 bg-white ring-offset-white focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-accent-600 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-accent-600 data-[state=checked]:border-accent-600 data-[state=checked]:text-white data-[state=indeterminate]:bg-accent-600 data-[state=indeterminate]:border-accent-600 data-[state=indeterminate]:text-white", {
44
8
  variants: {
45
9
  size: {
46
10
  small: "size-4 rounded-[4px]",
@@ -51,7 +15,6 @@ const checkboxVariants = (0, class_variance_authority_1.cva)("peer shrink-0 bord
51
15
  size: "regular",
52
16
  },
53
17
  });
54
- exports.checkboxVariants = checkboxVariants;
55
- const Checkbox = React.forwardRef(({ className, size, ...props }, ref) => ((0, jsx_runtime_1.jsx)(CheckboxPrimitive.Root, { ref: ref, className: (0, utils_1.cn)(checkboxVariants({ size }), className), ...props, children: (0, jsx_runtime_1.jsx)(CheckboxPrimitive.Indicator, { className: (0, utils_1.cn)("flex items-center justify-center text-current"), children: props.checked === "indeterminate" ? ((0, jsx_runtime_1.jsx)(lucide_react_1.Minus, { className: (0, utils_1.cn)(size === "small" ? "size-3" : "size-3.5") })) : ((0, jsx_runtime_1.jsx)(lucide_react_1.Check, { className: (0, utils_1.cn)(size === "small" ? "size-3" : "size-3.5") })) }) })));
56
- exports.Checkbox = Checkbox;
18
+ const Checkbox = React.forwardRef(({ className, size, ...props }, ref) => (_jsx(CheckboxPrimitive.Root, { ref: ref, className: cn(checkboxVariants({ size }), className), ...props, children: _jsx(CheckboxPrimitive.Indicator, { className: cn("flex items-center justify-center text-current"), children: props.checked === "indeterminate" ? (_jsx(Minus, { className: cn(size === "small" ? "size-3" : "size-3.5") })) : (_jsx(Check, { className: cn(size === "small" ? "size-3" : "size-3.5") })) }) })));
57
19
  Checkbox.displayName = CheckboxPrimitive.Root.displayName;
20
+ export { Checkbox, checkboxVariants };