@codefast/ui 0.0.12 → 0.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accordion.js +3 -9
- package/dist/accordion.js.map +1 -1
- package/dist/accordion.mjs +3 -9
- package/dist/accordion.mjs.map +1 -1
- package/dist/alert-dialog.js +6 -19
- package/dist/alert-dialog.js.map +1 -1
- package/dist/alert-dialog.mjs +4 -17
- package/dist/alert-dialog.mjs.map +1 -1
- package/dist/breadcrumb.js +1 -2
- package/dist/breadcrumb.js.map +1 -1
- package/dist/breadcrumb.mjs +1 -2
- package/dist/breadcrumb.mjs.map +1 -1
- package/dist/button.js +3 -3
- package/dist/button.mjs +2 -2
- package/dist/calendar.js +4 -4
- package/dist/calendar.mjs +2 -2
- package/dist/carousel.js +4 -4
- package/dist/carousel.mjs +2 -2
- package/dist/checkbox-cards.js +2 -6
- package/dist/checkbox-cards.js.map +1 -1
- package/dist/checkbox-cards.mjs +2 -6
- package/dist/checkbox-cards.mjs.map +1 -1
- package/dist/checkbox-group.js +1 -5
- package/dist/checkbox-group.js.map +1 -1
- package/dist/checkbox-group.mjs +1 -5
- package/dist/checkbox-group.mjs.map +1 -1
- package/dist/checkbox.js +1 -5
- package/dist/checkbox.js.map +1 -1
- package/dist/checkbox.mjs +1 -5
- package/dist/checkbox.mjs.map +1 -1
- package/dist/{chunk-V2254PQL.mjs → chunk-73S45XV3.mjs} +2 -5
- package/dist/chunk-73S45XV3.mjs.map +1 -0
- package/dist/{chunk-7S4DOWLB.js → chunk-AOIW2XNK.js} +2 -8
- package/dist/chunk-AOIW2XNK.js.map +1 -0
- package/dist/{chunk-6J6VPUBP.mjs → chunk-AUQEMOIM.mjs} +2 -8
- package/dist/chunk-AUQEMOIM.mjs.map +1 -0
- package/dist/{chunk-OK63Q6EJ.mjs → chunk-BBQXHKST.mjs} +2 -3
- package/dist/chunk-BBQXHKST.mjs.map +1 -0
- package/dist/{chunk-LNSEYAPJ.js → chunk-OSFYUOPN.js} +2 -3
- package/dist/chunk-OSFYUOPN.js.map +1 -0
- package/dist/{chunk-BWCO2ZQQ.js → chunk-TFYKPLNV.js} +4 -8
- package/dist/chunk-TFYKPLNV.js.map +1 -0
- package/dist/{chunk-IXEJO7ZP.js → chunk-TH24V27M.js} +7 -26
- package/dist/chunk-TH24V27M.js.map +1 -0
- package/dist/{chunk-XCKLBP2V.mjs → chunk-TXRIFICH.mjs} +7 -26
- package/dist/chunk-TXRIFICH.mjs.map +1 -0
- package/dist/{chunk-WFXEFJRB.mjs → chunk-U6VR5RJ5.mjs} +3 -7
- package/dist/chunk-U6VR5RJ5.mjs.map +1 -0
- package/dist/{chunk-MDSPK3M6.js → chunk-Y3DZHPJ5.js} +2 -5
- package/dist/chunk-Y3DZHPJ5.js.map +1 -0
- package/dist/command.d.mts +2 -2
- package/dist/command.d.ts +2 -2
- package/dist/command.js +2 -2
- package/dist/command.mjs +1 -1
- package/dist/data-table.js +12 -12
- package/dist/data-table.mjs +3 -3
- package/dist/dialog.js +2 -2
- package/dist/dialog.mjs +1 -1
- package/dist/input-otp.js +1 -1
- package/dist/input-otp.js.map +1 -1
- package/dist/input-otp.mjs +1 -1
- package/dist/input-otp.mjs.map +1 -1
- package/dist/input.js +1 -7
- package/dist/input.js.map +1 -1
- package/dist/input.mjs +1 -7
- package/dist/input.mjs.map +1 -1
- package/dist/navigation-menu.js +2 -3
- package/dist/navigation-menu.js.map +1 -1
- package/dist/navigation-menu.mjs +2 -3
- package/dist/navigation-menu.mjs.map +1 -1
- package/dist/pagination.js +3 -3
- package/dist/pagination.mjs +2 -2
- package/dist/radio-cards.js +1 -5
- package/dist/radio-cards.js.map +1 -1
- package/dist/radio-cards.mjs +1 -5
- package/dist/radio-cards.mjs.map +1 -1
- package/dist/radio-group.js +2 -10
- package/dist/radio-group.js.map +1 -1
- package/dist/radio-group.mjs +2 -10
- package/dist/radio-group.mjs.map +1 -1
- package/dist/radio.js +1 -7
- package/dist/radio.js.map +1 -1
- package/dist/radio.mjs +1 -7
- package/dist/radio.mjs.map +1 -1
- package/dist/resizable.js +1 -2
- package/dist/resizable.js.map +1 -1
- package/dist/resizable.mjs +1 -2
- package/dist/resizable.mjs.map +1 -1
- package/dist/select.js +2 -2
- package/dist/select.mjs +1 -1
- package/dist/sheet.js +6 -22
- package/dist/sheet.js.map +1 -1
- package/dist/sheet.mjs +6 -22
- package/dist/sheet.mjs.map +1 -1
- package/dist/slider.js +7 -8
- package/dist/slider.js.map +1 -1
- package/dist/slider.mjs +6 -7
- package/dist/slider.mjs.map +1 -1
- package/dist/spinner.js +2 -2
- package/dist/spinner.mjs +1 -1
- package/dist/styles.css +1 -1
- package/dist/styles.css.map +1 -1
- package/dist/switch.js +1 -2
- package/dist/switch.js.map +1 -1
- package/dist/switch.mjs +1 -2
- package/dist/switch.mjs.map +1 -1
- package/dist/tabs.js +2 -4
- package/dist/tabs.js.map +1 -1
- package/dist/tabs.mjs +2 -4
- package/dist/tabs.mjs.map +1 -1
- package/dist/textarea.js +1 -2
- package/dist/textarea.js.map +1 -1
- package/dist/textarea.mjs +1 -2
- package/dist/textarea.mjs.map +1 -1
- package/dist/toggle-group.js +2 -2
- package/dist/toggle-group.mjs +1 -1
- package/dist/toggle.js +2 -2
- package/dist/toggle.mjs +1 -1
- package/package.json +3 -6
- package/src/accordion.tsx +3 -9
- package/src/alert-dialog.tsx +2 -12
- package/src/breadcrumb.tsx +1 -2
- package/src/button.tsx +1 -5
- package/src/checkbox-cards.tsx +2 -6
- package/src/checkbox-group.tsx +1 -5
- package/src/checkbox.tsx +1 -5
- package/src/dialog.tsx +3 -15
- package/src/input-otp.tsx +1 -1
- package/src/input.tsx +1 -7
- package/src/navigation-menu.tsx +3 -3
- package/src/radio-cards.tsx +1 -5
- package/src/radio-group.tsx +2 -7
- package/src/radio.tsx +1 -7
- package/src/resizable.tsx +1 -2
- package/src/select.tsx +1 -2
- package/src/sheet.tsx +3 -12
- package/src/slider.tsx +9 -6
- package/src/spinner.tsx +1 -4
- package/src/switch.tsx +1 -2
- package/src/tabs.tsx +2 -4
- package/src/textarea.tsx +1 -2
- package/src/toggle.tsx +1 -7
- package/tailwind.config.ts +4 -1
- package/dist/chunk-6J6VPUBP.mjs.map +0 -1
- package/dist/chunk-7S4DOWLB.js.map +0 -1
- package/dist/chunk-BWCO2ZQQ.js.map +0 -1
- package/dist/chunk-IXEJO7ZP.js.map +0 -1
- package/dist/chunk-LNSEYAPJ.js.map +0 -1
- package/dist/chunk-MDSPK3M6.js.map +0 -1
- package/dist/chunk-OK63Q6EJ.mjs.map +0 -1
- package/dist/chunk-V2254PQL.mjs.map +0 -1
- package/dist/chunk-WFXEFJRB.mjs.map +0 -1
- package/dist/chunk-XCKLBP2V.mjs.map +0 -1
package/dist/command.d.mts
CHANGED
|
@@ -28,7 +28,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
|
|
|
28
28
|
ref?: React.Ref<HTMLInputElement> | undefined;
|
|
29
29
|
} & {
|
|
30
30
|
asChild?: boolean | undefined;
|
|
31
|
-
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "
|
|
31
|
+
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "type" | "value"> & {
|
|
32
32
|
value?: string | undefined;
|
|
33
33
|
onValueChange?: ((search: string) => void) | undefined;
|
|
34
34
|
} & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -77,7 +77,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
|
|
|
77
77
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
78
78
|
} & {
|
|
79
79
|
asChild?: boolean | undefined;
|
|
80
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "
|
|
80
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
|
|
81
81
|
disabled?: boolean | undefined;
|
|
82
82
|
onSelect?: ((value: string) => void) | undefined;
|
|
83
83
|
value?: string | undefined;
|
package/dist/command.d.ts
CHANGED
|
@@ -28,7 +28,7 @@ declare const CommandInput: React.ForwardRefExoticComponent<Omit<Omit<Pick<Pick<
|
|
|
28
28
|
ref?: React.Ref<HTMLInputElement> | undefined;
|
|
29
29
|
} & {
|
|
30
30
|
asChild?: boolean | undefined;
|
|
31
|
-
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "
|
|
31
|
+
}, "key" | "asChild" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "onChange" | "type" | "value"> & {
|
|
32
32
|
value?: string | undefined;
|
|
33
33
|
onValueChange?: ((search: string) => void) | undefined;
|
|
34
34
|
} & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
|
|
@@ -77,7 +77,7 @@ declare const CommandItem: React.ForwardRefExoticComponent<Omit<{
|
|
|
77
77
|
ref?: React.Ref<HTMLDivElement> | undefined;
|
|
78
78
|
} & {
|
|
79
79
|
asChild?: boolean | undefined;
|
|
80
|
-
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "
|
|
80
|
+
}, "key" | "asChild" | keyof React.HTMLAttributes<HTMLDivElement>>, "onSelect" | "disabled" | "value"> & {
|
|
81
81
|
disabled?: boolean | undefined;
|
|
82
82
|
onSelect?: ((value: string) => void) | undefined;
|
|
83
83
|
value?: string | undefined;
|
package/dist/command.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkTH24V27Mjs = require('./chunk-TH24V27M.js');
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
|
|
@@ -25,7 +25,7 @@ var Command = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */
|
|
|
25
25
|
));
|
|
26
26
|
Command.displayName = _cmdk.Command.displayName;
|
|
27
27
|
function CommandDialog({ children, ...props }) {
|
|
28
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
28
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTH24V27Mjs.Dialog, { ...props, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTH24V27Mjs.DialogContent, { className: "p-0", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Command, { className: "[&_[cmdk-group-heading]]:text-muted-foreground focus:outline-none [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:size-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:size-5", children }) }) });
|
|
29
29
|
}
|
|
30
30
|
var CommandInput = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2 border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
31
31
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.MagnifyingGlassIcon, { className: "size-4 shrink-0 opacity-50" }),
|
package/dist/command.mjs
CHANGED
package/dist/data-table.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkOSFYUOPNjs = require('./chunk-OSFYUOPN.js');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
@@ -17,8 +17,8 @@ var _chunkLNSEYAPJjs = require('./chunk-LNSEYAPJ.js');
|
|
|
17
17
|
var _chunk3ZZ3SRTJjs = require('./chunk-3ZZ3SRTJ.js');
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
21
|
-
require('./chunk-
|
|
20
|
+
var _chunkTFYKPLNVjs = require('./chunk-TFYKPLNV.js');
|
|
21
|
+
require('./chunk-Y3DZHPJ5.js');
|
|
22
22
|
|
|
23
23
|
|
|
24
24
|
var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
|
|
@@ -39,7 +39,7 @@ var _reacttable = require('@tanstack/react-table'); _createStarExport(_reacttabl
|
|
|
39
39
|
var _jsxruntime = require('react/jsx-runtime');
|
|
40
40
|
function DataTableViewOptions({ table }) {
|
|
41
41
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenu, { children: [
|
|
42
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
42
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkTFYKPLNVjs.Button, { variant: "outline", size: "sm", className: "ml-auto hidden h-8 lg:flex", children: [
|
|
43
43
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reacticons.MixerHorizontalIcon, { className: "mr-2 size-4" }),
|
|
44
44
|
"View"
|
|
45
45
|
] }) }),
|
|
@@ -79,15 +79,15 @@ function DataTablePagination({
|
|
|
79
79
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center space-x-2", children: [
|
|
80
80
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-sm font-medium", children: "Rows per page" }),
|
|
81
81
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
82
|
-
|
|
82
|
+
_chunkOSFYUOPNjs.Select,
|
|
83
83
|
{
|
|
84
84
|
value: `${table.getState().pagination.pageSize}`,
|
|
85
85
|
onValueChange: (value) => {
|
|
86
86
|
table.setPageSize(Number(value));
|
|
87
87
|
},
|
|
88
88
|
children: [
|
|
89
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
90
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
89
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectTrigger, { className: "h-8 w-[70px]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectValue, { placeholder: table.getState().pagination.pageSize }) }),
|
|
90
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectContent, { side: "top", children: [10, 20, 30, 40, 50].map((pageSize) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOSFYUOPNjs.SelectItem, { value: `${pageSize}`, children: pageSize }, pageSize)) })
|
|
91
91
|
]
|
|
92
92
|
}
|
|
93
93
|
)
|
|
@@ -100,7 +100,7 @@ function DataTablePagination({
|
|
|
100
100
|
] }),
|
|
101
101
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center space-x-2", children: [
|
|
102
102
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
103
|
-
|
|
103
|
+
_chunkTFYKPLNVjs.Button,
|
|
104
104
|
{
|
|
105
105
|
variant: "outline",
|
|
106
106
|
size: "icon-xs",
|
|
@@ -116,7 +116,7 @@ function DataTablePagination({
|
|
|
116
116
|
}
|
|
117
117
|
),
|
|
118
118
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
119
|
-
|
|
119
|
+
_chunkTFYKPLNVjs.Button,
|
|
120
120
|
{
|
|
121
121
|
variant: "outline",
|
|
122
122
|
size: "icon-xs",
|
|
@@ -131,7 +131,7 @@ function DataTablePagination({
|
|
|
131
131
|
}
|
|
132
132
|
),
|
|
133
133
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
134
|
-
|
|
134
|
+
_chunkTFYKPLNVjs.Button,
|
|
135
135
|
{
|
|
136
136
|
variant: "outline",
|
|
137
137
|
size: "icon-xs",
|
|
@@ -146,7 +146,7 @@ function DataTablePagination({
|
|
|
146
146
|
}
|
|
147
147
|
),
|
|
148
148
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
149
|
-
|
|
149
|
+
_chunkTFYKPLNVjs.Button,
|
|
150
150
|
{
|
|
151
151
|
variant: "outline",
|
|
152
152
|
size: "icon-xs",
|
|
@@ -174,7 +174,7 @@ function DataTableColumnHeader({
|
|
|
174
174
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _chunkG3NP7M2Njs.cn.call(void 0, className), children: title });
|
|
175
175
|
}
|
|
176
176
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: _chunkG3NP7M2Njs.cn.call(void 0, "flex items-center space-x-2", className), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenu, { children: [
|
|
177
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
177
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk3ZZ3SRTJjs.DropdownMenuTrigger, { asChild: true, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkTFYKPLNVjs.Button, { variant: "ghost", size: "xs", className: "data-[state=open]:bg-accent -ml-3", children: [
|
|
178
178
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { children: title }),
|
|
179
179
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, SortIcon, { sorted: column.getIsSorted() })
|
|
180
180
|
] }) }),
|
package/dist/data-table.mjs
CHANGED
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
SelectItem,
|
|
6
6
|
SelectTrigger,
|
|
7
7
|
SelectValue
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-BBQXHKST.mjs";
|
|
9
9
|
import {
|
|
10
10
|
DropdownMenu,
|
|
11
11
|
DropdownMenuCheckboxItem,
|
|
@@ -17,8 +17,8 @@ import {
|
|
|
17
17
|
} from "./chunk-EWS3N4OZ.mjs";
|
|
18
18
|
import {
|
|
19
19
|
Button
|
|
20
|
-
} from "./chunk-
|
|
21
|
-
import "./chunk-
|
|
20
|
+
} from "./chunk-U6VR5RJ5.mjs";
|
|
21
|
+
import "./chunk-73S45XV3.mjs";
|
|
22
22
|
import {
|
|
23
23
|
cn
|
|
24
24
|
} from "./chunk-UG3URV2Z.mjs";
|
package/dist/dialog.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkTH24V27Mjs = require('./chunk-TH24V27M.js');
|
|
12
12
|
require('./chunk-G3NP7M2N.js');
|
|
13
13
|
|
|
14
14
|
|
|
@@ -19,5 +19,5 @@ require('./chunk-G3NP7M2N.js');
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
exports.Dialog =
|
|
22
|
+
exports.Dialog = _chunkTH24V27Mjs.Dialog; exports.DialogClose = _chunkTH24V27Mjs.DialogClose; exports.DialogContent = _chunkTH24V27Mjs.DialogContent; exports.DialogDescription = _chunkTH24V27Mjs.DialogDescription; exports.DialogFooter = _chunkTH24V27Mjs.DialogFooter; exports.DialogHeader = _chunkTH24V27Mjs.DialogHeader; exports.DialogTitle = _chunkTH24V27Mjs.DialogTitle; exports.DialogTrigger = _chunkTH24V27Mjs.DialogTrigger;
|
|
23
23
|
//# sourceMappingURL=dialog.js.map
|
package/dist/dialog.mjs
CHANGED
package/dist/input-otp.js
CHANGED
|
@@ -43,7 +43,7 @@ var InputOTPSlot = React.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
43
43
|
...props,
|
|
44
44
|
children: [
|
|
45
45
|
_optionalChain([slot, 'optionalAccess', _2 => _2.char]),
|
|
46
|
-
_optionalChain([slot, 'optionalAccess', _3 => _3.hasFakeCaret]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "animate-caret-blink bg-foreground h-4 w-px
|
|
46
|
+
_optionalChain([slot, 'optionalAccess', _3 => _3.hasFakeCaret]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "animate-caret-blink bg-foreground animation-duration-1000 h-4 w-px" }) }) : null
|
|
47
47
|
]
|
|
48
48
|
}
|
|
49
49
|
);
|
package/dist/input-otp.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/input-otp.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,qBAAqB;AAC9B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAYH,cAuCA,YAvCA;AAFJ,IAAM,WAAiB;AAAA,EACrB,CAAC,EAAE,WAAW,oBAAoB,GAAG,MAAM,GAAG,QAC5C;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,oBAAoB,GAAG,sDAAsD,kBAAkB;AAAA,MAC/F,WAAW,GAAG,+BAA+B,SAAS;AAAA,MACrD,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,cAAc;AASvB,IAAM,gBAAsB,iBAAqD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACzG,oBAAC,SAAI,KAAU,WAAW,GAAG,qBAAqB,SAAS,GAAI,GAAG,OAAO,CAC1E;AAED,cAAc,cAAc;AAY5B,IAAM,eAAqB,iBAAmD,CAAC,EAAE,OAAO,WAAW,GAAG,MAAM,GAAG,QAAQ;AACrH,QAAM,kBAAwB,iBAAW,eAAe;AACxD,QAAM,OAAO,gBAAgB,MAAM,KAAK;AAExC,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA,MAAM,YAAY;AAAA,QAClB;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH;AAAA,cAAM;AAAA,QACN,MAAM,eACL,oBAAC,SAAI,WAAU,yEACb,8BAAC,SAAI,WAAU,
|
|
1
|
+
{"version":3,"sources":["../src/input-otp.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,qBAAqB;AAC9B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAYH,cAuCA,YAvCA;AAFJ,IAAM,WAAiB;AAAA,EACrB,CAAC,EAAE,WAAW,oBAAoB,GAAG,MAAM,GAAG,QAC5C;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,oBAAoB,GAAG,sDAAsD,kBAAkB;AAAA,MAC/F,WAAW,GAAG,+BAA+B,SAAS;AAAA,MACrD,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,cAAc;AASvB,IAAM,gBAAsB,iBAAqD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACzG,oBAAC,SAAI,KAAU,WAAW,GAAG,qBAAqB,SAAS,GAAI,GAAG,OAAO,CAC1E;AAED,cAAc,cAAc;AAY5B,IAAM,eAAqB,iBAAmD,CAAC,EAAE,OAAO,WAAW,GAAG,MAAM,GAAG,QAAQ;AACrH,QAAM,kBAAwB,iBAAW,eAAe;AACxD,QAAM,OAAO,gBAAgB,MAAM,KAAK;AAExC,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA,MAAM,YAAY;AAAA,QAClB;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH;AAAA,cAAM;AAAA,QACN,MAAM,eACL,oBAAC,SAAI,WAAU,yEACb,8BAAC,SAAI,WAAU,sEAAqE,GACtF,IACE;AAAA;AAAA;AAAA,EACN;AAEJ,CAAC;AAED,aAAa,cAAc;AAS3B,IAAM,oBAA0B,iBAA6D,CAAC,EAAE,GAAG,MAAM,GAAG,QAC1G,oBAAC,SAAI,KAAU,MAAK,aAAa,GAAG,OAClC,8BAAC,iBAAc,GACjB,CACD;AAED,kBAAkB,cAAc","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { DotFilledIcon } from \"@radix-ui/react-icons\";\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from \"input-otp\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn(\"flex items-center gap-2 has-[:disabled]:opacity-50\", containerClassName)}\n className={cn(\"disabled:cursor-not-allowed\", className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = \"InputOTP\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<InputOTPGroupElement, InputOTPGroupProps>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"flex items-center\", className)} {...props} />\n));\n\nInputOTPGroup.displayName = \"InputOTPGroup\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n \"border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md\",\n slot?.isActive && \"ring-ring z-10 ring-2\",\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animation-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n});\n\nInputOTPSlot.displayName = \"InputOTPSlot\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<InputOTPSeparatorElement, InputOTPSeparatorProps>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = \"InputOTPSeparator\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"]}
|
package/dist/input-otp.mjs
CHANGED
|
@@ -43,7 +43,7 @@ var InputOTPSlot = React.forwardRef(({ index, className, ...props }, ref) => {
|
|
|
43
43
|
...props,
|
|
44
44
|
children: [
|
|
45
45
|
slot?.char,
|
|
46
|
-
slot?.hasFakeCaret ? /* @__PURE__ */ jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx("div", { className: "animate-caret-blink bg-foreground h-4 w-px
|
|
46
|
+
slot?.hasFakeCaret ? /* @__PURE__ */ jsx("div", { className: "pointer-events-none absolute inset-0 flex items-center justify-center", children: /* @__PURE__ */ jsx("div", { className: "animate-caret-blink bg-foreground animation-duration-1000 h-4 w-px" }) }) : null
|
|
47
47
|
]
|
|
48
48
|
}
|
|
49
49
|
);
|
package/dist/input-otp.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/input-otp.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { DotFilledIcon } from \"@radix-ui/react-icons\";\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from \"input-otp\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn(\"flex items-center gap-2 has-[:disabled]:opacity-50\", containerClassName)}\n className={cn(\"disabled:cursor-not-allowed\", className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = \"InputOTP\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<InputOTPGroupElement, InputOTPGroupProps>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"flex items-center\", className)} {...props} />\n));\n\nInputOTPGroup.displayName = \"InputOTPGroup\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n \"border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md\",\n slot?.isActive && \"ring-ring z-10 ring-2\",\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground h-4 w-px
|
|
1
|
+
{"version":3,"sources":["../src/input-otp.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { DotFilledIcon } from \"@radix-ui/react-icons\";\nimport {\n OTPInput,\n OTPInputContext,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n} from \"input-otp\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOtp\n * -------------------------------------------------------------------------- */\n\ntype InputOTPElement = React.ElementRef<typeof OTPInput>;\ntype InputOTPProps = React.ComponentPropsWithoutRef<typeof OTPInput>;\n\nconst InputOTP = React.forwardRef<InputOTPElement, InputOTPProps>(\n ({ className, containerClassName, ...props }, ref) => (\n <OTPInput\n ref={ref}\n containerClassName={cn(\"flex items-center gap-2 has-[:disabled]:opacity-50\", containerClassName)}\n className={cn(\"disabled:cursor-not-allowed\", className)}\n {...props}\n />\n ),\n);\n\nInputOTP.displayName = \"InputOTP\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPGroup\n * -------------------------------------------------------------------------- */\n\ntype InputOTPGroupElement = HTMLDivElement;\ntype InputOTPGroupProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPGroup = React.forwardRef<InputOTPGroupElement, InputOTPGroupProps>(({ className, ...props }, ref) => (\n <div ref={ref} className={cn(\"flex items-center\", className)} {...props} />\n));\n\nInputOTPGroup.displayName = \"InputOTPGroup\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSlot\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSlotElement = HTMLDivElement;\n\ninterface InputOTPSlotProps extends React.HTMLAttributes<HTMLDivElement> {\n index: number;\n}\n\nconst InputOTPSlot = React.forwardRef<InputOTPSlotElement, InputOTPSlotProps>(({ index, className, ...props }, ref) => {\n const inputOTPContext = React.useContext(OTPInputContext);\n const slot = inputOTPContext.slots[index];\n\n return (\n <div\n ref={ref}\n className={cn(\n \"border-input relative flex size-10 items-center justify-center border-y border-r text-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md\",\n slot?.isActive && \"ring-ring z-10 ring-2\",\n className,\n )}\n {...props}\n >\n {slot?.char}\n {slot?.hasFakeCaret ? (\n <div className=\"pointer-events-none absolute inset-0 flex items-center justify-center\">\n <div className=\"animate-caret-blink bg-foreground animation-duration-1000 h-4 w-px\" />\n </div>\n ) : null}\n </div>\n );\n});\n\nInputOTPSlot.displayName = \"InputOTPSlot\";\n\n/* -----------------------------------------------------------------------------\n * Component: InputOTPSeparator\n * -------------------------------------------------------------------------- */\n\ntype InputOTPSeparatorElement = HTMLDivElement;\ntype InputOTPSeparatorProps = React.HTMLAttributes<HTMLDivElement>;\n\nconst InputOTPSeparator = React.forwardRef<InputOTPSeparatorElement, InputOTPSeparatorProps>(({ ...props }, ref) => (\n <div ref={ref} role=\"separator\" {...props}>\n <DotFilledIcon />\n </div>\n));\n\nInputOTPSeparator.displayName = \"InputOTPSeparator\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator,\n type InputOTPProps,\n type InputOTPGroupProps,\n type InputOTPSlotProps,\n type InputOTPSeparatorProps,\n REGEXP_ONLY_DIGITS_AND_CHARS,\n REGEXP_ONLY_CHARS,\n REGEXP_ONLY_DIGITS,\n};\n"],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,qBAAqB;AAC9B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAYH,cAuCA,YAvCA;AAFJ,IAAM,WAAiB;AAAA,EACrB,CAAC,EAAE,WAAW,oBAAoB,GAAG,MAAM,GAAG,QAC5C;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,oBAAoB,GAAG,sDAAsD,kBAAkB;AAAA,MAC/F,WAAW,GAAG,+BAA+B,SAAS;AAAA,MACrD,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,SAAS,cAAc;AASvB,IAAM,gBAAsB,iBAAqD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACzG,oBAAC,SAAI,KAAU,WAAW,GAAG,qBAAqB,SAAS,GAAI,GAAG,OAAO,CAC1E;AAED,cAAc,cAAc;AAY5B,IAAM,eAAqB,iBAAmD,CAAC,EAAE,OAAO,WAAW,GAAG,MAAM,GAAG,QAAQ;AACrH,QAAM,kBAAwB,iBAAW,eAAe;AACxD,QAAM,OAAO,gBAAgB,MAAM,KAAK;AAExC,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA,MAAM,YAAY;AAAA,QAClB;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEH;AAAA,cAAM;AAAA,QACN,MAAM,eACL,oBAAC,SAAI,WAAU,yEACb,8BAAC,SAAI,WAAU,sEAAqE,GACtF,IACE;AAAA;AAAA;AAAA,EACN;AAEJ,CAAC;AAED,aAAa,cAAc;AAS3B,IAAM,oBAA0B,iBAA6D,CAAC,EAAE,GAAG,MAAM,GAAG,QAC1G,oBAAC,SAAI,KAAU,MAAK,aAAa,GAAG,OAClC,8BAAC,iBAAc,GACjB,CACD;AAED,kBAAkB,cAAc;","names":[]}
|
package/dist/input.js
CHANGED
|
@@ -6,13 +6,7 @@ var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
|
|
|
6
6
|
var _react = require('react'); var React = _interopRequireWildcard(_react);
|
|
7
7
|
var _jsxruntime = require('react/jsx-runtime');
|
|
8
8
|
var inputVariants = _chunkG3NP7M2Njs.cva.call(void 0, {
|
|
9
|
-
base:
|
|
10
|
-
"border-input flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors",
|
|
11
|
-
"file:border-0 file:bg-transparent file:text-sm file:font-medium",
|
|
12
|
-
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
13
|
-
"placeholder:text-muted-foreground",
|
|
14
|
-
"focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2"
|
|
15
|
-
],
|
|
9
|
+
base: "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
|
|
16
10
|
variants: {
|
|
17
11
|
inputSize: {
|
|
18
12
|
default: "h-10",
|
package/dist/input.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/input.tsx"],"names":[],"mappings":";;;;;AAAA,YAAY,WAAW;
|
|
1
|
+
{"version":3,"sources":["../src/input.tsx"],"names":[],"mappings":";;;;;AAAA,YAAY,WAAW;AAiCd;AAzBT,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,WAAW;AAAA,MACT,SAAS;AAAA,MACT,IAAI;AAAA,MACJ,IAAI;AAAA,MACJ,IAAI;AAAA,IACN;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,WAAW;AAAA,EACb;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,WAAW,GAAG,MAAM,GAAG,QAAQ;AACpG,SAAO,oBAAC,WAAM,MAAK,QAAO,WAAW,cAAc,EAAE,WAAW,UAAU,CAAC,GAAG,KAAW,GAAG,OAAO;AACrG,CAAC;AAED,MAAM,cAAc","sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: \"border-input placeholder:text-muted-foreground focus-visible:ring-ring flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50\",\n variants: {\n inputSize: {\n default: \"h-10\",\n xs: \"h-8\",\n sm: \"h-9\",\n lg: \"h-11\",\n },\n },\n defaultVariants: {\n inputSize: \"default\",\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> & InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(({ className, inputSize, ...props }, ref) => {\n return <input type=\"text\" className={inputVariants({ className, inputSize })} ref={ref} {...props} />;\n});\n\nInput.displayName = \"Input\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"]}
|
package/dist/input.mjs
CHANGED
|
@@ -6,13 +6,7 @@ import {
|
|
|
6
6
|
import * as React from "react";
|
|
7
7
|
import { jsx } from "react/jsx-runtime";
|
|
8
8
|
var inputVariants = cva({
|
|
9
|
-
base:
|
|
10
|
-
"border-input flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors",
|
|
11
|
-
"file:border-0 file:bg-transparent file:text-sm file:font-medium",
|
|
12
|
-
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
13
|
-
"placeholder:text-muted-foreground",
|
|
14
|
-
"focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2"
|
|
15
|
-
],
|
|
9
|
+
base: "border-input placeholder:text-muted-foreground focus-visible:ring-ring flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
|
|
16
10
|
variants: {
|
|
17
11
|
inputSize: {
|
|
18
12
|
default: "h-10",
|
package/dist/input.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/input.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base:
|
|
1
|
+
{"version":3,"sources":["../src/input.tsx"],"sourcesContent":["import * as React from \"react\";\nimport { type VariantProps } from \"cva\";\nimport { cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: Input\n * -------------------------------------------------------------------------- */\n\nconst inputVariants = cva({\n base: \"border-input placeholder:text-muted-foreground focus-visible:ring-ring flex w-full rounded-md border bg-transparent px-3 py-2 text-sm shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50\",\n variants: {\n inputSize: {\n default: \"h-10\",\n xs: \"h-8\",\n sm: \"h-9\",\n lg: \"h-11\",\n },\n },\n defaultVariants: {\n inputSize: \"default\",\n },\n});\n\ntype InputVariantsProps = VariantProps<typeof inputVariants>;\n\n/* -----------------------------------------------------------------------------\n * Component: Input\n * -------------------------------------------------------------------------- */\n\ntype InputElement = HTMLInputElement;\ntype InputProps = React.InputHTMLAttributes<HTMLInputElement> & InputVariantsProps;\n\nconst Input = React.forwardRef<InputElement, InputProps>(({ className, inputSize, ...props }, ref) => {\n return <input type=\"text\" className={inputVariants({ className, inputSize })} ref={ref} {...props} />;\n});\n\nInput.displayName = \"Input\";\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { Input, type InputProps };\n"],"mappings":";;;;;AAAA,YAAY,WAAW;AAiCd;AAzBT,IAAM,gBAAgB,IAAI;AAAA,EACxB,MAAM;AAAA,EACN,UAAU;AAAA,IACR,WAAW;AAAA,MACT,SAAS;AAAA,MACT,IAAI;AAAA,MACJ,IAAI;AAAA,MACJ,IAAI;AAAA,IACN;AAAA,EACF;AAAA,EACA,iBAAiB;AAAA,IACf,WAAW;AAAA,EACb;AACF,CAAC;AAWD,IAAM,QAAc,iBAAqC,CAAC,EAAE,WAAW,WAAW,GAAG,MAAM,GAAG,QAAQ;AACpG,SAAO,oBAAC,WAAM,MAAK,QAAO,WAAW,cAAc,EAAE,WAAW,UAAU,CAAC,GAAG,KAAW,GAAG,OAAO;AACrG,CAAC;AAED,MAAM,cAAc;","names":[]}
|
package/dist/navigation-menu.js
CHANGED
|
@@ -50,11 +50,10 @@ var NavigationMenuTrigger = React.forwardRef(
|
|
|
50
50
|
...props,
|
|
51
51
|
children: [
|
|
52
52
|
children,
|
|
53
|
-
" ",
|
|
54
53
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
55
54
|
_reacticons.ChevronDownIcon,
|
|
56
55
|
{
|
|
57
|
-
className: _chunkG3NP7M2Njs.cn.call(void 0, "relative top-px ml-1
|
|
56
|
+
className: _chunkG3NP7M2Njs.cn.call(void 0, "relative top-px ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180"),
|
|
58
57
|
"aria-hidden": "true"
|
|
59
58
|
}
|
|
60
59
|
)
|
|
@@ -83,7 +82,7 @@ var NavigationMenuViewport = React.forwardRef(
|
|
|
83
82
|
NavigationMenuPrimitive.Viewport,
|
|
84
83
|
{
|
|
85
84
|
className: _chunkG3NP7M2Njs.cn.call(void 0,
|
|
86
|
-
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow md:w-[var(--radix-navigation-menu-viewport-width)]",
|
|
85
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow transition-[width,height] duration-200 md:w-[var(--radix-navigation-menu-viewport-width)]",
|
|
87
86
|
className
|
|
88
87
|
),
|
|
89
88
|
ref,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/navigation-menu.tsx"],"names":[],"mappings":";;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,uBAAuB;AAChC,YAAY,6BAA6B;AAoBrC,SAME,KANF;AAbJ,IAAM,gCAAgC,IAAI;AAAA,EACxC,MAAM;AACR,CAAC;AASD,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,mEAAmE,SAAS;AAAA,MACzF,GAAG;AAAA,MAEH;AAAA;AAAA,QACD,oBAAC,0BAAuB;AAAA;AAAA;AAAA,EAC1B;AAEJ;AAEA,eAAe,cAAsC,6BAAK;AAS1D,IAAM,qBAA2B;AAAA,EAC/B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,qEAAqE,SAAS;AAAA,MAC3F,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,mBAAmB,cAAsC,6BAAK;AAQ9D,IAAM,qBAA6C;AASnD,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,8BAA8B;AAAA,QACvC,WAAW,CAAC,SAAS,SAAS;AAAA,MAChC,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,QAAU;AAAA,QACX;AAAA,UAAC;AAAA;AAAA,YACC,WAAW,GAAG,yFAAyF;AAAA,YACvG,eAAY;AAAA;AAAA,QACd;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AASpE,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AAQpE,IAAM,qBAA6C;AASnD,IAAM,yBAA+B;AAAA,EACnC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,WAAW,GAAG,mEAAmE,GACpF;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,uBAAuB,cAAsC,iCAAS;AAStE,IAAM,0BAAgC;AAAA,EACpC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEJ,8BAAC,SAAI,WAAU,0EAAyE;AAAA;AAAA,EAC1F;AAEJ;AAEA,wBAAwB,cAAsC,kCAAU","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { ChevronDownIcon } from \"@radix-ui/react-icons\";\nimport * as NavigationMenuPrimitive from \"@radix-ui/react-navigation-menu\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: \"bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition-colors focus:outline-none disabled:pointer-events-none disabled:opacity-50\",\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\"relative z-10 flex max-w-max flex-1 items-center justify-center\", className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\"group flex flex-1 list-none items-center justify-center space-x-1\", className)}\n {...props}\n />\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: [\"group\", className],\n })}\n {...props}\n >\n {children}{\" \"}\n <ChevronDownIcon\n className={cn(\"relative top-px ml-1 h-3 w-3 transition duration-300 group-data-[state=open]:rotate-180\")}\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n \"data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full focus:outline-none md:absolute md:w-auto\",\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className={cn(\"perspective-[2000px] absolute left-0 top-full flex justify-center\")}>\n <NavigationMenuPrimitive.Viewport\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow md:w-[var(--radix-navigation-menu-viewport-width)]\",\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n \"data-[state=visible]:animate-in data-[state=visible]:fade-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden transition\",\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n NavigationMenuIndicator,\n NavigationMenuViewport,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n type NavigationMenuIndicatorProps,\n type NavigationMenuViewportProps,\n};\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/navigation-menu.tsx"],"names":[],"mappings":";;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,uBAAuB;AAChC,YAAY,6BAA6B;AAoBrC,SAME,KANF;AAbJ,IAAM,gCAAgC,IAAI;AAAA,EACxC,MAAM;AACR,CAAC;AASD,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,mEAAmE,SAAS;AAAA,MACzF,GAAG;AAAA,MAEH;AAAA;AAAA,QACD,oBAAC,0BAAuB;AAAA;AAAA;AAAA,EAC1B;AAEJ;AAEA,eAAe,cAAsC,6BAAK;AAS1D,IAAM,qBAA2B;AAAA,EAC/B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,qEAAqE,SAAS;AAAA,MAC3F,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,mBAAmB,cAAsC,6BAAK;AAQ9D,IAAM,qBAA6C;AASnD,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,8BAA8B;AAAA,QACvC,WAAW,CAAC,SAAS,SAAS;AAAA,MAChC,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,QACD;AAAA,UAAC;AAAA;AAAA,YACC,WAAW,GAAG,wFAAwF;AAAA,YACtG,eAAY;AAAA;AAAA,QACd;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AASpE,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AAQpE,IAAM,qBAA6C;AASnD,IAAM,yBAA+B;AAAA,EACnC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,WAAW,GAAG,mEAAmE,GACpF;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,uBAAuB,cAAsC,iCAAS;AAStE,IAAM,0BAAgC;AAAA,EACpC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEJ,8BAAC,SAAI,WAAU,0EAAyE;AAAA;AAAA,EAC1F;AAEJ;AAEA,wBAAwB,cAAsC,kCAAU","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { ChevronDownIcon } from \"@radix-ui/react-icons\";\nimport * as NavigationMenuPrimitive from \"@radix-ui/react-navigation-menu\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: \"bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition-colors focus:outline-none disabled:pointer-events-none disabled:opacity-50\",\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\"relative z-10 flex max-w-max flex-1 items-center justify-center\", className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\"group flex flex-1 list-none items-center justify-center space-x-1\", className)}\n {...props}\n />\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: [\"group\", className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className={cn(\"relative top-px ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180\")}\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n \"data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full focus:outline-none md:absolute md:w-auto\",\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className={cn(\"perspective-[2000px] absolute left-0 top-full flex justify-center\")}>\n <NavigationMenuPrimitive.Viewport\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow transition-[width,height] duration-200 md:w-[var(--radix-navigation-menu-viewport-width)]\",\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n \"data-[state=visible]:animate-in data-[state=visible]:fade-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden transition\",\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n NavigationMenuIndicator,\n NavigationMenuViewport,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n type NavigationMenuIndicatorProps,\n type NavigationMenuViewportProps,\n};\n"]}
|
package/dist/navigation-menu.mjs
CHANGED
|
@@ -50,11 +50,10 @@ var NavigationMenuTrigger = React.forwardRef(
|
|
|
50
50
|
...props,
|
|
51
51
|
children: [
|
|
52
52
|
children,
|
|
53
|
-
" ",
|
|
54
53
|
/* @__PURE__ */ jsx(
|
|
55
54
|
ChevronDownIcon,
|
|
56
55
|
{
|
|
57
|
-
className: cn("relative top-px ml-1
|
|
56
|
+
className: cn("relative top-px ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180"),
|
|
58
57
|
"aria-hidden": "true"
|
|
59
58
|
}
|
|
60
59
|
)
|
|
@@ -83,7 +82,7 @@ var NavigationMenuViewport = React.forwardRef(
|
|
|
83
82
|
NavigationMenuPrimitive.Viewport,
|
|
84
83
|
{
|
|
85
84
|
className: cn(
|
|
86
|
-
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow md:w-[var(--radix-navigation-menu-viewport-width)]",
|
|
85
|
+
"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow transition-[width,height] duration-200 md:w-[var(--radix-navigation-menu-viewport-width)]",
|
|
87
86
|
className
|
|
88
87
|
),
|
|
89
88
|
ref,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/navigation-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { ChevronDownIcon } from \"@radix-ui/react-icons\";\nimport * as NavigationMenuPrimitive from \"@radix-ui/react-navigation-menu\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: \"bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition-colors focus:outline-none disabled:pointer-events-none disabled:opacity-50\",\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\"relative z-10 flex max-w-max flex-1 items-center justify-center\", className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\"group flex flex-1 list-none items-center justify-center space-x-1\", className)}\n {...props}\n />\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: [\"group\", className],\n })}\n {...props}\n >\n {children}{\" \"}\n <ChevronDownIcon\n className={cn(\"relative top-px ml-1 h-3 w-3 transition duration-300 group-data-[state=open]:rotate-180\")}\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n \"data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full focus:outline-none md:absolute md:w-auto\",\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className={cn(\"perspective-[2000px] absolute left-0 top-full flex justify-center\")}>\n <NavigationMenuPrimitive.Viewport\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow md:w-[var(--radix-navigation-menu-viewport-width)]\",\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n \"data-[state=visible]:animate-in data-[state=visible]:fade-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden transition\",\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n NavigationMenuIndicator,\n NavigationMenuViewport,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n type NavigationMenuIndicatorProps,\n type NavigationMenuViewportProps,\n};\n"],"mappings":";;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,uBAAuB;AAChC,YAAY,6BAA6B;AAoBrC,SAME,KANF;AAbJ,IAAM,gCAAgC,IAAI;AAAA,EACxC,MAAM;AACR,CAAC;AASD,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,mEAAmE,SAAS;AAAA,MACzF,GAAG;AAAA,MAEH;AAAA;AAAA,QACD,oBAAC,0BAAuB;AAAA;AAAA;AAAA,EAC1B;AAEJ;AAEA,eAAe,cAAsC,6BAAK;AAS1D,IAAM,qBAA2B;AAAA,EAC/B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,qEAAqE,SAAS;AAAA,MAC3F,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,mBAAmB,cAAsC,6BAAK;AAQ9D,IAAM,qBAA6C;AASnD,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,8BAA8B;AAAA,QACvC,WAAW,CAAC,SAAS,SAAS;AAAA,MAChC,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,QAAU;AAAA,QACX;AAAA,UAAC;AAAA;AAAA,YACC,WAAW,GAAG,yFAAyF;AAAA,YACvG,eAAY;AAAA;AAAA,QACd;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AASpE,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AAQpE,IAAM,qBAA6C;AASnD,IAAM,yBAA+B;AAAA,EACnC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,WAAW,GAAG,mEAAmE,GACpF;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,uBAAuB,cAAsC,iCAAS;AAStE,IAAM,0BAAgC;AAAA,EACpC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEJ,8BAAC,SAAI,WAAU,0EAAyE;AAAA;AAAA,EAC1F;AAEJ;AAEA,wBAAwB,cAAsC,kCAAU;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/navigation-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { ChevronDownIcon } from \"@radix-ui/react-icons\";\nimport * as NavigationMenuPrimitive from \"@radix-ui/react-navigation-menu\";\nimport { cn, cva } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Variant: NavigationMenu\n * -------------------------------------------------------------------------- */\n\nconst navigationMenuTriggerVariants = cva({\n base: \"bg-background hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent/50 data-[active]:bg-accent/50 group inline-flex h-10 w-max items-center justify-center rounded-md px-3 py-2 text-sm font-medium transition-colors focus:outline-none disabled:pointer-events-none disabled:opacity-50\",\n});\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenu\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuElement = React.ElementRef<typeof NavigationMenuPrimitive.Root>;\ntype NavigationMenuProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Root>;\n\nconst NavigationMenu = React.forwardRef<NavigationMenuElement, NavigationMenuProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Root\n ref={ref}\n className={cn(\"relative z-10 flex max-w-max flex-1 items-center justify-center\", className)}\n {...props}\n >\n {children}\n <NavigationMenuViewport />\n </NavigationMenuPrimitive.Root>\n ),\n);\n\nNavigationMenu.displayName = NavigationMenuPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuList\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuListElement = React.ElementRef<typeof NavigationMenuPrimitive.List>;\ntype NavigationMenuListProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.List>;\n\nconst NavigationMenuList = React.forwardRef<NavigationMenuListElement, NavigationMenuListProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.List\n ref={ref}\n className={cn(\"group flex flex-1 list-none items-center justify-center space-x-1\", className)}\n {...props}\n />\n ),\n);\n\nNavigationMenuList.displayName = NavigationMenuPrimitive.List.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuItem\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuItemProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Item>;\n\nconst NavigationMenuItem = NavigationMenuPrimitive.Item;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuTriggerElement = React.ElementRef<typeof NavigationMenuPrimitive.Trigger>;\ntype NavigationMenuTriggerProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Trigger>;\n\nconst NavigationMenuTrigger = React.forwardRef<NavigationMenuTriggerElement, NavigationMenuTriggerProps>(\n ({ className, children, ...props }, ref) => (\n <NavigationMenuPrimitive.Trigger\n ref={ref}\n className={navigationMenuTriggerVariants({\n className: [\"group\", className],\n })}\n {...props}\n >\n {children}\n <ChevronDownIcon\n className={cn(\"relative top-px ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180\")}\n aria-hidden=\"true\"\n />\n </NavigationMenuPrimitive.Trigger>\n ),\n);\n\nNavigationMenuTrigger.displayName = NavigationMenuPrimitive.Trigger.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuContent\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuContentElement = React.ElementRef<typeof NavigationMenuPrimitive.Content>;\ntype NavigationMenuContentProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Content>;\n\nconst NavigationMenuContent = React.forwardRef<NavigationMenuContentElement, NavigationMenuContentProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Content\n ref={ref}\n className={cn(\n \"data-[motion^=from-]:animate-in data-[motion^=from-]:fade-in data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion^=to-]:animate-out data-[motion^=to-]:fade-out data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 left-0 top-0 w-full focus:outline-none md:absolute md:w-auto\",\n className,\n )}\n {...props}\n />\n ),\n);\n\nNavigationMenuContent.displayName = NavigationMenuPrimitive.Content.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuLink\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuLinkProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Link>;\n\nconst NavigationMenuLink = NavigationMenuPrimitive.Link;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuViewport\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuViewportElement = React.ElementRef<typeof NavigationMenuPrimitive.Viewport>;\ntype NavigationMenuViewportProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Viewport>;\n\nconst NavigationMenuViewport = React.forwardRef<NavigationMenuViewportElement, NavigationMenuViewportProps>(\n ({ className, ...props }, ref) => (\n <div className={cn(\"perspective-[2000px] absolute left-0 top-full flex justify-center\")}>\n <NavigationMenuPrimitive.Viewport\n className={cn(\n \"bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=open]:fade-in data-[state=open]:zoom-in-90 data-[state=closed]:animate-out data-[state=closed]:fade-out data-[state=closed]:zoom-out-95 relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full origin-[top_center] overflow-hidden rounded-md border shadow transition-[width,height] duration-200 md:w-[var(--radix-navigation-menu-viewport-width)]\",\n className,\n )}\n ref={ref}\n {...props}\n />\n </div>\n ),\n);\n\nNavigationMenuViewport.displayName = NavigationMenuPrimitive.Viewport.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: NavigationMenuIndicator\n * -------------------------------------------------------------------------- */\n\ntype NavigationMenuIndicatorElement = React.ElementRef<typeof NavigationMenuPrimitive.Indicator>;\ntype NavigationMenuIndicatorProps = React.ComponentPropsWithoutRef<typeof NavigationMenuPrimitive.Indicator>;\n\nconst NavigationMenuIndicator = React.forwardRef<NavigationMenuIndicatorElement, NavigationMenuIndicatorProps>(\n ({ className, ...props }, ref) => (\n <NavigationMenuPrimitive.Indicator\n ref={ref}\n className={cn(\n \"data-[state=visible]:animate-in data-[state=visible]:fade-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden transition\",\n className,\n )}\n {...props}\n >\n <div className=\"bg-border relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm shadow-md\" />\n </NavigationMenuPrimitive.Indicator>\n ),\n);\n\nNavigationMenuIndicator.displayName = NavigationMenuPrimitive.Indicator.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport {\n navigationMenuTriggerVariants,\n NavigationMenu,\n NavigationMenuList,\n NavigationMenuItem,\n NavigationMenuContent,\n NavigationMenuTrigger,\n NavigationMenuLink,\n NavigationMenuIndicator,\n NavigationMenuViewport,\n type NavigationMenuProps,\n type NavigationMenuListProps,\n type NavigationMenuItemProps,\n type NavigationMenuContentProps,\n type NavigationMenuTriggerProps,\n type NavigationMenuLinkProps,\n type NavigationMenuIndicatorProps,\n type NavigationMenuViewportProps,\n};\n"],"mappings":";;;;;;;AAEA,YAAY,WAAW;AACvB,SAAS,uBAAuB;AAChC,YAAY,6BAA6B;AAoBrC,SAME,KANF;AAbJ,IAAM,gCAAgC,IAAI;AAAA,EACxC,MAAM;AACR,CAAC;AASD,IAAM,iBAAuB;AAAA,EAC3B,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,mEAAmE,SAAS;AAAA,MACzF,GAAG;AAAA,MAEH;AAAA;AAAA,QACD,oBAAC,0BAAuB;AAAA;AAAA;AAAA,EAC1B;AAEJ;AAEA,eAAe,cAAsC,6BAAK;AAS1D,IAAM,qBAA2B;AAAA,EAC/B,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,GAAG,qEAAqE,SAAS;AAAA,MAC3F,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,mBAAmB,cAAsC,6BAAK;AAQ9D,IAAM,qBAA6C;AASnD,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,UAAU,GAAG,MAAM,GAAG,QAClC;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW,8BAA8B;AAAA,QACvC,WAAW,CAAC,SAAS,SAAS;AAAA,MAChC,CAAC;AAAA,MACA,GAAG;AAAA,MAEH;AAAA;AAAA,QACD;AAAA,UAAC;AAAA;AAAA,YACC,WAAW,GAAG,wFAAwF;AAAA,YACtG,eAAY;AAAA;AAAA,QACd;AAAA;AAAA;AAAA,EACF;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AASpE,IAAM,wBAA8B;AAAA,EAClC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ;AAEA,sBAAsB,cAAsC,gCAAQ;AAQpE,IAAM,qBAA6C;AASnD,IAAM,yBAA+B;AAAA,EACnC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB,oBAAC,SAAI,WAAW,GAAG,mEAAmE,GACpF;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACA;AAAA,MACC,GAAG;AAAA;AAAA,EACN,GACF;AAEJ;AAEA,uBAAuB,cAAsC,iCAAS;AAStE,IAAM,0BAAgC;AAAA,EACpC,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QACxB;AAAA,IAAyB;AAAA,IAAxB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA,MAEJ,8BAAC,SAAI,WAAU,0EAAyE;AAAA;AAAA,EAC1F;AAEJ;AAEA,wBAAwB,cAAsC,kCAAU;","names":[]}
|
package/dist/pagination.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } }
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
3
|
+
var _chunkTFYKPLNVjs = require('./chunk-TFYKPLNV.js');
|
|
4
|
+
require('./chunk-Y3DZHPJ5.js');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _chunkG3NP7M2Njs = require('./chunk-G3NP7M2N.js');
|
|
@@ -38,7 +38,7 @@ function PaginationLink({
|
|
|
38
38
|
"a",
|
|
39
39
|
{
|
|
40
40
|
"aria-current": isActive ? "page" : void 0,
|
|
41
|
-
className:
|
|
41
|
+
className: _chunkTFYKPLNVjs.buttonVariants.call(void 0, {
|
|
42
42
|
variant: isActive ? "outline" : "ghost",
|
|
43
43
|
size,
|
|
44
44
|
className
|
package/dist/pagination.mjs
CHANGED
package/dist/radio-cards.js
CHANGED
|
@@ -17,11 +17,7 @@ var RadioCardsItem = React.forwardRef(({ className, ...props }, ref) => {
|
|
|
17
17
|
{
|
|
18
18
|
ref,
|
|
19
19
|
className: _chunkG3NP7M2Njs.cn.call(void 0,
|
|
20
|
-
"border-compound/70 text-compound-foreground group peer flex cursor-default items-center justify-center rounded-md border p-4",
|
|
21
|
-
"hover:border-compound",
|
|
22
|
-
"aria-checked:border-primary",
|
|
23
|
-
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
24
|
-
"focus-visible:bg-primary/10 focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",
|
|
20
|
+
"border-compound/70 text-compound-foreground hover:border-compound aria-checked:border-primary focus-visible:bg-primary/10 focus-visible:ring-ring group peer flex cursor-default items-center justify-center rounded-md border p-4 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
|
|
25
21
|
className
|
|
26
22
|
),
|
|
27
23
|
...props
|
package/dist/radio-cards.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/radio-cards.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,yBAAyB;AAW5B;AADT,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACxG,SAAO,oBAAqB,0BAApB,EAAyB,WAAW,GAAG,cAAc,SAAS,GAAI,GAAG,OAAO,KAAU;AAChG,CAAC;AAED,WAAW,cAAkC,yBAAK;AASlD,IAAM,iBAAuB,iBAAuD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACpH,SACE;AAAA,IAAqB;AAAA,IAApB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,
|
|
1
|
+
{"version":3,"sources":["../src/radio-cards.tsx"],"names":[],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,yBAAyB;AAW5B;AADT,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACxG,SAAO,oBAAqB,0BAApB,EAAyB,WAAW,GAAG,cAAc,SAAS,GAAI,GAAG,OAAO,KAAU;AAChG,CAAC;AAED,WAAW,cAAkC,yBAAK;AASlD,IAAM,iBAAuB,iBAAuD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACpH,SACE;AAAA,IAAqB;AAAA,IAApB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ,CAAC;AAED,eAAe,cAAkC,yBAAK","sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as RadioGroupPrimitive from \"@radix-ui/react-radio-group\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCards\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsElement = React.ElementRef<typeof RadioGroupPrimitive.Root>;\ntype RadioCardsProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>;\n\nconst RadioCards = React.forwardRef<RadioCardsElement, RadioCardsProps>(({ className, ...props }, ref) => {\n return <RadioGroupPrimitive.Root className={cn(\"grid gap-2\", className)} {...props} ref={ref} />;\n});\n\nRadioCards.displayName = RadioGroupPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCardsItem\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsItemElement = React.ElementRef<typeof RadioGroupPrimitive.Item>;\ntype RadioCardsItemProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>;\n\nconst RadioCardsItem = React.forwardRef<RadioCardsItemElement, RadioCardsItemProps>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n \"border-compound/70 text-compound-foreground hover:border-compound aria-checked:border-primary focus-visible:bg-primary/10 focus-visible:ring-ring group peer flex cursor-default items-center justify-center rounded-md border p-4 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n );\n});\n\nRadioCardsItem.displayName = RadioGroupPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { RadioCards, RadioCardsItem, type RadioCardsProps, type RadioCardsItemProps };\n"]}
|
package/dist/radio-cards.mjs
CHANGED
|
@@ -17,11 +17,7 @@ var RadioCardsItem = React.forwardRef(({ className, ...props }, ref) => {
|
|
|
17
17
|
{
|
|
18
18
|
ref,
|
|
19
19
|
className: cn(
|
|
20
|
-
"border-compound/70 text-compound-foreground group peer flex cursor-default items-center justify-center rounded-md border p-4",
|
|
21
|
-
"hover:border-compound",
|
|
22
|
-
"aria-checked:border-primary",
|
|
23
|
-
"disabled:cursor-not-allowed disabled:opacity-50",
|
|
24
|
-
"focus-visible:bg-primary/10 focus-visible:ring-ring focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",
|
|
20
|
+
"border-compound/70 text-compound-foreground hover:border-compound aria-checked:border-primary focus-visible:bg-primary/10 focus-visible:ring-ring group peer flex cursor-default items-center justify-center rounded-md border p-4 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",
|
|
25
21
|
className
|
|
26
22
|
),
|
|
27
23
|
...props
|
package/dist/radio-cards.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/radio-cards.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as RadioGroupPrimitive from \"@radix-ui/react-radio-group\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCards\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsElement = React.ElementRef<typeof RadioGroupPrimitive.Root>;\ntype RadioCardsProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>;\n\nconst RadioCards = React.forwardRef<RadioCardsElement, RadioCardsProps>(({ className, ...props }, ref) => {\n return <RadioGroupPrimitive.Root className={cn(\"grid gap-2\", className)} {...props} ref={ref} />;\n});\n\nRadioCards.displayName = RadioGroupPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCardsItem\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsItemElement = React.ElementRef<typeof RadioGroupPrimitive.Item>;\ntype RadioCardsItemProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>;\n\nconst RadioCardsItem = React.forwardRef<RadioCardsItemElement, RadioCardsItemProps>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n \"border-compound/70 text-compound-foreground
|
|
1
|
+
{"version":3,"sources":["../src/radio-cards.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport * as RadioGroupPrimitive from \"@radix-ui/react-radio-group\";\nimport { cn } from \"./utils\";\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCards\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsElement = React.ElementRef<typeof RadioGroupPrimitive.Root>;\ntype RadioCardsProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Root>;\n\nconst RadioCards = React.forwardRef<RadioCardsElement, RadioCardsProps>(({ className, ...props }, ref) => {\n return <RadioGroupPrimitive.Root className={cn(\"grid gap-2\", className)} {...props} ref={ref} />;\n});\n\nRadioCards.displayName = RadioGroupPrimitive.Root.displayName;\n\n/* -----------------------------------------------------------------------------\n * Component: RadioCardsItem\n * -------------------------------------------------------------------------- */\n\ntype RadioCardsItemElement = React.ElementRef<typeof RadioGroupPrimitive.Item>;\ntype RadioCardsItemProps = React.ComponentPropsWithoutRef<typeof RadioGroupPrimitive.Item>;\n\nconst RadioCardsItem = React.forwardRef<RadioCardsItemElement, RadioCardsItemProps>(({ className, ...props }, ref) => {\n return (\n <RadioGroupPrimitive.Item\n ref={ref}\n className={cn(\n \"border-compound/70 text-compound-foreground hover:border-compound aria-checked:border-primary focus-visible:bg-primary/10 focus-visible:ring-ring group peer flex cursor-default items-center justify-center rounded-md border p-4 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50\",\n className,\n )}\n {...props}\n />\n );\n});\n\nRadioCardsItem.displayName = RadioGroupPrimitive.Item.displayName;\n\n/* -----------------------------------------------------------------------------\n * Exports\n * -------------------------------------------------------------------------- */\n\nexport { RadioCards, RadioCardsItem, type RadioCardsProps, type RadioCardsItemProps };\n"],"mappings":";;;;;;AAEA,YAAY,WAAW;AACvB,YAAY,yBAAyB;AAW5B;AADT,IAAM,aAAmB,iBAA+C,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACxG,SAAO,oBAAqB,0BAApB,EAAyB,WAAW,GAAG,cAAc,SAAS,GAAI,GAAG,OAAO,KAAU;AAChG,CAAC;AAED,WAAW,cAAkC,yBAAK;AASlD,IAAM,iBAAuB,iBAAuD,CAAC,EAAE,WAAW,GAAG,MAAM,GAAG,QAAQ;AACpH,SACE;AAAA,IAAqB;AAAA,IAApB;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,MACF;AAAA,MACC,GAAG;AAAA;AAAA,EACN;AAEJ,CAAC;AAED,eAAe,cAAkC,yBAAK;","names":[]}
|