@uipath/apollo-wind 2.36.1 → 2.37.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/dist/components/custom/flow-properties-simple.cjs +1 -0
- package/dist/components/custom/flow-properties-simple.js +1 -0
- package/dist/components/custom/panel-delegate.cjs +1 -1
- package/dist/components/custom/panel-delegate.js +1 -1
- package/dist/components/custom/panel-flow.cjs +2 -1
- package/dist/components/custom/panel-flow.js +2 -1
- package/dist/components/forms/field-renderer.cjs +1 -0
- package/dist/components/forms/field-renderer.js +1 -0
- package/dist/components/forms/form-designer.cjs +25 -9
- package/dist/components/forms/form-designer.js +25 -9
- package/dist/components/forms/form-examples.cjs +1 -1
- package/dist/components/forms/form-examples.js +1 -1
- package/dist/components/forms/form-state-viewer.cjs +4 -7
- package/dist/components/forms/form-state-viewer.js +4 -7
- package/dist/components/ui/accordion.cjs +9 -1
- package/dist/components/ui/accordion.d.ts +1 -1
- package/dist/components/ui/accordion.js +9 -1
- package/dist/components/ui/alert-dialog.cjs +25 -4
- package/dist/components/ui/alert-dialog.d.ts +9 -3
- package/dist/components/ui/alert-dialog.js +25 -4
- package/dist/components/ui/alert.cjs +3 -0
- package/dist/components/ui/alert.js +3 -0
- package/dist/components/ui/aspect-ratio.cjs +8 -1
- package/dist/components/ui/aspect-ratio.d.ts +2 -1
- package/dist/components/ui/aspect-ratio.js +8 -1
- package/dist/components/ui/avatar.cjs +25 -4
- package/dist/components/ui/avatar.d.ts +8 -2
- package/dist/components/ui/avatar.js +21 -3
- package/dist/components/ui/badge.cjs +1 -0
- package/dist/components/ui/badge.js +1 -0
- package/dist/components/ui/breadcrumb.cjs +7 -0
- package/dist/components/ui/breadcrumb.js +7 -0
- package/dist/components/ui/button-group.cjs +3 -0
- package/dist/components/ui/button-group.js +3 -0
- package/dist/components/ui/button.cjs +1 -0
- package/dist/components/ui/button.js +1 -0
- package/dist/components/ui/card.cjs +6 -0
- package/dist/components/ui/card.js +6 -0
- package/dist/components/ui/checkbox.cjs +1 -0
- package/dist/components/ui/checkbox.js +1 -0
- package/dist/components/ui/collapsible.cjs +20 -3
- package/dist/components/ui/collapsible.d.ts +4 -3
- package/dist/components/ui/collapsible.js +20 -3
- package/dist/components/ui/combobox.cjs +5 -3
- package/dist/components/ui/combobox.d.ts +2 -1
- package/dist/components/ui/combobox.js +6 -4
- package/dist/components/ui/command.cjs +9 -0
- package/dist/components/ui/command.js +9 -0
- package/dist/components/ui/context-menu.cjs +42 -6
- package/dist/components/ui/context-menu.d.ts +15 -6
- package/dist/components/ui/context-menu.js +42 -6
- package/dist/components/ui/data-table.cjs +2 -0
- package/dist/components/ui/data-table.js +2 -0
- package/dist/components/ui/date-picker.cjs +11 -6
- package/dist/components/ui/date-picker.d.ts +3 -3
- package/dist/components/ui/date-picker.js +10 -5
- package/dist/components/ui/datetime-picker.cjs +5 -3
- package/dist/components/ui/datetime-picker.d.ts +2 -1
- package/dist/components/ui/datetime-picker.js +6 -4
- package/dist/components/ui/dialog.cjs +1 -1
- package/dist/components/ui/dialog.js +1 -1
- package/dist/components/ui/drawer.cjs +29 -5
- package/dist/components/ui/drawer.d.ts +11 -4
- package/dist/components/ui/drawer.js +29 -5
- package/dist/components/ui/dropdown-menu.cjs +42 -6
- package/dist/components/ui/dropdown-menu.d.ts +15 -6
- package/dist/components/ui/dropdown-menu.js +42 -6
- package/dist/components/ui/editable-cell.cjs +2 -0
- package/dist/components/ui/editable-cell.js +2 -0
- package/dist/components/ui/empty-state.cjs +1 -0
- package/dist/components/ui/empty-state.js +1 -0
- package/dist/components/ui/file-upload.cjs +12 -4
- package/dist/components/ui/file-upload.d.ts +4 -1
- package/dist/components/ui/file-upload.js +13 -5
- package/dist/components/ui/hover-card.cjs +12 -2
- package/dist/components/ui/hover-card.d.ts +5 -2
- package/dist/components/ui/hover-card.js +12 -2
- package/dist/components/ui/index.cjs +193 -143
- package/dist/components/ui/index.d.ts +5 -0
- package/dist/components/ui/index.js +5 -0
- package/dist/components/ui/input-group.cjs +59 -15
- package/dist/components/ui/input-group.d.ts +5 -1
- package/dist/components/ui/input-group.js +61 -17
- package/dist/components/ui/input.cjs +31 -6
- package/dist/components/ui/input.d.ts +7 -0
- package/dist/components/ui/input.js +33 -8
- package/dist/components/ui/label.cjs +1 -0
- package/dist/components/ui/label.js +1 -0
- package/dist/components/ui/layout/column.cjs +1 -0
- package/dist/components/ui/layout/column.js +1 -0
- package/dist/components/ui/layout/grid.cjs +1 -0
- package/dist/components/ui/layout/grid.js +1 -0
- package/dist/components/ui/layout/row.cjs +1 -0
- package/dist/components/ui/layout/row.js +1 -0
- package/dist/components/ui/lockable-value-field/lockable-value-field.cjs +38 -5
- package/dist/components/ui/lockable-value-field/lockable-value-field.d.ts +1 -1
- package/dist/components/ui/lockable-value-field/lockable-value-field.js +38 -5
- package/dist/components/ui/lockable-value-field/types.d.ts +9 -1
- package/dist/components/ui/multi-select.cjs +5 -1
- package/dist/components/ui/multi-select.d.ts +3 -0
- package/dist/components/ui/multi-select.js +5 -1
- package/dist/components/ui/pagination.cjs +7 -0
- package/dist/components/ui/pagination.js +7 -0
- package/dist/components/ui/popover.cjs +18 -3
- package/dist/components/ui/popover.d.ts +6 -3
- package/dist/components/ui/popover.js +18 -3
- package/dist/components/ui/progress.cjs +1 -0
- package/dist/components/ui/progress.js +1 -0
- package/dist/components/ui/prompt-editor/components/EditorToolbar.cjs +5 -2
- package/dist/components/ui/prompt-editor/components/EditorToolbar.js +5 -2
- package/dist/components/ui/radio-group.cjs +2 -0
- package/dist/components/ui/radio-group.js +2 -0
- package/dist/components/ui/resizable.cjs +2 -0
- package/dist/components/ui/resizable.js +2 -0
- package/dist/components/ui/scroll-area.cjs +2 -0
- package/dist/components/ui/scroll-area.js +2 -0
- package/dist/components/ui/search.cjs +2 -0
- package/dist/components/ui/search.js +2 -0
- package/dist/components/ui/select.cjs +24 -3
- package/dist/components/ui/select.d.ts +6 -3
- package/dist/components/ui/select.js +24 -3
- package/dist/components/ui/separator.cjs +1 -0
- package/dist/components/ui/separator.js +1 -0
- package/dist/components/ui/sheet.cjs +29 -5
- package/dist/components/ui/sheet.d.ts +10 -4
- package/dist/components/ui/sheet.js +29 -5
- package/dist/components/ui/skeleton.cjs +1 -0
- package/dist/components/ui/skeleton.js +1 -0
- package/dist/components/ui/slider.cjs +1 -0
- package/dist/components/ui/slider.js +1 -0
- package/dist/components/ui/sonner.cjs +1 -0
- package/dist/components/ui/sonner.js +1 -0
- package/dist/components/ui/spinner.cjs +1 -0
- package/dist/components/ui/spinner.js +1 -0
- package/dist/components/ui/stats-card.cjs +26 -12
- package/dist/components/ui/stats-card.d.ts +6 -3
- package/dist/components/ui/stats-card.js +22 -11
- package/dist/components/ui/stepper.cjs +1 -0
- package/dist/components/ui/stepper.js +1 -0
- package/dist/components/ui/switch.cjs +1 -0
- package/dist/components/ui/switch.js +1 -0
- package/dist/components/ui/table.cjs +9 -0
- package/dist/components/ui/table.js +9 -0
- package/dist/components/ui/tabs.cjs +10 -1
- package/dist/components/ui/tabs.d.ts +1 -1
- package/dist/components/ui/tabs.js +10 -1
- package/dist/components/ui/textarea.cjs +1 -0
- package/dist/components/ui/textarea.js +1 -0
- package/dist/components/ui/toggle-group.cjs +2 -0
- package/dist/components/ui/toggle-group.js +2 -0
- package/dist/components/ui/toggle.cjs +1 -0
- package/dist/components/ui/toggle.js +1 -0
- package/dist/components/ui/tooltip.cjs +22 -4
- package/dist/components/ui/tooltip.d.ts +13 -4
- package/dist/components/ui/tooltip.js +22 -4
- package/dist/components/ui/tree-view.cjs +17 -9
- package/dist/components/ui/tree-view.d.ts +2 -1
- package/dist/components/ui/tree-view.js +18 -10
- package/dist/foundation/Future/index.cjs +107 -0
- package/dist/foundation/Future/index.d.ts +8 -0
- package/dist/foundation/Future/index.js +8 -0
- package/dist/foundation/index.cjs +58 -0
- package/dist/foundation/index.d.ts +1 -0
- package/dist/foundation/index.js +1 -0
- package/dist/index.cjs +52 -2
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -1
- package/dist/styles.css +208 -128
- package/package.json +2 -5
- package/dist/components/UiPath/index.cjs +0 -5
- package/dist/components/UiPath/index.d.ts +0 -1
- package/dist/components/UiPath/index.js +0 -0
|
@@ -4,14 +4,42 @@ import { CheckboxItem, Content, Group, Item, ItemIndicator, Label, Portal, Radio
|
|
|
4
4
|
import { Check, ChevronRight, Circle } from "lucide-react";
|
|
5
5
|
import { forwardRef } from "react";
|
|
6
6
|
import { cn } from "../../lib/index.js";
|
|
7
|
-
const ContextMenu = Root
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
const
|
|
7
|
+
const ContextMenu = (props)=>/*#__PURE__*/ jsx(Root, {
|
|
8
|
+
"data-slot": "context-menu",
|
|
9
|
+
...props
|
|
10
|
+
});
|
|
11
|
+
ContextMenu.displayName = 'ContextMenu';
|
|
12
|
+
const ContextMenuTrigger = /*#__PURE__*/ forwardRef((props, ref)=>/*#__PURE__*/ jsx(Trigger, {
|
|
13
|
+
ref: ref,
|
|
14
|
+
"data-slot": "context-menu-trigger",
|
|
15
|
+
...props
|
|
16
|
+
}));
|
|
17
|
+
ContextMenuTrigger.displayName = Trigger.displayName;
|
|
18
|
+
const ContextMenuGroup = /*#__PURE__*/ forwardRef((props, ref)=>/*#__PURE__*/ jsx(Group, {
|
|
19
|
+
ref: ref,
|
|
20
|
+
"data-slot": "context-menu-group",
|
|
21
|
+
...props
|
|
22
|
+
}));
|
|
23
|
+
ContextMenuGroup.displayName = Group.displayName;
|
|
24
|
+
const ContextMenuPortal = (props)=>/*#__PURE__*/ jsx(Portal, {
|
|
25
|
+
"data-slot": "context-menu-portal",
|
|
26
|
+
...props
|
|
27
|
+
});
|
|
28
|
+
ContextMenuPortal.displayName = 'ContextMenuPortal';
|
|
29
|
+
const ContextMenuSub = (props)=>/*#__PURE__*/ jsx(Sub, {
|
|
30
|
+
"data-slot": "context-menu-sub",
|
|
31
|
+
...props
|
|
32
|
+
});
|
|
33
|
+
ContextMenuSub.displayName = 'ContextMenuSub';
|
|
34
|
+
const ContextMenuRadioGroup = /*#__PURE__*/ forwardRef((props, ref)=>/*#__PURE__*/ jsx(RadioGroup, {
|
|
35
|
+
ref: ref,
|
|
36
|
+
"data-slot": "context-menu-radio-group",
|
|
37
|
+
...props
|
|
38
|
+
}));
|
|
39
|
+
ContextMenuRadioGroup.displayName = RadioGroup.displayName;
|
|
13
40
|
const ContextMenuSubTrigger = /*#__PURE__*/ forwardRef(({ className, inset, children, ...props }, ref)=>/*#__PURE__*/ jsxs(SubTrigger, {
|
|
14
41
|
ref: ref,
|
|
42
|
+
"data-slot": "context-menu-sub-trigger",
|
|
15
43
|
className: cn('flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground', inset && 'pl-8', className),
|
|
16
44
|
...props,
|
|
17
45
|
children: [
|
|
@@ -24,6 +52,7 @@ const ContextMenuSubTrigger = /*#__PURE__*/ forwardRef(({ className, inset, chil
|
|
|
24
52
|
ContextMenuSubTrigger.displayName = SubTrigger.displayName;
|
|
25
53
|
const ContextMenuSubContent = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(SubContent, {
|
|
26
54
|
ref: ref,
|
|
55
|
+
"data-slot": "context-menu-sub-content",
|
|
27
56
|
className: cn('z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md future:rounded-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]', className),
|
|
28
57
|
...props
|
|
29
58
|
}));
|
|
@@ -31,6 +60,7 @@ ContextMenuSubContent.displayName = SubContent.displayName;
|
|
|
31
60
|
const ContextMenuContent = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(Portal, {
|
|
32
61
|
children: /*#__PURE__*/ jsx(Content, {
|
|
33
62
|
ref: ref,
|
|
63
|
+
"data-slot": "context-menu-content",
|
|
34
64
|
className: cn('z-50 max-h-[--radix-context-menu-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md future:rounded-lg animate-in fade-in-80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]', className),
|
|
35
65
|
...props
|
|
36
66
|
})
|
|
@@ -38,12 +68,14 @@ const ContextMenuContent = /*#__PURE__*/ forwardRef(({ className, ...props }, re
|
|
|
38
68
|
ContextMenuContent.displayName = Content.displayName;
|
|
39
69
|
const ContextMenuItem = /*#__PURE__*/ forwardRef(({ className, inset, ...props }, ref)=>/*#__PURE__*/ jsx(Item, {
|
|
40
70
|
ref: ref,
|
|
71
|
+
"data-slot": "context-menu-item",
|
|
41
72
|
className: cn('relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50', inset && 'pl-8', className),
|
|
42
73
|
...props
|
|
43
74
|
}));
|
|
44
75
|
ContextMenuItem.displayName = Item.displayName;
|
|
45
76
|
const ContextMenuCheckboxItem = /*#__PURE__*/ forwardRef(({ className, children, checked, ...props }, ref)=>/*#__PURE__*/ jsxs(CheckboxItem, {
|
|
46
77
|
ref: ref,
|
|
78
|
+
"data-slot": "context-menu-checkbox-item",
|
|
47
79
|
className: cn('relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50', className),
|
|
48
80
|
checked: checked,
|
|
49
81
|
...props,
|
|
@@ -62,6 +94,7 @@ const ContextMenuCheckboxItem = /*#__PURE__*/ forwardRef(({ className, children,
|
|
|
62
94
|
ContextMenuCheckboxItem.displayName = CheckboxItem.displayName;
|
|
63
95
|
const ContextMenuRadioItem = /*#__PURE__*/ forwardRef(({ className, children, ...props }, ref)=>/*#__PURE__*/ jsxs(RadioItem, {
|
|
64
96
|
ref: ref,
|
|
97
|
+
"data-slot": "context-menu-radio-item",
|
|
65
98
|
className: cn('relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50', className),
|
|
66
99
|
...props,
|
|
67
100
|
children: [
|
|
@@ -79,17 +112,20 @@ const ContextMenuRadioItem = /*#__PURE__*/ forwardRef(({ className, children, ..
|
|
|
79
112
|
ContextMenuRadioItem.displayName = RadioItem.displayName;
|
|
80
113
|
const ContextMenuLabel = /*#__PURE__*/ forwardRef(({ className, inset, ...props }, ref)=>/*#__PURE__*/ jsx(Label, {
|
|
81
114
|
ref: ref,
|
|
115
|
+
"data-slot": "context-menu-label",
|
|
82
116
|
className: cn('px-2 py-1.5 text-sm font-semibold text-foreground', inset && 'pl-8', className),
|
|
83
117
|
...props
|
|
84
118
|
}));
|
|
85
119
|
ContextMenuLabel.displayName = Label.displayName;
|
|
86
120
|
const ContextMenuSeparator = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(Separator, {
|
|
87
121
|
ref: ref,
|
|
122
|
+
"data-slot": "context-menu-separator",
|
|
88
123
|
className: cn('-mx-1 my-1 h-px bg-border', className),
|
|
89
124
|
...props
|
|
90
125
|
}));
|
|
91
126
|
ContextMenuSeparator.displayName = Separator.displayName;
|
|
92
127
|
const ContextMenuShortcut = ({ className, ...props })=>/*#__PURE__*/ jsx("span", {
|
|
128
|
+
"data-slot": "context-menu-shortcut",
|
|
93
129
|
className: cn('ml-auto text-xs tracking-widest text-muted-foreground', className),
|
|
94
130
|
...props
|
|
95
131
|
});
|
|
@@ -141,6 +141,7 @@ function DataTable({ columns, data, searchKey, searchPlaceholder = 'Search...',
|
|
|
141
141
|
}
|
|
142
142
|
});
|
|
143
143
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
144
|
+
"data-slot": "data-table",
|
|
144
145
|
className: "w-full",
|
|
145
146
|
children: [
|
|
146
147
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
@@ -320,6 +321,7 @@ function DataTableColumnHeader({ column, title, children }) {
|
|
|
320
321
|
else column.toggleSorting(false);
|
|
321
322
|
};
|
|
322
323
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_button_cjs_namespaceObject.Button, {
|
|
324
|
+
"data-slot": "data-table-column-header",
|
|
323
325
|
variant: "ghost",
|
|
324
326
|
size: "sm",
|
|
325
327
|
className: "-ml-3 h-8 max-w-full data-[state=open]:bg-accent",
|
|
@@ -111,6 +111,7 @@ function DataTable({ columns, data, searchKey, searchPlaceholder = 'Search...',
|
|
|
111
111
|
}
|
|
112
112
|
});
|
|
113
113
|
return /*#__PURE__*/ jsxs("div", {
|
|
114
|
+
"data-slot": "data-table",
|
|
114
115
|
className: "w-full",
|
|
115
116
|
children: [
|
|
116
117
|
/*#__PURE__*/ jsxs("div", {
|
|
@@ -290,6 +291,7 @@ function DataTableColumnHeader({ column, title, children }) {
|
|
|
290
291
|
else column.toggleSorting(false);
|
|
291
292
|
};
|
|
292
293
|
return /*#__PURE__*/ jsxs(Button, {
|
|
294
|
+
"data-slot": "data-table-column-header",
|
|
293
295
|
variant: "ghost",
|
|
294
296
|
size: "sm",
|
|
295
297
|
className: "-ml-3 h-8 max-w-full data-[state=open]:bg-accent",
|
|
@@ -25,22 +25,25 @@ var __webpack_require__ = {};
|
|
|
25
25
|
var __webpack_exports__ = {};
|
|
26
26
|
__webpack_require__.r(__webpack_exports__);
|
|
27
27
|
__webpack_require__.d(__webpack_exports__, {
|
|
28
|
-
DatePicker: ()=>
|
|
29
|
-
DateRangePicker: ()=>
|
|
28
|
+
DatePicker: ()=>date_picker_DatePicker,
|
|
29
|
+
DateRangePicker: ()=>date_picker_DateRangePicker
|
|
30
30
|
});
|
|
31
31
|
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
32
32
|
const external_date_fns_namespaceObject = require("date-fns");
|
|
33
33
|
const external_lucide_react_namespaceObject = require("lucide-react");
|
|
34
|
+
const external_react_namespaceObject = require("react");
|
|
34
35
|
const external_button_cjs_namespaceObject = require("./button.cjs");
|
|
35
36
|
const external_calendar_cjs_namespaceObject = require("./calendar.cjs");
|
|
36
37
|
const external_popover_cjs_namespaceObject = require("./popover.cjs");
|
|
37
38
|
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
38
|
-
|
|
39
|
+
const date_picker_DatePicker = /*#__PURE__*/ external_react_namespaceObject.forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date', className, calendarProps }, ref) {
|
|
39
40
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_popover_cjs_namespaceObject.Popover, {
|
|
41
|
+
"data-slot": "date-picker",
|
|
40
42
|
children: [
|
|
41
43
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_popover_cjs_namespaceObject.PopoverTrigger, {
|
|
42
44
|
asChild: true,
|
|
43
45
|
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_button_cjs_namespaceObject.Button, {
|
|
46
|
+
ref: ref,
|
|
44
47
|
variant: "outline",
|
|
45
48
|
"aria-label": value ? `Selected date: ${(0, external_date_fns_namespaceObject.format)(value, 'PPP')}` : placeholder,
|
|
46
49
|
className: (0, index_cjs_namespaceObject.cn)('w-full justify-start text-left font-normal', !value && 'text-muted-foreground', className),
|
|
@@ -65,13 +68,15 @@ function DatePicker({ value, onValueChange, disabled, placeholder = 'Pick a date
|
|
|
65
68
|
})
|
|
66
69
|
]
|
|
67
70
|
});
|
|
68
|
-
}
|
|
69
|
-
|
|
71
|
+
});
|
|
72
|
+
const date_picker_DateRangePicker = /*#__PURE__*/ external_react_namespaceObject.forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date range', className, calendarProps }, ref) {
|
|
70
73
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_popover_cjs_namespaceObject.Popover, {
|
|
74
|
+
"data-slot": "date-range-picker",
|
|
71
75
|
children: [
|
|
72
76
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_popover_cjs_namespaceObject.PopoverTrigger, {
|
|
73
77
|
asChild: true,
|
|
74
78
|
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_button_cjs_namespaceObject.Button, {
|
|
79
|
+
ref: ref,
|
|
75
80
|
variant: "outline",
|
|
76
81
|
"aria-label": value?.from ? value.to ? `Selected range: ${(0, external_date_fns_namespaceObject.format)(value.from, 'LLL dd, y')} to ${(0, external_date_fns_namespaceObject.format)(value.to, 'LLL dd, y')}` : `Selected date: ${(0, external_date_fns_namespaceObject.format)(value.from, 'LLL dd, y')}` : placeholder,
|
|
77
82
|
className: (0, index_cjs_namespaceObject.cn)('w-[300px] justify-start text-left font-normal', !value && 'text-muted-foreground', className),
|
|
@@ -106,7 +111,7 @@ function DateRangePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
106
111
|
})
|
|
107
112
|
]
|
|
108
113
|
});
|
|
109
|
-
}
|
|
114
|
+
});
|
|
110
115
|
exports.DatePicker = __webpack_exports__.DatePicker;
|
|
111
116
|
exports.DateRangePicker = __webpack_exports__.DateRangePicker;
|
|
112
117
|
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DateRange } from 'react-day-picker';
|
|
2
|
-
import
|
|
2
|
+
import * as React from 'react';
|
|
3
3
|
import { Calendar } from './calendar';
|
|
4
4
|
export interface DatePickerProps {
|
|
5
5
|
value?: Date;
|
|
@@ -9,7 +9,7 @@ export interface DatePickerProps {
|
|
|
9
9
|
className?: string;
|
|
10
10
|
calendarProps?: Omit<React.ComponentProps<typeof Calendar>, 'mode' | 'selected' | 'onSelect' | 'initialFocus'>;
|
|
11
11
|
}
|
|
12
|
-
export declare
|
|
12
|
+
export declare const DatePicker: React.ForwardRefExoticComponent<DatePickerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
13
13
|
export interface DateRangePickerProps {
|
|
14
14
|
value?: DateRange;
|
|
15
15
|
onValueChange?: (range: DateRange | undefined) => void;
|
|
@@ -18,4 +18,4 @@ export interface DateRangePickerProps {
|
|
|
18
18
|
className?: string;
|
|
19
19
|
calendarProps?: Omit<React.ComponentProps<typeof Calendar>, 'mode' | 'selected' | 'onSelect' | 'initialFocus' | 'defaultMonth' | 'numberOfMonths' | 'required'>;
|
|
20
20
|
}
|
|
21
|
-
export declare
|
|
21
|
+
export declare const DateRangePicker: React.ForwardRefExoticComponent<DateRangePickerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -2,16 +2,19 @@
|
|
|
2
2
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { format } from "date-fns";
|
|
4
4
|
import { CalendarIcon } from "lucide-react";
|
|
5
|
+
import { forwardRef } from "react";
|
|
5
6
|
import { Button } from "./button.js";
|
|
6
7
|
import { Calendar } from "./calendar.js";
|
|
7
8
|
import { Popover, PopoverContent, PopoverTrigger } from "./popover.js";
|
|
8
9
|
import { cn } from "../../lib/index.js";
|
|
9
|
-
|
|
10
|
+
const date_picker_DatePicker = /*#__PURE__*/ forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date', className, calendarProps }, ref) {
|
|
10
11
|
return /*#__PURE__*/ jsxs(Popover, {
|
|
12
|
+
"data-slot": "date-picker",
|
|
11
13
|
children: [
|
|
12
14
|
/*#__PURE__*/ jsx(PopoverTrigger, {
|
|
13
15
|
asChild: true,
|
|
14
16
|
children: /*#__PURE__*/ jsxs(Button, {
|
|
17
|
+
ref: ref,
|
|
15
18
|
variant: "outline",
|
|
16
19
|
"aria-label": value ? `Selected date: ${format(value, 'PPP')}` : placeholder,
|
|
17
20
|
className: cn('w-full justify-start text-left font-normal', !value && 'text-muted-foreground', className),
|
|
@@ -36,13 +39,15 @@ function DatePicker({ value, onValueChange, disabled, placeholder = 'Pick a date
|
|
|
36
39
|
})
|
|
37
40
|
]
|
|
38
41
|
});
|
|
39
|
-
}
|
|
40
|
-
|
|
42
|
+
});
|
|
43
|
+
const date_picker_DateRangePicker = /*#__PURE__*/ forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date range', className, calendarProps }, ref) {
|
|
41
44
|
return /*#__PURE__*/ jsxs(Popover, {
|
|
45
|
+
"data-slot": "date-range-picker",
|
|
42
46
|
children: [
|
|
43
47
|
/*#__PURE__*/ jsx(PopoverTrigger, {
|
|
44
48
|
asChild: true,
|
|
45
49
|
children: /*#__PURE__*/ jsxs(Button, {
|
|
50
|
+
ref: ref,
|
|
46
51
|
variant: "outline",
|
|
47
52
|
"aria-label": value?.from ? value.to ? `Selected range: ${format(value.from, 'LLL dd, y')} to ${format(value.to, 'LLL dd, y')}` : `Selected date: ${format(value.from, 'LLL dd, y')}` : placeholder,
|
|
48
53
|
className: cn('w-[300px] justify-start text-left font-normal', !value && 'text-muted-foreground', className),
|
|
@@ -77,5 +82,5 @@ function DateRangePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
77
82
|
})
|
|
78
83
|
]
|
|
79
84
|
});
|
|
80
|
-
}
|
|
81
|
-
export { DatePicker, DateRangePicker };
|
|
85
|
+
});
|
|
86
|
+
export { date_picker_DatePicker as DatePicker, date_picker_DateRangePicker as DateRangePicker };
|
|
@@ -24,7 +24,7 @@ var __webpack_require__ = {};
|
|
|
24
24
|
var __webpack_exports__ = {};
|
|
25
25
|
__webpack_require__.r(__webpack_exports__);
|
|
26
26
|
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
-
DateTimePicker: ()=>
|
|
27
|
+
DateTimePicker: ()=>datetime_picker_DateTimePicker
|
|
28
28
|
});
|
|
29
29
|
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
30
30
|
const external_react_namespaceObject = require("react");
|
|
@@ -36,7 +36,7 @@ const external_popover_cjs_namespaceObject = require("./popover.cjs");
|
|
|
36
36
|
const external_input_cjs_namespaceObject = require("./input.cjs");
|
|
37
37
|
const external_label_cjs_namespaceObject = require("./label.cjs");
|
|
38
38
|
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
39
|
-
|
|
39
|
+
const datetime_picker_DateTimePicker = /*#__PURE__*/ external_react_namespaceObject.forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date and time', className, use12Hour = false }, ref) {
|
|
40
40
|
const [open, setOpen] = external_react_namespaceObject.useState(false);
|
|
41
41
|
const [selectedDate, setSelectedDate] = external_react_namespaceObject.useState(value);
|
|
42
42
|
const [timeValue, setTimeValue] = external_react_namespaceObject.useState(value ? (0, external_date_fns_namespaceObject.format)(value, use12Hour ? 'hh:mm a' : 'HH:mm') : '');
|
|
@@ -68,12 +68,14 @@ function DateTimePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
68
68
|
return `${datePart} at ${timePart}`;
|
|
69
69
|
};
|
|
70
70
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_popover_cjs_namespaceObject.Popover, {
|
|
71
|
+
"data-slot": "datetime-picker",
|
|
71
72
|
open: open,
|
|
72
73
|
onOpenChange: setOpen,
|
|
73
74
|
children: [
|
|
74
75
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_popover_cjs_namespaceObject.PopoverTrigger, {
|
|
75
76
|
asChild: true,
|
|
76
77
|
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_button_cjs_namespaceObject.Button, {
|
|
78
|
+
ref: ref,
|
|
77
79
|
variant: "outline",
|
|
78
80
|
className: (0, index_cjs_namespaceObject.cn)('w-full justify-start text-left font-normal', !selectedDate && 'text-muted-foreground', className),
|
|
79
81
|
disabled: disabled,
|
|
@@ -144,7 +146,7 @@ function DateTimePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
144
146
|
})
|
|
145
147
|
]
|
|
146
148
|
});
|
|
147
|
-
}
|
|
149
|
+
});
|
|
148
150
|
exports.DateTimePicker = __webpack_exports__.DateTimePicker;
|
|
149
151
|
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
150
152
|
"DateTimePicker"
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
1
2
|
export interface DateTimePickerProps {
|
|
2
3
|
value?: Date;
|
|
3
4
|
onValueChange?: (date: Date | undefined) => void;
|
|
@@ -6,4 +7,4 @@ export interface DateTimePickerProps {
|
|
|
6
7
|
className?: string;
|
|
7
8
|
use12Hour?: boolean;
|
|
8
9
|
}
|
|
9
|
-
export declare
|
|
10
|
+
export declare const DateTimePicker: React.ForwardRefExoticComponent<DateTimePickerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { useState } from "react";
|
|
2
|
+
import { forwardRef, useState } from "react";
|
|
3
3
|
import { format } from "date-fns";
|
|
4
4
|
import { CalendarIcon, Clock } from "lucide-react";
|
|
5
5
|
import { Button } from "./button.js";
|
|
@@ -8,7 +8,7 @@ import { Popover, PopoverContent, PopoverTrigger } from "./popover.js";
|
|
|
8
8
|
import { Input } from "./input.js";
|
|
9
9
|
import { Label } from "./label.js";
|
|
10
10
|
import { cn } from "../../lib/index.js";
|
|
11
|
-
|
|
11
|
+
const datetime_picker_DateTimePicker = /*#__PURE__*/ forwardRef(function({ value, onValueChange, disabled, placeholder = 'Pick a date and time', className, use12Hour = false }, ref) {
|
|
12
12
|
const [open, setOpen] = useState(false);
|
|
13
13
|
const [selectedDate, setSelectedDate] = useState(value);
|
|
14
14
|
const [timeValue, setTimeValue] = useState(value ? format(value, use12Hour ? 'hh:mm a' : 'HH:mm') : '');
|
|
@@ -40,12 +40,14 @@ function DateTimePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
40
40
|
return `${datePart} at ${timePart}`;
|
|
41
41
|
};
|
|
42
42
|
return /*#__PURE__*/ jsxs(Popover, {
|
|
43
|
+
"data-slot": "datetime-picker",
|
|
43
44
|
open: open,
|
|
44
45
|
onOpenChange: setOpen,
|
|
45
46
|
children: [
|
|
46
47
|
/*#__PURE__*/ jsx(PopoverTrigger, {
|
|
47
48
|
asChild: true,
|
|
48
49
|
children: /*#__PURE__*/ jsxs(Button, {
|
|
50
|
+
ref: ref,
|
|
49
51
|
variant: "outline",
|
|
50
52
|
className: cn('w-full justify-start text-left font-normal', !selectedDate && 'text-muted-foreground', className),
|
|
51
53
|
disabled: disabled,
|
|
@@ -116,5 +118,5 @@ function DateTimePicker({ value, onValueChange, disabled, placeholder = 'Pick a
|
|
|
116
118
|
})
|
|
117
119
|
]
|
|
118
120
|
});
|
|
119
|
-
}
|
|
120
|
-
export { DateTimePicker };
|
|
121
|
+
});
|
|
122
|
+
export { datetime_picker_DateTimePicker as DateTimePicker };
|
|
@@ -71,7 +71,7 @@ const dialog_DialogClose = /*#__PURE__*/ external_react_namespaceObject.forwardR
|
|
|
71
71
|
const dialog_DialogOverlay = /*#__PURE__*/ external_react_namespaceObject.forwardRef(function({ className, ...props }, ref) {
|
|
72
72
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(react_dialog_namespaceObject.Overlay, {
|
|
73
73
|
"data-slot": "dialog-overlay",
|
|
74
|
-
className: (0, index_cjs_namespaceObject.cn)('data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed flex items-center justify-center inset-0 z-50 bg-
|
|
74
|
+
className: (0, index_cjs_namespaceObject.cn)('data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed flex items-center justify-center inset-0 z-50 bg-curtain', className),
|
|
75
75
|
ref: ref,
|
|
76
76
|
...props
|
|
77
77
|
});
|
|
@@ -34,7 +34,7 @@ const dialog_DialogClose = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
|
34
34
|
const dialog_DialogOverlay = /*#__PURE__*/ forwardRef(function({ className, ...props }, ref) {
|
|
35
35
|
return /*#__PURE__*/ jsx(Overlay, {
|
|
36
36
|
"data-slot": "dialog-overlay",
|
|
37
|
-
className: cn('data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed flex items-center justify-center inset-0 z-50 bg-
|
|
37
|
+
className: cn('data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed flex items-center justify-center inset-0 z-50 bg-curtain', className),
|
|
38
38
|
ref: ref,
|
|
39
39
|
...props
|
|
40
40
|
});
|
|
@@ -40,13 +40,32 @@ const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
|
40
40
|
const external_react_namespaceObject = require("react");
|
|
41
41
|
const external_vaul_namespaceObject = require("vaul");
|
|
42
42
|
const index_cjs_namespaceObject = require("../../lib/index.cjs");
|
|
43
|
-
const Drawer = external_vaul_namespaceObject.Drawer.Root
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
const Drawer = (props)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Root, {
|
|
44
|
+
"data-slot": "drawer",
|
|
45
|
+
...props
|
|
46
|
+
});
|
|
47
|
+
Drawer.displayName = 'Drawer';
|
|
48
|
+
const DrawerTrigger = /*#__PURE__*/ external_react_namespaceObject.forwardRef((props, ref)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Trigger, {
|
|
49
|
+
ref: ref,
|
|
50
|
+
"data-slot": "drawer-trigger",
|
|
51
|
+
...props
|
|
52
|
+
}));
|
|
53
|
+
DrawerTrigger.displayName = 'DrawerTrigger';
|
|
54
|
+
const DrawerPortal = (props)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Portal, {
|
|
55
|
+
"data-slot": "drawer-portal",
|
|
56
|
+
...props
|
|
57
|
+
});
|
|
58
|
+
DrawerPortal.displayName = 'DrawerPortal';
|
|
59
|
+
const DrawerClose = /*#__PURE__*/ external_react_namespaceObject.forwardRef((props, ref)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Close, {
|
|
60
|
+
ref: ref,
|
|
61
|
+
"data-slot": "drawer-close",
|
|
62
|
+
...props
|
|
63
|
+
}));
|
|
64
|
+
DrawerClose.displayName = 'DrawerClose';
|
|
47
65
|
const DrawerOverlay = /*#__PURE__*/ external_react_namespaceObject.forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Overlay, {
|
|
48
66
|
ref: ref,
|
|
49
|
-
|
|
67
|
+
"data-slot": "drawer-overlay",
|
|
68
|
+
className: (0, index_cjs_namespaceObject.cn)('fixed inset-0 z-50 bg-curtain', className),
|
|
50
69
|
...props
|
|
51
70
|
}));
|
|
52
71
|
DrawerOverlay.displayName = external_vaul_namespaceObject.Drawer.Overlay.displayName;
|
|
@@ -55,6 +74,7 @@ const DrawerContent = /*#__PURE__*/ external_react_namespaceObject.forwardRef(({
|
|
|
55
74
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(DrawerOverlay, {}),
|
|
56
75
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_vaul_namespaceObject.Drawer.Content, {
|
|
57
76
|
ref: ref,
|
|
77
|
+
"data-slot": "drawer-content",
|
|
58
78
|
className: (0, index_cjs_namespaceObject.cn)('fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background', className),
|
|
59
79
|
...props,
|
|
60
80
|
children: [
|
|
@@ -68,23 +88,27 @@ const DrawerContent = /*#__PURE__*/ external_react_namespaceObject.forwardRef(({
|
|
|
68
88
|
}));
|
|
69
89
|
DrawerContent.displayName = 'DrawerContent';
|
|
70
90
|
const DrawerHeader = ({ className, ...props })=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
91
|
+
"data-slot": "drawer-header",
|
|
71
92
|
className: (0, index_cjs_namespaceObject.cn)('grid gap-1.5 p-4 text-center sm:text-left', className),
|
|
72
93
|
...props
|
|
73
94
|
});
|
|
74
95
|
DrawerHeader.displayName = 'DrawerHeader';
|
|
75
96
|
const DrawerFooter = ({ className, ...props })=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)("div", {
|
|
97
|
+
"data-slot": "drawer-footer",
|
|
76
98
|
className: (0, index_cjs_namespaceObject.cn)('mt-auto flex flex-col gap-2 p-4', className),
|
|
77
99
|
...props
|
|
78
100
|
});
|
|
79
101
|
DrawerFooter.displayName = 'DrawerFooter';
|
|
80
102
|
const DrawerTitle = /*#__PURE__*/ external_react_namespaceObject.forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Title, {
|
|
81
103
|
ref: ref,
|
|
104
|
+
"data-slot": "drawer-title",
|
|
82
105
|
className: (0, index_cjs_namespaceObject.cn)('text-lg font-semibold leading-none tracking-tight', className),
|
|
83
106
|
...props
|
|
84
107
|
}));
|
|
85
108
|
DrawerTitle.displayName = external_vaul_namespaceObject.Drawer.Title.displayName;
|
|
86
109
|
const DrawerDescription = /*#__PURE__*/ external_react_namespaceObject.forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_vaul_namespaceObject.Drawer.Description, {
|
|
87
110
|
ref: ref,
|
|
111
|
+
"data-slot": "drawer-description",
|
|
88
112
|
className: (0, index_cjs_namespaceObject.cn)('text-sm text-muted-foreground', className),
|
|
89
113
|
...props
|
|
90
114
|
}));
|
|
@@ -1,8 +1,15 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
|
|
3
|
-
declare const
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
import { Drawer as DrawerPrimitive } from 'vaul';
|
|
3
|
+
declare const Drawer: {
|
|
4
|
+
(props: React.ComponentProps<typeof DrawerPrimitive.Root>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
displayName: string;
|
|
6
|
+
};
|
|
7
|
+
declare const DrawerTrigger: React.ForwardRefExoticComponent<Omit<import("@radix-ui/react-dialog").DialogTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
8
|
+
declare const DrawerPortal: {
|
|
9
|
+
(props: React.ComponentProps<typeof DrawerPrimitive.Portal>): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
displayName: string;
|
|
11
|
+
};
|
|
12
|
+
declare const DrawerClose: React.ForwardRefExoticComponent<Omit<import("@radix-ui/react-dialog").DialogCloseProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
6
13
|
declare const DrawerOverlay: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
14
|
declare const DrawerContent: React.ForwardRefExoticComponent<Omit<Omit<import("@radix-ui/react-dialog").DialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
15
|
declare const DrawerHeader: {
|
|
@@ -3,13 +3,32 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
3
3
|
import { forwardRef } from "react";
|
|
4
4
|
import { Drawer } from "vaul";
|
|
5
5
|
import { cn } from "../../lib/index.js";
|
|
6
|
-
const drawer_Drawer = Drawer.Root
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
const drawer_Drawer = (props)=>/*#__PURE__*/ jsx(Drawer.Root, {
|
|
7
|
+
"data-slot": "drawer",
|
|
8
|
+
...props
|
|
9
|
+
});
|
|
10
|
+
drawer_Drawer.displayName = 'Drawer';
|
|
11
|
+
const DrawerTrigger = /*#__PURE__*/ forwardRef((props, ref)=>/*#__PURE__*/ jsx(Drawer.Trigger, {
|
|
12
|
+
ref: ref,
|
|
13
|
+
"data-slot": "drawer-trigger",
|
|
14
|
+
...props
|
|
15
|
+
}));
|
|
16
|
+
DrawerTrigger.displayName = 'DrawerTrigger';
|
|
17
|
+
const DrawerPortal = (props)=>/*#__PURE__*/ jsx(Drawer.Portal, {
|
|
18
|
+
"data-slot": "drawer-portal",
|
|
19
|
+
...props
|
|
20
|
+
});
|
|
21
|
+
DrawerPortal.displayName = 'DrawerPortal';
|
|
22
|
+
const DrawerClose = /*#__PURE__*/ forwardRef((props, ref)=>/*#__PURE__*/ jsx(Drawer.Close, {
|
|
23
|
+
ref: ref,
|
|
24
|
+
"data-slot": "drawer-close",
|
|
25
|
+
...props
|
|
26
|
+
}));
|
|
27
|
+
DrawerClose.displayName = 'DrawerClose';
|
|
10
28
|
const DrawerOverlay = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(Drawer.Overlay, {
|
|
11
29
|
ref: ref,
|
|
12
|
-
|
|
30
|
+
"data-slot": "drawer-overlay",
|
|
31
|
+
className: cn('fixed inset-0 z-50 bg-curtain', className),
|
|
13
32
|
...props
|
|
14
33
|
}));
|
|
15
34
|
DrawerOverlay.displayName = Drawer.Overlay.displayName;
|
|
@@ -18,6 +37,7 @@ const DrawerContent = /*#__PURE__*/ forwardRef(({ className, children, ...props
|
|
|
18
37
|
/*#__PURE__*/ jsx(DrawerOverlay, {}),
|
|
19
38
|
/*#__PURE__*/ jsxs(Drawer.Content, {
|
|
20
39
|
ref: ref,
|
|
40
|
+
"data-slot": "drawer-content",
|
|
21
41
|
className: cn('fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background', className),
|
|
22
42
|
...props,
|
|
23
43
|
children: [
|
|
@@ -31,23 +51,27 @@ const DrawerContent = /*#__PURE__*/ forwardRef(({ className, children, ...props
|
|
|
31
51
|
}));
|
|
32
52
|
DrawerContent.displayName = 'DrawerContent';
|
|
33
53
|
const DrawerHeader = ({ className, ...props })=>/*#__PURE__*/ jsx("div", {
|
|
54
|
+
"data-slot": "drawer-header",
|
|
34
55
|
className: cn('grid gap-1.5 p-4 text-center sm:text-left', className),
|
|
35
56
|
...props
|
|
36
57
|
});
|
|
37
58
|
DrawerHeader.displayName = 'DrawerHeader';
|
|
38
59
|
const DrawerFooter = ({ className, ...props })=>/*#__PURE__*/ jsx("div", {
|
|
60
|
+
"data-slot": "drawer-footer",
|
|
39
61
|
className: cn('mt-auto flex flex-col gap-2 p-4', className),
|
|
40
62
|
...props
|
|
41
63
|
});
|
|
42
64
|
DrawerFooter.displayName = 'DrawerFooter';
|
|
43
65
|
const DrawerTitle = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(Drawer.Title, {
|
|
44
66
|
ref: ref,
|
|
67
|
+
"data-slot": "drawer-title",
|
|
45
68
|
className: cn('text-lg font-semibold leading-none tracking-tight', className),
|
|
46
69
|
...props
|
|
47
70
|
}));
|
|
48
71
|
DrawerTitle.displayName = Drawer.Title.displayName;
|
|
49
72
|
const DrawerDescription = /*#__PURE__*/ forwardRef(({ className, ...props }, ref)=>/*#__PURE__*/ jsx(Drawer.Description, {
|
|
50
73
|
ref: ref,
|
|
74
|
+
"data-slot": "drawer-description",
|
|
51
75
|
className: cn('text-sm text-muted-foreground', className),
|
|
52
76
|
...props
|
|
53
77
|
}));
|