@splunk/react-ui 4.38.0 → 4.39.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 (136) hide show
  1. package/Accordion.js +131 -153
  2. package/Anchor.js +50 -58
  3. package/Animation.js +64 -59
  4. package/AnimationToggle.js +59 -61
  5. package/Box.js +59 -67
  6. package/Breadcrumbs.js +113 -127
  7. package/Button.js +151 -169
  8. package/ButtonGroup.js +41 -49
  9. package/ButtonSimple.js +264 -295
  10. package/CHANGELOG.md +28 -0
  11. package/Calendar.js +353 -414
  12. package/Card.js +183 -243
  13. package/CardLayout.js +86 -83
  14. package/Chip.js +104 -122
  15. package/Clickable.js +180 -198
  16. package/CloseButton.js +52 -60
  17. package/Code.js +24 -31
  18. package/CollapsiblePanel.js +172 -202
  19. package/Color.js +371 -412
  20. package/ColumnLayout.js +72 -96
  21. package/ComboBox.js +266 -303
  22. package/Concertina.js +406 -454
  23. package/ControlGroup.js +165 -194
  24. package/Date.js +116 -131
  25. package/DefinitionList.js +125 -149
  26. package/Divider.js +81 -79
  27. package/Dropdown.js +226 -237
  28. package/DualListbox.js +150 -186
  29. package/EventListener.js +4 -1
  30. package/File.js +1032 -955
  31. package/FormRows.js +281 -334
  32. package/Heading.js +27 -35
  33. package/Image.js +101 -116
  34. package/JSONTree.js +301 -344
  35. package/Layer.js +118 -126
  36. package/Link.js +141 -159
  37. package/List.js +61 -77
  38. package/MIGRATION.mdx +92 -38
  39. package/Markdown.js +288 -347
  40. package/Menu.js +506 -532
  41. package/Message.js +173 -196
  42. package/MessageBar.js +58 -66
  43. package/Modal.js +241 -290
  44. package/ModalLayer.js +130 -148
  45. package/Monogram.js +138 -138
  46. package/Multiselect.js +1589 -1902
  47. package/Number.js +159 -178
  48. package/Paginator.js +296 -335
  49. package/Paragraph.js +24 -32
  50. package/Popover.js +448 -441
  51. package/Progress.js +65 -75
  52. package/RadioBar.js +301 -303
  53. package/RadioList.js +77 -119
  54. package/Resize.js +105 -127
  55. package/ResultsMenu.js +373 -385
  56. package/ScreenReaderContent.js +50 -58
  57. package/Scroll.js +209 -244
  58. package/Search.js +379 -391
  59. package/Select.js +1077 -1345
  60. package/SidePanel.js +122 -142
  61. package/Slider.js +132 -145
  62. package/SlidingPanels.js +238 -270
  63. package/SplitButton.js +222 -245
  64. package/StaticContent.js +68 -76
  65. package/StepBar.js +206 -205
  66. package/Switch.js +176 -205
  67. package/TabBar.js +222 -258
  68. package/TabLayout.js +114 -139
  69. package/Table.js +2017 -2180
  70. package/Text.js +379 -493
  71. package/TextArea.js +411 -441
  72. package/Tooltip.js +116 -132
  73. package/TransitionOpen.js +160 -178
  74. package/Tree.js +268 -287
  75. package/Typography.js +48 -52
  76. package/WaitSpinner.js +60 -68
  77. package/cypress/support/commands.ts +9 -0
  78. package/cypress/support/index.d.ts +6 -0
  79. package/cypress/tsconfig.cypress.json +1 -0
  80. package/docker-compose.yml +0 -1
  81. package/package.json +14 -14
  82. package/types/src/Button/Button.d.ts +5 -1
  83. package/types/src/ButtonSimple/ButtonSimple.d.ts +2 -2
  84. package/types/src/CollapsiblePanel/CollapsiblePanel.d.ts +1 -1
  85. package/types/src/Color/Color.d.ts +2 -2
  86. package/types/src/Color/Palette.d.ts +4 -2
  87. package/types/src/ComboBox/Option.d.ts +1 -1
  88. package/types/src/ControlGroup/ControlGroup.d.ts +1 -2
  89. package/types/src/Date/Date.d.ts +2 -2
  90. package/types/src/File/File.d.ts +2 -3
  91. package/types/src/File/Retry.d.ts +1 -2
  92. package/types/src/Menu/Item.d.ts +18 -5
  93. package/types/src/Menu/Menu.d.ts +3 -3
  94. package/types/src/Menu/docs/examples/Adornments.d.ts +2 -0
  95. package/types/src/Menu/docs/examples/SelectableWithAdornments.d.ts +2 -0
  96. package/types/src/ModalLayer/ModalLayer.d.ts +1 -1
  97. package/types/src/Multiselect/Option.d.ts +2 -0
  98. package/types/src/Number/Number.d.ts +3 -3
  99. package/types/src/Popover/Popover.d.ts +3 -4
  100. package/types/src/RadioBar/RadioBar.d.ts +2 -2
  101. package/types/src/ResultsMenu/VirtualizedResultsMenu/VirtualizedResultsMenu.d.ts +1 -1
  102. package/types/src/ScrollContainerContext/ScrollContainerContext.d.ts +2 -2
  103. package/types/src/Search/Option.d.ts +9 -3
  104. package/types/src/Select/Option.d.ts +3 -1
  105. package/types/src/Select/OptionBase.d.ts +7 -5
  106. package/types/src/Select/Select.d.ts +1 -1
  107. package/types/src/Select/SelectAllOption.d.ts +4 -4
  108. package/types/src/SidePanel/SidePanel.d.ts +1 -1
  109. package/types/src/Slider/Slider.d.ts +2 -2
  110. package/types/src/SlidingPanels/SlidingPanels.d.ts +1 -1
  111. package/types/src/StepBar/Step.d.ts +1 -2
  112. package/types/src/Switch/Switch.d.ts +0 -1
  113. package/types/src/TabBar/Tab.d.ts +1 -1
  114. package/types/src/TabBar/TabBar.d.ts +3 -1
  115. package/types/src/TabLayout/TabLayout.d.ts +2 -0
  116. package/types/src/Table/HeadDropdownCell.d.ts +2 -0
  117. package/types/src/Table/Table.d.ts +0 -1
  118. package/types/src/Table/docs/examples/StripeRows.d.ts +2 -0
  119. package/types/src/Text/IconOutlinedHide.d.ts +1 -2
  120. package/types/src/Text/IconOutlinedView.d.ts +1 -2
  121. package/types/src/Text/Text.d.ts +2 -2
  122. package/types/src/TextArea/TextArea.d.ts +2 -2
  123. package/types/src/Tooltip/Tooltip.d.ts +4 -4
  124. package/types/src/TransitionOpen/TransitionOpen.d.ts +1 -1
  125. package/useForceUpdate.js +30 -32
  126. package/useKeyPress.js +1 -1
  127. package/types/src/ButtonGroup/docs/examples/prisma/Basic.d.ts +0 -1
  128. package/types/src/File/docs/examples/prisma/Error.d.ts +0 -1
  129. package/types/src/Menu/docs/examples/Icons.d.ts +0 -2
  130. package/types/src/Menu/docs/examples/SelectableWithIcons.d.ts +0 -2
  131. package/types/src/TabBar/docs/examples/prisma/Context.d.ts +0 -2
  132. package/types/src/TabLayout/docs/examples/prisma/Context.d.ts +0 -2
  133. package/types/src/Table/docs/examples/prisma/Basic.d.ts +0 -2
  134. /package/types/src/Message/docs/examples/{prisma/Title.d.ts → Title.d.ts} +0 -0
  135. /package/types/src/StepBar/docs/examples/{prisma/Error.d.ts → Error.d.ts} +0 -0
  136. /package/types/src/TabBar/docs/examples/{prisma/Disabled.d.ts → Disabled.d.ts} +0 -0
package/Select.js CHANGED
@@ -61,25 +61,25 @@
61
61
  e.r(t);
62
62
  // EXPORTS
63
63
  e.d(t, {
64
- Divider: () => /* reexport */ T.Divider,
65
- Heading: () => /* reexport */ T.Heading,
66
- Option: () => /* reexport */ nn,
67
- default: () => /* reexport */ wn
64
+ Divider: () => /* reexport */ M.Divider,
65
+ Heading: () => /* reexport */ M.Heading,
66
+ Option: () => /* reexport */ zt,
67
+ default: () => /* reexport */ fn
68
68
  });
69
69
  // CONCATENATED MODULE: external "react"
70
70
  const n = require("react");
71
71
  var r = e.n(n);
72
72
  // CONCATENATED MODULE: external "prop-types"
73
73
  const o = require("prop-types");
74
- var i = e.n(o);
74
+ var l = e.n(o);
75
75
  // CONCATENATED MODULE: external "lodash/has"
76
- const a = require("lodash/has");
77
- var l = e.n(a);
76
+ const i = require("lodash/has");
77
+ var a = e.n(i);
78
78
  // CONCATENATED MODULE: external "@splunk/ui-utils/i18n"
79
- const c = require("@splunk/ui-utils/i18n");
79
+ const u = require("@splunk/ui-utils/i18n");
80
80
  // CONCATENATED MODULE: external "lodash/castArray"
81
- const s = require("lodash/castArray");
82
- var u = e.n(s);
81
+ const c = require("lodash/castArray");
82
+ var s = e.n(c);
83
83
  // CONCATENATED MODULE: external "lodash/find"
84
84
  const p = require("lodash/find");
85
85
  var f = e.n(p);
@@ -90,268 +90,251 @@
90
90
  const h = require("lodash/includes");
91
91
  var b = e.n(h);
92
92
  // CONCATENATED MODULE: external "lodash/isUndefined"
93
- const m = require("lodash/isUndefined");
94
- var y = e.n(m);
93
+ const y = require("lodash/isUndefined");
94
+ var m = e.n(y);
95
95
  // CONCATENATED MODULE: external "lodash/keys"
96
96
  const g = require("lodash/keys");
97
97
  var O = e.n(g);
98
98
  // CONCATENATED MODULE: external "lodash/memoize"
99
- const S = require("lodash/memoize");
100
- var w = e.n(S);
99
+ const w = require("lodash/memoize");
100
+ var S = e.n(w);
101
101
  // CONCATENATED MODULE: external "lodash/omit"
102
- const x = require("lodash/omit");
103
- var C = e.n(x);
102
+ const C = require("lodash/omit");
103
+ var x = e.n(C);
104
104
  // CONCATENATED MODULE: external "lodash/pick"
105
105
  const k = require("lodash/pick");
106
- var I = e.n(k);
106
+ var j = e.n(k);
107
107
  // CONCATENATED MODULE: external "lodash/uniq"
108
- const _ = require("lodash/uniq");
109
- var A = e.n(_);
108
+ const P = require("lodash/uniq");
109
+ var E = e.n(P);
110
110
  // CONCATENATED MODULE: external "lodash/without"
111
- const j = require("lodash/without");
112
- var E = e.n(j);
111
+ const I = require("lodash/without");
112
+ var T = e.n(I);
113
113
  // CONCATENATED MODULE: external "@splunk/ui-utils/id"
114
- const M = require("@splunk/ui-utils/id");
114
+ const A = require("@splunk/ui-utils/id");
115
115
  // CONCATENATED MODULE: external "@splunk/react-ui/Menu"
116
- const T = require("@splunk/react-ui/Menu");
116
+ const M = require("@splunk/react-ui/Menu");
117
117
  // CONCATENATED MODULE: external "@splunk/react-ui/Dropdown"
118
- const P = require("@splunk/react-ui/Dropdown");
119
- var V = e.n(P);
118
+ const _ = require("@splunk/react-ui/Dropdown");
119
+ var V = e.n(_);
120
120
  // CONCATENATED MODULE: external "@splunk/ui-utils/keyboard"
121
- const R = require("@splunk/ui-utils/keyboard");
121
+ const q = require("@splunk/ui-utils/keyboard");
122
122
  // CONCATENATED MODULE: external "@splunk/ui-utils/filter"
123
- const D = require("@splunk/ui-utils/filter");
123
+ const R = require("@splunk/ui-utils/filter");
124
124
  // CONCATENATED MODULE: external "@splunk/react-ui/Link"
125
125
  const L = require("@splunk/react-ui/Link");
126
- var q = e.n(L);
126
+ var D = e.n(L);
127
127
  // CONCATENATED MODULE: external "@splunk/react-ui/ResultsMenu"
128
- const N = require("@splunk/react-ui/ResultsMenu");
129
- var B = e.n(N);
128
+ const B = require("@splunk/react-ui/ResultsMenu");
129
+ var K = e.n(B);
130
130
  // CONCATENATED MODULE: external "@splunk/react-ui/Text"
131
- const K = require("@splunk/react-ui/Text");
132
- var F = e.n(K);
131
+ const N = require("@splunk/react-ui/Text");
132
+ var F = e.n(N);
133
133
  // CONCATENATED MODULE: external "@splunk/react-icons/CaretSmallDown"
134
134
  const H = require("@splunk/react-icons/CaretSmallDown");
135
- var $ = e.n(H);
135
+ var z = e.n(H);
136
136
  // CONCATENATED MODULE: external "@splunk/react-icons/enterprise/Caret"
137
- const z = require("@splunk/react-icons/enterprise/Caret");
138
- var W = e.n(z);
137
+ const $ = require("@splunk/react-icons/enterprise/Caret");
138
+ var W = e.n($);
139
139
  // CONCATENATED MODULE: external "@splunk/themes"
140
140
  const U = require("@splunk/themes");
141
141
  // CONCATENATED MODULE: ./src/Select/icons/CaretSmallDown.tsx
142
- var G = function e() {
142
+ var J = function e() {
143
143
  var t = (0, U.useSplunkTheme)(), n = t.isEnterprise;
144
144
  var o = n ? r().createElement(W(), {
145
145
  screenReaderText: null,
146
146
  hideDefaultTooltip: true,
147
147
  size: .5
148
- }) : r().createElement($(), null);
148
+ }) : r().createElement(z(), null);
149
149
  return o;
150
150
  };
151
- /* harmony default export */ const J = G;
151
+ /* harmony default export */ const X = J;
152
152
  // CONCATENATED MODULE: external "@splunk/react-icons/enterprise/Search"
153
- const X = require("@splunk/react-icons/enterprise/Search");
154
- var Y = e.n(X);
153
+ const G = require("@splunk/react-icons/enterprise/Search");
154
+ var Q = e.n(G);
155
155
  // CONCATENATED MODULE: external "@splunk/react-icons/Magnifier"
156
- const Q = require("@splunk/react-icons/Magnifier");
157
- var Z = e.n(Q);
156
+ const Y = require("@splunk/react-icons/Magnifier");
157
+ var Z = e.n(Y);
158
158
  // CONCATENATED MODULE: ./src/Select/icons/Search.tsx
159
159
  var ee = function e() {
160
160
  var t = (0, U.useSplunkTheme)(), n = t.isEnterprise, o = t.isCompact;
161
- var i = (0, c._)("Search");
162
- var a = o ? "20px" : "24px";
163
- var l = n ? r().createElement(Y(), {
161
+ var l = (0, u._)("Search");
162
+ var i = o ? "20px" : "24px";
163
+ var a = n ? r().createElement(Q(), {
164
164
  role: "presentation",
165
165
  size: "16px",
166
- screenReaderText: i,
166
+ screenReaderText: l,
167
167
  hideDefaultTooltip: true
168
168
  }) : r().createElement(Z(), {
169
169
  role: "presentation",
170
- "aria-label": i,
171
- width: a,
172
- height: a
170
+ "aria-label": l,
171
+ width: i,
172
+ height: i
173
173
  });
174
- return l;
174
+ return a;
175
175
  };
176
176
  /* harmony default export */ const te = ee;
177
177
  // CONCATENATED MODULE: ./src/Select/OptionBase.tsx
178
178
  function ne(e) {
179
179
  "@babel/helpers - typeof";
180
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
181
- ne = function e(t) {
182
- return typeof t;
183
- };
184
- } else {
185
- ne = function e(t) {
186
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
187
- };
188
- }
189
- return ne(e);
180
+ return ne = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
181
+ return typeof e;
182
+ } : function(e) {
183
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
184
+ }, ne(e);
190
185
  }
191
186
  function re() {
192
- re = Object.assign || function(e) {
187
+ return re = Object.assign ? Object.assign.bind() : function(e) {
193
188
  for (var t = 1; t < arguments.length; t++) {
194
189
  var n = arguments[t];
195
190
  for (var r in n) {
196
- if (Object.prototype.hasOwnProperty.call(n, r)) {
197
- e[r] = n[r];
198
- }
191
+ ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
199
192
  }
200
193
  }
201
194
  return e;
202
- };
203
- return re.apply(this, arguments);
195
+ }, re.apply(null, arguments);
204
196
  }
205
197
  function oe(e, t) {
206
- if (e == null) return {};
207
- var n = ie(e, t);
208
- var r, o;
198
+ if (null == e) return {};
199
+ var n, r, o = le(e, t);
209
200
  if (Object.getOwnPropertySymbols) {
210
- var i = Object.getOwnPropertySymbols(e);
211
- for (o = 0; o < i.length; o++) {
212
- r = i[o];
213
- if (t.indexOf(r) >= 0) continue;
214
- if (!Object.prototype.propertyIsEnumerable.call(e, r)) continue;
215
- n[r] = e[r];
201
+ var l = Object.getOwnPropertySymbols(e);
202
+ for (r = 0; r < l.length; r++) {
203
+ n = l[r], t.includes(n) || {}.propertyIsEnumerable.call(e, n) && (o[n] = e[n]);
216
204
  }
217
205
  }
218
- return n;
206
+ return o;
219
207
  }
220
- function ie(e, t) {
221
- if (e == null) return {};
208
+ function le(e, t) {
209
+ if (null == e) return {};
222
210
  var n = {};
223
- var r = Object.keys(e);
224
- var o, i;
225
- for (i = 0; i < r.length; i++) {
226
- o = r[i];
227
- if (t.indexOf(o) >= 0) continue;
228
- n[o] = e[o];
211
+ for (var r in e) {
212
+ if ({}.hasOwnProperty.call(e, r)) {
213
+ if (t.includes(r)) continue;
214
+ n[r] = e[r];
215
+ }
229
216
  }
230
217
  return n;
231
218
  }
232
- function ae(e, t) {
233
- if (!(e instanceof t)) {
234
- throw new TypeError("Cannot call a class as a function");
235
- }
219
+ function ie(e, t) {
220
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
236
221
  }
237
- function le(e, t) {
222
+ function ae(e, t) {
238
223
  for (var n = 0; n < t.length; n++) {
239
224
  var r = t[n];
240
- r.enumerable = r.enumerable || false;
241
- r.configurable = true;
242
- if ("value" in r) r.writable = true;
243
- Object.defineProperty(e, r.key, r);
225
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0),
226
+ Object.defineProperty(e, ye(r.key), r);
244
227
  }
245
228
  }
246
- function ce(e, t, n) {
247
- if (t) le(e.prototype, t);
248
- if (n) le(e, n);
249
- return e;
229
+ function ue(e, t, n) {
230
+ return t && ae(e.prototype, t), n && ae(e, n), Object.defineProperty(e, "prototype", {
231
+ writable: !1
232
+ }), e;
250
233
  }
251
- function se(e, t) {
252
- if (typeof t !== "function" && t !== null) {
253
- throw new TypeError("Super expression must either be null or a function");
254
- }
234
+ function ce(e, t) {
235
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
255
236
  e.prototype = Object.create(t && t.prototype, {
256
237
  constructor: {
257
238
  value: e,
258
- writable: true,
259
- configurable: true
239
+ writable: !0,
240
+ configurable: !0
260
241
  }
261
- });
262
- if (t) ue(e, t);
242
+ }), Object.defineProperty(e, "prototype", {
243
+ writable: !1
244
+ }), t && se(e, t);
263
245
  }
264
- function ue(e, t) {
265
- ue = Object.setPrototypeOf || function e(t, n) {
266
- t.__proto__ = n;
267
- return t;
268
- };
269
- return ue(e, t);
246
+ function se(e, t) {
247
+ return se = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
248
+ return e.__proto__ = t, e;
249
+ }, se(e, t);
270
250
  }
271
251
  function pe(e) {
272
252
  var t = ve();
273
- return function n() {
274
- var r = he(e), o;
253
+ return function() {
254
+ var n, r = he(e);
275
255
  if (t) {
276
- var i = he(this).constructor;
277
- o = Reflect.construct(r, arguments, i);
278
- } else {
279
- o = r.apply(this, arguments);
280
- }
281
- return fe(this, o);
256
+ var o = he(this).constructor;
257
+ n = Reflect.construct(r, arguments, o);
258
+ } else n = r.apply(this, arguments);
259
+ return fe(this, n);
282
260
  };
283
261
  }
284
262
  function fe(e, t) {
285
- if (t && (ne(t) === "object" || typeof t === "function")) {
286
- return t;
287
- }
263
+ if (t && ("object" == ne(t) || "function" == typeof t)) return t;
264
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
288
265
  return de(e);
289
266
  }
290
267
  function de(e) {
291
- if (e === void 0) {
292
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
293
- }
268
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
294
269
  return e;
295
270
  }
296
271
  function ve() {
297
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
298
- if (Reflect.construct.sham) return false;
299
- if (typeof Proxy === "function") return true;
300
272
  try {
301
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
302
- return true;
303
- } catch (e) {
304
- return false;
305
- }
273
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
274
+ } catch (e) {}
275
+ return (ve = function t() {
276
+ return !!e;
277
+ })();
306
278
  }
307
279
  function he(e) {
308
- he = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
309
- return t.__proto__ || Object.getPrototypeOf(t);
310
- };
311
- return he(e);
280
+ return he = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
281
+ return e.__proto__ || Object.getPrototypeOf(e);
282
+ }, he(e);
312
283
  }
313
284
  function be(e, t, n) {
314
- if (t in e) {
315
- Object.defineProperty(e, t, {
316
- value: n,
317
- enumerable: true,
318
- configurable: true,
319
- writable: true
320
- });
321
- } else {
322
- e[t] = n;
285
+ return (t = ye(t)) in e ? Object.defineProperty(e, t, {
286
+ value: n,
287
+ enumerable: !0,
288
+ configurable: !0,
289
+ writable: !0
290
+ }) : e[t] = n, e;
291
+ }
292
+ function ye(e) {
293
+ var t = me(e, "string");
294
+ return "symbol" == ne(t) ? t : t + "";
295
+ }
296
+ function me(e, t) {
297
+ if ("object" != ne(e) || !e) return e;
298
+ var n = e[Symbol.toPrimitive];
299
+ if (void 0 !== n) {
300
+ var r = n.call(e, t || "default");
301
+ if ("object" != ne(r)) return r;
302
+ throw new TypeError("@@toPrimitive must return a primitive value.");
323
303
  }
324
- return e;
304
+ return ("string" === t ? String : Number)(e);
325
305
  }
326
- var me = {
306
+ var ge = {
327
307
  /** @private */
328
- active: i().bool,
329
- children: i().node,
330
- description: i().string,
331
- descriptionPosition: i().oneOf([ "right", "bottom" ]),
332
- disabled: i().bool,
333
- hidden: i().bool,
334
- icon: i().node,
335
- label: i().string.isRequired,
308
+ active: l().bool,
309
+ children: l().node,
310
+ description: l().string,
311
+ descriptionPosition: l().oneOf([ "right", "bottom" ]),
312
+ disabled: l().bool,
313
+ hidden: l().bool,
314
+ icon: l().node,
315
+ label: l().string.isRequired,
336
316
  /**
337
317
  * @private Passed down from <BaseSelect>
338
318
  */
339
- multiple: i().bool,
340
- matchRanges: i().arrayOf(i().shape({
341
- start: i().number.isRequired,
342
- end: i().number.isRequired
319
+ multiple: l().bool,
320
+ matchRanges: l().arrayOf(l().shape({
321
+ start: l().number.isRequired,
322
+ end: l().number.isRequired
343
323
  })),
344
324
  /** @private */
345
- onClick: i().func,
325
+ onClick: l().func,
326
+ /** @private */
327
+ role: l().oneOf([ "menuitemcheckbox", "option" ]),
346
328
  /** @private */
347
- selected: i().bool,
348
- truncate: i().bool,
349
- value: i().oneOfType([ i().string, i().number, i().bool ]).isRequired
329
+ selected: l().oneOfType([ l().bool, l().oneOf([ "some" ]) ]),
330
+ truncate: l().bool,
331
+ value: l().oneOfType([ l().string, l().number, l().bool ]).isRequired
350
332
  };
351
- var ye = {
333
+ var Oe = {
352
334
  descriptionPosition: "bottom",
353
335
  disabled: false,
354
336
  multiple: false,
337
+ role: "option",
355
338
  selected: false,
356
339
  truncate: false
357
340
  };
@@ -359,20 +342,20 @@
359
342
  * An option within a `Multiselect`. This inherits from
360
343
  * [PureComponent](https://reactjs.org/docs/react-api.html#reactpurecomponent)
361
344
  * so any elements passed to it must also be pure.
362
- */ var ge = function(e) {
363
- se(n, e);
345
+ */ var we = function(e) {
346
+ ce(n, e);
364
347
  var t = pe(n);
365
348
  function n() {
366
349
  var e;
367
- ae(this, n);
368
- for (var r = arguments.length, o = new Array(r), i = 0; i < r; i++) {
369
- o[i] = arguments[i];
350
+ ie(this, n);
351
+ for (var r = arguments.length, o = new Array(r), l = 0; l < r; l++) {
352
+ o[l] = arguments[l];
370
353
  }
371
354
  e = t.call.apply(t, [ this ].concat(o));
372
355
  be(de(e), "c", null);
373
356
  be(de(e), "handleClick", (function(t) {
374
- var n = e.props, r = n.onClick, o = n.value, i = n.disabled;
375
- if (!i) {
357
+ var n = e.props, r = n.onClick, o = n.value, l = n.disabled;
358
+ if (!l) {
376
359
  r === null || r === void 0 ? void 0 : r(t, {
377
360
  value: o
378
361
  });
@@ -383,15 +366,19 @@
383
366
  }));
384
367
  return e;
385
368
  }
386
- ce(n, [ {
369
+ // @docs-props-type OptionPropsBase
370
+ ue(n, [ {
387
371
  key: "scrollIntoViewIfNeeded",
372
+ // eslint-disable-next-line react/no-unused-class-component-methods
388
373
  value: function e() {
389
374
  var t;
390
375
  (t = this.c) === null || t === void 0 ? void 0 : t.scrollIntoViewIfNeeded();
391
376
  }
392
377
  /**
393
378
  * Place focus on the button.
394
- */ }, {
379
+ */
380
+ // eslint-disable-next-line react/no-unused-class-component-methods
381
+ }, {
395
382
  key: "focus",
396
383
  value: function e() {
397
384
  var t;
@@ -400,278 +387,73 @@
400
387
  }, {
401
388
  key: "render",
402
389
  value: function e() {
403
- var t = this.props, n = t.value, o = t.children, i = t.label, a = t.multiple, l = oe(t, [ "value", "children", "label", "multiple" ]);
390
+ var t = this.props, n = t.value, o = t.children, l = t.label, i = t.multiple, a = t.role, u = t.icon, c = oe(t, [ "value", "children", "label", "multiple", "role", "icon" ]);
391
+ var s = n.toString();
404
392
 
405
- return r().createElement(T.Item, re({
393
+ return r().createElement(M.Item, re({
406
394
  "data-test-value": n,
407
395
  "data-test": "option",
408
396
  ref: this.handleMount
409
- }, l, {
397
+ }, c, {
410
398
  selectable: true,
411
- selectableAppearance: a ? "checkbox" : "checkmark",
399
+ selectableAppearance: i ? "checkbox" : "checkmark",
412
400
  onClick: this.handleClick,
413
- role: "option",
414
- value: n.toString()
415
- }), o || i);
401
+ role: a,
402
+ value: s,
403
+ startAdornment: u
404
+ }), o || l);
416
405
  }
417
406
  } ]);
418
407
  return n;
419
408
  }(n.PureComponent);
420
- be(ge, "propTypes", me);
421
- be(ge, "defaultProps", ye);
422
- be(ge, "type", T.Item);
423
- /* harmony default export */ const Oe = ge;
424
- // CONCATENATED MODULE: external "styled-components"
425
- const Se = require("styled-components");
426
- var we = e.n(Se);
427
- // CONCATENATED MODULE: external "@splunk/react-ui/Clickable"
428
- const xe = require("@splunk/react-ui/Clickable");
429
- var Ce = e.n(xe);
430
- // CONCATENATED MODULE: external "@splunk/react-ui/Switch"
431
- const ke = require("@splunk/react-ui/Switch");
432
- var Ie = e.n(ke);
433
- // CONCATENATED MODULE: ./src/Menu/ItemStyles.ts
434
- var _e = (0, Se.css)([ "color:", ";font-size:", ";line-height:", ";overflow:inherit;white-space:inherit;text-overflow:inherit;" ], (0,
435
- U.pick)({
436
- prisma: U.variables.contentColorDefault,
437
- enterprise: U.variables.textGray
438
- }), U.variables.fontSizeSmall, (0, U.pick)({
439
- prisma: "16px"
440
- }));
441
- var Ae = we().span.withConfig({
442
- displayName: "ItemStyles__StyledItemDescriptionBottom",
443
- componentId: "sc-4kc053-0"
444
- })([ "", ";display:block;" ], _e);
445
- var je = we().span.withConfig({
446
- displayName: "ItemStyles__StyledItemDescriptionRight",
447
- componentId: "sc-4kc053-1"
448
- })([ "", ";float:right;", " max-width:50%;text-align:right;box-sizing:border-box;" ], _e, (0,
449
- U.pick)({
450
- enterprise: (0, Se.css)([ "padding-left:", ";" ], U.variables.spacingLarge)
451
- }));
452
- var Ee = we().div.withConfig({
453
- displayName: "ItemStyles__StyledItemSelectedIcon",
454
- componentId: "sc-4kc053-2"
455
- })([ "position:absolute;", " color:", ";" ], (0, U.pick)({
456
- prisma: (0, Se.css)([ "right:16px;" ]),
457
- enterprise: (0, Se.css)([ "right:3px;left:8px;" ])
458
- }), (0, U.pick)({
459
- prisma: U.variables.contentColorActive,
460
- enterprise: U.variables.accentColorL10
461
- }));
462
- var Me = we().span.withConfig({
463
- displayName: "ItemStyles__StyledItemIcon",
464
- componentId: "sc-4kc053-3"
465
- })([ "flex:0 0 auto;padding-right:", ";min-width:10px;display:inline-block;text-align:center;vertical-align:", ";", "" ], (0,
466
- U.pick)({
467
- prisma: "8px",
468
- enterprise: "3px"
469
- }), (0, U.pick)({
470
- prisma: "initial",
471
- enterprise: "middle"
472
- }), (0, U.pick)({
473
- prisma: (0, Se.css)([ "color:", ";display:inline-flex;align-items:center;min-width:20px;min-height:20px;& > svg{width:20px;height:20px;}" ], U.variables.contentColorMuted),
474
- enterprise: (0, Se.css)([ "transform:translateY(-1px);" ])
475
- }));
476
- var Te = we()(Ce()).withConfig({
477
- displayName: "ItemStyles__StyledClickable",
478
- componentId: "sc-4kc053-4"
479
- })([ "display:block;position:relative;cursor:pointer;color:", ";word-wrap:break-word;max-width:100%;width:100%;padding:", ";", " ", " ", " &:not([disabled],[aria-disabled='true']){&:hover{background:", ";", "}", " ", "}&:focus{outline:0;box-shadow:", ";", "}&[disabled],&[aria-disabled='true']{color:", ";cursor:not-allowed;", ",", "{color:inherit;}", "{cursor:not-allowed;color:", ";}", "}", "" ], (0,
480
- U.pick)({
481
- prisma: U.variables.contentColorActive,
482
- enterprise: {
483
- dark: U.variables.gray96,
484
- light: U.variables.gray22
485
- }
486
- }), (0, U.pick)({
487
- prisma: {
488
- comfortable: "10px 16px",
489
- compact: "6px 16px"
490
- },
491
- enterprise: "6px 10px"
492
- }), (function(e) {
493
- var t = e.$isSelectable, n = e.$selectableAppearance;
494
- return t && (0, U.pick)({
495
- prisma: (0, Se.css)([ "padding-right:44px;", "" ], (function() {
496
- return n === "checkbox" && "padding-left: 42px;";
497
- })),
498
- enterprise: (0, Se.css)([ "padding-right:10px;padding-left:", ";" ], (function() {
499
- return n === "checkbox" ? "32px" : "28px";
500
- }))
501
- });
502
- }), (function(e) {
503
- var t = e.$active, n = e.$preventFocus;
504
- return t && !n && (0, Se.css)([ "box-shadow:", ";" ], U.variables.focusShadowInset);
505
- }), (function(e) {
506
- var t = e.$active;
507
- return t && (0, Se.css)([ "background:", ";font-weight:", ";" ], (0, U.pick)({
508
- enterprise: {
509
- light: U.variables.gray92,
510
- dark: U.variables.gray22
511
- },
512
- prisma: U.variables.neutral100
513
- }), U.variables.fontWeightBold);
514
- }), (0, U.pick)({
515
- prisma: U.variables.interactiveColorOverlayHover,
516
- enterprise: U.variables.backgroundColorHover
517
- }), (function(e) {
518
- var t = e.$selected;
519
- return t && (0, U.pick)({
520
- prisma: (0, Se.css)([ "background:", ";" ], U.mixins.overlayColors(U.variables.interactiveColorOverlaySelected, U.variables.interactiveColorOverlayHover))
521
- });
522
- }), (0, U.pick)({
523
- prisma: (0, Se.css)([ "&:active{background:", ";}" ], U.variables.interactiveColorOverlayActive)
524
- }), (function(e) {
525
- var t = e.$selected;
526
- return t && (0, U.pick)({
527
- prisma: (0, Se.css)([ "background:", ";&:active{background:", ";}" ], U.variables.interactiveColorOverlaySelected, U.mixins.overlayColors(U.variables.interactiveColorOverlaySelected, U.variables.interactiveColorOverlayActive))
528
- });
529
- }), U.variables.focusShadowInset, (0, U.pick)({
530
- prisma: (0, Se.css)([ "background:", ";" ], U.variables.interactiveColorOverlayHover)
531
- }), (0, U.pick)({
532
- enterprise: {
533
- light: U.variables.gray45,
534
- dark: U.variables.contentColorDisabled
535
- },
536
- prisma: U.variables.contentColorDisabled
537
- }),
538
- /* sc-sel */
539
- Ae,
540
- /* sc-sel */
541
- je,
542
- /* sc-sel */
543
- Ee, (0, U.pick)({
544
- prisma: U.variables.contentColorDisabled,
545
- enterprise: U.variables.gray80
546
- }), (0, U.pick)({
547
- prisma: (0, Se.css)([ "& > * > ", "{color:", ";}" ],
548
- /* sc-sel */
549
- Me, U.variables.contentColorDisabled)
550
- }), (function(e) {
551
- var t = e.$selected;
552
- return t && (0, U.pick)({
553
- prisma: (0, Se.css)([ "", "{color:", ";}" ],
554
- /* sc-sel */
555
- Me, U.variables.contentColorActive)
556
- });
557
- }));
558
- var Pe = we()(Ie()).withConfig({
559
- displayName: "ItemStyles__StyledSwitch",
560
- componentId: "sc-4kc053-5"
561
- })([ "position:absolute;left:", ";top:", ";" ], (0, U.pick)({
562
- prisma: "16px",
563
- enterprise: "8px"
564
- }), (0, U.pick)({
565
- prisma: "0px",
566
- enterprise: {
567
- comfortable: "-1px",
568
- compact: "2px"
569
- }
570
- }));
571
- var Ve = we().span.withConfig({
572
- displayName: "ItemStyles__StyledInnerWrapper",
573
- componentId: "sc-4kc053-6"
574
- })([ "display:flex;align-items:flex-start;" ]);
575
- var Re = we().span.withConfig({
576
- displayName: "ItemStyles__StyledTitleAndDescriptionWrapper",
577
- componentId: "sc-4kc053-7"
578
- })([ "display:flex;flex-wrap:wrap;flex-direction:column;max-width:100%;width:100%;align-self:center;word-break:break-word;white-space:normal;", "" ], (function(e) {
579
- var t = e.$truncate;
580
- return t && (0, Se.css)([ "white-space:nowrap;overflow:hidden;text-overflow:ellipsis;" ]);
581
- }));
582
- var De = we().div.withConfig({
583
- displayName: "ItemStyles__StyledLabel",
584
- componentId: "sc-4kc053-8"
585
- })([ "overflow:inherit;white-space:inherit;text-overflow:inherit;max-width:100%;min-height:20px;", "" ], (function(e) {
586
- var t = e.$truncate;
587
- return t && (0, Se.css)([ "display:block;clear:both;" ]);
588
- }));
589
- var Le = we().span.withConfig({
590
- displayName: "ItemStyles__StyledMatch",
591
- componentId: "sc-4kc053-9"
592
- })([ "border-bottom:1px solid ", ";" ], (0, U.pick)({
593
- prisma: U.variables.contentColorActive,
594
- enterprise: {
595
- dark: U.variables.gray96,
596
- light: U.variables.gray45
597
- }
598
- }));
599
- var qe = we().span.withConfig({
600
- displayName: "ItemStyles__StyledSubmenu",
601
- componentId: "sc-4kc053-10"
602
- })([ "float:right;padding-left:", ";color:", ";", "" ], U.variables.spacingSmall, (0,
603
- U.pick)({
604
- prisma: "inherit",
605
- enterprise: U.variables.textGray
606
- }), (0, U.pick)({
607
- prisma: (0, Se.css)([ "& > svg{width:20px;height:20px;}" ])
608
- }));
609
- // CONCATENATED MODULE: ./src/Select/SelectAllOptionStyles.ts
610
- var Ne = we()(De).withConfig({
611
- displayName: "SelectAllOptionStyles__StyledSelectAllLabel",
612
- componentId: "y6bn08-0"
613
- })([ "font-weight:", ";" ], U.variables.fontWeightBold);
614
- var Be = we()(Oe).withConfig({
615
- displayName: "SelectAllOptionStyles__StyledSelectAllOption",
616
- componentId: "y6bn08-1"
617
- })([ "padding-inline-start:", ";box-shadow:none;" ], (0, U.pick)({
618
- prisma: "42px;",
619
- enterprise: "32px;"
620
- }));
409
+ be(we, "propTypes", ge);
410
+ be(we, "defaultProps", Oe);
411
+ be(we, "type", M.Item);
412
+ /* harmony default export */ const Se = we;
621
413
  // CONCATENATED MODULE: ./src/Select/SelectAllOption.tsx
622
- var Ke = {
623
- active: i().bool,
624
- elementRef: i().oneOfType([ i().func, i().object ]),
625
- id: i().string,
626
- onClick: i().func,
627
- selectAllLabel: i().string,
628
- totalCount: i().number,
629
- changedToggle: i().bool,
630
- selected: i().oneOf([ false, true, "some" ])
414
+ var Ce = {
415
+ active: l().bool,
416
+ elementRef: l().oneOfType([ l().func, l().object ]),
417
+ id: l().string,
418
+ onClick: l().func,
419
+ selectAllLabel: l().string,
420
+ totalCount: l().number,
421
+ changedToggle: l().bool,
422
+ selected: l().oneOf([ false, true, "some" ])
631
423
  };
632
- var Fe = r().forwardRef((function(e, t) {
633
- var n = e.active, o = e.id, i = e.onClick, a = e.selectAllLabel, l = e.totalCount, s = e.changedToggle, u = e.selected;
424
+ var xe = r().forwardRef((function(e, t) {
425
+ var n = e.active, o = e.id, l = e.onClick, i = e.selectAllLabel, a = e.totalCount, u = e.changedToggle, c = e.selected;
634
426
  // When toggle is changed the total count is not displayed anymore so the count is now shown in the Select all menu item
635
- var p = s ? " (".concat(l === null || l === void 0 ? void 0 : l.toString(), ")") : "";
427
+ var s = u ? " (".concat(a === null || a === void 0 ? void 0 : a.toString(), ")") : "";
636
428
 
637
- return r().createElement(Be, {
638
- label: a,
429
+ return r().createElement(Se, {
430
+ label: i,
639
431
  value: "selectAll",
640
432
  key: "selectAll",
641
- onClick: i,
433
+ onClick: l,
642
434
  "data-test": "select-all",
643
435
  "aria-keyshortcuts": "Control+A",
644
436
  id: o,
645
437
  active: n,
646
438
  ref: t,
647
- tabIndex: -1
648
- }, r().createElement(Pe, {
649
- interactive: false,
650
- selected: u === "some" && "some" || u,
651
- key: "main-checkbox",
652
- value: "main-checkbox",
653
- appearance: "checkbox",
654
- "aria-label": !u && (0, c._)("No options selected") || u === "some" && (0, c._)("Some options selected") || (0,
655
- c._)("All options selected"),
656
- "data-test": "select-all-switch",
657
- selectedLabel: u === true ? (0, c._)("All options selected") : (0, c._)("Option selected"),
658
- unselectedLabel: u === true ? (0, c._)("No options selected") : (0, c._)("Option unselected"),
659
- someSelectedLabel: (0, c._)("Some options selected")
660
- }), r().createElement(je, {
661
- "data-test": "description"
662
- }, "".concat(p, " Ctrl-a")), r().createElement(Ve, null, r().createElement(Re, {
663
- $truncate: false
664
- }, r().createElement(Ne, {
665
- $truncate: false
666
- }, a))));
439
+ tabIndex: -1,
440
+ selected: c,
441
+ description: "".concat(s, " Ctrl-a"),
442
+ descriptionPosition: "right",
443
+ multiple: true,
444
+ role: "menuitemcheckbox"
445
+ });
667
446
  }));
668
- Fe.propTypes = Ke;
669
- /* harmony default export */ const He = Fe;
447
+ xe.propTypes = Ce;
448
+ /* harmony default export */ const ke = xe;
449
+ // CONCATENATED MODULE: external "styled-components"
450
+ const je = require("styled-components");
451
+ var Pe = e.n(je);
670
452
  // CONCATENATED MODULE: external "@splunk/react-ui/Button"
671
- const $e = require("@splunk/react-ui/Button");
672
- var ze = e.n($e);
453
+ const Ee = require("@splunk/react-ui/Button");
454
+ var Ie = e.n(Ee);
673
455
  // CONCATENATED MODULE: ./src/Select/SelectBaseStyles.ts
674
- var We = we()(ze()).withConfig({
456
+ var Te = Pe()(Ie()).withConfig({
675
457
  displayName: "SelectBaseStyles__StyledButton",
676
458
  componentId: "sc-16cj7sk-0"
677
459
  })([ "&[data-inline]{width:", ";}", "" ], (function(e) {
@@ -681,22 +463,22 @@
681
463
  var t = e.$multiple;
682
464
  return !t && "flex-grow: 0;";
683
465
  }));
684
- var Ue = we().span.withConfig({
466
+ var Ae = Pe().span.withConfig({
685
467
  displayName: "SelectBaseStyles__StyledLinkIcon",
686
468
  componentId: "sc-16cj7sk-1"
687
469
  })([ "padding-right:2px;" ]);
688
- var Ge = we().span.withConfig({
470
+ var Me = Pe().span.withConfig({
689
471
  displayName: "SelectBaseStyles__StyledLinkCaret",
690
472
  componentId: "sc-16cj7sk-2"
691
473
  })([ "padding-left:2px;" ]);
692
- var Je = we().div.withConfig({
474
+ var _e = Pe().div.withConfig({
693
475
  displayName: "SelectBaseStyles__StyledFilter",
694
476
  componentId: "sc-16cj7sk-3"
695
477
  })([ "padding:", ";min-width:160px;" ], (0, U.pick)({
696
478
  enterprise: "8px",
697
479
  prisma: "10px 16px"
698
480
  }));
699
- var Xe = we().span.withConfig({
481
+ var Ve = Pe().span.withConfig({
700
482
  displayName: "SelectBaseStyles__StyledSearchIconWrapper",
701
483
  componentId: "sc-16cj7sk-4"
702
484
  })([ "color:", ";pointer-events:none;padding:", ";" ], (0, U.pick)({
@@ -709,18 +491,18 @@
709
491
  comfortable: "0 8px",
710
492
  compact: "0 6px"
711
493
  }));
712
- var Ye = we().span.withConfig({
494
+ var qe = Pe().span.withConfig({
713
495
  displayName: "SelectBaseStyles__StyledCount",
714
496
  componentId: "sc-16cj7sk-5"
715
497
  })([ "padding-right:", ";" ], U.variables.spacingXSmall);
716
- var Qe = we()(q()).withConfig({
498
+ var Re = Pe()(D()).withConfig({
717
499
  displayName: "SelectBaseStyles__StyledControlsLink",
718
500
  componentId: "sc-16cj7sk-6"
719
501
  })([ "margin-right:20px;", ";" ], (function(e) {
720
502
  var t = e.$disabled;
721
- return t && (0, Se.css)([ "color:", ";" ], U.variables.contentColorDisabled);
503
+ return t && (0, je.css)([ "color:", ";" ], U.variables.contentColorDisabled);
722
504
  }));
723
- var Ze = we().div.withConfig({
505
+ var Le = Pe().div.withConfig({
724
506
  displayName: "SelectBaseStyles__StyledToggleAllControls",
725
507
  componentId: "sc-16cj7sk-7"
726
508
  })([ "padding:", ";", "" ], (0, U.pick)({
@@ -728,54 +510,54 @@
728
510
  prisma: "10px 16px"
729
511
  }), (0, U.pickVariant)("$placement", {
730
512
  above: {
731
- enterprise: (0, Se.css)([ "border-top:", ";" ], U.variables.border),
732
- prisma: (0, Se.css)([ "border-top:1px solid ", ";" ], U.variables.neutral200)
513
+ enterprise: (0, je.css)([ "border-top:", ";" ], U.variables.border),
514
+ prisma: (0, je.css)([ "border-top:1px solid ", ";" ], U.variables.neutral200)
733
515
  },
734
516
  below: {
735
- enterprise: (0, Se.css)([ "border-bottom:", ";" ], U.variables.border),
736
- prisma: (0, Se.css)([ "border-bottom:1px solid ", ";" ], U.variables.neutral200)
517
+ enterprise: (0, je.css)([ "border-bottom:", ";" ], U.variables.border),
518
+ prisma: (0, je.css)([ "border-bottom:1px solid ", ";" ], U.variables.neutral200)
737
519
  }
738
520
  }));
739
521
  // CONCATENATED MODULE: ./src/utils/fuzzyMatch.ts
740
522
  // A utility for matching keyboard characters to list values
741
- var et = function e(t, n) {
523
+ var De = function e(t, n) {
742
524
  return t ? t.label.charAt(n).toLowerCase() : "";
743
525
  };
744
- var tt = function e(t, n) {
526
+ var Be = function e(t, n) {
745
527
  if (!t.length) {
746
528
  return t;
747
529
  }
748
530
  var r = null;
749
531
  var o = false;
750
- var i = t.filter((function(e) {
751
- var t = et(e, n.index);
532
+ var l = t.filter((function(e) {
533
+ var t = De(e, n.index);
752
534
  if (t === n.value) {
753
535
  o = true;
754
536
  return true;
755
537
  }
756
- // If we haven't found a match yet, keep track of the next closest match.
538
+ // If we haven't found a match yet, keep track of the next closest match.
757
539
  // Secondary matching looks for the closest character of a higher value, and failing that, closest of a lower value.
758
540
  if (!o) {
759
- var i = et(r, n.index);
760
- if (!i) {
541
+ var l = De(r, n.index);
542
+ if (!l) {
761
543
  r = e;
762
544
  } else if (t > n.value) {
763
- if (i < n.value) {
545
+ if (l < n.value) {
764
546
  r = e;
765
- } else if (i > t) {
547
+ } else if (l > t) {
766
548
  r = e;
767
549
  }
768
- } else if (t > i) {
550
+ } else if (t > l) {
769
551
  r = e;
770
552
  }
771
553
  }
772
554
  return false;
773
555
  }));
774
- return i.length === 0 && r ? [ r ] : i;
556
+ return l.length === 0 && r ? [ r ] : l;
775
557
  };
776
558
  // CONCATENATED MODULE: ./src/utils/ssrDocument.ts
777
559
  /* eslint-disable @typescript-eslint/no-empty-function */
778
- var nt = {
560
+ var Ke = {
779
561
  body: {
780
562
  appendChild: function e() {
781
563
  return [];
@@ -829,14 +611,14 @@
829
611
  search: ""
830
612
  }
831
613
  };
832
- function rt() {
833
- var e = typeof document !== "undefined" ? document : nt;
614
+ function Ne() {
615
+ var e = typeof document !== "undefined" ? document : Ke;
834
616
  return e;
835
617
  }
836
618
  // CONCATENATED MODULE: ./src/utils/ssrWindow.ts
837
619
  /* eslint-disable @typescript-eslint/no-empty-function */
838
- var ot = {
839
- document: nt,
620
+ var Fe = {
621
+ document: Ke,
840
622
  navigator: {
841
623
  userAgent: ""
842
624
  },
@@ -890,267 +672,243 @@
890
672
  clearTimeout(t);
891
673
  }
892
674
  };
893
- function it() {
894
- var e = typeof window !== "undefined" ? window : ot;
675
+ function He() {
676
+ var e = typeof window !== "undefined" ? window : Fe;
895
677
  return e;
896
678
  }
897
679
  // CONCATENATED MODULE: ./src/Select/SelectBase.tsx
898
- function at() {
899
- at = Object.assign || function(e) {
680
+ function ze() {
681
+ return ze = Object.assign ? Object.assign.bind() : function(e) {
900
682
  for (var t = 1; t < arguments.length; t++) {
901
683
  var n = arguments[t];
902
684
  for (var r in n) {
903
- if (Object.prototype.hasOwnProperty.call(n, r)) {
904
- e[r] = n[r];
905
- }
685
+ ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
906
686
  }
907
687
  }
908
688
  return e;
909
- };
910
- return at.apply(this, arguments);
689
+ }, ze.apply(null, arguments);
911
690
  }
912
- function lt(e, t) {
913
- return ut(e) || st(e, t) || dt(e, t) || ct();
691
+ function $e(e, t) {
692
+ return Je(e) || Ue(e, t) || Qe(e, t) || We();
914
693
  }
915
- function ct() {
694
+ function We() {
916
695
  throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
917
696
  }
918
- function st(e, t) {
919
- if (typeof Symbol === "undefined" || !(Symbol.iterator in Object(e))) return;
920
- var n = [];
921
- var r = true;
922
- var o = false;
923
- var i = undefined;
924
- try {
925
- for (var a = e[Symbol.iterator](), l; !(r = (l = a.next()).done); r = true) {
926
- n.push(l.value);
927
- if (t && n.length === t) break;
928
- }
929
- } catch (e) {
930
- o = true;
931
- i = e;
932
- } finally {
697
+ function Ue(e, t) {
698
+ var n = null == e ? null : "undefined" != typeof Symbol && e[Symbol.iterator] || e["@@iterator"];
699
+ if (null != n) {
700
+ var r, o, l, i, a = [], u = !0, c = !1;
933
701
  try {
934
- if (!r && a["return"] != null) a["return"]();
702
+ if (l = (n = n.call(e)).next, 0 === t) {
703
+ if (Object(n) !== n) return;
704
+ u = !1;
705
+ } else for (;!(u = (r = l.call(n)).done) && (a.push(r.value), a.length !== t); u = !0) {
706
+ }
707
+ } catch (e) {
708
+ c = !0, o = e;
935
709
  } finally {
936
- if (o) throw i;
710
+ try {
711
+ if (!u && null != n["return"] && (i = n["return"](), Object(i) !== i)) return;
712
+ } finally {
713
+ if (c) throw o;
714
+ }
937
715
  }
716
+ return a;
938
717
  }
939
- return n;
940
718
  }
941
- function ut(e) {
719
+ function Je(e) {
942
720
  if (Array.isArray(e)) return e;
943
721
  }
944
- function pt(e) {
945
- return ht(e) || vt(e) || dt(e) || ft();
722
+ function Xe(e) {
723
+ return Ze(e) || Ye(e) || Qe(e) || Ge();
946
724
  }
947
- function ft() {
725
+ function Ge() {
948
726
  throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
949
727
  }
950
- function dt(e, t) {
951
- if (!e) return;
952
- if (typeof e === "string") return bt(e, t);
953
- var n = Object.prototype.toString.call(e).slice(8, -1);
954
- if (n === "Object" && e.constructor) n = e.constructor.name;
955
- if (n === "Map" || n === "Set") return Array.from(e);
956
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return bt(e, t);
728
+ function Qe(e, t) {
729
+ if (e) {
730
+ if ("string" == typeof e) return et(e, t);
731
+ var n = {}.toString.call(e).slice(8, -1);
732
+ return "Object" === n && e.constructor && (n = e.constructor.name), "Map" === n || "Set" === n ? Array.from(e) : "Arguments" === n || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? et(e, t) : void 0;
733
+ }
957
734
  }
958
- function vt(e) {
959
- if (typeof Symbol !== "undefined" && Symbol.iterator in Object(e)) return Array.from(e);
735
+ function Ye(e) {
736
+ if ("undefined" != typeof Symbol && null != e[Symbol.iterator] || null != e["@@iterator"]) return Array.from(e);
960
737
  }
961
- function ht(e) {
962
- if (Array.isArray(e)) return bt(e);
738
+ function Ze(e) {
739
+ if (Array.isArray(e)) return et(e);
963
740
  }
964
- function bt(e, t) {
965
- if (t == null || t > e.length) t = e.length;
966
- for (var n = 0, r = new Array(t); n < t; n++) {
741
+ function et(e, t) {
742
+ (null == t || t > e.length) && (t = e.length);
743
+ for (var n = 0, r = Array(t); n < t; n++) {
967
744
  r[n] = e[n];
968
745
  }
969
746
  return r;
970
747
  }
971
- function mt(e, t) {
972
- if (!(e instanceof t)) {
973
- throw new TypeError("Cannot call a class as a function");
974
- }
748
+ function tt(e, t) {
749
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
975
750
  }
976
- function yt(e, t) {
751
+ function nt(e, t) {
977
752
  for (var n = 0; n < t.length; n++) {
978
753
  var r = t[n];
979
- r.enumerable = r.enumerable || false;
980
- r.configurable = true;
981
- if ("value" in r) r.writable = true;
982
- Object.defineProperty(e, r.key, r);
754
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0),
755
+ Object.defineProperty(e, ht(r.key), r);
983
756
  }
984
757
  }
985
- function gt(e, t, n) {
986
- if (t) yt(e.prototype, t);
987
- if (n) yt(e, n);
988
- return e;
758
+ function rt(e, t, n) {
759
+ return t && nt(e.prototype, t), n && nt(e, n), Object.defineProperty(e, "prototype", {
760
+ writable: !1
761
+ }), e;
989
762
  }
990
- function Ot(e, t) {
991
- if (typeof t !== "function" && t !== null) {
992
- throw new TypeError("Super expression must either be null or a function");
993
- }
763
+ function ot(e, t) {
764
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
994
765
  e.prototype = Object.create(t && t.prototype, {
995
766
  constructor: {
996
767
  value: e,
997
- writable: true,
998
- configurable: true
768
+ writable: !0,
769
+ configurable: !0
999
770
  }
1000
- });
1001
- if (t) St(e, t);
1002
- }
1003
- function St(e, t) {
1004
- St = Object.setPrototypeOf || function e(t, n) {
1005
- t.__proto__ = n;
1006
- return t;
1007
- };
1008
- return St(e, t);
771
+ }), Object.defineProperty(e, "prototype", {
772
+ writable: !1
773
+ }), t && lt(e, t);
1009
774
  }
1010
- function wt(e) {
1011
- var t = kt();
1012
- return function n() {
1013
- var r = It(e), o;
775
+ function lt(e, t) {
776
+ return lt = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
777
+ return e.__proto__ = t, e;
778
+ }, lt(e, t);
779
+ }
780
+ function it(e) {
781
+ var t = ct();
782
+ return function() {
783
+ var n, r = st(e);
1014
784
  if (t) {
1015
- var i = It(this).constructor;
1016
- o = Reflect.construct(r, arguments, i);
1017
- } else {
1018
- o = r.apply(this, arguments);
1019
- }
1020
- return xt(this, o);
785
+ var o = st(this).constructor;
786
+ n = Reflect.construct(r, arguments, o);
787
+ } else n = r.apply(this, arguments);
788
+ return at(this, n);
1021
789
  };
1022
790
  }
1023
- function xt(e, t) {
1024
- if (t && (_t(t) === "object" || typeof t === "function")) {
1025
- return t;
1026
- }
1027
- return Ct(e);
791
+ function at(e, t) {
792
+ if (t && ("object" == pt(t) || "function" == typeof t)) return t;
793
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
794
+ return ut(e);
1028
795
  }
1029
- function Ct(e) {
1030
- if (e === void 0) {
1031
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
1032
- }
796
+ function ut(e) {
797
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
1033
798
  return e;
1034
799
  }
1035
- function kt() {
1036
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
1037
- if (Reflect.construct.sham) return false;
1038
- if (typeof Proxy === "function") return true;
800
+ function ct() {
1039
801
  try {
1040
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
1041
- return true;
1042
- } catch (e) {
1043
- return false;
1044
- }
802
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
803
+ } catch (e) {}
804
+ return (ct = function t() {
805
+ return !!e;
806
+ })();
1045
807
  }
1046
- function It(e) {
1047
- It = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
1048
- return t.__proto__ || Object.getPrototypeOf(t);
1049
- };
1050
- return It(e);
808
+ function st(e) {
809
+ return st = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
810
+ return e.__proto__ || Object.getPrototypeOf(e);
811
+ }, st(e);
1051
812
  }
1052
- function _t(e) {
813
+ function pt(e) {
1053
814
  "@babel/helpers - typeof";
1054
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
1055
- _t = function e(t) {
1056
- return typeof t;
1057
- };
1058
- } else {
1059
- _t = function e(t) {
1060
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
1061
- };
1062
- }
1063
- return _t(e);
815
+ return pt = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
816
+ return typeof e;
817
+ } : function(e) {
818
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
819
+ }, pt(e);
1064
820
  }
1065
- function At(e, t) {
821
+ function ft(e, t) {
1066
822
  var n = Object.keys(e);
1067
823
  if (Object.getOwnPropertySymbols) {
1068
824
  var r = Object.getOwnPropertySymbols(e);
1069
- if (t) r = r.filter((function(t) {
825
+ t && (r = r.filter((function(t) {
1070
826
  return Object.getOwnPropertyDescriptor(e, t).enumerable;
1071
- }));
1072
- n.push.apply(n, r);
827
+ }))), n.push.apply(n, r);
1073
828
  }
1074
829
  return n;
1075
830
  }
1076
- function jt(e) {
831
+ function dt(e) {
1077
832
  for (var t = 1; t < arguments.length; t++) {
1078
- var n = arguments[t] != null ? arguments[t] : {};
1079
- if (t % 2) {
1080
- At(Object(n), true).forEach((function(t) {
1081
- Et(e, t, n[t]);
1082
- }));
1083
- } else if (Object.getOwnPropertyDescriptors) {
1084
- Object.defineProperties(e, Object.getOwnPropertyDescriptors(n));
1085
- } else {
1086
- At(Object(n)).forEach((function(t) {
1087
- Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
1088
- }));
1089
- }
833
+ var n = null != arguments[t] ? arguments[t] : {};
834
+ t % 2 ? ft(Object(n), !0).forEach((function(t) {
835
+ vt(e, t, n[t]);
836
+ })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : ft(Object(n)).forEach((function(t) {
837
+ Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
838
+ }));
1090
839
  }
1091
840
  return e;
1092
841
  }
1093
- function Et(e, t, n) {
1094
- if (t in e) {
1095
- Object.defineProperty(e, t, {
1096
- value: n,
1097
- enumerable: true,
1098
- configurable: true,
1099
- writable: true
1100
- });
1101
- } else {
1102
- e[t] = n;
1103
- }
1104
- return e;
842
+ function vt(e, t, n) {
843
+ return (t = ht(t)) in e ? Object.defineProperty(e, t, {
844
+ value: n,
845
+ enumerable: !0,
846
+ configurable: !0,
847
+ writable: !0
848
+ }) : e[t] = n, e;
1105
849
  }
1106
- var Mt = {
1107
- allowKeyMatching: i().bool,
1108
- allowNewValues: i().bool,
1109
- animateLoading: i().bool,
1110
- appearance: i().oneOf([ "default", "link", "primary", "pill", "toggle", "flat", "subtle" ]),
1111
- append: i().bool,
1112
- children: i().node,
1113
- defaultPlacement: i().oneOf([ "above", "below", "vertical" ]),
1114
- defaultValues: i().array,
1115
- describedBy: i().string,
1116
- disabled: i().bool,
1117
- elementRef: i().oneOfType([ i().func, i().object ]),
1118
- error: i().bool,
1119
- filter: i().oneOf([ false, true, "controlled" ]),
1120
- footerMessage: i().node,
1121
- inline: i().bool,
1122
- inputId: i().string,
1123
- inputRef: i().oneOfType([ i().func, i().object ]),
1124
- isLoadingOptions: i().bool,
1125
- labelledBy: i().string,
1126
- labelText: i().string,
1127
- loadingMessage: i().node,
1128
- menuStyle: i().object,
1129
- multiple: i().bool,
1130
- name: i().string,
1131
- noOptionsMessage: i().node,
1132
- onChange: i().func,
1133
- onClose: i().func,
1134
- onFilterChange: i().func,
1135
- onOpen: i().func,
1136
- onScroll: i().func,
1137
- onScrollBottom: i().func,
850
+ function ht(e) {
851
+ var t = bt(e, "string");
852
+ return "symbol" == pt(t) ? t : t + "";
853
+ }
854
+ function bt(e, t) {
855
+ if ("object" != pt(e) || !e) return e;
856
+ var n = e[Symbol.toPrimitive];
857
+ if (void 0 !== n) {
858
+ var r = n.call(e, t || "default");
859
+ if ("object" != pt(r)) return r;
860
+ throw new TypeError("@@toPrimitive must return a primitive value.");
861
+ }
862
+ return ("string" === t ? String : Number)(e);
863
+ }
864
+ var yt = {
865
+ allowKeyMatching: l().bool,
866
+ allowNewValues: l().bool,
867
+ animateLoading: l().bool,
868
+ appearance: l().oneOf([ "default", "link", "primary", "pill", "toggle", "flat", "subtle" ]),
869
+ append: l().bool,
870
+ children: l().node,
871
+ defaultPlacement: l().oneOf([ "above", "below", "vertical" ]),
872
+ defaultValues: l().array,
873
+ describedBy: l().string,
874
+ disabled: l().bool,
875
+ elementRef: l().oneOfType([ l().func, l().object ]),
876
+ error: l().bool,
877
+ filter: l().oneOf([ false, true, "controlled" ]),
878
+ footerMessage: l().node,
879
+ inline: l().bool,
880
+ inputId: l().string,
881
+ inputRef: l().oneOfType([ l().func, l().object ]),
882
+ isLoadingOptions: l().bool,
883
+ labelledBy: l().string,
884
+ labelText: l().string,
885
+ loadingMessage: l().node,
886
+ menuStyle: l().object,
887
+ multiple: l().bool,
888
+ name: l().string,
889
+ noOptionsMessage: l().node,
890
+ onChange: l().func,
891
+ onClose: l().func,
892
+ onFilterChange: l().func,
893
+ onOpen: l().func,
894
+ onScroll: l().func,
895
+ onScrollBottom: l().func,
1138
896
  /** @private. */
1139
- required: i().bool,
1140
- placeholder: i().string,
1141
- prefixLabel: i().string,
1142
- prepend: i().bool,
1143
- repositionMode: i().oneOf([ "none", "flip" ]),
1144
- selectAllAppearance: i().oneOf([ "buttongroup", "checkbox" ]),
1145
- showSelectedValuesFirst: i().oneOf([ "nextOpen", "immediately", "never" ]),
1146
- suffixLabel: i().string,
1147
- tabConfirmsNewValue: i().bool,
1148
- toggleContent: i().oneOf([ "optionChildren", "optionLabel" ]),
1149
- values: i().array,
897
+ required: l().bool,
898
+ placeholder: l().string,
899
+ prefixLabel: l().string,
900
+ prepend: l().bool,
901
+ repositionMode: l().oneOf([ "none", "flip" ]),
902
+ selectAllAppearance: l().oneOf([ "buttongroup", "checkbox" ]),
903
+ showSelectedValuesFirst: l().oneOf([ "nextOpen", "immediately", "never" ]),
904
+ suffixLabel: l().string,
905
+ tabConfirmsNewValue: l().bool,
906
+ toggleContent: l().oneOf([ "optionChildren", "optionLabel" ]),
907
+ values: l().array,
1150
908
  /** @private. */
1151
- virtualization: i().number
909
+ virtualization: l().number
1152
910
  };
1153
- var Tt = {
911
+ var mt = {
1154
912
  allowKeyMatching: true,
1155
913
  allowNewValues: false,
1156
914
  animateLoading: false,
@@ -1163,40 +921,40 @@
1163
921
  isLoadingOptions: false,
1164
922
  menuStyle: {},
1165
923
  multiple: false,
1166
- noOptionsMessage: (0, c._)("No matches"),
1167
- placeholder: (0, c._)("Select..."),
924
+ noOptionsMessage: (0, u._)("No matches"),
925
+ placeholder: (0, u._)("Select..."),
1168
926
  prepend: false,
1169
927
  repositionMode: "flip",
1170
928
  selectAllAppearance: "buttongroup",
1171
929
  tabConfirmsNewValue: false,
1172
930
  toggleContent: "optionChildren"
1173
931
  };
1174
- var Pt = w()((function(e) {
932
+ var gt = S()((function(e) {
1175
933
  return [ e ];
1176
934
  }));
1177
- // preserve separate widths for single vs. multi mode
1178
- var Vt = w()((function(e) {
935
+ // preserve separate widths for single vs. multi mode
936
+ var Ot = S()((function(e) {
1179
937
  var t = e.anchorWidth, n = e.isMultiple, r = e.maxHeight, o = e.menuStyle;
1180
- return n ? jt({
938
+ return n ? dt({
1181
939
  width: Math.max(t !== null && t !== void 0 ? t : 0, 200),
1182
940
  maxHeight: r
1183
- }, o) : jt({
941
+ }, o) : dt({
1184
942
  minWidth: t !== null && t !== void 0 ? t : undefined,
1185
943
  maxWidth: Math.max(t !== null && t !== void 0 ? t : 0, 300),
1186
944
  maxHeight: r
1187
945
  }, o);
1188
946
  }));
1189
- var Rt = [ "clickAway", "escapeKey", "offScreen", "tabKey", "toggleClick" ];
1190
- function Dt(e) {
1191
- return e && l()(e.props, "value");
947
+ var wt = [ "clickAway", "escapeKey", "offScreen", "tabKey", "toggleClick" ];
948
+ function St(e) {
949
+ return e && a()(e.props, "value");
1192
950
  }
1193
- function Lt(e, t) {
1194
- return "".concat(_t(e), "-").concat(e, "-").concat(t);
951
+ function Ct(e, t) {
952
+ return "".concat(pt(e), "-").concat(e, "-").concat(t);
1195
953
  }
1196
- var qt = function(e) {
1197
- Ot(o, e);
1198
- var t = wt(o);
1199
- gt(o, null, [ {
954
+ var xt = function(e) {
955
+ ot(o, e);
956
+ var t = it(o);
957
+ rt(o, null, [ {
1200
958
  key: "validateAppearance",
1201
959
  // @docs-props-type CompactPropsBase
1202
960
  value: function e(t) {
@@ -1204,601 +962,602 @@
1204
962
  }
1205
963
  } ]);
1206
964
  function o(e) {
1207
- var i;
1208
- mt(this, o);
1209
- i = t.call(this, e);
1210
- Et(Ct(i), "activeItemId", void 0);
1211
- Et(Ct(i), "activeValue", void 0);
1212
- Et(Ct(i), "availableOptionCount", void 0);
1213
- Et(Ct(i), "controlledExternally", void 0);
1214
- Et(Ct(i), "displayedValues", void 0);
1215
- Et(Ct(i), "dropdown", null);
1216
- Et(Ct(i), "firstSelectedEnabledOption", null);
1217
- Et(Ct(i), "firstSelectedOptionIndex", void 0);
1218
- Et(Ct(i), "menuListboxId", void 0);
1219
- Et(Ct(i), "previousActiveIndex", null);
1220
- Et(Ct(i), "selectedOptionCount", void 0);
1221
- Et(Ct(i), "optionRefsByKey", void 0);
1222
- Et(Ct(i), "matchCharacter", void 0);
1223
- Et(Ct(i), "matchTimeout", void 0);
1224
- Et(Ct(i), "currentMatchOptions", void 0);
1225
- Et(Ct(i), "availableMatchOptions", void 0);
1226
- Et(Ct(i), "optionSelection", void 0);
1227
- Et(Ct(i), "resetMatches", (function() {
1228
- i.matchCharacter = null;
1229
- i.currentMatchOptions = [];
1230
- if (i.matchTimeout) {
1231
- clearTimeout(i.matchTimeout);
965
+ var l;
966
+ tt(this, o);
967
+ l = t.call(this, e);
968
+ vt(ut(l), "activeItemId", void 0);
969
+ vt(ut(l), "activeValue", void 0);
970
+ vt(ut(l), "availableOptionCount", void 0);
971
+ vt(ut(l), "controlledExternally", void 0);
972
+ vt(ut(l), "displayedValues", void 0);
973
+ vt(ut(l), "dropdown", null);
974
+ vt(ut(l), "firstSelectedEnabledOption", null);
975
+ vt(ut(l), "firstSelectedOptionIndex", void 0);
976
+ vt(ut(l), "menuListboxId", void 0);
977
+ vt(ut(l), "previousActiveIndex", null);
978
+ vt(ut(l), "selectedOptionCount", void 0);
979
+ vt(ut(l), "optionRefsByKey", void 0);
980
+ vt(ut(l), "matchCharacter", void 0);
981
+ vt(ut(l), "matchTimeout", void 0);
982
+ vt(ut(l), "currentMatchOptions", void 0);
983
+ vt(ut(l), "availableMatchOptions", void 0);
984
+ vt(ut(l), "optionSelection", void 0);
985
+ vt(ut(l), "resetMatches", (function() {
986
+ l.matchCharacter = null;
987
+ l.currentMatchOptions = [];
988
+ if (l.matchTimeout) {
989
+ clearTimeout(l.matchTimeout);
1232
990
  }
1233
991
  }));
1234
- Et(Ct(i), "handleSelectAll", (function(e) {
992
+ vt(ut(l), "handleSelectAll", (function(e) {
1235
993
  var t, n, o;
1236
- var a = i.props, l = a.name, c = a.children, s = a.multiple;
994
+ var i = l.props, a = i.name, u = i.children, c = i.multiple;
1237
995
  // this doesn't make sense if we can't select multiple values
1238
- if (!s) {
996
+ if (!c) {
1239
997
  return;
1240
998
  }
1241
- var u = (t = i.getCurrentValues()) !== null && t !== void 0 ? t : [];
1242
- var p = A()(u.concat(i.displayedValues));
1243
- p = r().Children.toArray(c).filter((function(e) {
1244
- return Dt(e) && b()(p, e.props.value) && (!e.props.disabled || b()(u, e.props.value));
999
+ var s = (t = l.getCurrentValues()) !== null && t !== void 0 ? t : [];
1000
+ var p = E()(s.concat(l.displayedValues));
1001
+ p = r().Children.toArray(u).filter((function(e) {
1002
+ return St(e) && b()(p, e.props.value) && (!e.props.disabled || b()(s, e.props.value));
1245
1003
  })).map((function(e) {
1246
1004
  return e.props.value;
1247
1005
  }));
1248
- if (!i.isControlled()) {
1249
- i.setState({
1006
+ if (!l.isControlled()) {
1007
+ l.setState({
1250
1008
  values: p
1251
1009
  });
1252
1010
  }
1253
- (n = (o = i.props).onChange) === null || n === void 0 ? void 0 : n.call(o, e, {
1011
+ (n = (o = l.props).onChange) === null || n === void 0 ? void 0 : n.call(o, e, {
1254
1012
  values: p,
1255
- name: l,
1013
+ name: a,
1256
1014
  reason: "selectAll"
1257
1015
  });
1258
1016
  }));
1259
- Et(Ct(i), "handleClearAll", (function(e) {
1017
+ vt(ut(l), "handleClearAll", (function(e) {
1260
1018
  var t, n, o;
1261
- var a = i.props, l = a.name, c = a.children, s = a.multiple;
1019
+ var i = l.props, a = i.name, u = i.children, c = i.multiple;
1262
1020
  // this doesn't make sense if we can't select multiple values
1263
- if (!s) {
1021
+ if (!c) {
1264
1022
  return;
1265
1023
  }
1266
- var u = (t = i.getCurrentValues()) !== null && t !== void 0 ? t : [];
1267
- var p = E().apply(void 0, [ u ].concat(pt(i.displayedValues)));
1268
- // this will unselect all selected values unless those values are disabled or hidden by the filter
1269
- var f = r().Children.toArray(c).filter((function(e) {
1270
- return Dt(e) && (b()(u, e.props.value) && e.props.disabled || b()(p, e.props.value));
1024
+ var s = (t = l.getCurrentValues()) !== null && t !== void 0 ? t : [];
1025
+ var p = T().apply(void 0, [ s ].concat(Xe(l.displayedValues)));
1026
+ // this will unselect all selected values unless those values are disabled or hidden by the filter
1027
+ var f = r().Children.toArray(u).filter((function(e) {
1028
+ return St(e) && (b()(s, e.props.value) && e.props.disabled || b()(p, e.props.value));
1271
1029
  })).map((function(e) {
1272
1030
  return e.props.value;
1273
1031
  }));
1274
- if (!i.isControlled()) {
1275
- i.setState({
1032
+ if (!l.isControlled()) {
1033
+ l.setState({
1276
1034
  values: f
1277
1035
  });
1278
1036
  }
1279
- (n = (o = i.props).onChange) === null || n === void 0 ? void 0 : n.call(o, e, {
1037
+ (n = (o = l.props).onChange) === null || n === void 0 ? void 0 : n.call(o, e, {
1280
1038
  values: f,
1281
- name: l,
1039
+ name: a,
1282
1040
  reason: "clearAll"
1283
1041
  });
1284
1042
  }));
1285
- Et(Ct(i), "handleTextKeyDown", (function(e) {
1286
- var t = i.props, r = t.children, o = t.onScrollBottom, a = t.tabConfirmsNewValue;
1287
- var l = (0, R.keycode)(e.nativeEvent);
1288
- if (l === "tab") {
1289
- if (a && !y()(i.activeValue) && i.availableOptionCount <= 1) {
1043
+ vt(ut(l), "handleTextKeyDown", (function(e) {
1044
+ var t = l.props, r = t.children, o = t.onScrollBottom, i = t.tabConfirmsNewValue;
1045
+ var a = (0, q.keycode)(e.nativeEvent);
1046
+ if (a === "tab") {
1047
+ if (i && !m()(l.activeValue) && l.availableOptionCount <= 1) {
1290
1048
  e.preventDefault();
1291
- i.toggleValue(e, i.activeValue);
1049
+ l.toggleValue(e, l.activeValue);
1292
1050
  }
1293
1051
  }
1294
1052
  if (e.shiftKey || e.metaKey || e.ctrlKey) {
1295
- if (l === "a" && (e.ctrlKey || e.metaKey)) {
1053
+ if (a === "a" && (e.ctrlKey || e.metaKey)) {
1296
1054
  // handle control + A
1297
- if (i.optionSelection === "all") {
1298
- i.handleClearAll(e);
1055
+ if (l.optionSelection === "all") {
1056
+ l.handleClearAll(e);
1299
1057
  } else {
1300
- i.handleSelectAll(e);
1058
+ l.handleSelectAll(e);
1301
1059
  }
1302
1060
  }
1303
1061
  return;
1304
1062
  }
1305
- if (l === "down") {
1063
+ if (a === "down") {
1306
1064
  e.preventDefault();
1307
- i.setState((function(e) {
1065
+ l.setState((function(e) {
1308
1066
  return {
1309
- activeIndex: Math.min(e.activeIndex + 1, i.props.selectAllAppearance === "checkbox" ? i.availableOptionCount : i.availableOptionCount - 1)
1067
+ activeIndex: Math.min(e.activeIndex + 1, l.props.selectAllAppearance === "checkbox" ? l.availableOptionCount : l.availableOptionCount - 1)
1310
1068
  };
1311
1069
  }));
1312
1070
  if (r && o) {
1313
- var c;
1314
- var s = n.Children.toArray(r).length - (2 + ((c = i.getCurrentValues()) !== null && c !== void 0 ? c : []).length);
1315
- if (i.state.activeIndex === s) {
1316
- i.handleScrollBottom(e);
1071
+ var u;
1072
+ var c = n.Children.toArray(r).length - (2 + ((u = l.getCurrentValues()) !== null && u !== void 0 ? u : []).length);
1073
+ if (l.state.activeIndex === c) {
1074
+ l.handleScrollBottom(e);
1317
1075
  }
1318
1076
  }
1319
1077
  }
1320
- if (l === "up") {
1078
+ if (a === "up") {
1321
1079
  e.preventDefault();
1322
- i.setState((function(e) {
1080
+ l.setState((function(e) {
1323
1081
  return {
1324
1082
  activeIndex: Math.max(e.activeIndex - 1, 0)
1325
1083
  };
1326
1084
  }));
1327
1085
  }
1328
- if (l === "enter" && !y()(i.activeValue) && i.state.open) {
1329
- if (i.activeValue === "selectAll") {
1330
- if (i.optionSelection === "all") {
1331
- i.handleClearAll(e);
1086
+ if (a === "enter" && !m()(l.activeValue) && l.state.open) {
1087
+ if (l.activeValue === "selectAll") {
1088
+ if (l.optionSelection === "all") {
1089
+ l.handleClearAll(e);
1332
1090
  } else {
1333
- i.handleSelectAll(e);
1091
+ l.handleSelectAll(e);
1334
1092
  }
1335
1093
  } else {
1336
1094
  e.preventDefault();
1337
- i.toggleValue(e, i.activeValue);
1095
+ l.toggleValue(e, l.activeValue);
1338
1096
  }
1339
1097
  }
1340
1098
  }));
1341
- Et(Ct(i), "handleMenuOptionClick", (function(e, t) {
1099
+ vt(ut(l), "handleMenuOptionClick", (function(e, t) {
1342
1100
  var n = t.value;
1343
1101
  e.preventDefault();
1344
- if (!i.state.open) {
1102
+ if (!l.state.open) {
1345
1103
  return;
1346
1104
  }
1347
- i.toggleValue(e, n);
1105
+ l.toggleValue(e, n);
1348
1106
  }));
1349
- Et(Ct(i), "handleMenuOptionKeyDown", (function(e, t) {
1107
+ vt(ut(l), "handleMenuOptionKeyDown", (function(e, t) {
1350
1108
  var n = e.nativeEvent.key;
1351
- // Checking for a single character to avoid complications from double-byte languages and emojis.
1109
+ // Checking for a single character to avoid complications from double-byte languages and emojis.
1352
1110
  if (n.length === 1) {
1353
1111
  var r = [];
1354
1112
  var o = {
1355
1113
  index: 0,
1356
1114
  value: n
1357
1115
  };
1358
- if (!i.matchCharacter) {
1116
+ if (!l.matchCharacter) {
1359
1117
  if (n === " ") {
1360
- i.resetMatches();
1118
+ l.resetMatches();
1361
1119
  return;
1362
1120
  }
1363
- r = tt(i.availableMatchOptions, o);
1364
- } else if (i.currentMatchOptions.length > 1) {
1365
- o.index = i.matchCharacter.index + 1;
1366
- r = tt(i.currentMatchOptions, o);
1121
+ r = Be(l.availableMatchOptions, o);
1122
+ } else if (l.currentMatchOptions.length > 1) {
1123
+ o.index = l.matchCharacter.index + 1;
1124
+ r = Be(l.currentMatchOptions, o);
1367
1125
  }
1368
1126
  if (r.length) {
1369
- var a = 0;
1370
- // If the active option is a first character match, cycle to the next matching option.
1127
+ var i = 0;
1128
+ // If the active option is a first character match, cycle to the next matching option.
1371
1129
  if (o.index === 0 && r.length > 1) {
1372
- var l = r.indexOf(i.availableMatchOptions[t]);
1373
- if (l >= 0) {
1374
- a = l === r.length - 1 ? 0 : l + 1;
1130
+ var a = r.indexOf(l.availableMatchOptions[t]);
1131
+ if (a >= 0) {
1132
+ i = a === r.length - 1 ? 0 : a + 1;
1375
1133
  }
1376
1134
  }
1377
- var c = r[a];
1378
- var s = i.optionRefsByKey[Lt(c.value, c.label)];
1379
- if (s != null) {
1380
- var u;
1381
- (u = s.focus) === null || u === void 0 ? void 0 : u.call(s);
1135
+ var u = r[i];
1136
+ var c = l.optionRefsByKey[Ct(u.value, u.label)];
1137
+ if (c != null) {
1138
+ var s;
1139
+ (s = c.focus) === null || s === void 0 ? void 0 : s.call(c);
1382
1140
  }
1383
1141
  }
1384
- i.currentMatchOptions = r;
1385
- i.matchCharacter = o;
1386
- if (i.matchTimeout) {
1387
- clearTimeout(i.matchTimeout);
1142
+ l.currentMatchOptions = r;
1143
+ l.matchCharacter = o;
1144
+ if (l.matchTimeout) {
1145
+ clearTimeout(l.matchTimeout);
1388
1146
  }
1389
- i.matchTimeout = setTimeout(i.resetMatches, 500);
1147
+ l.matchTimeout = setTimeout(l.resetMatches, 500);
1390
1148
  e.preventDefault();
1391
1149
  e.stopPropagation();
1392
1150
  }
1393
1151
  }));
1394
- Et(Ct(i), "handleTextChange", (function(e, t) {
1152
+ vt(ut(l), "handleTextChange", (function(e, t) {
1395
1153
  var n, r;
1396
1154
  var o = t.value;
1397
- i.setState({
1155
+ l.setState({
1398
1156
  filterKeyword: o,
1399
1157
  open: true,
1400
1158
  activeIndex: 0
1401
1159
  });
1402
- (n = (r = i.props).onFilterChange) === null || n === void 0 ? void 0 : n.call(r, e, {
1160
+ (n = (r = l.props).onFilterChange) === null || n === void 0 ? void 0 : n.call(r, e, {
1403
1161
  keyword: o
1404
1162
  });
1405
1163
  }));
1406
- Et(Ct(i), "handleTextFocus", (function() {
1407
- i.setState({
1164
+ vt(ut(l), "handleTextFocus", (function() {
1165
+ l.setState({
1408
1166
  textHasFocus: true
1409
1167
  });
1410
1168
  }));
1411
- Et(Ct(i), "handleTextBlur", (function() {
1412
- i.setState({
1169
+ vt(ut(l), "handleTextBlur", (function() {
1170
+ l.setState({
1413
1171
  textHasFocus: false
1414
1172
  });
1415
1173
  }));
1416
- Et(Ct(i), "handleRequestOpen", (function(e) {
1174
+ vt(ut(l), "handleRequestOpen", (function(e) {
1417
1175
  var t = {
1418
1176
  open: true,
1419
- topValues: i.getTopValues()
1177
+ topValues: l.getTopValues()
1420
1178
  };
1421
- // SUI-3234: preserve existing behavior difference between <Select> and <Multiselect.Compact>
1422
- if (i.props.multiple) {
1179
+ // SUI-3234: preserve existing behavior difference between <Select> and <Multiselect.Compact>
1180
+ if (l.props.multiple) {
1423
1181
  t.filterKeyword = "";
1424
1182
  }
1425
- var n = i.state.filterKeyword;
1426
- i.setState(t, (function() {
1183
+ var n = l.state.filterKeyword;
1184
+ l.setState(t, (function() {
1427
1185
  var t, r;
1428
- (t = (r = i.props).onOpen) === null || t === void 0 ? void 0 : t.call(r);
1429
- if (i.firstSelectedEnabledOption && !i.hasFilter()) {
1430
- i.firstSelectedEnabledOption.focus();
1186
+ (t = (r = l.props).onOpen) === null || t === void 0 ? void 0 : t.call(r);
1187
+ if (l.firstSelectedEnabledOption && !l.hasFilter()) {
1188
+ l.firstSelectedEnabledOption.focus();
1431
1189
  } else {
1432
1190
  var o;
1433
- i.setState({
1434
- activeIndex: (o = i.firstSelectedOptionIndex) !== null && o !== void 0 ? o : 0
1191
+ l.setState({
1192
+ activeIndex: (o = l.firstSelectedOptionIndex) !== null && o !== void 0 ? o : 0
1435
1193
  });
1436
1194
  }
1437
- if (n !== i.state.filterKeyword) {
1438
- var a, l;
1439
- (a = (l = i.props).onFilterChange) === null || a === void 0 ? void 0 : a.call(l, e, {
1440
- keyword: i.state.filterKeyword
1195
+ if (n !== l.state.filterKeyword) {
1196
+ var i, a;
1197
+ (i = (a = l.props).onFilterChange) === null || i === void 0 ? void 0 : i.call(a, e, {
1198
+ keyword: l.state.filterKeyword
1441
1199
  });
1442
1200
  }
1443
1201
  }));
1444
1202
  }));
1445
- Et(Ct(i), "handleRequestClose", (function() {
1446
- i.setState({
1203
+ vt(ut(l), "handleRequestClose", (function() {
1204
+ l.setState({
1447
1205
  open: false,
1448
1206
  activeIndex: 0
1449
1207
  }, (function() {
1450
1208
  var e, t;
1451
- i.previousActiveIndex = null;
1452
- (e = (t = i.props).onClose) === null || e === void 0 ? void 0 : e.call(t);
1209
+ l.previousActiveIndex = null;
1210
+ (e = (t = l.props).onClose) === null || e === void 0 ? void 0 : e.call(t);
1453
1211
  }));
1454
1212
  }));
1455
- Et(Ct(i), "handleScrollBottom", (function(e) {
1456
- if (i.state.open && !i.props.isLoadingOptions) {
1213
+ vt(ut(l), "handleScrollBottom", (function(e) {
1214
+ if (l.state.open && !l.props.isLoadingOptions) {
1457
1215
  var t, n;
1458
- (t = (n = i.props).onScrollBottom) === null || t === void 0 ? void 0 : t.call(n, e);
1216
+ (t = (n = l.props).onScrollBottom) === null || t === void 0 ? void 0 : t.call(n, e);
1459
1217
  }
1460
1218
  }));
1461
- Et(Ct(i), "handleActiveOptionMount", (function(e) {
1462
- if (i.previousActiveIndex !== i.state.activeIndex) {
1219
+ vt(ut(l), "handleActiveOptionMount", (function(e) {
1220
+ if (l.previousActiveIndex !== l.state.activeIndex) {
1463
1221
  e === null || e === void 0 ? void 0 : e.scrollIntoViewIfNeeded();
1464
1222
  }
1465
1223
  }));
1466
- Et(Ct(i), "handleOptionMount", (function(e, t, n) {
1224
+ vt(ut(l), "handleOptionMount", (function(e, t, n) {
1467
1225
  if (n) {
1468
- i.firstSelectedEnabledOption = e;
1226
+ l.firstSelectedEnabledOption = e;
1469
1227
  }
1470
1228
  if (e == null) {
1471
- delete i.optionRefsByKey[t];
1229
+ delete l.optionRefsByKey[t];
1472
1230
  } else {
1473
- i.optionRefsByKey[t] = e;
1231
+ l.optionRefsByKey[t] = e;
1474
1232
  }
1475
1233
  }));
1476
- Et(Ct(i), "createToggle", (function() {
1234
+ vt(ut(l), "createToggle", (function() {
1477
1235
  var e;
1478
- var t = i.props, a = t.toggle, l = t.appearance, s = t.children, u = t.describedBy, p = t.disabled, d = t.elementRef, v = t.error, h = t.inline, b = t.labelledBy, m = t.labelText, y = t.multiple, g = t.placeholder, S = t.prefixLabel, w = t.required, x = t.suffixLabel, k = t.toggleContent;
1479
- var _;
1480
- var A;
1481
- var j = [];
1482
- // Generate buttonLabels
1483
- var E = (e = i.getCurrentValues()) !== null && e !== void 0 ? e : [];
1484
- var M = n.Children.toArray(s);
1485
- var T = E.reduce((function(e, t, n, r) {
1486
- var o = f()(M, (function(e) {
1487
- return Dt(e) && e.props.value === t;
1236
+ var t = l.props, i = t.toggle, a = t.appearance, c = t.children, s = t.describedBy, p = t.disabled, d = t.elementRef, v = t.error, h = t.inline, b = t.labelledBy, y = t.labelText, m = t.multiple, g = t.placeholder, w = t.prefixLabel, S = t.required, C = t.suffixLabel, k = t.toggleContent;
1237
+ var P;
1238
+ var E;
1239
+ var I = [];
1240
+ // Generate buttonLabels
1241
+ var T = (e = l.getCurrentValues()) !== null && e !== void 0 ? e : [];
1242
+ var A = n.Children.toArray(c);
1243
+ var M = T.reduce((function(e, t, n, r) {
1244
+ var o = f()(A, (function(e) {
1245
+ return St(e) && e.props.value === t;
1488
1246
  }));
1489
1247
  if (o) {
1490
- var i = k !== "optionLabel" && o.props.children ? o.props.children : o.props.label;
1491
- e.push(i);
1492
- j.push(o.props.label);
1493
- // if not in multiple mode, add the icon
1494
- if (!y && E.length === 1) {
1495
- _ = o.props.icon;
1248
+ var l = k !== "optionLabel" && o.props.children ? o.props.children : o.props.label;
1249
+ e.push(l);
1250
+ I.push(o.props.label);
1251
+ // if not in multiple mode, add the icon
1252
+ if (!m && T.length === 1) {
1253
+ P = o.props.icon;
1496
1254
  }
1497
- } else if (y) {
1255
+ } else if (m) {
1498
1256
  // only add values that don't match an option in "multiple" mode to preserve old behaviour
1499
1257
  e.push(t);
1500
- j.push(t.toString());
1258
+ I.push(t.toString());
1501
1259
  }
1502
1260
  if (n < r.length - 1) {
1503
- e.push((0, c._)(", "));
1504
- j.push((0, c._)(", "));
1261
+ e.push((0, u._)(", "));
1262
+ I.push((0, u._)(", "));
1505
1263
  }
1506
1264
  return e;
1507
1265
  }), []);
1508
- A = T;
1509
- // only apply prefix / suffix if the label is not empty
1510
- if (A.length > 0) {
1266
+ E = M;
1267
+ // only apply prefix / suffix if the label is not empty
1268
+ if (E.length > 0) {
1511
1269
  // If there's more than one item selected, read out the selected total
1512
1270
  // rather than reading out each selected item
1513
- j = i.wrapLabel({
1514
- prefixLabel: S,
1515
- label: A.length > 1 ? [ "".concat(E.length, " items selected") ] : j,
1516
- suffixLabel: x
1271
+ I = l.wrapLabel({
1272
+ prefixLabel: w,
1273
+ label: E.length > 1 ? [ "".concat(T.length, " items selected") ] : I,
1274
+ suffixLabel: C
1517
1275
  });
1518
- A = i.wrapLabel({
1519
- prefixLabel: S,
1520
- label: A,
1521
- suffixLabel: x
1276
+ E = l.wrapLabel({
1277
+ prefixLabel: w,
1278
+ label: E,
1279
+ suffixLabel: C
1522
1280
  });
1523
1281
  }
1524
- // single <Select> behaviour is to show the placeholder if all parts of the label
1282
+ // single <Select> behaviour is to show the placeholder if all parts of the label
1525
1283
  // are empty strings so we replicate this behaviour here
1526
- if (A.length === 0 || !y && A.every((function(e) {
1284
+ if (E.length === 0 || !m && E.every((function(e) {
1527
1285
  return e === "";
1528
1286
  }))) {
1529
- A = Pt(g);
1530
- j = A;
1287
+ E = gt(g);
1288
+ I = E;
1531
1289
  }
1532
- var P = jt({
1533
- "aria-describedby": u,
1534
- "aria-label": "".concat(m ? "".concat(m, ", ") : "").concat(j.join("")),
1535
- "aria-labelledby": m ? undefined : b,
1536
- "aria-required": w,
1537
- "data-select-appearance": l,
1538
- "data-test": y ? "multiselect" : "select",
1290
+ var _ = dt({
1291
+ "aria-describedby": s,
1292
+ "aria-label": "".concat(y ? "".concat(y, ", ") : "").concat(I.join("")),
1293
+ "aria-labelledby": b,
1294
+ // aria-labelledby takes precedence over aria-label if exists
1295
+ "aria-required": S,
1296
+ "data-select-appearance": a,
1297
+ "data-test": m ? "multiselect" : "select",
1539
1298
  role: "combobox",
1540
1299
  disabled: p,
1541
1300
  elementRef: d,
1542
1301
  error: v
1543
- }, C()(i.props, O()(o.propTypes)));
1544
- if (y) {
1545
- P["data-test-values"] = JSON.stringify(E);
1302
+ }, x()(l.props, O()(o.propTypes)));
1303
+ if (m) {
1304
+ _["data-test-values"] = JSON.stringify(T);
1546
1305
  } else {
1547
- var V = lt(E, 1), R = V[0];
1548
- P["data-test-value"] = R;
1306
+ var V = $e(T, 1), q = V[0];
1307
+ _["data-test-value"] = q;
1549
1308
  }
1550
- if (a) {
1309
+ if (i) {
1551
1310
 
1552
- return (0, n.cloneElement)(a, P);
1311
+ return (0, n.cloneElement)(i, _);
1553
1312
  }
1554
- if (l === "link") {
1313
+ if (a === "link") {
1555
1314
 
1556
- return r().createElement(q(), at({}, P, {
1315
+ return r().createElement(D(), ze({}, _, {
1557
1316
  "data-select-appearance": "link"
1558
- }), !!_ && r().createElement(Ue, null, _), A || g, r().createElement(Ge, null, r().createElement(J, null)));
1317
+ }), !!P && r().createElement(Ae, null, P), E || g, r().createElement(Me, null, r().createElement(X, null)));
1559
1318
  }
1560
1319
 
1561
- return r().createElement(We, at({}, P, {
1562
- $multiple: y,
1563
- appearance: l,
1564
- label: A,
1320
+ return r().createElement(Te, ze({}, _, {
1321
+ $multiple: m,
1322
+ appearance: a,
1323
+ label: E,
1565
1324
  error: v,
1566
- icon: _,
1325
+ icon: P,
1567
1326
  inline: h,
1568
1327
  isMenu: true,
1569
- onClick: i.props.onClick
1570
- }, I()(i.props, o.invalidLinkAppearanceProps)), !!E.length && y && r().createElement(Ye, {
1328
+ onClick: l.props.onClick
1329
+ }, j()(l.props, o.invalidLinkAppearanceProps)), !!T.length && m && r().createElement(qe, {
1571
1330
  "data-role": "count"
1572
- }, "(", E.length, ")"));
1331
+ }, "(", T.length, ")"));
1573
1332
  }));
1574
- Et(Ct(i), "createChildren", (function() {
1575
- var e = i.state, t = e.filterKeyword, o = e.textHasFocus, a = e.topValues;
1576
- var l = i.props, s = l.allowKeyMatching, u = l.allowNewValues, p = l.filter, d = l.multiple, h = l.selectAllAppearance, b = l.showSelectedValuesFirst, m = l.isLoadingOptions, y = l.onScrollBottom;
1577
- var g = i.getCurrentValues();
1578
- i.availableOptionCount = 0;
1579
- i.firstSelectedOptionIndex = undefined;
1580
- i.selectedOptionCount = 0;
1581
- i.activeValue = undefined;
1582
- i.availableMatchOptions = [];
1333
+ vt(ut(l), "createChildren", (function() {
1334
+ var e = l.state, t = e.filterKeyword, o = e.textHasFocus, i = e.topValues;
1335
+ var a = l.props, c = a.allowKeyMatching, s = a.allowNewValues, p = a.filter, d = a.multiple, h = a.selectAllAppearance, b = a.showSelectedValuesFirst, y = a.isLoadingOptions, m = a.onScrollBottom;
1336
+ var g = l.getCurrentValues();
1337
+ l.availableOptionCount = 0;
1338
+ l.firstSelectedOptionIndex = undefined;
1339
+ l.selectedOptionCount = 0;
1340
+ l.activeValue = undefined;
1341
+ l.availableMatchOptions = [];
1583
1342
  var O;
1584
- var S = 0;
1585
- var w = false;
1586
- // used to avoid overwriting the selected item ref in multiple mode
1587
- var x;
1588
- var C = b === "immediately" ? i.getTopValues() : a;
1589
- var k = n.Children.toArray(i.props.children).reduce((function(e, t, o) {
1343
+ var w = 0;
1344
+ var S = false;
1345
+ // used to avoid overwriting the selected item ref in multiple mode
1346
+ var C;
1347
+ var x = b === "immediately" ? l.getTopValues() : i;
1348
+ var k = n.Children.toArray(l.props.children).reduce((function(e, t, o) {
1590
1349
  // ignore Headings and Dividers
1591
- if (!Dt(t)) {
1350
+ if (!St(t)) {
1592
1351
  e.push(t);
1593
1352
  return e;
1594
1353
  }
1595
- // Find out if the search string exactly matches a value
1596
- if (t.props.value === i.state.filterKeyword) {
1354
+ // Find out if the search string exactly matches a value
1355
+ if (t.props.value === l.state.filterKeyword) {
1597
1356
  O = true;
1598
1357
  }
1599
- var a = g && g.indexOf(t.props.value) >= 0;
1600
- var l = !!a && !t.props.disabled && !x;
1601
- var c = s && !d && !p && !m && !y;
1602
- var u = Lt(t.props.value, t.props.label);
1358
+ var i = g && g.indexOf(t.props.value) >= 0;
1359
+ var a = !!i && !t.props.disabled && !C;
1360
+ var u = c && !d && !p && !y && !m;
1361
+ var s = Ct(t.props.value, t.props.label);
1603
1362
  var f = -1;
1604
- if (c && !t.props.disabled && !t.props.hidden) {
1605
- i.availableMatchOptions.push({
1363
+ if (u && !t.props.disabled && !t.props.hidden) {
1364
+ l.availableMatchOptions.push({
1606
1365
  label: t.props.label,
1607
1366
  value: t.props.value
1608
1367
  });
1609
- f = i.availableMatchOptions.length - 1;
1368
+ f = l.availableMatchOptions.length - 1;
1610
1369
  }
1611
- // Format the Menu.Item
1370
+ // Format the Menu.Item
1612
1371
  var v = (0, n.cloneElement)(t, {
1613
1372
  key: t.key || o,
1614
- onClick: i.handleMenuOptionClick,
1615
- onKeyDown: c ? function(e) {
1616
- return i.handleMenuOptionKeyDown(e, f);
1373
+ onClick: l.handleMenuOptionClick,
1374
+ onKeyDown: u ? function(e) {
1375
+ return l.handleMenuOptionKeyDown(e, f);
1617
1376
  } : undefined,
1618
- selected: a,
1377
+ selected: i,
1619
1378
  multiple: d,
1620
1379
  role: "option",
1621
1380
  ref: function e(t) {
1622
- return i.handleOptionMount(t, u, l);
1381
+ return l.handleOptionMount(t, s, a);
1623
1382
  }
1624
1383
  });
1625
- if (l) {
1626
- x = true;
1384
+ if (a) {
1385
+ C = true;
1627
1386
  }
1628
- if (C && C.indexOf(t.props.value) >= 0) {
1629
- if (S === 0) {
1630
- e.splice(S, 0, r().createElement(T.Divider, {
1387
+ if (x && x.indexOf(t.props.value) >= 0) {
1388
+ if (w === 0) {
1389
+ e.splice(w, 0, r().createElement(M.Divider, {
1631
1390
  key: "topDivider"
1632
1391
  }));
1633
- w = true;
1392
+ S = true;
1634
1393
  }
1635
- e.splice(S, 0, v);
1636
- S += 1;
1394
+ e.splice(w, 0, v);
1395
+ w += 1;
1637
1396
  } else {
1638
1397
  e.push(v);
1639
1398
  }
1640
1399
  return e;
1641
1400
  }), []);
1642
- // In multiple mode, add missing items
1401
+ // In multiple mode, add missing items
1643
1402
  if (d) {
1644
1403
  v()(g, (function(e) {
1645
1404
  var t = f()(k, (function(t) {
1646
- return Dt(t) && t.props && t.props.value === e;
1405
+ return St(t) && t.props && t.props.value === e;
1647
1406
  }));
1648
1407
  if (!t) {
1649
- if (e === i.state.filterKeyword) {
1408
+ if (e === l.state.filterKeyword) {
1650
1409
  O = true;
1651
1410
  }
1652
- var n = C && C.indexOf(e) >= 0;
1653
- var o = C.length;
1654
- if (S === 0) {
1655
- k.splice(0, 0, r().createElement(T.Divider, {
1411
+ var n = x && x.indexOf(e) >= 0;
1412
+ var o = x.length;
1413
+ if (w === 0) {
1414
+ k.splice(0, 0, r().createElement(M.Divider, {
1656
1415
  key: "topDivider"
1657
1416
  }));
1658
- S += 1;
1659
- w = true;
1417
+ w += 1;
1418
+ S = true;
1660
1419
  }
1661
- k.splice(n ? 0 : o + 1, 0, r().createElement(Oe, {
1420
+ k.splice(n ? 0 : o + 1, 0, r().createElement(Se, {
1662
1421
  label: String(e),
1663
1422
  value: e,
1664
1423
  key: "missing-value-".concat(e),
1665
- onClick: i.handleMenuOptionClick,
1424
+ onClick: l.handleMenuOptionClick,
1666
1425
  multiple: d,
1667
1426
  selected: true
1668
1427
  }));
1669
1428
  if (n) {
1670
- S += 1;
1429
+ w += 1;
1671
1430
  }
1672
1431
  }
1673
1432
  }));
1674
1433
  }
1675
- var I = p === "controlled";
1676
- // Filter the items
1677
- var _ = (0, D.stringToKeywords)(t);
1678
- k = I ? k : k.filter((function(e) {
1679
- if (Dt(e)) {
1680
- return (0, D.testPhrase)(e.props.label, _);
1434
+ var j = p === "controlled";
1435
+ // Filter the items
1436
+ var P = (0, R.stringToKeywords)(t);
1437
+ k = j ? k : k.filter((function(e) {
1438
+ if (St(e)) {
1439
+ return (0, R.testPhrase)(e.props.label, P);
1681
1440
  }
1682
1441
  return true;
1683
1442
  // Keep all headers and non-interactive options
1684
1443
  })).map((function(e) {
1685
- if (!Dt(e)) {
1444
+ if (!St(e)) {
1686
1445
  return e;
1687
1446
  }
1688
- // highlight matched text
1689
- var t = _ && (0, D.keywordLocations)(e.props.label, _);
1447
+ // highlight matched text
1448
+ var t = P && (0, R.keywordLocations)(e.props.label, P);
1690
1449
 
1691
1450
  return (0, n.cloneElement)(e, {
1692
1451
  matchRanges: t || undefined
1693
1452
  });
1694
1453
  }));
1695
- // Add the option to add the new value
1696
- if (u && !O && t) {
1697
- var A = w ? S + 1 : S;
1698
- k.splice(A, 0, r().createElement(Oe, {
1454
+ // Add the option to add the new value
1455
+ if (s && !O && t) {
1456
+ var E = S ? w + 1 : w;
1457
+ k.splice(E, 0, r().createElement(Se, {
1699
1458
  label: "".concat(t, " (new value)"),
1700
1459
  value: t,
1701
1460
  key: "newValue",
1702
1461
  multiple: d,
1703
- onClick: i.handleMenuOptionClick
1462
+ onClick: l.handleMenuOptionClick
1704
1463
  }));
1705
1464
  }
1706
- // When selectAll is a menu item, add an offset so that activeItem accounts for the extra selectAll option.
1707
- var j = h === "checkbox" && d && k.length > 1 ? 1 : 0;
1708
- var E = true;
1709
- // Highlight the selected Items and remove hidden
1465
+ // When selectAll is a menu item, add an offset so that activeItem accounts for the extra selectAll option.
1466
+ var I = h === "checkbox" && d && k.length > 1 ? 1 : 0;
1467
+ var T = true;
1468
+ // Highlight the selected Items and remove hidden
1710
1469
  k = k.reduce((function(e, t) {
1711
1470
  // ignore Dividers & Headings
1712
- if (!Dt(t)) {
1471
+ if (!St(t)) {
1713
1472
  e.push(t);
1714
1473
  return e;
1715
1474
  }
1716
- // Ignore any hidden items
1475
+ // Ignore any hidden items
1717
1476
  if (t.props && t.props.hidden) {
1718
1477
  return e;
1719
1478
  }
1720
- if (t.props.selected && !t.props.disabled && i.firstSelectedOptionIndex == null) {
1721
- i.firstSelectedOptionIndex = i.availableOptionCount;
1479
+ if (t.props.selected && !t.props.disabled && l.firstSelectedOptionIndex == null) {
1480
+ l.firstSelectedOptionIndex = l.availableOptionCount;
1722
1481
  }
1723
- var r = j === i.state.activeIndex;
1724
- j += 1;
1725
- i.availableOptionCount += 1;
1726
- i.selectedOptionCount += t.props.selected ? 1 : 0;
1482
+ var r = I === l.state.activeIndex;
1483
+ I += 1;
1484
+ l.availableOptionCount += 1;
1485
+ l.selectedOptionCount += t.props.selected ? 1 : 0;
1727
1486
  if (t.key !== "newValue" && !t.props.disabled && !t.props.selected) {
1728
- E = false;
1487
+ T = false;
1729
1488
  }
1730
1489
  if (!r || !o) {
1731
1490
  e.push(t);
1732
1491
  return e;
1733
1492
  }
1734
1493
  if (!t.props.disabled) {
1735
- i.activeValue = t.props.value;
1494
+ l.activeValue = t.props.value;
1736
1495
  }
1737
- var a = (0, n.cloneElement)(t, {
1496
+ var i = (0, n.cloneElement)(t, {
1738
1497
  active: r,
1739
- id: i.activeItemId,
1740
- ref: i.handleActiveOptionMount
1498
+ id: l.activeItemId,
1499
+ ref: l.handleActiveOptionMount
1741
1500
  });
1742
- e.push(a);
1501
+ e.push(i);
1743
1502
  return e;
1744
1503
  }), []);
1745
- i.optionSelection = i.selectedOptionCount === 0 && "none" || E && "all" || "some";
1746
- // add select all option
1747
- if (h === "checkbox" && d && i.availableOptionCount > 0) {
1748
- var M;
1749
- var P;
1750
- if (i.optionSelection === "all") {
1504
+ l.optionSelection = l.selectedOptionCount === 0 && "none" || T && "all" || "some";
1505
+ // add select all option
1506
+ if (h === "checkbox" && d && l.availableOptionCount > 0) {
1507
+ var A;
1508
+ var _;
1509
+ if (l.optionSelection === "all") {
1751
1510
  if (t === "") {
1752
- P = (0, c._)("Clear all");
1511
+ _ = (0, u._)("Clear all");
1753
1512
  } else {
1754
- P = (0, c._)("Clear all matches");
1513
+ _ = (0, u._)("Clear all matches");
1755
1514
  }
1756
1515
  } else if (t === "") {
1757
- P = (0, c._)("Select all");
1516
+ _ = (0, u._)("Select all");
1758
1517
  } else {
1759
- P = (0, c._)("Select all matches");
1518
+ _ = (0, u._)("Select all matches");
1760
1519
  }
1761
- if (i.state.activeIndex === 0 && o) {
1762
- i.activeValue = "selectAll";
1520
+ if (l.state.activeIndex === 0 && o) {
1521
+ l.activeValue = "selectAll";
1763
1522
  }
1764
- k.unshift( r().createElement(He, {
1523
+ k.unshift( r().createElement(ke, {
1765
1524
  key: "selectAllOption",
1766
- selected: i.optionSelection === "all" || i.optionSelection !== "none" && "some",
1767
- selectAllLabel: P,
1768
- totalCount: (M = i.getCurrentValues()) === null || M === void 0 ? void 0 : M.length,
1769
- changedToggle: !!i.props.toggle,
1770
- onClick: i.optionSelection === "all" ? i.handleClearAll : i.handleSelectAll,
1771
- id: i.state.activeIndex === 0 ? i.activeItemId : undefined,
1772
- active: i.state.activeIndex === 0,
1773
- ref: i.handleActiveOptionMount,
1525
+ selected: l.optionSelection === "all" || l.optionSelection !== "none" && "some",
1526
+ selectAllLabel: _,
1527
+ totalCount: (A = l.getCurrentValues()) === null || A === void 0 ? void 0 : A.length,
1528
+ changedToggle: !!l.props.toggle,
1529
+ onClick: l.optionSelection === "all" ? l.handleClearAll : l.handleSelectAll,
1530
+ id: l.state.activeIndex === 0 ? l.activeItemId : undefined,
1531
+ active: l.state.activeIndex === 0,
1532
+ ref: l.handleActiveOptionMount,
1774
1533
  tabIndex: -1
1775
- }), r().createElement(T.Divider, {
1534
+ }), r().createElement(M.Divider, {
1776
1535
  key: "selectAllDivider"
1777
1536
  }));
1778
1537
  }
1779
- i.displayedValues = k.reduce((function(e, t) {
1780
- if (Dt(t)) {
1538
+ l.displayedValues = k.reduce((function(e, t) {
1539
+ if (St(t)) {
1781
1540
  e.push(t.props.value);
1782
1541
  }
1783
1542
  return e;
1784
1543
  }), []);
1785
1544
  return k;
1786
1545
  }));
1787
- Et(Ct(i), "wrapLabel", (function(e) {
1546
+ vt(ut(l), "wrapLabel", (function(e) {
1788
1547
  var t = e.prefixLabel, n = e.label, r = e.suffixLabel;
1789
1548
  var o = n;
1790
1549
  if (t) {
1791
1550
  o = [ "".concat(t, ": ") ].concat(o);
1792
1551
  }
1793
1552
  if (r) {
1794
- o = u()(o).concat(" ".concat(r));
1553
+ o = s()(o).concat(" ".concat(r));
1795
1554
  }
1796
1555
  return o;
1797
1556
  }));
1798
- Et(Ct(i), "handleDropdownMount", (function(e) {
1799
- i.dropdown = e;
1557
+ vt(ut(l), "handleDropdownMount", (function(e) {
1558
+ l.dropdown = e;
1800
1559
  }));
1801
- i.state = {
1560
+ l.state = {
1802
1561
  activeIndex: 0,
1803
1562
  filterKeyword: "",
1804
1563
  open: false,
@@ -1806,25 +1565,25 @@
1806
1565
  topValues: [],
1807
1566
  values: e.defaultValues || []
1808
1567
  };
1809
- i.controlledExternally = l()(e, "values");
1810
- i.displayedValues = [];
1811
- i.availableOptionCount = 0;
1812
- i.firstSelectedOptionIndex = undefined;
1813
- i.selectedOptionCount = 0;
1814
- i.matchCharacter = null;
1815
- i.matchTimeout = null;
1816
- i.currentMatchOptions = [];
1817
- i.availableMatchOptions = [];
1818
- i.optionRefsByKey = {};
1819
- i.optionSelection = "none";
1568
+ l.controlledExternally = a()(e, "values");
1569
+ l.displayedValues = [];
1570
+ l.availableOptionCount = 0;
1571
+ l.firstSelectedOptionIndex = undefined;
1572
+ l.selectedOptionCount = 0;
1573
+ l.matchCharacter = null;
1574
+ l.matchTimeout = null;
1575
+ l.currentMatchOptions = [];
1576
+ l.availableMatchOptions = [];
1577
+ l.optionRefsByKey = {};
1578
+ l.optionSelection = "none";
1820
1579
  if (false) {}
1821
1580
  if (false) {}
1822
1581
  o.validateAppearance(e);
1823
- i.menuListboxId = (0, M.createDOMID)("menu-listbox");
1824
- i.activeItemId = (0, M.createDOMID)("active-item");
1825
- return i;
1582
+ l.menuListboxId = (0, A.createDOMID)("menu-listbox");
1583
+ l.activeItemId = (0, A.createDOMID)("active-item");
1584
+ return l;
1826
1585
  }
1827
- gt(o, [ {
1586
+ rt(o, [ {
1828
1587
  key: "componentDidUpdate",
1829
1588
  value: function e(t, n) {
1830
1589
  if (false) {}
@@ -1858,16 +1617,16 @@
1858
1617
  }, {
1859
1618
  key: "toggleValue",
1860
1619
  value: function e(t, n) {
1861
- var r, o, i;
1862
- var a = (r = this.getCurrentValues()) !== null && r !== void 0 ? r : [];
1863
- var l = a.indexOf(n);
1864
- var c = this.props, s = c.name, u = c.multiple;
1620
+ var r, o, l;
1621
+ var i = (r = this.getCurrentValues()) !== null && r !== void 0 ? r : [];
1622
+ var a = i.indexOf(n);
1623
+ var u = this.props, c = u.name, s = u.multiple;
1865
1624
  var p;
1866
- if (u) {
1867
- if (l >= 0) {
1868
- p = [].concat(pt(a.slice(0, l)), pt(a.slice(l + 1)));
1625
+ if (s) {
1626
+ if (a >= 0) {
1627
+ p = [].concat(Xe(i.slice(0, a)), Xe(i.slice(a + 1)));
1869
1628
  } else {
1870
- p = a.concat([ n ]);
1629
+ p = i.concat([ n ]);
1871
1630
  }
1872
1631
  } else {
1873
1632
  // non-multiple mode must always have a value
@@ -1879,7 +1638,7 @@
1879
1638
  values: p
1880
1639
  });
1881
1640
  }
1882
- if (u) {
1641
+ if (s) {
1883
1642
  // in uncontrolled multiple mode, keep the menu open
1884
1643
  if (f) {
1885
1644
  this.setState({
@@ -1894,9 +1653,9 @@
1894
1653
  });
1895
1654
  this.focus();
1896
1655
  }
1897
- (o = (i = this.props).onChange) === null || o === void 0 ? void 0 : o.call(i, t, {
1656
+ (o = (l = this.props).onChange) === null || o === void 0 ? void 0 : o.call(l, t, {
1898
1657
  values: p,
1899
- name: s,
1658
+ name: c,
1900
1659
  reason: "valueToggle"
1901
1660
  });
1902
1661
  }
@@ -1912,32 +1671,32 @@
1912
1671
  key: "renderControls",
1913
1672
  value: function e(t) {
1914
1673
  var n = t.hasChildren, o = t.placement;
1915
- var i = this.state.filterKeyword;
1916
- var a = this.props, l = a.inputId, s = a.inputRef, u = a.multiple, p = a.selectAllAppearance;
1917
- var f = (0, c._)("Select all options".concat(this.optionSelection === "all" ? " disabled" : ""));
1918
- var d = (0, c._)("Clear all options".concat(this.optionSelection === "none" ? " disabled" : ""));
1919
- // only visually disable these as opposed to fully disabling to avoid losing keyboard focus - see SUI-2731
1920
- var v = r().createElement(Ze, {
1674
+ var l = this.state.filterKeyword;
1675
+ var i = this.props, a = i.inputId, c = i.inputRef, s = i.multiple, p = i.selectAllAppearance;
1676
+ var f = (0, u._)("Select all options".concat(this.optionSelection === "all" ? " disabled" : ""));
1677
+ var d = (0, u._)("Clear all options".concat(this.optionSelection === "none" ? " disabled" : ""));
1678
+ // only visually disable these as opposed to fully disabling to avoid losing keyboard focus - see SUI-2731
1679
+ var v = r().createElement(Le, {
1921
1680
  $placement: o,
1922
1681
  key: "selectAll"
1923
- }, r().createElement(Qe, {
1682
+ }, r().createElement(Re, {
1924
1683
  $disabled: this.optionSelection === "all",
1925
1684
  "aria-label": f,
1926
1685
  onClick: this.handleSelectAll,
1927
1686
  "data-test": "select-all"
1928
- }, i ? (0, c._)("Select all Matches") : (0, c._)("Select all")), r().createElement(Qe, {
1687
+ }, l ? (0, u._)("Select all Matches") : (0, u._)("Select all")), r().createElement(Re, {
1929
1688
  $disabled: this.optionSelection === "none",
1930
1689
  "aria-label": d,
1931
1690
  onClick: this.handleClearAll,
1932
1691
  "data-test": "clear-all"
1933
- }, i ? (0, c._)("Clear all Matches") : (0, c._)("Clear all")));
1692
+ }, l ? (0, u._)("Clear all Matches") : (0, u._)("Clear all")));
1934
1693
  return this.hasFilter() && r().createElement("div", {
1935
1694
  key: "controls"
1936
- }, r().createElement(Je, {
1695
+ }, r().createElement(_e, {
1937
1696
  key: "filter",
1938
1697
  "data-test": "filter"
1939
1698
  }, r().createElement(F(), {
1940
- value: i,
1699
+ value: l,
1941
1700
  autoCapitalize: "off",
1942
1701
  autoComplete: "off",
1943
1702
  autoCorrect: "off",
@@ -1946,83 +1705,83 @@
1946
1705
  onKeyDown: this.handleTextKeyDown,
1947
1706
  onFocus: this.handleTextFocus,
1948
1707
  onBlur: this.handleTextBlur,
1949
- placeholder: (0, c._)("filter"),
1708
+ placeholder: (0, u._)("filter"),
1950
1709
  role: "combobox",
1951
1710
  "aria-expanded": "true",
1952
1711
  "aria-controls": this.menuListboxId,
1953
1712
  "aria-owns": n ? this.activeItemId : undefined,
1954
- "aria-label": (0, c._)("Filter"),
1713
+ "aria-label": (0, u._)("Filter"),
1955
1714
  "aria-autocomplete": "list",
1956
1715
  "aria-activedescendant": this.state.textHasFocus && n ? this.activeItemId : undefined,
1957
- inputRef: s,
1958
- inputId: l,
1716
+ inputRef: c,
1717
+ inputId: a,
1959
1718
  canClear: true,
1960
- startAdornment: r().createElement(Xe, null, r().createElement(te, null))
1961
- })), u && n && p === "buttongroup" && v);
1719
+ startAdornment: r().createElement(Ve, null, r().createElement(te, null))
1720
+ })), s && n && p === "buttongroup" && v);
1962
1721
  }
1963
1722
  }, {
1964
1723
  key: "render",
1965
1724
  value: function e() {
1966
1725
  var t, o = this;
1967
- var i = this.props, a = i.children, l = i.defaultPlacement, c = i.inputId, s = i.multiple, u = i.repositionMode, p = i.virtualization;
1726
+ var l = this.props, i = l.children, a = l.defaultPlacement, u = l.inputId, c = l.multiple, s = l.repositionMode, p = l.virtualization;
1968
1727
  var d = this.hasFilter();
1969
1728
  var v = (t = this.getCurrentValues()) !== null && t !== void 0 ? t : [];
1970
- var h = n.Children.toArray(a);
1729
+ var h = n.Children.toArray(i);
1971
1730
  var b = v.some((function(e) {
1972
1731
  var t = f()(h, (function(t) {
1973
- return Dt(t) && t.props.value === e;
1732
+ return St(t) && t.props.value === e;
1974
1733
  }));
1975
1734
  return t && !t.props.disabled;
1976
1735
  }));
1977
- var m = this.createChildren();
1978
- var y = this.createToggle();
1736
+ var y = this.createChildren();
1737
+ var m = this.createToggle();
1979
1738
  var g = function e(t) {
1980
- var n = t.anchorWidth, i = t.maxHeight, a = t.placement;
1981
- var l = Vt({
1739
+ var n = t.anchorWidth, l = t.maxHeight, i = t.placement;
1740
+ var a = Ot({
1982
1741
  anchorWidth: n,
1983
1742
  isMultiple: o.props.multiple,
1984
- maxHeight: i,
1743
+ maxHeight: l,
1985
1744
  menuStyle: o.props.menuStyle
1986
1745
  });
1987
- var c = v.length > 0 && !b && !o.hasFilter() ? 0 : undefined;
1988
- var u = jt(jt({
1989
- "aria-multiselectable": s || undefined,
1746
+ var u = v.length > 0 && !b && !o.hasFilter() ? 0 : undefined;
1747
+ var s = dt(dt({
1748
+ "aria-multiselectable": c || undefined,
1990
1749
  childrenStart: o.renderControls({
1991
- placement: a,
1992
- hasChildren: m.some((function(e) {
1993
- return Dt(e);
1750
+ placement: i,
1751
+ hasChildren: y.some((function(e) {
1752
+ return St(e);
1994
1753
  }))
1995
1754
  }),
1996
1755
  focusMode: o.hasFilter() ? "never" : undefined,
1997
1756
  isLoading: o.props.isLoadingOptions,
1998
1757
  menuId: o.menuListboxId,
1999
1758
  onScrollBottom: o.props.onScrollBottom ? o.handleScrollBottom : undefined,
2000
- placement: a !== null && a !== void 0 ? a : undefined
2001
- }, I()(o.props, "noOptionsMessage", "footerMessage", "animateLoading", "loadingMessage", "onScroll")), {}, {
2002
- style: l,
2003
- tabIndex: c
1759
+ placement: i !== null && i !== void 0 ? i : undefined
1760
+ }, j()(o.props, "noOptionsMessage", "footerMessage", "animateLoading", "loadingMessage", "onScroll")), {}, {
1761
+ style: a,
1762
+ tabIndex: u
2004
1763
  });
2005
1764
  if (p) {
2006
1765
 
2007
- return r().createElement(N.VirtualizedResultsMenu, at({
1766
+ return r().createElement(B.VirtualizedResultsMenu, ze({
2008
1767
  virtualization: p
2009
- }, u), m);
1768
+ }, s), y);
2010
1769
  }
2011
1770
 
2012
- return r().createElement(B(), u, m);
1771
+ return r().createElement(K(), s, y);
2013
1772
  };
2014
1773
 
2015
1774
  return r().createElement(V(), {
2016
- closeReasons: Rt,
2017
- inputId: c,
2018
- toggle: y,
1775
+ closeReasons: wt,
1776
+ inputId: u,
1777
+ toggle: m,
2019
1778
  onRequestOpen: this.handleRequestOpen,
2020
1779
  onRequestClose: this.handleRequestClose,
2021
1780
  open: this.state.open,
2022
1781
  openWithArrowKeys: true,
2023
- repositionMode: u,
2024
- defaultPlacement: d ? l : undefined,
2025
- canCoverAnchor: it().innerHeight < 500,
1782
+ repositionMode: s,
1783
+ defaultPlacement: d ? a : undefined,
1784
+ canCoverAnchor: He().innerHeight < 500,
2026
1785
  ref: this.handleDropdownMount,
2027
1786
  retainFocus: false,
2028
1787
  takeFocus: v.length === 0 || v.length > 0 && !b || d
@@ -2031,157 +1790,144 @@
2031
1790
  } ]);
2032
1791
  return o;
2033
1792
  }(n.Component);
2034
- Et(qt, "propTypes", Mt);
2035
- Et(qt, "defaultProps", Tt);
2036
- Et(qt, "Option", Oe);
2037
- Et(qt, "Divider", T.Divider);
2038
- Et(qt, "Heading", T.Heading);
2039
- Et(qt, "invalidLinkAppearanceProps", [ "append", "error", "prepend" ]);
2040
- /* harmony default export */ const Nt = qt;
1793
+ vt(xt, "propTypes", yt);
1794
+ vt(xt, "defaultProps", mt);
1795
+ vt(xt, "Option", Se);
1796
+ vt(xt, "Divider", M.Divider);
1797
+ vt(xt, "Heading", M.Heading);
1798
+ vt(xt, "invalidLinkAppearanceProps", [ "append", "error", "prepend" ]);
1799
+ /* harmony default export */ const kt = xt;
2041
1800
  // CONCATENATED MODULE: ./src/Select/Option.tsx
2042
- function Bt(e) {
1801
+ function jt(e) {
2043
1802
  "@babel/helpers - typeof";
2044
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
2045
- Bt = function e(t) {
2046
- return typeof t;
2047
- };
2048
- } else {
2049
- Bt = function e(t) {
2050
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
2051
- };
2052
- }
2053
- return Bt(e);
2054
- }
2055
- function Kt() {
2056
- Kt = Object.assign || function(e) {
1803
+ return jt = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
1804
+ return typeof e;
1805
+ } : function(e) {
1806
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
1807
+ }, jt(e);
1808
+ }
1809
+ function Pt() {
1810
+ return Pt = Object.assign ? Object.assign.bind() : function(e) {
2057
1811
  for (var t = 1; t < arguments.length; t++) {
2058
1812
  var n = arguments[t];
2059
1813
  for (var r in n) {
2060
- if (Object.prototype.hasOwnProperty.call(n, r)) {
2061
- e[r] = n[r];
2062
- }
1814
+ ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
2063
1815
  }
2064
1816
  }
2065
1817
  return e;
2066
- };
2067
- return Kt.apply(this, arguments);
1818
+ }, Pt.apply(null, arguments);
2068
1819
  }
2069
- function Ft(e, t) {
2070
- if (!(e instanceof t)) {
2071
- throw new TypeError("Cannot call a class as a function");
2072
- }
1820
+ function Et(e, t) {
1821
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
2073
1822
  }
2074
- function Ht(e, t) {
1823
+ function It(e, t) {
2075
1824
  for (var n = 0; n < t.length; n++) {
2076
1825
  var r = t[n];
2077
- r.enumerable = r.enumerable || false;
2078
- r.configurable = true;
2079
- if ("value" in r) r.writable = true;
2080
- Object.defineProperty(e, r.key, r);
1826
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0),
1827
+ Object.defineProperty(e, Bt(r.key), r);
2081
1828
  }
2082
1829
  }
2083
- function $t(e, t, n) {
2084
- if (t) Ht(e.prototype, t);
2085
- if (n) Ht(e, n);
2086
- return e;
1830
+ function Tt(e, t, n) {
1831
+ return t && It(e.prototype, t), n && It(e, n), Object.defineProperty(e, "prototype", {
1832
+ writable: !1
1833
+ }), e;
2087
1834
  }
2088
- function zt(e, t) {
2089
- if (typeof t !== "function" && t !== null) {
2090
- throw new TypeError("Super expression must either be null or a function");
2091
- }
1835
+ function At(e, t) {
1836
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
2092
1837
  e.prototype = Object.create(t && t.prototype, {
2093
1838
  constructor: {
2094
1839
  value: e,
2095
- writable: true,
2096
- configurable: true
1840
+ writable: !0,
1841
+ configurable: !0
2097
1842
  }
2098
- });
2099
- if (t) Wt(e, t);
1843
+ }), Object.defineProperty(e, "prototype", {
1844
+ writable: !1
1845
+ }), t && Mt(e, t);
2100
1846
  }
2101
- function Wt(e, t) {
2102
- Wt = Object.setPrototypeOf || function e(t, n) {
2103
- t.__proto__ = n;
2104
- return t;
2105
- };
2106
- return Wt(e, t);
1847
+ function Mt(e, t) {
1848
+ return Mt = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
1849
+ return e.__proto__ = t, e;
1850
+ }, Mt(e, t);
2107
1851
  }
2108
- function Ut(e) {
2109
- var t = Xt();
2110
- return function n() {
2111
- var r = Yt(e), o;
1852
+ function _t(e) {
1853
+ var t = Rt();
1854
+ return function() {
1855
+ var n, r = Lt(e);
2112
1856
  if (t) {
2113
- var i = Yt(this).constructor;
2114
- o = Reflect.construct(r, arguments, i);
2115
- } else {
2116
- o = r.apply(this, arguments);
2117
- }
2118
- return Gt(this, o);
1857
+ var o = Lt(this).constructor;
1858
+ n = Reflect.construct(r, arguments, o);
1859
+ } else n = r.apply(this, arguments);
1860
+ return Vt(this, n);
2119
1861
  };
2120
1862
  }
2121
- function Gt(e, t) {
2122
- if (t && (Bt(t) === "object" || typeof t === "function")) {
2123
- return t;
2124
- }
2125
- return Jt(e);
1863
+ function Vt(e, t) {
1864
+ if (t && ("object" == jt(t) || "function" == typeof t)) return t;
1865
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
1866
+ return qt(e);
2126
1867
  }
2127
- function Jt(e) {
2128
- if (e === void 0) {
2129
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
2130
- }
1868
+ function qt(e) {
1869
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
2131
1870
  return e;
2132
1871
  }
2133
- function Xt() {
2134
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
2135
- if (Reflect.construct.sham) return false;
2136
- if (typeof Proxy === "function") return true;
1872
+ function Rt() {
2137
1873
  try {
2138
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
2139
- return true;
2140
- } catch (e) {
2141
- return false;
2142
- }
1874
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
1875
+ } catch (e) {}
1876
+ return (Rt = function t() {
1877
+ return !!e;
1878
+ })();
1879
+ }
1880
+ function Lt(e) {
1881
+ return Lt = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
1882
+ return e.__proto__ || Object.getPrototypeOf(e);
1883
+ }, Lt(e);
1884
+ }
1885
+ function Dt(e, t, n) {
1886
+ return (t = Bt(t)) in e ? Object.defineProperty(e, t, {
1887
+ value: n,
1888
+ enumerable: !0,
1889
+ configurable: !0,
1890
+ writable: !0
1891
+ }) : e[t] = n, e;
2143
1892
  }
2144
- function Yt(e) {
2145
- Yt = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
2146
- return t.__proto__ || Object.getPrototypeOf(t);
2147
- };
2148
- return Yt(e);
2149
- }
2150
- function Qt(e, t, n) {
2151
- if (t in e) {
2152
- Object.defineProperty(e, t, {
2153
- value: n,
2154
- enumerable: true,
2155
- configurable: true,
2156
- writable: true
2157
- });
2158
- } else {
2159
- e[t] = n;
1893
+ function Bt(e) {
1894
+ var t = Kt(e, "string");
1895
+ return "symbol" == jt(t) ? t : t + "";
1896
+ }
1897
+ function Kt(e, t) {
1898
+ if ("object" != jt(e) || !e) return e;
1899
+ var n = e[Symbol.toPrimitive];
1900
+ if (void 0 !== n) {
1901
+ var r = n.call(e, t || "default");
1902
+ if ("object" != jt(r)) return r;
1903
+ throw new TypeError("@@toPrimitive must return a primitive value.");
2160
1904
  }
2161
- return e;
1905
+ return ("string" === t ? String : Number)(e);
2162
1906
  }
2163
- var Zt = {
1907
+ var Nt = {
2164
1908
  /** @private */
2165
- active: i().bool,
2166
- children: i().node,
2167
- description: i().string,
2168
- descriptionPosition: i().oneOf([ "right", "bottom" ]),
2169
- disabled: i().bool,
2170
- hidden: i().bool,
2171
- icon: i().node,
2172
- label: i().string.isRequired,
2173
- matchRanges: i().arrayOf(i().shape({
2174
- start: i().number.isRequired,
2175
- end: i().number.isRequired
1909
+ active: l().bool,
1910
+ children: l().node,
1911
+ description: l().string,
1912
+ descriptionPosition: l().oneOf([ "right", "bottom" ]),
1913
+ disabled: l().bool,
1914
+ hidden: l().bool,
1915
+ icon: l().node,
1916
+ label: l().string.isRequired,
1917
+ matchRanges: l().arrayOf(l().shape({
1918
+ start: l().number.isRequired,
1919
+ end: l().number.isRequired
2176
1920
  })),
2177
1921
  /** @private */
2178
- onClick: i().func,
1922
+ onClick: l().func,
2179
1923
  /** @private */
2180
- selected: i().bool,
2181
- truncate: i().bool,
2182
- value: i().oneOfType([ i().string, i().number, i().bool ]).isRequired
1924
+ role: l().oneOf([ "menuitemcheckbox", "option" ]),
1925
+ /** @private */
1926
+ selected: l().bool,
1927
+ truncate: l().bool,
1928
+ value: l().oneOfType([ l().string, l().number, l().bool ]).isRequired
2183
1929
  };
2184
- var en = {
1930
+ var Ft = {
2185
1931
  active: false,
2186
1932
  descriptionPosition: "bottom",
2187
1933
  disabled: false,
@@ -2193,31 +1939,35 @@
2193
1939
  * An option within a `Select`. This inherits from
2194
1940
  * [PureComponent](https://reactjs.org/docs/react-api.html#reactpurecomponent)
2195
1941
  * so any elements passed to it must also be pure.
2196
- */ var tn = function(e) {
2197
- zt(n, e);
2198
- var t = Ut(n);
1942
+ */ var Ht = function(e) {
1943
+ At(n, e);
1944
+ var t = _t(n);
2199
1945
  function n() {
2200
1946
  var e;
2201
- Ft(this, n);
2202
- for (var r = arguments.length, o = new Array(r), i = 0; i < r; i++) {
2203
- o[i] = arguments[i];
1947
+ Et(this, n);
1948
+ for (var r = arguments.length, o = new Array(r), l = 0; l < r; l++) {
1949
+ o[l] = arguments[l];
2204
1950
  }
2205
1951
  e = t.call.apply(t, [ this ].concat(o));
2206
- Qt(Jt(e), "c", null);
2207
- Qt(Jt(e), "handleMount", (function(t) {
1952
+ Dt(qt(e), "c", null);
1953
+ Dt(qt(e), "handleMount", (function(t) {
2208
1954
  e.c = t;
2209
1955
  }));
2210
1956
  return e;
2211
1957
  }
2212
- $t(n, [ {
1958
+ // @docs-props-type OptionPropsBase
1959
+ Tt(n, [ {
2213
1960
  key: "scrollIntoViewIfNeeded",
1961
+ // eslint-disable-next-line react/no-unused-class-component-methods
2214
1962
  value: function e() {
2215
1963
  var t;
2216
1964
  (t = this.c) === null || t === void 0 ? void 0 : t.scrollIntoViewIfNeeded();
2217
1965
  }
2218
1966
  /**
2219
1967
  * Place focus on the button.
2220
- */ }, {
1968
+ */
1969
+ // eslint-disable-next-line react/no-unused-class-component-methods
1970
+ }, {
2221
1971
  key: "focus",
2222
1972
  value: function e() {
2223
1973
  var t;
@@ -2227,7 +1977,7 @@
2227
1977
  key: "render",
2228
1978
  value: function e() {
2229
1979
 
2230
- return r().createElement(Oe, Kt({}, this.props, {
1980
+ return r().createElement(Se, Pt({}, this.props, {
2231
1981
  multiple: false,
2232
1982
  ref: this.handleMount
2233
1983
  }), this.props.children || this.props.label);
@@ -2235,201 +1985,183 @@
2235
1985
  } ]);
2236
1986
  return n;
2237
1987
  }(n.PureComponent);
2238
- Qt(tn, "propTypes", Zt);
2239
- Qt(tn, "defaultProps", en);
2240
- /* harmony default export */ const nn = tn;
1988
+ Dt(Ht, "propTypes", Nt);
1989
+ Dt(Ht, "defaultProps", Ft);
1990
+ /* harmony default export */ const zt = Ht;
2241
1991
  // CONCATENATED MODULE: ./src/Select/Select.tsx
2242
- function rn(e) {
1992
+ function $t(e) {
2243
1993
  "@babel/helpers - typeof";
2244
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
2245
- rn = function e(t) {
2246
- return typeof t;
2247
- };
2248
- } else {
2249
- rn = function e(t) {
2250
- return t && typeof Symbol === "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
2251
- };
2252
- }
2253
- return rn(e);
2254
- }
2255
- function on() {
2256
- on = Object.assign || function(e) {
1994
+ return $t = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(e) {
1995
+ return typeof e;
1996
+ } : function(e) {
1997
+ return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
1998
+ }, $t(e);
1999
+ }
2000
+ function Wt() {
2001
+ return Wt = Object.assign ? Object.assign.bind() : function(e) {
2257
2002
  for (var t = 1; t < arguments.length; t++) {
2258
2003
  var n = arguments[t];
2259
2004
  for (var r in n) {
2260
- if (Object.prototype.hasOwnProperty.call(n, r)) {
2261
- e[r] = n[r];
2262
- }
2005
+ ({}).hasOwnProperty.call(n, r) && (e[r] = n[r]);
2263
2006
  }
2264
2007
  }
2265
2008
  return e;
2266
- };
2267
- return on.apply(this, arguments);
2009
+ }, Wt.apply(null, arguments);
2268
2010
  }
2269
- function an(e, t) {
2270
- if (e == null) return {};
2271
- var n = ln(e, t);
2272
- var r, o;
2011
+ function Ut(e, t) {
2012
+ if (null == e) return {};
2013
+ var n, r, o = Jt(e, t);
2273
2014
  if (Object.getOwnPropertySymbols) {
2274
- var i = Object.getOwnPropertySymbols(e);
2275
- for (o = 0; o < i.length; o++) {
2276
- r = i[o];
2277
- if (t.indexOf(r) >= 0) continue;
2278
- if (!Object.prototype.propertyIsEnumerable.call(e, r)) continue;
2279
- n[r] = e[r];
2015
+ var l = Object.getOwnPropertySymbols(e);
2016
+ for (r = 0; r < l.length; r++) {
2017
+ n = l[r], t.includes(n) || {}.propertyIsEnumerable.call(e, n) && (o[n] = e[n]);
2280
2018
  }
2281
2019
  }
2282
- return n;
2020
+ return o;
2283
2021
  }
2284
- function ln(e, t) {
2285
- if (e == null) return {};
2022
+ function Jt(e, t) {
2023
+ if (null == e) return {};
2286
2024
  var n = {};
2287
- var r = Object.keys(e);
2288
- var o, i;
2289
- for (i = 0; i < r.length; i++) {
2290
- o = r[i];
2291
- if (t.indexOf(o) >= 0) continue;
2292
- n[o] = e[o];
2025
+ for (var r in e) {
2026
+ if ({}.hasOwnProperty.call(e, r)) {
2027
+ if (t.includes(r)) continue;
2028
+ n[r] = e[r];
2029
+ }
2293
2030
  }
2294
2031
  return n;
2295
2032
  }
2296
- function cn(e, t) {
2297
- if (!(e instanceof t)) {
2298
- throw new TypeError("Cannot call a class as a function");
2299
- }
2033
+ function Xt(e, t) {
2034
+ if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
2300
2035
  }
2301
- function sn(e, t) {
2036
+ function Gt(e, t) {
2302
2037
  for (var n = 0; n < t.length; n++) {
2303
2038
  var r = t[n];
2304
- r.enumerable = r.enumerable || false;
2305
- r.configurable = true;
2306
- if ("value" in r) r.writable = true;
2307
- Object.defineProperty(e, r.key, r);
2039
+ r.enumerable = r.enumerable || !1, r.configurable = !0, "value" in r && (r.writable = !0),
2040
+ Object.defineProperty(e, an(r.key), r);
2308
2041
  }
2309
2042
  }
2310
- function un(e, t, n) {
2311
- if (t) sn(e.prototype, t);
2312
- if (n) sn(e, n);
2313
- return e;
2043
+ function Qt(e, t, n) {
2044
+ return t && Gt(e.prototype, t), n && Gt(e, n), Object.defineProperty(e, "prototype", {
2045
+ writable: !1
2046
+ }), e;
2314
2047
  }
2315
- function pn(e, t) {
2316
- if (typeof t !== "function" && t !== null) {
2317
- throw new TypeError("Super expression must either be null or a function");
2318
- }
2048
+ function Yt(e, t) {
2049
+ if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
2319
2050
  e.prototype = Object.create(t && t.prototype, {
2320
2051
  constructor: {
2321
2052
  value: e,
2322
- writable: true,
2323
- configurable: true
2053
+ writable: !0,
2054
+ configurable: !0
2324
2055
  }
2325
- });
2326
- if (t) fn(e, t);
2327
- }
2328
- function fn(e, t) {
2329
- fn = Object.setPrototypeOf || function e(t, n) {
2330
- t.__proto__ = n;
2331
- return t;
2332
- };
2333
- return fn(e, t);
2334
- }
2335
- function dn(e) {
2336
- var t = bn();
2337
- return function n() {
2338
- var r = mn(e), o;
2056
+ }), Object.defineProperty(e, "prototype", {
2057
+ writable: !1
2058
+ }), t && Zt(e, t);
2059
+ }
2060
+ function Zt(e, t) {
2061
+ return Zt = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(e, t) {
2062
+ return e.__proto__ = t, e;
2063
+ }, Zt(e, t);
2064
+ }
2065
+ function en(e) {
2066
+ var t = rn();
2067
+ return function() {
2068
+ var n, r = on(e);
2339
2069
  if (t) {
2340
- var i = mn(this).constructor;
2341
- o = Reflect.construct(r, arguments, i);
2342
- } else {
2343
- o = r.apply(this, arguments);
2344
- }
2345
- return vn(this, o);
2070
+ var o = on(this).constructor;
2071
+ n = Reflect.construct(r, arguments, o);
2072
+ } else n = r.apply(this, arguments);
2073
+ return tn(this, n);
2346
2074
  };
2347
2075
  }
2348
- function vn(e, t) {
2349
- if (t && (rn(t) === "object" || typeof t === "function")) {
2350
- return t;
2351
- }
2352
- return hn(e);
2076
+ function tn(e, t) {
2077
+ if (t && ("object" == $t(t) || "function" == typeof t)) return t;
2078
+ if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
2079
+ return nn(e);
2353
2080
  }
2354
- function hn(e) {
2355
- if (e === void 0) {
2356
- throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
2357
- }
2081
+ function nn(e) {
2082
+ if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
2358
2083
  return e;
2359
2084
  }
2360
- function bn() {
2361
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
2362
- if (Reflect.construct.sham) return false;
2363
- if (typeof Proxy === "function") return true;
2085
+ function rn() {
2364
2086
  try {
2365
- Date.prototype.toString.call(Reflect.construct(Date, [], (function() {})));
2366
- return true;
2367
- } catch (e) {
2368
- return false;
2369
- }
2370
- }
2371
- function mn(e) {
2372
- mn = Object.setPrototypeOf ? Object.getPrototypeOf : function e(t) {
2373
- return t.__proto__ || Object.getPrototypeOf(t);
2374
- };
2375
- return mn(e);
2376
- }
2377
- function yn(e, t, n) {
2378
- if (t in e) {
2379
- Object.defineProperty(e, t, {
2380
- value: n,
2381
- enumerable: true,
2382
- configurable: true,
2383
- writable: true
2384
- });
2385
- } else {
2386
- e[t] = n;
2087
+ var e = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], (function() {})));
2088
+ } catch (e) {}
2089
+ return (rn = function t() {
2090
+ return !!e;
2091
+ })();
2092
+ }
2093
+ function on(e) {
2094
+ return on = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(e) {
2095
+ return e.__proto__ || Object.getPrototypeOf(e);
2096
+ }, on(e);
2097
+ }
2098
+ function ln(e, t, n) {
2099
+ return (t = an(t)) in e ? Object.defineProperty(e, t, {
2100
+ value: n,
2101
+ enumerable: !0,
2102
+ configurable: !0,
2103
+ writable: !0
2104
+ }) : e[t] = n, e;
2105
+ }
2106
+ function an(e) {
2107
+ var t = un(e, "string");
2108
+ return "symbol" == $t(t) ? t : t + "";
2109
+ }
2110
+ function un(e, t) {
2111
+ if ("object" != $t(e) || !e) return e;
2112
+ var n = e[Symbol.toPrimitive];
2113
+ if (void 0 !== n) {
2114
+ var r = n.call(e, t || "default");
2115
+ if ("object" != $t(r)) return r;
2116
+ throw new TypeError("@@toPrimitive must return a primitive value.");
2387
2117
  }
2388
- return e;
2118
+ return ("string" === t ? String : Number)(e);
2389
2119
  }
2390
2120
  /* eslint-disable max-classes-per-file */
2391
- /** @public */ var gn = {
2392
- allowKeyMatching: i().bool,
2393
- animateLoading: i().bool,
2394
- appearance: i().oneOf([ "default", "link", "primary", "pill", "toggle", "flat", "subtle" ]),
2395
- append: i().bool,
2396
- children: i().node,
2397
- defaultPlacement: i().oneOf([ "above", "below", "vertical" ]),
2398
- defaultValue: i().oneOfType([ i().string, i().number, i().bool ]),
2399
- describedBy: i().string,
2400
- disabled: i().bool,
2401
- elementRef: i().oneOfType([ i().func, i().object ]),
2402
- error: i().bool,
2403
- filter: i().oneOf([ false, true, "controlled" ]),
2404
- footerMessage: i().node,
2405
- inline: i().bool,
2406
- inputId: i().string,
2407
- inputRef: i().oneOfType([ i().func, i().object ]),
2408
- isLoadingOptions: i().bool,
2409
- labelledBy: i().string,
2410
- labelText: i().string,
2411
- loadingMessage: i().node,
2412
- menuStyle: i().object,
2413
- name: i().string,
2414
- noOptionsMessage: i().node,
2415
- onChange: i().func,
2416
- onClose: i().func,
2417
- onFilterChange: i().func,
2418
- onOpen: i().func,
2419
- onScroll: i().func,
2420
- onScrollBottom: i().func,
2421
- placeholder: i().string,
2422
- prefixLabel: i().string,
2423
- prepend: i().bool,
2424
- suffixLabel: i().string,
2425
- toggleContent: i().oneOf([ "optionChildren", "optionLabel" ]),
2121
+ /** @public */
2122
+ /** @public */
2123
+ /** @public */ var cn = {
2124
+ allowKeyMatching: l().bool,
2125
+ animateLoading: l().bool,
2126
+ appearance: l().oneOf([ "default", "link", "primary", "pill", "toggle", "flat", "subtle" ]),
2127
+ append: l().bool,
2128
+ children: l().node,
2129
+ defaultPlacement: l().oneOf([ "above", "below", "vertical" ]),
2130
+ defaultValue: l().oneOfType([ l().string, l().number, l().bool ]),
2131
+ describedBy: l().string,
2132
+ disabled: l().bool,
2133
+ elementRef: l().oneOfType([ l().func, l().object ]),
2134
+ error: l().bool,
2135
+ filter: l().oneOf([ false, true, "controlled" ]),
2136
+ footerMessage: l().node,
2137
+ inline: l().bool,
2138
+ inputId: l().string,
2139
+ inputRef: l().oneOfType([ l().func, l().object ]),
2140
+ isLoadingOptions: l().bool,
2141
+ labelledBy: l().string,
2142
+ labelText: l().string,
2143
+ loadingMessage: l().node,
2144
+ menuStyle: l().object,
2145
+ name: l().string,
2146
+ noOptionsMessage: l().node,
2147
+ onChange: l().func,
2148
+ onClose: l().func,
2149
+ onFilterChange: l().func,
2150
+ onOpen: l().func,
2151
+ onScroll: l().func,
2152
+ onScrollBottom: l().func,
2153
+ placeholder: l().string,
2154
+ prefixLabel: l().string,
2155
+ prepend: l().bool,
2156
+ suffixLabel: l().string,
2157
+ toggleContent: l().oneOf([ "optionChildren", "optionLabel" ]),
2426
2158
  /** @private. */
2427
- toggle: i().node,
2428
- value: i().oneOfType([ i().string, i().number, i().bool ]),
2159
+ toggle: l().node,
2160
+ value: l().oneOfType([ l().string, l().number, l().bool ]),
2429
2161
  /** @private. */
2430
- virtualization: i().number
2162
+ virtualization: l().number
2431
2163
  };
2432
- var On = {
2164
+ var sn = {
2433
2165
  allowKeyMatching: true,
2434
2166
  animateLoading: false,
2435
2167
  appearance: "toggle",
@@ -2442,23 +2174,23 @@
2442
2174
  inline: true,
2443
2175
  isLoadingOptions: false,
2444
2176
  menuStyle: {},
2445
- noOptionsMessage: (0, c._)("No matches"),
2446
- placeholder: (0, c._)("Select..."),
2177
+ noOptionsMessage: (0, u._)("No matches"),
2178
+ placeholder: (0, u._)("Select..."),
2447
2179
  prepend: false,
2448
2180
  toggleContent: "optionChildren"
2449
2181
  };
2450
- var Sn = function(e) {
2451
- pn(n, e);
2452
- var t = dn(n);
2182
+ var pn = function(e) {
2183
+ Yt(n, e);
2184
+ var t = en(n);
2453
2185
  // @docs-props-type SelectPropsBase
2454
2186
  function n(e) {
2455
2187
  var r;
2456
- cn(this, n);
2188
+ Xt(this, n);
2457
2189
  r = t.call(this, e);
2458
2190
  var o = {};
2459
- // wrap defaultValue in an array once to avoid failing <SelectBase>'s defaultValues comparison check
2191
+ // wrap defaultValue in an array once to avoid failing <SelectBase>'s defaultValues comparison check
2460
2192
  // using "has" to make sure that pre-4.3 behavior is preserved if a user explicitly passes "null" or "undefined"
2461
- if (l()(e, "defaultValue")) {
2193
+ if (a()(e, "defaultValue")) {
2462
2194
  if (e.defaultValue != null) {
2463
2195
  o.defaultValues = [ e.defaultValue ];
2464
2196
  } else {
@@ -2466,12 +2198,12 @@
2466
2198
  }
2467
2199
  }
2468
2200
  r.state = o;
2469
- // `this.props.appearance === 'toggle'` is not included here because it is the default value.
2201
+ // `this.props.appearance === 'toggle'` is not included here because it is the default value.
2470
2202
  // Including it would trigger a warning for every instance of using `Select`.
2471
2203
  if (false) {}
2472
2204
  return r;
2473
2205
  }
2474
- un(n, [ {
2206
+ Qt(n, [ {
2475
2207
  key: "componentDidUpdate",
2476
2208
  value: function e(t) {
2477
2209
  if (false) {}
@@ -2479,41 +2211,41 @@
2479
2211
  }, {
2480
2212
  key: "render",
2481
2213
  value: function e() {
2482
- var t = this.props, n = t.defaultValue, o = t.onChange, i = t.value, a = an(t, [ "defaultValue", "onChange", "value" ]);
2483
- var c = {
2214
+ var t = this.props, n = t.defaultValue, o = t.onChange, l = t.value, i = Ut(t, [ "defaultValue", "onChange", "value" ]);
2215
+ var u = {
2484
2216
  onChange: function e(t, n) {
2485
- var r = n.name, i = n.values;
2217
+ var r = n.name, l = n.values;
2486
2218
  o === null || o === void 0 ? void 0 : o(t, {
2487
2219
  name: r,
2488
- value: i[0]
2220
+ value: l[0]
2489
2221
  });
2490
2222
  }
2491
2223
  };
2492
- // using "has" as opposed to a null check to match SelectBase
2493
- if (l()(this.props, "value")) {
2494
- if (i != null) {
2495
- c.values = [ i ];
2224
+ // using "has" as opposed to a null check to match SelectBase
2225
+ if (a()(this.props, "value")) {
2226
+ if (l != null) {
2227
+ u.values = [ l ];
2496
2228
  } else {
2497
- c.values = [];
2229
+ u.values = [];
2498
2230
  }
2499
2231
  } else if (this.state.defaultValues != null) {
2500
2232
  // using defaultValues from state in order to avoid wrapping defaultValue here
2501
- c.defaultValues = this.state.defaultValues;
2233
+ u.defaultValues = this.state.defaultValues;
2502
2234
  }
2503
2235
 
2504
- return r().createElement(Nt, on({}, a, c, {
2236
+ return r().createElement(kt, Wt({}, i, u, {
2505
2237
  multiple: false
2506
2238
  }));
2507
2239
  }
2508
2240
  } ]);
2509
2241
  return n;
2510
2242
  }(n.Component);
2511
- yn(Sn, "propTypes", gn);
2512
- yn(Sn, "defaultProps", On);
2513
- yn(Sn, "Option", nn);
2514
- yn(Sn, "Heading", T.Heading);
2515
- yn(Sn, "Divider", T.Divider);
2516
- /* harmony default export */ const wn = Sn;
2243
+ ln(pn, "propTypes", cn);
2244
+ ln(pn, "defaultProps", sn);
2245
+ ln(pn, "Option", zt);
2246
+ ln(pn, "Heading", M.Heading);
2247
+ ln(pn, "Divider", M.Divider);
2248
+ /* harmony default export */ const fn = pn;
2517
2249
  // CONCATENATED MODULE: ./src/Select/index.ts
2518
2250
  module.exports = t;
2519
2251
  /******/})();