@waveso/ui 0.0.2 → 0.0.4
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/LICENSE +21 -0
- package/README.md +72 -52
- package/dist/accordion.d.ts +14 -0
- package/dist/accordion.js +81 -0
- package/dist/accordion.js.map +1 -0
- package/dist/alert.d.ts +8 -4
- package/dist/alert.js.map +1 -1
- package/dist/aspect-ratio.d.ts +10 -0
- package/dist/aspect-ratio.js +18 -0
- package/dist/aspect-ratio.js.map +1 -0
- package/dist/autocomplete.d.ts +48 -0
- package/dist/autocomplete.js +222 -0
- package/dist/autocomplete.js.map +1 -0
- package/dist/avatar.d.ts +13 -7
- package/dist/avatar.js.map +1 -1
- package/dist/badge.d.ts +3 -2
- package/dist/badge.js +1 -1
- package/dist/badge.js.map +1 -1
- package/dist/breadcrumb.d.ts +20 -0
- package/dist/breadcrumb.js +123 -0
- package/dist/breadcrumb.js.map +1 -0
- package/dist/button-group.d.ts +19 -0
- package/dist/button-group.js +81 -0
- package/dist/button-group.js.map +1 -0
- package/dist/card.d.ts +15 -8
- package/dist/card.js.map +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/chunk-45VQAWIM.js +228 -0
- package/dist/chunk-45VQAWIM.js.map +1 -0
- package/dist/chunk-6Y7LPQMO.js +11 -0
- package/dist/chunk-6Y7LPQMO.js.map +1 -0
- package/dist/chunk-7F4MPMLJ.js +17 -0
- package/dist/chunk-7F4MPMLJ.js.map +1 -0
- package/dist/chunk-7OIQ6YBK.js +66 -0
- package/dist/chunk-7OIQ6YBK.js.map +1 -0
- package/dist/chunk-D5XPEJ6T.js +36 -0
- package/dist/chunk-D5XPEJ6T.js.map +1 -0
- package/dist/chunk-DIGOLJIR.js +105 -0
- package/dist/chunk-DIGOLJIR.js.map +1 -0
- package/dist/chunk-IQ7YQ5XA.js +141 -0
- package/dist/chunk-IQ7YQ5XA.js.map +1 -0
- package/dist/chunk-NCHHHWTB.js +85 -0
- package/dist/chunk-NCHHHWTB.js.map +1 -0
- package/dist/chunk-PVX4VQFJ.js +143 -0
- package/dist/chunk-PVX4VQFJ.js.map +1 -0
- package/dist/chunk-QFSEK4M6.js +22 -0
- package/dist/chunk-QFSEK4M6.js.map +1 -0
- package/dist/chunk-QRW37LRP.js +25 -0
- package/dist/chunk-QRW37LRP.js.map +1 -0
- package/dist/chunk-RPQHL6C5.js +26 -0
- package/dist/chunk-RPQHL6C5.js.map +1 -0
- package/dist/chunk-YTSQQTSF.js +44 -0
- package/dist/chunk-YTSQQTSF.js.map +1 -0
- package/dist/chunk-ZZZH3JGW.js +23 -0
- package/dist/chunk-ZZZH3JGW.js.map +1 -0
- package/dist/collapsible.d.ts +12 -0
- package/dist/collapsible.js +16 -0
- package/dist/collapsible.js.map +1 -0
- package/dist/combobox.d.ts +48 -0
- package/dist/combobox.js +281 -0
- package/dist/combobox.js.map +1 -0
- package/dist/context-menu.d.ts +47 -0
- package/dist/context-menu.js +193 -0
- package/dist/context-menu.js.map +1 -0
- package/dist/dialog.js +1 -1
- package/dist/direction.d.ts +1 -0
- package/dist/direction.js +3 -0
- package/dist/direction.js.map +1 -0
- package/dist/drawer.d.ts +29 -0
- package/dist/drawer.js +6 -0
- package/dist/drawer.js.map +1 -0
- package/dist/encrypted-text.d.ts +16 -0
- package/dist/encrypted-text.js +141 -0
- package/dist/encrypted-text.js.map +1 -0
- package/dist/field.d.ts +22 -0
- package/dist/field.js +4 -0
- package/dist/field.js.map +1 -0
- package/dist/form.d.ts +80 -0
- package/dist/form.js +108 -0
- package/dist/form.js.map +1 -0
- package/dist/hooks/use-mobile.d.ts +6 -1
- package/dist/hooks/use-mobile.js +1 -18
- package/dist/hooks/use-mobile.js.map +1 -1
- package/dist/infinite-scroll.d.ts +19 -0
- package/dist/infinite-scroll.js +102 -0
- package/dist/infinite-scroll.js.map +1 -0
- package/dist/input-group.d.ts +29 -0
- package/dist/input-group.js +7 -0
- package/dist/input-group.js.map +1 -0
- package/dist/input-otp.d.ts +18 -0
- package/dist/input-otp.js +79 -0
- package/dist/input-otp.js.map +1 -0
- package/dist/input.d.ts +2 -1
- package/dist/input.js +2 -20
- package/dist/input.js.map +1 -1
- package/dist/item.d.ts +37 -0
- package/dist/item.js +181 -0
- package/dist/item.js.map +1 -0
- package/dist/kbd.d.ts +8 -0
- package/dist/kbd.js +30 -0
- package/dist/kbd.js.map +1 -0
- package/dist/label.d.ts +2 -1
- package/dist/label.js.map +1 -1
- package/dist/masonry.d.ts +17 -0
- package/dist/masonry.js +235 -0
- package/dist/masonry.js.map +1 -0
- package/dist/menu.d.ts +47 -0
- package/dist/menu.js +5 -0
- package/dist/menu.js.map +1 -0
- package/dist/menubar.d.ts +40 -0
- package/dist/menubar.js +84 -0
- package/dist/menubar.js.map +1 -0
- package/dist/pagination.d.ts +29 -0
- package/dist/pagination.js +120 -0
- package/dist/pagination.js.map +1 -0
- package/dist/popover.d.ts +24 -0
- package/dist/popover.js +105 -0
- package/dist/popover.js.map +1 -0
- package/dist/preview-card.d.ts +17 -0
- package/dist/preview-card.js +70 -0
- package/dist/preview-card.js.map +1 -0
- package/dist/radio-group.d.ts +12 -0
- package/dist/radio-group.js +28 -0
- package/dist/radio-group.js.map +1 -0
- package/dist/radio.d.ts +10 -0
- package/dist/radio.js +4 -0
- package/dist/radio.js.map +1 -0
- package/dist/scroll-area.d.ts +10 -0
- package/dist/scroll-area.js +59 -0
- package/dist/scroll-area.js.map +1 -0
- package/dist/select.d.ts +36 -0
- package/dist/select.js +208 -0
- package/dist/select.js.map +1 -0
- package/dist/separator.js +2 -24
- package/dist/separator.js.map +1 -1
- package/dist/sidebar.d.ts +112 -0
- package/dist/sidebar.js +619 -0
- package/dist/sidebar.js.map +1 -0
- package/dist/skeleton.d.ts +2 -1
- package/dist/skeleton.js +2 -15
- package/dist/skeleton.js.map +1 -1
- package/dist/slider.d.ts +10 -0
- package/dist/slider.js +70 -0
- package/dist/slider.js.map +1 -0
- package/dist/spinner.d.ts +2 -1
- package/dist/spinner.js +3 -9
- package/dist/spinner.js.map +1 -1
- package/dist/styles.css +196 -0
- package/dist/table.d.ts +21 -0
- package/dist/table.js +106 -0
- package/dist/table.js.map +1 -0
- package/dist/tabs.d.ts +20 -0
- package/dist/tabs.js +82 -0
- package/dist/tabs.js.map +1 -0
- package/dist/textarea.js +2 -23
- package/dist/textarea.js.map +1 -1
- package/dist/toast.d.ts +57 -0
- package/dist/toast.js +239 -0
- package/dist/toast.js.map +1 -0
- package/dist/toggle-group.d.ts +17 -0
- package/dist/toggle-group.js +78 -0
- package/dist/toggle-group.js.map +1 -0
- package/dist/toggle.d.ts +14 -0
- package/dist/toggle.js +4 -0
- package/dist/toggle.js.map +1 -0
- package/dist/tooltip.d.ts +21 -0
- package/dist/tooltip.js +4 -0
- package/dist/tooltip.js.map +1 -0
- package/package.json +10 -3
- package/dist/chunk-L3UIJEIQ.js +0 -41
- package/dist/chunk-L3UIJEIQ.js.map +0 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
import { Button } from './button.js';
|
|
6
|
+
import '@base-ui/react/button';
|
|
7
|
+
|
|
8
|
+
type InputGroupProps = React.ComponentProps<"div">;
|
|
9
|
+
type InputGroupAddonProps = React.ComponentProps<"div"> & VariantProps<typeof inputGroupAddonVariants>;
|
|
10
|
+
type InputGroupButtonProps = Omit<React.ComponentProps<typeof Button>, "size" | "type"> & VariantProps<typeof inputGroupButtonVariants> & {
|
|
11
|
+
type?: "button" | "submit" | "reset";
|
|
12
|
+
};
|
|
13
|
+
type InputGroupTextProps = React.ComponentProps<"span">;
|
|
14
|
+
type InputGroupInputProps = React.ComponentProps<"input">;
|
|
15
|
+
type InputGroupTextareaProps = React.ComponentProps<"textarea">;
|
|
16
|
+
declare function InputGroup({ className, ...props }: InputGroupProps): react_jsx_runtime.JSX.Element;
|
|
17
|
+
declare const inputGroupAddonVariants: (props?: ({
|
|
18
|
+
align?: "inline-end" | "inline-start" | "block-start" | "block-end" | null | undefined;
|
|
19
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
20
|
+
declare function InputGroupAddon({ className, align, ...props }: InputGroupAddonProps): react_jsx_runtime.JSX.Element;
|
|
21
|
+
declare const inputGroupButtonVariants: (props?: ({
|
|
22
|
+
size?: "sm" | "xs" | "icon-xs" | "icon-sm" | null | undefined;
|
|
23
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
24
|
+
declare function InputGroupButton({ className, type, variant, size, ...props }: InputGroupButtonProps): react_jsx_runtime.JSX.Element;
|
|
25
|
+
declare function InputGroupText({ className, ...props }: InputGroupTextProps): react_jsx_runtime.JSX.Element;
|
|
26
|
+
declare function InputGroupInput({ className, ...props }: InputGroupInputProps): react_jsx_runtime.JSX.Element;
|
|
27
|
+
declare function InputGroupTextarea({ className, ...props }: InputGroupTextareaProps): react_jsx_runtime.JSX.Element;
|
|
28
|
+
|
|
29
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea } from './chunk-IQ7YQ5XA.js';
|
|
2
|
+
import './chunk-QRW37LRP.js';
|
|
3
|
+
import './chunk-QFSEK4M6.js';
|
|
4
|
+
import './chunk-OUFYQLVN.js';
|
|
5
|
+
import './chunk-76UQO56T.js';
|
|
6
|
+
//# sourceMappingURL=input-group.js.map
|
|
7
|
+
//# sourceMappingURL=input-group.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"input-group.js"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { OTPInput } from 'input-otp';
|
|
4
|
+
|
|
5
|
+
type InputOTPProps = React.ComponentProps<typeof OTPInput> & {
|
|
6
|
+
containerClassName?: string;
|
|
7
|
+
};
|
|
8
|
+
declare function InputOTP({ className, containerClassName, ...props }: InputOTPProps): react_jsx_runtime.JSX.Element;
|
|
9
|
+
type InputOTPGroupProps = React.ComponentProps<"div">;
|
|
10
|
+
declare function InputOTPGroup({ className, ...props }: InputOTPGroupProps): react_jsx_runtime.JSX.Element;
|
|
11
|
+
type InputOTPSlotProps = React.ComponentProps<"div"> & {
|
|
12
|
+
index: number;
|
|
13
|
+
};
|
|
14
|
+
declare function InputOTPSlot({ index, className, ...props }: InputOTPSlotProps): react_jsx_runtime.JSX.Element;
|
|
15
|
+
type InputOTPSeparatorProps = React.ComponentProps<"div">;
|
|
16
|
+
declare function InputOTPSeparator({ className, ...props }: InputOTPSeparatorProps): react_jsx_runtime.JSX.Element;
|
|
17
|
+
|
|
18
|
+
export { InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot };
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { MinusIcon } from './chunk-DIGOLJIR.js';
|
|
2
|
+
import { cn } from './chunk-76UQO56T.js';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { OTPInput, OTPInputContext } from 'input-otp';
|
|
5
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
6
|
+
|
|
7
|
+
function InputOTP({
|
|
8
|
+
className,
|
|
9
|
+
containerClassName,
|
|
10
|
+
...props
|
|
11
|
+
}) {
|
|
12
|
+
return /* @__PURE__ */ jsx(
|
|
13
|
+
OTPInput,
|
|
14
|
+
{
|
|
15
|
+
"data-slot": "input-otp",
|
|
16
|
+
containerClassName: cn(
|
|
17
|
+
"flex items-center has-disabled:opacity-50",
|
|
18
|
+
containerClassName
|
|
19
|
+
),
|
|
20
|
+
spellCheck: false,
|
|
21
|
+
className: cn("disabled:cursor-not-allowed", className),
|
|
22
|
+
...props
|
|
23
|
+
}
|
|
24
|
+
);
|
|
25
|
+
}
|
|
26
|
+
function InputOTPGroup({ className, ...props }) {
|
|
27
|
+
return /* @__PURE__ */ jsx(
|
|
28
|
+
"div",
|
|
29
|
+
{
|
|
30
|
+
"data-slot": "input-otp-group",
|
|
31
|
+
className: cn(
|
|
32
|
+
"flex items-center rounded-lg has-aria-invalid:border-destructive has-aria-invalid:ring-3 has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40",
|
|
33
|
+
className
|
|
34
|
+
),
|
|
35
|
+
...props
|
|
36
|
+
}
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
function InputOTPSlot({ index, className, ...props }) {
|
|
40
|
+
const inputOTPContext = React.useContext(OTPInputContext);
|
|
41
|
+
const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {};
|
|
42
|
+
return /* @__PURE__ */ jsxs(
|
|
43
|
+
"div",
|
|
44
|
+
{
|
|
45
|
+
"data-slot": "input-otp-slot",
|
|
46
|
+
"data-active": isActive || void 0,
|
|
47
|
+
className: cn(
|
|
48
|
+
"border-input dark:bg-input/30 relative flex size-9 items-center justify-center border-y border-r text-sm transition-all outline-none first:rounded-l-lg first:border-l last:rounded-r-lg",
|
|
49
|
+
"data-active:border-ring data-active:ring-3 data-active:ring-ring/50 data-active:z-10",
|
|
50
|
+
"aria-invalid:border-destructive data-active:aria-invalid:border-destructive data-active:aria-invalid:ring-destructive/20 dark:data-active:aria-invalid:ring-destructive/40",
|
|
51
|
+
className
|
|
52
|
+
),
|
|
53
|
+
...props,
|
|
54
|
+
children: [
|
|
55
|
+
char,
|
|
56
|
+
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 duration-1000" }) })
|
|
57
|
+
]
|
|
58
|
+
}
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
function InputOTPSeparator({ className, ...props }) {
|
|
62
|
+
return /* @__PURE__ */ jsx(
|
|
63
|
+
"div",
|
|
64
|
+
{
|
|
65
|
+
"data-slot": "input-otp-separator",
|
|
66
|
+
className: cn(
|
|
67
|
+
"flex items-center [&_svg:not([class*='size-'])]:size-4",
|
|
68
|
+
className
|
|
69
|
+
),
|
|
70
|
+
role: "separator",
|
|
71
|
+
...props,
|
|
72
|
+
children: /* @__PURE__ */ jsx(MinusIcon, {})
|
|
73
|
+
}
|
|
74
|
+
);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export { InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot };
|
|
78
|
+
//# sourceMappingURL=input-otp.js.map
|
|
79
|
+
//# sourceMappingURL=input-otp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/input-otp.tsx"],"names":[],"mappings":";;;;;;AAYA,SAAS,QAAA,CAAS;AAAA,EAChB,SAAA;AAAA,EACA,kBAAA;AAAA,EACA,GAAG;AACL,CAAA,EAAkB;AAChB,EAAA,uBACE,GAAA;AAAA,IAAC,QAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,WAAA;AAAA,MACV,kBAAA,EAAoB,EAAA;AAAA,QAClB,2CAAA;AAAA,QACA;AAAA,OACF;AAAA,MACA,UAAA,EAAY,KAAA;AAAA,MACZ,SAAA,EAAW,EAAA,CAAG,6BAAA,EAA+B,SAAS,CAAA;AAAA,MACrD,GAAG;AAAA;AAAA,GACN;AAEJ;AAIA,SAAS,aAAA,CAAc,EAAE,SAAA,EAAW,GAAG,OAAM,EAAuB;AAClE,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,iBAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,yKAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAMA,SAAS,aAAa,EAAE,KAAA,EAAO,SAAA,EAAW,GAAG,OAAM,EAAsB;AACvE,EAAA,MAAM,eAAA,GAAwB,iBAAW,eAAe,CAAA;AACxD,EAAA,MAAM,EAAE,MAAM,YAAA,EAAc,QAAA,KAAa,eAAA,EAAiB,KAAA,CAAM,KAAK,CAAA,IAAK,EAAC;AAE3E,EAAA,uBACE,IAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,gBAAA;AAAA,MACV,eAAa,QAAA,IAAY,MAAA;AAAA,MACzB,SAAA,EAAW,EAAA;AAAA,QACT,0LAAA;AAAA,QACA,sFAAA;AAAA,QACA,4KAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG,KAAA;AAAA,MAEH,QAAA,EAAA;AAAA,QAAA,IAAA;AAAA,QACA,YAAA,wBACE,KAAA,EAAA,EAAI,SAAA,EAAU,yEACb,QAAA,kBAAA,GAAA,CAAC,KAAA,EAAA,EAAI,SAAA,EAAU,0DAAA,EAA2D,CAAA,EAC5E;AAAA;AAAA;AAAA,GAEJ;AAEJ;AAIA,SAAS,iBAAA,CAAkB,EAAE,SAAA,EAAW,GAAG,OAAM,EAA2B;AAC1E,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,qBAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,wDAAA;AAAA,QACA;AAAA,OACF;AAAA,MACA,IAAA,EAAK,WAAA;AAAA,MACJ,GAAG,KAAA;AAAA,MAEJ,8BAAC,SAAA,EAAA,EAAU;AAAA;AAAA,GACb;AAEJ","file":"input-otp.js","sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\nimport { OTPInput, OTPInputContext } from \"input-otp\"\n\nimport { cn } from \"./lib/utils\"\nimport { MinusIcon } from \"./lib/internal-icons\"\n\ntype InputOTPProps = React.ComponentProps<typeof OTPInput> & {\n containerClassName?: string\n}\n\nfunction InputOTP({\n className,\n containerClassName,\n ...props\n}: InputOTPProps) {\n return (\n <OTPInput\n data-slot=\"input-otp\"\n containerClassName={cn(\n \"flex items-center has-disabled:opacity-50\",\n containerClassName,\n )}\n spellCheck={false}\n className={cn(\"disabled:cursor-not-allowed\", className)}\n {...props}\n />\n )\n}\n\ntype InputOTPGroupProps = React.ComponentProps<\"div\">\n\nfunction InputOTPGroup({ className, ...props }: InputOTPGroupProps) {\n return (\n <div\n data-slot=\"input-otp-group\"\n className={cn(\n \"flex items-center rounded-lg has-aria-invalid:border-destructive has-aria-invalid:ring-3 has-aria-invalid:ring-destructive/20 dark:has-aria-invalid:ring-destructive/40\",\n className,\n )}\n {...props}\n />\n )\n}\n\ntype InputOTPSlotProps = React.ComponentProps<\"div\"> & {\n index: number\n}\n\nfunction InputOTPSlot({ index, className, ...props }: InputOTPSlotProps) {\n const inputOTPContext = React.useContext(OTPInputContext)\n const { char, hasFakeCaret, isActive } = inputOTPContext?.slots[index] ?? {}\n\n return (\n <div\n data-slot=\"input-otp-slot\"\n data-active={isActive || undefined}\n className={cn(\n \"border-input dark:bg-input/30 relative flex size-9 items-center justify-center border-y border-r text-sm transition-all outline-none first:rounded-l-lg first:border-l last:rounded-r-lg\",\n \"data-active:border-ring data-active:ring-3 data-active:ring-ring/50 data-active:z-10\",\n \"aria-invalid:border-destructive data-active:aria-invalid:border-destructive data-active:aria-invalid:ring-destructive/20 dark:data-active:aria-invalid:ring-destructive/40\",\n className,\n )}\n {...props}\n >\n {char}\n {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 duration-1000\" />\n </div>\n )}\n </div>\n )\n}\n\ntype InputOTPSeparatorProps = React.ComponentProps<\"div\">\n\nfunction InputOTPSeparator({ className, ...props }: InputOTPSeparatorProps) {\n return (\n <div\n data-slot=\"input-otp-separator\"\n className={cn(\n \"flex items-center [&_svg:not([class*='size-'])]:size-4\",\n className,\n )}\n role=\"separator\"\n {...props}\n >\n <MinusIcon />\n </div>\n )\n}\n\nexport {\n InputOTP,\n InputOTPGroup,\n InputOTPSlot,\n InputOTPSeparator\n}\n"]}
|
package/dist/input.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
type InputProps = React.ComponentProps<"input">;
|
|
5
|
+
declare function Input({ className, type, ...props }: InputProps): react_jsx_runtime.JSX.Element;
|
|
5
6
|
|
|
6
7
|
export { Input };
|
package/dist/input.js
CHANGED
|
@@ -1,22 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import { jsx } from 'react/jsx-runtime';
|
|
4
|
-
|
|
5
|
-
function Input({ className, type, ...props }) {
|
|
6
|
-
return /* @__PURE__ */ jsx(
|
|
7
|
-
Input$1,
|
|
8
|
-
{
|
|
9
|
-
type,
|
|
10
|
-
"data-slot": "input",
|
|
11
|
-
className: cn(
|
|
12
|
-
"dark:bg-input/30 border-input focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 disabled:bg-input/50 dark:disabled:bg-input/80 file:text-foreground placeholder:text-muted-foreground h-8 w-full min-w-0 rounded-lg border bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:ring-3 disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:ring-3 md:text-sm",
|
|
13
|
-
className
|
|
14
|
-
),
|
|
15
|
-
...props
|
|
16
|
-
}
|
|
17
|
-
);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export { Input };
|
|
1
|
+
export { Input } from './chunk-QFSEK4M6.js';
|
|
2
|
+
import './chunk-76UQO56T.js';
|
|
21
3
|
//# sourceMappingURL=input.js.map
|
|
22
4
|
//# sourceMappingURL=input.js.map
|
package/dist/input.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"input.js"}
|
package/dist/item.d.ts
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
5
|
+
import { VariantProps } from 'class-variance-authority';
|
|
6
|
+
import { Separator } from './separator.js';
|
|
7
|
+
import '@base-ui/react/separator';
|
|
8
|
+
|
|
9
|
+
declare const itemVariants: (props?: ({
|
|
10
|
+
variant?: "default" | "outline" | "muted" | null | undefined;
|
|
11
|
+
size?: "default" | "sm" | "xs" | null | undefined;
|
|
12
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
13
|
+
declare const itemMediaVariants: (props?: ({
|
|
14
|
+
variant?: "image" | "default" | "icon" | null | undefined;
|
|
15
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
16
|
+
type ItemGroupProps = React.ComponentProps<"div">;
|
|
17
|
+
type ItemSeparatorProps = React.ComponentProps<typeof Separator>;
|
|
18
|
+
type ItemProps = useRender.ComponentProps<"div"> & VariantProps<typeof itemVariants>;
|
|
19
|
+
type ItemMediaProps = React.ComponentProps<"div"> & VariantProps<typeof itemMediaVariants>;
|
|
20
|
+
type ItemContentProps = React.ComponentProps<"div">;
|
|
21
|
+
type ItemTitleProps = React.ComponentProps<"div">;
|
|
22
|
+
type ItemDescriptionProps = React.ComponentProps<"p">;
|
|
23
|
+
type ItemActionsProps = React.ComponentProps<"div">;
|
|
24
|
+
type ItemHeaderProps = React.ComponentProps<"div">;
|
|
25
|
+
type ItemFooterProps = React.ComponentProps<"div">;
|
|
26
|
+
declare function ItemGroup({ className, ...props }: ItemGroupProps): react_jsx_runtime.JSX.Element;
|
|
27
|
+
declare function ItemSeparator({ className, ...props }: ItemSeparatorProps): react_jsx_runtime.JSX.Element;
|
|
28
|
+
declare function Item({ className, variant, size, render, ...props }: ItemProps): React.ReactElement<unknown, string | React.JSXElementConstructor<any>>;
|
|
29
|
+
declare function ItemMedia({ className, variant, ...props }: ItemMediaProps): react_jsx_runtime.JSX.Element;
|
|
30
|
+
declare function ItemContent({ className, ...props }: ItemContentProps): react_jsx_runtime.JSX.Element;
|
|
31
|
+
declare function ItemTitle({ className, ...props }: ItemTitleProps): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare function ItemDescription({ className, ...props }: ItemDescriptionProps): react_jsx_runtime.JSX.Element;
|
|
33
|
+
declare function ItemActions({ className, ...props }: ItemActionsProps): react_jsx_runtime.JSX.Element;
|
|
34
|
+
declare function ItemHeader({ className, ...props }: ItemHeaderProps): react_jsx_runtime.JSX.Element;
|
|
35
|
+
declare function ItemFooter({ className, ...props }: ItemFooterProps): react_jsx_runtime.JSX.Element;
|
|
36
|
+
|
|
37
|
+
export { Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle };
|
package/dist/item.js
ADDED
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
import { Separator } from './chunk-RPQHL6C5.js';
|
|
2
|
+
import { cn } from './chunk-76UQO56T.js';
|
|
3
|
+
import { mergeProps } from '@base-ui/react/merge-props';
|
|
4
|
+
import { useRender } from '@base-ui/react/use-render';
|
|
5
|
+
import { cva } from 'class-variance-authority';
|
|
6
|
+
import { jsx } from 'react/jsx-runtime';
|
|
7
|
+
|
|
8
|
+
var itemVariants = cva(
|
|
9
|
+
"[a]:hover:bg-muted rounded-lg border text-sm w-full group/item focus-visible:border-ring focus-visible:ring-ring/50 flex items-center flex-wrap outline-none transition-colors duration-100 focus-visible:ring-3 [a]:transition-colors",
|
|
10
|
+
{
|
|
11
|
+
variants: {
|
|
12
|
+
variant: {
|
|
13
|
+
default: "border-transparent",
|
|
14
|
+
outline: "border-border",
|
|
15
|
+
muted: "bg-muted/50 border-transparent"
|
|
16
|
+
},
|
|
17
|
+
size: {
|
|
18
|
+
default: "gap-2.5 px-3 py-2.5",
|
|
19
|
+
sm: "gap-2.5 px-3 py-2.5",
|
|
20
|
+
xs: "gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
defaultVariants: {
|
|
24
|
+
variant: "default",
|
|
25
|
+
size: "default"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
);
|
|
29
|
+
var itemMediaVariants = cva(
|
|
30
|
+
"gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start flex shrink-0 items-center justify-center [&_svg]:pointer-events-none",
|
|
31
|
+
{
|
|
32
|
+
variants: {
|
|
33
|
+
variant: {
|
|
34
|
+
default: "bg-transparent",
|
|
35
|
+
icon: "[&_svg:not([class*='size-'])]:size-4",
|
|
36
|
+
image: "size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
defaultVariants: {
|
|
40
|
+
variant: "default"
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
);
|
|
44
|
+
function ItemGroup({ className, ...props }) {
|
|
45
|
+
return /* @__PURE__ */ jsx(
|
|
46
|
+
"div",
|
|
47
|
+
{
|
|
48
|
+
role: "list",
|
|
49
|
+
"data-slot": "item-group",
|
|
50
|
+
className: cn(
|
|
51
|
+
"group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2",
|
|
52
|
+
className
|
|
53
|
+
),
|
|
54
|
+
...props
|
|
55
|
+
}
|
|
56
|
+
);
|
|
57
|
+
}
|
|
58
|
+
function ItemSeparator({ className, ...props }) {
|
|
59
|
+
return /* @__PURE__ */ jsx(
|
|
60
|
+
Separator,
|
|
61
|
+
{
|
|
62
|
+
"data-slot": "item-separator",
|
|
63
|
+
orientation: "horizontal",
|
|
64
|
+
className: cn("my-2", className),
|
|
65
|
+
...props
|
|
66
|
+
}
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
function Item({
|
|
70
|
+
className,
|
|
71
|
+
variant = "default",
|
|
72
|
+
size = "default",
|
|
73
|
+
render,
|
|
74
|
+
...props
|
|
75
|
+
}) {
|
|
76
|
+
return useRender({
|
|
77
|
+
defaultTagName: "div",
|
|
78
|
+
props: mergeProps(
|
|
79
|
+
{
|
|
80
|
+
className: cn(itemVariants({ variant, size, className }))
|
|
81
|
+
},
|
|
82
|
+
props
|
|
83
|
+
),
|
|
84
|
+
render,
|
|
85
|
+
state: {
|
|
86
|
+
slot: "item",
|
|
87
|
+
variant,
|
|
88
|
+
size
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
function ItemMedia({ className, variant = "default", ...props }) {
|
|
93
|
+
return /* @__PURE__ */ jsx(
|
|
94
|
+
"div",
|
|
95
|
+
{
|
|
96
|
+
"data-slot": "item-media",
|
|
97
|
+
"data-variant": variant,
|
|
98
|
+
className: cn(itemMediaVariants({ variant, className })),
|
|
99
|
+
...props
|
|
100
|
+
}
|
|
101
|
+
);
|
|
102
|
+
}
|
|
103
|
+
function ItemContent({ className, ...props }) {
|
|
104
|
+
return /* @__PURE__ */ jsx(
|
|
105
|
+
"div",
|
|
106
|
+
{
|
|
107
|
+
"data-slot": "item-content",
|
|
108
|
+
className: cn(
|
|
109
|
+
"flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none",
|
|
110
|
+
className
|
|
111
|
+
),
|
|
112
|
+
...props
|
|
113
|
+
}
|
|
114
|
+
);
|
|
115
|
+
}
|
|
116
|
+
function ItemTitle({ className, ...props }) {
|
|
117
|
+
return /* @__PURE__ */ jsx(
|
|
118
|
+
"div",
|
|
119
|
+
{
|
|
120
|
+
"data-slot": "item-title",
|
|
121
|
+
className: cn(
|
|
122
|
+
"line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4",
|
|
123
|
+
className
|
|
124
|
+
),
|
|
125
|
+
...props
|
|
126
|
+
}
|
|
127
|
+
);
|
|
128
|
+
}
|
|
129
|
+
function ItemDescription({ className, ...props }) {
|
|
130
|
+
return /* @__PURE__ */ jsx(
|
|
131
|
+
"p",
|
|
132
|
+
{
|
|
133
|
+
"data-slot": "item-description",
|
|
134
|
+
className: cn(
|
|
135
|
+
"text-muted-foreground [&>a:hover]:text-primary line-clamp-2 text-left text-sm leading-normal font-normal group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4",
|
|
136
|
+
className
|
|
137
|
+
),
|
|
138
|
+
...props
|
|
139
|
+
}
|
|
140
|
+
);
|
|
141
|
+
}
|
|
142
|
+
function ItemActions({ className, ...props }) {
|
|
143
|
+
return /* @__PURE__ */ jsx(
|
|
144
|
+
"div",
|
|
145
|
+
{
|
|
146
|
+
"data-slot": "item-actions",
|
|
147
|
+
className: cn("flex items-center gap-2", className),
|
|
148
|
+
...props
|
|
149
|
+
}
|
|
150
|
+
);
|
|
151
|
+
}
|
|
152
|
+
function ItemHeader({ className, ...props }) {
|
|
153
|
+
return /* @__PURE__ */ jsx(
|
|
154
|
+
"div",
|
|
155
|
+
{
|
|
156
|
+
"data-slot": "item-header",
|
|
157
|
+
className: cn(
|
|
158
|
+
"flex basis-full items-center justify-between gap-2",
|
|
159
|
+
className
|
|
160
|
+
),
|
|
161
|
+
...props
|
|
162
|
+
}
|
|
163
|
+
);
|
|
164
|
+
}
|
|
165
|
+
function ItemFooter({ className, ...props }) {
|
|
166
|
+
return /* @__PURE__ */ jsx(
|
|
167
|
+
"div",
|
|
168
|
+
{
|
|
169
|
+
"data-slot": "item-footer",
|
|
170
|
+
className: cn(
|
|
171
|
+
"flex basis-full items-center justify-between gap-2",
|
|
172
|
+
className
|
|
173
|
+
),
|
|
174
|
+
...props
|
|
175
|
+
}
|
|
176
|
+
);
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
export { Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle };
|
|
180
|
+
//# sourceMappingURL=item.js.map
|
|
181
|
+
//# sourceMappingURL=item.js.map
|
package/dist/item.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/item.tsx"],"names":[],"mappings":";;;;;;;AAQA,IAAM,YAAA,GAAe,GAAA;AAAA,EACnB,wOAAA;AAAA,EACA;AAAA,IACE,QAAA,EAAU;AAAA,MACR,OAAA,EAAS;AAAA,QACP,OAAA,EAAS,oBAAA;AAAA,QACT,OAAA,EAAS,eAAA;AAAA,QACT,KAAA,EAAO;AAAA,OACT;AAAA,MACA,IAAA,EAAM;AAAA,QACJ,OAAA,EAAS,qBAAA;AAAA,QACT,EAAA,EAAI,qBAAA;AAAA,QACJ,EAAA,EAAI;AAAA;AACN,KACF;AAAA,IACA,eAAA,EAAiB;AAAA,MACf,OAAA,EAAS,SAAA;AAAA,MACT,IAAA,EAAM;AAAA;AACR;AAEJ,CAAA;AAEA,IAAM,iBAAA,GAAoB,GAAA;AAAA,EACxB,gMAAA;AAAA,EACA;AAAA,IACE,QAAA,EAAU;AAAA,MACR,OAAA,EAAS;AAAA,QACP,OAAA,EAAS,gBAAA;AAAA,QACT,IAAA,EAAM,sCAAA;AAAA,QACN,KAAA,EAAO;AAAA;AACT,KACF;AAAA,IACA,eAAA,EAAiB;AAAA,MACf,OAAA,EAAS;AAAA;AACX;AAEJ,CAAA;AAaA,SAAS,SAAA,CAAU,EAAE,SAAA,EAAW,GAAG,OAAM,EAAmB;AAC1D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,IAAA,EAAK,MAAA;AAAA,MACL,WAAA,EAAU,YAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,iGAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,aAAA,CAAc,EAAE,SAAA,EAAW,GAAG,OAAM,EAAuB;AAClE,EAAA,uBACE,GAAA;AAAA,IAAC,SAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,gBAAA;AAAA,MACV,WAAA,EAAY,YAAA;AAAA,MACZ,SAAA,EAAW,EAAA,CAAG,MAAA,EAAQ,SAAS,CAAA;AAAA,MAC9B,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,IAAA,CAAK;AAAA,EACZ,SAAA;AAAA,EACA,OAAA,GAAU,SAAA;AAAA,EACV,IAAA,GAAO,SAAA;AAAA,EACP,MAAA;AAAA,EACA,GAAG;AACL,CAAA,EAAc;AACZ,EAAA,OAAO,SAAA,CAAU;AAAA,IACf,cAAA,EAAgB,KAAA;AAAA,IAChB,KAAA,EAAO,UAAA;AAAA,MACL;AAAA,QACE,SAAA,EAAW,GAAG,YAAA,CAAa,EAAE,SAAS,IAAA,EAAM,SAAA,EAAW,CAAC;AAAA,OAC1D;AAAA,MACA;AAAA,KACF;AAAA,IACA,MAAA;AAAA,IACA,KAAA,EAAO;AAAA,MACL,IAAA,EAAM,MAAA;AAAA,MACN,OAAA;AAAA,MACA;AAAA;AACF,GACD,CAAA;AACH;AAEA,SAAS,UAAU,EAAE,SAAA,EAAW,UAAU,SAAA,EAAW,GAAG,OAAM,EAAmB;AAC/E,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,YAAA;AAAA,MACV,cAAA,EAAc,OAAA;AAAA,MACd,WAAW,EAAA,CAAG,iBAAA,CAAkB,EAAE,OAAA,EAAS,SAAA,EAAW,CAAC,CAAA;AAAA,MACtD,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,WAAA,CAAY,EAAE,SAAA,EAAW,GAAG,OAAM,EAAqB;AAC9D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,cAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,mGAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,SAAA,CAAU,EAAE,SAAA,EAAW,GAAG,OAAM,EAAmB;AAC1D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,YAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,gGAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,eAAA,CAAgB,EAAE,SAAA,EAAW,GAAG,OAAM,EAAyB;AACtE,EAAA,uBACE,GAAA;AAAA,IAAC,GAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,kBAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,qLAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,WAAA,CAAY,EAAE,SAAA,EAAW,GAAG,OAAM,EAAqB;AAC9D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,cAAA;AAAA,MACV,SAAA,EAAW,EAAA,CAAG,yBAAA,EAA2B,SAAS,CAAA;AAAA,MACjD,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,UAAA,CAAW,EAAE,SAAA,EAAW,GAAG,OAAM,EAAoB;AAC5D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,aAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,oDAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,UAAA,CAAW,EAAE,SAAA,EAAW,GAAG,OAAM,EAAoB;AAC5D,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,aAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,oDAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ","file":"item.js","sourcesContent":["import * as React from \"react\"\nimport { mergeProps } from \"@base-ui/react/merge-props\"\nimport { useRender } from \"@base-ui/react/use-render\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { cn } from \"./lib/utils\"\nimport { Separator } from \"./separator\"\n\nconst itemVariants = cva(\n \"[a]:hover:bg-muted rounded-lg border text-sm w-full group/item focus-visible:border-ring focus-visible:ring-ring/50 flex items-center flex-wrap outline-none transition-colors duration-100 focus-visible:ring-3 [a]:transition-colors\",\n {\n variants: {\n variant: {\n default: \"border-transparent\",\n outline: \"border-border\",\n muted: \"bg-muted/50 border-transparent\",\n },\n size: {\n default: \"gap-2.5 px-3 py-2.5\",\n sm: \"gap-2.5 px-3 py-2.5\",\n xs: \"gap-2 px-2.5 py-2 in-data-[slot=dropdown-menu-content]:p-0\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n size: \"default\",\n },\n }\n)\n\nconst itemMediaVariants = cva(\n \"gap-2 group-has-data-[slot=item-description]/item:translate-y-0.5 group-has-data-[slot=item-description]/item:self-start flex shrink-0 items-center justify-center [&_svg]:pointer-events-none\",\n {\n variants: {\n variant: {\n default: \"bg-transparent\",\n icon: \"[&_svg:not([class*='size-'])]:size-4\",\n image: \"size-10 overflow-hidden rounded-sm group-data-[size=sm]/item:size-8 group-data-[size=xs]/item:size-6 [&_img]:size-full [&_img]:object-cover\",\n },\n },\n defaultVariants: {\n variant: \"default\",\n },\n }\n)\n\ntype ItemGroupProps = React.ComponentProps<\"div\">\ntype ItemSeparatorProps = React.ComponentProps<typeof Separator>\ntype ItemProps = useRender.ComponentProps<\"div\"> & VariantProps<typeof itemVariants>\ntype ItemMediaProps = React.ComponentProps<\"div\"> & VariantProps<typeof itemMediaVariants>\ntype ItemContentProps = React.ComponentProps<\"div\">\ntype ItemTitleProps = React.ComponentProps<\"div\">\ntype ItemDescriptionProps = React.ComponentProps<\"p\">\ntype ItemActionsProps = React.ComponentProps<\"div\">\ntype ItemHeaderProps = React.ComponentProps<\"div\">\ntype ItemFooterProps = React.ComponentProps<\"div\">\n\nfunction ItemGroup({ className, ...props }: ItemGroupProps) {\n return (\n <div\n role=\"list\"\n data-slot=\"item-group\"\n className={cn(\n \"group/item-group flex w-full flex-col gap-4 has-data-[size=sm]:gap-2.5 has-data-[size=xs]:gap-2\",\n className\n )}\n {...props}\n />\n )\n}\n\nfunction ItemSeparator({ className, ...props }: ItemSeparatorProps) {\n return (\n <Separator\n data-slot=\"item-separator\"\n orientation=\"horizontal\"\n className={cn(\"my-2\", className)}\n {...props}\n />\n )\n}\n\nfunction Item({\n className,\n variant = \"default\",\n size = \"default\",\n render,\n ...props\n}: ItemProps) {\n return useRender({\n defaultTagName: \"div\",\n props: mergeProps<\"div\">(\n {\n className: cn(itemVariants({ variant, size, className })),\n },\n props\n ),\n render,\n state: {\n slot: \"item\",\n variant,\n size,\n },\n })\n}\n\nfunction ItemMedia({ className, variant = \"default\", ...props }: ItemMediaProps) {\n return (\n <div\n data-slot=\"item-media\"\n data-variant={variant}\n className={cn(itemMediaVariants({ variant, className }))}\n {...props}\n />\n )\n}\n\nfunction ItemContent({ className, ...props }: ItemContentProps) {\n return (\n <div\n data-slot=\"item-content\"\n className={cn(\n \"flex flex-1 flex-col gap-1 group-data-[size=xs]/item:gap-0 [&+[data-slot=item-content]]:flex-none\",\n className\n )}\n {...props}\n />\n )\n}\n\nfunction ItemTitle({ className, ...props }: ItemTitleProps) {\n return (\n <div\n data-slot=\"item-title\"\n className={cn(\n \"line-clamp-1 flex w-fit items-center gap-2 text-sm leading-snug font-medium underline-offset-4\",\n className\n )}\n {...props}\n />\n )\n}\n\nfunction ItemDescription({ className, ...props }: ItemDescriptionProps) {\n return (\n <p\n data-slot=\"item-description\"\n className={cn(\n \"text-muted-foreground [&>a:hover]:text-primary line-clamp-2 text-left text-sm leading-normal font-normal group-data-[size=xs]/item:text-xs [&>a]:underline [&>a]:underline-offset-4\",\n className\n )}\n {...props}\n />\n )\n}\n\nfunction ItemActions({ className, ...props }: ItemActionsProps) {\n return (\n <div\n data-slot=\"item-actions\"\n className={cn(\"flex items-center gap-2\", className)}\n {...props}\n />\n )\n}\n\nfunction ItemHeader({ className, ...props }: ItemHeaderProps) {\n return (\n <div\n data-slot=\"item-header\"\n className={cn(\n \"flex basis-full items-center justify-between gap-2\",\n className\n )}\n {...props}\n />\n )\n}\n\nfunction ItemFooter({ className, ...props }: ItemFooterProps) {\n return (\n <div\n data-slot=\"item-footer\"\n className={cn(\n \"flex basis-full items-center justify-between gap-2\",\n className\n )}\n {...props}\n />\n )\n}\n\nexport {\n Item,\n ItemMedia,\n ItemContent,\n ItemActions,\n ItemGroup,\n ItemSeparator,\n ItemTitle,\n ItemDescription,\n ItemHeader,\n ItemFooter,\n}\n"]}
|
package/dist/kbd.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
|
|
3
|
+
type KbdProps = React.ComponentProps<"kbd">;
|
|
4
|
+
type KbdGroupProps = React.ComponentProps<"div">;
|
|
5
|
+
declare function Kbd({ className, ...props }: KbdProps): react_jsx_runtime.JSX.Element;
|
|
6
|
+
declare function KbdGroup({ className, ...props }: KbdGroupProps): react_jsx_runtime.JSX.Element;
|
|
7
|
+
|
|
8
|
+
export { Kbd, KbdGroup, type KbdGroupProps, type KbdProps };
|
package/dist/kbd.js
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { cn } from './chunk-76UQO56T.js';
|
|
2
|
+
import { jsx } from 'react/jsx-runtime';
|
|
3
|
+
|
|
4
|
+
function Kbd({ className, ...props }) {
|
|
5
|
+
return /* @__PURE__ */ jsx(
|
|
6
|
+
"kbd",
|
|
7
|
+
{
|
|
8
|
+
"data-slot": "kbd",
|
|
9
|
+
className: cn(
|
|
10
|
+
"bg-muted text-muted-foreground in-data-[slot=tooltip-content]:bg-background/20 in-data-[slot=tooltip-content]:text-background dark:in-data-[slot=tooltip-content]:bg-background/10 pointer-events-none inline-flex h-5 w-fit min-w-5 items-center justify-center gap-1 rounded-sm px-1 font-sans text-xs font-medium select-none [&_svg:not([class*='size-'])]:size-3",
|
|
11
|
+
className
|
|
12
|
+
),
|
|
13
|
+
...props
|
|
14
|
+
}
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
function KbdGroup({ className, ...props }) {
|
|
18
|
+
return /* @__PURE__ */ jsx(
|
|
19
|
+
"div",
|
|
20
|
+
{
|
|
21
|
+
"data-slot": "kbd-group",
|
|
22
|
+
className: cn("inline-flex items-center gap-1", className),
|
|
23
|
+
...props
|
|
24
|
+
}
|
|
25
|
+
);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export { Kbd, KbdGroup };
|
|
29
|
+
//# sourceMappingURL=kbd.js.map
|
|
30
|
+
//# sourceMappingURL=kbd.js.map
|
package/dist/kbd.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/kbd.tsx"],"names":[],"mappings":";;;AAMA,SAAS,GAAA,CAAI,EAAE,SAAA,EAAW,GAAG,OAAM,EAAa;AAC9C,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,KAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,uWAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ;AAEA,SAAS,QAAA,CAAS,EAAE,SAAA,EAAW,GAAG,OAAM,EAAkB;AACxD,EAAA,uBACE,GAAA;AAAA,IAAC,KAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,WAAA;AAAA,MACV,SAAA,EAAW,EAAA,CAAG,gCAAA,EAAkC,SAAS,CAAA;AAAA,MACxD,GAAG;AAAA;AAAA,GACN;AAEJ","file":"kbd.js","sourcesContent":["import { cn } from \"./lib/utils\"\n\ntype KbdProps = React.ComponentProps<\"kbd\">\n\ntype KbdGroupProps = React.ComponentProps<\"div\">\n\nfunction Kbd({ className, ...props }: KbdProps) {\n return (\n <kbd\n data-slot=\"kbd\"\n className={cn(\n \"bg-muted text-muted-foreground in-data-[slot=tooltip-content]:bg-background/20 in-data-[slot=tooltip-content]:text-background dark:in-data-[slot=tooltip-content]:bg-background/10 pointer-events-none inline-flex h-5 w-fit min-w-5 items-center justify-center gap-1 rounded-sm px-1 font-sans text-xs font-medium select-none [&_svg:not([class*='size-'])]:size-3\",\n className,\n )}\n {...props}\n />\n )\n}\n\nfunction KbdGroup({ className, ...props }: KbdGroupProps) {\n return (\n <div\n data-slot=\"kbd-group\"\n className={cn(\"inline-flex items-center gap-1\", className)}\n {...props}\n />\n )\n}\n\nexport { Kbd, KbdGroup }\nexport type { KbdProps, KbdGroupProps }\n"]}
|
package/dist/label.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
type LabelProps = React.ComponentProps<"label">;
|
|
5
|
+
declare function Label({ className, ...props }: LabelProps): react_jsx_runtime.JSX.Element;
|
|
5
6
|
|
|
6
7
|
export { Label };
|
package/dist/label.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/label.tsx"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"sources":["../src/label.tsx"],"names":[],"mappings":";;;AAQA,SAAS,KAAA,CAAM,EAAE,SAAA,EAAW,GAAG,OAAM,EAAe;AAClD,EAAA,uBACE,GAAA;AAAA,IAAC,OAAA;AAAA,IAAA;AAAA,MACC,WAAA,EAAU,OAAA;AAAA,MACV,SAAA,EAAW,EAAA;AAAA,QACT,qNAAA;AAAA,QACA;AAAA,OACF;AAAA,MACC,GAAG;AAAA;AAAA,GACN;AAEJ","file":"label.js","sourcesContent":["\"use client\"\n\nimport * as React from \"react\"\n\nimport { cn } from \"./lib/utils\"\n\ntype LabelProps = React.ComponentProps<\"label\">\n\nfunction Label({ className, ...props }: LabelProps) {\n return (\n <label\n data-slot=\"label\"\n className={cn(\n \"flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50\",\n className\n )}\n {...props}\n />\n )\n}\n\nexport { Label }\n"]}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { HTMLMotionProps } from 'motion/react';
|
|
4
|
+
|
|
5
|
+
type MasonryProps = React.ComponentProps<"div"> & {
|
|
6
|
+
columns?: number;
|
|
7
|
+
columnWidth?: number;
|
|
8
|
+
gap?: number;
|
|
9
|
+
};
|
|
10
|
+
type MasonryItemProps = Omit<HTMLMotionProps<"div">, "children"> & {
|
|
11
|
+
span?: number;
|
|
12
|
+
children?: React.ReactNode;
|
|
13
|
+
};
|
|
14
|
+
declare function Masonry({ columns, columnWidth, gap, className, children, ...props }: MasonryProps): react_jsx_runtime.JSX.Element;
|
|
15
|
+
declare function MasonryItem({ className, span, children, ...props }: MasonryItemProps): react_jsx_runtime.JSX.Element;
|
|
16
|
+
|
|
17
|
+
export { Masonry, MasonryItem };
|