@iress-oss/ids-components 5.16.0 → 5.17.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/{AutocompleteNoResults-D7YVtBHi.js → AutocompleteNoResults-Z4L_A4F_.js} +1 -1
- package/dist/{ComboboxHiddenInput-CzqAhHnZ.js → ComboboxHiddenInput-gJl1k-Vp.js} +5 -5
- package/dist/{FieldAppendToLabel-CMgTenh1.js → FieldAppendToLabel-CNMj7tRY.js} +3 -3
- package/dist/{InputBase-Bjj3LDLa.js → InputBase-Dt3vHG19.js} +1 -1
- package/dist/Loading.module-PM8ehb0Z.js +13 -0
- package/dist/LoadingSuspense-BjzbePWa.js +5725 -0
- package/dist/LogoFromSrc-Dr3xwNJa.js +59 -0
- package/dist/MenuItem.module-xNOwGiI0.js +24 -0
- package/dist/Popover.module-BzjyEvrY.js +11 -0
- package/dist/PopoverProvider-BqnPfQtY.js +138 -0
- package/dist/{SelectControl-CN6caR5z.js → SelectControl-IZ6Sl4ap.js} +1 -1
- package/dist/{SliderTicks-Dfw5LJ8X.js → SliderTicks-8ffd5McY.js} +1 -1
- package/dist/TabSet.module-p87tRckl.js +13 -0
- package/dist/Table.module-CdZFi754.js +32 -0
- package/dist/components/Alert/Alert.js +1 -1
- package/dist/components/Alert/index.js +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +4 -4
- package/dist/components/Autocomplete/components/AutocompleteInstructions.js +12 -0
- package/dist/components/Autocomplete/components/AutocompleteNoResults.js +1 -1
- package/dist/components/Autocomplete/hooks/useAutocompleteSearch.js +161 -113
- package/dist/components/Autocomplete/index.js +1 -1
- package/dist/components/Badge/Badge.js +4 -4
- package/dist/components/Button/Button.js +2 -2
- package/dist/components/Button/CloseButton/CloseButton.js +1 -1
- package/dist/components/Button/index.js +1 -1
- package/dist/components/ButtonGroup/ButtonGroup.js +2 -2
- package/dist/components/ButtonGroup/hooks/useIDSButtonGroupItem.js +1 -1
- package/dist/components/ButtonGroup/index.js +1 -1
- package/dist/components/Checkbox/Checkbox.js +1 -1
- package/dist/components/Checkbox/helpers/mapCheckboxGroupOptions.js +1 -1
- package/dist/components/Checkbox/index.js +1 -1
- package/dist/components/CheckboxGroup/CheckboxGroup.js +6 -6
- package/dist/components/CheckboxMark/CheckboxMark.types.js +2 -2
- package/dist/components/Combobox/Combobox.js +3 -3
- package/dist/components/Combobox/MultiCombobox/MultiCombobox.js +3 -3
- package/dist/components/Combobox/components/ComboboxHiddenInput.js +1 -1
- package/dist/components/Combobox/components/ComboboxResults.js +4 -4
- package/dist/components/Combobox/components/ComboboxResultsDescriptor.js +2 -2
- package/dist/components/Combobox/index.js +1 -1
- package/dist/components/Expander/Expander.js +1 -1
- package/dist/components/Field/Field.js +1 -1
- package/dist/components/Field/FieldGroup/FieldGroup.js +2 -2
- package/dist/components/Field/components/FieldAppendToLabel.js +3 -3
- package/dist/components/Filter/Filter.js +3 -3
- package/dist/components/Filter/components/FilterResetButton.js +2 -2
- package/dist/components/Filter/components/FilterSearch.js +2 -2
- package/dist/components/Filter/index.js +1 -1
- package/dist/components/Form/Form.js +1 -1
- package/dist/components/Form/FormField/FormField.js +2 -2
- package/dist/components/Form/FormField/FormFieldset.js +2 -2
- package/dist/components/Form/HookForm/HookForm.js +1 -1
- package/dist/components/Form/index.js +1 -1
- package/dist/components/Hide/Hide.js +1 -1
- package/dist/components/Hide/helpers/composeHideClasses.js +2 -2
- package/dist/components/Hide/index.js +1 -1
- package/dist/components/Icon/Icon.js +2 -2
- package/dist/components/Icon/index.js +1 -1
- package/dist/components/Inline/Inline.js +2 -2
- package/dist/components/Inline/index.js +1 -1
- package/dist/components/Input/ClearButton/ClearButton.js +1 -1
- package/dist/components/Input/Input.js +2 -2
- package/dist/components/Input/InputBase/InputBase.js +1 -1
- package/dist/components/Input/index.js +1 -1
- package/dist/components/InputCurrency/InputCurrency.js +1 -1
- package/dist/components/InputCurrency/index.js +1 -1
- package/dist/components/Label/LabelBase/LabelBase.js +1 -1
- package/dist/components/Menu/MenuDivider/MenuDivider.js +2 -2
- package/dist/components/Menu/MenuHeading/MenuHeading.js +2 -2
- package/dist/components/Menu/MenuItem/MenuItem.js +1 -1
- package/dist/components/Menu/MenuItem/hooks/useMenuItemButtonProps.js +1 -1
- package/dist/components/Menu/MenuItem/hooks/useMenuItemComposite.js +1 -1
- package/dist/components/Menu/MenuText/MenuText.js +3 -3
- package/dist/components/Menu/helpers/mapMenuItems.js +1 -1
- package/dist/components/Menu/hooks/useMenuStyles.js +3 -3
- package/dist/components/Menu/index.js +1 -1
- package/dist/components/Modal/Modal.js +1 -1
- package/dist/components/Modal/index.js +1 -1
- package/dist/components/Navbar/Navbar.js +2 -2
- package/dist/components/Navbar/components/HomeLinkContent.js +2 -2
- package/dist/components/Navbar/components/LogoFromSrc.js +1 -1
- package/dist/components/Navbar/components/NavbarLogo.js +2 -2
- package/dist/components/Navbar/index.js +1 -1
- package/dist/components/Placeholder/Placeholder.js +1 -1
- package/dist/components/Popover/InputPopover/InputPopover.js +1 -1
- package/dist/components/Popover/InputPopover/InputPopoverActivator.js +1 -1
- package/dist/components/Popover/InputPopover/InputPopoverProvider.js +1 -1
- package/dist/components/Popover/Popover.js +2 -2
- package/dist/components/Popover/PopoverProvider.js +4 -3
- package/dist/components/Popover/components/PopoverActivator.js +1 -1
- package/dist/components/Popover/components/PopoverContent.js +1 -1
- package/dist/components/Popover/helpers/handlePopoverTabKey.js +1 -1
- package/dist/components/Popover/hooks/usePopover.js +1 -1
- package/dist/components/Progress/Progress.js +1 -1
- package/dist/components/Provider/Provider.js +1 -1
- package/dist/components/Radio/Radio.js +1 -1
- package/dist/components/Radio/helpers/mapRadioGroupOptions.js +1 -1
- package/dist/components/Radio/index.js +1 -1
- package/dist/components/RadioGroup/RadioGroup.js +3 -3
- package/dist/components/Readonly/Readonly.js +3 -3
- package/dist/components/Readonly/index.js +1 -1
- package/dist/components/RichSelect/RichSelect.js +2 -2
- package/dist/components/RichSelect/SelectBody/SelectBody.js +2 -2
- package/dist/components/RichSelect/SelectCreate/SelectCreate.js +2 -2
- package/dist/components/RichSelect/SelectHeading/SelectHeading.js +2 -2
- package/dist/components/RichSelect/SelectLabel/SelectLabel.js +1 -1
- package/dist/components/RichSelect/SelectMenu/SelectMenu.js +2 -2
- package/dist/components/RichSelect/SelectMenu/SelectMenuItem.js +2 -2
- package/dist/components/RichSelect/SelectSearch/SelectSearch.js +1 -1
- package/dist/components/RichSelect/SelectSearchInput/SelectSearchInput.js +1 -1
- package/dist/components/RichSelect/SelectTags/SelectTags.js +1 -1
- package/dist/components/RichSelect/components/SelectActivator.js +1 -1
- package/dist/components/RichSelect/components/SelectOptions.js +2 -2
- package/dist/components/RichSelect/index.js +1 -1
- package/dist/components/Row/Row.js +2 -2
- package/dist/components/Row/index.js +1 -1
- package/dist/components/Select/Select.js +2 -2
- package/dist/components/Select/components/SelectControl.js +1 -1
- package/dist/components/Select/components/SelectReadonly.js +2 -2
- package/dist/components/Select/helpers/mapSelectOptions.js +1 -1
- package/dist/components/Select/helpers/nodesToSelectOptions.js +1 -1
- package/dist/components/Select/index.js +1 -1
- package/dist/components/Skeleton/Skeleton.js +2 -2
- package/dist/components/SkipLink/SkipLink.js +1 -1
- package/dist/components/Slideout/Slideout.js +2 -2
- package/dist/components/Slideout/components/SlideoutInner.js +2 -2
- package/dist/components/Slideout/index.js +1 -1
- package/dist/components/Slider/Slider.js +2 -2
- package/dist/components/Slider/components/SliderTicks.js +1 -1
- package/dist/components/Slider/index.js +1 -1
- package/dist/components/Spinner/Spinner.js +1 -1
- package/dist/components/Spinner/index.js +1 -1
- package/dist/components/TabSet/Tab/Tab.js +77 -66
- package/dist/components/TabSet/TabSet.js +1 -1
- package/dist/components/TabSet/components/TabSetItem.js +1 -1
- package/dist/components/Table/Table.js +2 -2
- package/dist/components/Table/TableBody/TableBody.js +2 -2
- package/dist/components/Table/components/TableEmpty.js +1 -1
- package/dist/components/Table/components/TableHeader.js +1 -1
- package/dist/components/Table/components/TableHeaderCell.js +1 -1
- package/dist/components/Table/components/TableSortButton.js +2 -2
- package/dist/components/Table/hooks/useIDSTableColumnStyles.js +1 -1
- package/dist/components/Table/index.js +1 -1
- package/dist/components/Tag/Tag.js +1 -1
- package/dist/components/Tag/TagInput/TagInput.js +1 -1
- package/dist/components/Tag/components/TagListInput/TagListInput.js +1 -1
- package/dist/components/Tag/index.js +1 -1
- package/dist/components/Toaster/Toast/Toast.js +1 -1
- package/dist/components/Toaster/Toast/ToastAnimated.js +1 -1
- package/dist/components/Toaster/Toast/ToastIcon.js +1 -1
- package/dist/components/Toaster/Toaster.js +1 -1
- package/dist/components/Toaster/ToasterProvider.js +1 -1
- package/dist/components/Toaster/hooks/useToaster.js +1 -1
- package/dist/components/Toaster/index.js +1 -1
- package/dist/components/Toggle/Toggle.js +3 -3
- package/dist/components/Tooltip/Tooltip.js +1 -1
- package/dist/components/ValidationMessage/ValidationBase/ValidationBase.js +1 -1
- package/dist/components/ValidationMessage/ValidationSummary/ValidationSummary.js +1 -1
- package/dist/constants.js +1 -1
- package/dist/helpers/dom/closestCrossShadow.js +26 -0
- package/dist/main.js +2 -2
- package/dist/patterns/Loading/Loading.js +1 -1
- package/dist/patterns/Loading/LoadingSuspense.js +1 -1
- package/dist/patterns/Loading/components/ComponentLoading.js +2 -2
- package/dist/patterns/Loading/components/DefaultLoading.js +2 -2
- package/dist/patterns/Loading/components/LongLoading.js +2 -2
- package/dist/patterns/Loading/components/PageLoading.js +2 -2
- package/dist/patterns/Loading/components/StartUpLoading.js +2 -2
- package/dist/patterns/Loading/components/ValidateLoading.js +2 -2
- package/dist/patterns/Loading/index.js +1 -1
- package/dist/src/components/Autocomplete/Autocomplete.types.d.ts +32 -0
- package/dist/src/components/Autocomplete/components/AutocompleteInstructions.d.ts +2 -0
- package/dist/src/components/Autocomplete/hooks/useAutocompleteSearch.d.ts +4 -0
- package/dist/src/components/Modal/Modal.types.d.ts +4 -0
- package/dist/src/components/RichSelect/components/SelectOptions.d.ts +3 -1
- package/dist/src/components/Slideout/Slideout.types.d.ts +4 -0
- package/dist/src/helpers/dom/closestCrossShadow.d.ts +9 -0
- package/dist/style.css +1 -1
- package/dist/{useIDSButtonGroupItem-aiqu-PIW.js → useIDSButtonGroupItem-NdNvcZnJ.js} +1 -1
- package/package.json +1 -1
- package/dist/Loading.module-BU91nTNp.js +0 -13
- package/dist/LoadingSuspense-D0TO0TDT.js +0 -5666
- package/dist/LogoFromSrc-_ACFUgYc.js +0 -59
- package/dist/MenuItem.module-aggbBK2E.js +0 -24
- package/dist/Popover.module-B2pz2c2y.js +0 -11
- package/dist/PopoverProvider-Cw5-iAgZ.js +0 -137
- package/dist/TabSet.module-yK1UoG-L.js +0 -13
- package/dist/Table.module-BgIez5R-.js +0 -32
- package/dist/components/Autocomplete/hooks/useAutocompleteFlags.js +0 -16
- package/dist/src/components/Autocomplete/hooks/useAutocompleteFlags.d.ts +0 -5
|
@@ -1,129 +1,177 @@
|
|
|
1
|
-
import { useRef as
|
|
2
|
-
import { searchLabelValues as
|
|
3
|
-
import { highlightQueryInLabelValue as
|
|
4
|
-
function
|
|
5
|
-
var
|
|
6
|
-
|
|
7
|
-
var
|
|
8
|
-
if (typeof
|
|
9
|
-
|
|
10
|
-
var
|
|
1
|
+
import { useRef as d, useState as S, useCallback as p, useEffect as M, useMemo as U } from "react";
|
|
2
|
+
import { searchLabelValues as I } from "../../../helpers/label-value/searchLabelValues.js";
|
|
3
|
+
import { highlightQueryInLabelValue as L } from "../../../helpers/label-value/highlightQueryInLabelValue.js";
|
|
4
|
+
function V(e, n, u, c) {
|
|
5
|
+
var o = this, t = d(null), a = d(0), s = d(0), r = d(null), i = d([]), h = d(), E = d(), T = d(e), m = d(!0);
|
|
6
|
+
T.current = e;
|
|
7
|
+
var v = typeof window < "u", g = !n && n !== 0 && v;
|
|
8
|
+
if (typeof e != "function") throw new TypeError("Expected a function");
|
|
9
|
+
n = +n || 0;
|
|
10
|
+
var R = !!(u = u || {}).leading, y = !("trailing" in u) || !!u.trailing, w = "maxWait" in u, H = "debounceOnServer" in u && !!u.debounceOnServer, b = w ? Math.max(+u.maxWait || 0, n) : null;
|
|
11
11
|
M(function() {
|
|
12
|
-
return
|
|
13
|
-
|
|
12
|
+
return m.current = !0, function() {
|
|
13
|
+
m.current = !1;
|
|
14
14
|
};
|
|
15
15
|
}, []);
|
|
16
|
-
var
|
|
17
|
-
var
|
|
18
|
-
var
|
|
19
|
-
return
|
|
20
|
-
},
|
|
21
|
-
|
|
22
|
-
},
|
|
23
|
-
if (!
|
|
24
|
-
var
|
|
25
|
-
return !
|
|
26
|
-
},
|
|
27
|
-
return
|
|
28
|
-
},
|
|
29
|
-
var
|
|
30
|
-
if (
|
|
31
|
-
if (
|
|
32
|
-
var
|
|
33
|
-
|
|
16
|
+
var N = U(function() {
|
|
17
|
+
var x = function(l) {
|
|
18
|
+
var f = i.current, W = h.current;
|
|
19
|
+
return i.current = h.current = null, a.current = l, s.current = s.current || l, E.current = T.current.apply(W, f);
|
|
20
|
+
}, A = function(l, f) {
|
|
21
|
+
g && cancelAnimationFrame(r.current), r.current = g ? requestAnimationFrame(l) : setTimeout(l, f);
|
|
22
|
+
}, Q = function(l) {
|
|
23
|
+
if (!m.current) return !1;
|
|
24
|
+
var f = l - t.current;
|
|
25
|
+
return !t.current || f >= n || f < 0 || w && l - a.current >= b;
|
|
26
|
+
}, _ = function(l) {
|
|
27
|
+
return r.current = null, y && i.current ? x(l) : (i.current = h.current = null, E.current);
|
|
28
|
+
}, F = function l() {
|
|
29
|
+
var f = Date.now();
|
|
30
|
+
if (R && s.current === a.current && O(), Q(f)) return _(f);
|
|
31
|
+
if (m.current) {
|
|
32
|
+
var W = n - (f - t.current), k = w ? Math.min(W, b - (f - a.current)) : W;
|
|
33
|
+
A(l, k);
|
|
34
34
|
}
|
|
35
|
-
},
|
|
36
|
-
|
|
37
|
-
},
|
|
38
|
-
if (
|
|
39
|
-
var
|
|
40
|
-
if (
|
|
41
|
-
if (!
|
|
42
|
-
if (
|
|
35
|
+
}, O = function() {
|
|
36
|
+
c && c({});
|
|
37
|
+
}, D = function() {
|
|
38
|
+
if (v || H) {
|
|
39
|
+
var l = Date.now(), f = Q(l);
|
|
40
|
+
if (i.current = [].slice.call(arguments), h.current = o, t.current = l, f) {
|
|
41
|
+
if (!r.current && m.current) return a.current = t.current, A(F, n), R ? x(t.current) : E.current;
|
|
42
|
+
if (w) return A(F, n), x(t.current);
|
|
43
43
|
}
|
|
44
|
-
return
|
|
44
|
+
return r.current || A(F, n), E.current;
|
|
45
45
|
}
|
|
46
46
|
};
|
|
47
|
-
return
|
|
48
|
-
|
|
49
|
-
},
|
|
50
|
-
return !!
|
|
51
|
-
},
|
|
52
|
-
return
|
|
53
|
-
},
|
|
54
|
-
}, [
|
|
55
|
-
return
|
|
47
|
+
return D.cancel = function() {
|
|
48
|
+
r.current && (g ? cancelAnimationFrame(r.current) : clearTimeout(r.current)), a.current = 0, i.current = t.current = h.current = r.current = null;
|
|
49
|
+
}, D.isPending = function() {
|
|
50
|
+
return !!r.current;
|
|
51
|
+
}, D.flush = function() {
|
|
52
|
+
return r.current ? _(Date.now()) : E.current;
|
|
53
|
+
}, D;
|
|
54
|
+
}, [R, w, n, b, y, g, v, H, c]);
|
|
55
|
+
return N;
|
|
56
56
|
}
|
|
57
|
-
function
|
|
58
|
-
return
|
|
57
|
+
function B(e, n) {
|
|
58
|
+
return e === n;
|
|
59
59
|
}
|
|
60
|
-
function
|
|
61
|
-
var
|
|
62
|
-
|
|
63
|
-
}, [
|
|
64
|
-
return
|
|
60
|
+
function C(e, n, u) {
|
|
61
|
+
var c = B, o = d(e), t = S({})[1], a = V(p(function(r) {
|
|
62
|
+
o.current = r, t({});
|
|
63
|
+
}, [t]), n, u, t), s = d(e);
|
|
64
|
+
return c(s.current, e) || (a(e), s.current = e), [o.current, a];
|
|
65
65
|
}
|
|
66
|
-
const
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
66
|
+
const G = 500, P = 1, j = (e) => e instanceof Error && e.message ? e.message : typeof e == "string" ? e : !0, z = () => {
|
|
67
|
+
const [e, n] = S(!1), [u, c] = S(!1), [o, t] = S([]), [a, s] = S(!1), r = p(() => {
|
|
68
|
+
t([]), n(!1), c(!1), s(!1);
|
|
69
|
+
}, []), i = p(
|
|
70
|
+
(g, R) => {
|
|
71
|
+
t(
|
|
72
|
+
g.map(
|
|
73
|
+
(y) => L(y, R)
|
|
74
|
+
)
|
|
75
|
+
), c(!1), n(!1);
|
|
76
|
+
},
|
|
77
|
+
[]
|
|
78
|
+
), h = p((g) => {
|
|
79
|
+
t([]), c(g), n(!1);
|
|
80
|
+
}, []), E = p(() => {
|
|
81
|
+
c(!1);
|
|
82
|
+
}, []), T = p((g) => {
|
|
83
|
+
n(g);
|
|
84
|
+
}, []), m = p((g) => {
|
|
85
|
+
s(g);
|
|
86
|
+
}, []), v = p(() => {
|
|
87
|
+
c(!1);
|
|
88
|
+
}, []);
|
|
89
|
+
return {
|
|
90
|
+
loading: e,
|
|
91
|
+
error: u,
|
|
92
|
+
results: o,
|
|
93
|
+
hasSearched: a,
|
|
94
|
+
reset: r,
|
|
95
|
+
updateWithResults: i,
|
|
96
|
+
updateWithError: h,
|
|
97
|
+
clearError: E,
|
|
98
|
+
setLoadingState: T,
|
|
99
|
+
setSearched: m,
|
|
100
|
+
clearErrorState: v
|
|
101
|
+
};
|
|
102
|
+
}, J = (e, n) => {
|
|
103
|
+
const u = d(""), c = p((s) => u.current === s, []), o = p((s) => {
|
|
104
|
+
u.current = s;
|
|
105
|
+
}, []), t = p(
|
|
106
|
+
async (s, r, i) => {
|
|
107
|
+
if (c(r)) return;
|
|
108
|
+
const h = ++n.current;
|
|
109
|
+
if (o(r), r.length >= i) {
|
|
110
|
+
e.setLoadingState(!0), e.clearErrorState();
|
|
111
|
+
try {
|
|
112
|
+
const E = await s(r);
|
|
113
|
+
if (h !== n.current) return;
|
|
114
|
+
e.setSearched(!0), e.updateWithResults(E, r);
|
|
115
|
+
} catch (E) {
|
|
116
|
+
if (h !== n.current) return;
|
|
117
|
+
e.setSearched(!0), e.updateWithError(
|
|
118
|
+
j(E)
|
|
119
|
+
);
|
|
120
|
+
}
|
|
121
|
+
} else
|
|
122
|
+
e.reset();
|
|
123
|
+
},
|
|
124
|
+
[e, c, o, n]
|
|
125
|
+
), a = p(
|
|
126
|
+
(s, r, i) => {
|
|
127
|
+
if (!c(r))
|
|
128
|
+
if (o(r), r.length >= i) {
|
|
129
|
+
e.setSearched(!0);
|
|
130
|
+
const h = I(r, s);
|
|
131
|
+
e.updateWithResults(h, r);
|
|
132
|
+
} else
|
|
133
|
+
e.reset();
|
|
134
|
+
},
|
|
135
|
+
[e, c, o]
|
|
136
|
+
);
|
|
137
|
+
return {
|
|
138
|
+
handleAsync: t,
|
|
139
|
+
handleSync: a
|
|
140
|
+
};
|
|
141
|
+
}, Z = ({
|
|
142
|
+
debounceThreshold: e = G,
|
|
143
|
+
initialOptions: n = [],
|
|
144
|
+
minSearchLength: u = P,
|
|
145
|
+
options: c = [],
|
|
146
|
+
query: o = ""
|
|
72
147
|
}) => {
|
|
73
|
-
const
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
debouncedQuery: a,
|
|
82
|
-
searchFn: d,
|
|
83
|
-
setResults: l,
|
|
84
|
-
setLoading: c,
|
|
85
|
-
setError: e,
|
|
86
|
-
currentRequestIdRef: h,
|
|
87
|
-
requestId: w
|
|
88
|
-
}) : g.current !== a && (g.current = a, l([]), c(!1), e(!1));
|
|
148
|
+
const t = z(), a = d(0), s = J(t, a), [r] = C(o, e);
|
|
149
|
+
M(() => {
|
|
150
|
+
if (typeof c == "function") {
|
|
151
|
+
s.handleAsync(
|
|
152
|
+
c,
|
|
153
|
+
r,
|
|
154
|
+
u
|
|
155
|
+
);
|
|
89
156
|
return;
|
|
90
157
|
}
|
|
91
|
-
|
|
92
|
-
}, [
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
158
|
+
s.handleSync(c, r, u);
|
|
159
|
+
}, [r, c, u, s]);
|
|
160
|
+
const i = () => r.length < u ? n ?? [] : t.hasSearched ? t.results : n ?? [];
|
|
161
|
+
return {
|
|
162
|
+
clearError: t.clearError,
|
|
163
|
+
debouncedQuery: r,
|
|
164
|
+
error: t.error,
|
|
165
|
+
loading: t.loading,
|
|
166
|
+
shouldShowInstructions: o.length < u,
|
|
167
|
+
shouldShowDebounceWaiting: o.length >= u && r.length < u && !t.loading && !t.hasSearched,
|
|
168
|
+
shouldShowNoResults: t.hasSearched && !t.loading && t.results.length === 0 && r.length >= u,
|
|
169
|
+
displayResults: i(),
|
|
170
|
+
// Backward compatibility
|
|
171
|
+
results: r ? t.results : n ?? [],
|
|
172
|
+
stopSearch: t.reset
|
|
101
173
|
};
|
|
102
|
-
}
|
|
103
|
-
lastQueryRun: t,
|
|
104
|
-
debouncedQuery: r,
|
|
105
|
-
searchFn: u,
|
|
106
|
-
setResults: i,
|
|
107
|
-
setLoading: s,
|
|
108
|
-
setError: n,
|
|
109
|
-
currentRequestIdRef: c,
|
|
110
|
-
requestId: v
|
|
111
|
-
}) => {
|
|
112
|
-
if (t.current === r) return;
|
|
113
|
-
if (t.current = r, !r) {
|
|
114
|
-
s(!1), n(!1);
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
let e = !1;
|
|
118
|
-
const p = await u(r).catch(
|
|
119
|
-
(l) => (e = K(l), [])
|
|
120
|
-
);
|
|
121
|
-
v === c.current && (i(
|
|
122
|
-
p.map(
|
|
123
|
-
(l) => z(l, r)
|
|
124
|
-
)
|
|
125
|
-
), n(e), s(!1));
|
|
126
|
-
}, K = (t) => t instanceof Error && t.message ? t.message : typeof t == "string" ? t : !0;
|
|
174
|
+
};
|
|
127
175
|
export {
|
|
128
|
-
|
|
176
|
+
Z as useAutocompleteSearch
|
|
129
177
|
};
|
|
@@ -2,7 +2,7 @@ import { jsx as r, jsxs as b } from "react/jsx-runtime";
|
|
|
2
2
|
import { BadgeMode as l } from "./Badge.types.js";
|
|
3
3
|
import { c as v } from "../../index-2QXL0WYc.js";
|
|
4
4
|
import { propagateTestid as p } from "../../helpers/utility/propagateTestid.js";
|
|
5
|
-
const u = "ids-badge--base-
|
|
5
|
+
const u = "ids-badge--base-v5170", m = "ids-badge--pill-v5170", f = "ids-badge--success-v5170", h = "ids-badge--warning-v5170", k = "ids-badge--danger-v5170", N = "ids-badge--info-v5170", w = "ids-badge--positive-v5170", x = "ids-badge--negative-v5170", B = "ids-badge-v5170", M = "ids-badge--host-v5170", s = {
|
|
6
6
|
base: u,
|
|
7
7
|
pill: m,
|
|
8
8
|
success: f,
|
|
@@ -11,10 +11,10 @@ const u = "ids-badge--base-v5160", m = "ids-badge--pill-v5160", f = "ids-badge--
|
|
|
11
11
|
info: N,
|
|
12
12
|
positive: w,
|
|
13
13
|
negative: x,
|
|
14
|
-
"background-default": "ids-badge--background-default-
|
|
15
|
-
"background-alt": "ids-badge--background-alt-
|
|
14
|
+
"background-default": "ids-badge--background-default-v5170",
|
|
15
|
+
"background-alt": "ids-badge--background-alt-v5170",
|
|
16
16
|
badge: B,
|
|
17
|
-
"ids-icon": "ids-icon-
|
|
17
|
+
"ids-icon": "ids-icon-v5170",
|
|
18
18
|
host: M
|
|
19
19
|
}, t = ({
|
|
20
20
|
children: i,
|
|
@@ -2,9 +2,9 @@ import "react/jsx-runtime";
|
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../index-2QXL0WYc.js";
|
|
4
4
|
import "./Button.types.js";
|
|
5
|
-
import { b as a } from "../../LoadingSuspense-
|
|
5
|
+
import { b as a } from "../../LoadingSuspense-BjzbePWa.js";
|
|
6
6
|
import "../../enums.js";
|
|
7
|
-
import "../../useIDSButtonGroupItem-
|
|
7
|
+
import "../../useIDSButtonGroupItem-NdNvcZnJ.js";
|
|
8
8
|
export {
|
|
9
9
|
a as IressButton
|
|
10
10
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BUTTON_MODES as s, BUTTON_TYPES as e, ButtonCssClass as B, ButtonMode as r, ButtonType as T } from "./Button.types.js";
|
|
2
|
-
import { b as u, c as a } from "../../LoadingSuspense-
|
|
2
|
+
import { b as u, c as a } from "../../LoadingSuspense-BjzbePWa.js";
|
|
3
3
|
export {
|
|
4
4
|
s as BUTTON_MODES,
|
|
5
5
|
e as BUTTON_TYPES,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx as o, jsxs as d } from "react/jsx-runtime";
|
|
2
2
|
import { c as n } from "../../index-2QXL0WYc.js";
|
|
3
|
-
import { s } from "../../useIDSButtonGroupItem-
|
|
3
|
+
import { s } from "../../useIDSButtonGroupItem-NdNvcZnJ.js";
|
|
4
4
|
import G, { useMemo as _ } from "react";
|
|
5
5
|
import { toArray as g } from "../../helpers/formatting/toArray.js";
|
|
6
6
|
import { useIdIfNeeded as x } from "../../hooks/useIdIfNeeded.js";
|
|
7
7
|
import { IressButtonGroupProvider as B } from "./ButtonGroupProvider.js";
|
|
8
8
|
import { propagateTestid as u } from "../../helpers/utility/propagateTestid.js";
|
|
9
|
-
import { b as I } from "../../LoadingSuspense-
|
|
9
|
+
import { b as I } from "../../LoadingSuspense-BjzbePWa.js";
|
|
10
10
|
import { GlobalCSSClass as S } from "../../enums.js";
|
|
11
11
|
const w = ({
|
|
12
12
|
children: c,
|
|
@@ -5,7 +5,7 @@ import "../../enums.js";
|
|
|
5
5
|
import "../../helpers/form/getFormControlValueAsString.js";
|
|
6
6
|
import "../CheckboxMark/CheckboxMark.types.js";
|
|
7
7
|
import "../CheckboxMark/CheckboxMark.js";
|
|
8
|
-
import { d as f } from "../../LoadingSuspense-
|
|
8
|
+
import { d as f } from "../../LoadingSuspense-BjzbePWa.js";
|
|
9
9
|
import "../../hooks/useControlledState.js";
|
|
10
10
|
import "../Form/hooks/useNoDefaultValueInForms.js";
|
|
11
11
|
import "../CheckboxGroup/CheckboxGroupContext.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import { d as p } from "../../../LoadingSuspense-
|
|
2
|
+
import { d as p } from "../../../LoadingSuspense-BjzbePWa.js";
|
|
3
3
|
import { idsLogger as i } from "../../../helpers/utility/idsLogger.js";
|
|
4
4
|
import { getFormControlValueAsString as d } from "../../../helpers/form/getFormControlValueAsString.js";
|
|
5
5
|
const h = (r) => r != null && r.length ? (i(
|
|
@@ -6,18 +6,18 @@ import { CheckboxGroupLayout as w } from "./CheckboxGroup.types.js";
|
|
|
6
6
|
import { useControlledState as A } from "../../hooks/useControlledState.js";
|
|
7
7
|
import { useNoDefaultValueInForms as D } from "../Form/hooks/useNoDefaultValueInForms.js";
|
|
8
8
|
import { CheckboxGroupContext as H } from "./CheckboxGroupContext.js";
|
|
9
|
-
const M = "ids-checkbox-group-
|
|
9
|
+
const M = "ids-checkbox-group-v5170", z = "ids-checkbox-group--full-v5170", B = "ids-checkbox-group--block-v5170", J = "ids-checkbox-group--stack-v5170", K = "ids-checkbox-group--inline-v5170", O = "ids-checkbox-group--readonly-v5170", u = {
|
|
10
10
|
checkboxGroup: M,
|
|
11
11
|
full: z,
|
|
12
12
|
block: B,
|
|
13
13
|
stack: J,
|
|
14
|
-
"ids-checkbox": "ids-checkbox-
|
|
15
|
-
"ids-input--readonly": "ids-input--readonly-
|
|
16
|
-
"ids-checkbox--label": "ids-checkbox--label-
|
|
17
|
-
"ids-checkbox--label-span": "ids-checkbox--label-span-
|
|
14
|
+
"ids-checkbox": "ids-checkbox-v5170",
|
|
15
|
+
"ids-input--readonly": "ids-input--readonly-v5170",
|
|
16
|
+
"ids-checkbox--label": "ids-checkbox--label-v5170",
|
|
17
|
+
"ids-checkbox--label-span": "ids-checkbox--label-span-v5170",
|
|
18
18
|
inline: K,
|
|
19
19
|
readonly: O,
|
|
20
|
-
"ids-input-base--readonly": "ids-input-base--readonly-
|
|
20
|
+
"ids-input-base--readonly": "ids-input-base--readonly-v5170"
|
|
21
21
|
}, h = S(
|
|
22
22
|
({
|
|
23
23
|
className: v,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const c = "ids-checkbox-mark-
|
|
1
|
+
const c = "ids-checkbox-mark-v5170", k = "ids-checkbox-mark--checked-v5170", t = "ids-checkbox-mark--indeterminate-v5170", a = {
|
|
2
2
|
checkboxMark: c,
|
|
3
3
|
checked: k,
|
|
4
4
|
indeterminate: t
|
|
5
|
-
}, n = "ids-checkbox-mark-
|
|
5
|
+
}, n = "ids-checkbox-mark-v5170", r = "ids-checkbox-mark--indeterminate-mark-v5170", i = "ids-checkbox-mark--checked-mark-v5170", s = "ids-checkbox-mark--checked-v5170", d = "ids-checkbox-mark--indeterminate-v5170", e = {
|
|
6
6
|
checkboxMark: n,
|
|
7
7
|
indeterminateMark: r,
|
|
8
8
|
checkedMark: i,
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../index-2QXL0WYc.js";
|
|
4
|
-
import "../../ComboboxHiddenInput-
|
|
4
|
+
import "../../ComboboxHiddenInput-gJl1k-Vp.js";
|
|
5
5
|
import "../../helpers/utility/propagateTestid.js";
|
|
6
6
|
import "../../helpers/formatting/toArray.js";
|
|
7
7
|
import "../Popover/Popover.js";
|
|
8
|
-
import "../../PopoverProvider-
|
|
8
|
+
import "../../PopoverProvider-BqnPfQtY.js";
|
|
9
9
|
import "../Popover/InputPopover/InputPopover.js";
|
|
10
10
|
import "../../enums.js";
|
|
11
11
|
import "../RichSelect/hooks/useRichSelectState.js";
|
|
12
|
-
import { e as T } from "../../LoadingSuspense-
|
|
12
|
+
import { e as T } from "../../LoadingSuspense-BjzbePWa.js";
|
|
13
13
|
import "../Autocomplete/hooks/useAutocompleteSearch.js";
|
|
14
14
|
import "../Badge/Badge.js";
|
|
15
15
|
import "../../hooks/useIdIfNeeded.js";
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../../index-2QXL0WYc.js";
|
|
4
|
-
import "../../../ComboboxHiddenInput-
|
|
4
|
+
import "../../../ComboboxHiddenInput-gJl1k-Vp.js";
|
|
5
5
|
import "../../../helpers/utility/propagateTestid.js";
|
|
6
6
|
import "../../../helpers/formatting/toArray.js";
|
|
7
7
|
import "../../Popover/Popover.js";
|
|
8
|
-
import "../../../PopoverProvider-
|
|
8
|
+
import "../../../PopoverProvider-BqnPfQtY.js";
|
|
9
9
|
import "../../Popover/InputPopover/InputPopover.js";
|
|
10
10
|
import "../../RichSelect/hooks/useRichSelectState.js";
|
|
11
|
-
import { f as R } from "../../../LoadingSuspense-
|
|
11
|
+
import { f as R } from "../../../LoadingSuspense-BjzbePWa.js";
|
|
12
12
|
import "../../Autocomplete/hooks/useAutocompleteSearch.js";
|
|
13
13
|
import "../../Badge/Badge.js";
|
|
14
14
|
import "../../../hooks/useIdIfNeeded.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import { C as b } from "../../../ComboboxHiddenInput-
|
|
2
|
+
import { C as b } from "../../../ComboboxHiddenInput-gJl1k-Vp.js";
|
|
3
3
|
import "../../../helpers/utility/propagateTestid.js";
|
|
4
4
|
import "../../../index-2QXL0WYc.js";
|
|
5
5
|
import "react";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import { $ as K } from "../../../LoadingSuspense-
|
|
3
|
+
import { $ as K } from "../../../LoadingSuspense-BjzbePWa.js";
|
|
4
4
|
import "../../../fuzzysort-eoXOpoo6.js";
|
|
5
5
|
import "../../Badge/Badge.js";
|
|
6
6
|
import "../../../index-2QXL0WYc.js";
|
|
@@ -13,7 +13,7 @@ import "../../Expander/Expander.js";
|
|
|
13
13
|
import "../../Form/FormContext.js";
|
|
14
14
|
import "../../Menu/Menu.js";
|
|
15
15
|
import "../../Menu/MenuProvider.js";
|
|
16
|
-
import "../../../PopoverProvider-
|
|
16
|
+
import "../../../PopoverProvider-BqnPfQtY.js";
|
|
17
17
|
import "../../CheckboxMark/CheckboxMark.types.js";
|
|
18
18
|
import "../../CheckboxMark/CheckboxMark.js";
|
|
19
19
|
import "../../Modal/ModalProvider.js";
|
|
@@ -33,8 +33,8 @@ import "../../Text/Text.js";
|
|
|
33
33
|
import "../../Toggle/Toggle.js";
|
|
34
34
|
import "../../Tooltip/Tooltip.js";
|
|
35
35
|
import "../../ValidationMessage/ValidationMessage.js";
|
|
36
|
-
import "../../../ComboboxHiddenInput-
|
|
37
|
-
import "../../../AutocompleteNoResults-
|
|
36
|
+
import "../../../ComboboxHiddenInput-gJl1k-Vp.js";
|
|
37
|
+
import "../../../AutocompleteNoResults-Z4L_A4F_.js";
|
|
38
38
|
export {
|
|
39
39
|
K as ComboboxResults
|
|
40
40
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import { _ as J } from "../../../LoadingSuspense-
|
|
3
|
+
import { _ as J } from "../../../LoadingSuspense-BjzbePWa.js";
|
|
4
4
|
import "../../../fuzzysort-eoXOpoo6.js";
|
|
5
5
|
import "../../Badge/Badge.js";
|
|
6
6
|
import "../../../index-2QXL0WYc.js";
|
|
@@ -13,7 +13,7 @@ import "../../Expander/Expander.js";
|
|
|
13
13
|
import "../../Form/FormContext.js";
|
|
14
14
|
import "../../Menu/Menu.js";
|
|
15
15
|
import "../../Menu/MenuProvider.js";
|
|
16
|
-
import "../../../PopoverProvider-
|
|
16
|
+
import "../../../PopoverProvider-BqnPfQtY.js";
|
|
17
17
|
import "../../CheckboxMark/CheckboxMark.types.js";
|
|
18
18
|
import "../../CheckboxMark/CheckboxMark.js";
|
|
19
19
|
import "../../Modal/ModalProvider.js";
|
|
@@ -4,7 +4,7 @@ import { useState as h, useEffect as _ } from "react";
|
|
|
4
4
|
import { propagateTestid as d } from "../../helpers/utility/propagateTestid.js";
|
|
5
5
|
import { ExpanderMode as E } from "./Expander.types.js";
|
|
6
6
|
import { useIdIfNeeded as b } from "../../hooks/useIdIfNeeded.js";
|
|
7
|
-
const j = "ids-expander--link-
|
|
7
|
+
const j = "ids-expander--link-v5170", y = "ids-expander--heading-v5170", M = "ids-expander--activator-v5170", O = "ids-expander--section-v5170", $ = "ids-expander-v5170", A = "ids-expander--container-v5170", S = "ids-expander--open-v5170", T = "ids-expander--container-inner-v5170", g = "ids-expander--content-v5170", e = {
|
|
8
8
|
link: j,
|
|
9
9
|
heading: y,
|
|
10
10
|
activator: M,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as c, jsxs as y } from "react/jsx-runtime";
|
|
2
2
|
import { c as A } from "../../index-2QXL0WYc.js";
|
|
3
|
-
import { F as E, s as p } from "../../FieldAppendToLabel-
|
|
3
|
+
import { F as E, s as p } from "../../FieldAppendToLabel-CNMj7tRY.js";
|
|
4
4
|
import { useMemo as o, isValidElement as q } from "react";
|
|
5
5
|
import { IressLabel as V } from "../Label/Label.js";
|
|
6
6
|
import { propagateTestid as k } from "../../helpers/utility/propagateTestid.js";
|
|
@@ -2,9 +2,9 @@ import { jsx as o, jsxs as N } from "react/jsx-runtime";
|
|
|
2
2
|
import { c as x } from "../../../index-2QXL0WYc.js";
|
|
3
3
|
import { useMemo as f } from "react";
|
|
4
4
|
import { propagateTestid as b } from "../../../helpers/utility/propagateTestid.js";
|
|
5
|
-
import { F as L } from "../../../FieldAppendToLabel-
|
|
5
|
+
import { F as L } from "../../../FieldAppendToLabel-CNMj7tRY.js";
|
|
6
6
|
import { FieldLegend as g } from "../components/FieldLegend.js";
|
|
7
|
-
const y = "ids-field-group-
|
|
7
|
+
const y = "ids-field-group-v5170", A = "ids-field-group--invalid-v5170", E = "ids-field-group--hidden-label-v5170", k = "ids-field-group--legend-v5170", q = "ids-field-group--fields-v5170", w = "ids-field-group--inline-v5170", z = "ids-field-group--join-v5170", l = {
|
|
8
8
|
fieldGroup: y,
|
|
9
9
|
invalid: A,
|
|
10
10
|
hiddenLabel: E,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "../../../index-2QXL0WYc.js";
|
|
3
|
-
import { F as N } from "../../../FieldAppendToLabel-
|
|
4
|
-
import "../../../LoadingSuspense-
|
|
3
|
+
import { F as N } from "../../../FieldAppendToLabel-CNMj7tRY.js";
|
|
4
|
+
import "../../../LoadingSuspense-BjzbePWa.js";
|
|
5
5
|
import "react";
|
|
6
6
|
import "../../../fuzzysort-eoXOpoo6.js";
|
|
7
7
|
import "../../Badge/Badge.js";
|
|
@@ -15,7 +15,7 @@ import "../../Expander/Expander.js";
|
|
|
15
15
|
import "../../Form/FormContext.js";
|
|
16
16
|
import "../../Menu/Menu.js";
|
|
17
17
|
import "../../Menu/MenuProvider.js";
|
|
18
|
-
import "../../../PopoverProvider-
|
|
18
|
+
import "../../../PopoverProvider-BqnPfQtY.js";
|
|
19
19
|
import "../../CheckboxMark/CheckboxMark.types.js";
|
|
20
20
|
import "../../CheckboxMark/CheckboxMark.js";
|
|
21
21
|
import "../../Modal/ModalProvider.js";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../index-2QXL0WYc.js";
|
|
4
|
-
import { g as Q } from "../../LoadingSuspense-
|
|
4
|
+
import { g as Q } from "../../LoadingSuspense-BjzbePWa.js";
|
|
5
5
|
import "../../helpers/utility/propagateTestid.js";
|
|
6
6
|
import "../Popover/Popover.js";
|
|
7
|
-
import "../../PopoverProvider-
|
|
7
|
+
import "../../PopoverProvider-BqnPfQtY.js";
|
|
8
8
|
import "../Popover/InputPopover/InputPopover.js";
|
|
9
9
|
import "../RichSelect/hooks/useRichSelectState.js";
|
|
10
10
|
import "../Autocomplete/hooks/useAutocompleteSearch.js";
|
|
@@ -37,7 +37,7 @@ import "../Toggle/Toggle.js";
|
|
|
37
37
|
import "../Tooltip/Tooltip.js";
|
|
38
38
|
import "../ValidationMessage/ValidationMessage.js";
|
|
39
39
|
import "./hooks/useFilterFlags.js";
|
|
40
|
-
import "../../AutocompleteNoResults-
|
|
40
|
+
import "../../AutocompleteNoResults-Z4L_A4F_.js";
|
|
41
41
|
import "./components/FilterLabel.js";
|
|
42
42
|
export {
|
|
43
43
|
Q as IressFilter
|