@uipath/apollo-wind 0.9.0 → 0.10.0-pr257.2a4b17b
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/forms/field-renderer.cjs +120 -69
- package/dist/components/forms/field-renderer.js +120 -69
- package/dist/components/forms/form-designer.cjs +2352 -1488
- package/dist/components/forms/form-designer.js +2353 -1489
- package/dist/components/forms/form-examples.cjs +10 -10
- package/dist/components/forms/form-examples.js +10 -10
- package/dist/components/forms/form-state-viewer.cjs +988 -433
- package/dist/components/forms/form-state-viewer.js +988 -433
- package/dist/components/forms/metadata-form.cjs +446 -170
- package/dist/components/forms/metadata-form.js +446 -170
- package/dist/components/forms/schema-viewer.cjs +173 -80
- package/dist/components/forms/schema-viewer.js +173 -80
- package/dist/components/ui/accordion.cjs +131 -27
- package/dist/components/ui/accordion.js +131 -27
- package/dist/components/ui/alert-dialog.cjs +273 -45
- package/dist/components/ui/alert-dialog.js +273 -45
- package/dist/components/ui/alert.cjs +106 -17
- package/dist/components/ui/alert.js +106 -17
- package/dist/components/ui/avatar.cjs +100 -15
- package/dist/components/ui/avatar.js +100 -15
- package/dist/components/ui/badge.cjs +36 -6
- package/dist/components/ui/badge.js +36 -6
- package/dist/components/ui/breadcrumb.cjs +258 -52
- package/dist/components/ui/breadcrumb.js +258 -52
- package/dist/components/ui/button-group.cjs +119 -19
- package/dist/components/ui/button-group.js +119 -19
- package/dist/components/ui/button.cjs +48 -8
- package/dist/components/ui/button.js +48 -8
- package/dist/components/ui/calendar.cjs +88 -30
- package/dist/components/ui/calendar.js +88 -30
- package/dist/components/ui/card.cjs +199 -30
- package/dist/components/ui/card.js +199 -30
- package/dist/components/ui/checkbox.cjs +42 -8
- package/dist/components/ui/checkbox.js +42 -8
- package/dist/components/ui/combobox.cjs +150 -53
- package/dist/components/ui/combobox.js +150 -53
- package/dist/components/ui/command.cjs +291 -53
- package/dist/components/ui/command.js +291 -53
- package/dist/components/ui/context-menu.cjs +370 -72
- package/dist/components/ui/context-menu.js +370 -72
- package/dist/components/ui/data-table.cjs +76 -39
- package/dist/components/ui/data-table.js +76 -39
- package/dist/components/ui/date-picker.cjs +179 -68
- package/dist/components/ui/date-picker.js +179 -68
- package/dist/components/ui/datetime-picker.cjs +225 -104
- package/dist/components/ui/datetime-picker.js +225 -104
- package/dist/components/ui/dialog.cjs +290 -78
- package/dist/components/ui/dialog.js +290 -78
- package/dist/components/ui/drawer.cjs +220 -39
- package/dist/components/ui/drawer.js +220 -39
- package/dist/components/ui/dropdown-menu.cjs +376 -73
- package/dist/components/ui/dropdown-menu.js +376 -73
- package/dist/components/ui/editable-cell.cjs +106 -42
- package/dist/components/ui/editable-cell.js +106 -42
- package/dist/components/ui/empty-state.cjs +106 -33
- package/dist/components/ui/empty-state.js +106 -33
- package/dist/components/ui/file-upload.cjs +405 -187
- package/dist/components/ui/file-upload.d.ts +3 -1
- package/dist/components/ui/file-upload.js +405 -187
- package/dist/components/ui/hover-card.cjs +46 -7
- package/dist/components/ui/hover-card.js +46 -7
- package/dist/components/ui/index.cjs +4 -4
- package/dist/components/ui/input.cjs +39 -6
- package/dist/components/ui/input.js +39 -6
- package/dist/components/ui/label.cjs +34 -5
- package/dist/components/ui/label.js +34 -5
- package/dist/components/ui/layout/column.cjs +209 -41
- package/dist/components/ui/layout/column.js +209 -41
- package/dist/components/ui/layout/grid.cjs +275 -60
- package/dist/components/ui/layout/grid.js +275 -60
- package/dist/components/ui/layout/row.cjs +209 -41
- package/dist/components/ui/layout/row.js +209 -41
- package/dist/components/ui/menubar.cjs +540 -106
- package/dist/components/ui/menubar.js +540 -106
- package/dist/components/ui/multi-select.cjs +289 -135
- package/dist/components/ui/multi-select.js +289 -135
- package/dist/components/ui/navigation-menu.cjs +244 -47
- package/dist/components/ui/navigation-menu.js +244 -47
- package/dist/components/ui/pagination.cjs +301 -65
- package/dist/components/ui/pagination.js +301 -65
- package/dist/components/ui/popover.cjs +48 -9
- package/dist/components/ui/popover.js +48 -9
- package/dist/components/ui/progress.cjs +48 -8
- package/dist/components/ui/progress.js +48 -8
- package/dist/components/ui/radio-group.cjs +74 -12
- package/dist/components/ui/radio-group.js +74 -12
- package/dist/components/ui/resizable.cjs +75 -10
- package/dist/components/ui/resizable.js +75 -10
- package/dist/components/ui/scroll-area.cjs +113 -21
- package/dist/components/ui/scroll-area.js +113 -21
- package/dist/components/ui/search.cjs +280 -98
- package/dist/components/ui/search.js +280 -98
- package/dist/components/ui/select.cjs +334 -68
- package/dist/components/ui/select.js +334 -68
- package/dist/components/ui/separator.cjs +48 -7
- package/dist/components/ui/separator.js +48 -7
- package/dist/components/ui/sheet.cjs +236 -50
- package/dist/components/ui/sheet.js +236 -50
- package/dist/components/ui/skeleton.cjs +31 -5
- package/dist/components/ui/skeleton.js +31 -5
- package/dist/components/ui/slider.cjs +71 -21
- package/dist/components/ui/slider.js +71 -21
- package/dist/components/ui/sonner.cjs +43 -15
- package/dist/components/ui/sonner.js +43 -15
- package/dist/components/ui/spinner.cjs +83 -21
- package/dist/components/ui/spinner.js +83 -21
- package/dist/components/ui/stats-card.cjs +169 -60
- package/dist/components/ui/stats-card.js +169 -60
- package/dist/components/ui/stepper.cjs +126 -57
- package/dist/components/ui/stepper.js +126 -57
- package/dist/components/ui/switch.cjs +42 -8
- package/dist/components/ui/switch.js +42 -8
- package/dist/components/ui/table.cjs +267 -42
- package/dist/components/ui/table.js +267 -42
- package/dist/components/ui/tabs.cjs +100 -15
- package/dist/components/ui/tabs.js +100 -15
- package/dist/components/ui/textarea.cjs +34 -5
- package/dist/components/ui/textarea.js +34 -5
- package/dist/components/ui/toggle-group.cjs +112 -19
- package/dist/components/ui/toggle-group.js +112 -19
- package/dist/components/ui/toggle.cjs +43 -6
- package/dist/components/ui/toggle.js +43 -6
- package/dist/components/ui/tooltip.cjs +40 -6
- package/dist/components/ui/tooltip.js +40 -6
- package/dist/examples/admin-layout-example.cjs +879 -347
- package/dist/examples/admin-layout-example.js +879 -347
- package/dist/examples/app-shell-example.cjs +14 -14
- package/dist/examples/app-shell-example.js +14 -14
- package/dist/examples/dashboard-example.cjs +495 -334
- package/dist/examples/dashboard-example.js +495 -334
- package/dist/examples/data-management-example.cjs +501 -303
- package/dist/examples/data-management-example.js +502 -304
- package/dist/examples/flow-editor-layout-example.cjs +435 -231
- package/dist/examples/flow-editor-layout-example.js +436 -232
- package/dist/examples/flow-start-example.cjs +508 -251
- package/dist/examples/flow-start-example.js +509 -252
- package/dist/examples/form-builder-example.cjs +1006 -602
- package/dist/examples/form-builder-example.js +1007 -603
- package/dist/examples/new-project-example.cjs +806 -474
- package/dist/examples/new-project-example.js +807 -475
- package/dist/examples/settings-example.cjs +792 -704
- package/dist/examples/settings-example.js +792 -704
- package/dist/examples/vscode-example.cjs +731 -236
- package/dist/examples/vscode-example.js +731 -236
- package/package.json +4 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { c } from "react/compiler-runtime";
|
|
2
3
|
import { Check, ChevronsUpDown, X } from "lucide-react";
|
|
3
4
|
import { forwardRef, useState } from "react";
|
|
4
5
|
import { Badge } from "./badge.js";
|
|
@@ -6,148 +7,301 @@ import { Button } from "./button.js";
|
|
|
6
7
|
import { Command, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList } from "./command.js";
|
|
7
8
|
import { Popover, PopoverContent, PopoverTrigger } from "./popover.js";
|
|
8
9
|
import { cn } from "../../lib/index.js";
|
|
9
|
-
const MultiSelect = /*#__PURE__*/ forwardRef((
|
|
10
|
+
const MultiSelect = /*#__PURE__*/ forwardRef((t0, ref)=>{
|
|
11
|
+
const $ = c(64);
|
|
12
|
+
const { options, selected, onChange, placeholder: t1, emptyMessage: t2, className, maxSelected, disabled: t3, searchPlaceholder: t4, clearAllText } = t0;
|
|
13
|
+
const placeholder = void 0 === t1 ? "Select items..." : t1;
|
|
14
|
+
const emptyMessage = void 0 === t2 ? "No items found." : t2;
|
|
15
|
+
const disabled = void 0 === t3 ? false : t3;
|
|
16
|
+
const searchPlaceholder = void 0 === t4 ? "Search..." : t4;
|
|
10
17
|
const [open, setOpen] = useState(false);
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
18
|
+
let t5;
|
|
19
|
+
if ($[0] !== onChange || $[1] !== selected) {
|
|
20
|
+
t5 = (value)=>{
|
|
21
|
+
onChange(selected.filter((s)=>s !== value));
|
|
22
|
+
};
|
|
23
|
+
$[0] = onChange;
|
|
24
|
+
$[1] = selected;
|
|
25
|
+
$[2] = t5;
|
|
26
|
+
} else t5 = $[2];
|
|
27
|
+
const handleUnselect = t5;
|
|
28
|
+
let t6;
|
|
29
|
+
if ($[3] !== handleUnselect || $[4] !== maxSelected || $[5] !== onChange || $[6] !== selected) {
|
|
30
|
+
t6 = (value_0)=>{
|
|
31
|
+
if (selected.includes(value_0)) handleUnselect(value_0);
|
|
32
|
+
else {
|
|
33
|
+
if (maxSelected && selected.length >= maxSelected) return;
|
|
34
|
+
onChange([
|
|
35
|
+
...selected,
|
|
36
|
+
value_0
|
|
37
|
+
]);
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
$[3] = handleUnselect;
|
|
41
|
+
$[4] = maxSelected;
|
|
42
|
+
$[5] = onChange;
|
|
43
|
+
$[6] = selected;
|
|
44
|
+
$[7] = t6;
|
|
45
|
+
} else t6 = $[7];
|
|
46
|
+
const handleSelect = t6;
|
|
47
|
+
let t7;
|
|
48
|
+
if ($[8] !== onChange) {
|
|
49
|
+
t7 = ()=>{
|
|
50
|
+
onChange([]);
|
|
51
|
+
};
|
|
52
|
+
$[8] = onChange;
|
|
53
|
+
$[9] = t7;
|
|
54
|
+
} else t7 = $[9];
|
|
55
|
+
const handleClearAll = t7;
|
|
56
|
+
let t8;
|
|
57
|
+
if ($[10] !== className) {
|
|
58
|
+
t8 = cn("relative", className);
|
|
59
|
+
$[10] = className;
|
|
60
|
+
$[11] = t8;
|
|
61
|
+
} else t8 = $[11];
|
|
62
|
+
const t9 = selected.length > 0 ? `${selected.length} items selected` : placeholder;
|
|
63
|
+
const t10 = selected.length > 0 ? "h-auto min-h-10" : "h-10";
|
|
64
|
+
let t11;
|
|
65
|
+
if ($[12] !== t10) {
|
|
66
|
+
t11 = cn("w-full justify-between", t10);
|
|
67
|
+
$[12] = t10;
|
|
68
|
+
$[13] = t11;
|
|
69
|
+
} else t11 = $[13];
|
|
70
|
+
let t12;
|
|
71
|
+
if ($[14] !== handleUnselect || $[15] !== options || $[16] !== placeholder || $[17] !== selected) {
|
|
72
|
+
t12 = 0 === selected.length ? /*#__PURE__*/ jsx("span", {
|
|
73
|
+
className: "text-muted-foreground",
|
|
74
|
+
children: placeholder
|
|
75
|
+
}) : selected.map((value_1)=>{
|
|
76
|
+
const option = options.find((opt)=>opt.value === value_1);
|
|
77
|
+
return /*#__PURE__*/ jsxs(Badge, {
|
|
78
|
+
variant: "secondary",
|
|
79
|
+
className: "mr-1",
|
|
80
|
+
onClick: (e)=>{
|
|
81
|
+
e.stopPropagation();
|
|
82
|
+
handleUnselect(value_1);
|
|
83
|
+
},
|
|
84
|
+
children: [
|
|
85
|
+
option?.label,
|
|
86
|
+
/*#__PURE__*/ jsx("span", {
|
|
87
|
+
role: "button",
|
|
88
|
+
tabIndex: 0,
|
|
89
|
+
"aria-label": `Remove ${option?.label}`,
|
|
90
|
+
className: "ml-1 rounded-full outline-none ring-offset-background focus:ring-2 focus:ring-ring focus:ring-offset-2 cursor-pointer",
|
|
91
|
+
onKeyDown: (e_0)=>{
|
|
92
|
+
if ("Enter" === e_0.key || " " === e_0.key) {
|
|
93
|
+
e_0.preventDefault();
|
|
94
|
+
handleUnselect(value_1);
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
onMouseDown: _temp,
|
|
98
|
+
onClick: (e_2)=>{
|
|
99
|
+
e_2.preventDefault();
|
|
100
|
+
e_2.stopPropagation();
|
|
101
|
+
handleUnselect(value_1);
|
|
102
|
+
},
|
|
103
|
+
children: /*#__PURE__*/ jsx(X, {
|
|
104
|
+
className: "h-3 w-3 text-muted-foreground hover:text-foreground"
|
|
105
|
+
})
|
|
92
106
|
})
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
107
|
+
]
|
|
108
|
+
}, value_1);
|
|
109
|
+
});
|
|
110
|
+
$[14] = handleUnselect;
|
|
111
|
+
$[15] = options;
|
|
112
|
+
$[16] = placeholder;
|
|
113
|
+
$[17] = selected;
|
|
114
|
+
$[18] = t12;
|
|
115
|
+
} else t12 = $[18];
|
|
116
|
+
let t13;
|
|
117
|
+
if ($[19] !== t12) {
|
|
118
|
+
t13 = /*#__PURE__*/ jsx("div", {
|
|
119
|
+
className: "flex flex-wrap gap-1 flex-1",
|
|
120
|
+
children: t12
|
|
121
|
+
});
|
|
122
|
+
$[19] = t12;
|
|
123
|
+
$[20] = t13;
|
|
124
|
+
} else t13 = $[20];
|
|
125
|
+
let t14;
|
|
126
|
+
if ($[21] === Symbol.for("react.memo_cache_sentinel")) {
|
|
127
|
+
t14 = /*#__PURE__*/ jsx(ChevronsUpDown, {
|
|
128
|
+
className: "h-4 w-4 shrink-0 opacity-50"
|
|
129
|
+
});
|
|
130
|
+
$[21] = t14;
|
|
131
|
+
} else t14 = $[21];
|
|
132
|
+
let t15;
|
|
133
|
+
if ($[22] !== disabled || $[23] !== open || $[24] !== t11 || $[25] !== t13 || $[26] !== t9) {
|
|
134
|
+
t15 = /*#__PURE__*/ jsx(PopoverTrigger, {
|
|
135
|
+
asChild: true,
|
|
136
|
+
children: /*#__PURE__*/ jsxs(Button, {
|
|
137
|
+
variant: "outline",
|
|
138
|
+
role: "combobox",
|
|
139
|
+
"aria-expanded": open,
|
|
140
|
+
"aria-label": t9,
|
|
141
|
+
className: t11,
|
|
142
|
+
disabled: disabled,
|
|
143
|
+
children: [
|
|
144
|
+
t13,
|
|
145
|
+
t14
|
|
146
|
+
]
|
|
147
|
+
})
|
|
148
|
+
});
|
|
149
|
+
$[22] = disabled;
|
|
150
|
+
$[23] = open;
|
|
151
|
+
$[24] = t11;
|
|
152
|
+
$[25] = t13;
|
|
153
|
+
$[26] = t9;
|
|
154
|
+
$[27] = t15;
|
|
155
|
+
} else t15 = $[27];
|
|
156
|
+
let t16;
|
|
157
|
+
if ($[28] !== searchPlaceholder) {
|
|
158
|
+
t16 = /*#__PURE__*/ jsx(CommandInput, {
|
|
159
|
+
placeholder: searchPlaceholder
|
|
160
|
+
});
|
|
161
|
+
$[28] = searchPlaceholder;
|
|
162
|
+
$[29] = t16;
|
|
163
|
+
} else t16 = $[29];
|
|
164
|
+
let t17;
|
|
165
|
+
if ($[30] !== emptyMessage) {
|
|
166
|
+
t17 = /*#__PURE__*/ jsx(CommandEmpty, {
|
|
167
|
+
children: emptyMessage
|
|
168
|
+
});
|
|
169
|
+
$[30] = emptyMessage;
|
|
170
|
+
$[31] = t17;
|
|
171
|
+
} else t17 = $[31];
|
|
172
|
+
let t18;
|
|
173
|
+
if ($[32] !== handleSelect || $[33] !== maxSelected || $[34] !== options || $[35] !== selected) {
|
|
174
|
+
let t19;
|
|
175
|
+
if ($[37] !== handleSelect || $[38] !== maxSelected || $[39] !== selected) {
|
|
176
|
+
t19 = (option_0)=>{
|
|
177
|
+
const isSelected = selected.includes(option_0.value);
|
|
178
|
+
const isDisabled = void 0 !== maxSelected && selected.length >= maxSelected && !isSelected;
|
|
179
|
+
return /*#__PURE__*/ jsxs(CommandItem, {
|
|
180
|
+
onSelect: ()=>{
|
|
181
|
+
if (!isDisabled) handleSelect(option_0.value);
|
|
182
|
+
},
|
|
183
|
+
disabled: isDisabled,
|
|
184
|
+
className: cn(isDisabled && "opacity-50 cursor-not-allowed"),
|
|
97
185
|
children: [
|
|
98
|
-
/*#__PURE__*/
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
}),
|
|
103
|
-
/*#__PURE__*/ jsxs(CommandList, {
|
|
104
|
-
children: [
|
|
105
|
-
/*#__PURE__*/ jsx(CommandEmpty, {
|
|
106
|
-
children: emptyMessage
|
|
107
|
-
}),
|
|
108
|
-
/*#__PURE__*/ jsx(CommandGroup, {
|
|
109
|
-
children: options.map((option)=>{
|
|
110
|
-
const isSelected = selected.includes(option.value);
|
|
111
|
-
const isDisabled = void 0 !== maxSelected && selected.length >= maxSelected && !isSelected;
|
|
112
|
-
return /*#__PURE__*/ jsxs(CommandItem, {
|
|
113
|
-
onSelect: ()=>{
|
|
114
|
-
if (!isDisabled) handleSelect(option.value);
|
|
115
|
-
},
|
|
116
|
-
disabled: isDisabled,
|
|
117
|
-
className: cn(isDisabled && 'opacity-50 cursor-not-allowed'),
|
|
118
|
-
children: [
|
|
119
|
-
/*#__PURE__*/ jsx("div", {
|
|
120
|
-
className: cn('mr-2 flex h-4 w-4 items-center justify-center rounded-sm border border-primary', isSelected ? 'bg-primary text-primary-foreground' : 'opacity-50 [&_svg]:invisible'),
|
|
121
|
-
children: /*#__PURE__*/ jsx(Check, {
|
|
122
|
-
className: "h-4 w-4"
|
|
123
|
-
})
|
|
124
|
-
}),
|
|
125
|
-
/*#__PURE__*/ jsx("span", {
|
|
126
|
-
children: option.label
|
|
127
|
-
})
|
|
128
|
-
]
|
|
129
|
-
}, option.value);
|
|
130
|
-
})
|
|
131
|
-
})
|
|
132
|
-
]
|
|
133
|
-
})
|
|
134
|
-
]
|
|
135
|
-
}),
|
|
136
|
-
selected.length > 0 && /*#__PURE__*/ jsx("div", {
|
|
137
|
-
className: "border-t p-2",
|
|
138
|
-
children: /*#__PURE__*/ jsx(Button, {
|
|
139
|
-
variant: "ghost",
|
|
140
|
-
size: "sm",
|
|
141
|
-
className: "w-full",
|
|
142
|
-
onClick: handleClearAll,
|
|
143
|
-
children: 'function' == typeof clearAllText ? clearAllText(selected.length) : clearAllText || `Clear all (${selected.length})`
|
|
186
|
+
/*#__PURE__*/ jsx("div", {
|
|
187
|
+
className: cn("mr-2 flex h-4 w-4 items-center justify-center rounded-sm border border-primary", isSelected ? "bg-primary text-primary-foreground" : "opacity-50 [&_svg]:invisible"),
|
|
188
|
+
children: /*#__PURE__*/ jsx(Check, {
|
|
189
|
+
className: "h-4 w-4"
|
|
144
190
|
})
|
|
191
|
+
}),
|
|
192
|
+
/*#__PURE__*/ jsx("span", {
|
|
193
|
+
children: option_0.label
|
|
145
194
|
})
|
|
146
195
|
]
|
|
147
|
-
})
|
|
196
|
+
}, option_0.value);
|
|
197
|
+
};
|
|
198
|
+
$[37] = handleSelect;
|
|
199
|
+
$[38] = maxSelected;
|
|
200
|
+
$[39] = selected;
|
|
201
|
+
$[40] = t19;
|
|
202
|
+
} else t19 = $[40];
|
|
203
|
+
t18 = options.map(t19);
|
|
204
|
+
$[32] = handleSelect;
|
|
205
|
+
$[33] = maxSelected;
|
|
206
|
+
$[34] = options;
|
|
207
|
+
$[35] = selected;
|
|
208
|
+
$[36] = t18;
|
|
209
|
+
} else t18 = $[36];
|
|
210
|
+
let t19;
|
|
211
|
+
if ($[41] !== t18) {
|
|
212
|
+
t19 = /*#__PURE__*/ jsx(CommandGroup, {
|
|
213
|
+
children: t18
|
|
214
|
+
});
|
|
215
|
+
$[41] = t18;
|
|
216
|
+
$[42] = t19;
|
|
217
|
+
} else t19 = $[42];
|
|
218
|
+
let t20;
|
|
219
|
+
if ($[43] !== t17 || $[44] !== t19) {
|
|
220
|
+
t20 = /*#__PURE__*/ jsxs(CommandList, {
|
|
221
|
+
children: [
|
|
222
|
+
t17,
|
|
223
|
+
t19
|
|
224
|
+
]
|
|
225
|
+
});
|
|
226
|
+
$[43] = t17;
|
|
227
|
+
$[44] = t19;
|
|
228
|
+
$[45] = t20;
|
|
229
|
+
} else t20 = $[45];
|
|
230
|
+
let t21;
|
|
231
|
+
if ($[46] !== t16 || $[47] !== t20) {
|
|
232
|
+
t21 = /*#__PURE__*/ jsxs(Command, {
|
|
233
|
+
children: [
|
|
234
|
+
t16,
|
|
235
|
+
t20
|
|
236
|
+
]
|
|
237
|
+
});
|
|
238
|
+
$[46] = t16;
|
|
239
|
+
$[47] = t20;
|
|
240
|
+
$[48] = t21;
|
|
241
|
+
} else t21 = $[48];
|
|
242
|
+
let t22;
|
|
243
|
+
if ($[49] !== clearAllText || $[50] !== handleClearAll || $[51] !== selected.length) {
|
|
244
|
+
t22 = selected.length > 0 && /*#__PURE__*/ jsx("div", {
|
|
245
|
+
className: "border-t p-2",
|
|
246
|
+
children: /*#__PURE__*/ jsx(Button, {
|
|
247
|
+
variant: "ghost",
|
|
248
|
+
size: "sm",
|
|
249
|
+
className: "w-full",
|
|
250
|
+
onClick: handleClearAll,
|
|
251
|
+
children: "function" == typeof clearAllText ? clearAllText(selected.length) : clearAllText || `Clear all (${selected.length})`
|
|
252
|
+
})
|
|
253
|
+
});
|
|
254
|
+
$[49] = clearAllText;
|
|
255
|
+
$[50] = handleClearAll;
|
|
256
|
+
$[51] = selected.length;
|
|
257
|
+
$[52] = t22;
|
|
258
|
+
} else t22 = $[52];
|
|
259
|
+
let t23;
|
|
260
|
+
if ($[53] !== t21 || $[54] !== t22) {
|
|
261
|
+
t23 = /*#__PURE__*/ jsxs(PopoverContent, {
|
|
262
|
+
className: "w-[--radix-popover-trigger-width] p-0",
|
|
263
|
+
align: "start",
|
|
264
|
+
children: [
|
|
265
|
+
t21,
|
|
266
|
+
t22
|
|
267
|
+
]
|
|
268
|
+
});
|
|
269
|
+
$[53] = t21;
|
|
270
|
+
$[54] = t22;
|
|
271
|
+
$[55] = t23;
|
|
272
|
+
} else t23 = $[55];
|
|
273
|
+
let t24;
|
|
274
|
+
if ($[56] !== open || $[57] !== t15 || $[58] !== t23) {
|
|
275
|
+
t24 = /*#__PURE__*/ jsxs(Popover, {
|
|
276
|
+
open: open,
|
|
277
|
+
onOpenChange: setOpen,
|
|
278
|
+
children: [
|
|
279
|
+
t15,
|
|
280
|
+
t23
|
|
148
281
|
]
|
|
149
|
-
})
|
|
150
|
-
|
|
282
|
+
});
|
|
283
|
+
$[56] = open;
|
|
284
|
+
$[57] = t15;
|
|
285
|
+
$[58] = t23;
|
|
286
|
+
$[59] = t24;
|
|
287
|
+
} else t24 = $[59];
|
|
288
|
+
let t25;
|
|
289
|
+
if ($[60] !== ref || $[61] !== t24 || $[62] !== t8) {
|
|
290
|
+
t25 = /*#__PURE__*/ jsx("div", {
|
|
291
|
+
ref: ref,
|
|
292
|
+
className: t8,
|
|
293
|
+
children: t24
|
|
294
|
+
});
|
|
295
|
+
$[60] = ref;
|
|
296
|
+
$[61] = t24;
|
|
297
|
+
$[62] = t8;
|
|
298
|
+
$[63] = t25;
|
|
299
|
+
} else t25 = $[63];
|
|
300
|
+
return t25;
|
|
151
301
|
});
|
|
152
302
|
MultiSelect.displayName = 'MultiSelect';
|
|
303
|
+
function _temp(e_1) {
|
|
304
|
+
e_1.preventDefault();
|
|
305
|
+
e_1.stopPropagation();
|
|
306
|
+
}
|
|
153
307
|
export { MultiSelect };
|