lecom-ui 5.3.76 → 5.3.77
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/README.md +1 -1
- package/dist/components/Collapse/Collapse.js +94 -0
- package/dist/components/Combobox/Combobox.js +58 -24
- package/dist/components/MultiSelect/MultiSelect.js +17 -14
- package/dist/components/NumberControl/NumberControl.js +20 -9
- package/dist/index.d.ts +14 -20
- package/dist/plugin/extend.js +78 -78
- package/dist/plugin/fontFaces.js +172 -172
- package/dist/plugin/general.js +12 -12
- package/dist/plugin/pluginDev.cjs +5 -5
- package/dist/plugin/pluginNext.cjs +5 -5
- package/dist/plugin/pluginNextTurbo.cjs +5 -5
- package/dist/plugin/pluginVite.cjs +5 -5
- package/dist/plugin/template.js +31 -31
- package/dist/plugin/typographies.js +152 -152
- package/dist/plugin/varsTheme.js +79 -79
- package/dist/style.min.css +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
lecom-ui
|
|
1
|
+
lecom-ui
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { cn } from '../../lib/utils.js';
|
|
3
|
+
import * as AccordionPrimitive from '@radix-ui/react-accordion';
|
|
4
|
+
import { cva } from 'class-variance-authority';
|
|
5
|
+
import { ChevronRight } from 'lucide-react';
|
|
6
|
+
|
|
7
|
+
const collapseTriggerVariants = cva(
|
|
8
|
+
"flex items-center justify-between w-full transition-all text-left outline-none data-[state=open]:font-semibold",
|
|
9
|
+
{
|
|
10
|
+
variants: {
|
|
11
|
+
size: {
|
|
12
|
+
small: "text-sm py-1.5 px-4 min-h-8",
|
|
13
|
+
medium: "text-base py-2.5 px-4 min-h-10",
|
|
14
|
+
large: "text-lg py-3 px-4 min-h-12"
|
|
15
|
+
},
|
|
16
|
+
ghost: {
|
|
17
|
+
true: "bg-transparent border-none",
|
|
18
|
+
false: "border-t-none border-grey-400"
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
defaultVariants: {
|
|
22
|
+
size: "large",
|
|
23
|
+
ghost: false
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
);
|
|
27
|
+
const CollapseRoot = AccordionPrimitive.Root;
|
|
28
|
+
const CollapseItem = AccordionPrimitive.Item;
|
|
29
|
+
const CollapsePanel = React.forwardRef(
|
|
30
|
+
({
|
|
31
|
+
header,
|
|
32
|
+
children,
|
|
33
|
+
extra,
|
|
34
|
+
expandIconPosition = "start",
|
|
35
|
+
size = "large",
|
|
36
|
+
ghost = false,
|
|
37
|
+
disabled = false,
|
|
38
|
+
className,
|
|
39
|
+
...props
|
|
40
|
+
}, ref) => /* @__PURE__ */ React.createElement(
|
|
41
|
+
CollapseItem,
|
|
42
|
+
{
|
|
43
|
+
ref,
|
|
44
|
+
...props,
|
|
45
|
+
className: cn(
|
|
46
|
+
"group w-full",
|
|
47
|
+
disabled && "pointer-events-none opacity-50",
|
|
48
|
+
className
|
|
49
|
+
)
|
|
50
|
+
},
|
|
51
|
+
/* @__PURE__ */ React.createElement(AccordionPrimitive.Header, { asChild: true }, /* @__PURE__ */ React.createElement(
|
|
52
|
+
AccordionPrimitive.Trigger,
|
|
53
|
+
{
|
|
54
|
+
disabled,
|
|
55
|
+
className: cn(
|
|
56
|
+
collapseTriggerVariants({ size, ghost }),
|
|
57
|
+
"flex gap-2 items-center text-left font-normal"
|
|
58
|
+
)
|
|
59
|
+
},
|
|
60
|
+
/* @__PURE__ */ React.createElement(
|
|
61
|
+
"div",
|
|
62
|
+
{
|
|
63
|
+
className: cn(
|
|
64
|
+
"flex flex-1 items-center justify-between gap-4 w-full",
|
|
65
|
+
expandIconPosition === "end" ? "flex-row-reverse" : ""
|
|
66
|
+
)
|
|
67
|
+
},
|
|
68
|
+
/* @__PURE__ */ React.createElement("div", { className: "flex items-center gap-2 truncate" }, /* @__PURE__ */ React.createElement(
|
|
69
|
+
"span",
|
|
70
|
+
{
|
|
71
|
+
className: "flex items-center justify-center flex-shrink-0 min-w-4 min-h-4 transition-transform duration-300 group-data-[state=open]:rotate-90 text-grey-700 text-lg select-none font-normal"
|
|
72
|
+
},
|
|
73
|
+
/* @__PURE__ */ React.createElement(ChevronRight, { className: "size-4" })
|
|
74
|
+
), /* @__PURE__ */ React.createElement("span", { className: "font-normal" }, header)),
|
|
75
|
+
extra && /* @__PURE__ */ React.createElement("div", { className: "text-sm text-grey-500" }, extra)
|
|
76
|
+
)
|
|
77
|
+
)),
|
|
78
|
+
/* @__PURE__ */ React.createElement(
|
|
79
|
+
AccordionPrimitive.Content,
|
|
80
|
+
{
|
|
81
|
+
className: cn(
|
|
82
|
+
"overflow-hidden data-[state=open]:animate-accordion-down data-[state=closed]:animate-accordion-up"
|
|
83
|
+
)
|
|
84
|
+
},
|
|
85
|
+
/* @__PURE__ */ React.createElement("div", { className: "text-sm text-grey-800 pt-2 pb-4 px-4" }, children)
|
|
86
|
+
)
|
|
87
|
+
)
|
|
88
|
+
);
|
|
89
|
+
CollapsePanel.displayName = "CollapsePanel";
|
|
90
|
+
const Collapse = Object.assign(CollapseRoot, {
|
|
91
|
+
Panel: CollapsePanel
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
export { Collapse, collapseTriggerVariants };
|
|
@@ -22,19 +22,21 @@ const SEARCH_INPUT_CLASSES = {
|
|
|
22
22
|
large: "[&_[cmdk-input]]:h-9 [&_[cmdk-input]]:body-large-400 [&_svg]:text-grey-800 [&_svg]:opacity-100 [&_svg]:h-4 [&_svg]:w-4"
|
|
23
23
|
};
|
|
24
24
|
const isComboboxGroup = (item) => "options" in item && Array.isArray(item.options);
|
|
25
|
-
const
|
|
26
|
-
const
|
|
27
|
-
const
|
|
28
|
-
|
|
25
|
+
const normalize = (s) => s.normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().trim();
|
|
26
|
+
const matchesSearch = (text, searchTerm) => normalize(text).includes(normalize(searchTerm));
|
|
27
|
+
const filterOption = (option, search) => matchesSearch(option.label, search) || matchesSearch(option.value, search);
|
|
28
|
+
const filterComboboxOptions = (opts, search) => {
|
|
29
|
+
const normalizedSearch = normalize(search);
|
|
30
|
+
if (!normalizedSearch) return opts;
|
|
29
31
|
return opts.reduce((acc, item) => {
|
|
30
32
|
if (isComboboxGroup(item)) {
|
|
31
33
|
const filteredOptions = item.options.filter(
|
|
32
|
-
(opt) => filterOption(opt,
|
|
34
|
+
(opt) => filterOption(opt, normalizedSearch)
|
|
33
35
|
);
|
|
34
36
|
if (filteredOptions.length > 0) {
|
|
35
37
|
acc.push({ ...item, options: filteredOptions });
|
|
36
38
|
}
|
|
37
|
-
} else if (filterOption(item,
|
|
39
|
+
} else if (filterOption(item, normalizedSearch)) {
|
|
38
40
|
acc.push(item);
|
|
39
41
|
}
|
|
40
42
|
return acc;
|
|
@@ -54,22 +56,27 @@ const getFontVariant = (size) => {
|
|
|
54
56
|
return sizeMap[size ?? "medium"];
|
|
55
57
|
};
|
|
56
58
|
const comboboxItemVariants = cva(
|
|
57
|
-
"text-grey-800 flex items-
|
|
59
|
+
"text-grey-800 flex items-start justify-start gap-2 hover:bg-grey-50 hover:cursor-pointer py-1 w-full",
|
|
58
60
|
{
|
|
59
61
|
variants: {
|
|
60
62
|
size: {
|
|
61
|
-
small: "
|
|
62
|
-
medium: "
|
|
63
|
-
large: "
|
|
63
|
+
small: "body-small-400",
|
|
64
|
+
medium: "body-medium-400",
|
|
65
|
+
large: "body-large-400"
|
|
64
66
|
},
|
|
65
67
|
disabled: {
|
|
66
68
|
true: "text-grey-400 pointer-events-none",
|
|
67
69
|
false: ""
|
|
70
|
+
},
|
|
71
|
+
selected: {
|
|
72
|
+
true: "bg-grey-100 font-medium text-grey-900",
|
|
73
|
+
false: ""
|
|
68
74
|
}
|
|
69
75
|
},
|
|
70
76
|
defaultVariants: {
|
|
71
77
|
size: "medium",
|
|
72
|
-
disabled: false
|
|
78
|
+
disabled: false,
|
|
79
|
+
selected: false
|
|
73
80
|
}
|
|
74
81
|
}
|
|
75
82
|
);
|
|
@@ -90,28 +97,41 @@ const ComboboxItemContent = ({
|
|
|
90
97
|
const checkIconSize = CHECK_ICON_SIZES[size];
|
|
91
98
|
const isDisabled = option.disabled || false;
|
|
92
99
|
const textColor = isDisabled ? "text-grey-400" : "text-grey-800";
|
|
100
|
+
const isSelected = option.value === value;
|
|
93
101
|
return /* @__PURE__ */ React.createElement(
|
|
94
102
|
CommandItem,
|
|
95
103
|
{
|
|
96
104
|
key: option.value,
|
|
97
105
|
onSelect: handleSelect,
|
|
106
|
+
"data-combobox-value": option.value,
|
|
107
|
+
tabIndex: isSelected ? 0 : -1,
|
|
98
108
|
className: cn(
|
|
99
109
|
comboboxItemVariants({
|
|
100
110
|
size,
|
|
101
|
-
disabled: isDisabled
|
|
111
|
+
disabled: isDisabled,
|
|
112
|
+
selected: isSelected
|
|
102
113
|
}),
|
|
103
114
|
itemsClassName
|
|
104
|
-
)
|
|
115
|
+
),
|
|
116
|
+
"aria-current": isSelected ? "true" : void 0
|
|
105
117
|
},
|
|
106
|
-
/* @__PURE__ */ React.createElement(Typography, { className: "w-4 h-4 flex items-
|
|
107
|
-
|
|
118
|
+
/* @__PURE__ */ React.createElement(Typography, { className: "w-4 h-4 flex items-start justify-center shrink-0 pt-1" }, option.value === value && /* @__PURE__ */ React.createElement(
|
|
119
|
+
Check,
|
|
120
|
+
{
|
|
121
|
+
className: cn(textColor, isSelected ? "text-primary-600" : ""),
|
|
122
|
+
size: checkIconSize,
|
|
123
|
+
strokeWidth: isSelected ? 2.5 : 2
|
|
124
|
+
}
|
|
125
|
+
)),
|
|
126
|
+
option.prefix && /* @__PURE__ */ React.createElement(Typography, { className: cn("mr-2 flex items-start shrink-0", textColor) }, option.prefix),
|
|
127
|
+
/* @__PURE__ */ React.createElement(
|
|
108
128
|
Typography,
|
|
109
129
|
{
|
|
110
|
-
|
|
130
|
+
variant: fontVariant,
|
|
131
|
+
className: cn(textColor, "whitespace-normal")
|
|
111
132
|
},
|
|
112
|
-
option.
|
|
113
|
-
)
|
|
114
|
-
/* @__PURE__ */ React.createElement(Typography, { variant: fontVariant, className: textColor }, option.label)
|
|
133
|
+
option.label
|
|
134
|
+
)
|
|
115
135
|
);
|
|
116
136
|
};
|
|
117
137
|
ComboboxItemContent.displayName = "ComboboxItemContent";
|
|
@@ -258,8 +278,9 @@ function Combobox({
|
|
|
258
278
|
}) {
|
|
259
279
|
const [open, setOpen] = React.useState(false);
|
|
260
280
|
const [search, setSearch] = React.useState("");
|
|
281
|
+
const commandListRef = React.useRef(null);
|
|
261
282
|
const filteredOptions = React.useMemo(
|
|
262
|
-
() => !search ? options : filterComboboxOptions(options, search
|
|
283
|
+
() => !search ? options : filterComboboxOptions(options, search),
|
|
263
284
|
[options, search]
|
|
264
285
|
);
|
|
265
286
|
const selectedOption = React.useMemo(
|
|
@@ -271,6 +292,18 @@ function Combobox({
|
|
|
271
292
|
const handleClose = React.useCallback(() => {
|
|
272
293
|
setOpen(false);
|
|
273
294
|
}, []);
|
|
295
|
+
React.useEffect(() => {
|
|
296
|
+
if (!open) return;
|
|
297
|
+
if (!value) return;
|
|
298
|
+
requestAnimationFrame(() => {
|
|
299
|
+
const el = commandListRef.current?.querySelector(
|
|
300
|
+
`[data-combobox-value="${value}"]`
|
|
301
|
+
);
|
|
302
|
+
if (el) {
|
|
303
|
+
el.scrollIntoView({ block: "nearest" });
|
|
304
|
+
}
|
|
305
|
+
});
|
|
306
|
+
}, [open, value]);
|
|
274
307
|
React.useEffect(() => {
|
|
275
308
|
if (!open) {
|
|
276
309
|
setSearch("");
|
|
@@ -306,8 +339,10 @@ function Combobox({
|
|
|
306
339
|
onValueChange: setSearch
|
|
307
340
|
}
|
|
308
341
|
), /* @__PURE__ */ React.createElement(
|
|
309
|
-
|
|
342
|
+
"div",
|
|
310
343
|
{
|
|
344
|
+
ref: commandListRef,
|
|
345
|
+
key: search,
|
|
311
346
|
className: cn(
|
|
312
347
|
"max-h-44 overflow-y-auto overflow-x-hidden",
|
|
313
348
|
"[&::-webkit-scrollbar]:w-1.5",
|
|
@@ -318,8 +353,7 @@ function Combobox({
|
|
|
318
353
|
contentClassName
|
|
319
354
|
)
|
|
320
355
|
},
|
|
321
|
-
/* @__PURE__ */ React.createElement(CommandEmpty, null, notFoundContent),
|
|
322
|
-
/* @__PURE__ */ React.createElement(
|
|
356
|
+
/* @__PURE__ */ React.createElement(CommandList, { className: "overflow-visible" }, /* @__PURE__ */ React.createElement(CommandEmpty, null, notFoundContent), /* @__PURE__ */ React.createElement(
|
|
323
357
|
ComboboxOptionsList,
|
|
324
358
|
{
|
|
325
359
|
items: filteredOptions,
|
|
@@ -329,7 +363,7 @@ function Combobox({
|
|
|
329
363
|
itemsClassName,
|
|
330
364
|
size
|
|
331
365
|
}
|
|
332
|
-
)
|
|
366
|
+
))
|
|
333
367
|
))
|
|
334
368
|
));
|
|
335
369
|
}
|
|
@@ -69,6 +69,11 @@ const MultiSelect = React.forwardRef(
|
|
|
69
69
|
const handleTogglePopover = () => {
|
|
70
70
|
setIsPopoverOpen((prev) => !prev);
|
|
71
71
|
};
|
|
72
|
+
const clearExtraOptions = () => {
|
|
73
|
+
const newSelectedValues = selectedValues.slice(0, maxCount);
|
|
74
|
+
setSelectedValues(newSelectedValues);
|
|
75
|
+
onValueChange(newSelectedValues);
|
|
76
|
+
};
|
|
72
77
|
const toggleAll = () => {
|
|
73
78
|
if (treeOptions && treeOptions.length) {
|
|
74
79
|
const gather = (acc, nodes) => {
|
|
@@ -372,17 +377,8 @@ const MultiSelect = React.forwardRef(
|
|
|
372
377
|
"aria-expanded": isPopoverOpen
|
|
373
378
|
},
|
|
374
379
|
selectedValues.length > 0 ? /* @__PURE__ */ React.createElement("div", { className: "flex justify-between items-center w-full" }, /* @__PURE__ */ React.createElement("div", { className: "flex flex-wrap items-center gap-1" }, selectedValues.slice(0, maxCount).map((value2) => {
|
|
375
|
-
const
|
|
376
|
-
|
|
377
|
-
const prefix = selectedOption?.prefix;
|
|
378
|
-
return /* @__PURE__ */ React.createElement(Tag, { key: value2, color: "blue", className: "focus:ring-0 flex items-center gap-1" }, prefix && /* @__PURE__ */ React.createElement(
|
|
379
|
-
Typography,
|
|
380
|
-
{
|
|
381
|
-
className: "flex items-center flex-shrink-0 [&_svg]:text-blue-600",
|
|
382
|
-
textColor: "text-blue-600"
|
|
383
|
-
},
|
|
384
|
-
prefix
|
|
385
|
-
), /* @__PURE__ */ React.createElement(
|
|
380
|
+
const label = findTreeLabel(value2) || options.find((o) => o.value === value2)?.label || value2;
|
|
381
|
+
return /* @__PURE__ */ React.createElement(Tag, { key: value2, color: "blue", className: "focus:ring-0" }, /* @__PURE__ */ React.createElement(
|
|
386
382
|
Typography,
|
|
387
383
|
{
|
|
388
384
|
variant: "body-small-400",
|
|
@@ -399,7 +395,16 @@ const MultiSelect = React.forwardRef(
|
|
|
399
395
|
}
|
|
400
396
|
}
|
|
401
397
|
));
|
|
402
|
-
}), selectedValues.length > maxCount && /* @__PURE__ */ React.createElement(Tag, { color: "blue", className: "focus:ring-0" }, /* @__PURE__ */ React.createElement(Typography, { variant: "body-small-400", className: "text-blue-600" }, `+ ${selectedValues.length - maxCount}`)
|
|
398
|
+
}), selectedValues.length > maxCount && /* @__PURE__ */ React.createElement(Tag, { color: "blue", className: "focus:ring-0" }, /* @__PURE__ */ React.createElement(Typography, { variant: "body-small-400", className: "text-blue-600" }, `+ ${selectedValues.length - maxCount}`), /* @__PURE__ */ React.createElement(
|
|
399
|
+
X,
|
|
400
|
+
{
|
|
401
|
+
className: "h-4 w-4 cursor-pointer flex-shrink-0",
|
|
402
|
+
onClick: (event) => {
|
|
403
|
+
event.stopPropagation();
|
|
404
|
+
clearExtraOptions();
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
))), /* @__PURE__ */ React.createElement("div", { className: "flex items-center justify-between" }, /* @__PURE__ */ React.createElement(
|
|
403
408
|
X,
|
|
404
409
|
{
|
|
405
410
|
className: "h-4 mx-2 cursor-pointer text-grey-800",
|
|
@@ -485,7 +490,6 @@ const MultiSelect = React.forwardRef(
|
|
|
485
490
|
},
|
|
486
491
|
/* @__PURE__ */ React.createElement(Check, { className: "h-4 w-4" })
|
|
487
492
|
),
|
|
488
|
-
option.prefix && /* @__PURE__ */ React.createElement(Typography, { className: "flex items-center flex-shrink-0 mr-2" }, option.prefix),
|
|
489
493
|
/* @__PURE__ */ React.createElement(
|
|
490
494
|
"span",
|
|
491
495
|
{
|
|
@@ -518,7 +522,6 @@ const MultiSelect = React.forwardRef(
|
|
|
518
522
|
},
|
|
519
523
|
/* @__PURE__ */ React.createElement(Check, { className: "h-4 w-4" })
|
|
520
524
|
),
|
|
521
|
-
option.prefix && /* @__PURE__ */ React.createElement(Typography, { className: "flex items-center flex-shrink-0 mr-2" }, option.prefix),
|
|
522
525
|
/* @__PURE__ */ React.createElement(
|
|
523
526
|
"span",
|
|
524
527
|
{
|
|
@@ -9,22 +9,28 @@ const NumberControl = ({
|
|
|
9
9
|
label,
|
|
10
10
|
value,
|
|
11
11
|
onChange,
|
|
12
|
-
placeholder
|
|
12
|
+
placeholder,
|
|
13
13
|
required = false,
|
|
14
|
-
min
|
|
14
|
+
min,
|
|
15
|
+
max,
|
|
16
|
+
maxDigits,
|
|
15
17
|
className = "",
|
|
16
18
|
labelClassName = "",
|
|
17
19
|
info = false,
|
|
18
20
|
labelPosition = "top"
|
|
19
21
|
}) => {
|
|
22
|
+
const defaultPlaceholder = maxDigits ? "0".repeat(maxDigits) : "0";
|
|
23
|
+
const finalPlaceholder = placeholder ?? defaultPlaceholder;
|
|
20
24
|
const handleIncrement = () => {
|
|
21
|
-
const current = parseInt(value, 10) || 0;
|
|
22
|
-
|
|
23
|
-
|
|
25
|
+
const current = typeof value === "number" ? value : parseInt(value, 10) || 0;
|
|
26
|
+
if (max === void 0 || current < max) {
|
|
27
|
+
const newValue = (current + 1).toString();
|
|
28
|
+
onChange(newValue);
|
|
29
|
+
}
|
|
24
30
|
};
|
|
25
31
|
const handleDecrement = () => {
|
|
26
|
-
const current = parseInt(value, 10) || 0;
|
|
27
|
-
if (current > min) {
|
|
32
|
+
const current = typeof value === "number" ? value : parseInt(value, 10) || 0;
|
|
33
|
+
if (min === void 0 || current > min) {
|
|
28
34
|
const newValue = (current - 1).toString();
|
|
29
35
|
onChange(newValue);
|
|
30
36
|
}
|
|
@@ -35,8 +41,13 @@ const NumberControl = ({
|
|
|
35
41
|
onChange("");
|
|
36
42
|
return;
|
|
37
43
|
}
|
|
44
|
+
if (maxDigits && numbersOnly.length > maxDigits) {
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
38
47
|
const numValue = parseInt(numbersOnly, 10);
|
|
39
|
-
|
|
48
|
+
const isAboveMin = min === void 0 || numValue >= min;
|
|
49
|
+
const isBelowMax = max === void 0 || numValue <= max;
|
|
50
|
+
if (isAboveMin && isBelowMax) {
|
|
40
51
|
onChange(numbersOnly);
|
|
41
52
|
}
|
|
42
53
|
};
|
|
@@ -58,7 +69,7 @@ const NumberControl = ({
|
|
|
58
69
|
onChange: (e) => handleInputChange(e.target.value),
|
|
59
70
|
className: "text-center flex-1 px-10 w-full",
|
|
60
71
|
containerClassName: "w-full",
|
|
61
|
-
placeholder,
|
|
72
|
+
placeholder: finalPlaceholder,
|
|
62
73
|
prefixInset: /* @__PURE__ */ React__default.createElement(
|
|
63
74
|
Minus,
|
|
64
75
|
{
|
package/dist/index.d.ts
CHANGED
|
@@ -756,9 +756,9 @@ interface HeaderProps extends React$1.HTMLAttributes<HTMLElement>, VariantProps<
|
|
|
756
756
|
}
|
|
757
757
|
|
|
758
758
|
declare const inputVariants: (props?: ({
|
|
759
|
-
variant?: "
|
|
760
|
-
size?: "small" | "
|
|
761
|
-
radius?: "small" | "
|
|
759
|
+
variant?: "default" | "filled" | "borderless" | null | undefined;
|
|
760
|
+
size?: "small" | "default" | "large" | null | undefined;
|
|
761
|
+
radius?: "small" | "default" | "large" | "full" | null | undefined;
|
|
762
762
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
763
763
|
interface InputProps extends Omit<React$1.InputHTMLAttributes<HTMLInputElement>, 'size' | 'sufix' | 'prefix'>, VariantProps<typeof inputVariants> {
|
|
764
764
|
sufix?: React$1.ReactNode;
|
|
@@ -803,7 +803,6 @@ interface MultiSelectProps extends React$1.ButtonHTMLAttributes<HTMLButtonElemen
|
|
|
803
803
|
options?: {
|
|
804
804
|
label: string;
|
|
805
805
|
value: string;
|
|
806
|
-
prefix?: React$1.ReactNode;
|
|
807
806
|
}[];
|
|
808
807
|
onValueChange: (value: string[]) => void;
|
|
809
808
|
value?: string[];
|
|
@@ -823,7 +822,6 @@ interface MultiSelectProps extends React$1.ButtonHTMLAttributes<HTMLButtonElemen
|
|
|
823
822
|
filterFn?: (query: string, option: {
|
|
824
823
|
label: string;
|
|
825
824
|
value: string;
|
|
826
|
-
prefix?: React$1.ReactNode;
|
|
827
825
|
}) => number | false;
|
|
828
826
|
searchStrategy?: 'simple' | 'ranked';
|
|
829
827
|
highlightMatches?: boolean;
|
|
@@ -833,16 +831,10 @@ interface MultiSelectProps extends React$1.ButtonHTMLAttributes<HTMLButtonElemen
|
|
|
833
831
|
[categoryName: string]: {
|
|
834
832
|
label: string;
|
|
835
833
|
value: string;
|
|
836
|
-
prefix?: React$1.ReactNode;
|
|
837
834
|
}[];
|
|
838
835
|
};
|
|
839
836
|
classNameContent?: string;
|
|
840
837
|
}
|
|
841
|
-
interface MultiSelectOption {
|
|
842
|
-
label: string;
|
|
843
|
-
value: string;
|
|
844
|
-
prefix?: React$1.ReactNode;
|
|
845
|
-
}
|
|
846
838
|
interface MultiSelectTreeOption {
|
|
847
839
|
label: string;
|
|
848
840
|
value: string;
|
|
@@ -947,17 +939,19 @@ declare function useNotificationToast(): {
|
|
|
947
939
|
|
|
948
940
|
interface NumberControlProps {
|
|
949
941
|
label: string;
|
|
950
|
-
value: string;
|
|
942
|
+
value: string | number;
|
|
951
943
|
onChange: (value: string) => void;
|
|
952
944
|
placeholder?: string;
|
|
953
945
|
required?: boolean;
|
|
954
946
|
min?: number;
|
|
947
|
+
max?: number;
|
|
948
|
+
maxDigits?: number;
|
|
955
949
|
className?: string;
|
|
956
950
|
labelClassName?: string;
|
|
957
951
|
info?: boolean;
|
|
958
952
|
labelPosition?: 'top' | 'bottom';
|
|
959
953
|
}
|
|
960
|
-
declare const NumberControl: ({ label, value, onChange, placeholder, required, min, className, labelClassName, info, labelPosition, }: NumberControlProps) => React__default.JSX.Element;
|
|
954
|
+
declare const NumberControl: ({ label, value, onChange, placeholder, required, min, max, maxDigits, className, labelClassName, info, labelPosition, }: NumberControlProps) => React__default.JSX.Element;
|
|
961
955
|
|
|
962
956
|
declare const Popover: React$1.FC<PopoverPrimitive.PopoverProps>;
|
|
963
957
|
declare const PopoverTrigger: React$1.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React$1.RefAttributes<HTMLButtonElement>>;
|
|
@@ -967,7 +961,7 @@ declare const RadioGroup: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimi
|
|
|
967
961
|
declare const RadioGroupItem: React$1.ForwardRefExoticComponent<Omit<RadioGroupPrimitive.RadioGroupItemProps & React$1.RefAttributes<HTMLButtonElement>, "ref"> & React$1.RefAttributes<HTMLButtonElement>>;
|
|
968
962
|
|
|
969
963
|
declare const ResizablePanelGroup: ({ className, ...props }: React$1.ComponentProps<typeof ResizablePrimitive.PanelGroup>) => React$1.JSX.Element;
|
|
970
|
-
declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<
|
|
964
|
+
declare const ResizablePanel: React$1.ForwardRefExoticComponent<Omit<React$1.HTMLAttributes<HTMLElement | HTMLOListElement | HTMLLIElement | HTMLAnchorElement | HTMLSpanElement | HTMLDivElement | HTMLButtonElement | HTMLHeadingElement | HTMLParagraphElement | HTMLLabelElement | HTMLInputElement | HTMLUListElement | HTMLObjectElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableCaptionElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDialogElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLFormElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLImageElement | HTMLLegendElement | HTMLLinkElement | HTMLMapElement | HTMLMenuElement | HTMLMetaElement | HTMLMeterElement | HTMLOptGroupElement | HTMLOptionElement | HTMLOutputElement | HTMLPictureElement | HTMLPreElement | HTMLProgressElement | HTMLScriptElement | HTMLSelectElement | HTMLSlotElement | HTMLSourceElement | HTMLStyleElement | HTMLTableElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTemplateElement | HTMLTextAreaElement | HTMLTimeElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLVideoElement>, "id" | "onResize"> & {
|
|
971
965
|
className?: string;
|
|
972
966
|
collapsedSize?: number | undefined;
|
|
973
967
|
collapsible?: boolean | undefined;
|
|
@@ -1132,10 +1126,10 @@ declare const TabsTrigger: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.
|
|
|
1132
1126
|
declare const TabsContent: React$1.ForwardRefExoticComponent<Omit<TabsPrimitive.TabsContentProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1133
1127
|
|
|
1134
1128
|
declare const textareaVariants: (props?: ({
|
|
1135
|
-
variant?: "
|
|
1136
|
-
size?: "small" | "
|
|
1137
|
-
radius?: "small" | "
|
|
1138
|
-
resize?: "
|
|
1129
|
+
variant?: "default" | "filled" | "borderless" | null | undefined;
|
|
1130
|
+
size?: "small" | "default" | "large" | null | undefined;
|
|
1131
|
+
radius?: "small" | "default" | "large" | "full" | null | undefined;
|
|
1132
|
+
resize?: "default" | "both" | "horizontal" | "vertical" | "vertical-limited" | null | undefined;
|
|
1139
1133
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
1140
1134
|
interface TextareaProps extends React$1.ComponentProps<'textarea'>, VariantProps<typeof textareaVariants> {
|
|
1141
1135
|
}
|
|
@@ -1272,7 +1266,7 @@ declare const SheetClose: React$1.ForwardRefExoticComponent<DialogPrimitive.Dial
|
|
|
1272
1266
|
declare const SheetPortal: React$1.FC<DialogPrimitive.DialogPortalProps>;
|
|
1273
1267
|
declare const SheetOverlay: React$1.ForwardRefExoticComponent<Omit<DialogPrimitive.DialogOverlayProps & React$1.RefAttributes<HTMLDivElement>, "ref"> & React$1.RefAttributes<HTMLDivElement>>;
|
|
1274
1268
|
declare const sheetVariants: (props?: ({
|
|
1275
|
-
side?: "
|
|
1269
|
+
side?: "left" | "right" | "top" | "bottom" | null | undefined;
|
|
1276
1270
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
1277
1271
|
interface SheetContentProps extends React$1.ComponentPropsWithoutRef<typeof DialogPrimitive.Content>, VariantProps<typeof sheetVariants> {
|
|
1278
1272
|
}
|
|
@@ -1295,4 +1289,4 @@ interface DateInputProps extends Omit<React$1.InputHTMLAttributes<HTMLInputEleme
|
|
|
1295
1289
|
declare const DateInput: React$1.ForwardRefExoticComponent<DateInputProps & React$1.RefAttributes<HTMLInputElement>>;
|
|
1296
1290
|
|
|
1297
1291
|
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, CadastroFacil, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, ColorPicker, Combobox, CustomDivider, MemoizedDataTable as DataTable, DateInput, DatePicker, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogScroll, DialogTitle, DialogTrigger, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, ErrorEmptyDisplay, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Input, Layout, LogoLecom, LogoLecomBrand, ModoTeste, MultiSelect, Notification, NumberControl, Pagination, PaginationContent, PaginationEllipsis, PaginationFirst, PaginationIndex, PaginationItem, PaginationLast, PaginationNext, PaginationPrevious, Popover, PopoverContent, PopoverTrigger, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, Rpa, SairModoTeste, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, Spin, Steps, Switch, SyntaxHighlighter, TOAST_REMOVE_DELAY, Tabs, TabsContent, TabsList, TabsTrigger, Tag, TagInput, Textarea, ToggleGroup, ToggleGroupItem, Tooltip, TooltipArrow, TooltipContent, TooltipPortal, TooltipProvider, TooltipTrigger, Translations, TypeMessageNotification, Typography, Upload, accordionVariants, buttonVariants, colors, fonts, initializeI18n, inputVariants, notificationVariants, reducer, tagVariants, textareaVariants, toast, typographyVariants, useFormField, useIsMobile, useNotificationToast, usePagination, useSidebar };
|
|
1298
|
-
export type { BgColor, BuildCellSelect, BuildColumns, BuildHeaderSelect, ButtonProps, CadastroFacilProps, CalloutNotificationProps, ChartConfig, CheckboxProps, CheckedCell, CheckedCellChange, CheckedHeader, CheckedHeaderChange, Color, ColorToken, Column, ColumnRender, ColumnSort, ColumnSortClient, ColumnTitle, ComboboxFont, ComboboxGroup, ComboboxOption, ComboboxProps, ComboboxRounded, ComboboxSize, ComboboxStatus, CustomStyles$1 as CustomStyles, DataTableProps, DateInputProps, DatePickerProps, DialogContentProps, ErrorEmptyDisplayProps, File, FillColor, Fonts, Header, HeaderProps, InlineNotificationProps, InputProps, LayoutProps, LogoLecomBrandProps, LogoLecomProps, Meta, ModoTesteProps,
|
|
1292
|
+
export type { BgColor, BuildCellSelect, BuildColumns, BuildHeaderSelect, ButtonProps, CadastroFacilProps, CalloutNotificationProps, ChartConfig, CheckboxProps, CheckedCell, CheckedCellChange, CheckedHeader, CheckedHeaderChange, Color, ColorToken, Column, ColumnRender, ColumnSort, ColumnSortClient, ColumnTitle, ComboboxFont, ComboboxGroup, ComboboxOption, ComboboxProps, ComboboxRounded, ComboboxSize, ComboboxStatus, CustomStyles$1 as CustomStyles, DataTableProps, DateInputProps, DatePickerProps, DialogContentProps, ErrorEmptyDisplayProps, File, FillColor, Fonts, Header, HeaderProps, InlineNotificationProps, InputProps, LayoutProps, LogoLecomBrandProps, LogoLecomProps, Meta, ModoTesteProps, MultiSelectTreeOption, NotificationProps, PaginationProps, Row, RpaProps, SideBarProps, SpinProps, StepsProps, SwitchProps, TableProps, TagInputProps, TagItem, TagProps, TextColor, TextareaProps, TimelineStepItem, ToastNotificationProps, ToasterToast, TooltipContentProps, TypographyProps, UploadProps, UsePaginationItem };
|