dropdowns-js 1.1.4 → 1.1.5

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.
@@ -1,107 +1,107 @@
1
1
  import { jsxs as Q, jsx as L } from "react/jsx-runtime";
2
- import { useState as ee, useMemo as re, useEffect as Pe } from "react";
3
- function $e(i) {
4
- return i && i.__esModule && Object.prototype.hasOwnProperty.call(i, "default") ? i.default : i;
2
+ import { useId as ce, useState as ee, useMemo as re, useEffect as Pe } from "react";
3
+ function _e(n) {
4
+ return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
5
5
  }
6
- var se = { exports: {} }, ae = { exports: {} }, Y = {};
7
- var ge;
8
- function _e() {
9
- if (ge) return Y;
10
- ge = 1;
11
- var i = typeof Symbol == "function" && Symbol.for, T = i ? /* @__PURE__ */ Symbol.for("react.element") : 60103, M = i ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, v = i ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, C = i ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, p = i ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, b = i ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, y = i ? /* @__PURE__ */ Symbol.for("react.context") : 60110, w = i ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, g = i ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, S = i ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, m = i ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, P = i ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, j = i ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, J = i ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, x = i ? /* @__PURE__ */ Symbol.for("react.block") : 60121, q = i ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, V = i ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, H = i ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
12
- function I(s) {
6
+ var se = { exports: {} }, ae = { exports: {} }, F = {};
7
+ var me;
8
+ function Ie() {
9
+ if (me) return F;
10
+ me = 1;
11
+ var n = typeof Symbol == "function" && Symbol.for, j = n ? /* @__PURE__ */ Symbol.for("react.element") : 60103, M = n ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, b = n ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, T = n ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, p = n ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, w = n ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, m = n ? /* @__PURE__ */ Symbol.for("react.context") : 60110, g = n ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, x = n ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, y = n ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, C = n ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, E = n ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, P = n ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, Y = n ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, q = n ? /* @__PURE__ */ Symbol.for("react.block") : 60121, _ = n ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, U = n ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, X = n ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
12
+ function D(s) {
13
13
  if (typeof s == "object" && s !== null) {
14
- var X = s.$$typeof;
15
- switch (X) {
16
- case T:
14
+ var B = s.$$typeof;
15
+ switch (B) {
16
+ case j:
17
17
  switch (s = s.type, s) {
18
- case w:
19
18
  case g:
20
- case v:
19
+ case x:
20
+ case b:
21
21
  case p:
22
+ case T:
22
23
  case C:
23
- case m:
24
24
  return s;
25
25
  default:
26
26
  switch (s = s && s.$$typeof, s) {
27
+ case m:
27
28
  case y:
28
- case S:
29
- case J:
30
- case j:
31
- case b:
29
+ case Y:
30
+ case P:
31
+ case w:
32
32
  return s;
33
33
  default:
34
- return X;
34
+ return B;
35
35
  }
36
36
  }
37
37
  case M:
38
- return X;
38
+ return B;
39
39
  }
40
40
  }
41
41
  }
42
- function O(s) {
43
- return I(s) === g;
44
- }
45
- return Y.AsyncMode = w, Y.ConcurrentMode = g, Y.ContextConsumer = y, Y.ContextProvider = b, Y.Element = T, Y.ForwardRef = S, Y.Fragment = v, Y.Lazy = J, Y.Memo = j, Y.Portal = M, Y.Profiler = p, Y.StrictMode = C, Y.Suspense = m, Y.isAsyncMode = function(s) {
46
- return O(s) || I(s) === w;
47
- }, Y.isConcurrentMode = O, Y.isContextConsumer = function(s) {
48
- return I(s) === y;
49
- }, Y.isContextProvider = function(s) {
50
- return I(s) === b;
51
- }, Y.isElement = function(s) {
52
- return typeof s == "object" && s !== null && s.$$typeof === T;
53
- }, Y.isForwardRef = function(s) {
54
- return I(s) === S;
55
- }, Y.isFragment = function(s) {
56
- return I(s) === v;
57
- }, Y.isLazy = function(s) {
58
- return I(s) === J;
59
- }, Y.isMemo = function(s) {
60
- return I(s) === j;
61
- }, Y.isPortal = function(s) {
62
- return I(s) === M;
63
- }, Y.isProfiler = function(s) {
64
- return I(s) === p;
65
- }, Y.isStrictMode = function(s) {
66
- return I(s) === C;
67
- }, Y.isSuspense = function(s) {
68
- return I(s) === m;
69
- }, Y.isValidElementType = function(s) {
70
- return typeof s == "string" || typeof s == "function" || s === v || s === g || s === p || s === C || s === m || s === P || typeof s == "object" && s !== null && (s.$$typeof === J || s.$$typeof === j || s.$$typeof === b || s.$$typeof === y || s.$$typeof === S || s.$$typeof === q || s.$$typeof === V || s.$$typeof === H || s.$$typeof === x);
71
- }, Y.typeOf = I, Y;
42
+ function $(s) {
43
+ return D(s) === x;
44
+ }
45
+ return F.AsyncMode = g, F.ConcurrentMode = x, F.ContextConsumer = m, F.ContextProvider = w, F.Element = j, F.ForwardRef = y, F.Fragment = b, F.Lazy = Y, F.Memo = P, F.Portal = M, F.Profiler = p, F.StrictMode = T, F.Suspense = C, F.isAsyncMode = function(s) {
46
+ return $(s) || D(s) === g;
47
+ }, F.isConcurrentMode = $, F.isContextConsumer = function(s) {
48
+ return D(s) === m;
49
+ }, F.isContextProvider = function(s) {
50
+ return D(s) === w;
51
+ }, F.isElement = function(s) {
52
+ return typeof s == "object" && s !== null && s.$$typeof === j;
53
+ }, F.isForwardRef = function(s) {
54
+ return D(s) === y;
55
+ }, F.isFragment = function(s) {
56
+ return D(s) === b;
57
+ }, F.isLazy = function(s) {
58
+ return D(s) === Y;
59
+ }, F.isMemo = function(s) {
60
+ return D(s) === P;
61
+ }, F.isPortal = function(s) {
62
+ return D(s) === M;
63
+ }, F.isProfiler = function(s) {
64
+ return D(s) === p;
65
+ }, F.isStrictMode = function(s) {
66
+ return D(s) === T;
67
+ }, F.isSuspense = function(s) {
68
+ return D(s) === C;
69
+ }, F.isValidElementType = function(s) {
70
+ return typeof s == "string" || typeof s == "function" || s === b || s === x || s === p || s === T || s === C || s === E || typeof s == "object" && s !== null && (s.$$typeof === Y || s.$$typeof === P || s.$$typeof === w || s.$$typeof === m || s.$$typeof === y || s.$$typeof === _ || s.$$typeof === U || s.$$typeof === X || s.$$typeof === q);
71
+ }, F.typeOf = D, F;
72
72
  }
73
- var U = {};
74
- var me;
75
- function Ie() {
76
- return me || (me = 1, process.env.NODE_ENV !== "production" && (function() {
77
- var i = typeof Symbol == "function" && Symbol.for, T = i ? /* @__PURE__ */ Symbol.for("react.element") : 60103, M = i ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, v = i ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, C = i ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, p = i ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, b = i ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, y = i ? /* @__PURE__ */ Symbol.for("react.context") : 60110, w = i ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, g = i ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, S = i ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, m = i ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, P = i ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, j = i ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, J = i ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, x = i ? /* @__PURE__ */ Symbol.for("react.block") : 60121, q = i ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, V = i ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, H = i ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
78
- function I(d) {
73
+ var V = {};
74
+ var ve;
75
+ function De() {
76
+ return ve || (ve = 1, process.env.NODE_ENV !== "production" && (function() {
77
+ var n = typeof Symbol == "function" && Symbol.for, j = n ? /* @__PURE__ */ Symbol.for("react.element") : 60103, M = n ? /* @__PURE__ */ Symbol.for("react.portal") : 60106, b = n ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107, T = n ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108, p = n ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114, w = n ? /* @__PURE__ */ Symbol.for("react.provider") : 60109, m = n ? /* @__PURE__ */ Symbol.for("react.context") : 60110, g = n ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111, x = n ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111, y = n ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112, C = n ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113, E = n ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120, P = n ? /* @__PURE__ */ Symbol.for("react.memo") : 60115, Y = n ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116, q = n ? /* @__PURE__ */ Symbol.for("react.block") : 60121, _ = n ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117, U = n ? /* @__PURE__ */ Symbol.for("react.responder") : 60118, X = n ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
78
+ function D(d) {
79
79
  return typeof d == "string" || typeof d == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
80
- d === v || d === g || d === p || d === C || d === m || d === P || typeof d == "object" && d !== null && (d.$$typeof === J || d.$$typeof === j || d.$$typeof === b || d.$$typeof === y || d.$$typeof === S || d.$$typeof === q || d.$$typeof === V || d.$$typeof === H || d.$$typeof === x);
80
+ d === b || d === x || d === p || d === T || d === C || d === E || typeof d == "object" && d !== null && (d.$$typeof === Y || d.$$typeof === P || d.$$typeof === w || d.$$typeof === m || d.$$typeof === y || d.$$typeof === _ || d.$$typeof === U || d.$$typeof === X || d.$$typeof === q);
81
81
  }
82
- function O(d) {
82
+ function $(d) {
83
83
  if (typeof d == "object" && d !== null) {
84
84
  var oe = d.$$typeof;
85
85
  switch (oe) {
86
- case T:
86
+ case j:
87
87
  var ie = d.type;
88
88
  switch (ie) {
89
- case w:
90
89
  case g:
91
- case v:
90
+ case x:
91
+ case b:
92
92
  case p:
93
+ case T:
93
94
  case C:
94
- case m:
95
95
  return ie;
96
96
  default:
97
- var ye = ie && ie.$$typeof;
98
- switch (ye) {
97
+ var ge = ie && ie.$$typeof;
98
+ switch (ge) {
99
+ case m:
99
100
  case y:
100
- case S:
101
- case J:
102
- case j:
103
- case b:
104
- return ye;
101
+ case Y:
102
+ case P:
103
+ case w:
104
+ return ge;
105
105
  default:
106
106
  return oe;
107
107
  }
@@ -111,432 +111,432 @@ function Ie() {
111
111
  }
112
112
  }
113
113
  }
114
- var s = w, X = g, K = y, W = b, e = T, t = S, a = v, o = J, r = j, c = M, l = p, D = C, G = m, h = !1;
115
- function B(d) {
116
- return h || (h = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), n(d) || O(d) === w;
114
+ var s = g, B = x, G = m, Z = w, t = j, o = y, u = b, r = Y, i = P, f = M, c = p, v = T, h = C, H = !1;
115
+ function K(d) {
116
+ return H || (H = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), e(d) || $(d) === g;
117
117
  }
118
- function n(d) {
119
- return O(d) === g;
118
+ function e(d) {
119
+ return $(d) === x;
120
120
  }
121
- function f(d) {
122
- return O(d) === y;
121
+ function a(d) {
122
+ return $(d) === m;
123
123
  }
124
- function k(d) {
125
- return O(d) === b;
124
+ function S(d) {
125
+ return $(d) === w;
126
126
  }
127
- function $(d) {
128
- return typeof d == "object" && d !== null && d.$$typeof === T;
127
+ function O(d) {
128
+ return typeof d == "object" && d !== null && d.$$typeof === j;
129
129
  }
130
- function E(d) {
131
- return O(d) === S;
130
+ function R(d) {
131
+ return $(d) === y;
132
132
  }
133
133
  function A(d) {
134
- return O(d) === v;
134
+ return $(d) === b;
135
135
  }
136
- function R(d) {
137
- return O(d) === J;
136
+ function I(d) {
137
+ return $(d) === Y;
138
138
  }
139
- function _(d) {
140
- return O(d) === j;
139
+ function k(d) {
140
+ return $(d) === P;
141
141
  }
142
142
  function z(d) {
143
- return O(d) === M;
143
+ return $(d) === M;
144
144
  }
145
- function F(d) {
146
- return O(d) === p;
145
+ function W(d) {
146
+ return $(d) === p;
147
147
  }
148
148
  function N(d) {
149
- return O(d) === C;
149
+ return $(d) === T;
150
150
  }
151
151
  function te(d) {
152
- return O(d) === m;
152
+ return $(d) === C;
153
153
  }
154
- U.AsyncMode = s, U.ConcurrentMode = X, U.ContextConsumer = K, U.ContextProvider = W, U.Element = e, U.ForwardRef = t, U.Fragment = a, U.Lazy = o, U.Memo = r, U.Portal = c, U.Profiler = l, U.StrictMode = D, U.Suspense = G, U.isAsyncMode = B, U.isConcurrentMode = n, U.isContextConsumer = f, U.isContextProvider = k, U.isElement = $, U.isForwardRef = E, U.isFragment = A, U.isLazy = R, U.isMemo = _, U.isPortal = z, U.isProfiler = F, U.isStrictMode = N, U.isSuspense = te, U.isValidElementType = I, U.typeOf = O;
155
- })()), U;
154
+ V.AsyncMode = s, V.ConcurrentMode = B, V.ContextConsumer = G, V.ContextProvider = Z, V.Element = t, V.ForwardRef = o, V.Fragment = u, V.Lazy = r, V.Memo = i, V.Portal = f, V.Profiler = c, V.StrictMode = v, V.Suspense = h, V.isAsyncMode = K, V.isConcurrentMode = e, V.isContextConsumer = a, V.isContextProvider = S, V.isElement = O, V.isForwardRef = R, V.isFragment = A, V.isLazy = I, V.isMemo = k, V.isPortal = z, V.isProfiler = W, V.isStrictMode = N, V.isSuspense = te, V.isValidElementType = D, V.typeOf = $;
155
+ })()), V;
156
156
  }
157
- var ve;
158
- function Oe() {
159
- return ve || (ve = 1, process.env.NODE_ENV === "production" ? ae.exports = _e() : ae.exports = Ie()), ae.exports;
157
+ var be;
158
+ function Re() {
159
+ return be || (be = 1, process.env.NODE_ENV === "production" ? ae.exports = Ie() : ae.exports = De()), ae.exports;
160
160
  }
161
- var ce, be;
162
- function De() {
163
- if (be) return ce;
164
- be = 1;
165
- var i = Object.getOwnPropertySymbols, T = Object.prototype.hasOwnProperty, M = Object.prototype.propertyIsEnumerable;
166
- function v(p) {
161
+ var le, we;
162
+ function ke() {
163
+ if (we) return le;
164
+ we = 1;
165
+ var n = Object.getOwnPropertySymbols, j = Object.prototype.hasOwnProperty, M = Object.prototype.propertyIsEnumerable;
166
+ function b(p) {
167
167
  if (p == null)
168
168
  throw new TypeError("Object.assign cannot be called with null or undefined");
169
169
  return Object(p);
170
170
  }
171
- function C() {
171
+ function T() {
172
172
  try {
173
173
  if (!Object.assign)
174
174
  return !1;
175
175
  var p = new String("abc");
176
176
  if (p[5] = "de", Object.getOwnPropertyNames(p)[0] === "5")
177
177
  return !1;
178
- for (var b = {}, y = 0; y < 10; y++)
179
- b["_" + String.fromCharCode(y)] = y;
180
- var w = Object.getOwnPropertyNames(b).map(function(S) {
181
- return b[S];
178
+ for (var w = {}, m = 0; m < 10; m++)
179
+ w["_" + String.fromCharCode(m)] = m;
180
+ var g = Object.getOwnPropertyNames(w).map(function(y) {
181
+ return w[y];
182
182
  });
183
- if (w.join("") !== "0123456789")
183
+ if (g.join("") !== "0123456789")
184
184
  return !1;
185
- var g = {};
186
- return "abcdefghijklmnopqrst".split("").forEach(function(S) {
187
- g[S] = S;
188
- }), Object.keys(Object.assign({}, g)).join("") === "abcdefghijklmnopqrst";
185
+ var x = {};
186
+ return "abcdefghijklmnopqrst".split("").forEach(function(y) {
187
+ x[y] = y;
188
+ }), Object.keys(Object.assign({}, x)).join("") === "abcdefghijklmnopqrst";
189
189
  } catch {
190
190
  return !1;
191
191
  }
192
192
  }
193
- return ce = C() ? Object.assign : function(p, b) {
194
- for (var y, w = v(p), g, S = 1; S < arguments.length; S++) {
195
- y = Object(arguments[S]);
196
- for (var m in y)
197
- T.call(y, m) && (w[m] = y[m]);
198
- if (i) {
199
- g = i(y);
200
- for (var P = 0; P < g.length; P++)
201
- M.call(y, g[P]) && (w[g[P]] = y[g[P]]);
193
+ return le = T() ? Object.assign : function(p, w) {
194
+ for (var m, g = b(p), x, y = 1; y < arguments.length; y++) {
195
+ m = Object(arguments[y]);
196
+ for (var C in m)
197
+ j.call(m, C) && (g[C] = m[C]);
198
+ if (n) {
199
+ x = n(m);
200
+ for (var E = 0; E < x.length; E++)
201
+ M.call(m, x[E]) && (g[x[E]] = m[x[E]]);
202
202
  }
203
203
  }
204
- return w;
205
- }, ce;
206
- }
207
- var le, we;
208
- function he() {
209
- if (we) return le;
210
- we = 1;
211
- var i = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
212
- return le = i, le;
204
+ return g;
205
+ }, le;
213
206
  }
214
207
  var ue, Se;
215
- function Re() {
216
- return Se || (Se = 1, ue = Function.call.bind(Object.prototype.hasOwnProperty)), ue;
208
+ function ye() {
209
+ if (Se) return ue;
210
+ Se = 1;
211
+ var n = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
212
+ return ue = n, ue;
217
213
  }
218
214
  var de, Ce;
219
- function ke() {
220
- if (Ce) return de;
221
- Ce = 1;
222
- var i = function() {
215
+ function $e() {
216
+ return Ce || (Ce = 1, de = Function.call.bind(Object.prototype.hasOwnProperty)), de;
217
+ }
218
+ var fe, xe;
219
+ function qe() {
220
+ if (xe) return fe;
221
+ xe = 1;
222
+ var n = function() {
223
223
  };
224
224
  if (process.env.NODE_ENV !== "production") {
225
- var T = /* @__PURE__ */ he(), M = {}, v = /* @__PURE__ */ Re();
226
- i = function(p) {
227
- var b = "Warning: " + p;
228
- typeof console < "u" && console.error(b);
225
+ var j = /* @__PURE__ */ ye(), M = {}, b = /* @__PURE__ */ $e();
226
+ n = function(p) {
227
+ var w = "Warning: " + p;
228
+ typeof console < "u" && console.error(w);
229
229
  try {
230
- throw new Error(b);
230
+ throw new Error(w);
231
231
  } catch {
232
232
  }
233
233
  };
234
234
  }
235
- function C(p, b, y, w, g) {
235
+ function T(p, w, m, g, x) {
236
236
  if (process.env.NODE_ENV !== "production") {
237
- for (var S in p)
238
- if (v(p, S)) {
239
- var m;
237
+ for (var y in p)
238
+ if (b(p, y)) {
239
+ var C;
240
240
  try {
241
- if (typeof p[S] != "function") {
242
- var P = Error(
243
- (w || "React class") + ": " + y + " type `" + S + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof p[S] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
241
+ if (typeof p[y] != "function") {
242
+ var E = Error(
243
+ (g || "React class") + ": " + m + " type `" + y + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof p[y] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
244
244
  );
245
- throw P.name = "Invariant Violation", P;
245
+ throw E.name = "Invariant Violation", E;
246
246
  }
247
- m = p[S](b, S, w, y, null, T);
248
- } catch (J) {
249
- m = J;
247
+ C = p[y](w, y, g, m, null, j);
248
+ } catch (Y) {
249
+ C = Y;
250
250
  }
251
- if (m && !(m instanceof Error) && i(
252
- (w || "React class") + ": type specification of " + y + " `" + S + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof m + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
253
- ), m instanceof Error && !(m.message in M)) {
254
- M[m.message] = !0;
255
- var j = g ? g() : "";
256
- i(
257
- "Failed " + y + " type: " + m.message + (j ?? "")
251
+ if (C && !(C instanceof Error) && n(
252
+ (g || "React class") + ": type specification of " + m + " `" + y + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof C + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
253
+ ), C instanceof Error && !(C.message in M)) {
254
+ M[C.message] = !0;
255
+ var P = x ? x() : "";
256
+ n(
257
+ "Failed " + m + " type: " + C.message + (P ?? "")
258
258
  );
259
259
  }
260
260
  }
261
261
  }
262
262
  }
263
- return C.resetWarningCache = function() {
263
+ return T.resetWarningCache = function() {
264
264
  process.env.NODE_ENV !== "production" && (M = {});
265
- }, de = C, de;
265
+ }, fe = T, fe;
266
266
  }
267
- var fe, xe;
268
- function qe() {
269
- if (xe) return fe;
270
- xe = 1;
271
- var i = Oe(), T = De(), M = /* @__PURE__ */ he(), v = /* @__PURE__ */ Re(), C = /* @__PURE__ */ ke(), p = function() {
267
+ var pe, Te;
268
+ function Me() {
269
+ if (Te) return pe;
270
+ Te = 1;
271
+ var n = Re(), j = ke(), M = /* @__PURE__ */ ye(), b = /* @__PURE__ */ $e(), T = /* @__PURE__ */ qe(), p = function() {
272
272
  };
273
- process.env.NODE_ENV !== "production" && (p = function(y) {
274
- var w = "Warning: " + y;
275
- typeof console < "u" && console.error(w);
273
+ process.env.NODE_ENV !== "production" && (p = function(m) {
274
+ var g = "Warning: " + m;
275
+ typeof console < "u" && console.error(g);
276
276
  try {
277
- throw new Error(w);
277
+ throw new Error(g);
278
278
  } catch {
279
279
  }
280
280
  });
281
- function b() {
281
+ function w() {
282
282
  return null;
283
283
  }
284
- return fe = function(y, w) {
285
- var g = typeof Symbol == "function" && Symbol.iterator, S = "@@iterator";
286
- function m(n) {
287
- var f = n && (g && n[g] || n[S]);
288
- if (typeof f == "function")
289
- return f;
284
+ return pe = function(m, g) {
285
+ var x = typeof Symbol == "function" && Symbol.iterator, y = "@@iterator";
286
+ function C(e) {
287
+ var a = e && (x && e[x] || e[y]);
288
+ if (typeof a == "function")
289
+ return a;
290
290
  }
291
- var P = "<<anonymous>>", j = {
292
- array: V("array"),
293
- bigint: V("bigint"),
294
- bool: V("boolean"),
295
- func: V("function"),
296
- number: V("number"),
297
- object: V("object"),
298
- string: V("string"),
299
- symbol: V("symbol"),
300
- any: H(),
301
- arrayOf: I,
302
- element: O(),
291
+ var E = "<<anonymous>>", P = {
292
+ array: U("array"),
293
+ bigint: U("bigint"),
294
+ bool: U("boolean"),
295
+ func: U("function"),
296
+ number: U("number"),
297
+ object: U("object"),
298
+ string: U("string"),
299
+ symbol: U("symbol"),
300
+ any: X(),
301
+ arrayOf: D,
302
+ element: $(),
303
303
  elementType: s(),
304
- instanceOf: X,
305
- node: t(),
306
- objectOf: W,
307
- oneOf: K,
308
- oneOfType: e,
309
- shape: o,
310
- exact: r
304
+ instanceOf: B,
305
+ node: o(),
306
+ objectOf: Z,
307
+ oneOf: G,
308
+ oneOfType: t,
309
+ shape: r,
310
+ exact: i
311
311
  };
312
- function J(n, f) {
313
- return n === f ? n !== 0 || 1 / n === 1 / f : n !== n && f !== f;
312
+ function Y(e, a) {
313
+ return e === a ? e !== 0 || 1 / e === 1 / a : e !== e && a !== a;
314
314
  }
315
- function x(n, f) {
316
- this.message = n, this.data = f && typeof f == "object" ? f : {}, this.stack = "";
315
+ function q(e, a) {
316
+ this.message = e, this.data = a && typeof a == "object" ? a : {}, this.stack = "";
317
317
  }
318
- x.prototype = Error.prototype;
319
- function q(n) {
318
+ q.prototype = Error.prototype;
319
+ function _(e) {
320
320
  if (process.env.NODE_ENV !== "production")
321
- var f = {}, k = 0;
322
- function $(A, R, _, z, F, N, te) {
323
- if (z = z || P, N = N || _, te !== M) {
324
- if (w) {
321
+ var a = {}, S = 0;
322
+ function O(A, I, k, z, W, N, te) {
323
+ if (z = z || E, N = N || k, te !== M) {
324
+ if (g) {
325
325
  var d = new Error(
326
326
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
327
327
  );
328
328
  throw d.name = "Invariant Violation", d;
329
329
  } else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
330
- var oe = z + ":" + _;
331
- !f[oe] && // Avoid spamming the console because they are often not actionable except for lib authors
332
- k < 3 && (p(
330
+ var oe = z + ":" + k;
331
+ !a[oe] && // Avoid spamming the console because they are often not actionable except for lib authors
332
+ S < 3 && (p(
333
333
  "You are manually calling a React.PropTypes validation function for the `" + N + "` prop on `" + z + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
334
- ), f[oe] = !0, k++);
334
+ ), a[oe] = !0, S++);
335
335
  }
336
336
  }
337
- return R[_] == null ? A ? R[_] === null ? new x("The " + F + " `" + N + "` is marked as required " + ("in `" + z + "`, but its value is `null`.")) : new x("The " + F + " `" + N + "` is marked as required in " + ("`" + z + "`, but its value is `undefined`.")) : null : n(R, _, z, F, N);
337
+ return I[k] == null ? A ? I[k] === null ? new q("The " + W + " `" + N + "` is marked as required " + ("in `" + z + "`, but its value is `null`.")) : new q("The " + W + " `" + N + "` is marked as required in " + ("`" + z + "`, but its value is `undefined`.")) : null : e(I, k, z, W, N);
338
338
  }
339
- var E = $.bind(null, !1);
340
- return E.isRequired = $.bind(null, !0), E;
341
- }
342
- function V(n) {
343
- function f(k, $, E, A, R, _) {
344
- var z = k[$], F = D(z);
345
- if (F !== n) {
346
- var N = G(z);
347
- return new x(
348
- "Invalid " + A + " `" + R + "` of type " + ("`" + N + "` supplied to `" + E + "`, expected ") + ("`" + n + "`."),
349
- { expectedType: n }
339
+ var R = O.bind(null, !1);
340
+ return R.isRequired = O.bind(null, !0), R;
341
+ }
342
+ function U(e) {
343
+ function a(S, O, R, A, I, k) {
344
+ var z = S[O], W = v(z);
345
+ if (W !== e) {
346
+ var N = h(z);
347
+ return new q(
348
+ "Invalid " + A + " `" + I + "` of type " + ("`" + N + "` supplied to `" + R + "`, expected ") + ("`" + e + "`."),
349
+ { expectedType: e }
350
350
  );
351
351
  }
352
352
  return null;
353
353
  }
354
- return q(f);
355
- }
356
- function H() {
357
- return q(b);
358
- }
359
- function I(n) {
360
- function f(k, $, E, A, R) {
361
- if (typeof n != "function")
362
- return new x("Property `" + R + "` of component `" + E + "` has invalid PropType notation inside arrayOf.");
363
- var _ = k[$];
364
- if (!Array.isArray(_)) {
365
- var z = D(_);
366
- return new x("Invalid " + A + " `" + R + "` of type " + ("`" + z + "` supplied to `" + E + "`, expected an array."));
354
+ return _(a);
355
+ }
356
+ function X() {
357
+ return _(w);
358
+ }
359
+ function D(e) {
360
+ function a(S, O, R, A, I) {
361
+ if (typeof e != "function")
362
+ return new q("Property `" + I + "` of component `" + R + "` has invalid PropType notation inside arrayOf.");
363
+ var k = S[O];
364
+ if (!Array.isArray(k)) {
365
+ var z = v(k);
366
+ return new q("Invalid " + A + " `" + I + "` of type " + ("`" + z + "` supplied to `" + R + "`, expected an array."));
367
367
  }
368
- for (var F = 0; F < _.length; F++) {
369
- var N = n(_, F, E, A, R + "[" + F + "]", M);
368
+ for (var W = 0; W < k.length; W++) {
369
+ var N = e(k, W, R, A, I + "[" + W + "]", M);
370
370
  if (N instanceof Error)
371
371
  return N;
372
372
  }
373
373
  return null;
374
374
  }
375
- return q(f);
376
- }
377
- function O() {
378
- function n(f, k, $, E, A) {
379
- var R = f[k];
380
- if (!y(R)) {
381
- var _ = D(R);
382
- return new x("Invalid " + E + " `" + A + "` of type " + ("`" + _ + "` supplied to `" + $ + "`, expected a single ReactElement."));
375
+ return _(a);
376
+ }
377
+ function $() {
378
+ function e(a, S, O, R, A) {
379
+ var I = a[S];
380
+ if (!m(I)) {
381
+ var k = v(I);
382
+ return new q("Invalid " + R + " `" + A + "` of type " + ("`" + k + "` supplied to `" + O + "`, expected a single ReactElement."));
383
383
  }
384
384
  return null;
385
385
  }
386
- return q(n);
386
+ return _(e);
387
387
  }
388
388
  function s() {
389
- function n(f, k, $, E, A) {
390
- var R = f[k];
391
- if (!i.isValidElementType(R)) {
392
- var _ = D(R);
393
- return new x("Invalid " + E + " `" + A + "` of type " + ("`" + _ + "` supplied to `" + $ + "`, expected a single ReactElement type."));
389
+ function e(a, S, O, R, A) {
390
+ var I = a[S];
391
+ if (!n.isValidElementType(I)) {
392
+ var k = v(I);
393
+ return new q("Invalid " + R + " `" + A + "` of type " + ("`" + k + "` supplied to `" + O + "`, expected a single ReactElement type."));
394
394
  }
395
395
  return null;
396
396
  }
397
- return q(n);
397
+ return _(e);
398
398
  }
399
- function X(n) {
400
- function f(k, $, E, A, R) {
401
- if (!(k[$] instanceof n)) {
402
- var _ = n.name || P, z = B(k[$]);
403
- return new x("Invalid " + A + " `" + R + "` of type " + ("`" + z + "` supplied to `" + E + "`, expected ") + ("instance of `" + _ + "`."));
399
+ function B(e) {
400
+ function a(S, O, R, A, I) {
401
+ if (!(S[O] instanceof e)) {
402
+ var k = e.name || E, z = K(S[O]);
403
+ return new q("Invalid " + A + " `" + I + "` of type " + ("`" + z + "` supplied to `" + R + "`, expected ") + ("instance of `" + k + "`."));
404
404
  }
405
405
  return null;
406
406
  }
407
- return q(f);
407
+ return _(a);
408
408
  }
409
- function K(n) {
410
- if (!Array.isArray(n))
409
+ function G(e) {
410
+ if (!Array.isArray(e))
411
411
  return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? p(
412
412
  "Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
413
- ) : p("Invalid argument supplied to oneOf, expected an array.")), b;
414
- function f(k, $, E, A, R) {
415
- for (var _ = k[$], z = 0; z < n.length; z++)
416
- if (J(_, n[z]))
413
+ ) : p("Invalid argument supplied to oneOf, expected an array.")), w;
414
+ function a(S, O, R, A, I) {
415
+ for (var k = S[O], z = 0; z < e.length; z++)
416
+ if (Y(k, e[z]))
417
417
  return null;
418
- var F = JSON.stringify(n, function(te, d) {
419
- var oe = G(d);
418
+ var W = JSON.stringify(e, function(te, d) {
419
+ var oe = h(d);
420
420
  return oe === "symbol" ? String(d) : d;
421
421
  });
422
- return new x("Invalid " + A + " `" + R + "` of value `" + String(_) + "` " + ("supplied to `" + E + "`, expected one of " + F + "."));
422
+ return new q("Invalid " + A + " `" + I + "` of value `" + String(k) + "` " + ("supplied to `" + R + "`, expected one of " + W + "."));
423
423
  }
424
- return q(f);
424
+ return _(a);
425
425
  }
426
- function W(n) {
427
- function f(k, $, E, A, R) {
428
- if (typeof n != "function")
429
- return new x("Property `" + R + "` of component `" + E + "` has invalid PropType notation inside objectOf.");
430
- var _ = k[$], z = D(_);
426
+ function Z(e) {
427
+ function a(S, O, R, A, I) {
428
+ if (typeof e != "function")
429
+ return new q("Property `" + I + "` of component `" + R + "` has invalid PropType notation inside objectOf.");
430
+ var k = S[O], z = v(k);
431
431
  if (z !== "object")
432
- return new x("Invalid " + A + " `" + R + "` of type " + ("`" + z + "` supplied to `" + E + "`, expected an object."));
433
- for (var F in _)
434
- if (v(_, F)) {
435
- var N = n(_, F, E, A, R + "." + F, M);
432
+ return new q("Invalid " + A + " `" + I + "` of type " + ("`" + z + "` supplied to `" + R + "`, expected an object."));
433
+ for (var W in k)
434
+ if (b(k, W)) {
435
+ var N = e(k, W, R, A, I + "." + W, M);
436
436
  if (N instanceof Error)
437
437
  return N;
438
438
  }
439
439
  return null;
440
440
  }
441
- return q(f);
442
- }
443
- function e(n) {
444
- if (!Array.isArray(n))
445
- return process.env.NODE_ENV !== "production" && p("Invalid argument supplied to oneOfType, expected an instance of array."), b;
446
- for (var f = 0; f < n.length; f++) {
447
- var k = n[f];
448
- if (typeof k != "function")
441
+ return _(a);
442
+ }
443
+ function t(e) {
444
+ if (!Array.isArray(e))
445
+ return process.env.NODE_ENV !== "production" && p("Invalid argument supplied to oneOfType, expected an instance of array."), w;
446
+ for (var a = 0; a < e.length; a++) {
447
+ var S = e[a];
448
+ if (typeof S != "function")
449
449
  return p(
450
- "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + h(k) + " at index " + f + "."
451
- ), b;
450
+ "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + H(S) + " at index " + a + "."
451
+ ), w;
452
452
  }
453
- function $(E, A, R, _, z) {
454
- for (var F = [], N = 0; N < n.length; N++) {
455
- var te = n[N], d = te(E, A, R, _, z, M);
453
+ function O(R, A, I, k, z) {
454
+ for (var W = [], N = 0; N < e.length; N++) {
455
+ var te = e[N], d = te(R, A, I, k, z, M);
456
456
  if (d == null)
457
457
  return null;
458
- d.data && v(d.data, "expectedType") && F.push(d.data.expectedType);
458
+ d.data && b(d.data, "expectedType") && W.push(d.data.expectedType);
459
459
  }
460
- var oe = F.length > 0 ? ", expected one of type [" + F.join(", ") + "]" : "";
461
- return new x("Invalid " + _ + " `" + z + "` supplied to " + ("`" + R + "`" + oe + "."));
460
+ var oe = W.length > 0 ? ", expected one of type [" + W.join(", ") + "]" : "";
461
+ return new q("Invalid " + k + " `" + z + "` supplied to " + ("`" + I + "`" + oe + "."));
462
462
  }
463
- return q($);
463
+ return _(O);
464
464
  }
465
- function t() {
466
- function n(f, k, $, E, A) {
467
- return c(f[k]) ? null : new x("Invalid " + E + " `" + A + "` supplied to " + ("`" + $ + "`, expected a ReactNode."));
465
+ function o() {
466
+ function e(a, S, O, R, A) {
467
+ return f(a[S]) ? null : new q("Invalid " + R + " `" + A + "` supplied to " + ("`" + O + "`, expected a ReactNode."));
468
468
  }
469
- return q(n);
469
+ return _(e);
470
470
  }
471
- function a(n, f, k, $, E) {
472
- return new x(
473
- (n || "React class") + ": " + f + " type `" + k + "." + $ + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + E + "`."
471
+ function u(e, a, S, O, R) {
472
+ return new q(
473
+ (e || "React class") + ": " + a + " type `" + S + "." + O + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + R + "`."
474
474
  );
475
475
  }
476
- function o(n) {
477
- function f(k, $, E, A, R) {
478
- var _ = k[$], z = D(_);
476
+ function r(e) {
477
+ function a(S, O, R, A, I) {
478
+ var k = S[O], z = v(k);
479
479
  if (z !== "object")
480
- return new x("Invalid " + A + " `" + R + "` of type `" + z + "` " + ("supplied to `" + E + "`, expected `object`."));
481
- for (var F in n) {
482
- var N = n[F];
480
+ return new q("Invalid " + A + " `" + I + "` of type `" + z + "` " + ("supplied to `" + R + "`, expected `object`."));
481
+ for (var W in e) {
482
+ var N = e[W];
483
483
  if (typeof N != "function")
484
- return a(E, A, R, F, G(N));
485
- var te = N(_, F, E, A, R + "." + F, M);
484
+ return u(R, A, I, W, h(N));
485
+ var te = N(k, W, R, A, I + "." + W, M);
486
486
  if (te)
487
487
  return te;
488
488
  }
489
489
  return null;
490
490
  }
491
- return q(f);
491
+ return _(a);
492
492
  }
493
- function r(n) {
494
- function f(k, $, E, A, R) {
495
- var _ = k[$], z = D(_);
493
+ function i(e) {
494
+ function a(S, O, R, A, I) {
495
+ var k = S[O], z = v(k);
496
496
  if (z !== "object")
497
- return new x("Invalid " + A + " `" + R + "` of type `" + z + "` " + ("supplied to `" + E + "`, expected `object`."));
498
- var F = T({}, k[$], n);
499
- for (var N in F) {
500
- var te = n[N];
501
- if (v(n, N) && typeof te != "function")
502
- return a(E, A, R, N, G(te));
497
+ return new q("Invalid " + A + " `" + I + "` of type `" + z + "` " + ("supplied to `" + R + "`, expected `object`."));
498
+ var W = j({}, S[O], e);
499
+ for (var N in W) {
500
+ var te = e[N];
501
+ if (b(e, N) && typeof te != "function")
502
+ return u(R, A, I, N, h(te));
503
503
  if (!te)
504
- return new x(
505
- "Invalid " + A + " `" + R + "` key `" + N + "` supplied to `" + E + "`.\nBad object: " + JSON.stringify(k[$], null, " ") + `
506
- Valid keys: ` + JSON.stringify(Object.keys(n), null, " ")
504
+ return new q(
505
+ "Invalid " + A + " `" + I + "` key `" + N + "` supplied to `" + R + "`.\nBad object: " + JSON.stringify(S[O], null, " ") + `
506
+ Valid keys: ` + JSON.stringify(Object.keys(e), null, " ")
507
507
  );
508
- var d = te(_, N, E, A, R + "." + N, M);
508
+ var d = te(k, N, R, A, I + "." + N, M);
509
509
  if (d)
510
510
  return d;
511
511
  }
512
512
  return null;
513
513
  }
514
- return q(f);
514
+ return _(a);
515
515
  }
516
- function c(n) {
517
- switch (typeof n) {
516
+ function f(e) {
517
+ switch (typeof e) {
518
518
  case "number":
519
519
  case "string":
520
520
  case "undefined":
521
521
  return !0;
522
522
  case "boolean":
523
- return !n;
523
+ return !e;
524
524
  case "object":
525
- if (Array.isArray(n))
526
- return n.every(c);
527
- if (n === null || y(n))
525
+ if (Array.isArray(e))
526
+ return e.every(f);
527
+ if (e === null || m(e))
528
528
  return !0;
529
- var f = m(n);
530
- if (f) {
531
- var k = f.call(n), $;
532
- if (f !== n.entries) {
533
- for (; !($ = k.next()).done; )
534
- if (!c($.value))
529
+ var a = C(e);
530
+ if (a) {
531
+ var S = a.call(e), O;
532
+ if (a !== e.entries) {
533
+ for (; !(O = S.next()).done; )
534
+ if (!f(O.value))
535
535
  return !1;
536
536
  } else
537
- for (; !($ = k.next()).done; ) {
538
- var E = $.value;
539
- if (E && !c(E[1]))
537
+ for (; !(O = S.next()).done; ) {
538
+ var R = O.value;
539
+ if (R && !f(R[1]))
540
540
  return !1;
541
541
  }
542
542
  } else
@@ -546,460 +546,464 @@ Valid keys: ` + JSON.stringify(Object.keys(n), null, " ")
546
546
  return !1;
547
547
  }
548
548
  }
549
- function l(n, f) {
550
- return n === "symbol" ? !0 : f ? f["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && f instanceof Symbol : !1;
549
+ function c(e, a) {
550
+ return e === "symbol" ? !0 : a ? a["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && a instanceof Symbol : !1;
551
551
  }
552
- function D(n) {
553
- var f = typeof n;
554
- return Array.isArray(n) ? "array" : n instanceof RegExp ? "object" : l(f, n) ? "symbol" : f;
552
+ function v(e) {
553
+ var a = typeof e;
554
+ return Array.isArray(e) ? "array" : e instanceof RegExp ? "object" : c(a, e) ? "symbol" : a;
555
555
  }
556
- function G(n) {
557
- if (typeof n > "u" || n === null)
558
- return "" + n;
559
- var f = D(n);
560
- if (f === "object") {
561
- if (n instanceof Date)
556
+ function h(e) {
557
+ if (typeof e > "u" || e === null)
558
+ return "" + e;
559
+ var a = v(e);
560
+ if (a === "object") {
561
+ if (e instanceof Date)
562
562
  return "date";
563
- if (n instanceof RegExp)
563
+ if (e instanceof RegExp)
564
564
  return "regexp";
565
565
  }
566
- return f;
566
+ return a;
567
567
  }
568
- function h(n) {
569
- var f = G(n);
570
- switch (f) {
568
+ function H(e) {
569
+ var a = h(e);
570
+ switch (a) {
571
571
  case "array":
572
572
  case "object":
573
- return "an " + f;
573
+ return "an " + a;
574
574
  case "boolean":
575
575
  case "date":
576
576
  case "regexp":
577
- return "a " + f;
577
+ return "a " + a;
578
578
  default:
579
- return f;
579
+ return a;
580
580
  }
581
581
  }
582
- function B(n) {
583
- return !n.constructor || !n.constructor.name ? P : n.constructor.name;
582
+ function K(e) {
583
+ return !e.constructor || !e.constructor.name ? E : e.constructor.name;
584
584
  }
585
- return j.checkPropTypes = C, j.resetWarningCache = C.resetWarningCache, j.PropTypes = j, j;
586
- }, fe;
585
+ return P.checkPropTypes = T, P.resetWarningCache = T.resetWarningCache, P.PropTypes = P, P;
586
+ }, pe;
587
587
  }
588
- var pe, Te;
589
- function Me() {
590
- if (Te) return pe;
591
- Te = 1;
592
- var i = /* @__PURE__ */ he();
593
- function T() {
588
+ var he, Ee;
589
+ function Ae() {
590
+ if (Ee) return he;
591
+ Ee = 1;
592
+ var n = /* @__PURE__ */ ye();
593
+ function j() {
594
594
  }
595
595
  function M() {
596
596
  }
597
- return M.resetWarningCache = T, pe = function() {
598
- function v(b, y, w, g, S, m) {
599
- if (m !== i) {
600
- var P = new Error(
597
+ return M.resetWarningCache = j, he = function() {
598
+ function b(w, m, g, x, y, C) {
599
+ if (C !== n) {
600
+ var E = new Error(
601
601
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
602
602
  );
603
- throw P.name = "Invariant Violation", P;
603
+ throw E.name = "Invariant Violation", E;
604
604
  }
605
605
  }
606
- v.isRequired = v;
607
- function C() {
608
- return v;
606
+ b.isRequired = b;
607
+ function T() {
608
+ return b;
609
609
  }
610
610
  var p = {
611
- array: v,
612
- bigint: v,
613
- bool: v,
614
- func: v,
615
- number: v,
616
- object: v,
617
- string: v,
618
- symbol: v,
619
- any: v,
620
- arrayOf: C,
621
- element: v,
622
- elementType: v,
623
- instanceOf: C,
624
- node: v,
625
- objectOf: C,
626
- oneOf: C,
627
- oneOfType: C,
628
- shape: C,
629
- exact: C,
611
+ array: b,
612
+ bigint: b,
613
+ bool: b,
614
+ func: b,
615
+ number: b,
616
+ object: b,
617
+ string: b,
618
+ symbol: b,
619
+ any: b,
620
+ arrayOf: T,
621
+ element: b,
622
+ elementType: b,
623
+ instanceOf: T,
624
+ node: b,
625
+ objectOf: T,
626
+ oneOf: T,
627
+ oneOfType: T,
628
+ shape: T,
629
+ exact: T,
630
630
  checkPropTypes: M,
631
- resetWarningCache: T
631
+ resetWarningCache: j
632
632
  };
633
633
  return p.PropTypes = p, p;
634
- }, pe;
634
+ }, he;
635
635
  }
636
- var Ee;
637
- function Ae() {
638
- if (Ee) return se.exports;
639
- if (Ee = 1, process.env.NODE_ENV !== "production") {
640
- var i = Oe(), T = !0;
641
- se.exports = /* @__PURE__ */ qe()(i.isElement, T);
636
+ var je;
637
+ function ze() {
638
+ if (je) return se.exports;
639
+ if (je = 1, process.env.NODE_ENV !== "production") {
640
+ var n = Re(), j = !0;
641
+ se.exports = /* @__PURE__ */ Me()(n.isElement, j);
642
642
  } else
643
- se.exports = /* @__PURE__ */ Me()();
643
+ se.exports = /* @__PURE__ */ Ae()();
644
644
  return se.exports;
645
645
  }
646
- var ze = /* @__PURE__ */ Ae();
647
- const u = /* @__PURE__ */ $e(ze);
648
- var Z = {}, je;
649
- function Ne() {
650
- if (je) return Z;
651
- je = 1;
652
- function i(e) {
653
- return e ? /^[a-zA-Z][a-zA-Z0-9_-]{2,50}$/.test(e) : !1;
654
- }
655
- Z.isValidUserName = i;
656
- function T(e) {
657
- return e ? /^[A-Za-z' -]{2,50}$/.test(e) : !1;
658
- }
659
- Z.isValidName = T;
660
- function M(e) {
661
- return e ? /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/.test(e) : !1;
662
- }
663
- Z.isValidEmail = M;
664
- function v(e) {
665
- return e ? /^[0-9]{10,15}$/g.test(e) : !1;
666
- }
667
- Z.isValidPhoneNum = v;
668
- function C(e) {
669
- return e ? /^[a-zA-Z0-9.\-\(\) ]{2,}$/.test(e) : !1;
670
- }
671
- Z.isValidOrganisationName = C;
672
- function p(e) {
673
- return !(!e || e.length < 6 || /[A-Z]/.test(e) === !1 || /[a-z]/.test(e) === !1 || /[0-9]/.test(e) === !1 || /[\s]/.test(e) || /[\][!"#$%&'()*+,./:;<=>?@^\\_`{|}~-]/.test(e) === !1);
674
- }
675
- Z.isValidPassword = p;
676
- function b(e) {
677
- let t = e.getFullYear(), a = e.getMonth() + 1;
678
- a = w(a, 2);
679
- let o = e.getDate();
680
- return o = w(o, 2), `${t}-${a}-${o}`;
681
- }
682
- Z.timeStampYyyyMmDd = b;
683
- function y(e) {
684
- let t = w(e.getHours(), 2), a = w(e.getMinutes(), 2), o = w(e.getSeconds(), 2), r = w(e.getMilliseconds(), 3);
685
- return `${b(e)}T${t}:${a}:${o}.${r}`;
686
- }
687
- Z.timeStampString = y;
688
- function w(e, t) {
689
- let a = e + "";
690
- const o = t - a.length;
691
- for (let r = 1; r <= o; r++)
692
- a = "0" + a;
693
- return a;
694
- }
695
- Z.addLeadingZeros = w;
696
- function g(e) {
697
- return new Intl.NumberFormat("en-US", { style: "currency", currency: "ZAR" }).format(e).replace(/ZAR/gi, "R");
698
- }
699
- Z.toZarCurrencyFormat = g;
700
- function S(e) {
701
- if (Object.prototype.toString.call(e) !== "[object Object]") return e instanceof Date ? new Date(e) : (["string", "number", "boolean"].includes(typeof e), e);
702
- const t = [{ ...e }];
703
- let a = 0;
704
- for (; a < t.length; ) {
705
- let o = t[a];
706
- if (Object.prototype.toString.call(o) === "[object Object]")
707
- for (let r in o)
708
- o[r] instanceof Date ? o[r] = new Date(o[r]) : Object.prototype.toString.call(o[r]) === "[object Object]" && (o[r] = { ...o[r] }), t.push(o[r]);
709
- a++;
710
- }
711
- return t[0];
712
- }
713
- Z.deepClone = S;
714
- function m(e) {
715
- const t = [{ value: e }];
716
- let a = 0;
717
- for (; a < t.length; ) {
718
- const o = t[a];
719
- if (Object.prototype.toString.call(o.value) === "[object Object]") {
720
- for (const r in o.value) {
721
- let c = o.path ? o.path + "." + r : r;
722
- t.push(
723
- { value: o.value[r], path: c }
646
+ var Ne = /* @__PURE__ */ ze();
647
+ const l = /* @__PURE__ */ _e(Ne);
648
+ var J = {}, Oe;
649
+ function Le() {
650
+ if (Oe) return J;
651
+ Oe = 1;
652
+ function n(t) {
653
+ return t ? /^[a-zA-Z][a-zA-Z0-9_-]{2,50}$/.test(t) : !1;
654
+ }
655
+ J.isValidUserName = n;
656
+ function j(t) {
657
+ return t ? /^[A-Za-z' -]{2,50}$/.test(t) : !1;
658
+ }
659
+ J.isValidName = j;
660
+ function M(t) {
661
+ return t ? /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/.test(t) : !1;
662
+ }
663
+ J.isValidEmail = M;
664
+ function b(t) {
665
+ return t ? /^[0-9]{10,15}$/g.test(t) : !1;
666
+ }
667
+ J.isValidPhoneNum = b;
668
+ function T(t) {
669
+ return t ? /^[a-zA-Z0-9.\-\(\) ]{2,}$/.test(t) : !1;
670
+ }
671
+ J.isValidOrganisationName = T;
672
+ function p(t) {
673
+ return !(!t || t.length < 6 || /[A-Z]/.test(t) === !1 || /[a-z]/.test(t) === !1 || /[0-9]/.test(t) === !1 || /[\s]/.test(t) || /[\][!"#$%&'()*+,./:;<=>?@^\\_`{|}~-]/.test(t) === !1);
674
+ }
675
+ J.isValidPassword = p;
676
+ function w(t) {
677
+ let o = t.getFullYear(), u = t.getMonth() + 1;
678
+ u = g(u, 2);
679
+ let r = t.getDate();
680
+ return r = g(r, 2), `${o}-${u}-${r}`;
681
+ }
682
+ J.timeStampYyyyMmDd = w;
683
+ function m(t) {
684
+ let o = g(t.getHours(), 2), u = g(t.getMinutes(), 2), r = g(t.getSeconds(), 2), i = g(t.getMilliseconds(), 3);
685
+ return `${w(t)}T${o}:${u}:${r}.${i}`;
686
+ }
687
+ J.timeStampString = m;
688
+ function g(t, o) {
689
+ let u = t + "";
690
+ const r = o - u.length;
691
+ for (let i = 1; i <= r; i++)
692
+ u = "0" + u;
693
+ return u;
694
+ }
695
+ J.addLeadingZeros = g;
696
+ function x(t) {
697
+ return new Intl.NumberFormat("en-US", { style: "currency", currency: "ZAR" }).format(t).replace(/ZAR/gi, "R");
698
+ }
699
+ J.toZarCurrencyFormat = x;
700
+ function y(t) {
701
+ if (Object.prototype.toString.call(t) !== "[object Object]") return t instanceof Date ? new Date(t) : (["string", "number", "boolean"].includes(typeof t), t);
702
+ const o = [{ ...t }];
703
+ let u = 0;
704
+ for (; u < o.length; ) {
705
+ let r = o[u];
706
+ if (Object.prototype.toString.call(r) === "[object Object]")
707
+ for (let i in r)
708
+ r[i] instanceof Date ? r[i] = new Date(r[i]) : Object.prototype.toString.call(r[i]) === "[object Object]" && (r[i] = { ...r[i] }), o.push(r[i]);
709
+ u++;
710
+ }
711
+ return o[0];
712
+ }
713
+ J.deepClone = y;
714
+ function C(t) {
715
+ const o = [{ value: t }];
716
+ let u = 0;
717
+ for (; u < o.length; ) {
718
+ const r = o[u];
719
+ if (Object.prototype.toString.call(r.value) === "[object Object]") {
720
+ for (const i in r.value) {
721
+ let f = r.path ? r.path + "." + i : i;
722
+ o.push(
723
+ { value: r.value[i], path: f }
724
724
  );
725
725
  }
726
- o.remove = !0;
726
+ r.remove = !0;
727
727
  }
728
- a++;
728
+ u++;
729
729
  }
730
- return t.filter((o) => !o.remove).map((o) => o.path);
730
+ return o.filter((r) => !r.remove).map((r) => r.path);
731
731
  }
732
- Z.getPaths = m;
733
- function P(e) {
734
- let t = S(e), a = 0;
735
- const o = m(t).toSorted();
732
+ J.getPaths = C;
733
+ function E(t) {
734
+ let o = y(t), u = 0;
735
+ const r = C(o).toSorted();
736
736
  sortedObj = {};
737
- for (a in o) {
738
- const r = o[a], c = j(t, r);
739
- J(sortedObj, r, c);
737
+ for (u in r) {
738
+ const i = r[u], f = P(o, i);
739
+ Y(sortedObj, i, f);
740
740
  }
741
741
  return sortedObj;
742
742
  }
743
- Z.getSortedObject = P;
744
- function j(e, t, a = void 0) {
745
- let o = t.split("."), r = e;
746
- for (let c in o) {
747
- let l = o[c];
748
- if (r[l] === void 0 || (r = r[l], r === void 0))
749
- return a;
750
- }
751
- return r;
752
- }
753
- Z.get = j;
754
- function J(e, t, a) {
755
- let o = e, r = t.split(".");
756
- for (let c in r) {
757
- let l = r[c];
758
- c < r.length - 1 ? (l in o || (o[l] = {}), o = o[l]) : o[l] = a;
759
- }
760
- }
761
- Z.set = J;
762
- function x(e, t) {
763
- let a = t.split("."), o = e;
764
- for (let r in a) {
765
- let c = a[r];
766
- if (Object.prototype.toString.call(o) !== "[object Object]" || o[c] === void 0)
743
+ J.getSortedObject = E;
744
+ function P(t, o, u = void 0) {
745
+ let r = o.split("."), i = t;
746
+ for (let f in r) {
747
+ let c = r[f];
748
+ if (i[c] === void 0 || (i = i[c], i === void 0))
749
+ return u;
750
+ }
751
+ return i;
752
+ }
753
+ J.get = P;
754
+ function Y(t, o, u) {
755
+ let r = t, i = o.split(".");
756
+ for (let f in i) {
757
+ let c = i[f];
758
+ f < i.length - 1 ? (c in r || (r[c] = {}), r = r[c]) : r[c] = u;
759
+ }
760
+ }
761
+ J.set = Y;
762
+ function q(t, o) {
763
+ let u = o.split("."), r = t;
764
+ for (let i in u) {
765
+ let f = u[i];
766
+ if (Object.prototype.toString.call(r) !== "[object Object]" || r[f] === void 0)
767
767
  return;
768
- r < a.length - 1 ? o = o[c] : delete o[c];
768
+ i < u.length - 1 ? r = r[f] : delete r[f];
769
769
  }
770
770
  }
771
- Z.unset = x;
772
- function q(e, ...t) {
773
- if (!t || !t.length)
771
+ J.unset = q;
772
+ function _(t, ...o) {
773
+ if (!o || !o.length)
774
774
  throw new Error("fields must be specified");
775
- const a = m(e);
776
- let o = 0;
777
- for (const r in a) {
778
- const c = a[r];
779
- if (t.includes(c))
780
- o++;
775
+ const u = C(t);
776
+ let r = 0;
777
+ for (const i in u) {
778
+ const f = u[i];
779
+ if (o.includes(f))
780
+ r++;
781
781
  else
782
782
  return !1;
783
783
  }
784
- return o > 0;
784
+ return r > 0;
785
785
  }
786
- Z.hasOnly = q;
787
- function V(e, ...t) {
788
- if (!t || !t.length)
786
+ J.hasOnly = _;
787
+ function U(t, ...o) {
788
+ if (!o || !o.length)
789
789
  throw new Error("fields must be specified");
790
- const a = m(e);
791
- let o = 0;
792
- for (const r in t) {
793
- const c = t[r];
794
- if (a.includes(c))
795
- o++;
790
+ const u = C(t);
791
+ let r = 0;
792
+ for (const i in o) {
793
+ const f = o[i];
794
+ if (u.includes(f))
795
+ r++;
796
796
  else
797
797
  return !1;
798
798
  }
799
- return o === t.length;
799
+ return r === o.length;
800
800
  }
801
- Z.hasAll = V;
802
- function H(e, ...t) {
803
- return q(e, ...t) && V(e, ...t);
801
+ J.hasAll = U;
802
+ function X(t, ...o) {
803
+ return _(t, ...o) && U(t, ...o);
804
804
  }
805
- Z.hasOnlyAll = H;
806
- function I(e, t, a = 0, o = "asc") {
807
- const r = ["asc", "desc"];
808
- if (!["asc", "desc"].includes(o))
809
- throw new Error(`arraySortDir must be one of ${r}`);
810
- if (e.length === 0)
805
+ J.hasOnlyAll = X;
806
+ function D(t, o, u = 0, r = "asc") {
807
+ const i = ["asc", "desc"];
808
+ if (!["asc", "desc"].includes(r))
809
+ throw new Error(`arraySortDir must be one of ${i}`);
810
+ if (t.length === 0)
811
811
  return -1;
812
- let c = a, l = e.length - 1;
813
- for (; c < l; ) {
814
- if (O(e[c], t) === 0)
812
+ let f = u, c = t.length - 1;
813
+ for (; f < c; ) {
814
+ if ($(t[f], o) === 0)
815
+ return f;
816
+ if ($(t[c], o) === 0)
815
817
  return c;
816
- if (O(e[l], t) === 0)
817
- return l;
818
- const D = Math.trunc((c + l) / 2), G = O(e[D], t, o);
819
- if (G < 0)
820
- c = D + 1;
821
- else if (G > 0)
822
- l = D - 1;
818
+ const v = Math.trunc((f + c) / 2), h = $(t[v], o, r);
819
+ if (h < 0)
820
+ f = v + 1;
821
+ else if (h > 0)
822
+ c = v - 1;
823
823
  else
824
- return D;
824
+ return v;
825
825
  }
826
- return c;
826
+ return f;
827
827
  }
828
- Z.binarySearch = I;
829
- function O(e, t, a = "asc") {
830
- if (!["asc", "desc"].includes(a))
831
- throw new Error(`sortDir must be one of ${a}`);
832
- const o = a === "desc" ? -1 : 1;
833
- return e > t ? o : e < t ? -o : 0;
828
+ J.binarySearch = D;
829
+ function $(t, o, u = "asc") {
830
+ if (!["asc", "desc"].includes(u))
831
+ throw new Error(`sortDir must be one of ${u}`);
832
+ const r = u === "desc" ? -1 : 1;
833
+ return t > o ? r : t < o ? -r : 0;
834
834
  }
835
- Z.compare = O;
836
- function s(e, t, a = 0, ...o) {
837
- if (e.length === 0)
835
+ J.compare = $;
836
+ function s(t, o, u = 0, ...r) {
837
+ if (t.length === 0)
838
838
  return -1;
839
- let r = a, c = e.length - 1;
840
- for (; r < c; ) {
841
- if (W(e[r], t, ...o) === 0)
842
- return r;
843
- if (W(e[c], t, ...o) === 0)
844
- return c;
845
- let l = Math.trunc((r + c) / 2);
846
- if (W(e[l], t, ...o) < 0)
847
- r = l + 1;
848
- else if (W(e[l], t, ...o) > 0)
849
- c = l - 1;
839
+ let i = u, f = t.length - 1;
840
+ for (; i < f; ) {
841
+ if (Z(t[i], o, ...r) === 0)
842
+ return i;
843
+ if (Z(t[f], o, ...r) === 0)
844
+ return f;
845
+ let c = Math.trunc((i + f) / 2);
846
+ if (Z(t[c], o, ...r) < 0)
847
+ i = c + 1;
848
+ else if (Z(t[c], o, ...r) > 0)
849
+ f = c - 1;
850
850
  else
851
- return l;
851
+ return c;
852
852
  }
853
- return r;
853
+ return i;
854
854
  }
855
- Z.binarySearchObj = s;
856
- function X(e, t, a, ...o) {
857
- let r = a, c = e.length - 1;
858
- if (r >= e.length)
855
+ J.binarySearchObj = s;
856
+ function B(t, o, u, ...r) {
857
+ let i = u, f = t.length - 1;
858
+ if (i >= t.length)
859
859
  throw new Error("startFrom is outside the bounds of the array.");
860
- if (W(t, e[r], ...o) > 0)
860
+ if (Z(o, t[i], ...r) > 0)
861
861
  throw new Error("targetObj is to the right ('greater than') objArray[startFrom].");
862
- for (; r < c; ) {
863
- let l = Math.trunc((r + c) / 2);
864
- W(t, e[l], ...o) === 0 ? r = l + 1 : W(t, e[l], ...o) < 0 && (c = l);
862
+ for (; i < f; ) {
863
+ let c = Math.trunc((i + f) / 2);
864
+ Z(o, t[c], ...r) === 0 ? i = c + 1 : Z(o, t[c], ...r) < 0 && (f = c);
865
865
  }
866
- return W(t, e[r], ...o) === 0 ? -1 : r;
866
+ return Z(o, t[i], ...r) === 0 ? -1 : i;
867
867
  }
868
- Z.getNextDifferent = X;
869
- function K(e, t, ...a) {
870
- if (e.length <= 1)
871
- return [...e];
872
- if (typeof t != "boolean")
868
+ J.getNextDifferent = B;
869
+ function G(t, o, ...u) {
870
+ if (t.length <= 1)
871
+ return [...t];
872
+ if (typeof o != "boolean")
873
873
  throw new Error("firstOfDuplicates must be boolean true or false.");
874
- const o = [];
875
- let r = 0;
876
- for (; r < e.length - 1 && (t && o.push(e[r]), r = X(e, e[r], r + 1, ...a), !(r < 0)); ) {
877
- let c = r - 1;
878
- t || o.push(e[c]);
874
+ const r = [];
875
+ let i = 0;
876
+ for (; i < t.length - 1 && (o && r.push(t[i]), i = B(t, t[i], i + 1, ...u), !(i < 0)); ) {
877
+ let f = i - 1;
878
+ o || r.push(t[f]);
879
879
  }
880
- return o.length === 0 ? t ? o.push(e[0]) : o.push(e[e.length - 1]) : W(o[o.length - 1], e[e.length - 1], ...a) !== 0 && o.push(e[e.length - 1]), o;
880
+ return r.length === 0 ? o ? r.push(t[0]) : r.push(t[t.length - 1]) : Z(r[r.length - 1], t[t.length - 1], ...u) !== 0 && r.push(t[t.length - 1]), r;
881
881
  }
882
- Z.getObjArrayWithNoDuplicates = K;
883
- function W(e, t, ...a) {
884
- if (a.length === 0)
882
+ J.getObjArrayWithNoDuplicates = G;
883
+ function Z(t, o, ...u) {
884
+ if (u.length === 0)
885
885
  throw new Error("comparisonFields not supplied!");
886
- const o = ["", "asc", "desc"];
887
- for (const r in a) {
888
- const c = a[r].split(" "), l = c[0];
889
- let D = "";
890
- if (c.length === 2 && (D = c[1]), !o.includes(D))
891
- throw new Error("Sort direction must be one of " + o.toString());
892
- const G = j(e, l), h = j(t, l), B = D === "desc" ? -1 : 1;
893
- if (G > h)
894
- return B;
895
- if (G < h)
896
- return -B;
886
+ const r = ["", "asc", "desc"];
887
+ for (const i in u) {
888
+ const f = u[i].split(" "), c = f[0];
889
+ let v = "";
890
+ if (f.length === 2 && (v = f[1]), !r.includes(v))
891
+ throw new Error("Sort direction must be one of " + r.toString());
892
+ const h = P(t, c), H = P(o, c), K = v === "desc" ? -1 : 1;
893
+ if (h > H)
894
+ return K;
895
+ if (h < H)
896
+ return -K;
897
897
  }
898
898
  return 0;
899
899
  }
900
- return Z.objCompare = W, Z;
900
+ return J.objCompare = Z, J;
901
901
  }
902
- var ne = Ne();
903
- function Le({
904
- label: i,
902
+ var ne = Le();
903
+ function Ye({
904
+ label: n,
905
905
  // label with which to describe the dropdown.
906
- data: T,
906
+ data: j,
907
907
  // Primitive type array.
908
908
  sortOrder: M = "asc",
909
- onItemSelected: v = null,
909
+ onItemSelected: b = null,
910
910
  // Function to pass on the value of the selected item to the parent component
911
- selected: C = null,
911
+ selected: T = null,
912
912
  // Initial selected item.
913
913
  dropdownStyle: p,
914
914
  // Styling object with fields {color, backgroundColor, borderColor (optional), fontSize}.
915
- isDisabled: b = !1
915
+ isDisabled: w = !1
916
916
  }) {
917
- const [y, w] = ee(!1), [g, S] = ee(""), m = re(() => T.toSorted(O), [T]), P = re(() => {
918
- if (g.length === 0)
917
+ const m = ce(), [g, x] = ee(!1), [y, C] = ee(""), E = re(() => j.toSorted(s), [j]), P = re(() => {
918
+ if (y.length === 0)
919
919
  return [];
920
- const t = g.toUpperCase();
921
- return m.filter((a) => a.toUpperCase().includes(t));
922
- }, [m, g]), j = re(() => g.length === 0 ? m : P, [m, g]), [J, x] = ee(""), [q, V] = ee(null);
920
+ const r = y.toUpperCase();
921
+ return E.filter((i) => i.toUpperCase().includes(r));
922
+ }, [E, y]), Y = re(() => y.length === 0 ? E : P, [E, y]), [q, _] = ee(""), [U, X] = ee(null);
923
923
  re(() => {
924
- let t = "";
925
- if (q)
926
- t = q;
927
- else if (C) {
928
- const a = T.findIndex((o) => o === C);
929
- a >= 0 && (t = T[a]);
930
- }
931
- return x(t), t;
932
- }, [C, q]);
933
- const H = (() => {
934
- const t = {
924
+ let r = "";
925
+ if (U)
926
+ r = U;
927
+ else if (T) {
928
+ const i = j.findIndex((f) => f === T);
929
+ i >= 0 && (r = j[i]);
930
+ }
931
+ return _(r), r;
932
+ }, [T, U]);
933
+ const D = (() => {
934
+ const r = {
935
935
  backgroundColor: p?.backgroundColor,
936
936
  color: p?.color
937
937
  };
938
- return p?.fontSize && (t.fontSize = p?.fontSize), t;
939
- })(), I = p?.borderColor;
940
- function O(t, a) {
941
- return ne.compare(t, a, M);
938
+ return p?.fontSize && (r.fontSize = p?.fontSize), r;
939
+ })(), $ = p?.borderColor;
940
+ function s(r, i) {
941
+ return ne.compare(r, i, M);
942
942
  }
943
- function s(t) {
944
- S(t.target.value), x(t.target.value), P.length === 0 ? W() : e();
943
+ function B(r) {
944
+ C(r.target.value), _(r.target.value), P.length === 0 ? t() : o();
945
945
  }
946
- async function X(t) {
947
- x(t), S(""), V(t), v !== null && v(t), W();
946
+ async function G(r) {
947
+ _(r), C(""), X(r), b !== null && b(r), t();
948
948
  }
949
- function K() {
950
- y ? W() : e();
949
+ function Z() {
950
+ g ? t() : o();
951
951
  }
952
- function W() {
953
- w(!1);
952
+ function t() {
953
+ x(!1);
954
954
  }
955
- function e() {
956
- j.length > 0 && w(!0);
955
+ function o() {
956
+ Y.length > 0 && x(!0);
957
957
  }
958
+ const u = {
959
+ dropdownSearch: `dropdownSearch-${m}`,
960
+ dropdown: `dropdown-${m}`
961
+ };
958
962
  return /* @__PURE__ */ Q(
959
963
  "div",
960
964
  {
961
965
  className: `dropdown-js dropdown-js-rounded
962
- ${I && `dropdown-js-border ${I}`}`,
963
- style: { ...b ? { pointerEvents: "none" } : {} },
966
+ ${$ && `dropdown-js-border ${$}`}`,
967
+ style: { ...w ? { pointerEvents: "none" } : {} },
964
968
  children: [
965
- /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: H, children: [
969
+ /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: D, children: [
966
970
  /* @__PURE__ */ L(
967
971
  "input",
968
972
  {
969
- id: "dropdownSearch",
973
+ id: u.dropdownSearch,
970
974
  name: "dropdownSearch",
971
975
  className: "dropdown-js-input dropdown-js-rounded",
972
976
  autoComplete: "off",
973
977
  type: "text",
974
- style: H,
978
+ style: D,
975
979
  role: "combobox",
976
- "aria-placeholder": `Type to Search for ${i}`,
980
+ "aria-placeholder": `Type to Search for ${n}`,
977
981
  "aria-required": !0,
978
- "aria-controls": "dropdown",
982
+ "aria-controls": u.dropdown,
979
983
  "aria-autocomplete": "list",
980
984
  "aria-haspopup": "listbox",
981
- "aria-expanded": y,
982
- onChange: (t) => s(t),
983
- disabled: b,
984
- placeholder: `Type to Search for ${i}`,
985
- value: J
985
+ "aria-expanded": g,
986
+ onChange: (r) => B(r),
987
+ disabled: w,
988
+ placeholder: `Type to Search for ${n}`,
989
+ value: q
986
990
  }
987
991
  ),
988
992
  /* @__PURE__ */ L(
989
993
  "div",
990
994
  {
991
995
  className: "dropdown-js-arrow-container dropdown-js-padding dropdown-js-rounded",
992
- "aria-expanded": y,
996
+ "aria-expanded": g,
993
997
  "aria-controls": "multiSelectionDropdown",
994
- "aria-label": `${i} options`,
995
- onClick: (t) => K(),
998
+ "aria-label": `${n} options`,
999
+ onClick: (r) => Z(),
996
1000
  children: /* @__PURE__ */ L(
997
1001
  "span",
998
1002
  {
999
1003
  className: "dropdown-js-arrow dropdown-js-padding",
1000
- "aria-label": `${i} options`,
1001
- "aria-expanded": y,
1002
- children: y ? "-" : "+"
1004
+ "aria-label": `${n} options`,
1005
+ "aria-expanded": g,
1006
+ children: g ? "-" : "+"
1003
1007
  }
1004
1008
  )
1005
1009
  }
@@ -1008,28 +1012,28 @@ function Le({
1008
1012
  /* @__PURE__ */ L(
1009
1013
  "div",
1010
1014
  {
1011
- className: `dropdown-js-padding dropdown-js-menu ${!y && "dropdown-js-hide"}`,
1012
- id: "dropDown",
1015
+ className: `dropdown-js-padding dropdown-js-menu ${!g && "dropdown-js-hide"}`,
1016
+ id: u.dropdown,
1013
1017
  name: "dropDown",
1014
1018
  role: "listbox",
1015
- "aria-expanded": y,
1016
- disabled: b,
1017
- "aria-label": i,
1018
- style: { ...H, marginTop: "3.5px" },
1019
- children: j.map((t, a) => /* @__PURE__ */ Q(
1019
+ "aria-expanded": g,
1020
+ disabled: w,
1021
+ "aria-label": n,
1022
+ style: { ...D, marginTop: "3.5px" },
1023
+ children: Y.map((r, i) => /* @__PURE__ */ Q(
1020
1024
  "div",
1021
1025
  {
1022
- name: t,
1026
+ name: r,
1023
1027
  role: "option",
1024
- "aria-label": t,
1028
+ "aria-label": r,
1025
1029
  style: { cursor: "pointer" },
1026
- onClick: (o) => X(t),
1030
+ onClick: (f) => G(r),
1027
1031
  children: [
1028
- t,
1029
- a < j.length - 1 && /* @__PURE__ */ L("hr", { style: { borderColor: H.color } })
1032
+ r,
1033
+ i < Y.length - 1 && /* @__PURE__ */ L("hr", { style: { borderColor: D.color } })
1030
1034
  ]
1031
1035
  },
1032
- `${a}#${t}`
1036
+ `${i}#${r}`
1033
1037
  ))
1034
1038
  }
1035
1039
  )
@@ -1037,150 +1041,154 @@ function Le({
1037
1041
  }
1038
1042
  );
1039
1043
  }
1040
- Le.propTypes = {
1041
- label: u.string.isRequired,
1042
- data: u.array.isRequired,
1043
- sortOrder: u.string,
1044
- selected: u.any,
1045
- isDisabled: u.bool,
1046
- onItemSelected: u.func,
1047
- dropdownStyle: u.shape({
1048
- color: u.string.isRequired,
1044
+ Ye.propTypes = {
1045
+ label: l.string.isRequired,
1046
+ data: l.array.isRequired,
1047
+ sortOrder: l.string,
1048
+ selected: l.any,
1049
+ isDisabled: l.bool,
1050
+ onItemSelected: l.func,
1051
+ dropdownStyle: l.shape({
1052
+ color: l.string.isRequired,
1049
1053
  // text color
1050
- backgroundColor: u.string.isRequired,
1051
- fontSize: u.string,
1052
- borderColor: u.string
1054
+ backgroundColor: l.string.isRequired,
1055
+ fontSize: l.string,
1056
+ borderColor: l.string
1053
1057
  }),
1054
- buttonStyle: u.shape({
1055
- color: u.string.isRequired,
1058
+ buttonStyle: l.shape({
1059
+ color: l.string.isRequired,
1056
1060
  // text color
1057
- backgroundColor: u.string.isRequired,
1058
- fontSize: u.string,
1059
- borderColor: u.string
1061
+ backgroundColor: l.string.isRequired,
1062
+ fontSize: l.string,
1063
+ borderColor: l.string
1060
1064
  })
1061
1065
  };
1062
- function Ye({
1063
- label: i,
1066
+ function Ue({
1067
+ label: n,
1064
1068
  // label with which to describe the dropdown.
1065
- data: T,
1069
+ data: j,
1066
1070
  sortFields: M,
1067
- selected: v = null,
1068
- displayName: C,
1071
+ selected: b = null,
1072
+ displayName: T,
1069
1073
  // the name of the field that will be used for displaying the list items to the user.
1070
1074
  valueName: p,
1071
1075
  // the name of the field that will be used as the underlying unique value of each list item.
1072
- isDisabled: b = !1,
1073
- onItemSelected: y = null,
1074
- dropdownStyle: w
1076
+ isDisabled: w = !1,
1077
+ onItemSelected: m = null,
1078
+ dropdownStyle: g
1075
1079
  }) {
1076
- const [g, S] = ee(null), [m, P] = ee(""), [j, J] = ee(""), x = re(() => T.toSorted(e), [T]), q = re(() => {
1077
- if (j.length === 0)
1080
+ const x = ce(), [y, C] = ee(null), [E, P] = ee(""), [Y, q] = ee(""), _ = re(() => j.toSorted(o), [j]), U = re(() => {
1081
+ if (Y.length === 0)
1078
1082
  return [];
1079
- const l = j.toUpperCase();
1080
- return x.filter((D) => D[C].toUpperCase().toUpperCase().includes(l));
1081
- }, [j]), [V, H] = ee(""), [I, O] = ee(null);
1083
+ const h = Y.toUpperCase();
1084
+ return _.filter((H) => H[T].toUpperCase().toUpperCase().includes(h));
1085
+ }, [Y]), [X, D] = ee(""), [$, s] = ee(null);
1082
1086
  re(() => {
1083
- let l;
1084
- if (I)
1085
- l = { ...I };
1086
- else if (v) {
1087
- const D = t(), G = T.findIndex((h) => ne.get(h, ...D) === ne.get(v, ...D));
1088
- G >= 0 && (l = T[G]);
1089
- }
1090
- return l && H(l[C]), l;
1091
- }, [v, I]);
1092
- const s = re(() => j.length > 0 ? q : x, [j, x]), X = (() => {
1093
- const l = {
1094
- backgroundColor: w?.backgroundColor,
1095
- color: w?.color
1087
+ let h;
1088
+ if ($)
1089
+ h = { ...$ };
1090
+ else if (b) {
1091
+ const H = u(), K = j.findIndex((e) => ne.get(e, ...H) === ne.get(b, ...H));
1092
+ K >= 0 && (h = j[K]);
1093
+ }
1094
+ return h && D(h[T]), h;
1095
+ }, [b, $]);
1096
+ const B = re(() => Y.length > 0 ? U : _, [Y, _]), G = (() => {
1097
+ const h = {
1098
+ backgroundColor: g?.backgroundColor,
1099
+ color: g?.color
1096
1100
  };
1097
- return w?.fontSize && (l.fontSize = w?.fontSize), l;
1098
- })(), K = w?.borderColor;
1099
- async function W(l) {
1100
- J((D) => l.target.value), H((D) => l.target.value), q.length > 0 ? c() : r();
1101
+ return g?.fontSize && (h.fontSize = g?.fontSize), h;
1102
+ })(), Z = g?.borderColor;
1103
+ async function t(h) {
1104
+ q((H) => h.target.value), D((H) => h.target.value), U.length > 0 ? c() : f();
1101
1105
  }
1102
- function e(l, D) {
1103
- return ne.objCompare(l, D, ...M);
1106
+ function o(h, H) {
1107
+ return ne.objCompare(h, H, ...M);
1104
1108
  }
1105
- function t() {
1106
- let l = m;
1107
- return l || (T.length > 0 && (l = ne.getPaths(T[0])), P(l)), l;
1109
+ function u() {
1110
+ let h = E;
1111
+ return h || (j.length > 0 && (h = ne.getPaths(j[0])), P(h)), h;
1108
1112
  }
1109
- function a(l) {
1110
- O(l), y !== null && y(l), r();
1113
+ function r(h) {
1114
+ s(h), m !== null && m(h), f();
1111
1115
  }
1112
- function o() {
1113
- g ? r() : c();
1116
+ function i() {
1117
+ y ? f() : c();
1114
1118
  }
1115
- function r() {
1116
- S(!1);
1119
+ function f() {
1120
+ C(!1);
1117
1121
  }
1118
1122
  function c() {
1119
- s.length > 0 && S(!0);
1123
+ B.length > 0 && C(!0);
1120
1124
  }
1125
+ const v = {
1126
+ dropdownSearch: `dropdownObjSearch-${x}`,
1127
+ dropdownObj: `dropdownObj-${x}`
1128
+ };
1121
1129
  return /* @__PURE__ */ Q(
1122
1130
  "div",
1123
1131
  {
1124
1132
  className: `dropdown-js dropdown-js-rounded
1125
- ${K && `dropdown-js-border ${K}`}`,
1126
- style: { ...b ? { pointerEvents: "none" } : {} },
1133
+ ${Z && `dropdown-js-border ${Z}`}`,
1134
+ style: { ...w ? { pointerEvents: "none" } : {} },
1127
1135
  children: [
1128
- /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: X, children: [
1136
+ /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: G, children: [
1129
1137
  /* @__PURE__ */ L(
1130
1138
  "input",
1131
1139
  {
1132
- id: "dropdownObjSearch",
1140
+ id: v.dropdownSearch,
1133
1141
  name: "dropdownObjSearch",
1134
1142
  className: "dropdown-js-input dropdown-js-rounded",
1135
- style: X,
1143
+ style: G,
1136
1144
  type: "text",
1137
1145
  autoComplete: "off",
1138
1146
  role: "combobox",
1139
1147
  "aria-autocomplete": "list",
1140
- "aria-controls": "dropdownObj",
1141
- "aria-expanded": g,
1142
- "aria-placeholder": `Type to Search for ${i}`,
1148
+ "aria-controls": v.dropdownObj,
1149
+ "aria-expanded": y,
1150
+ "aria-placeholder": `Type to Search for ${n}`,
1143
1151
  "aria-required": !0,
1144
- onChange: (l) => W(l),
1145
- disabled: b,
1146
- placeholder: `Type to Search for ${i}`,
1147
- value: V
1152
+ onChange: (h) => t(h),
1153
+ disabled: w,
1154
+ placeholder: `Type to Search for ${n}`,
1155
+ value: X
1148
1156
  }
1149
1157
  ),
1150
1158
  /* @__PURE__ */ L(
1151
1159
  "div",
1152
1160
  {
1153
1161
  className: "dropdown-js-arrow-container dropdown-js-padding dropdown-js-rounded",
1154
- "aria-label": `${i} options`,
1155
- "aria-expanded": g,
1156
- onClick: (l) => o(),
1157
- children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: g ? "-" : "+" })
1162
+ "aria-label": `${n} options`,
1163
+ "aria-expanded": y,
1164
+ onClick: (h) => i(),
1165
+ children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: y ? "-" : "+" })
1158
1166
  }
1159
1167
  )
1160
1168
  ] }),
1161
1169
  /* @__PURE__ */ L(
1162
1170
  "div",
1163
1171
  {
1164
- className: `dropdown-js-padding dropdown-js-menu ${!g && "dropdown-js-hide"}`,
1165
- id: "dropDownObj",
1172
+ className: `dropdown-js-padding dropdown-js-menu ${!y && "dropdown-js-hide"}`,
1173
+ id: v.dropdownObj,
1166
1174
  name: "dropDownObj",
1167
1175
  role: "listbox",
1168
- "aria-expanded": g,
1169
- style: { ...X, marginTop: "3.5px" },
1170
- children: s.map((l, D) => /* @__PURE__ */ Q(
1176
+ "aria-expanded": y,
1177
+ style: { ...G, marginTop: "3.5px" },
1178
+ children: B.map((h, H) => /* @__PURE__ */ Q(
1171
1179
  "div",
1172
1180
  {
1173
- name: l[C],
1181
+ name: h[T],
1174
1182
  role: "option",
1175
- "aria-label": l[C],
1183
+ "aria-label": h[T],
1176
1184
  style: { cursor: "pointer" },
1177
- onClick: (G) => a(l),
1185
+ onClick: (K) => r(h),
1178
1186
  children: [
1179
- l[C],
1180
- D < s.length - 1 && /* @__PURE__ */ L("hr", { style: { borderColor: X.color } })
1187
+ h[T],
1188
+ H < B.length - 1 && /* @__PURE__ */ L("hr", { style: { borderColor: G.color } })
1181
1189
  ]
1182
1190
  },
1183
- `${l[p]}${D}`
1191
+ `${h[p]}${H}`
1184
1192
  ))
1185
1193
  }
1186
1194
  )
@@ -1188,208 +1196,213 @@ function Ye({
1188
1196
  }
1189
1197
  );
1190
1198
  }
1191
- Ye.propTypes = {
1192
- label: u.string.isRequired,
1193
- data: u.arrayOf(u.object).isRequired,
1194
- sortFields: u.arrayOf(u.string).isRequired,
1195
- selected: u.object,
1196
- displayName: u.string.isRequired,
1197
- valueName: u.string.isRequired,
1198
- isDisabled: u.bool,
1199
- onItemSelected: u.func,
1200
- dropdownStyle: u.shape({
1201
- color: u.string.isRequired,
1199
+ Ue.propTypes = {
1200
+ label: l.string.isRequired,
1201
+ data: l.arrayOf(l.object).isRequired,
1202
+ sortFields: l.arrayOf(l.string).isRequired,
1203
+ selected: l.object,
1204
+ displayName: l.string.isRequired,
1205
+ valueName: l.string.isRequired,
1206
+ isDisabled: l.bool,
1207
+ onItemSelected: l.func,
1208
+ dropdownStyle: l.shape({
1209
+ color: l.string.isRequired,
1202
1210
  // text color
1203
- backgroundColor: u.string.isRequired,
1204
- fontSize: u.string,
1205
- borderColor: u.string
1211
+ backgroundColor: l.string.isRequired,
1212
+ fontSize: l.string,
1213
+ borderColor: l.string
1206
1214
  })
1207
1215
  };
1208
- function Ue({
1209
- label: i,
1216
+ function Fe({
1217
+ label: n,
1210
1218
  // label with which to describe the dropdown.
1211
- data: T,
1219
+ data: j,
1212
1220
  sortFields: M,
1213
- selectedData: v = [],
1214
- maxNumSelections: C = null,
1221
+ selectedData: b = [],
1222
+ maxNumSelections: T = null,
1215
1223
  displayName: p,
1216
1224
  // the name of the field that will be used for displaying the list items to the user.
1217
- valueName: b,
1225
+ valueName: w,
1218
1226
  // the name of the field that will be used as the underlying unique value of each list item.
1219
- isDisabled: y = !1,
1220
- onItemsSelected: w = null,
1221
- dropdownStyle: g,
1222
- buttonStyle: S
1227
+ isDisabled: m = !1,
1228
+ onItemsSelected: g = null,
1229
+ dropdownStyle: x,
1230
+ buttonStyle: y
1223
1231
  }) {
1224
- const [m, P] = ee(!1), [j, J] = ee(""), [x, q] = ee(""), V = re(() => T.toSorted(t), [T]), [H, I] = ee([]), O = re(() => H.length > 0 ? H.filter((h) => V.findIndex((B) => {
1225
- const n = e();
1226
- return ne.objCompare(h, B, ...n) === 0;
1227
- }) >= 0).toSorted(t) : v.filter((h) => V.findIndex((B) => {
1228
- const n = e();
1229
- return ne.objCompare(h, B, ...n) === 0;
1230
- }) >= 0).toSorted(t), [V, v, H]), s = re(() => {
1231
- if (x.length === 0)
1232
+ const C = ce(), [E, P] = ee(!1), [Y, q] = ee(""), [_, U] = ee(""), X = re(() => j.toSorted(u), [j]), [D, $] = ee([]), s = re(() => D.length > 0 ? D.filter((e) => X.findIndex((a) => {
1233
+ const S = o();
1234
+ return ne.objCompare(e, a, ...S) === 0;
1235
+ }) >= 0).toSorted(u) : b.filter((e) => X.findIndex((a) => {
1236
+ const S = o();
1237
+ return ne.objCompare(e, a, ...S) === 0;
1238
+ }) >= 0).toSorted(u), [X, b, D]), B = re(() => {
1239
+ if (_.length === 0)
1232
1240
  return [];
1233
- const h = x.toUpperCase();
1234
- return V.filter((B) => B[p].toUpperCase().includes(h));
1235
- }, [x]), X = re(() => x.length > 0 ? s : V, [x, V]), K = (() => {
1236
- const h = {
1237
- backgroundColor: g?.backgroundColor,
1238
- color: g?.color
1241
+ const e = _.toUpperCase();
1242
+ return X.filter((a) => a[p].toUpperCase().includes(e));
1243
+ }, [_]), G = re(() => _.length > 0 ? B : X, [_, X]), Z = (() => {
1244
+ const e = {
1245
+ backgroundColor: x?.backgroundColor,
1246
+ color: x?.color
1239
1247
  };
1240
- return g?.fontSize && (h.fontSize = g?.fontSize), h;
1241
- })(), W = g?.borderColor;
1248
+ return x?.fontSize && (e.fontSize = x?.fontSize), e;
1249
+ })(), t = x?.borderColor;
1242
1250
  Pe(() => {
1243
1251
  if (!p)
1244
1252
  throw new Error("displayName must be provided");
1245
- if (!b)
1253
+ if (!w)
1246
1254
  throw new Error("valueName must be provided");
1247
1255
  }, []);
1248
- function e() {
1249
- let h = j;
1250
- return h || (T.length > 0 && (h = ne.getPaths(T[0])), J(h)), h;
1251
- }
1252
- function t(h, B) {
1253
- return ne.objCompare(h, B, ...M);
1254
- }
1255
- function a(h) {
1256
- q(h.target.value), s.length > 0 ? G() : D();
1257
- }
1258
- function o(h) {
1259
- let B = [...O];
1260
- if (r(h))
1261
- B = B.filter((n) => {
1262
- const f = e();
1263
- return ne.objCompare(n, h, ...f) !== 0;
1256
+ function o() {
1257
+ let e = Y;
1258
+ return e || (j.length > 0 && (e = ne.getPaths(j[0])), q(e)), e;
1259
+ }
1260
+ function u(e, a) {
1261
+ return ne.objCompare(e, a, ...M);
1262
+ }
1263
+ function r(e) {
1264
+ U(e.target.value), B.length > 0 ? H() : h();
1265
+ }
1266
+ function i(e) {
1267
+ let a = [...s];
1268
+ if (f(e))
1269
+ a = a.filter((S) => {
1270
+ const O = o();
1271
+ return ne.objCompare(S, e, ...O) !== 0;
1264
1272
  });
1265
1273
  else {
1266
- if (C !== null && O.length >= C)
1274
+ if (T !== null && s.length >= T)
1267
1275
  return;
1268
- B.push(h);
1276
+ a.push(e);
1269
1277
  }
1270
- I(B);
1278
+ $(a);
1271
1279
  }
1272
- function r(h) {
1273
- const B = e();
1274
- return O.findIndex((n) => ne.objCompare(n, h, ...B) === 0) >= 0;
1280
+ function f(e) {
1281
+ const a = o();
1282
+ return s.findIndex((S) => ne.objCompare(S, e, ...a) === 0) >= 0;
1275
1283
  }
1276
- function c(h) {
1277
- const B = e(), n = O.filter((f) => ne.objCompare(f, h, ...B) !== 0);
1278
- I(n), w !== null && w(n);
1284
+ function c(e) {
1285
+ const a = o(), S = s.filter((O) => ne.objCompare(O, e, ...a) !== 0);
1286
+ $(S), g !== null && g(S);
1279
1287
  }
1280
- function l() {
1281
- m ? D() : G();
1288
+ function v() {
1289
+ E ? h() : H();
1282
1290
  }
1283
- function D() {
1284
- P(!1), w !== null && w(O);
1291
+ function h() {
1292
+ P(!1), g !== null && g(s);
1285
1293
  }
1286
- function G() {
1287
- X.length > 0 && P(!0);
1294
+ function H() {
1295
+ G.length > 0 && P(!0);
1288
1296
  }
1297
+ const K = {
1298
+ multiSelectionDropdownObjSearch: `multiSelectionDropdownSearch-${C}`,
1299
+ multiSelectionDropdownObj: `multiSelectionDropdown-${C}`,
1300
+ selectedItems: `selectedItems-${C}`
1301
+ };
1289
1302
  return /* @__PURE__ */ Q(
1290
1303
  "div",
1291
1304
  {
1292
1305
  className: `dropdown-js dropdown-js-rounded
1293
- ${W && `dropdown-js-border ${W}`}`,
1294
- style: { ...y ? { pointerEvents: "none" } : {} },
1306
+ ${t && `dropdown-js-border ${t}`}`,
1307
+ style: { ...m ? { pointerEvents: "none" } : {} },
1295
1308
  children: [
1296
- /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: K, children: [
1309
+ /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: Z, children: [
1297
1310
  /* @__PURE__ */ L("div", { children: /* @__PURE__ */ L(
1298
1311
  "input",
1299
1312
  {
1300
- id: "multiSelectionDropdownObjSearch",
1313
+ id: K.multiSelectionDropdownObjSearch,
1301
1314
  name: "multiSelectionDropdownObjSearch",
1302
1315
  className: "dropdown-js-input dropdown-js-rounded",
1303
- style: K,
1304
- "aria-label": i,
1316
+ style: Z,
1317
+ "aria-label": n,
1305
1318
  "aria-autocomplete": "list",
1306
- "aria-controls": "multiSelectionDropdownObj",
1319
+ "aria-controls": K.multiSelectionDropdownObj,
1307
1320
  role: "combobox",
1308
- "aria-expanded": m,
1321
+ "aria-expanded": E,
1309
1322
  "aria-haspopup": "listbox",
1310
1323
  type: "text",
1311
1324
  autoComplete: "off",
1312
- "aria-placeholder": `Type to Search for ${i}`,
1313
- onChange: (h) => a(h),
1314
- placeholder: `Type to Search for ${i}`,
1315
- value: x
1325
+ "aria-placeholder": `Type to Search for ${n}`,
1326
+ onChange: (e) => r(e),
1327
+ placeholder: `Type to Search for ${n}`,
1328
+ value: _
1316
1329
  }
1317
1330
  ) }),
1318
1331
  /* @__PURE__ */ L(
1319
1332
  "div",
1320
1333
  {
1321
1334
  className: "dropdown-js-arrow-container dropdown-js-padding dropdown-js-rounded",
1322
- "aria-expanded": m,
1335
+ "aria-expanded": E,
1323
1336
  "aria-controls": "multiSelectionDropdownObj",
1324
- "aria-label": `${i} options`,
1325
- onClick: (h) => l(),
1326
- children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: m ? "-" : "+" })
1337
+ "aria-label": `${n} options`,
1338
+ onClick: (e) => v(),
1339
+ children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: E ? "-" : "+" })
1327
1340
  }
1328
1341
  )
1329
1342
  ] }),
1330
1343
  /* @__PURE__ */ L("div", { className: "dropdown-js-padding dropdown-js-selected-wrapper dropdown-js-selected-container", children: /* @__PURE__ */ L(
1331
1344
  "div",
1332
1345
  {
1333
- id: "multiSelectionDropdownObj",
1346
+ id: K.selectedItems,
1334
1347
  className: "dropdown-js-selected-items",
1335
- "aria-label": `Selected ${i} options`,
1348
+ "aria-label": `Selected ${n} options`,
1336
1349
  "aria-multiselectable": !0,
1337
1350
  "aria-live": "polite",
1338
- children: O.map((h) => /* @__PURE__ */ Q(
1351
+ children: s.map((e) => /* @__PURE__ */ Q(
1339
1352
  "span",
1340
1353
  {
1341
1354
  className: "dropdown-js-padding dropdown-js-rounded",
1342
- "aria-label": `${h[p]}`,
1343
- style: { ...K, margin: "3.5px", marginRight: "0px" },
1355
+ "aria-label": `${e[p]}`,
1356
+ style: { ...Z, margin: "3.5px", marginRight: "0px" },
1344
1357
  children: [
1345
- h[p],
1358
+ e[p],
1346
1359
  " ",
1347
- /* @__PURE__ */ L("span", { className: "dropdown-js-padding", style: { cursor: "pointer" }, "aria-label": `Remove ${h[p]}`, onClick: (B) => c(h), children: "×" })
1360
+ /* @__PURE__ */ L("span", { className: "dropdown-js-padding", style: { cursor: "pointer" }, "aria-label": `Remove ${e[p]}`, onClick: (a) => c(e), children: "×" })
1348
1361
  ]
1349
1362
  },
1350
- `${h[b]}${h[p]}`
1363
+ `${e[w]}${e[p]}`
1351
1364
  ))
1352
1365
  }
1353
1366
  ) }),
1354
1367
  /* @__PURE__ */ Q(
1355
1368
  "div",
1356
1369
  {
1357
- className: `dropdown-js-padding dropdown-js-menu dropdown-js-rounded ${!m && "dropdown-js-hide"}`,
1358
- style: K,
1359
- id: "multiSelectionDropdownObj",
1370
+ className: `dropdown-js-padding dropdown-js-menu dropdown-js-rounded ${!E && "dropdown-js-hide"}`,
1371
+ style: Z,
1372
+ id: K.multiSelectionDropdownObj,
1360
1373
  name: "multiSelectionDropdownObj",
1361
1374
  role: "listbox",
1362
1375
  "aria-multiselectable": !0,
1363
- "aria-expanded": m,
1376
+ "aria-expanded": E,
1364
1377
  children: [
1365
- X.map((h) => /* @__PURE__ */ Q("div", { children: [
1378
+ G.map((e) => /* @__PURE__ */ Q("div", { children: [
1366
1379
  /* @__PURE__ */ L(
1367
1380
  "input",
1368
1381
  {
1369
- id: `${h[b]}Checkbox`,
1382
+ id: `${e[w]}Checkbox`,
1370
1383
  type: "checkbox",
1371
- name: `${h[p]}Checkbox`,
1384
+ name: `${e[p]}Checkbox`,
1372
1385
  role: "option",
1373
- "aria-label": `${h[p]}`,
1374
- "aria-checked": r(h),
1386
+ "aria-label": `${e[p]}`,
1387
+ "aria-checked": f(e),
1375
1388
  style: { cursor: "pointer" },
1376
- checked: r(h),
1377
- onChange: (B) => o(h),
1378
- value: h[b]
1389
+ checked: f(e),
1390
+ onChange: (a) => i(e),
1391
+ value: e[w]
1379
1392
  }
1380
1393
  ),
1381
- /* @__PURE__ */ L("label", { style: { marginLeft: "5px" }, htmlFor: `${h[b]}`, children: h[p] }),
1382
- /* @__PURE__ */ L("hr", { style: { backgroundColor: K.color, border: "none", height: "0.5px" } })
1383
- ] }, `${h[b]}${h[p]}`)),
1394
+ /* @__PURE__ */ L("label", { style: { marginLeft: "5px" }, htmlFor: `${e[w]}`, children: e[p] }),
1395
+ /* @__PURE__ */ L("hr", { style: { backgroundColor: Z.color, border: "none", height: "0.5px" } })
1396
+ ] }, `${e[w]}${e[p]}`)),
1384
1397
  /* @__PURE__ */ L(
1385
1398
  "button",
1386
1399
  {
1387
1400
  className: "dropdown-js-padding dropdown-js-round",
1388
- style: S,
1401
+ style: y,
1389
1402
  title: "Done",
1390
- disabled: X.length === 0,
1391
- "aria-label": `Close ${i} options`,
1392
- onClick: (h) => D(),
1403
+ disabled: G.length === 0,
1404
+ "aria-label": `Close ${n} options`,
1405
+ onClick: (e) => h(),
1393
1406
  type: "button",
1394
1407
  children: "Done"
1395
1408
  }
@@ -1401,117 +1414,122 @@ function Ue({
1401
1414
  }
1402
1415
  );
1403
1416
  }
1404
- Ue.propTypes = {
1405
- label: u.string.isRequired,
1406
- data: u.arrayOf(u.object).isRequired,
1407
- sortFields: u.arrayOf(u.string).isRequired,
1408
- selectedData: u.arrayOf(u.object),
1409
- maxNumSelections: u.number,
1410
- displayName: u.string.isRequired,
1411
- valueName: u.string.isRequired,
1412
- isDisabled: u.bool,
1413
- onItemsSelected: u.func,
1414
- dropdownStyle: u.shape({
1415
- color: u.string.isRequired,
1417
+ Fe.propTypes = {
1418
+ label: l.string.isRequired,
1419
+ data: l.arrayOf(l.object).isRequired,
1420
+ sortFields: l.arrayOf(l.string).isRequired,
1421
+ selectedData: l.arrayOf(l.object),
1422
+ maxNumSelections: l.number,
1423
+ displayName: l.string.isRequired,
1424
+ valueName: l.string.isRequired,
1425
+ isDisabled: l.bool,
1426
+ onItemsSelected: l.func,
1427
+ dropdownStyle: l.shape({
1428
+ color: l.string.isRequired,
1416
1429
  // text color
1417
- backgroundColor: u.string.isRequired,
1418
- fontSize: u.string,
1419
- borderColor: u.string
1430
+ backgroundColor: l.string.isRequired,
1431
+ fontSize: l.string,
1432
+ borderColor: l.string
1420
1433
  }),
1421
- buttonStyle: u.shape({
1422
- color: u.string.isRequired,
1434
+ buttonStyle: l.shape({
1435
+ color: l.string.isRequired,
1423
1436
  // text color
1424
- backgroundColor: u.string.isRequired,
1425
- fontSize: u.string,
1426
- borderColor: u.string
1437
+ backgroundColor: l.string.isRequired,
1438
+ fontSize: l.string,
1439
+ borderColor: l.string
1427
1440
  })
1428
1441
  };
1429
- function Fe({
1430
- label: i,
1442
+ function Ve({
1443
+ label: n,
1431
1444
  // label with which to describe the dropdown.
1432
- data: T,
1445
+ data: j,
1433
1446
  sortOrder: M = "asc",
1434
- selectedData: v = [],
1435
- maxNumSelections: C = null,
1447
+ selectedData: b = [],
1448
+ maxNumSelections: T = null,
1436
1449
  isDisabled: p = !1,
1437
- onItemsSelected: b = null,
1438
- dropdownStyle: y,
1450
+ onItemsSelected: w = null,
1451
+ dropdownStyle: m,
1439
1452
  // Styling object with fields {color, backgroundColor, borderColor (optional), fontSize}.
1440
- buttonStyle: w
1453
+ buttonStyle: g
1441
1454
  // Styling for the DONE button
1442
1455
  }) {
1443
- const [g, S] = ee(!1), m = re(() => T.toSorted(s), [T]), [P, j] = ee(""), [J, x] = ee([]), q = re(() => J.length > 0 ? J.filter((r) => m.findIndex((c) => c === r) >= 0).toSorted(s) : v.filter((r) => m.findIndex((c) => c === r) >= 0).toSorted(s), [m, v, J]), V = re(() => {
1456
+ const x = ce(), [y, C] = ee(!1), E = re(() => j.toSorted(B), [j]), [P, Y] = ee(""), [q, _] = ee([]), U = re(() => q.length > 0 ? q.filter((c) => E.findIndex((v) => v === c) >= 0).toSorted(B) : b.filter((c) => E.findIndex((v) => v === c) >= 0).toSorted(B), [E, b, q]), X = re(() => {
1444
1457
  if (P.length === 0)
1445
1458
  return [];
1446
- const r = P.toUpperCase();
1447
- return m.filter((c) => c.toUpperCase().includes(r));
1448
- }, [P]), H = re(() => P.length > 0 ? V : m, [P, m]), I = (() => {
1449
- const r = {
1450
- backgroundColor: y?.backgroundColor,
1451
- color: y?.color
1459
+ const c = P.toUpperCase();
1460
+ return E.filter((v) => v.toUpperCase().includes(c));
1461
+ }, [P]), D = re(() => P.length > 0 ? X : E, [P, E]), $ = (() => {
1462
+ const c = {
1463
+ backgroundColor: m?.backgroundColor,
1464
+ color: m?.color
1452
1465
  };
1453
- return y?.fontSize && (r.fontSize = y?.fontSize), r;
1454
- })(), O = y?.borderColor;
1455
- function s(r, c) {
1456
- return ne.compare(r, c, M);
1457
- }
1458
- function X(r) {
1459
- const c = r.target.value;
1460
- j(c), H.length > 0 ? o() : a();
1461
- }
1462
- function K(r) {
1463
- let c = [...q];
1464
- if (W(r))
1465
- c = c.filter((l) => l !== r);
1466
+ return m?.fontSize && (c.fontSize = m?.fontSize), c;
1467
+ })(), s = m?.borderColor;
1468
+ function B(c, v) {
1469
+ return ne.compare(c, v, M);
1470
+ }
1471
+ function G(c) {
1472
+ const v = c.target.value;
1473
+ Y(v), D.length > 0 ? i() : r();
1474
+ }
1475
+ function Z(c) {
1476
+ let v = [...U];
1477
+ if (t(c))
1478
+ v = v.filter((h) => h !== c);
1466
1479
  else {
1467
- if (C !== null && c.length >= C)
1480
+ if (T !== null && v.length >= T)
1468
1481
  return;
1469
- c.push(r);
1482
+ v.push(c);
1470
1483
  }
1471
- x(c);
1484
+ _(v);
1472
1485
  }
1473
- function W(r) {
1474
- return q.findIndex((c) => c === r) >= 0;
1486
+ function t(c) {
1487
+ return U.findIndex((v) => v === c) >= 0;
1475
1488
  }
1476
- function e(r) {
1477
- const c = q.filter((l) => l !== r);
1478
- x((l) => c), b !== null && b(c);
1489
+ function o(c) {
1490
+ const v = U.filter((h) => h !== c);
1491
+ _((h) => v), w !== null && w(v);
1479
1492
  }
1480
- function t() {
1481
- g ? a() : o();
1493
+ function u() {
1494
+ y ? r() : i();
1482
1495
  }
1483
- function a() {
1484
- S(!1), b !== null && b(q);
1496
+ function r() {
1497
+ C(!1), w !== null && w(U);
1485
1498
  }
1486
- function o() {
1487
- H.length > 0 && S(!0);
1499
+ function i() {
1500
+ D.length > 0 && C(!0);
1488
1501
  }
1502
+ const f = {
1503
+ multiSelectionDropdownSearch: `multiSelectionDropdown-${x}`,
1504
+ multiSelectionDropdown: `multiSelectionDropdown-${x}`,
1505
+ selectedItems: `selectedItems-${x}`
1506
+ };
1489
1507
  return /* @__PURE__ */ Q(
1490
1508
  "div",
1491
1509
  {
1492
1510
  className: `dropdown-js dropdown-js-rounded
1493
- ${O && `dropdown-js-border ${O}`}`,
1511
+ ${s && `dropdown-js-border ${s}`}`,
1494
1512
  style: { ...p ? { pointerEvents: "none" } : {} },
1495
1513
  children: [
1496
- /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: I, children: [
1514
+ /* @__PURE__ */ Q("div", { className: "dropdown-js-input-wrapper dropdown-js-rounded", style: $, children: [
1497
1515
  /* @__PURE__ */ L("div", { children: /* @__PURE__ */ L(
1498
1516
  "input",
1499
1517
  {
1500
1518
  className: "dropdown-js-input dropdown-js-rounded",
1501
- id: "multiselectionDropdownSearch",
1519
+ id: f.multiSelectionDropdownSearch,
1502
1520
  name: "multiselectionDropdownSearch",
1503
- style: I,
1521
+ style: $,
1504
1522
  type: "text",
1505
1523
  autoComplete: "off",
1506
1524
  role: "combobox",
1507
- "aria-label": i,
1508
- "aria-placeholder": `Type to search for ${i}`,
1525
+ "aria-label": n,
1526
+ "aria-placeholder": `Type to search for ${n}`,
1509
1527
  "aria-autocomplete": "list",
1510
- "aria-controls": "multiSelectionDropdown",
1511
- "aria-expanded": g,
1528
+ "aria-controls": f.multiSelectionDropdown,
1529
+ "aria-expanded": y,
1512
1530
  "aria-haspopup": "listbox",
1513
- onChange: (r) => X(r),
1514
- placeholder: `Type to Search for ${i}`,
1531
+ onChange: (c) => G(c),
1532
+ placeholder: `Type to Search for ${n}`,
1515
1533
  value: P
1516
1534
  }
1517
1535
  ) }),
@@ -1519,75 +1537,75 @@ function Fe({
1519
1537
  "div",
1520
1538
  {
1521
1539
  className: "dropdown-js-arrow-container dropdown-js-padding dropdown-js-rounded",
1522
- "aria-expanded": g,
1540
+ "aria-expanded": y,
1523
1541
  "aria-controls": "multiSelectionDropdown",
1524
- "aria-label": `${i} options`,
1525
- onClick: (r) => t(),
1526
- children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: g ? "-" : "+" })
1542
+ "aria-label": `${n} options`,
1543
+ onClick: (c) => u(),
1544
+ children: /* @__PURE__ */ L("span", { className: "dropdown-js-arrow dropdown-js-padding", children: y ? "-" : "+" })
1527
1545
  }
1528
1546
  )
1529
1547
  ] }),
1530
1548
  /* @__PURE__ */ L("div", { className: "dropdown-js-padding dropdown-js-selected-wrapper dropdown-js-selected-container", children: /* @__PURE__ */ L(
1531
1549
  "div",
1532
1550
  {
1533
- id: "multiSelectionDropdown-selectedItems",
1551
+ id: f.selectedItems,
1534
1552
  className: "dropdown-js-selected-items",
1535
- "aria-label": `Selected ${i} options`,
1553
+ "aria-label": `Selected ${n} options`,
1536
1554
  "aria-live": "polite",
1537
- children: q.map((r) => /* @__PURE__ */ Q(
1555
+ children: U.map((c) => /* @__PURE__ */ Q(
1538
1556
  "span",
1539
1557
  {
1540
1558
  className: "dropdown-js-padding dropdown-js-rounded",
1541
- "aria-label": `${r}`,
1542
- style: { ...I, margin: "3.5px", marginRight: "0px" },
1559
+ "aria-label": `${c}`,
1560
+ style: { ...$, margin: "3.5px", marginRight: "0px" },
1543
1561
  children: [
1544
- r,
1562
+ c,
1545
1563
  " ",
1546
- /* @__PURE__ */ L("span", { style: { cursor: "pointer" }, "aria-label": `Remove ${r}`, onClick: (c) => e(r), children: "×" })
1564
+ /* @__PURE__ */ L("span", { style: { cursor: "pointer" }, "aria-label": `Remove ${c}`, onClick: (v) => o(c), children: "×" })
1547
1565
  ]
1548
1566
  },
1549
- `${r}`
1567
+ `${c}`
1550
1568
  ))
1551
1569
  }
1552
1570
  ) }),
1553
1571
  /* @__PURE__ */ Q(
1554
1572
  "div",
1555
1573
  {
1556
- className: `dropdown-js-padding dropdown-js-menu dropdown-js-rounded ${!g && "dropdown-js-hide"}`,
1557
- style: I,
1558
- id: "multiSelectionDropdown",
1574
+ className: `dropdown-js-padding dropdown-js-menu dropdown-js-rounded ${!y && "dropdown-js-hide"}`,
1575
+ style: $,
1576
+ id: f.multiSelectionDropdown,
1559
1577
  name: "multiSelectionDropdown",
1560
1578
  role: "listbox",
1561
1579
  "aria-multiselectable": !0,
1562
- "aria-expanded": g,
1580
+ "aria-expanded": y,
1563
1581
  children: [
1564
- H.map((r, c) => /* @__PURE__ */ Q("div", { children: [
1582
+ D.map((c, v) => /* @__PURE__ */ Q("div", { children: [
1565
1583
  /* @__PURE__ */ L(
1566
1584
  "input",
1567
1585
  {
1568
1586
  type: "checkbox",
1569
- name: `${r}Checkbox`,
1587
+ name: `${c}Checkbox`,
1570
1588
  role: "option",
1571
- "aria-label": r,
1572
- "aria-checked": W(r),
1589
+ "aria-label": c,
1590
+ "aria-checked": t(c),
1573
1591
  style: { cursor: "pointer" },
1574
- checked: W(r),
1575
- onChange: (l) => K(r),
1576
- value: r
1592
+ checked: t(c),
1593
+ onChange: (h) => Z(c),
1594
+ value: c
1577
1595
  }
1578
1596
  ),
1579
- /* @__PURE__ */ L("label", { style: { marginLeft: "5px" }, htmlFor: `${r}`, children: r }),
1580
- /* @__PURE__ */ L("hr", { style: { backgroundColor: I.color, border: "none", height: "0.5px" } })
1581
- ] }, `${c}#${r}`)),
1597
+ /* @__PURE__ */ L("label", { style: { marginLeft: "5px" }, htmlFor: `${c}`, children: c }),
1598
+ /* @__PURE__ */ L("hr", { style: { backgroundColor: $.color, border: "none", height: "0.5px" } })
1599
+ ] }, `${v}#${c}`)),
1582
1600
  /* @__PURE__ */ L(
1583
1601
  "button",
1584
1602
  {
1585
1603
  className: "dropdown-js-padding dropdown-js-round",
1586
- style: w,
1587
- "aria-label": `Click to collapse ${i} options`,
1604
+ style: g,
1605
+ "aria-label": `Click to collapse ${n} options`,
1588
1606
  title: "Done",
1589
- disabled: H.length === 0,
1590
- onClick: (r) => a(),
1607
+ disabled: D.length === 0,
1608
+ onClick: (c) => r(),
1591
1609
  type: "button",
1592
1610
  children: "Done"
1593
1611
  }
@@ -1599,32 +1617,32 @@ function Fe({
1599
1617
  }
1600
1618
  );
1601
1619
  }
1602
- Fe.propTypes = {
1603
- label: u.string.isRequired,
1604
- data: u.array.isRequired,
1605
- sortOrder: u.string,
1606
- selectedData: u.array.isRequired,
1607
- maxNumSelections: u.number,
1608
- isDisabled: u.bool,
1609
- onItemsSelected: u.func,
1610
- dropdownStyle: u.shape({
1611
- color: u.string.isRequired,
1620
+ Ve.propTypes = {
1621
+ label: l.string.isRequired,
1622
+ data: l.array.isRequired,
1623
+ sortOrder: l.string,
1624
+ selectedData: l.array.isRequired,
1625
+ maxNumSelections: l.number,
1626
+ isDisabled: l.bool,
1627
+ onItemsSelected: l.func,
1628
+ dropdownStyle: l.shape({
1629
+ color: l.string.isRequired,
1612
1630
  // text color
1613
- backgroundColor: u.string.isRequired,
1614
- fontSize: u.string,
1615
- borderColor: u.string
1631
+ backgroundColor: l.string.isRequired,
1632
+ fontSize: l.string,
1633
+ borderColor: l.string
1616
1634
  }),
1617
- buttonStyle: u.shape({
1618
- color: u.string.isRequired,
1635
+ buttonStyle: l.shape({
1636
+ color: l.string.isRequired,
1619
1637
  // text color
1620
- backgroundColor: u.string.isRequired,
1621
- fontSize: u.string,
1622
- borderColor: u.string
1638
+ backgroundColor: l.string.isRequired,
1639
+ fontSize: l.string,
1640
+ borderColor: l.string
1623
1641
  })
1624
1642
  };
1625
1643
  export {
1626
- Le as Dropdown,
1627
- Ye as DropdownObj,
1628
- Fe as MultiSelectionDropdown,
1629
- Ue as MultiSelectionDropdownObj
1644
+ Ye as Dropdown,
1645
+ Ue as DropdownObj,
1646
+ Ve as MultiSelectionDropdown,
1647
+ Fe as MultiSelectionDropdownObj
1630
1648
  };