@nexus-cross/design-system 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cursor-rules/nexus-project-setup.mdc +292 -0
- package/cursor-rules/nexus-ui-api.mdc +698 -0
- package/cursor-rules/nexus-ui-components.mdc +136 -0
- package/dist/accordion.d.mts +28 -0
- package/dist/accordion.d.ts +28 -0
- package/dist/accordion.js +28 -0
- package/dist/accordion.mjs +3 -0
- package/dist/avatar.d.mts +17 -0
- package/dist/avatar.d.ts +17 -0
- package/dist/avatar.js +16 -0
- package/dist/avatar.mjs +3 -0
- package/dist/button.d.mts +17 -0
- package/dist/button.d.ts +17 -0
- package/dist/button.js +16 -0
- package/dist/button.mjs +3 -0
- package/dist/carousel.d.mts +36 -0
- package/dist/carousel.d.ts +36 -0
- package/dist/carousel.js +32 -0
- package/dist/carousel.mjs +3 -0
- package/dist/checkbox.d.mts +21 -0
- package/dist/checkbox.d.ts +21 -0
- package/dist/checkbox.js +20 -0
- package/dist/checkbox.mjs +3 -0
- package/dist/chip.d.mts +16 -0
- package/dist/chip.d.ts +16 -0
- package/dist/chip.js +16 -0
- package/dist/chip.mjs +3 -0
- package/dist/chunks/chunk-22ULI3BF.js +21 -0
- package/dist/chunks/chunk-26BUGBOY.mjs +57 -0
- package/dist/chunks/chunk-2JTPRBHZ.mjs +36 -0
- package/dist/chunks/chunk-2MC7XJSE.js +98 -0
- package/dist/chunks/chunk-2RPRCWKV.mjs +139 -0
- package/dist/chunks/chunk-2ZXDXO4I.js +166 -0
- package/dist/chunks/chunk-33UFQJIO.mjs +135 -0
- package/dist/chunks/chunk-3HHJORN7.mjs +137 -0
- package/dist/chunks/chunk-3PCNRCTB.js +61 -0
- package/dist/chunks/chunk-3VFBPFZF.mjs +640 -0
- package/dist/chunks/chunk-4J3GCZ7W.mjs +102 -0
- package/dist/chunks/chunk-54IA2P2Z.mjs +40 -0
- package/dist/chunks/chunk-54RBL7J4.mjs +179 -0
- package/dist/chunks/chunk-5JHJNN2K.js +83 -0
- package/dist/chunks/chunk-5JHN4FCY.mjs +58 -0
- package/dist/chunks/chunk-6FMDO6TT.mjs +114 -0
- package/dist/chunks/chunk-6H7V2I3X.mjs +270 -0
- package/dist/chunks/chunk-7AISZYWL.js +7 -0
- package/dist/chunks/chunk-7G65JBTN.js +133 -0
- package/dist/chunks/chunk-ADO7PDLY.mjs +66 -0
- package/dist/chunks/chunk-AFSEYJZT.js +267 -0
- package/dist/chunks/chunk-AOXXE5UQ.mjs +14 -0
- package/dist/chunks/chunk-AZ2URLDD.js +39 -0
- package/dist/chunks/chunk-B6G5TJRO.js +116 -0
- package/dist/chunks/chunk-BLGQHR3M.js +56 -0
- package/dist/chunks/chunk-BPUQ2CO2.mjs +48 -0
- package/dist/chunks/chunk-BSZ2LN6E.js +129 -0
- package/dist/chunks/chunk-CA3SOLI3.mjs +78 -0
- package/dist/chunks/chunk-CSJDDREF.js +90 -0
- package/dist/chunks/chunk-CVYXRSXT.mjs +8 -0
- package/dist/chunks/chunk-CZC76ZD5.js +10 -0
- package/dist/chunks/chunk-D6FII7HW.js +202 -0
- package/dist/chunks/chunk-DLFV7ZZV.js +112 -0
- package/dist/chunks/chunk-DO6VK2QQ.mjs +108 -0
- package/dist/chunks/chunk-ECVAVQUY.mjs +243 -0
- package/dist/chunks/chunk-EHAUUUWB.mjs +120 -0
- package/dist/chunks/chunk-EVOOTSY5.js +59 -0
- package/dist/chunks/chunk-GX6GSWX3.mjs +38 -0
- package/dist/chunks/chunk-HHXDOKXY.js +108 -0
- package/dist/chunks/chunk-HNLI646G.mjs +325 -0
- package/dist/chunks/chunk-HUPAHDJ7.js +273 -0
- package/dist/chunks/chunk-I252NERB.mjs +21 -0
- package/dist/chunks/chunk-IE4DGLMH.js +75 -0
- package/dist/chunks/chunk-INP2AH3B.js +27 -0
- package/dist/chunks/chunk-IOSIQLZL.js +70 -0
- package/dist/chunks/chunk-J5ZKGPBY.js +132 -0
- package/dist/chunks/chunk-JNMCYWGY.js +10 -0
- package/dist/chunks/chunk-LI7SFBUQ.mjs +89 -0
- package/dist/chunks/chunk-LMMON5AU.mjs +81 -0
- package/dist/chunks/chunk-LOQXCHKL.js +74 -0
- package/dist/chunks/chunk-MA2VCCIY.js +71 -0
- package/dist/chunks/chunk-MCKOWMLS.mjs +8 -0
- package/dist/chunks/chunk-MRRKW5QN.mjs +108 -0
- package/dist/chunks/chunk-MTX7GD3H.js +80 -0
- package/dist/chunks/chunk-NFIPQZ4O.js +100 -0
- package/dist/chunks/chunk-NHDGKOAM.js +104 -0
- package/dist/chunks/chunk-OMN5YQCE.js +143 -0
- package/dist/chunks/chunk-OTGS6BDQ.mjs +25 -0
- package/dist/chunks/chunk-P2T72N62.mjs +34 -0
- package/dist/chunks/chunk-P3DZKXG4.js +116 -0
- package/dist/chunks/chunk-QK6NCII4.js +36 -0
- package/dist/chunks/chunk-QZ4QR3XV.mjs +142 -0
- package/dist/chunks/chunk-RS3SBY3I.js +163 -0
- package/dist/chunks/chunk-RX5UKRYK.mjs +76 -0
- package/dist/chunks/chunk-SGNRVYYQ.mjs +99 -0
- package/dist/chunks/chunk-SJMCPSVH.mjs +76 -0
- package/dist/chunks/chunk-T2IY2TSR.js +43 -0
- package/dist/chunks/chunk-U53UA76K.js +653 -0
- package/dist/chunks/chunk-U56AGSLE.mjs +106 -0
- package/dist/chunks/chunk-ULGYTBCT.mjs +47 -0
- package/dist/chunks/chunk-V5OTJP6H.mjs +5 -0
- package/dist/chunks/chunk-VGO4Z2WH.js +336 -0
- package/dist/chunks/chunk-VIGRCJAE.mjs +37 -0
- package/dist/chunks/chunk-VVXQZ4XH.mjs +93 -0
- package/dist/chunks/chunk-W4GG5A7K.mjs +51 -0
- package/dist/chunks/chunk-WKCXACMZ.js +99 -0
- package/dist/chunks/chunk-WR55D4ZS.js +80 -0
- package/dist/chunks/chunk-X2SHTVZQ.js +89 -0
- package/dist/chunks/chunk-XEHFB62A.js +82 -0
- package/dist/chunks/chunk-XG6QG65W.mjs +63 -0
- package/dist/chunks/chunk-YB5ZKHVB.js +64 -0
- package/dist/chunks/chunk-YCG4FZC3.js +167 -0
- package/dist/chunks/chunk-YEWKPWK3.mjs +80 -0
- package/dist/chunks/chunk-YLO4UKSC.mjs +48 -0
- package/dist/chunks/chunk-YZV6FWE7.js +160 -0
- package/dist/chunks/chunk-ZWSIIGA3.mjs +58 -0
- package/dist/client-only.d.mts +13 -0
- package/dist/client-only.d.ts +13 -0
- package/dist/client-only.js +11 -0
- package/dist/client-only.mjs +2 -0
- package/dist/countdown.d.mts +27 -0
- package/dist/countdown.d.ts +27 -0
- package/dist/countdown.js +16 -0
- package/dist/countdown.mjs +3 -0
- package/dist/counter.d.mts +15 -0
- package/dist/counter.d.ts +15 -0
- package/dist/counter.js +11 -0
- package/dist/counter.mjs +2 -0
- package/dist/data-list.d.mts +33 -0
- package/dist/data-list.d.ts +33 -0
- package/dist/data-list.js +14 -0
- package/dist/data-list.mjs +5 -0
- package/dist/divider.d.mts +14 -0
- package/dist/divider.d.ts +14 -0
- package/dist/divider.js +16 -0
- package/dist/divider.mjs +3 -0
- package/dist/drawer.d.mts +42 -0
- package/dist/drawer.d.ts +42 -0
- package/dist/drawer.js +44 -0
- package/dist/drawer.mjs +3 -0
- package/dist/ellipsis.d.mts +16 -0
- package/dist/ellipsis.d.ts +16 -0
- package/dist/ellipsis.js +12 -0
- package/dist/ellipsis.mjs +3 -0
- package/dist/error-boundary.d.mts +20 -0
- package/dist/error-boundary.d.ts +20 -0
- package/dist/error-boundary.js +11 -0
- package/dist/error-boundary.mjs +2 -0
- package/dist/hooks/useCheckDevice.d.mts +47 -0
- package/dist/hooks/useCheckDevice.d.ts +47 -0
- package/dist/hooks/useCheckDevice.js +8 -0
- package/dist/hooks/useCheckDevice.mjs +2 -0
- package/dist/hooks/useClickOutside.d.mts +12 -0
- package/dist/hooks/useClickOutside.d.ts +12 -0
- package/dist/hooks/useClickOutside.js +8 -0
- package/dist/hooks/useClickOutside.mjs +2 -0
- package/dist/hooks/useDraggableBottomSheet.d.mts +24 -0
- package/dist/hooks/useDraggableBottomSheet.d.ts +24 -0
- package/dist/hooks/useDraggableBottomSheet.js +11 -0
- package/dist/hooks/useDraggableBottomSheet.mjs +2 -0
- package/dist/hooks/useDraggableWindow.d.mts +21 -0
- package/dist/hooks/useDraggableWindow.d.ts +21 -0
- package/dist/hooks/useDraggableWindow.js +11 -0
- package/dist/hooks/useDraggableWindow.mjs +2 -0
- package/dist/hooks/useInView.d.mts +14 -0
- package/dist/hooks/useInView.d.ts +14 -0
- package/dist/hooks/useInView.js +17 -0
- package/dist/hooks/useInView.mjs +2 -0
- package/dist/hooks/useModal.d.mts +2 -0
- package/dist/hooks/useModal.d.ts +2 -0
- package/dist/hooks/useModal.js +11 -0
- package/dist/hooks/useModal.mjs +2 -0
- package/dist/index.d.mts +76 -0
- package/dist/index.d.ts +76 -0
- package/dist/index.js +746 -0
- package/dist/index.mjs +328 -0
- package/dist/infinite-scroll.d.mts +26 -0
- package/dist/infinite-scroll.d.ts +26 -0
- package/dist/infinite-scroll.js +12 -0
- package/dist/infinite-scroll.mjs +3 -0
- package/dist/marquee.d.mts +12 -0
- package/dist/marquee.d.ts +12 -0
- package/dist/marquee.js +12 -0
- package/dist/marquee.mjs +3 -0
- package/dist/modal/index.d.mts +87 -0
- package/dist/modal/index.d.ts +87 -0
- package/dist/modal/index.js +54 -0
- package/dist/modal/index.mjs +9 -0
- package/dist/number-input.d.mts +38 -0
- package/dist/number-input.d.ts +38 -0
- package/dist/number-input.js +20 -0
- package/dist/number-input.mjs +3 -0
- package/dist/pagination.d.mts +22 -0
- package/dist/pagination.d.ts +22 -0
- package/dist/pagination.js +20 -0
- package/dist/pagination.mjs +3 -0
- package/dist/popover.d.mts +25 -0
- package/dist/popover.d.ts +25 -0
- package/dist/popover.js +32 -0
- package/dist/popover.mjs +3 -0
- package/dist/radio-group.d.mts +29 -0
- package/dist/radio-group.d.ts +29 -0
- package/dist/radio-group.js +24 -0
- package/dist/radio-group.mjs +3 -0
- package/dist/schemas/_all.json +2250 -0
- package/dist/schemas/accordion.json +101 -0
- package/dist/schemas/avatar.json +55 -0
- package/dist/schemas/button.json +71 -0
- package/dist/schemas/carousel.json +32 -0
- package/dist/schemas/carouselButton.json +20 -0
- package/dist/schemas/carouselDots.json +17 -0
- package/dist/schemas/carouselSlide.json +20 -0
- package/dist/schemas/checkBox.json +57 -0
- package/dist/schemas/chip.json +49 -0
- package/dist/schemas/clientOnly.json +19 -0
- package/dist/schemas/countdown.json +58 -0
- package/dist/schemas/counter.json +57 -0
- package/dist/schemas/dataList.json +56 -0
- package/dist/schemas/divider.json +40 -0
- package/dist/schemas/drawer.json +27 -0
- package/dist/schemas/drawerContent.json +50 -0
- package/dist/schemas/ellipsis.json +49 -0
- package/dist/schemas/errorBoundary.json +22 -0
- package/dist/schemas/infiniteScroll.json +65 -0
- package/dist/schemas/marquee.json +46 -0
- package/dist/schemas/modalCall.json +21 -0
- package/dist/schemas/modalTemplate.json +123 -0
- package/dist/schemas/numberInput.json +77 -0
- package/dist/schemas/pagination.json +50 -0
- package/dist/schemas/popover.json +67 -0
- package/dist/schemas/radioGroup.json +61 -0
- package/dist/schemas/radioItem.json +35 -0
- package/dist/schemas/select.json +62 -0
- package/dist/schemas/selectItem.json +31 -0
- package/dist/schemas/skeleton.json +48 -0
- package/dist/schemas/spinner.json +27 -0
- package/dist/schemas/switch.json +41 -0
- package/dist/schemas/tab.json +89 -0
- package/dist/schemas/table.json +75 -0
- package/dist/schemas/tableRow.json +32 -0
- package/dist/schemas/tdColumn.json +107 -0
- package/dist/schemas/textArea.json +44 -0
- package/dist/schemas/textInput.json +67 -0
- package/dist/schemas/themeProvider.json +65 -0
- package/dist/schemas/toaster.json +31 -0
- package/dist/schemas/tooltip.json +67 -0
- package/dist/schemas/virtualGrid.json +59 -0
- package/dist/schemas/virtualList.json +54 -0
- package/dist/schemas.d.mts +1263 -0
- package/dist/schemas.d.ts +1263 -0
- package/dist/schemas.js +513 -0
- package/dist/schemas.mjs +469 -0
- package/dist/select.d.mts +31 -0
- package/dist/select.d.ts +31 -0
- package/dist/select.js +24 -0
- package/dist/select.mjs +3 -0
- package/dist/skeleton.d.mts +15 -0
- package/dist/skeleton.d.ts +15 -0
- package/dist/skeleton.js +12 -0
- package/dist/skeleton.mjs +3 -0
- package/dist/spinner.d.mts +9 -0
- package/dist/spinner.d.ts +9 -0
- package/dist/spinner.js +12 -0
- package/dist/spinner.mjs +3 -0
- package/dist/styles/layer.d.mts +3 -0
- package/dist/styles/layer.d.ts +3 -0
- package/dist/styles/layer.js +18 -0
- package/dist/styles/layer.mjs +16 -0
- package/dist/styles.css +2401 -0
- package/dist/styles.d.mts +3 -0
- package/dist/styles.d.ts +3 -0
- package/dist/styles.js +16 -0
- package/dist/styles.layered.css +2404 -0
- package/dist/styles.mjs +14 -0
- package/dist/switch.d.mts +15 -0
- package/dist/switch.d.ts +15 -0
- package/dist/switch.js +16 -0
- package/dist/switch.mjs +3 -0
- package/dist/tab.d.mts +36 -0
- package/dist/tab.d.ts +36 -0
- package/dist/tab.js +20 -0
- package/dist/tab.mjs +3 -0
- package/dist/table.d.mts +80 -0
- package/dist/table.d.ts +80 -0
- package/dist/table.js +33 -0
- package/dist/table.mjs +4 -0
- package/dist/text-area.d.mts +15 -0
- package/dist/text-area.d.ts +15 -0
- package/dist/text-area.js +16 -0
- package/dist/text-area.mjs +3 -0
- package/dist/text-input.d.mts +21 -0
- package/dist/text-input.d.ts +21 -0
- package/dist/text-input.js +16 -0
- package/dist/text-input.mjs +3 -0
- package/dist/theme-provider.d.mts +25 -0
- package/dist/theme-provider.d.ts +25 -0
- package/dist/theme-provider.js +15 -0
- package/dist/theme-provider.mjs +2 -0
- package/dist/toast.d.mts +42 -0
- package/dist/toast.d.ts +42 -0
- package/dist/toast.js +20 -0
- package/dist/toast.mjs +3 -0
- package/dist/tooltip.d.mts +24 -0
- package/dist/tooltip.d.ts +24 -0
- package/dist/tooltip.js +20 -0
- package/dist/tooltip.mjs +3 -0
- package/dist/useModal-BsGIcP8t.d.mts +128 -0
- package/dist/useModal-BsGIcP8t.d.ts +128 -0
- package/dist/utils/cn.d.mts +5 -0
- package/dist/utils/cn.d.ts +5 -0
- package/dist/utils/cn.js +11 -0
- package/dist/utils/cn.mjs +2 -0
- package/dist/utils/scroll.d.mts +4 -0
- package/dist/utils/scroll.d.ts +4 -0
- package/dist/utils/scroll.js +15 -0
- package/dist/utils/scroll.mjs +2 -0
- package/dist/virtual-scroll.d.mts +34 -0
- package/dist/virtual-scroll.d.ts +34 -0
- package/dist/virtual-scroll.js +16 -0
- package/dist/virtual-scroll.mjs +3 -0
- package/package.json +291 -0
- package/scripts/setup-cursor-rules.cjs +92 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkCZC76ZD5_js = require('./chunk-CZC76ZD5.js');
|
|
4
|
+
var React = require('react');
|
|
5
|
+
var classVarianceAuthority = require('class-variance-authority');
|
|
6
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
7
|
+
|
|
8
|
+
function _interopNamespace(e) {
|
|
9
|
+
if (e && e.__esModule) return e;
|
|
10
|
+
var n = Object.create(null);
|
|
11
|
+
if (e) {
|
|
12
|
+
Object.keys(e).forEach(function (k) {
|
|
13
|
+
if (k !== 'default') {
|
|
14
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
15
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
16
|
+
enumerable: true,
|
|
17
|
+
get: function () { return e[k]; }
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
n.default = e;
|
|
23
|
+
return Object.freeze(n);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
27
|
+
|
|
28
|
+
var radioGroupVariants = classVarianceAuthority.cva("nexus-radio-group", {
|
|
29
|
+
variants: {
|
|
30
|
+
orientation: {
|
|
31
|
+
horizontal: "nexus-radio-group--horizontal",
|
|
32
|
+
vertical: "nexus-radio-group--vertical"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
defaultVariants: { orientation: "vertical" }
|
|
36
|
+
});
|
|
37
|
+
var radioItemVariants = classVarianceAuthority.cva("nexus-radio-item", {
|
|
38
|
+
variants: {
|
|
39
|
+
size: {
|
|
40
|
+
sm: "nexus-radio-item--sm",
|
|
41
|
+
md: "nexus-radio-item--md"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
defaultVariants: { size: "md" }
|
|
45
|
+
});
|
|
46
|
+
var RadioGroupCtx = React__namespace.createContext({
|
|
47
|
+
name: ""
|
|
48
|
+
});
|
|
49
|
+
var RadioGroup = React__namespace.forwardRef(
|
|
50
|
+
({
|
|
51
|
+
className,
|
|
52
|
+
orientation,
|
|
53
|
+
name,
|
|
54
|
+
value: controlledValue,
|
|
55
|
+
defaultValue,
|
|
56
|
+
size = "md",
|
|
57
|
+
disabled,
|
|
58
|
+
onValueChange,
|
|
59
|
+
children,
|
|
60
|
+
...props
|
|
61
|
+
}, ref) => {
|
|
62
|
+
const [uncontrolled, setUncontrolled] = React__namespace.useState(defaultValue ?? "");
|
|
63
|
+
const isControlled = controlledValue !== void 0;
|
|
64
|
+
const value = isControlled ? controlledValue : uncontrolled;
|
|
65
|
+
const handleChange = React__namespace.useCallback(
|
|
66
|
+
(v) => {
|
|
67
|
+
if (!isControlled) setUncontrolled(v);
|
|
68
|
+
onValueChange?.(v);
|
|
69
|
+
},
|
|
70
|
+
[isControlled, onValueChange]
|
|
71
|
+
);
|
|
72
|
+
const ctx = React__namespace.useMemo(
|
|
73
|
+
() => ({ name, value, size, disabled, onValueChange: handleChange }),
|
|
74
|
+
[name, value, size, disabled, handleChange]
|
|
75
|
+
);
|
|
76
|
+
return /* @__PURE__ */ jsxRuntime.jsx(RadioGroupCtx.Provider, { value: ctx, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
77
|
+
"div",
|
|
78
|
+
{
|
|
79
|
+
ref,
|
|
80
|
+
role: "radiogroup",
|
|
81
|
+
className: chunkCZC76ZD5_js.cn(radioGroupVariants({ orientation }), className),
|
|
82
|
+
...props,
|
|
83
|
+
children
|
|
84
|
+
}
|
|
85
|
+
) });
|
|
86
|
+
}
|
|
87
|
+
);
|
|
88
|
+
RadioGroup.displayName = "RadioGroup";
|
|
89
|
+
var RadioItem = React__namespace.forwardRef(
|
|
90
|
+
({
|
|
91
|
+
className,
|
|
92
|
+
value,
|
|
93
|
+
size: sizeProp,
|
|
94
|
+
disabled: disabledProp,
|
|
95
|
+
label,
|
|
96
|
+
children,
|
|
97
|
+
...props
|
|
98
|
+
}, ref) => {
|
|
99
|
+
const ctx = React__namespace.useContext(RadioGroupCtx);
|
|
100
|
+
const size = sizeProp ?? ctx.size ?? "md";
|
|
101
|
+
const disabled = disabledProp ?? ctx.disabled;
|
|
102
|
+
const checked = ctx.value === value;
|
|
103
|
+
const content = label ?? children;
|
|
104
|
+
const handleChange = React__namespace.useCallback(() => {
|
|
105
|
+
ctx.onValueChange?.(value);
|
|
106
|
+
}, [ctx, value]);
|
|
107
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
108
|
+
"label",
|
|
109
|
+
{
|
|
110
|
+
className: chunkCZC76ZD5_js.cn(
|
|
111
|
+
radioItemVariants({ size }),
|
|
112
|
+
disabled ? "nexus-radio-item--disabled" : "nexus-radio-item--pointer",
|
|
113
|
+
className
|
|
114
|
+
),
|
|
115
|
+
children: [
|
|
116
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
117
|
+
"input",
|
|
118
|
+
{
|
|
119
|
+
ref,
|
|
120
|
+
type: "radio",
|
|
121
|
+
className: "nexus-sr-only",
|
|
122
|
+
name: ctx.name,
|
|
123
|
+
value,
|
|
124
|
+
checked,
|
|
125
|
+
disabled,
|
|
126
|
+
onChange: handleChange,
|
|
127
|
+
...props
|
|
128
|
+
}
|
|
129
|
+
),
|
|
130
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
131
|
+
"span",
|
|
132
|
+
{
|
|
133
|
+
className: chunkCZC76ZD5_js.cn(
|
|
134
|
+
size === "sm" ? "nexus-radio__circle--sm" : "nexus-radio__circle--md",
|
|
135
|
+
"nexus-radio__circle",
|
|
136
|
+
checked ? "nexus-radio__circle--checked" : "nexus-radio__circle--unchecked"
|
|
137
|
+
),
|
|
138
|
+
children: checked && /* @__PURE__ */ jsxRuntime.jsx(
|
|
139
|
+
"span",
|
|
140
|
+
{
|
|
141
|
+
className: chunkCZC76ZD5_js.cn(
|
|
142
|
+
"nexus-radio__dot",
|
|
143
|
+
size === "sm" ? "nexus-radio__dot--sm" : "nexus-radio__dot--md"
|
|
144
|
+
)
|
|
145
|
+
}
|
|
146
|
+
)
|
|
147
|
+
}
|
|
148
|
+
),
|
|
149
|
+
content && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "nexus-radio__label", children: content })
|
|
150
|
+
]
|
|
151
|
+
}
|
|
152
|
+
);
|
|
153
|
+
}
|
|
154
|
+
);
|
|
155
|
+
RadioItem.displayName = "RadioItem";
|
|
156
|
+
|
|
157
|
+
exports.RadioGroup = RadioGroup;
|
|
158
|
+
exports.RadioItem = RadioItem;
|
|
159
|
+
exports.radioGroupVariants = radioGroupVariants;
|
|
160
|
+
exports.radioItemVariants = radioItemVariants;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { cn } from './chunk-MCKOWMLS.mjs';
|
|
2
|
+
import { Toaster as Toaster$1, toast } from 'sonner';
|
|
3
|
+
export { toast } from 'sonner';
|
|
4
|
+
import { jsx } from 'react/jsx-runtime';
|
|
5
|
+
|
|
6
|
+
function Toaster({
|
|
7
|
+
position = "top-center",
|
|
8
|
+
unstyled = false,
|
|
9
|
+
toastOptions,
|
|
10
|
+
...props
|
|
11
|
+
}) {
|
|
12
|
+
return /* @__PURE__ */ jsx(
|
|
13
|
+
Toaster$1,
|
|
14
|
+
{
|
|
15
|
+
position,
|
|
16
|
+
toastOptions: {
|
|
17
|
+
unstyled,
|
|
18
|
+
...toastOptions,
|
|
19
|
+
classNames: {
|
|
20
|
+
toast: cn(!unstyled && "nexus-toast", toastOptions?.classNames?.toast),
|
|
21
|
+
title: cn(!unstyled && "nexus-toast__title", toastOptions?.classNames?.title),
|
|
22
|
+
description: cn(!unstyled && "nexus-toast__desc", toastOptions?.classNames?.description),
|
|
23
|
+
success: cn(!unstyled && "nexus-toast--success", toastOptions?.classNames?.success),
|
|
24
|
+
error: cn(!unstyled && "nexus-toast--error", toastOptions?.classNames?.error),
|
|
25
|
+
warning: cn(!unstyled && "nexus-toast--warning", toastOptions?.classNames?.warning),
|
|
26
|
+
info: cn(!unstyled && "nexus-toast--info", toastOptions?.classNames?.info),
|
|
27
|
+
actionButton: cn(!unstyled && "nexus-toast__action-btn", toastOptions?.classNames?.actionButton),
|
|
28
|
+
cancelButton: cn(!unstyled && "nexus-toast__cancel-btn", toastOptions?.classNames?.cancelButton),
|
|
29
|
+
closeButton: cn(!unstyled && "nexus-toast__close-btn", toastOptions?.classNames?.closeButton),
|
|
30
|
+
...toastOptions?.classNames
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
...props
|
|
34
|
+
}
|
|
35
|
+
);
|
|
36
|
+
}
|
|
37
|
+
function useToast() {
|
|
38
|
+
const showToast = (message, options) => toast(message, options);
|
|
39
|
+
const successToast = (message, options) => toast.success(message, options);
|
|
40
|
+
const errorToast = (message, options) => toast.error(message, options);
|
|
41
|
+
const warningToast = (message, options) => toast.warning(message, options);
|
|
42
|
+
const infoToast = (message, options) => toast.info(message, options);
|
|
43
|
+
const promiseToast = (promise, msgs, options) => toast.promise(promise, { ...msgs, ...options });
|
|
44
|
+
const customToast = (jsx2, options) => toast.custom(jsx2, options);
|
|
45
|
+
const dismissToast = (id) => toast.dismiss(id);
|
|
46
|
+
return {
|
|
47
|
+
toast: showToast,
|
|
48
|
+
successToast,
|
|
49
|
+
errorToast,
|
|
50
|
+
warningToast,
|
|
51
|
+
infoToast,
|
|
52
|
+
promiseToast,
|
|
53
|
+
customToast,
|
|
54
|
+
dismissToast
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export { Toaster, useToast };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface ClientOnlyProps {
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
fallback?: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
declare function ClientOnly({ children, fallback }: ClientOnlyProps): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare namespace ClientOnly {
|
|
10
|
+
var displayName: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { ClientOnly, type ClientOnlyProps };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface ClientOnlyProps {
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
fallback?: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
declare function ClientOnly({ children, fallback }: ClientOnlyProps): react_jsx_runtime.JSX.Element;
|
|
9
|
+
declare namespace ClientOnly {
|
|
10
|
+
var displayName: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { ClientOnly, type ClientOnlyProps };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkQK6NCII4_js = require('./chunks/chunk-QK6NCII4.js');
|
|
4
|
+
require('./chunks/chunk-JNMCYWGY.js');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
Object.defineProperty(exports, "ClientOnly", {
|
|
9
|
+
enumerable: true,
|
|
10
|
+
get: function () { return chunkQK6NCII4_js.ClientOnly; }
|
|
11
|
+
});
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface TimeLeft {
|
|
4
|
+
days: number;
|
|
5
|
+
hours: number;
|
|
6
|
+
minutes: number;
|
|
7
|
+
seconds: number;
|
|
8
|
+
total: number;
|
|
9
|
+
isFinished: boolean;
|
|
10
|
+
}
|
|
11
|
+
declare function useCountdown(endTimestamp: number, onEnd?: () => void): TimeLeft;
|
|
12
|
+
interface CountdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
13
|
+
endTimestamp: number;
|
|
14
|
+
separator?: React.ReactNode;
|
|
15
|
+
showDays?: boolean;
|
|
16
|
+
labels?: {
|
|
17
|
+
days?: string;
|
|
18
|
+
hours?: string;
|
|
19
|
+
minutes?: string;
|
|
20
|
+
seconds?: string;
|
|
21
|
+
};
|
|
22
|
+
onEnd?: () => void;
|
|
23
|
+
render?: (timeLeft: TimeLeft) => React.ReactNode;
|
|
24
|
+
}
|
|
25
|
+
declare const Countdown: React.ForwardRefExoticComponent<CountdownProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
|
|
27
|
+
export { Countdown, type CountdownProps, type TimeLeft, useCountdown };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface TimeLeft {
|
|
4
|
+
days: number;
|
|
5
|
+
hours: number;
|
|
6
|
+
minutes: number;
|
|
7
|
+
seconds: number;
|
|
8
|
+
total: number;
|
|
9
|
+
isFinished: boolean;
|
|
10
|
+
}
|
|
11
|
+
declare function useCountdown(endTimestamp: number, onEnd?: () => void): TimeLeft;
|
|
12
|
+
interface CountdownProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
13
|
+
endTimestamp: number;
|
|
14
|
+
separator?: React.ReactNode;
|
|
15
|
+
showDays?: boolean;
|
|
16
|
+
labels?: {
|
|
17
|
+
days?: string;
|
|
18
|
+
hours?: string;
|
|
19
|
+
minutes?: string;
|
|
20
|
+
seconds?: string;
|
|
21
|
+
};
|
|
22
|
+
onEnd?: () => void;
|
|
23
|
+
render?: (timeLeft: TimeLeft) => React.ReactNode;
|
|
24
|
+
}
|
|
25
|
+
declare const Countdown: React.ForwardRefExoticComponent<CountdownProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
|
|
27
|
+
export { Countdown, type CountdownProps, type TimeLeft, useCountdown };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkDLFV7ZZV_js = require('./chunks/chunk-DLFV7ZZV.js');
|
|
4
|
+
require('./chunks/chunk-CZC76ZD5.js');
|
|
5
|
+
require('./chunks/chunk-JNMCYWGY.js');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(exports, "Countdown", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function () { return chunkDLFV7ZZV_js.Countdown; }
|
|
12
|
+
});
|
|
13
|
+
Object.defineProperty(exports, "useCountdown", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () { return chunkDLFV7ZZV_js.useCountdown; }
|
|
16
|
+
});
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface CounterProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
4
|
+
startValue?: number;
|
|
5
|
+
endValue: number;
|
|
6
|
+
duration?: number;
|
|
7
|
+
delay?: number;
|
|
8
|
+
separator?: boolean;
|
|
9
|
+
digits?: number;
|
|
10
|
+
triggerOnView?: boolean;
|
|
11
|
+
onEnd?: () => void;
|
|
12
|
+
}
|
|
13
|
+
declare const Counter: React.ForwardRefExoticComponent<CounterProps & React.RefAttributes<HTMLSpanElement>>;
|
|
14
|
+
|
|
15
|
+
export { Counter, type CounterProps };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface CounterProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
4
|
+
startValue?: number;
|
|
5
|
+
endValue: number;
|
|
6
|
+
duration?: number;
|
|
7
|
+
delay?: number;
|
|
8
|
+
separator?: boolean;
|
|
9
|
+
digits?: number;
|
|
10
|
+
triggerOnView?: boolean;
|
|
11
|
+
onEnd?: () => void;
|
|
12
|
+
}
|
|
13
|
+
declare const Counter: React.ForwardRefExoticComponent<CounterProps & React.RefAttributes<HTMLSpanElement>>;
|
|
14
|
+
|
|
15
|
+
export { Counter, type CounterProps };
|
package/dist/counter.js
ADDED
package/dist/counter.mjs
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
type UnknownArray = readonly unknown[];
|
|
5
|
+
interface DataListProps<T extends UnknownArray> {
|
|
6
|
+
/** 렌더링할 데이터 배열. null이면 로딩 상태로 간주 */
|
|
7
|
+
list: T | null;
|
|
8
|
+
/** 빈 배열일 때 표시할 메시지 또는 요소 */
|
|
9
|
+
noDataMessage?: string | React.ReactElement;
|
|
10
|
+
/** 에러 발생 시 표시할 fallback */
|
|
11
|
+
errorFallback?: React.ReactNode;
|
|
12
|
+
/** 로딩 중 표시할 요소 (기본: Spinner) */
|
|
13
|
+
loadingElement?: React.ReactElement;
|
|
14
|
+
/** 로딩 중 표시할 스켈레톤 요소 */
|
|
15
|
+
skeletonElement?: React.ReactElement;
|
|
16
|
+
/** 스켈레톤 반복 개수 */
|
|
17
|
+
skeletonCount?: number;
|
|
18
|
+
/** 강제 로딩 상태 */
|
|
19
|
+
loading?: boolean;
|
|
20
|
+
/** 각 아이템을 렌더링하는 함수 */
|
|
21
|
+
children: (params: {
|
|
22
|
+
item: T[number];
|
|
23
|
+
index: number;
|
|
24
|
+
}) => React.ReactNode;
|
|
25
|
+
/** 루트 요소 className */
|
|
26
|
+
className?: string;
|
|
27
|
+
}
|
|
28
|
+
declare function DataList<T extends UnknownArray>({ list, loadingElement, skeletonElement, skeletonCount, noDataMessage, loading, errorFallback, children, className, }: DataListProps<T>): react_jsx_runtime.JSX.Element;
|
|
29
|
+
declare namespace DataList {
|
|
30
|
+
var displayName: string;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export { DataList, type DataListProps };
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
type UnknownArray = readonly unknown[];
|
|
5
|
+
interface DataListProps<T extends UnknownArray> {
|
|
6
|
+
/** 렌더링할 데이터 배열. null이면 로딩 상태로 간주 */
|
|
7
|
+
list: T | null;
|
|
8
|
+
/** 빈 배열일 때 표시할 메시지 또는 요소 */
|
|
9
|
+
noDataMessage?: string | React.ReactElement;
|
|
10
|
+
/** 에러 발생 시 표시할 fallback */
|
|
11
|
+
errorFallback?: React.ReactNode;
|
|
12
|
+
/** 로딩 중 표시할 요소 (기본: Spinner) */
|
|
13
|
+
loadingElement?: React.ReactElement;
|
|
14
|
+
/** 로딩 중 표시할 스켈레톤 요소 */
|
|
15
|
+
skeletonElement?: React.ReactElement;
|
|
16
|
+
/** 스켈레톤 반복 개수 */
|
|
17
|
+
skeletonCount?: number;
|
|
18
|
+
/** 강제 로딩 상태 */
|
|
19
|
+
loading?: boolean;
|
|
20
|
+
/** 각 아이템을 렌더링하는 함수 */
|
|
21
|
+
children: (params: {
|
|
22
|
+
item: T[number];
|
|
23
|
+
index: number;
|
|
24
|
+
}) => React.ReactNode;
|
|
25
|
+
/** 루트 요소 className */
|
|
26
|
+
className?: string;
|
|
27
|
+
}
|
|
28
|
+
declare function DataList<T extends UnknownArray>({ list, loadingElement, skeletonElement, skeletonCount, noDataMessage, loading, errorFallback, children, className, }: DataListProps<T>): react_jsx_runtime.JSX.Element;
|
|
29
|
+
declare namespace DataList {
|
|
30
|
+
var displayName: string;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export { DataList, type DataListProps };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkMTX7GD3H_js = require('./chunks/chunk-MTX7GD3H.js');
|
|
4
|
+
require('./chunks/chunk-EVOOTSY5.js');
|
|
5
|
+
require('./chunks/chunk-IOSIQLZL.js');
|
|
6
|
+
require('./chunks/chunk-CZC76ZD5.js');
|
|
7
|
+
require('./chunks/chunk-JNMCYWGY.js');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
Object.defineProperty(exports, "DataList", {
|
|
12
|
+
enumerable: true,
|
|
13
|
+
get: function () { return chunkMTX7GD3H_js.DataList; }
|
|
14
|
+
});
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
|
|
5
|
+
declare const dividerVariants: (props?: ({
|
|
6
|
+
orientation?: "horizontal" | "vertical" | null | undefined;
|
|
7
|
+
variant?: "dashed" | "dotted" | "solid" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
interface DividerProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof dividerVariants> {
|
|
10
|
+
color?: string;
|
|
11
|
+
}
|
|
12
|
+
declare const Divider: React.ForwardRefExoticComponent<DividerProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
|
|
14
|
+
export { Divider, type DividerProps, dividerVariants };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { VariantProps } from 'class-variance-authority';
|
|
4
|
+
|
|
5
|
+
declare const dividerVariants: (props?: ({
|
|
6
|
+
orientation?: "horizontal" | "vertical" | null | undefined;
|
|
7
|
+
variant?: "dashed" | "dotted" | "solid" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
interface DividerProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof dividerVariants> {
|
|
10
|
+
color?: string;
|
|
11
|
+
}
|
|
12
|
+
declare const Divider: React.ForwardRefExoticComponent<DividerProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
|
|
14
|
+
export { Divider, type DividerProps, dividerVariants };
|
package/dist/divider.js
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunk3PCNRCTB_js = require('./chunks/chunk-3PCNRCTB.js');
|
|
4
|
+
require('./chunks/chunk-CZC76ZD5.js');
|
|
5
|
+
require('./chunks/chunk-JNMCYWGY.js');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(exports, "Divider", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function () { return chunk3PCNRCTB_js.Divider; }
|
|
12
|
+
});
|
|
13
|
+
Object.defineProperty(exports, "dividerVariants", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () { return chunk3PCNRCTB_js.dividerVariants; }
|
|
16
|
+
});
|
package/dist/divider.mjs
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { Drawer as Drawer$1 } from 'vaul';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
|
|
6
|
+
declare const drawerOverlayVariants: (props?: ({
|
|
7
|
+
blur?: "none" | "md" | "sm" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
declare const drawerContentVariants: (props?: ({
|
|
10
|
+
direction?: "left" | "right" | "top" | "bottom" | null | undefined;
|
|
11
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
12
|
+
type DrawerDirection = 'bottom' | 'top' | 'left' | 'right';
|
|
13
|
+
type DrawerRootProps = React.ComponentPropsWithoutRef<typeof Drawer$1.Root> & {
|
|
14
|
+
direction?: DrawerDirection;
|
|
15
|
+
};
|
|
16
|
+
declare const DrawerRoot: ({ direction, ...props }: DrawerRootProps) => React.ReactElement;
|
|
17
|
+
declare const DrawerTrigger: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Trigger>>;
|
|
18
|
+
interface DrawerContentProps extends VariantProps<typeof drawerOverlayVariants> {
|
|
19
|
+
children?: React.ReactNode;
|
|
20
|
+
direction?: DrawerDirection;
|
|
21
|
+
showHandle?: boolean;
|
|
22
|
+
overlayClassName?: string;
|
|
23
|
+
className?: string;
|
|
24
|
+
}
|
|
25
|
+
declare const DrawerContent: React.ForwardRefExoticComponent<DrawerContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
declare const DrawerClose: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Close>>;
|
|
27
|
+
declare const DrawerTitle: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Title> & {
|
|
28
|
+
className?: string;
|
|
29
|
+
}>;
|
|
30
|
+
declare const DrawerDescription: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Description> & {
|
|
31
|
+
className?: string;
|
|
32
|
+
}>;
|
|
33
|
+
type DrawerComponent = typeof DrawerRoot & {
|
|
34
|
+
Trigger: typeof DrawerTrigger;
|
|
35
|
+
Content: typeof DrawerContent;
|
|
36
|
+
Close: typeof DrawerClose;
|
|
37
|
+
Title: typeof DrawerTitle;
|
|
38
|
+
Description: typeof DrawerDescription;
|
|
39
|
+
};
|
|
40
|
+
declare const Drawer: DrawerComponent;
|
|
41
|
+
|
|
42
|
+
export { Drawer, DrawerClose, DrawerContent, type DrawerContentProps, DrawerDescription, type DrawerDirection, DrawerRoot, type DrawerRootProps, DrawerTitle, DrawerTrigger, drawerContentVariants, drawerOverlayVariants };
|
package/dist/drawer.d.ts
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { Drawer as Drawer$1 } from 'vaul';
|
|
4
|
+
import { VariantProps } from 'class-variance-authority';
|
|
5
|
+
|
|
6
|
+
declare const drawerOverlayVariants: (props?: ({
|
|
7
|
+
blur?: "none" | "md" | "sm" | null | undefined;
|
|
8
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
9
|
+
declare const drawerContentVariants: (props?: ({
|
|
10
|
+
direction?: "left" | "right" | "top" | "bottom" | null | undefined;
|
|
11
|
+
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
12
|
+
type DrawerDirection = 'bottom' | 'top' | 'left' | 'right';
|
|
13
|
+
type DrawerRootProps = React.ComponentPropsWithoutRef<typeof Drawer$1.Root> & {
|
|
14
|
+
direction?: DrawerDirection;
|
|
15
|
+
};
|
|
16
|
+
declare const DrawerRoot: ({ direction, ...props }: DrawerRootProps) => React.ReactElement;
|
|
17
|
+
declare const DrawerTrigger: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Trigger>>;
|
|
18
|
+
interface DrawerContentProps extends VariantProps<typeof drawerOverlayVariants> {
|
|
19
|
+
children?: React.ReactNode;
|
|
20
|
+
direction?: DrawerDirection;
|
|
21
|
+
showHandle?: boolean;
|
|
22
|
+
overlayClassName?: string;
|
|
23
|
+
className?: string;
|
|
24
|
+
}
|
|
25
|
+
declare const DrawerContent: React.ForwardRefExoticComponent<DrawerContentProps & React.RefAttributes<HTMLDivElement>>;
|
|
26
|
+
declare const DrawerClose: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Close>>;
|
|
27
|
+
declare const DrawerTitle: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Title> & {
|
|
28
|
+
className?: string;
|
|
29
|
+
}>;
|
|
30
|
+
declare const DrawerDescription: React.FC<React.ComponentPropsWithoutRef<typeof Drawer$1.Description> & {
|
|
31
|
+
className?: string;
|
|
32
|
+
}>;
|
|
33
|
+
type DrawerComponent = typeof DrawerRoot & {
|
|
34
|
+
Trigger: typeof DrawerTrigger;
|
|
35
|
+
Content: typeof DrawerContent;
|
|
36
|
+
Close: typeof DrawerClose;
|
|
37
|
+
Title: typeof DrawerTitle;
|
|
38
|
+
Description: typeof DrawerDescription;
|
|
39
|
+
};
|
|
40
|
+
declare const Drawer: DrawerComponent;
|
|
41
|
+
|
|
42
|
+
export { Drawer, DrawerClose, DrawerContent, type DrawerContentProps, DrawerDescription, type DrawerDirection, DrawerRoot, type DrawerRootProps, DrawerTitle, DrawerTrigger, drawerContentVariants, drawerOverlayVariants };
|
package/dist/drawer.js
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkBSZ2LN6E_js = require('./chunks/chunk-BSZ2LN6E.js');
|
|
4
|
+
require('./chunks/chunk-CZC76ZD5.js');
|
|
5
|
+
require('./chunks/chunk-JNMCYWGY.js');
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(exports, "Drawer", {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function () { return chunkBSZ2LN6E_js.Drawer; }
|
|
12
|
+
});
|
|
13
|
+
Object.defineProperty(exports, "DrawerClose", {
|
|
14
|
+
enumerable: true,
|
|
15
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerClose; }
|
|
16
|
+
});
|
|
17
|
+
Object.defineProperty(exports, "DrawerContent", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerContent; }
|
|
20
|
+
});
|
|
21
|
+
Object.defineProperty(exports, "DrawerDescription", {
|
|
22
|
+
enumerable: true,
|
|
23
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerDescription; }
|
|
24
|
+
});
|
|
25
|
+
Object.defineProperty(exports, "DrawerRoot", {
|
|
26
|
+
enumerable: true,
|
|
27
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerRoot; }
|
|
28
|
+
});
|
|
29
|
+
Object.defineProperty(exports, "DrawerTitle", {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerTitle; }
|
|
32
|
+
});
|
|
33
|
+
Object.defineProperty(exports, "DrawerTrigger", {
|
|
34
|
+
enumerable: true,
|
|
35
|
+
get: function () { return chunkBSZ2LN6E_js.DrawerTrigger; }
|
|
36
|
+
});
|
|
37
|
+
Object.defineProperty(exports, "drawerContentVariants", {
|
|
38
|
+
enumerable: true,
|
|
39
|
+
get: function () { return chunkBSZ2LN6E_js.drawerContentVariants; }
|
|
40
|
+
});
|
|
41
|
+
Object.defineProperty(exports, "drawerOverlayVariants", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
get: function () { return chunkBSZ2LN6E_js.drawerOverlayVariants; }
|
|
44
|
+
});
|