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