@reportportal/ui-kit 0.0.1-alpha.12 → 0.0.1-alpha.121
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 +28 -2
- package/dist/attachedFile.js +9 -0
- package/dist/autocompletes.js +729 -0
- package/dist/baseIconButton-251479f7.js +25 -0
- package/dist/baseIconButton.js +1 -1
- package/dist/breadcrumbs-8e5ca8d7.js +183 -0
- package/dist/breadcrumbs.js +12 -0
- package/dist/bubblesLoader-f3ffa240.js +28 -0
- package/dist/bubblesLoader.js +1 -1
- package/dist/button-97d9e587.js +66 -0
- package/dist/button.js +1 -1
- package/dist/calendarArrow-44c7e60e.js +5 -0
- package/dist/checkbox-ed6cc375.js +73 -0
- package/dist/checkbox.js +1 -1
- package/dist/chevronDownDropdown-66f5b1af.js +7 -0
- package/dist/clear-53660571.js +5 -0
- package/dist/close-4d480ef7.js +5 -0
- package/dist/common/constants/floatingUi.d.ts +8 -0
- package/dist/common/hooks/useOnClickOutside.d.ts +1 -0
- package/dist/common/types.d.ts +4 -0
- package/dist/common/utils/floatingUi.d.ts +3 -0
- package/dist/common/utils/getFileExtension.d.ts +1 -0
- package/dist/common/utils/index.d.ts +3 -0
- package/dist/common/utils/isString.d.ts +1 -0
- package/dist/components/attachedFile/attachedFile.d.ts +14 -0
- package/dist/components/attachedFile/index.d.ts +2 -0
- package/dist/components/autocompletes/common/autocompleteMenu/autocompleteMenu.d.ts +10 -0
- package/dist/components/autocompletes/common/autocompleteMenu/index.d.ts +1 -0
- package/dist/components/autocompletes/common/autocompleteOption/autocompleteOption.d.ts +13 -0
- package/dist/components/autocompletes/common/autocompleteOption/index.d.ts +1 -0
- package/dist/components/autocompletes/common/autocompleteOptions.d.ts +19 -0
- package/dist/components/autocompletes/common/autocompletePrompt/autocompletePrompt.d.ts +7 -0
- package/dist/components/autocompletes/common/autocompletePrompt/index.d.ts +1 -0
- package/dist/components/autocompletes/common/index.d.ts +19 -0
- package/dist/components/autocompletes/constants.d.ts +2 -0
- package/dist/components/autocompletes/index.d.ts +3 -0
- package/dist/components/autocompletes/multipleAutocomplete/index.d.ts +17 -0
- package/dist/components/autocompletes/multipleAutocomplete/multipleAutocomplete.d.ts +49 -0
- package/dist/components/autocompletes/multipleAutocomplete/multipleDownshift.d.ts +25 -0
- package/dist/components/autocompletes/multipleAutocomplete/selectedItems/index.d.ts +1 -0
- package/dist/components/autocompletes/multipleAutocomplete/selectedItems/selectedItems.d.ts +35 -0
- package/dist/components/autocompletes/singleAutocomplete/index.d.ts +1 -0
- package/dist/components/autocompletes/singleAutocomplete/singleAutocomplete.d.ts +42 -0
- package/dist/components/autocompletes/types.d.ts +8 -0
- package/dist/components/autocompletes/utils.d.ts +5 -0
- package/dist/components/{icons/baseIconButton → baseIconButton}/baseIconButton.d.ts +1 -0
- package/dist/components/{icons/baseIconButton → baseIconButton}/index.d.ts +1 -0
- package/dist/components/breadcrumbs/breadcrumb/breadcrumb.d.ts +10 -0
- package/dist/components/breadcrumbs/breadcrumb/index.d.ts +1 -0
- package/dist/components/breadcrumbs/breadcrumbs.d.ts +3 -0
- package/dist/components/breadcrumbs/breadcrumbsProvider/breadcrumbsProvider.d.ts +13 -0
- package/dist/components/breadcrumbs/breadcrumbsProvider/hooks.d.ts +3 -0
- package/dist/components/breadcrumbs/breadcrumbsProvider/index.d.ts +1 -0
- package/dist/components/breadcrumbs/hiddenBreadcrumbs/hiddenBreadcrumbs.d.ts +6 -0
- package/dist/components/breadcrumbs/hiddenBreadcrumbs/index.d.ts +2 -0
- package/dist/components/breadcrumbs/index.d.ts +5 -0
- package/dist/components/breadcrumbs/tree/index.d.ts +1 -0
- package/dist/components/breadcrumbs/tree/tree.d.ts +7 -0
- package/dist/components/breadcrumbs/types.d.ts +24 -0
- package/dist/components/bubblesLoader/bubblesLoader.d.ts +2 -0
- package/dist/components/bubblesLoader/index.d.ts +1 -0
- package/dist/components/button/button.d.ts +5 -4
- package/dist/components/button/index.d.ts +1 -0
- package/dist/components/checkbox/checkbox.d.ts +2 -1
- package/dist/components/checkbox/index.d.ts +1 -0
- package/dist/components/datePicker/datePicker.d.ts +25 -0
- package/dist/components/datePicker/header/datePickerHeader.d.ts +16 -0
- package/dist/components/datePicker/header/index.d.ts +4 -0
- package/dist/components/datePicker/index.d.ts +5 -0
- package/dist/components/datePicker/utils.d.ts +4 -0
- package/dist/components/dropdown/constants.d.ts +2 -0
- package/dist/components/dropdown/dropdown.d.ts +25 -4
- package/dist/components/dropdown/dropdownOption/dropdownOption.d.ts +1 -0
- package/dist/components/dropdown/dropdownOption/index.d.ts +1 -0
- package/dist/components/dropdown/index.d.ts +1 -0
- package/dist/components/dropdown/types.d.ts +11 -0
- package/dist/components/dropdown/utils.d.ts +6 -2
- package/dist/components/fieldLabel/fieldLabel.d.ts +7 -0
- package/dist/components/fieldLabel/index.d.ts +1 -0
- package/dist/components/fieldNumber/constants.d.ts +1 -0
- package/dist/components/fieldNumber/fieldNumber.d.ts +3 -3
- package/dist/components/fieldNumber/index.d.ts +1 -0
- package/dist/components/fieldText/fieldText.d.ts +12 -4
- package/dist/components/fieldText/index.d.ts +1 -0
- package/dist/components/fieldTextFlex/fieldTextFlex.d.ts +5 -2
- package/dist/components/fieldTextFlex/index.d.ts +1 -0
- package/dist/components/fileDropArea/attachedFilesList/attachedFilesList.d.ts +21 -0
- package/dist/components/fileDropArea/attachedFilesList/index.d.ts +5 -0
- package/dist/components/fileDropArea/browseButton/browseButton.d.ts +9 -0
- package/dist/components/fileDropArea/browseButton/index.d.ts +4 -0
- package/dist/components/fileDropArea/constants.d.ts +2 -0
- package/dist/components/fileDropArea/dropZone/dropZone.d.ts +10 -0
- package/dist/components/fileDropArea/dropZone/index.d.ts +4 -0
- package/dist/components/fileDropArea/errorMessage/errorMessage.d.ts +5 -0
- package/dist/components/fileDropArea/errorMessage/index.d.ts +4 -0
- package/dist/components/fileDropArea/fileDropArea.d.ts +19 -0
- package/dist/components/fileDropArea/fileDropAreaProvider/fileDropAreaProvider.d.ts +17 -0
- package/dist/components/fileDropArea/fileDropAreaProvider/index.d.ts +1 -0
- package/dist/components/fileDropArea/fileDropAreaProvider/useFileDropAreaContext.d.ts +3 -0
- package/dist/components/fileDropArea/hooks/index.d.ts +1 -0
- package/dist/components/fileDropArea/hooks/useFileDropArea.d.ts +13 -0
- package/dist/components/fileDropArea/hooks/useFileProcessing.d.ts +13 -0
- package/dist/components/fileDropArea/hooks/useOverlayDropArea.d.ts +22 -0
- package/dist/components/fileDropArea/index.d.ts +6 -0
- package/dist/components/fileDropArea/types.d.ts +58 -0
- package/dist/components/fileDropArea/utils/getValidationErrorMessage.d.ts +3 -0
- package/dist/components/fileDropArea/utils/index.d.ts +2 -0
- package/dist/components/fileDropArea/utils/validateFile.d.ts +3 -0
- package/dist/components/icons/index.d.ts +63 -7
- package/dist/components/index.d.ts +21 -9
- package/dist/components/maxValueDisplay/index.d.ts +4 -0
- package/dist/components/maxValueDisplay/maxValueDisplay.d.ts +8 -0
- package/dist/components/maxValueDisplay/utils/index.d.ts +1 -0
- package/dist/components/maxValueDisplay/utils/isPositiveInteger.d.ts +1 -0
- package/dist/components/modal/index.d.ts +1 -0
- package/dist/components/modal/modal.d.ts +7 -3
- package/dist/components/modal/modalContent/modalContent.d.ts +2 -0
- package/dist/components/modal/modalFooter/modalFooter.d.ts +3 -1
- package/dist/components/modal/modalHeader/modalHeader.d.ts +2 -1
- package/dist/components/modal/types.d.ts +6 -0
- package/dist/components/pagination/index.d.ts +1 -0
- package/dist/components/pagination/itemsCounter/itemCounter.d.ts +1 -0
- package/dist/components/pagination/pageControls/activePage/activePage.d.ts +1 -0
- package/dist/components/pagination/pageControls/activePage/pageSelector/pageSelector.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageControls.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageNavigator/bar/bar.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageNavigator/pageNavigator.d.ts +1 -0
- package/dist/components/pagination/pageSizeControl/pageSizeControl.d.ts +1 -0
- package/dist/components/pagination/pageSizeControl/sizeSelector/sizeSelector.d.ts +1 -0
- package/dist/components/pagination/pagination.d.ts +1 -0
- package/dist/components/popover/index.d.ts +4 -1
- package/dist/components/popover/popover.d.ts +3 -2
- package/dist/components/radio/index.d.ts +1 -0
- package/dist/components/radio/radio.d.ts +1 -0
- package/dist/components/radio/radioGroup.d.ts +1 -0
- package/dist/components/selection/index.d.ts +5 -0
- package/dist/components/selection/selection.d.ts +12 -0
- package/dist/components/selection/types.d.ts +1 -0
- package/dist/components/sidePanel/index.d.ts +2 -0
- package/dist/components/sidePanel/sidePanel.d.ts +17 -0
- package/dist/components/spinLoader/index.d.ts +4 -0
- package/dist/components/spinLoader/spinLoader.d.ts +8 -0
- package/dist/components/systemAlert/index.d.ts +1 -0
- package/dist/components/systemAlert/systemAlert.d.ts +4 -0
- package/dist/components/systemAlert/types.d.ts +22 -0
- package/dist/components/systemMessage/index.d.ts +1 -0
- package/dist/components/systemMessage/systemMessage.d.ts +1 -0
- package/dist/components/table/constants.d.ts +5 -0
- package/dist/components/table/hooks/index.d.ts +4 -0
- package/dist/components/table/hooks/useColumnWidths.d.ts +8 -0
- package/dist/components/table/hooks/useTableColumns.d.ts +13 -0
- package/dist/components/table/hooks/useTableExpansion.d.ts +15 -0
- package/dist/components/table/hooks/useTableHover.d.ts +10 -0
- package/dist/components/table/index.d.ts +2 -0
- package/dist/components/table/table.d.ts +1 -0
- package/dist/components/table/types.d.ts +25 -9
- package/dist/components/table/utils.d.ts +10 -1
- package/dist/components/themeProvider/index.d.ts +1 -0
- package/dist/components/themeProvider/themeProvider.d.ts +1 -0
- package/dist/components/toggle/index.d.ts +1 -0
- package/dist/components/toggle/toggle.d.ts +1 -0
- package/dist/components/tooltip/tooltip.d.ts +12 -2
- package/dist/datePicker-fcff097b.js +194 -0
- package/dist/datePicker.js +32 -0
- package/dist/dropdown-0260bb66.js +5 -0
- package/dist/dropdown-e85dd323.js +436 -0
- package/dist/dropdown.js +10 -2
- package/dist/fieldLabel.js +18 -0
- package/dist/fieldNumber-d1b5a7a1.js +140 -0
- package/dist/fieldNumber.js +5 -2
- package/dist/fieldText-2c4790e1.js +167 -0
- package/dist/fieldText.js +7 -2
- package/dist/fieldTextFlex-2f51c173.js +80 -0
- package/dist/fieldTextFlex.js +3 -1
- package/dist/fileDropArea.js +325 -0
- package/dist/floatingUi-41f8c7b5.js +29 -0
- package/dist/fonts/OpenSans/OpenSans-Bold.ttf +0 -0
- package/dist/fonts/OpenSans/OpenSans-Medium.ttf +0 -0
- package/dist/icons.js +84 -0
- package/dist/index-1a874a8b.js +110 -0
- package/dist/index.js +147 -50
- package/dist/isEmpty-ccacb5ff.js +38 -0
- package/dist/maxValueDisplay-9be01a75.js +13 -0
- package/dist/maxValueDisplay.js +6 -0
- package/dist/minus-2857540f.js +5 -0
- package/dist/modal.js +154 -14
- package/dist/openEye-950159cb.js +6 -0
- package/dist/pagination-5cc0ebdd.js +347 -0
- package/dist/pagination.js +12 -5
- package/dist/plus-199fb2a8.js +5 -0
- package/dist/popover.js +58 -73
- package/dist/prevPage-87faf576.js +6 -0
- package/dist/radio-62546efa.js +76 -0
- package/dist/radio.js +1 -1
- package/dist/selection-9124d029.js +38 -0
- package/dist/selection.js +10 -0
- package/dist/sidePanel.js +74 -0
- package/dist/spinLoader-c4a53718.js +11 -0
- package/dist/spinLoader.js +7 -0
- package/dist/style.css +1 -1
- package/dist/success-8fd8bd2c.js +7 -0
- package/dist/systemAlert.js +69 -0
- package/dist/systemMessage-924fdaa6.js +30 -0
- package/dist/systemMessage.js +1 -1
- package/dist/table-8e223d5d.js +485 -0
- package/dist/table.js +3 -3
- package/dist/toggle-304107fa.js +59 -0
- package/dist/toggle.js +1 -1
- package/dist/tooltip.js +89 -56
- package/dist/tree-c3dd3d45.js +6 -0
- package/dist/xls-995781cc.js +11 -0
- package/package.json +47 -16
- package/dist/baseIconButton-7bc53dec.js +0 -25
- package/dist/bubblesLoader-a7e709d4.js +0 -17
- package/dist/button-7fb84fde.js +0 -62
- package/dist/checkbox-6777be17.js +0 -73
- package/dist/dropdown-e07f2a71.js +0 -212
- package/dist/fieldNumber-46fe79b9.js +0 -127
- package/dist/fieldText-d80b29ba.js +0 -102
- package/dist/fieldTextFlex-5bddf46a.js +0 -67
- package/dist/index-bb9b62ef.js +0 -131
- package/dist/pagination-5449cd03.js +0 -346
- package/dist/radio-fd49a09c.js +0 -76
- package/dist/systemMessage-1ced6079.js +0 -30
- package/dist/table-231fd19c.js +0 -138
- package/dist/toggle-707ecb74.js +0 -67
|
@@ -0,0 +1,729 @@
|
|
|
1
|
+
import { jsx as s, jsxs as M, Fragment as ee } from "react/jsx-runtime";
|
|
2
|
+
import { useState as de, useCallback as Y, forwardRef as xe, useRef as Ee, useEffect as Ie } from "react";
|
|
3
|
+
import { c as H } from "./bind-06a7ff84.js";
|
|
4
|
+
import { Scrollbars as Se } from "rc-scrollbars";
|
|
5
|
+
import { B as Be } from "./bubblesLoader-f3ffa240.js";
|
|
6
|
+
import { B as Fe } from "./button-97d9e587.js";
|
|
7
|
+
import { S as Me } from "./plus-199fb2a8.js";
|
|
8
|
+
import { i as qe } from "./isEmpty-ccacb5ff.js";
|
|
9
|
+
import U from "downshift";
|
|
10
|
+
import { useFloating as he, autoUpdate as be } from "@floating-ui/react";
|
|
11
|
+
import { F as Ae } from "./fieldText-2c4790e1.js";
|
|
12
|
+
import { S as ve } from "./dropdown-0260bb66.js";
|
|
13
|
+
import { S as $e } from "./close-4d480ef7.js";
|
|
14
|
+
import { S as De } from "./clear-53660571.js";
|
|
15
|
+
import "./openEye-950159cb.js";
|
|
16
|
+
import "./baseIconButton-251479f7.js";
|
|
17
|
+
import "./spinLoader-c4a53718.js";
|
|
18
|
+
import "./maxValueDisplay-9be01a75.js";
|
|
19
|
+
import "./fieldLabel.js";
|
|
20
|
+
const Ce = "_disabled_18ek6_43", Re = "_input_18ek6_97", Oe = {
|
|
21
|
+
"selected-item": "_selected-item_18ek6_16",
|
|
22
|
+
"validation-error": "_validation-error_18ek6_35",
|
|
23
|
+
"highlight-un-stored-item": "_highlight-un-stored-item_18ek6_40",
|
|
24
|
+
disabled: Ce,
|
|
25
|
+
"mobile-disabled": "_mobile-disabled_18ek6_48",
|
|
26
|
+
"cross-icon": "_cross-icon_18ek6_54",
|
|
27
|
+
input: Re
|
|
28
|
+
}, ae = H.bind(Oe), je = ({
|
|
29
|
+
item: o,
|
|
30
|
+
onRemoveItem: e,
|
|
31
|
+
disabled: a = !1,
|
|
32
|
+
mobileDisabled: r = !1,
|
|
33
|
+
parseValueToString: n,
|
|
34
|
+
error: i = !1,
|
|
35
|
+
editItem: p,
|
|
36
|
+
editable: u = !1,
|
|
37
|
+
getAdditionalCreationCondition: g = () => !0,
|
|
38
|
+
storedOption: N = !0,
|
|
39
|
+
highlightUnStoredItem: b = !1,
|
|
40
|
+
variant: E = "light",
|
|
41
|
+
getItemName: w
|
|
42
|
+
}) => {
|
|
43
|
+
const [f, I] = de(!1), [k, _] = de(""), y = () => {
|
|
44
|
+
!a && u && !N && (_((w == null ? void 0 : w(o)) || (n == null ? void 0 : n(o)) || ""), I(!0));
|
|
45
|
+
}, B = (t) => {
|
|
46
|
+
_(t.target.value);
|
|
47
|
+
}, $ = (t) => {
|
|
48
|
+
const l = g(k);
|
|
49
|
+
t.key === "Enter" && l && (p(o, k), I(!1), _(""));
|
|
50
|
+
}, c = () => {
|
|
51
|
+
I(!1), _("");
|
|
52
|
+
}, d = (t) => {
|
|
53
|
+
t.stopPropagation(), e(o);
|
|
54
|
+
};
|
|
55
|
+
return f ? /* @__PURE__ */ s(
|
|
56
|
+
"input",
|
|
57
|
+
{
|
|
58
|
+
autoFocus: !0,
|
|
59
|
+
value: k,
|
|
60
|
+
onChange: B,
|
|
61
|
+
onKeyDown: $,
|
|
62
|
+
onBlur: c,
|
|
63
|
+
className: ae("input")
|
|
64
|
+
}
|
|
65
|
+
) : /* @__PURE__ */ M(
|
|
66
|
+
"div",
|
|
67
|
+
{
|
|
68
|
+
className: ae("selected-item", E, {
|
|
69
|
+
[`validation-${i}`]: i,
|
|
70
|
+
disabled: a,
|
|
71
|
+
"mobile-disabled": r,
|
|
72
|
+
"highlight-un-stored-item": b && !N
|
|
73
|
+
}),
|
|
74
|
+
onClick: y,
|
|
75
|
+
children: [
|
|
76
|
+
n == null ? void 0 : n(o),
|
|
77
|
+
!a && /* @__PURE__ */ s(
|
|
78
|
+
"button",
|
|
79
|
+
{
|
|
80
|
+
type: "button",
|
|
81
|
+
className: ae("cross-icon", {
|
|
82
|
+
[`validation-${i}`]: i,
|
|
83
|
+
"mobile-disabled": r,
|
|
84
|
+
disabled: a
|
|
85
|
+
}),
|
|
86
|
+
onClick: d,
|
|
87
|
+
children: /* @__PURE__ */ s($e, {})
|
|
88
|
+
}
|
|
89
|
+
)
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
);
|
|
93
|
+
}, He = ({
|
|
94
|
+
items: o = [],
|
|
95
|
+
parseValueToString: e,
|
|
96
|
+
getItemValidationErrorType: a,
|
|
97
|
+
storedItemsMap: r = {},
|
|
98
|
+
highlightUnStoredItem: n = !1,
|
|
99
|
+
renderCustomSelectedItem: i,
|
|
100
|
+
...p
|
|
101
|
+
}) => o.map((u) => i ? i(u) : /* @__PURE__ */ s(
|
|
102
|
+
je,
|
|
103
|
+
{
|
|
104
|
+
parseValueToString: e,
|
|
105
|
+
error: (a == null ? void 0 : a(u)) || "",
|
|
106
|
+
item: u,
|
|
107
|
+
storedOption: !!r[e(u)],
|
|
108
|
+
highlightUnStoredItem: n,
|
|
109
|
+
...p
|
|
110
|
+
},
|
|
111
|
+
e == null ? void 0 : e(u)
|
|
112
|
+
)), Le = "_prompt_1xfmd_16", Pe = {
|
|
113
|
+
prompt: Le
|
|
114
|
+
}, We = H.bind(Pe), ze = ({ children: o = null }) => /* @__PURE__ */ s("div", { className: We("prompt"), children: o }), Ke = "_item_1qhaq_16", Ye = "_divider_1qhaq_24", Xe = "_active_1qhaq_48", Ge = "_value_1qhaq_60", Je = "_tag_1qhaq_78", Qe = "_disabled_1qhaq_89", Te = {
|
|
115
|
+
item: Ke,
|
|
116
|
+
divider: Ye,
|
|
117
|
+
"new-item": "_new-item_1qhaq_31",
|
|
118
|
+
active: Xe,
|
|
119
|
+
value: Ge,
|
|
120
|
+
"key-variant": "_key-variant_1qhaq_75",
|
|
121
|
+
tag: Je,
|
|
122
|
+
"button-active": "_button-active_1qhaq_89",
|
|
123
|
+
disabled: Qe,
|
|
124
|
+
"value-variant": "_value-variant_1qhaq_109"
|
|
125
|
+
}, X = H.bind(Te), fe = ({
|
|
126
|
+
isActive: o = !1,
|
|
127
|
+
isSelected: e = !1,
|
|
128
|
+
isNew: a = !1,
|
|
129
|
+
children: r = null,
|
|
130
|
+
disabled: n = !1,
|
|
131
|
+
optionVariant: i = "",
|
|
132
|
+
newItemButtonText: p = "",
|
|
133
|
+
...u
|
|
134
|
+
}) => {
|
|
135
|
+
const g = () => p || (i === "key-variant" ? "New key" : "New value");
|
|
136
|
+
return a ? /* @__PURE__ */ M(ee, { children: [
|
|
137
|
+
/* @__PURE__ */ s("div", { className: X("divider") }),
|
|
138
|
+
/* @__PURE__ */ M(
|
|
139
|
+
"li",
|
|
140
|
+
{
|
|
141
|
+
className: X("new-item", i, {
|
|
142
|
+
active: o,
|
|
143
|
+
selected: e,
|
|
144
|
+
disabled: n
|
|
145
|
+
}),
|
|
146
|
+
...u,
|
|
147
|
+
children: [
|
|
148
|
+
/* @__PURE__ */ s("span", { className: X("value"), children: r }),
|
|
149
|
+
/* @__PURE__ */ s(
|
|
150
|
+
Fe,
|
|
151
|
+
{
|
|
152
|
+
...!n && u,
|
|
153
|
+
className: X({ "button-active": o }),
|
|
154
|
+
icon: /* @__PURE__ */ s(Me, {}),
|
|
155
|
+
variant: "text",
|
|
156
|
+
children: g()
|
|
157
|
+
}
|
|
158
|
+
)
|
|
159
|
+
]
|
|
160
|
+
}
|
|
161
|
+
)
|
|
162
|
+
] }) : /* @__PURE__ */ s(
|
|
163
|
+
"li",
|
|
164
|
+
{
|
|
165
|
+
className: X("item", i, {
|
|
166
|
+
active: o,
|
|
167
|
+
selected: e,
|
|
168
|
+
disabled: n
|
|
169
|
+
}),
|
|
170
|
+
...n ? {} : u,
|
|
171
|
+
children: /* @__PURE__ */ s("span", { className: X("label", "tag"), children: r })
|
|
172
|
+
}
|
|
173
|
+
);
|
|
174
|
+
}, Ze = "_container_igshu_16", Ue = {
|
|
175
|
+
container: Ze
|
|
176
|
+
}, ie = H.bind(Ue), Ve = (o) => {
|
|
177
|
+
const {
|
|
178
|
+
options: e,
|
|
179
|
+
async: a,
|
|
180
|
+
inputValue: r,
|
|
181
|
+
loading: n,
|
|
182
|
+
createWithoutConfirmation: i,
|
|
183
|
+
customEmptyListMessage: p,
|
|
184
|
+
customNoMatchesMessage: u,
|
|
185
|
+
optionVariant: g,
|
|
186
|
+
newItemButtonText: N,
|
|
187
|
+
renderOption: b,
|
|
188
|
+
getUniqKey: E,
|
|
189
|
+
getItemProps: w,
|
|
190
|
+
parseValueToString: f
|
|
191
|
+
} = o, I = Y(() => (e || []).filter((t) => f(t).toUpperCase().indexOf((r.toUpperCase() || "").trim()) > -1), [r, e, f]), k = Y(
|
|
192
|
+
(t, l, h = !1) => b ? b(t, l, h, w) : /* @__PURE__ */ s(
|
|
193
|
+
fe,
|
|
194
|
+
{
|
|
195
|
+
optionVariant: g,
|
|
196
|
+
...w({ item: t, index: l }),
|
|
197
|
+
isNew: h,
|
|
198
|
+
newItemButtonText: N,
|
|
199
|
+
children: f(t)
|
|
200
|
+
},
|
|
201
|
+
(E == null ? void 0 : E(t)) || f(t)
|
|
202
|
+
),
|
|
203
|
+
[w, E, N, g, f, b]
|
|
204
|
+
), _ = Y(
|
|
205
|
+
(t) => t.length ? t.map((l, h) => k(l, h)) : "",
|
|
206
|
+
[k]
|
|
207
|
+
), y = Y(
|
|
208
|
+
(t) => {
|
|
209
|
+
const l = t.length;
|
|
210
|
+
return /* @__PURE__ */ s("div", { className: ie({ container: !l }), children: /* @__PURE__ */ s(
|
|
211
|
+
fe,
|
|
212
|
+
{
|
|
213
|
+
optionVariant: g,
|
|
214
|
+
isNew: !0,
|
|
215
|
+
...w({ item: r, index: l }),
|
|
216
|
+
children: f(r)
|
|
217
|
+
},
|
|
218
|
+
f(r)
|
|
219
|
+
) });
|
|
220
|
+
},
|
|
221
|
+
[w, r, g, f]
|
|
222
|
+
), B = Y(
|
|
223
|
+
(t) => n ? /* @__PURE__ */ M(ee, { children: [
|
|
224
|
+
/* @__PURE__ */ s(ze, { children: /* @__PURE__ */ s(Be, {}) }),
|
|
225
|
+
!i && y(t)
|
|
226
|
+
] }) : "",
|
|
227
|
+
[i, n, y]
|
|
228
|
+
), $ = Y(() => {
|
|
229
|
+
const t = (e == null ? void 0 : e.length) === 0 ? p || "No available options" : u || "No matches found";
|
|
230
|
+
return /* @__PURE__ */ s("div", { className: ie("empty-list-message"), children: t });
|
|
231
|
+
}, [p, u, e == null ? void 0 : e.length]), c = a ? e : I(), d = B(e);
|
|
232
|
+
return d || /* @__PURE__ */ M("div", { className: ie({ container: e.length }), children: [
|
|
233
|
+
/* @__PURE__ */ s(Se, { autoHeight: !0, autoHeightMax: 216, hideTracksWhenNotNeeded: !0, children: qe(c) ? $() : _(c) }),
|
|
234
|
+
!i && y(c)
|
|
235
|
+
] });
|
|
236
|
+
}, et = "_menu_1bgrz_16", tt = "_opened_1bgrz_35", ot = "_dark_1bgrz_38", nt = {
|
|
237
|
+
menu: et,
|
|
238
|
+
opened: tt,
|
|
239
|
+
dark: ot
|
|
240
|
+
}, st = H.bind(nt), rt = (o, e) => !o || o <= e.trim().length, ge = xe(
|
|
241
|
+
({
|
|
242
|
+
isOpen: o = !1,
|
|
243
|
+
style: e = {},
|
|
244
|
+
minLength: a = 1,
|
|
245
|
+
isDropdownMode: r,
|
|
246
|
+
inputValue: n = "",
|
|
247
|
+
className: i = "",
|
|
248
|
+
...p
|
|
249
|
+
}, u) => /* @__PURE__ */ s(
|
|
250
|
+
"ul",
|
|
251
|
+
{
|
|
252
|
+
ref: u,
|
|
253
|
+
className: st(
|
|
254
|
+
"menu",
|
|
255
|
+
{ opened: o && (r || rt(a, n)) },
|
|
256
|
+
i
|
|
257
|
+
),
|
|
258
|
+
style: e,
|
|
259
|
+
children: /* @__PURE__ */ s(Ve, { inputValue: n, ...p })
|
|
260
|
+
}
|
|
261
|
+
)
|
|
262
|
+
), _e = (o, e) => typeof o == "string" ? o : e ? String(o[e(o)]) : "", V = (o, e) => {
|
|
263
|
+
var r;
|
|
264
|
+
return o === e ? !0 : !!(o && e && typeof o == "object" && typeof e == "object" && Object.keys(o).length === Object.keys(e).length && ((r = Object.entries(o)) != null && r.every(([n, i]) => V(i, e[n]))));
|
|
265
|
+
}, ct = (o, e, a) => typeof o == "string" ? o === e : a ? (() => {
|
|
266
|
+
const r = a(o);
|
|
267
|
+
return o[r] === e[r];
|
|
268
|
+
})() : !1, lt = ({
|
|
269
|
+
options: o = [],
|
|
270
|
+
onChange: e,
|
|
271
|
+
selectedItems: a = [],
|
|
272
|
+
handleUnStoredItemCb: r = null,
|
|
273
|
+
existingItemsMap: n = {},
|
|
274
|
+
children: i,
|
|
275
|
+
customizeNewSelectedValue: p = (b) => b,
|
|
276
|
+
getOptionUniqKey: u,
|
|
277
|
+
getOptionUniqKeyValue: g,
|
|
278
|
+
...N
|
|
279
|
+
}) => {
|
|
280
|
+
const [b, E] = de(n), w = (c, d) => {
|
|
281
|
+
const t = {
|
|
282
|
+
...b
|
|
283
|
+
};
|
|
284
|
+
c.forEach((l) => {
|
|
285
|
+
if (o.find((h) => ct(h, l, u))) {
|
|
286
|
+
const h = _e(l, u);
|
|
287
|
+
t[h] = !0;
|
|
288
|
+
}
|
|
289
|
+
}), E(t), d(t);
|
|
290
|
+
}, f = (c, d) => {
|
|
291
|
+
const t = _e(c, u);
|
|
292
|
+
if (t in b) {
|
|
293
|
+
const l = { ...b };
|
|
294
|
+
delete l[t], E(l), d(l);
|
|
295
|
+
} else
|
|
296
|
+
d(b);
|
|
297
|
+
}, I = (c, d) => {
|
|
298
|
+
const t = p(c), l = Array.isArray(t) ? t : [t], L = [...a.filter((C) => l.indexOf(C) < 0), ...l];
|
|
299
|
+
e == null || e(L, d), w(l, (C) => r == null ? void 0 : r(L, C));
|
|
300
|
+
}, k = (c, d) => {
|
|
301
|
+
const t = a.indexOf(c), l = [...a];
|
|
302
|
+
l.splice(t, 1, d), e == null || e(l, null);
|
|
303
|
+
}, _ = (c, d) => {
|
|
304
|
+
const t = a.filter((h) => !V(h, c));
|
|
305
|
+
e == null || e(t, d), f(c, (h) => r == null ? void 0 : r(t, h));
|
|
306
|
+
}, y = (c, d) => {
|
|
307
|
+
c && I(c, d);
|
|
308
|
+
}, B = (c) => ({
|
|
309
|
+
removeItem: _,
|
|
310
|
+
editItem: k,
|
|
311
|
+
handleChange: e,
|
|
312
|
+
getOptionUniqKeyValue: g,
|
|
313
|
+
storedItemsMap: b,
|
|
314
|
+
...c
|
|
315
|
+
});
|
|
316
|
+
return /* @__PURE__ */ s(
|
|
317
|
+
U,
|
|
318
|
+
{
|
|
319
|
+
...N,
|
|
320
|
+
stateReducer: (c, d) => {
|
|
321
|
+
switch (d.type) {
|
|
322
|
+
case U.stateChangeTypes.keyDownEnter:
|
|
323
|
+
case U.stateChangeTypes.clickItem:
|
|
324
|
+
return {
|
|
325
|
+
...d,
|
|
326
|
+
highlightedIndex: c.highlightedIndex,
|
|
327
|
+
inputValue: ""
|
|
328
|
+
};
|
|
329
|
+
default:
|
|
330
|
+
return d;
|
|
331
|
+
}
|
|
332
|
+
},
|
|
333
|
+
onChange: y,
|
|
334
|
+
selectedItem: null,
|
|
335
|
+
children: (c) => i == null ? void 0 : i(B(c))
|
|
336
|
+
}
|
|
337
|
+
);
|
|
338
|
+
}, at = "_autocomplete_w0t1o_16", it = "_disabled_w0t1o_32", dt = "_error_w0t1o_35", ut = "_touched_w0t1o_35", mt = "_input_w0t1o_74", ft = {
|
|
339
|
+
autocomplete: at,
|
|
340
|
+
"autocomplete-wrapper": "_autocomplete-wrapper_w0t1o_28",
|
|
341
|
+
disabled: it,
|
|
342
|
+
error: dt,
|
|
343
|
+
touched: ut,
|
|
344
|
+
"clear-icon": "_clear-icon_w0t1o_46",
|
|
345
|
+
"clear-icon--disabled": "_clear-icon--disabled_w0t1o_56",
|
|
346
|
+
"autocomplete-input": "_autocomplete-input_w0t1o_60",
|
|
347
|
+
"mobile-disabled": "_mobile-disabled_w0t1o_69",
|
|
348
|
+
input: mt,
|
|
349
|
+
"type-number": "_type-number_w0t1o_98",
|
|
350
|
+
"error-text": "_error-text_w0t1o_109",
|
|
351
|
+
"dropdown-button": "_dropdown-button_w0t1o_118",
|
|
352
|
+
"icon-reversed": "_icon-reversed_w0t1o_126"
|
|
353
|
+
}, j = H.bind(ft), jt = (o) => {
|
|
354
|
+
const {
|
|
355
|
+
options: e = [],
|
|
356
|
+
loading: a = !1,
|
|
357
|
+
onStateChange: r = () => {
|
|
358
|
+
},
|
|
359
|
+
value: n = [],
|
|
360
|
+
placeholder: i = "",
|
|
361
|
+
error: p = "",
|
|
362
|
+
touched: u = !1,
|
|
363
|
+
creatable: g = !1,
|
|
364
|
+
editable: N = !1,
|
|
365
|
+
onChange: b = () => {
|
|
366
|
+
},
|
|
367
|
+
onFocus: E = () => {
|
|
368
|
+
},
|
|
369
|
+
onBlur: w = () => {
|
|
370
|
+
},
|
|
371
|
+
disabled: f = !1,
|
|
372
|
+
isDropdownMode: I = !1,
|
|
373
|
+
mobileDisabled: k = !1,
|
|
374
|
+
inputProps: _ = {},
|
|
375
|
+
parseValueToString: y = (m) => m == null ? "" : String(m),
|
|
376
|
+
maxLength: B = null,
|
|
377
|
+
async: $ = !1,
|
|
378
|
+
customClass: c = "",
|
|
379
|
+
createWithoutConfirmation: d = !1,
|
|
380
|
+
getItemValidationErrorType: t = null,
|
|
381
|
+
clearItemsError: l = () => {
|
|
382
|
+
},
|
|
383
|
+
getAdditionalCreationCondition: h = () => !0,
|
|
384
|
+
highlightUnStoredItem: L = !1,
|
|
385
|
+
parseInputValueFn: G = null,
|
|
386
|
+
handleUnStoredItemCb: C = null,
|
|
387
|
+
dataAutomationId: te = "",
|
|
388
|
+
existingItemsMap: Z = {},
|
|
389
|
+
customizeNewSelectedValue: oe = (m) => m,
|
|
390
|
+
renderCustomSelectedItem: ne,
|
|
391
|
+
useFixedPositioning: se,
|
|
392
|
+
newItemButtonText: S = "",
|
|
393
|
+
...R
|
|
394
|
+
} = o, { refs: O, floatingStyles: P } = he({
|
|
395
|
+
placement: "bottom-start",
|
|
396
|
+
strategy: se ? "fixed" : "absolute",
|
|
397
|
+
whileElementsMounted: be
|
|
398
|
+
}), q = n.length === 0 && !f ? i : "", A = Ee(null);
|
|
399
|
+
Ie(() => {
|
|
400
|
+
l();
|
|
401
|
+
}, [l, n]);
|
|
402
|
+
const re = (m, v) => {
|
|
403
|
+
b(m, v);
|
|
404
|
+
}, ce = (m, v, F) => ({ item: x, index: T, ...z }) => m({
|
|
405
|
+
item: x,
|
|
406
|
+
index: T,
|
|
407
|
+
isSelected: F.some((le) => V(le, x)),
|
|
408
|
+
...z,
|
|
409
|
+
isActive: v === T
|
|
410
|
+
}), J = ({
|
|
411
|
+
event: m,
|
|
412
|
+
removeItem: v,
|
|
413
|
+
inputValue: F
|
|
414
|
+
}) => {
|
|
415
|
+
m.key === "Backspace" && !F && n.length && v(n[n.length - 1], null);
|
|
416
|
+
}, D = ({
|
|
417
|
+
inputValue: m,
|
|
418
|
+
selectItem: v,
|
|
419
|
+
clearSelection: F
|
|
420
|
+
}) => {
|
|
421
|
+
if (G) {
|
|
422
|
+
const x = G(m);
|
|
423
|
+
(x.length ? x : [m]).forEach((z) => v(z)), F();
|
|
424
|
+
} else
|
|
425
|
+
v(m), F();
|
|
426
|
+
}, W = (m) => (v) => {
|
|
427
|
+
m(v, null), A.current && A.current.focus();
|
|
428
|
+
}, Q = e.filter((m) => n.every((v) => !V(v, m)));
|
|
429
|
+
return /* @__PURE__ */ s(
|
|
430
|
+
lt,
|
|
431
|
+
{
|
|
432
|
+
onChange: re,
|
|
433
|
+
itemToString: y,
|
|
434
|
+
selectedItems: n,
|
|
435
|
+
onStateChange: r,
|
|
436
|
+
options: e,
|
|
437
|
+
existingItemsMap: Z,
|
|
438
|
+
handleUnStoredItemCb: C,
|
|
439
|
+
customizeNewSelectedValue: oe,
|
|
440
|
+
children: ({
|
|
441
|
+
getInputProps: m,
|
|
442
|
+
getItemProps: v,
|
|
443
|
+
isOpen: F,
|
|
444
|
+
inputValue: x,
|
|
445
|
+
highlightedIndex: T,
|
|
446
|
+
removeItem: z,
|
|
447
|
+
editItem: le,
|
|
448
|
+
openMenu: we,
|
|
449
|
+
selectItem: ue,
|
|
450
|
+
clearSelection: me,
|
|
451
|
+
toggleMenu: ye,
|
|
452
|
+
storedItemsMap: Ne,
|
|
453
|
+
getRootProps: ke
|
|
454
|
+
}) => /* @__PURE__ */ M(
|
|
455
|
+
"div",
|
|
456
|
+
{
|
|
457
|
+
...ke(void 0, { suppressRefError: !0 }),
|
|
458
|
+
className: j("autocomplete-wrapper"),
|
|
459
|
+
ref: O.setReference,
|
|
460
|
+
children: [
|
|
461
|
+
/* @__PURE__ */ M(ee, { children: [
|
|
462
|
+
/* @__PURE__ */ M(
|
|
463
|
+
"div",
|
|
464
|
+
{
|
|
465
|
+
className: j("autocomplete", c, {
|
|
466
|
+
"mobile-disabled": k,
|
|
467
|
+
error: p,
|
|
468
|
+
touched: u,
|
|
469
|
+
disabled: f
|
|
470
|
+
}),
|
|
471
|
+
children: [
|
|
472
|
+
/* @__PURE__ */ M(
|
|
473
|
+
"div",
|
|
474
|
+
{
|
|
475
|
+
className: j("autocomplete-input", {
|
|
476
|
+
"mobile-disabled": k
|
|
477
|
+
}),
|
|
478
|
+
children: [
|
|
479
|
+
/* @__PURE__ */ s(
|
|
480
|
+
He,
|
|
481
|
+
{
|
|
482
|
+
items: n,
|
|
483
|
+
onRemoveItem: W(z),
|
|
484
|
+
disabled: f,
|
|
485
|
+
mobileDisabled: k,
|
|
486
|
+
parseValueToString: y,
|
|
487
|
+
getItemValidationErrorType: t,
|
|
488
|
+
renderCustomSelectedItem: ne,
|
|
489
|
+
editItem: le,
|
|
490
|
+
editable: N,
|
|
491
|
+
getAdditionalCreationCondition: h,
|
|
492
|
+
storedItemsMap: Ne,
|
|
493
|
+
highlightUnStoredItem: L
|
|
494
|
+
}
|
|
495
|
+
),
|
|
496
|
+
/* @__PURE__ */ s(
|
|
497
|
+
"input",
|
|
498
|
+
{
|
|
499
|
+
...m({
|
|
500
|
+
ref: A,
|
|
501
|
+
placeholder: q,
|
|
502
|
+
maxLength: B,
|
|
503
|
+
onFocus: () => {
|
|
504
|
+
we(), E();
|
|
505
|
+
},
|
|
506
|
+
onKeyDown: (K) => {
|
|
507
|
+
K.key === "Enter" && x && g && h(x) && D({
|
|
508
|
+
inputValue: x,
|
|
509
|
+
selectItem: ue,
|
|
510
|
+
clearSelection: me
|
|
511
|
+
}), J({ event: K, removeItem: z, inputValue: x });
|
|
512
|
+
},
|
|
513
|
+
onBlur: () => {
|
|
514
|
+
w(), x && g && h(x) && D({
|
|
515
|
+
inputValue: x,
|
|
516
|
+
selectItem: ue,
|
|
517
|
+
clearSelection: me
|
|
518
|
+
});
|
|
519
|
+
},
|
|
520
|
+
disabled: f,
|
|
521
|
+
..._
|
|
522
|
+
}),
|
|
523
|
+
className: j("input", { disabled: f }),
|
|
524
|
+
"data-automation-id": te
|
|
525
|
+
}
|
|
526
|
+
)
|
|
527
|
+
]
|
|
528
|
+
}
|
|
529
|
+
),
|
|
530
|
+
(_ == null ? void 0 : _.clearable) && (n == null ? void 0 : n.length) > 0 && /* @__PURE__ */ s(
|
|
531
|
+
"button",
|
|
532
|
+
{
|
|
533
|
+
className: j("clear-icon", { "clear-icon--disabled": f }),
|
|
534
|
+
onClick: () => {
|
|
535
|
+
var K;
|
|
536
|
+
return !f && ((K = _ == null ? void 0 : _.onClear) == null ? void 0 : K.call(_));
|
|
537
|
+
},
|
|
538
|
+
children: /* @__PURE__ */ s(De, {})
|
|
539
|
+
}
|
|
540
|
+
),
|
|
541
|
+
I && /* @__PURE__ */ s(
|
|
542
|
+
"button",
|
|
543
|
+
{
|
|
544
|
+
type: "button",
|
|
545
|
+
className: j("dropdown-button", { "icon-reversed": F }),
|
|
546
|
+
onClick: () => ye(),
|
|
547
|
+
"aria-label": "Toggle dropdown",
|
|
548
|
+
"aria-expanded": F,
|
|
549
|
+
children: /* @__PURE__ */ s(ve, {})
|
|
550
|
+
}
|
|
551
|
+
)
|
|
552
|
+
]
|
|
553
|
+
}
|
|
554
|
+
),
|
|
555
|
+
p && u && /* @__PURE__ */ s("span", { className: j("error-text"), children: p })
|
|
556
|
+
] }),
|
|
557
|
+
/* @__PURE__ */ s(
|
|
558
|
+
ge,
|
|
559
|
+
{
|
|
560
|
+
isOpen: F,
|
|
561
|
+
loading: a,
|
|
562
|
+
async: $,
|
|
563
|
+
ref: O.setFloating,
|
|
564
|
+
newItemButtonText: S,
|
|
565
|
+
isDropdownMode: I,
|
|
566
|
+
style: P,
|
|
567
|
+
inputValue: (x || "").trim(),
|
|
568
|
+
getItemProps: ce(v, T, n),
|
|
569
|
+
parseValueToString: y,
|
|
570
|
+
createWithoutConfirmation: d,
|
|
571
|
+
options: Q,
|
|
572
|
+
...R
|
|
573
|
+
}
|
|
574
|
+
)
|
|
575
|
+
]
|
|
576
|
+
}
|
|
577
|
+
)
|
|
578
|
+
}
|
|
579
|
+
);
|
|
580
|
+
}, _t = "Enter", pt = "Tab", ht = {
|
|
581
|
+
"input-wrapper": "_input-wrapper_d9vma_1",
|
|
582
|
+
"dropdown-button": "_dropdown-button_d9vma_6",
|
|
583
|
+
"icon-reversed": "_icon-reversed_d9vma_14"
|
|
584
|
+
}, pe = H.bind(ht), bt = 0, Ht = (o) => {
|
|
585
|
+
const {
|
|
586
|
+
options: e = [],
|
|
587
|
+
value: a,
|
|
588
|
+
placeholder: r = "",
|
|
589
|
+
onChange: n = () => {
|
|
590
|
+
},
|
|
591
|
+
onFocus: i = () => {
|
|
592
|
+
},
|
|
593
|
+
onBlur: p = () => {
|
|
594
|
+
},
|
|
595
|
+
disabled: u = !1,
|
|
596
|
+
inputProps: g = {},
|
|
597
|
+
parseValueToString: N = (S) => S === null ? "" : String(S),
|
|
598
|
+
minLength: b = 1,
|
|
599
|
+
skipOptionCreation: E = !1,
|
|
600
|
+
maxLength: w = null,
|
|
601
|
+
optionVariant: f = "",
|
|
602
|
+
isRequired: I = !1,
|
|
603
|
+
error: k = "",
|
|
604
|
+
touched: _ = !1,
|
|
605
|
+
setTouch: y = () => {
|
|
606
|
+
},
|
|
607
|
+
createWithoutConfirmation: B = !1,
|
|
608
|
+
menuClassName: $ = "",
|
|
609
|
+
icon: c,
|
|
610
|
+
isDropdownMode: d = !1,
|
|
611
|
+
isOptionUnique: t,
|
|
612
|
+
refFunction: l,
|
|
613
|
+
stateReducer: h,
|
|
614
|
+
onStateChange: L,
|
|
615
|
+
useFixedPositioning: G,
|
|
616
|
+
newItemButtonText: C = "",
|
|
617
|
+
...te
|
|
618
|
+
} = o, { refs: Z, floatingStyles: oe } = he({
|
|
619
|
+
placement: "bottom-start",
|
|
620
|
+
strategy: G ? "fixed" : "absolute",
|
|
621
|
+
whileElementsMounted: be
|
|
622
|
+
}), ne = (S, R, O) => ({ item: P, index: q, ...A }) => S({
|
|
623
|
+
item: P,
|
|
624
|
+
index: q,
|
|
625
|
+
isSelected: O !== null && O === P,
|
|
626
|
+
...A,
|
|
627
|
+
isActive: R === q
|
|
628
|
+
}), se = (S, R) => {
|
|
629
|
+
S.key === pt && (S.preventDefault(), R(e.length));
|
|
630
|
+
};
|
|
631
|
+
return /* @__PURE__ */ s(
|
|
632
|
+
U,
|
|
633
|
+
{
|
|
634
|
+
onChange: n,
|
|
635
|
+
itemToString: N,
|
|
636
|
+
selectedItem: a,
|
|
637
|
+
onStateChange: L,
|
|
638
|
+
defaultHighlightedIndex: bt,
|
|
639
|
+
stateReducer: h,
|
|
640
|
+
children: ({
|
|
641
|
+
getInputProps: S,
|
|
642
|
+
getItemProps: R,
|
|
643
|
+
setHighlightedIndex: O,
|
|
644
|
+
toggleMenu: P,
|
|
645
|
+
isOpen: q,
|
|
646
|
+
inputValue: A,
|
|
647
|
+
highlightedIndex: re,
|
|
648
|
+
getRootProps: ce,
|
|
649
|
+
selectItem: J
|
|
650
|
+
}) => /* @__PURE__ */ s(ee, { children: /* @__PURE__ */ M(
|
|
651
|
+
"div",
|
|
652
|
+
{
|
|
653
|
+
className: pe("input-wrapper"),
|
|
654
|
+
...ce(void 0, { suppressRefError: !0 }),
|
|
655
|
+
ref: Z.setReference,
|
|
656
|
+
children: [
|
|
657
|
+
/* @__PURE__ */ s(
|
|
658
|
+
Ae,
|
|
659
|
+
{
|
|
660
|
+
...S({
|
|
661
|
+
placeholder: u ? "" : r,
|
|
662
|
+
maxLength: w || void 0,
|
|
663
|
+
onFocus: () => {
|
|
664
|
+
i();
|
|
665
|
+
},
|
|
666
|
+
refFunction: l,
|
|
667
|
+
onKeyDown: (D) => {
|
|
668
|
+
D.key === _t && D.preventDefault(), A && q && se(D, O);
|
|
669
|
+
},
|
|
670
|
+
onBlur: (D) => {
|
|
671
|
+
const W = (A ?? "").trim(), Q = !!W, m = Q ? e.find((v) => N(v) === W) : void 0;
|
|
672
|
+
J(m || (!E && B && Q ? W : null)), p(D), t == null || t(
|
|
673
|
+
Q ? !e.some((v) => N(v) === W) : null
|
|
674
|
+
), y == null || y(!0);
|
|
675
|
+
},
|
|
676
|
+
disabled: u,
|
|
677
|
+
defaultWidth: !1,
|
|
678
|
+
isRequired: I,
|
|
679
|
+
touched: _,
|
|
680
|
+
error: k,
|
|
681
|
+
...g,
|
|
682
|
+
endIcon: d && !c ? /* @__PURE__ */ s(
|
|
683
|
+
"button",
|
|
684
|
+
{
|
|
685
|
+
type: "button",
|
|
686
|
+
className: pe("dropdown-button", { "icon-reversed": q }),
|
|
687
|
+
onClick: () => P(),
|
|
688
|
+
"aria-label": "Toggle dropdown",
|
|
689
|
+
"aria-expanded": q,
|
|
690
|
+
children: /* @__PURE__ */ s(ve, {})
|
|
691
|
+
}
|
|
692
|
+
) : c,
|
|
693
|
+
minLength: d ? 0 : b
|
|
694
|
+
})
|
|
695
|
+
}
|
|
696
|
+
),
|
|
697
|
+
/* @__PURE__ */ s(
|
|
698
|
+
ge,
|
|
699
|
+
{
|
|
700
|
+
isOpen: q,
|
|
701
|
+
isDropdownMode: d,
|
|
702
|
+
style: oe,
|
|
703
|
+
ref: Z.setFloating,
|
|
704
|
+
minLength: b,
|
|
705
|
+
inputValue: (A || "").trim(),
|
|
706
|
+
getItemProps: ne(R, re, a),
|
|
707
|
+
parseValueToString: N,
|
|
708
|
+
optionVariant: f,
|
|
709
|
+
createWithoutConfirmation: B,
|
|
710
|
+
className: $,
|
|
711
|
+
options: e,
|
|
712
|
+
newItemButtonText: C,
|
|
713
|
+
...te
|
|
714
|
+
}
|
|
715
|
+
)
|
|
716
|
+
]
|
|
717
|
+
}
|
|
718
|
+
) })
|
|
719
|
+
}
|
|
720
|
+
);
|
|
721
|
+
};
|
|
722
|
+
export {
|
|
723
|
+
ge as AutocompleteMenu,
|
|
724
|
+
fe as AutocompleteOption,
|
|
725
|
+
Ve as AutocompleteOptions,
|
|
726
|
+
ze as AutocompletePrompt,
|
|
727
|
+
jt as MultipleAutocomplete,
|
|
728
|
+
Ht as SingleAutocomplete
|
|
729
|
+
};
|