@starasia/dropdown 1.0.1 → 1.0.3

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,5 +1,5 @@
1
- import or, { useState as Z, useRef as H, useEffect as N, forwardRef as gn } from "react";
2
- var wr = { exports: {} }, G = {};
1
+ import or, { useState as G, useRef as X, useEffect as B, forwardRef as gn } from "react";
2
+ var wr = { exports: {} }, H = {};
3
3
  /**
4
4
  * @license React
5
5
  * react-jsx-runtime.production.min.js
@@ -12,22 +12,22 @@ var wr = { exports: {} }, G = {};
12
12
  var zr;
13
13
  function bn() {
14
14
  if (zr)
15
- return G;
15
+ return H;
16
16
  zr = 1;
17
- var u = or, p = Symbol.for("react.element"), x = Symbol.for("react.fragment"), k = Object.prototype.hasOwnProperty, f = u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, g = { key: !0, ref: !0, __self: !0, __source: !0 };
18
- function P(R, w, C) {
19
- var _, F = {}, E = null, L = null;
20
- C !== void 0 && (E = "" + C), w.key !== void 0 && (E = "" + w.key), w.ref !== void 0 && (L = w.ref);
21
- for (_ in w)
22
- k.call(w, _) && !g.hasOwnProperty(_) && (F[_] = w[_]);
23
- if (R && R.defaultProps)
24
- for (_ in w = R.defaultProps, w)
25
- F[_] === void 0 && (F[_] = w[_]);
26
- return { $$typeof: p, type: R, key: E, ref: L, props: F, _owner: f.current };
17
+ var c = or, p = Symbol.for("react.element"), x = Symbol.for("react.fragment"), b = Object.prototype.hasOwnProperty, u = c.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, v = { key: !0, ref: !0, __self: !0, __source: !0 };
18
+ function O(m, f, F) {
19
+ var y, T = {}, A = null, D = null;
20
+ F !== void 0 && (A = "" + F), f.key !== void 0 && (A = "" + f.key), f.ref !== void 0 && (D = f.ref);
21
+ for (y in f)
22
+ b.call(f, y) && !v.hasOwnProperty(y) && (T[y] = f[y]);
23
+ if (m && m.defaultProps)
24
+ for (y in f = m.defaultProps, f)
25
+ T[y] === void 0 && (T[y] = f[y]);
26
+ return { $$typeof: p, type: m, key: A, ref: D, props: T, _owner: u.current };
27
27
  }
28
- return G.Fragment = x, G.jsx = P, G.jsxs = P, G;
28
+ return H.Fragment = x, H.jsx = O, H.jsxs = O, H;
29
29
  }
30
- var X = {};
30
+ var K = {};
31
31
  /**
32
32
  * @license React
33
33
  * react-jsx-runtime.development.js
@@ -40,88 +40,88 @@ var X = {};
40
40
  var Nr;
41
41
  function xn() {
42
42
  return Nr || (Nr = 1, process.env.NODE_ENV !== "production" && function() {
43
- var u = or, p = Symbol.for("react.element"), x = Symbol.for("react.portal"), k = Symbol.for("react.fragment"), f = Symbol.for("react.strict_mode"), g = Symbol.for("react.profiler"), P = Symbol.for("react.provider"), R = Symbol.for("react.context"), w = Symbol.for("react.forward_ref"), C = Symbol.for("react.suspense"), _ = Symbol.for("react.suspense_list"), F = Symbol.for("react.memo"), E = Symbol.for("react.lazy"), L = Symbol.for("react.offscreen"), $ = Symbol.iterator, m = "@@iterator";
44
- function o(r) {
43
+ var c = or, p = Symbol.for("react.element"), x = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), v = Symbol.for("react.profiler"), O = Symbol.for("react.provider"), m = Symbol.for("react.context"), f = Symbol.for("react.forward_ref"), F = Symbol.for("react.suspense"), y = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), A = Symbol.for("react.lazy"), D = Symbol.for("react.offscreen"), I = Symbol.iterator, o = "@@iterator";
44
+ function $(r) {
45
45
  if (r === null || typeof r != "object")
46
46
  return null;
47
- var n = $ && r[$] || r[m];
47
+ var n = I && r[I] || r[o];
48
48
  return typeof n == "function" ? n : null;
49
49
  }
50
- var v = u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
51
- function l(r) {
50
+ var S = c.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
51
+ function h(r) {
52
52
  {
53
53
  for (var n = arguments.length, e = new Array(n > 1 ? n - 1 : 0), a = 1; a < n; a++)
54
54
  e[a - 1] = arguments[a];
55
- h("error", r, e);
55
+ W("error", r, e);
56
56
  }
57
57
  }
58
- function h(r, n, e) {
58
+ function W(r, n, e) {
59
59
  {
60
- var a = v.ReactDebugCurrentFrame, d = a.getStackAddendum();
60
+ var a = S.ReactDebugCurrentFrame, d = a.getStackAddendum();
61
61
  d !== "" && (n += "%s", e = e.concat([d]));
62
- var c = e.map(function(s) {
62
+ var l = e.map(function(s) {
63
63
  return String(s);
64
64
  });
65
- c.unshift("Warning: " + n), Function.prototype.apply.call(console[r], console, c);
65
+ l.unshift("Warning: " + n), Function.prototype.apply.call(console[r], console, l);
66
66
  }
67
67
  }
68
- var j = !1, z = !1, B = !1, ir = !1, Q = !1, rr;
68
+ var V = !1, U = !1, Z = !1, ir = !1, Q = !1, rr;
69
69
  rr = Symbol.for("react.module.reference");
70
- function Y(r) {
71
- return !!(typeof r == "string" || typeof r == "function" || r === k || r === g || Q || r === f || r === C || r === _ || ir || r === L || j || z || B || typeof r == "object" && r !== null && (r.$$typeof === E || r.$$typeof === F || r.$$typeof === P || r.$$typeof === R || r.$$typeof === w || // This needs to include all possible module reference object
70
+ function L(r) {
71
+ return !!(typeof r == "string" || typeof r == "function" || r === b || r === v || Q || r === u || r === F || r === y || ir || r === D || V || U || Z || typeof r == "object" && r !== null && (r.$$typeof === A || r.$$typeof === T || r.$$typeof === O || r.$$typeof === m || r.$$typeof === f || // This needs to include all possible module reference object
72
72
  // types supported by any Flight configuration anywhere since
73
73
  // we don't know which Flight build this will end up being used
74
74
  // with.
75
75
  r.$$typeof === rr || r.getModuleId !== void 0));
76
76
  }
77
- function T(r, n, e) {
77
+ function R(r, n, e) {
78
78
  var a = r.displayName;
79
79
  if (a)
80
80
  return a;
81
81
  var d = n.displayName || n.name || "";
82
82
  return d !== "" ? e + "(" + d + ")" : e;
83
83
  }
84
- function O(r) {
84
+ function k(r) {
85
85
  return r.displayName || "Context";
86
86
  }
87
- function D(r) {
87
+ function j(r) {
88
88
  if (r == null)
89
89
  return null;
90
- if (typeof r.tag == "number" && l("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function")
90
+ if (typeof r.tag == "number" && h("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function")
91
91
  return r.displayName || r.name || null;
92
92
  if (typeof r == "string")
93
93
  return r;
94
94
  switch (r) {
95
- case k:
95
+ case b:
96
96
  return "Fragment";
97
97
  case x:
98
98
  return "Portal";
99
- case g:
99
+ case v:
100
100
  return "Profiler";
101
- case f:
101
+ case u:
102
102
  return "StrictMode";
103
- case C:
103
+ case F:
104
104
  return "Suspense";
105
- case _:
105
+ case y:
106
106
  return "SuspenseList";
107
107
  }
108
108
  if (typeof r == "object")
109
109
  switch (r.$$typeof) {
110
- case R:
110
+ case m:
111
111
  var n = r;
112
- return O(n) + ".Consumer";
113
- case P:
112
+ return k(n) + ".Consumer";
113
+ case O:
114
114
  var e = r;
115
- return O(e._context) + ".Provider";
116
- case w:
117
- return T(r, r.render, "ForwardRef");
118
- case F:
115
+ return k(e._context) + ".Provider";
116
+ case f:
117
+ return R(r, r.render, "ForwardRef");
118
+ case T:
119
119
  var a = r.displayName || null;
120
- return a !== null ? a : D(r.type) || "Memo";
121
- case E: {
122
- var d = r, c = d._payload, s = d._init;
120
+ return a !== null ? a : j(r.type) || "Memo";
121
+ case A: {
122
+ var d = r, l = d._payload, s = d._init;
123
123
  try {
124
- return D(s(c));
124
+ return j(s(l));
125
125
  } catch {
126
126
  return null;
127
127
  }
@@ -129,13 +129,13 @@ function xn() {
129
129
  }
130
130
  return null;
131
131
  }
132
- var S = Object.assign, M = 0, gr, br, xr, mr, yr, kr, Er;
132
+ var E = Object.assign, z = 0, gr, br, xr, mr, yr, kr, Er;
133
133
  function Rr() {
134
134
  }
135
135
  Rr.__reactDisabledLog = !0;
136
136
  function Mr() {
137
137
  {
138
- if (M === 0) {
138
+ if (z === 0) {
139
139
  gr = console.log, br = console.info, xr = console.warn, mr = console.error, yr = console.group, kr = console.groupCollapsed, Er = console.groupEnd;
140
140
  var r = {
141
141
  configurable: !0,
@@ -153,45 +153,45 @@ function xn() {
153
153
  groupEnd: r
154
154
  });
155
155
  }
156
- M++;
156
+ z++;
157
157
  }
158
158
  }
159
159
  function Vr() {
160
160
  {
161
- if (M--, M === 0) {
161
+ if (z--, z === 0) {
162
162
  var r = {
163
163
  configurable: !0,
164
164
  enumerable: !0,
165
165
  writable: !0
166
166
  };
167
167
  Object.defineProperties(console, {
168
- log: S({}, r, {
168
+ log: E({}, r, {
169
169
  value: gr
170
170
  }),
171
- info: S({}, r, {
171
+ info: E({}, r, {
172
172
  value: br
173
173
  }),
174
- warn: S({}, r, {
174
+ warn: E({}, r, {
175
175
  value: xr
176
176
  }),
177
- error: S({}, r, {
177
+ error: E({}, r, {
178
178
  value: mr
179
179
  }),
180
- group: S({}, r, {
180
+ group: E({}, r, {
181
181
  value: yr
182
182
  }),
183
- groupCollapsed: S({}, r, {
183
+ groupCollapsed: E({}, r, {
184
184
  value: kr
185
185
  }),
186
- groupEnd: S({}, r, {
186
+ groupEnd: E({}, r, {
187
187
  value: Er
188
188
  })
189
189
  });
190
190
  }
191
- M < 0 && l("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
191
+ z < 0 && h("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
192
192
  }
193
193
  }
194
- var sr = v.ReactCurrentDispatcher, dr;
194
+ var sr = S.ReactCurrentDispatcher, dr;
195
195
  function nr(r, n, e) {
196
196
  {
197
197
  if (dr === void 0)
@@ -222,8 +222,8 @@ function xn() {
222
222
  lr = !0;
223
223
  var d = Error.prepareStackTrace;
224
224
  Error.prepareStackTrace = void 0;
225
- var c;
226
- c = sr.current, sr.current = null, Mr();
225
+ var l;
226
+ l = sr.current, sr.current = null, Mr();
227
227
  try {
228
228
  if (n) {
229
229
  var s = function() {
@@ -236,55 +236,55 @@ function xn() {
236
236
  }), typeof Reflect == "object" && Reflect.construct) {
237
237
  try {
238
238
  Reflect.construct(s, []);
239
- } catch (A) {
240
- a = A;
239
+ } catch (C) {
240
+ a = C;
241
241
  }
242
242
  Reflect.construct(r, [], s);
243
243
  } else {
244
244
  try {
245
245
  s.call();
246
- } catch (A) {
247
- a = A;
246
+ } catch (C) {
247
+ a = C;
248
248
  }
249
249
  r.call(s.prototype);
250
250
  }
251
251
  } else {
252
252
  try {
253
253
  throw Error();
254
- } catch (A) {
255
- a = A;
254
+ } catch (C) {
255
+ a = C;
256
256
  }
257
257
  r();
258
258
  }
259
- } catch (A) {
260
- if (A && a && typeof A.stack == "string") {
261
- for (var i = A.stack.split(`
262
- `), I = a.stack.split(`
263
- `), b = i.length - 1, y = I.length - 1; b >= 1 && y >= 0 && i[b] !== I[y]; )
264
- y--;
265
- for (; b >= 1 && y >= 0; b--, y--)
266
- if (i[b] !== I[y]) {
267
- if (b !== 1 || y !== 1)
259
+ } catch (C) {
260
+ if (C && a && typeof C.stack == "string") {
261
+ for (var i = C.stack.split(`
262
+ `), _ = a.stack.split(`
263
+ `), w = i.length - 1, g = _.length - 1; w >= 1 && g >= 0 && i[w] !== _[g]; )
264
+ g--;
265
+ for (; w >= 1 && g >= 0; w--, g--)
266
+ if (i[w] !== _[g]) {
267
+ if (w !== 1 || g !== 1)
268
268
  do
269
- if (b--, y--, y < 0 || i[b] !== I[y]) {
270
- var W = `
271
- ` + i[b].replace(" at new ", " at ");
272
- return r.displayName && W.includes("<anonymous>") && (W = W.replace("<anonymous>", r.displayName)), typeof r == "function" && er.set(r, W), W;
269
+ if (w--, g--, g < 0 || i[w] !== _[g]) {
270
+ var P = `
271
+ ` + i[w].replace(" at new ", " at ");
272
+ return r.displayName && P.includes("<anonymous>") && (P = P.replace("<anonymous>", r.displayName)), typeof r == "function" && er.set(r, P), P;
273
273
  }
274
- while (b >= 1 && y >= 0);
274
+ while (w >= 1 && g >= 0);
275
275
  break;
276
276
  }
277
277
  }
278
278
  } finally {
279
- lr = !1, sr.current = c, Vr(), Error.prepareStackTrace = d;
279
+ lr = !1, sr.current = l, Vr(), Error.prepareStackTrace = d;
280
280
  }
281
- var q = r ? r.displayName || r.name : "", V = q ? nr(q) : "";
282
- return typeof r == "function" && er.set(r, V), V;
281
+ var M = r ? r.displayName || r.name : "", N = M ? nr(M) : "";
282
+ return typeof r == "function" && er.set(r, N), N;
283
283
  }
284
284
  function qr(r, n, e) {
285
285
  return _r(r, !1);
286
286
  }
287
- function Hr(r) {
287
+ function Jr(r) {
288
288
  var n = r.prototype;
289
289
  return !!(n && n.isReactComponent);
290
290
  }
@@ -292,32 +292,32 @@ function xn() {
292
292
  if (r == null)
293
293
  return "";
294
294
  if (typeof r == "function")
295
- return _r(r, Hr(r));
295
+ return _r(r, Jr(r));
296
296
  if (typeof r == "string")
297
297
  return nr(r);
298
298
  switch (r) {
299
- case C:
299
+ case F:
300
300
  return nr("Suspense");
301
- case _:
301
+ case y:
302
302
  return nr("SuspenseList");
303
303
  }
304
304
  if (typeof r == "object")
305
305
  switch (r.$$typeof) {
306
- case w:
306
+ case f:
307
307
  return qr(r.render);
308
- case F:
308
+ case T:
309
309
  return ar(r.type, n, e);
310
- case E: {
311
- var a = r, d = a._payload, c = a._init;
310
+ case A: {
311
+ var a = r, d = a._payload, l = a._init;
312
312
  try {
313
- return ar(c(d), n, e);
313
+ return ar(l(d), n, e);
314
314
  } catch {
315
315
  }
316
316
  }
317
317
  }
318
318
  return "";
319
319
  }
320
- var J = Object.prototype.hasOwnProperty, jr = {}, Cr = v.ReactDebugCurrentFrame;
320
+ var q = Object.prototype.hasOwnProperty, jr = {}, Cr = S.ReactDebugCurrentFrame;
321
321
  function tr(r) {
322
322
  if (r) {
323
323
  var n = r._owner, e = ar(r.type, r._source, n ? n.type : null);
@@ -325,22 +325,22 @@ function xn() {
325
325
  } else
326
326
  Cr.setExtraStackFrame(null);
327
327
  }
328
- function Jr(r, n, e, a, d) {
328
+ function Hr(r, n, e, a, d) {
329
329
  {
330
- var c = Function.call.bind(J);
330
+ var l = Function.call.bind(q);
331
331
  for (var s in r)
332
- if (c(r, s)) {
332
+ if (l(r, s)) {
333
333
  var i = void 0;
334
334
  try {
335
335
  if (typeof r[s] != "function") {
336
- var I = Error((a || "React class") + ": " + e + " type `" + s + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[s] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
337
- throw I.name = "Invariant Violation", I;
336
+ var _ = Error((a || "React class") + ": " + e + " type `" + s + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[s] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
337
+ throw _.name = "Invariant Violation", _;
338
338
  }
339
339
  i = r[s](n, s, a, e, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
340
- } catch (b) {
341
- i = b;
340
+ } catch (w) {
341
+ i = w;
342
342
  }
343
- i && !(i instanceof Error) && (tr(d), l("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", a || "React class", e, s, typeof i), tr(null)), i instanceof Error && !(i.message in jr) && (jr[i.message] = !0, tr(d), l("Failed %s type: %s", e, i.message), tr(null));
343
+ i && !(i instanceof Error) && (tr(d), h("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", a || "React class", e, s, typeof i), tr(null)), i instanceof Error && !(i.message in jr) && (jr[i.message] = !0, tr(d), h("Failed %s type: %s", e, i.message), tr(null));
344
344
  }
345
345
  }
346
346
  }
@@ -356,19 +356,19 @@ function xn() {
356
356
  }
357
357
  function Xr(r) {
358
358
  try {
359
- return Tr(r), !1;
359
+ return Or(r), !1;
360
360
  } catch {
361
361
  return !0;
362
362
  }
363
363
  }
364
- function Tr(r) {
364
+ function Or(r) {
365
365
  return "" + r;
366
366
  }
367
- function Or(r) {
367
+ function Tr(r) {
368
368
  if (Xr(r))
369
- return l("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Gr(r)), Tr(r);
369
+ return h("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Gr(r)), Or(r);
370
370
  }
371
- var K = v.ReactCurrentOwner, Zr = {
371
+ var J = S.ReactCurrentOwner, Zr = {
372
372
  key: !0,
373
373
  ref: !0,
374
374
  __self: !0,
@@ -376,7 +376,7 @@ function xn() {
376
376
  }, Sr, Pr, ur;
377
377
  ur = {};
378
378
  function Qr(r) {
379
- if (J.call(r, "ref")) {
379
+ if (q.call(r, "ref")) {
380
380
  var n = Object.getOwnPropertyDescriptor(r, "ref").get;
381
381
  if (n && n.isReactWarning)
382
382
  return !1;
@@ -384,7 +384,7 @@ function xn() {
384
384
  return r.ref !== void 0;
385
385
  }
386
386
  function rn(r) {
387
- if (J.call(r, "key")) {
387
+ if (q.call(r, "key")) {
388
388
  var n = Object.getOwnPropertyDescriptor(r, "key").get;
389
389
  if (n && n.isReactWarning)
390
390
  return !1;
@@ -392,15 +392,15 @@ function xn() {
392
392
  return r.key !== void 0;
393
393
  }
394
394
  function nn(r, n) {
395
- if (typeof r.ref == "string" && K.current && n && K.current.stateNode !== n) {
396
- var e = D(K.current.type);
397
- ur[e] || (l('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', D(K.current.type), r.ref), ur[e] = !0);
395
+ if (typeof r.ref == "string" && J.current && n && J.current.stateNode !== n) {
396
+ var e = j(J.current.type);
397
+ ur[e] || (h('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', j(J.current.type), r.ref), ur[e] = !0);
398
398
  }
399
399
  }
400
400
  function en(r, n) {
401
401
  {
402
402
  var e = function() {
403
- Sr || (Sr = !0, l("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
403
+ Sr || (Sr = !0, h("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
404
404
  };
405
405
  e.isReactWarning = !0, Object.defineProperty(r, "key", {
406
406
  get: e,
@@ -411,7 +411,7 @@ function xn() {
411
411
  function an(r, n) {
412
412
  {
413
413
  var e = function() {
414
- Pr || (Pr = !0, l("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
414
+ Pr || (Pr = !0, h("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
415
415
  };
416
416
  e.isReactWarning = !0, Object.defineProperty(r, "ref", {
417
417
  get: e,
@@ -419,7 +419,7 @@ function xn() {
419
419
  });
420
420
  }
421
421
  }
422
- var tn = function(r, n, e, a, d, c, s) {
422
+ var tn = function(r, n, e, a, d, l, s) {
423
423
  var i = {
424
424
  // This tag allows us to uniquely identify this as a React Element
425
425
  $$typeof: p,
@@ -429,7 +429,7 @@ function xn() {
429
429
  ref: e,
430
430
  props: s,
431
431
  // Record the component responsible for creating this element.
432
- _owner: c
432
+ _owner: l
433
433
  };
434
434
  return i._store = {}, Object.defineProperty(i._store, "validated", {
435
435
  configurable: !1,
@@ -450,24 +450,24 @@ function xn() {
450
450
  };
451
451
  function on(r, n, e, a, d) {
452
452
  {
453
- var c, s = {}, i = null, I = null;
454
- e !== void 0 && (Or(e), i = "" + e), rn(n) && (Or(n.key), i = "" + n.key), Qr(n) && (I = n.ref, nn(n, d));
455
- for (c in n)
456
- J.call(n, c) && !Zr.hasOwnProperty(c) && (s[c] = n[c]);
453
+ var l, s = {}, i = null, _ = null;
454
+ e !== void 0 && (Tr(e), i = "" + e), rn(n) && (Tr(n.key), i = "" + n.key), Qr(n) && (_ = n.ref, nn(n, d));
455
+ for (l in n)
456
+ q.call(n, l) && !Zr.hasOwnProperty(l) && (s[l] = n[l]);
457
457
  if (r && r.defaultProps) {
458
- var b = r.defaultProps;
459
- for (c in b)
460
- s[c] === void 0 && (s[c] = b[c]);
458
+ var w = r.defaultProps;
459
+ for (l in w)
460
+ s[l] === void 0 && (s[l] = w[l]);
461
461
  }
462
- if (i || I) {
463
- var y = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
464
- i && en(s, y), I && an(s, y);
462
+ if (i || _) {
463
+ var g = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
464
+ i && en(s, g), _ && an(s, g);
465
465
  }
466
- return tn(r, i, I, d, a, K.current, s);
466
+ return tn(r, i, _, d, a, J.current, s);
467
467
  }
468
468
  }
469
- var pr = v.ReactCurrentOwner, Ir = v.ReactDebugCurrentFrame;
470
- function U(r) {
469
+ var pr = S.ReactCurrentOwner, Ir = S.ReactDebugCurrentFrame;
470
+ function Y(r) {
471
471
  if (r) {
472
472
  var n = r._owner, e = ar(r.type, r._source, n ? n.type : null);
473
473
  Ir.setExtraStackFrame(e);
@@ -479,10 +479,10 @@ function xn() {
479
479
  function vr(r) {
480
480
  return typeof r == "object" && r !== null && r.$$typeof === p;
481
481
  }
482
- function Dr() {
482
+ function Fr() {
483
483
  {
484
484
  if (pr.current) {
485
- var r = D(pr.current.type);
485
+ var r = j(pr.current.type);
486
486
  if (r)
487
487
  return `
488
488
 
@@ -505,7 +505,7 @@ Check your code at ` + n + ":" + e + ".";
505
505
  var Ar = {};
506
506
  function dn(r) {
507
507
  {
508
- var n = Dr();
508
+ var n = Fr();
509
509
  if (!n) {
510
510
  var e = typeof r == "string" ? r : r.displayName || r.name;
511
511
  e && (n = `
@@ -515,7 +515,7 @@ Check the top-level render call using <` + e + ">.");
515
515
  return n;
516
516
  }
517
517
  }
518
- function Fr(r, n) {
518
+ function Dr(r, n) {
519
519
  {
520
520
  if (!r._store || r._store.validated || r.key != null)
521
521
  return;
@@ -525,25 +525,25 @@ Check the top-level render call using <` + e + ">.");
525
525
  return;
526
526
  Ar[e] = !0;
527
527
  var a = "";
528
- r && r._owner && r._owner !== pr.current && (a = " It was passed a child from " + D(r._owner.type) + "."), U(r), l('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', e, a), U(null);
528
+ r && r._owner && r._owner !== pr.current && (a = " It was passed a child from " + j(r._owner.type) + "."), Y(r), h('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', e, a), Y(null);
529
529
  }
530
530
  }
531
- function $r(r, n) {
531
+ function Wr(r, n) {
532
532
  {
533
533
  if (typeof r != "object")
534
534
  return;
535
535
  if (cr(r))
536
536
  for (var e = 0; e < r.length; e++) {
537
537
  var a = r[e];
538
- vr(a) && Fr(a, n);
538
+ vr(a) && Dr(a, n);
539
539
  }
540
540
  else if (vr(r))
541
541
  r._store && (r._store.validated = !0);
542
542
  else if (r) {
543
- var d = o(r);
543
+ var d = $(r);
544
544
  if (typeof d == "function" && d !== r.entries)
545
- for (var c = d.call(r), s; !(s = c.next()).done; )
546
- vr(s.value) && Fr(s.value, n);
545
+ for (var l = d.call(r), s; !(s = l.next()).done; )
546
+ vr(s.value) && Dr(s.value, n);
547
547
  }
548
548
  }
549
549
  }
@@ -555,21 +555,21 @@ Check the top-level render call using <` + e + ">.");
555
555
  var e;
556
556
  if (typeof n == "function")
557
557
  e = n.propTypes;
558
- else if (typeof n == "object" && (n.$$typeof === w || // Note: Memo only checks outer props here.
558
+ else if (typeof n == "object" && (n.$$typeof === f || // Note: Memo only checks outer props here.
559
559
  // Inner props are checked in the reconciler.
560
- n.$$typeof === F))
560
+ n.$$typeof === T))
561
561
  e = n.propTypes;
562
562
  else
563
563
  return;
564
564
  if (e) {
565
- var a = D(n);
566
- Jr(e, r.props, "prop", a, r);
565
+ var a = j(n);
566
+ Hr(e, r.props, "prop", a, r);
567
567
  } else if (n.PropTypes !== void 0 && !fr) {
568
568
  fr = !0;
569
- var d = D(n);
570
- l("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", d || "Unknown");
569
+ var d = j(n);
570
+ h("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", d || "Unknown");
571
571
  }
572
- typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && l("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
572
+ typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && h("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
573
573
  }
574
574
  }
575
575
  function cn(r) {
@@ -577,56 +577,56 @@ Check the top-level render call using <` + e + ">.");
577
577
  for (var n = Object.keys(r.props), e = 0; e < n.length; e++) {
578
578
  var a = n[e];
579
579
  if (a !== "children" && a !== "key") {
580
- U(r), l("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", a), U(null);
580
+ Y(r), h("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", a), Y(null);
581
581
  break;
582
582
  }
583
583
  }
584
- r.ref !== null && (U(r), l("Invalid attribute `ref` supplied to `React.Fragment`."), U(null));
584
+ r.ref !== null && (Y(r), h("Invalid attribute `ref` supplied to `React.Fragment`."), Y(null));
585
585
  }
586
586
  }
587
- var Wr = {};
588
- function Lr(r, n, e, a, d, c) {
587
+ var $r = {};
588
+ function Lr(r, n, e, a, d, l) {
589
589
  {
590
- var s = Y(r);
590
+ var s = L(r);
591
591
  if (!s) {
592
592
  var i = "";
593
593
  (r === void 0 || typeof r == "object" && r !== null && Object.keys(r).length === 0) && (i += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
594
- var I = sn(d);
595
- I ? i += I : i += Dr();
596
- var b;
597
- r === null ? b = "null" : cr(r) ? b = "array" : r !== void 0 && r.$$typeof === p ? (b = "<" + (D(r.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : b = typeof r, l("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", b, i);
594
+ var _ = sn(d);
595
+ _ ? i += _ : i += Fr();
596
+ var w;
597
+ r === null ? w = "null" : cr(r) ? w = "array" : r !== void 0 && r.$$typeof === p ? (w = "<" + (j(r.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : w = typeof r, h("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", w, i);
598
598
  }
599
- var y = on(r, n, e, d, c);
600
- if (y == null)
601
- return y;
599
+ var g = on(r, n, e, d, l);
600
+ if (g == null)
601
+ return g;
602
602
  if (s) {
603
- var W = n.children;
604
- if (W !== void 0)
603
+ var P = n.children;
604
+ if (P !== void 0)
605
605
  if (a)
606
- if (cr(W)) {
607
- for (var q = 0; q < W.length; q++)
608
- $r(W[q], r);
609
- Object.freeze && Object.freeze(W);
606
+ if (cr(P)) {
607
+ for (var M = 0; M < P.length; M++)
608
+ Wr(P[M], r);
609
+ Object.freeze && Object.freeze(P);
610
610
  } else
611
- l("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
611
+ h("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
612
612
  else
613
- $r(W, r);
613
+ Wr(P, r);
614
614
  }
615
- if (J.call(n, "key")) {
616
- var V = D(r), A = Object.keys(n).filter(function(wn) {
615
+ if (q.call(n, "key")) {
616
+ var N = j(r), C = Object.keys(n).filter(function(wn) {
617
617
  return wn !== "key";
618
- }), hr = A.length > 0 ? "{key: someKey, " + A.join(": ..., ") + ": ...}" : "{key: someKey}";
619
- if (!Wr[V + hr]) {
620
- var hn = A.length > 0 ? "{" + A.join(": ..., ") + ": ...}" : "{}";
621
- l(`A props object containing a "key" prop is being spread into JSX:
618
+ }), hr = C.length > 0 ? "{key: someKey, " + C.join(": ..., ") + ": ...}" : "{key: someKey}";
619
+ if (!$r[N + hr]) {
620
+ var hn = C.length > 0 ? "{" + C.join(": ..., ") + ": ...}" : "{}";
621
+ h(`A props object containing a "key" prop is being spread into JSX:
622
622
  let props = %s;
623
623
  <%s {...props} />
624
624
  React keys must be passed directly to JSX without using spread:
625
625
  let props = %s;
626
- <%s key={someKey} {...props} />`, hr, V, hn, V), Wr[V + hr] = !0;
626
+ <%s key={someKey} {...props} />`, hr, N, hn, N), $r[N + hr] = !0;
627
627
  }
628
628
  }
629
- return r === k ? cn(y) : ln(y), y;
629
+ return r === b ? cn(g) : ln(g), g;
630
630
  }
631
631
  }
632
632
  function un(r, n, e) {
@@ -636,8 +636,8 @@ React keys must be passed directly to JSX without using spread:
636
636
  return Lr(r, n, e, !1);
637
637
  }
638
638
  var fn = pn, vn = un;
639
- X.Fragment = k, X.jsx = fn, X.jsxs = vn;
640
- }()), X;
639
+ K.Fragment = b, K.jsx = fn, K.jsxs = vn;
640
+ }()), K;
641
641
  }
642
642
  process.env.NODE_ENV === "production" ? wr.exports = bn() : wr.exports = xn();
643
643
  var t = wr.exports;
@@ -844,12 +844,6 @@ const mn = `@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@3
844
844
  white-space: nowrap; */
845
845
  }
846
846
 
847
- /* remove default focus outline when container is focused for keyboard handling */
848
- .starasia-input-dropdown-lists-container:focus {
849
- outline: none;
850
- box-shadow: none;
851
- }
852
-
853
847
  .starasia-input-dropdown-lists-container-bottom {
854
848
  top: 100%;
855
849
  margin-top: var(--starasia-ui-dropdown-spacing-xs);
@@ -922,10 +916,6 @@ const mn = `@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@3
922
916
  /* box-shadow: 0px 0px 0px -1px #f0f0f0; */
923
917
  }
924
918
 
925
- .starasia-input-dropdwon-item.highlight {
926
- background-color: rgba(100, 181, 246, 0.21);
927
- }
928
-
929
919
  .starasia-input-dropdwon-item-disable {
930
920
  color: var(--starasia-ui-dropdown-color-disable) !important;
931
921
  pointer-events: none;
@@ -1056,19 +1046,19 @@ const mn = `@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@3
1056
1046
  width: 100%;
1057
1047
  }
1058
1048
  `;
1059
- function yn(u) {
1060
- const [p, x] = Z(u), k = H(null), f = (g) => {
1061
- k.current && !k.current.contains(g.target) && x(!1);
1049
+ function yn(c) {
1050
+ const [p, x] = G(c), b = X(null), u = (v) => {
1051
+ b.current && !b.current.contains(v.target) && x(!1);
1062
1052
  };
1063
- return N(() => (document.addEventListener("click", f, !0), () => {
1064
- document.removeEventListener("click", f, !0);
1065
- }), []), { ref: k, isComponentVisible: p, setIsComponentVisible: x };
1053
+ return B(() => (document.addEventListener("click", u, !0), () => {
1054
+ document.removeEventListener("click", u, !0);
1055
+ }), []), { ref: b, isComponentVisible: p, setIsComponentVisible: x };
1066
1056
  }
1067
- const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1057
+ const kn = ({ ...c }) => /* @__PURE__ */ t.jsx(
1068
1058
  "svg",
1069
1059
  {
1070
1060
  xmlns: "http://www.w3.org/2000/svg",
1071
- ...u,
1061
+ ...c,
1072
1062
  viewBox: "0 0 24 24",
1073
1063
  fill: "none",
1074
1064
  color: "#939E99",
@@ -1083,11 +1073,11 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1083
1073
  }
1084
1074
  )
1085
1075
  }
1086
- ), En = ({ ...u }) => /* @__PURE__ */ t.jsxs(
1076
+ ), En = ({ ...c }) => /* @__PURE__ */ t.jsxs(
1087
1077
  "svg",
1088
1078
  {
1089
1079
  xmlns: "http://www.w3.org/2000/svg",
1090
- ...u,
1080
+ ...c,
1091
1081
  viewBox: "0 0 20 20",
1092
1082
  fill: "none",
1093
1083
  children: [
@@ -1115,14 +1105,14 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1115
1105
  )
1116
1106
  ]
1117
1107
  }
1118
- ), Rn = ({ isChecked: u }) => /* @__PURE__ */ t.jsxs("div", { className: "checkbox-wrapper-30", children: [
1108
+ ), Rn = ({ isChecked: c }) => /* @__PURE__ */ t.jsxs("div", { className: "checkbox-wrapper-30", children: [
1119
1109
  /* @__PURE__ */ t.jsxs("span", { className: "checkbox", children: [
1120
1110
  /* @__PURE__ */ t.jsx(
1121
1111
  "input",
1122
1112
  {
1123
1113
  type: "checkbox",
1124
1114
  style: { pointerEvents: "none" },
1125
- checked: u
1115
+ checked: c
1126
1116
  }
1127
1117
  ),
1128
1118
  /* @__PURE__ */ t.jsx("svg", { children: /* @__PURE__ */ t.jsx("use", { xlinkHref: "#checkbox-30", className: "checkbox" }) })
@@ -1137,82 +1127,42 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1137
1127
  ) }) })
1138
1128
  ] }), _n = gn(
1139
1129
  ({
1140
- positionDropdown: u,
1130
+ positionDropdown: c,
1141
1131
  dropdownLists: p,
1142
1132
  isComponentVisible: x,
1143
- searchAble: k,
1144
- onSearch: f,
1145
- value: g,
1146
- handleChangeValue: P,
1147
- multiSelect: R,
1148
- searchValue: w
1149
- }, C) => {
1150
- const [_, F] = Z(0), [E, L] = Z(), $ = H(null), m = H(null);
1151
- return N(() => {
1152
- if ($.current) {
1153
- const o = $.current.getBoundingClientRect();
1154
- F(o.width);
1133
+ searchAble: b,
1134
+ onSearch: u,
1135
+ value: v,
1136
+ handleChangeValue: O,
1137
+ multiSelect: m,
1138
+ searchValue: f
1139
+ }, F) => {
1140
+ const [y, T] = G(0), [A, D] = G(), I = X(null);
1141
+ return B(() => {
1142
+ if (I.current) {
1143
+ const o = I.current.getBoundingClientRect();
1144
+ T(o.width);
1155
1145
  }
1156
- }, [$, x]), N(() => {
1157
- p && w ? p.forEach((o) => {
1158
- if (o.label.startsWith(w || "")) {
1159
- L(o.value);
1146
+ }, [I, x]), B(() => {
1147
+ p && f ? p.forEach((o) => {
1148
+ if (o.label.startsWith(f || "")) {
1149
+ D(o.value);
1160
1150
  return;
1161
1151
  }
1162
- }) : L(void 0);
1163
- }, [w, p]), N(() => {
1164
- const o = m.current || (C == null ? void 0 : C.current);
1165
- if (!o || !x)
1166
- return;
1167
- const v = p.filter((h) => !h.disable), l = (h) => {
1168
- if (h.key === "ArrowDown") {
1169
- if (h.preventDefault(), !v.length)
1170
- return;
1171
- const j = v.findIndex((B) => B.value === E), z = j === -1 ? 0 : (j + 1) % v.length;
1172
- L(v[z].value);
1173
- } else if (h.key === "ArrowUp") {
1174
- if (h.preventDefault(), !v.length)
1175
- return;
1176
- const j = v.findIndex((B) => B.value === E), z = j <= 0 ? v.length - 1 : j - 1;
1177
- L(v[z].value);
1178
- } else if (h.key === "Enter") {
1179
- if (h.preventDefault(), !E)
1180
- return;
1181
- const j = p.find((z) => z.value === E);
1182
- j && !j.disable && P(j.label, j.value);
1183
- }
1184
- };
1185
- return o.addEventListener("keydown", l), () => o.removeEventListener("keydown", l);
1186
- }, [x, p, E, P, C]), N(() => {
1187
- if (!E)
1188
- return;
1189
- const o = $.current;
1190
- if (!o)
1191
- return;
1192
- const v = o.querySelector(`[data-value="${E}"]`);
1193
- v && v.scrollIntoView && v.scrollIntoView({ block: "nearest" });
1194
- }, [E]), /* @__PURE__ */ t.jsx(t.Fragment, { children: x ? /* @__PURE__ */ t.jsxs(
1152
+ }) : D(void 0);
1153
+ }, [f, p]), /* @__PURE__ */ t.jsx(t.Fragment, { children: x ? /* @__PURE__ */ t.jsxs(
1195
1154
  "div",
1196
1155
  {
1197
1156
  className: "starasia-input-dropdown-lists-container",
1198
1157
  onClick: (o) => o.stopPropagation(),
1199
- ref: (o) => {
1200
- if (m.current = o, typeof C == "function")
1201
- C(o);
1202
- else if (C)
1203
- try {
1204
- C.current = o;
1205
- } catch {
1206
- }
1207
- },
1208
- tabIndex: 0,
1158
+ ref: F,
1209
1159
  children: [
1210
- k ? /* @__PURE__ */ t.jsxs(
1160
+ b ? /* @__PURE__ */ t.jsxs(
1211
1161
  "div",
1212
1162
  {
1213
1163
  className: "starasia-input-dropdown-container-dropdown-search",
1214
1164
  style: {
1215
- order: u == "bottom" ? 0 : 2,
1165
+ order: c == "bottom" ? 0 : 2,
1216
1166
  position: "sticky",
1217
1167
  top: 0,
1218
1168
  bottom: 0,
@@ -1224,9 +1174,9 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1224
1174
  "input",
1225
1175
  {
1226
1176
  onChange: (o) => {
1227
- f && f(o.target.value);
1177
+ u && u(o.target.value);
1228
1178
  },
1229
- value: w,
1179
+ value: f,
1230
1180
  autoFocus: !0,
1231
1181
  style: { width: "100%" }
1232
1182
  }
@@ -1237,18 +1187,17 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1237
1187
  /* @__PURE__ */ t.jsx(
1238
1188
  "div",
1239
1189
  {
1240
- className: `starasia-input-dropdwon-item-container ${R ? "multi" : ""}`,
1241
- ref: $,
1242
- children: p.map((o, v) => {
1243
- const l = !!(g != null && g.find((h) => h.value === o.value));
1190
+ className: `starasia-input-dropdwon-item-container ${m ? "multi" : ""}`,
1191
+ ref: I,
1192
+ children: p.map((o, $) => {
1193
+ const S = !!(v != null && v.find((h) => h.value === o.value));
1244
1194
  return /* @__PURE__ */ t.jsxs(
1245
1195
  "div",
1246
1196
  {
1247
- "data-value": o.value,
1248
- className: `starasia-input-dropdwon-item ${l ? "active" : " "} ${E === o.value ? "highlight" : ""} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1249
- onClick: () => P(o.label, o.value),
1197
+ className: `starasia-input-dropdwon-item ${S ? "active" : " "} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1198
+ onClick: () => O(o.label, o.value),
1250
1199
  children: [
1251
- R ? /* @__PURE__ */ t.jsx("div", { style: { marginRight: "8px" }, children: /* @__PURE__ */ t.jsx(Rn, { isChecked: l }) }) : null,
1200
+ m ? /* @__PURE__ */ t.jsx("div", { style: { marginRight: "8px" }, children: /* @__PURE__ */ t.jsx(Rn, { isChecked: S }) }) : null,
1252
1201
  o.icon ? /* @__PURE__ */ t.jsx("div", { children: or.cloneElement(o.icon, {
1253
1202
  width: 16
1254
1203
  }) }) : null,
@@ -1256,10 +1205,10 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1256
1205
  /* @__PURE__ */ t.jsx(
1257
1206
  "p",
1258
1207
  {
1259
- className: `starasia-input-dropdwon-item-text ${l ? "active" : null} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1208
+ className: `starasia-input-dropdwon-item-text ${S ? "active" : null} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1260
1209
  style: {
1261
1210
  textWrap: "nowrap",
1262
- width: `${_ - 12}px`,
1211
+ width: `${y - 12}px`,
1263
1212
  overflow: "hidden",
1264
1213
  textOverflow: "ellipsis"
1265
1214
  },
@@ -1269,10 +1218,10 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1269
1218
  o.description ? /* @__PURE__ */ t.jsx(
1270
1219
  "p",
1271
1220
  {
1272
- className: `starasia-input-dropdwon-item-text-description ${l ? "active" : null} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1221
+ className: `starasia-input-dropdwon-item-text-description ${S ? "active" : null} ${o.disable ? "starasia-input-dropdwon-item-disable" : null}`,
1273
1222
  style: {
1274
1223
  textWrap: "nowrap",
1275
- width: `${_ - 12}px`,
1224
+ width: `${y - 12}px`,
1276
1225
  overflow: "hidden",
1277
1226
  textOverflow: "ellipsis"
1278
1227
  },
@@ -1282,7 +1231,7 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1282
1231
  ] })
1283
1232
  ]
1284
1233
  },
1285
- v
1234
+ $
1286
1235
  );
1287
1236
  })
1288
1237
  }
@@ -1292,105 +1241,98 @@ const kn = ({ ...u }) => /* @__PURE__ */ t.jsx(
1292
1241
  ) : null });
1293
1242
  }
1294
1243
  ), jn = ({
1295
- children: u,
1244
+ children: c,
1296
1245
  handleChangePosition: p
1297
1246
  }) => {
1298
- const x = H(null);
1299
- N(() => {
1300
- var P;
1301
- const f = () => {
1247
+ const x = X(null);
1248
+ B(() => {
1249
+ var O;
1250
+ const u = () => {
1302
1251
  if (x.current) {
1303
- let R = x.current.parentElement;
1304
- for (; R && !k(R); )
1305
- R = R.parentElement;
1306
- R && p();
1252
+ let m = x.current.parentElement;
1253
+ for (; m && !b(m); )
1254
+ m = m.parentElement;
1255
+ m && p();
1307
1256
  }
1308
1257
  };
1309
- let g = (P = x.current) == null ? void 0 : P.parentElement;
1310
- for (; g && !k(g); )
1311
- g = g.parentElement;
1312
- return g && g.addEventListener("scroll", f), f(), () => {
1313
- g && g.removeEventListener("scroll", f);
1258
+ let v = (O = x.current) == null ? void 0 : O.parentElement;
1259
+ for (; v && !b(v); )
1260
+ v = v.parentElement;
1261
+ return v && v.addEventListener("scroll", u), u(), () => {
1262
+ v && v.removeEventListener("scroll", u);
1314
1263
  };
1315
1264
  }, []);
1316
- const k = (f) => f && (f.scrollHeight > f.clientHeight || f.scrollWidth > f.clientWidth);
1317
- return /* @__PURE__ */ t.jsx("div", { ref: x, children: u });
1318
- }, Br = "starasia-input-dropdown-styles", Cn = (u) => {
1265
+ const b = (u) => u && (u.scrollHeight > u.clientHeight || u.scrollWidth > u.clientWidth);
1266
+ return /* @__PURE__ */ t.jsx("div", { ref: x, children: c });
1267
+ }, Br = "starasia-input-dropdown-styles", Cn = (c) => {
1319
1268
  if (!document.getElementById(Br)) {
1320
1269
  const p = document.createElement("style");
1321
- p.id = Br, p.textContent = u, document.head.appendChild(p);
1270
+ p.id = Br, p.textContent = c, document.head.appendChild(p);
1322
1271
  }
1323
1272
  };
1324
1273
  Cn(mn);
1325
1274
  const Sn = ({
1326
- dropdownLists: u,
1275
+ dropdownLists: c,
1327
1276
  onChange: p,
1328
1277
  defaultValue: x,
1329
- size: k = "md",
1330
- multiSelect: f,
1331
- searchAble: g,
1332
- iconLeft: P,
1333
- placeholder: R,
1334
- onSearch: w,
1335
- error: C,
1336
- onBlur: _,
1337
- onFocus: F,
1338
- disable: E,
1339
- searchValue: L
1278
+ size: b = "md",
1279
+ multiSelect: u,
1280
+ searchAble: v,
1281
+ iconLeft: O,
1282
+ placeholder: m,
1283
+ onSearch: f,
1284
+ error: F,
1285
+ onBlur: y,
1286
+ onFocus: T,
1287
+ disable: A,
1288
+ searchValue: D
1340
1289
  }) => {
1341
- const $ = H(), [m, o] = Z([]), [v, l] = Z(""), h = H(null), { isComponentVisible: j, ref: z, setIsComponentVisible: B } = yn(!1), ir = () => {
1342
- B((T) => !T);
1343
- }, Q = (T, O) => {
1344
- if (!f)
1345
- o([{ label: T, value: O }]), p([{ label: T, value: O }]), B(!1);
1346
- else if (m == null ? void 0 : m.find((S) => S.value === O)) {
1347
- const S = [
1348
- ...m ? m.filter((M) => M.value !== O) : []
1290
+ const I = X(), [o, $] = G([]), [S, h] = G(""), W = X(null), { isComponentVisible: V, ref: U, setIsComponentVisible: Z } = yn(!1), ir = () => {
1291
+ Z((R) => !R);
1292
+ }, Q = (R, k) => {
1293
+ if (!u)
1294
+ $([{ label: R, value: k }]), p([{ label: R, value: k }]), Z(!1);
1295
+ else if (o == null ? void 0 : o.find((E) => E.value === k)) {
1296
+ const E = [
1297
+ ...o ? o.filter((z) => z.value !== k) : []
1349
1298
  ];
1350
- o(S), p(S);
1299
+ $(E), p(E);
1351
1300
  } else {
1352
- const S = [...m || [], { label: T, value: O }];
1353
- o(S), p(S);
1301
+ const E = [...o || [], { label: R, value: k }];
1302
+ $(E), p(E);
1354
1303
  }
1355
1304
  };
1356
- N(() => {
1357
- JSON.stringify($.current) === JSON.stringify(x) || ($.current = x, o($.current || []));
1305
+ B(() => {
1306
+ JSON.stringify(I.current) === JSON.stringify(x) || (I.current = x, $(I.current || []));
1358
1307
  }, [x]);
1359
- const rr = () => m.length ? f ? m == null ? void 0 : m.map((T, O) => /* @__PURE__ */ t.jsxs("div", { className: "starasia-input-dropdown-preview-item", children: [
1360
- /* @__PURE__ */ t.jsx("p", { style: { minWidth: "max-content" }, children: T == null ? void 0 : T.label }, O),
1308
+ const rr = () => o.length ? u ? o == null ? void 0 : o.map((R, k) => /* @__PURE__ */ t.jsxs("div", { className: "starasia-input-dropdown-preview-item", children: [
1309
+ /* @__PURE__ */ t.jsx("p", { style: { minWidth: "max-content" }, children: R == null ? void 0 : R.label }, k),
1361
1310
  /* @__PURE__ */ t.jsx(
1362
- Tn,
1311
+ On,
1363
1312
  {
1364
- onClick: () => Q(T.label, T.value)
1313
+ onClick: () => Q(R.label, R.value)
1365
1314
  }
1366
1315
  )
1367
- ] })) : /* @__PURE__ */ t.jsx("p", { style: { minWidth: "max-content" }, children: m == null ? void 0 : m[0].label }) : /* @__PURE__ */ t.jsx("p", { className: "starasia-input-dropdown-placeholder", children: R }), Y = () => {
1368
- if (z.current && h.current) {
1369
- const T = window.innerHeight, O = z.current.getBoundingClientRect(), D = h.current.getBoundingClientRect(), S = O.bottom + D.height;
1370
- h.current.style.left = `${O.left}px`, h.current.style.width = `${O.width}px`, S >= T - 10 ? (h.current.style.top = `${O.top - D.height - 5}px`, l("top")) : (h.current.style.top = `${O.top + O.height}px`, l("bottom"));
1316
+ ] })) : /* @__PURE__ */ t.jsx("p", { style: { minWidth: "max-content" }, children: o == null ? void 0 : o[0].label }) : /* @__PURE__ */ t.jsx("p", { className: "starasia-input-dropdown-placeholder", children: m }), L = () => {
1317
+ if (U.current && W.current) {
1318
+ const R = window.innerHeight, k = U.current.getBoundingClientRect(), j = W.current.getBoundingClientRect(), E = k.bottom + j.height;
1319
+ W.current.style.left = `${k.left}px`, W.current.style.width = `${k.width}px`, E >= R - 10 ? (W.current.style.top = `${k.top - j.height - 5}px`, h("top")) : (W.current.style.top = `${k.top + k.height}px`, h("bottom"));
1371
1320
  }
1372
1321
  };
1373
- return N(() => (window.addEventListener("scroll", Y), window.addEventListener("resize", Y), () => {
1374
- window.removeEventListener("scroll", Y), window.removeEventListener("resize", Y);
1375
- }), []), N(() => {
1376
- Y();
1377
- }, [j]), N(() => {
1378
- j && h.current && setTimeout(() => {
1379
- try {
1380
- h.current && h.current.focus();
1381
- } catch {
1382
- }
1383
- }, 0);
1384
- }, [j]), /* @__PURE__ */ t.jsx(jn, { handleChangePosition: Y, children: /* @__PURE__ */ t.jsxs(
1322
+ return B(() => (window.addEventListener("scroll", L), window.addEventListener("resize", L), () => {
1323
+ window.removeEventListener("scroll", L), window.removeEventListener("resize", L);
1324
+ }), []), B(() => {
1325
+ L();
1326
+ }, [V]), /* @__PURE__ */ t.jsx(jn, { handleChangePosition: L, children: /* @__PURE__ */ t.jsxs(
1385
1327
  "div",
1386
1328
  {
1387
- className: `starasia-input-dropdown-container ${E ? "disable" : ""} starasia-input-dropdown-size-${k} ${j ? "active" : ""} ${C ? "error" : ""}`,
1388
- ref: z,
1329
+ className: `starasia-input-dropdown-container ${A ? "disable" : ""} starasia-input-dropdown-size-${b} ${V ? "active" : ""} ${F ? "error" : ""}`,
1330
+ ref: U,
1389
1331
  onClick: ir,
1390
1332
  children: [
1391
1333
  /* @__PURE__ */ t.jsxs("div", { className: "starasia-input-dropdown-preview-container", children: [
1392
- P ? /* @__PURE__ */ t.jsx(t.Fragment, { children: or.cloneElement(P, {
1393
- width: Yr(k),
1334
+ O ? /* @__PURE__ */ t.jsx(t.Fragment, { children: or.cloneElement(O, {
1335
+ width: Yr(b),
1394
1336
  color: "#939E99",
1395
1337
  style: {
1396
1338
  color: "#939E99"
@@ -1401,8 +1343,8 @@ const Sn = ({
1401
1343
  {
1402
1344
  className: "starasia-input-dropdown-container-preview-item",
1403
1345
  tabIndex: 100,
1404
- onBlur: _,
1405
- onFocus: F,
1346
+ onBlur: y,
1347
+ onFocus: T,
1406
1348
  children: rr()
1407
1349
  }
1408
1350
  ),
@@ -1410,7 +1352,7 @@ const Sn = ({
1410
1352
  kn,
1411
1353
  {
1412
1354
  strokeWidth: 2,
1413
- width: Yr(k),
1355
+ width: Yr(b),
1414
1356
  style: { color: "#939E99" }
1415
1357
  }
1416
1358
  )
@@ -1418,29 +1360,29 @@ const Sn = ({
1418
1360
  /* @__PURE__ */ t.jsx(
1419
1361
  _n,
1420
1362
  {
1421
- dropdownLists: u,
1363
+ dropdownLists: c,
1422
1364
  handleChangeValue: Q,
1423
- isComponentVisible: j,
1424
- positionDropdown: v,
1425
- searchAble: !!g,
1426
- value: m,
1427
- onSearch: w,
1428
- ref: h,
1429
- multiSelect: f,
1430
- searchValue: L
1365
+ isComponentVisible: V,
1366
+ positionDropdown: S,
1367
+ searchAble: !!v,
1368
+ value: o,
1369
+ onSearch: f,
1370
+ ref: W,
1371
+ multiSelect: u,
1372
+ searchValue: D
1431
1373
  }
1432
1374
  )
1433
1375
  ]
1434
1376
  }
1435
1377
  ) });
1436
- }, Yr = (u) => {
1437
- if (u === "sm")
1378
+ }, Yr = (c) => {
1379
+ if (c === "sm")
1438
1380
  return 16;
1439
- if (u === "md")
1381
+ if (c === "md")
1440
1382
  return 16;
1441
- if (u === "lg")
1383
+ if (c === "lg")
1442
1384
  return 20;
1443
- }, Tn = (u) => /* @__PURE__ */ t.jsx(
1385
+ }, On = (c) => /* @__PURE__ */ t.jsx(
1444
1386
  "svg",
1445
1387
  {
1446
1388
  xmlns: "http://www.w3.org/2000/svg",
@@ -1448,7 +1390,7 @@ const Sn = ({
1448
1390
  height: "18",
1449
1391
  viewBox: "0 0 18 18",
1450
1392
  fill: "none",
1451
- ...u,
1393
+ ...c,
1452
1394
  children: /* @__PURE__ */ t.jsx(
1453
1395
  "path",
1454
1396
  {