@hudoro/dropdown
Advanced tools
Comparing version 0.0.3-beta.28 to 0.0.3-beta.29
@@ -1,3 +0,3 @@ | ||
import K, { useState as ar, useRef as fn, useEffect as Wr } from "react"; | ||
var dr = { exports: {} }, N = {}; | ||
import K, { useState as dr, useRef as fn, useEffect as $r } from "react"; | ||
var sr = { exports: {} }, Y = {}; | ||
/** | ||
@@ -12,21 +12,21 @@ * @license React | ||
*/ | ||
var Fr; | ||
var Ir; | ||
function pn() { | ||
if (Fr) | ||
return N; | ||
Fr = 1; | ||
var h = K, g = Symbol.for("react.element"), _ = Symbol.for("react.fragment"), m = Object.prototype.hasOwnProperty, j = h.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, S = { key: !0, ref: !0, __self: !0, __source: !0 }; | ||
function P(C, p, y) { | ||
var b, d = {}, E = null, I = null; | ||
y !== void 0 && (E = "" + y), p.key !== void 0 && (E = "" + p.key), p.ref !== void 0 && (I = p.ref); | ||
for (b in p) | ||
m.call(p, b) && !S.hasOwnProperty(b) && (d[b] = p[b]); | ||
if (C && C.defaultProps) | ||
for (b in p = C.defaultProps, p) | ||
d[b] === void 0 && (d[b] = p[b]); | ||
return { $$typeof: g, type: C, key: E, ref: I, props: d, _owner: j.current }; | ||
if (Ir) | ||
return Y; | ||
Ir = 1; | ||
var v = K, w = Symbol.for("react.element"), E = Symbol.for("react.fragment"), m = Object.prototype.hasOwnProperty, R = v.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, S = { key: !0, ref: !0, __self: !0, __source: !0 }; | ||
function P(j, h, F) { | ||
var c, _ = {}, l = null, C = null; | ||
F !== void 0 && (l = "" + F), h.key !== void 0 && (l = "" + h.key), h.ref !== void 0 && (C = h.ref); | ||
for (c in h) | ||
m.call(h, c) && !S.hasOwnProperty(c) && (_[c] = h[c]); | ||
if (j && j.defaultProps) | ||
for (c in h = j.defaultProps, h) | ||
_[c] === void 0 && (_[c] = h[c]); | ||
return { $$typeof: w, type: j, key: l, ref: C, props: _, _owner: R.current }; | ||
} | ||
return N.Fragment = _, N.jsx = P, N.jsxs = P, N; | ||
return Y.Fragment = E, Y.jsx = P, Y.jsxs = P, Y; | ||
} | ||
var Y = {}; | ||
var z = {}; | ||
/** | ||
@@ -41,38 +41,38 @@ * @license React | ||
*/ | ||
var Ir; | ||
var Dr; | ||
function hn() { | ||
return Ir || (Ir = 1, process.env.NODE_ENV !== "production" && function() { | ||
var h = K, g = Symbol.for("react.element"), _ = Symbol.for("react.portal"), m = Symbol.for("react.fragment"), j = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), P = Symbol.for("react.provider"), C = Symbol.for("react.context"), p = Symbol.for("react.forward_ref"), y = Symbol.for("react.suspense"), b = Symbol.for("react.suspense_list"), d = Symbol.for("react.memo"), E = Symbol.for("react.lazy"), I = Symbol.for("react.offscreen"), z = Symbol.iterator, V = "@@iterator"; | ||
function H(r) { | ||
return Dr || (Dr = 1, process.env.NODE_ENV !== "production" && function() { | ||
var v = K, w = Symbol.for("react.element"), E = Symbol.for("react.portal"), m = Symbol.for("react.fragment"), R = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), P = Symbol.for("react.provider"), j = Symbol.for("react.context"), h = Symbol.for("react.forward_ref"), F = Symbol.for("react.suspense"), c = Symbol.for("react.suspense_list"), _ = Symbol.for("react.memo"), l = Symbol.for("react.lazy"), C = Symbol.for("react.offscreen"), $ = Symbol.iterator, H = "@@iterator"; | ||
function V(r) { | ||
if (r === null || typeof r != "object") | ||
return null; | ||
var n = z && r[z] || r[V]; | ||
var n = $ && r[$] || r[H]; | ||
return typeof n == "function" ? n : null; | ||
} | ||
var F = h.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; | ||
function v(r) { | ||
var I = v.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED; | ||
function g(r) { | ||
{ | ||
for (var n = arguments.length, e = new Array(n > 1 ? n - 1 : 0), o = 1; o < n; o++) | ||
e[o - 1] = arguments[o]; | ||
s("error", r, e); | ||
X("error", r, e); | ||
} | ||
} | ||
function s(r, n, e) { | ||
function X(r, n, e) { | ||
{ | ||
var o = F.ReactDebugCurrentFrame, a = o.getStackAddendum(); | ||
var o = I.ReactDebugCurrentFrame, a = o.getStackAddendum(); | ||
a !== "" && (n += "%s", e = e.concat([a])); | ||
var u = e.map(function(t) { | ||
var s = e.map(function(t) { | ||
return String(t); | ||
}); | ||
u.unshift("Warning: " + n), Function.prototype.apply.call(console[r], console, u); | ||
s.unshift("Warning: " + n), Function.prototype.apply.call(console[r], console, s); | ||
} | ||
} | ||
var x = !1, M = !1, k = !1, X = !1, $r = !1, sr; | ||
sr = Symbol.for("react.module.reference"); | ||
var d = !1, y = !1, M = !1, k = !1, Z = !1, ur; | ||
ur = Symbol.for("react.module.reference"); | ||
function Lr(r) { | ||
return !!(typeof r == "string" || typeof r == "function" || r === m || r === S || $r || r === j || r === y || r === b || X || r === I || x || M || k || typeof r == "object" && r !== null && (r.$$typeof === E || r.$$typeof === d || r.$$typeof === P || r.$$typeof === C || r.$$typeof === p || // This needs to include all possible module reference object | ||
return !!(typeof r == "string" || typeof r == "function" || r === m || r === S || Z || r === R || r === F || r === c || k || r === C || d || y || M || typeof r == "object" && r !== null && (r.$$typeof === l || r.$$typeof === _ || r.$$typeof === P || r.$$typeof === j || r.$$typeof === h || // This needs to include all possible module reference object | ||
// types supported by any Flight configuration anywhere since | ||
// we don't know which Flight build this will end up being used | ||
// with. | ||
r.$$typeof === sr || r.getModuleId !== void 0)); | ||
r.$$typeof === ur || r.getModuleId !== void 0)); | ||
} | ||
@@ -86,3 +86,3 @@ function Nr(r, n, e) { | ||
} | ||
function ur(r) { | ||
function lr(r) { | ||
return r.displayName || "Context"; | ||
@@ -93,3 +93,3 @@ } | ||
return null; | ||
if (typeof r.tag == "number" && v("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function") | ||
if (typeof r.tag == "number" && g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function") | ||
return r.displayName || r.name || null; | ||
@@ -101,11 +101,11 @@ if (typeof r == "string") | ||
return "Fragment"; | ||
case _: | ||
case E: | ||
return "Portal"; | ||
case S: | ||
return "Profiler"; | ||
case j: | ||
case R: | ||
return "StrictMode"; | ||
case y: | ||
case F: | ||
return "Suspense"; | ||
case b: | ||
case c: | ||
return "SuspenseList"; | ||
@@ -115,17 +115,17 @@ } | ||
switch (r.$$typeof) { | ||
case C: | ||
case j: | ||
var n = r; | ||
return ur(n) + ".Consumer"; | ||
return lr(n) + ".Consumer"; | ||
case P: | ||
var e = r; | ||
return ur(e._context) + ".Provider"; | ||
case p: | ||
return lr(e._context) + ".Provider"; | ||
case h: | ||
return Nr(r, r.render, "ForwardRef"); | ||
case d: | ||
case _: | ||
var o = r.displayName || null; | ||
return o !== null ? o : T(r.type) || "Memo"; | ||
case E: { | ||
var a = r, u = a._payload, t = a._init; | ||
case l: { | ||
var a = r, s = a._payload, t = a._init; | ||
try { | ||
return T(t(u)); | ||
return T(t(s)); | ||
} catch { | ||
@@ -138,3 +138,3 @@ return null; | ||
} | ||
var D = Object.assign, $ = 0, lr, cr, fr, pr, hr, vr, gr; | ||
var D = Object.assign, L = 0, cr, fr, pr, hr, vr, gr, wr; | ||
function br() { | ||
@@ -145,4 +145,4 @@ } | ||
{ | ||
if ($ === 0) { | ||
lr = console.log, cr = console.info, fr = console.warn, pr = console.error, hr = console.group, vr = console.groupCollapsed, gr = console.groupEnd; | ||
if (L === 0) { | ||
cr = console.log, fr = console.info, pr = console.warn, hr = console.error, vr = console.group, gr = console.groupCollapsed, wr = console.groupEnd; | ||
var r = { | ||
@@ -164,3 +164,3 @@ configurable: !0, | ||
} | ||
$++; | ||
L++; | ||
} | ||
@@ -170,3 +170,3 @@ } | ||
{ | ||
if ($--, $ === 0) { | ||
if (L--, L === 0) { | ||
var r = { | ||
@@ -179,31 +179,31 @@ configurable: !0, | ||
log: D({}, r, { | ||
value: lr | ||
value: cr | ||
}), | ||
info: D({}, r, { | ||
value: cr | ||
value: fr | ||
}), | ||
warn: D({}, r, { | ||
value: fr | ||
value: pr | ||
}), | ||
error: D({}, r, { | ||
value: pr | ||
value: hr | ||
}), | ||
group: D({}, r, { | ||
value: hr | ||
value: vr | ||
}), | ||
groupCollapsed: D({}, r, { | ||
value: vr | ||
value: gr | ||
}), | ||
groupEnd: D({}, r, { | ||
value: gr | ||
value: wr | ||
}) | ||
}); | ||
} | ||
$ < 0 && v("disabledDepth fell below zero. This is a bug in React. Please file an issue."); | ||
L < 0 && g("disabledDepth fell below zero. This is a bug in React. Please file an issue."); | ||
} | ||
} | ||
var Z = F.ReactCurrentDispatcher, Q; | ||
var Q = I.ReactCurrentDispatcher, rr; | ||
function U(r, n, e) { | ||
{ | ||
if (Q === void 0) | ||
if (rr === void 0) | ||
try { | ||
@@ -213,9 +213,9 @@ throw Error(); | ||
var o = a.stack.trim().match(/\n( *(at )?)/); | ||
Q = o && o[1] || ""; | ||
rr = o && o[1] || ""; | ||
} | ||
return ` | ||
` + Q + r; | ||
` + rr + r; | ||
} | ||
} | ||
var rr = !1, q; | ||
var nr = !1, q; | ||
{ | ||
@@ -225,4 +225,4 @@ var Vr = typeof WeakMap == "function" ? WeakMap : Map; | ||
} | ||
function wr(r, n) { | ||
if (!r || rr) | ||
function mr(r, n) { | ||
if (!r || nr) | ||
return ""; | ||
@@ -235,7 +235,7 @@ { | ||
var o; | ||
rr = !0; | ||
nr = !0; | ||
var a = Error.prepareStackTrace; | ||
Error.prepareStackTrace = void 0; | ||
var u; | ||
u = Z.current, Z.current = null, Yr(); | ||
var s; | ||
s = Q.current, Q.current = null, Yr(); | ||
try { | ||
@@ -276,15 +276,15 @@ if (n) { | ||
for (var i = O.stack.split(` | ||
`), w = o.stack.split(` | ||
`), c = i.length - 1, f = w.length - 1; c >= 1 && f >= 0 && i[c] !== w[f]; ) | ||
f--; | ||
for (; c >= 1 && f >= 0; c--, f--) | ||
if (i[c] !== w[f]) { | ||
if (c !== 1 || f !== 1) | ||
`), b = o.stack.split(` | ||
`), f = i.length - 1, p = b.length - 1; f >= 1 && p >= 0 && i[f] !== b[p]; ) | ||
p--; | ||
for (; f >= 1 && p >= 0; f--, p--) | ||
if (i[f] !== b[p]) { | ||
if (f !== 1 || p !== 1) | ||
do | ||
if (c--, f--, f < 0 || i[c] !== w[f]) { | ||
var R = ` | ||
` + i[c].replace(" at new ", " at "); | ||
return r.displayName && R.includes("<anonymous>") && (R = R.replace("<anonymous>", r.displayName)), typeof r == "function" && q.set(r, R), R; | ||
if (f--, p--, p < 0 || i[f] !== b[p]) { | ||
var x = ` | ||
` + i[f].replace(" at new ", " at "); | ||
return r.displayName && x.includes("<anonymous>") && (x = x.replace("<anonymous>", r.displayName)), typeof r == "function" && q.set(r, x), x; | ||
} | ||
while (c >= 1 && f >= 0); | ||
while (f >= 1 && p >= 0); | ||
break; | ||
@@ -294,9 +294,9 @@ } | ||
} finally { | ||
rr = !1, Z.current = u, zr(), Error.prepareStackTrace = a; | ||
nr = !1, Q.current = s, zr(), Error.prepareStackTrace = a; | ||
} | ||
var W = r ? r.displayName || r.name : "", Pr = W ? U(W) : ""; | ||
return typeof r == "function" && q.set(r, Pr), Pr; | ||
var W = r ? r.displayName || r.name : "", Fr = W ? U(W) : ""; | ||
return typeof r == "function" && q.set(r, Fr), Fr; | ||
} | ||
function Mr(r, n, e) { | ||
return wr(r, !1); | ||
return mr(r, !1); | ||
} | ||
@@ -311,9 +311,9 @@ function Ur(r) { | ||
if (typeof r == "function") | ||
return wr(r, Ur(r)); | ||
return mr(r, Ur(r)); | ||
if (typeof r == "string") | ||
return U(r); | ||
switch (r) { | ||
case y: | ||
case F: | ||
return U("Suspense"); | ||
case b: | ||
case c: | ||
return U("SuspenseList"); | ||
@@ -323,10 +323,10 @@ } | ||
switch (r.$$typeof) { | ||
case p: | ||
case h: | ||
return Mr(r.render); | ||
case d: | ||
case _: | ||
return B(r.type, n, e); | ||
case E: { | ||
var o = r, a = o._payload, u = o._init; | ||
case l: { | ||
var o = r, a = o._payload, s = o._init; | ||
try { | ||
return B(u(a), n, e); | ||
return B(s(a), n, e); | ||
} catch { | ||
@@ -338,26 +338,26 @@ } | ||
} | ||
var J = Object.prototype.hasOwnProperty, mr = {}, yr = F.ReactDebugCurrentFrame; | ||
var J = Object.prototype.hasOwnProperty, yr = {}, xr = I.ReactDebugCurrentFrame; | ||
function G(r) { | ||
if (r) { | ||
var n = r._owner, e = B(r.type, r._source, n ? n.type : null); | ||
yr.setExtraStackFrame(e); | ||
xr.setExtraStackFrame(e); | ||
} else | ||
yr.setExtraStackFrame(null); | ||
xr.setExtraStackFrame(null); | ||
} | ||
function qr(r, n, e, o, a) { | ||
{ | ||
var u = Function.call.bind(J); | ||
var s = Function.call.bind(J); | ||
for (var t in r) | ||
if (u(r, t)) { | ||
if (s(r, t)) { | ||
var i = void 0; | ||
try { | ||
if (typeof r[t] != "function") { | ||
var w = Error((o || "React class") + ": " + e + " type `" + t + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[t] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."); | ||
throw w.name = "Invariant Violation", w; | ||
var b = Error((o || "React class") + ": " + e + " type `" + t + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[t] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."); | ||
throw b.name = "Invariant Violation", b; | ||
} | ||
i = r[t](n, t, o, e, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"); | ||
} catch (c) { | ||
i = c; | ||
} catch (f) { | ||
i = f; | ||
} | ||
i && !(i instanceof Error) && (G(a), v("%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).", o || "React class", e, t, typeof i), G(null)), i instanceof Error && !(i.message in mr) && (mr[i.message] = !0, G(a), v("Failed %s type: %s", e, i.message), G(null)); | ||
i && !(i instanceof Error) && (G(a), g("%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).", o || "React class", e, t, typeof i), G(null)), i instanceof Error && !(i.message in yr) && (yr[i.message] = !0, G(a), g("Failed %s type: %s", e, i.message), G(null)); | ||
} | ||
@@ -367,3 +367,3 @@ } | ||
var Br = Array.isArray; | ||
function nr(r) { | ||
function er(r) { | ||
return Br(r); | ||
@@ -379,3 +379,3 @@ } | ||
try { | ||
return xr(r), !1; | ||
return Er(r), !1; | ||
} catch { | ||
@@ -385,10 +385,10 @@ return !0; | ||
} | ||
function xr(r) { | ||
function Er(r) { | ||
return "" + r; | ||
} | ||
function Er(r) { | ||
function Rr(r) { | ||
if (Gr(r)) | ||
return v("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Jr(r)), xr(r); | ||
return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Jr(r)), Er(r); | ||
} | ||
var L = F.ReactCurrentOwner, Kr = { | ||
var N = I.ReactCurrentOwner, Kr = { | ||
key: !0, | ||
@@ -398,4 +398,4 @@ ref: !0, | ||
__source: !0 | ||
}, Rr, _r, er; | ||
er = {}; | ||
}, _r, jr, or; | ||
or = {}; | ||
function Hr(r) { | ||
@@ -418,5 +418,5 @@ if (J.call(r, "ref")) { | ||
function Zr(r, n) { | ||
if (typeof r.ref == "string" && L.current && n && L.current.stateNode !== n) { | ||
var e = T(L.current.type); | ||
er[e] || (v('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', T(L.current.type), r.ref), er[e] = !0); | ||
if (typeof r.ref == "string" && N.current && n && N.current.stateNode !== n) { | ||
var e = T(N.current.type); | ||
or[e] || (g('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', T(N.current.type), r.ref), or[e] = !0); | ||
} | ||
@@ -427,3 +427,3 @@ } | ||
var e = function() { | ||
Rr || (Rr = !0, v("%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)); | ||
_r || (_r = !0, g("%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)); | ||
}; | ||
@@ -439,3 +439,3 @@ e.isReactWarning = !0, Object.defineProperty(r, "key", { | ||
var e = function() { | ||
_r || (_r = !0, v("%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)); | ||
jr || (jr = !0, g("%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)); | ||
}; | ||
@@ -448,6 +448,6 @@ e.isReactWarning = !0, Object.defineProperty(r, "ref", { | ||
} | ||
var nn = function(r, n, e, o, a, u, t) { | ||
var nn = function(r, n, e, o, a, s, t) { | ||
var i = { | ||
// This tag allows us to uniquely identify this as a React Element | ||
$$typeof: g, | ||
$$typeof: w, | ||
// Built-in properties that belong on the element | ||
@@ -459,3 +459,3 @@ type: r, | ||
// Record the component responsible for creating this element. | ||
_owner: u | ||
_owner: s | ||
}; | ||
@@ -481,35 +481,35 @@ return i._store = {}, Object.defineProperty(i._store, "validated", { | ||
{ | ||
var u, t = {}, i = null, w = null; | ||
e !== void 0 && (Er(e), i = "" + e), Xr(n) && (Er(n.key), i = "" + n.key), Hr(n) && (w = n.ref, Zr(n, a)); | ||
for (u in n) | ||
J.call(n, u) && !Kr.hasOwnProperty(u) && (t[u] = n[u]); | ||
var s, t = {}, i = null, b = null; | ||
e !== void 0 && (Rr(e), i = "" + e), Xr(n) && (Rr(n.key), i = "" + n.key), Hr(n) && (b = n.ref, Zr(n, a)); | ||
for (s in n) | ||
J.call(n, s) && !Kr.hasOwnProperty(s) && (t[s] = n[s]); | ||
if (r && r.defaultProps) { | ||
var c = r.defaultProps; | ||
for (u in c) | ||
t[u] === void 0 && (t[u] = c[u]); | ||
var f = r.defaultProps; | ||
for (s in f) | ||
t[s] === void 0 && (t[s] = f[s]); | ||
} | ||
if (i || w) { | ||
var f = typeof r == "function" ? r.displayName || r.name || "Unknown" : r; | ||
i && Qr(t, f), w && rn(t, f); | ||
if (i || b) { | ||
var p = typeof r == "function" ? r.displayName || r.name || "Unknown" : r; | ||
i && Qr(t, p), b && rn(t, p); | ||
} | ||
return nn(r, i, w, a, o, L.current, t); | ||
return nn(r, i, b, a, o, N.current, t); | ||
} | ||
} | ||
var or = F.ReactCurrentOwner, jr = F.ReactDebugCurrentFrame; | ||
var ir = I.ReactCurrentOwner, Cr = I.ReactDebugCurrentFrame; | ||
function A(r) { | ||
if (r) { | ||
var n = r._owner, e = B(r.type, r._source, n ? n.type : null); | ||
jr.setExtraStackFrame(e); | ||
Cr.setExtraStackFrame(e); | ||
} else | ||
jr.setExtraStackFrame(null); | ||
Cr.setExtraStackFrame(null); | ||
} | ||
var ir; | ||
ir = !1; | ||
function tr(r) { | ||
return typeof r == "object" && r !== null && r.$$typeof === g; | ||
var tr; | ||
tr = !1; | ||
function ar(r) { | ||
return typeof r == "object" && r !== null && r.$$typeof === w; | ||
} | ||
function Cr() { | ||
function kr() { | ||
{ | ||
if (or.current) { | ||
var r = T(or.current.type); | ||
if (ir.current) { | ||
var r = T(ir.current.type); | ||
if (r) | ||
@@ -534,6 +534,6 @@ return ` | ||
} | ||
var kr = {}; | ||
var Tr = {}; | ||
function tn(r) { | ||
{ | ||
var n = Cr(); | ||
var n = kr(); | ||
if (!n) { | ||
@@ -548,3 +548,3 @@ var e = typeof r == "string" ? r : r.displayName || r.name; | ||
} | ||
function Tr(r, n) { | ||
function Or(r, n) { | ||
{ | ||
@@ -555,25 +555,25 @@ if (!r._store || r._store.validated || r.key != null) | ||
var e = tn(n); | ||
if (kr[e]) | ||
if (Tr[e]) | ||
return; | ||
kr[e] = !0; | ||
Tr[e] = !0; | ||
var o = ""; | ||
r && r._owner && r._owner !== or.current && (o = " It was passed a child from " + T(r._owner.type) + "."), A(r), v('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', e, o), A(null); | ||
r && r._owner && r._owner !== ir.current && (o = " It was passed a child from " + T(r._owner.type) + "."), A(r), g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', e, o), A(null); | ||
} | ||
} | ||
function Or(r, n) { | ||
function Sr(r, n) { | ||
{ | ||
if (typeof r != "object") | ||
return; | ||
if (nr(r)) | ||
if (er(r)) | ||
for (var e = 0; e < r.length; e++) { | ||
var o = r[e]; | ||
tr(o) && Tr(o, n); | ||
ar(o) && Or(o, n); | ||
} | ||
else if (tr(r)) | ||
else if (ar(r)) | ||
r._store && (r._store.validated = !0); | ||
else if (r) { | ||
var a = H(r); | ||
var a = V(r); | ||
if (typeof a == "function" && a !== r.entries) | ||
for (var u = a.call(r), t; !(t = u.next()).done; ) | ||
tr(t.value) && Tr(t.value, n); | ||
for (var s = a.call(r), t; !(t = s.next()).done; ) | ||
ar(t.value) && Or(t.value, n); | ||
} | ||
@@ -590,5 +590,5 @@ } | ||
e = n.propTypes; | ||
else if (typeof n == "object" && (n.$$typeof === p || // Note: Memo only checks outer props here. | ||
else if (typeof n == "object" && (n.$$typeof === h || // Note: Memo only checks outer props here. | ||
// Inner props are checked in the reconciler. | ||
n.$$typeof === d)) | ||
n.$$typeof === _)) | ||
e = n.propTypes; | ||
@@ -600,8 +600,8 @@ else | ||
qr(e, r.props, "prop", o, r); | ||
} else if (n.PropTypes !== void 0 && !ir) { | ||
ir = !0; | ||
} else if (n.PropTypes !== void 0 && !tr) { | ||
tr = !0; | ||
var a = T(n); | ||
v("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", a || "Unknown"); | ||
g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", a || "Unknown"); | ||
} | ||
typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && v("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead."); | ||
typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead."); | ||
} | ||
@@ -614,10 +614,10 @@ } | ||
if (o !== "children" && o !== "key") { | ||
A(r), v("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", o), A(null); | ||
A(r), g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", o), A(null); | ||
break; | ||
} | ||
} | ||
r.ref !== null && (A(r), v("Invalid attribute `ref` supplied to `React.Fragment`."), A(null)); | ||
r.ref !== null && (A(r), g("Invalid attribute `ref` supplied to `React.Fragment`."), A(null)); | ||
} | ||
} | ||
function Sr(r, n, e, o, a, u) { | ||
function Pr(r, n, e, o, a, s) { | ||
{ | ||
@@ -628,38 +628,38 @@ var t = Lr(r); | ||
(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."); | ||
var w = on(a); | ||
w ? i += w : i += Cr(); | ||
var c; | ||
r === null ? c = "null" : nr(r) ? c = "array" : r !== void 0 && r.$$typeof === g ? (c = "<" + (T(r.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : c = typeof r, v("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", c, i); | ||
var b = on(a); | ||
b ? i += b : i += kr(); | ||
var f; | ||
r === null ? f = "null" : er(r) ? f = "array" : r !== void 0 && r.$$typeof === w ? (f = "<" + (T(r.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : f = typeof r, g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", f, i); | ||
} | ||
var f = en(r, n, e, a, u); | ||
if (f == null) | ||
return f; | ||
var p = en(r, n, e, a, s); | ||
if (p == null) | ||
return p; | ||
if (t) { | ||
var R = n.children; | ||
if (R !== void 0) | ||
var x = n.children; | ||
if (x !== void 0) | ||
if (o) | ||
if (nr(R)) { | ||
for (var W = 0; W < R.length; W++) | ||
Or(R[W], r); | ||
Object.freeze && Object.freeze(R); | ||
if (er(x)) { | ||
for (var W = 0; W < x.length; W++) | ||
Sr(x[W], r); | ||
Object.freeze && Object.freeze(x); | ||
} else | ||
v("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."); | ||
g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."); | ||
else | ||
Or(R, r); | ||
Sr(x, r); | ||
} | ||
return r === m ? dn(f) : an(f), f; | ||
return r === m ? dn(p) : an(p), p; | ||
} | ||
} | ||
function sn(r, n, e) { | ||
return Sr(r, n, e, !0); | ||
return Pr(r, n, e, !0); | ||
} | ||
function un(r, n, e) { | ||
return Sr(r, n, e, !1); | ||
return Pr(r, n, e, !1); | ||
} | ||
var ln = un, cn = sn; | ||
Y.Fragment = m, Y.jsx = ln, Y.jsxs = cn; | ||
}()), Y; | ||
z.Fragment = m, z.jsx = ln, z.jsxs = cn; | ||
}()), z; | ||
} | ||
process.env.NODE_ENV === "production" ? dr.exports = pn() : dr.exports = hn(); | ||
var l = dr.exports; | ||
process.env.NODE_ENV === "production" ? sr.exports = pn() : sr.exports = hn(); | ||
var u = sr.exports; | ||
const vn = `@import url("https://fonts.googleapis.com/css2?family=Poppins&display=swap"); | ||
@@ -716,2 +716,4 @@ * { | ||
--hsd-ui-dropdown-color-secondary-red: var(--hsd-ui-color-red-500, #ef4444); | ||
/* plachoder color */ | ||
@@ -784,2 +786,6 @@ --hsd-ui-dropdown-placholder-color: #d0d6dd; | ||
} | ||
.hsd-input-dropdown-container.error { | ||
border-color: var(--hsd-ui-dropdown-color-secondary-red) !important; | ||
} | ||
.hsd-input-dropdown-container.active { | ||
@@ -895,47 +901,48 @@ border-color: var(--hsd-ui-dropdown-border-color-primary); | ||
`; | ||
function gn(h) { | ||
const [g, _] = ar(h), m = fn(null), j = (S) => { | ||
m.current && !m.current.contains(S.target) && _(!1); | ||
function gn(v) { | ||
const [w, E] = dr(v), m = fn(null), R = (S) => { | ||
m.current && !m.current.contains(S.target) && E(!1); | ||
}; | ||
return Wr(() => (document.addEventListener("click", j, !0), () => { | ||
document.removeEventListener("click", j, !0); | ||
}), []), { ref: m, isComponentVisible: g, setIsComponentVisible: _ }; | ||
return $r(() => (document.addEventListener("click", R, !0), () => { | ||
document.removeEventListener("click", R, !0); | ||
}), []), { ref: m, isComponentVisible: w, setIsComponentVisible: E }; | ||
} | ||
const Dr = "hudoro-input-dropdown-styles", bn = (h) => { | ||
if (!document.getElementById(Dr)) { | ||
const g = document.createElement("style"); | ||
g.id = Dr, g.textContent = h, document.head.appendChild(g); | ||
const Ar = "hudoro-input-dropdown-styles", wn = (v) => { | ||
if (!document.getElementById(Ar)) { | ||
const w = document.createElement("style"); | ||
w.id = Ar, w.textContent = v, document.head.appendChild(w); | ||
} | ||
}; | ||
bn(vn); | ||
wn(vn); | ||
const xn = ({ | ||
dropdownLists: h, | ||
onChange: g, | ||
defaultValue: _, | ||
dropdownLists: v, | ||
onChange: w, | ||
defaultValue: E, | ||
size: m = "md", | ||
multiSelect: j, | ||
multiSelect: R, | ||
searchAble: S, | ||
iconLeft: P, | ||
placeholder: C, | ||
onSearch: p | ||
placeholder: j, | ||
onSearch: h, | ||
error: F | ||
}) => { | ||
const [y, b] = ar([]), [d, E] = ar([]), { isComponentVisible: I, ref: z, setIsComponentVisible: V } = gn(!1), H = () => { | ||
V((s) => !s); | ||
}, F = (s, x) => { | ||
if (!j) | ||
E([{ label: s, value: x }]), g([{ label: s, value: x }]), V(!1); | ||
else if (d == null ? void 0 : d.find((k) => k.value === x)) { | ||
const [c, _] = dr([]), [l, C] = dr([]), { isComponentVisible: $, ref: H, setIsComponentVisible: V } = gn(!1), I = () => { | ||
V((d) => !d); | ||
}, g = (d, y) => { | ||
if (!R) | ||
C([{ label: d, value: y }]), w([{ label: d, value: y }]), V(!1); | ||
else if (l == null ? void 0 : l.find((k) => k.value === y)) { | ||
const k = [ | ||
...d ? d.filter((X) => X.value !== x) : [] | ||
...l ? l.filter((Z) => Z.value !== y) : [] | ||
]; | ||
E(k), g(k); | ||
C(k), w(k); | ||
} else { | ||
const k = [...d || [], { label: s, value: x }]; | ||
E(k), g(k); | ||
const k = [...l || [], { label: d, value: y }]; | ||
C(k), w(k); | ||
} | ||
}; | ||
Wr(() => { | ||
_ && (E(_), b(_)); | ||
}, [_]); | ||
const v = () => d.length ? j ? d == null ? void 0 : d.map((s, x) => /* @__PURE__ */ l.jsx( | ||
$r(() => { | ||
E && (C(E), _(E)); | ||
}, [E]); | ||
const X = () => l.length ? R ? l == null ? void 0 : l.map((d, y) => /* @__PURE__ */ u.jsx( | ||
"p", | ||
@@ -945,6 +952,6 @@ { | ||
className: "hsd-input-dropdown-preview-item", | ||
children: s == null ? void 0 : s.label | ||
children: d == null ? void 0 : d.label | ||
}, | ||
x | ||
)) : /* @__PURE__ */ l.jsx("p", { style: { minWidth: "max-content" }, children: d == null ? void 0 : d[0].label }) : y.length ? j ? y == null ? void 0 : y.map((s, x) => /* @__PURE__ */ l.jsx( | ||
y | ||
)) : /* @__PURE__ */ u.jsx("p", { style: { minWidth: "max-content" }, children: l == null ? void 0 : l[0].label }) : c.length ? R ? c == null ? void 0 : c.map((d, y) => /* @__PURE__ */ u.jsx( | ||
"p", | ||
@@ -954,34 +961,34 @@ { | ||
className: "hsd-input-dropdown-preview-item", | ||
children: s == null ? void 0 : s.label | ||
children: d == null ? void 0 : d.label | ||
}, | ||
x | ||
)) : /* @__PURE__ */ l.jsx("p", { style: { minWidth: "max-content" }, children: y == null ? void 0 : y[0].label }) : /* @__PURE__ */ l.jsx("p", { className: "hsd-input-dropdown-placeholder", children: C || "Search" }); | ||
return /* @__PURE__ */ l.jsxs( | ||
y | ||
)) : /* @__PURE__ */ u.jsx("p", { style: { minWidth: "max-content" }, children: c == null ? void 0 : c[0].label }) : /* @__PURE__ */ u.jsx("p", { className: "hsd-input-dropdown-placeholder", children: j || "Search" }); | ||
return /* @__PURE__ */ u.jsxs( | ||
"div", | ||
{ | ||
className: `hsd-input-dropdown-container hsd-input-dropdown-size-${m} ${I ? "active" : ""}`, | ||
ref: z, | ||
onClick: H, | ||
className: `hsd-input-dropdown-container hsd-input-dropdown-size-${m} ${$ ? "active" : ""} ${F ? "error" : ""}`, | ||
ref: H, | ||
onClick: I, | ||
children: [ | ||
/* @__PURE__ */ l.jsxs("div", { className: "hsd-input-dropdown-preview-container", children: [ | ||
P ? /* @__PURE__ */ l.jsx(l.Fragment, { children: K.cloneElement(P, { | ||
width: Ar(m), | ||
/* @__PURE__ */ u.jsxs("div", { className: "hsd-input-dropdown-preview-container", children: [ | ||
P ? /* @__PURE__ */ u.jsx(u.Fragment, { children: K.cloneElement(P, { | ||
width: Wr(m), | ||
color: "#939E99" | ||
}) }) : null, | ||
/* @__PURE__ */ l.jsx("div", { className: "hsd-input-dropdown-container-preview-item", children: v() }), | ||
/* @__PURE__ */ l.jsx(mn, { strokeWidth: 2, width: Ar(m) }) | ||
/* @__PURE__ */ u.jsx("div", { className: "hsd-input-dropdown-container-preview-item", children: X() }), | ||
/* @__PURE__ */ u.jsx(mn, { strokeWidth: 2, width: Wr(m) }) | ||
] }), | ||
I ? /* @__PURE__ */ l.jsxs( | ||
$ ? /* @__PURE__ */ u.jsxs( | ||
"div", | ||
{ | ||
className: "hsd-input-dropdown-lists-container", | ||
onClick: (s) => s.stopPropagation(), | ||
onClick: (d) => d.stopPropagation(), | ||
children: [ | ||
S ? /* @__PURE__ */ l.jsxs("div", { className: "hsd-input-dropdown-container-dropdown-search", children: [ | ||
/* @__PURE__ */ l.jsx("div", { style: { display: "flex" }, children: /* @__PURE__ */ l.jsx(wn, { strokeWidth: 2, width: 20 }) }), | ||
/* @__PURE__ */ l.jsx( | ||
S ? /* @__PURE__ */ u.jsxs("div", { className: "hsd-input-dropdown-container-dropdown-search", children: [ | ||
/* @__PURE__ */ u.jsx("div", { style: { display: "flex" }, children: /* @__PURE__ */ u.jsx(bn, { strokeWidth: 2, width: 20 }) }), | ||
/* @__PURE__ */ u.jsx( | ||
"input", | ||
{ | ||
onChange: (s) => { | ||
p && p(s.target.value); | ||
onChange: (d) => { | ||
h && h(d.target.value); | ||
} | ||
@@ -991,18 +998,18 @@ } | ||
] }) : null, | ||
/* @__PURE__ */ l.jsx("div", { className: "hsd-input-dropdwon-item-container", children: h.map((s, x) => /* @__PURE__ */ l.jsxs( | ||
/* @__PURE__ */ u.jsx("div", { className: "hsd-input-dropdwon-item-container", children: v.map((d, y) => /* @__PURE__ */ u.jsxs( | ||
"div", | ||
{ | ||
className: `hsd-input-dropdwon-item ${d != null && d.find((M) => M.value === s.value) ? "active" : ""} ${s.disable ? "hsd-input-dropdwon-item-disable" : null}`, | ||
onClick: () => F(s.label, s.value), | ||
className: `hsd-input-dropdwon-item ${l != null && l.find((M) => M.value === d.value) ? "active" : ""} ${d.disable ? "hsd-input-dropdwon-item-disable" : null}`, | ||
onClick: () => g(d.label, d.value), | ||
children: [ | ||
s.icon ? /* @__PURE__ */ l.jsx("div", { children: K.cloneElement(s.icon, { | ||
d.icon ? /* @__PURE__ */ u.jsx("div", { children: K.cloneElement(d.icon, { | ||
width: 16 | ||
}) }) : null, | ||
/* @__PURE__ */ l.jsxs("div", { children: [ | ||
/* @__PURE__ */ u.jsxs("div", { children: [ | ||
" ", | ||
/* @__PURE__ */ l.jsx("p", { children: s.label }) | ||
/* @__PURE__ */ u.jsx("p", { children: d.label }) | ||
] }) | ||
] | ||
}, | ||
x | ||
y | ||
)) }) | ||
@@ -1015,11 +1022,11 @@ ] | ||
); | ||
}, wn = ({ ...h }) => /* @__PURE__ */ l.jsxs( | ||
}, bn = ({ ...v }) => /* @__PURE__ */ u.jsxs( | ||
"svg", | ||
{ | ||
xmlns: "http://www.w3.org/2000/svg", | ||
...h, | ||
...v, | ||
viewBox: "0 0 20 20", | ||
fill: "none", | ||
children: [ | ||
/* @__PURE__ */ l.jsx( | ||
/* @__PURE__ */ u.jsx( | ||
"circle", | ||
@@ -1036,3 +1043,3 @@ { | ||
), | ||
/* @__PURE__ */ l.jsx( | ||
/* @__PURE__ */ u.jsx( | ||
"path", | ||
@@ -1049,11 +1056,11 @@ { | ||
} | ||
), mn = ({ ...h }) => /* @__PURE__ */ l.jsx( | ||
), mn = ({ ...v }) => /* @__PURE__ */ u.jsx( | ||
"svg", | ||
{ | ||
xmlns: "http://www.w3.org/2000/svg", | ||
...h, | ||
...v, | ||
viewBox: "0 0 24 24", | ||
fill: "none", | ||
color: "#1976D2", | ||
children: /* @__PURE__ */ l.jsx( | ||
children: /* @__PURE__ */ u.jsx( | ||
"path", | ||
@@ -1068,8 +1075,8 @@ { | ||
} | ||
), Ar = (h) => { | ||
if (h === "sm") | ||
), Wr = (v) => { | ||
if (v === "sm") | ||
return 16; | ||
if (h === "md") | ||
if (v === "md") | ||
return 20; | ||
if (h === "lg") | ||
if (v === "lg") | ||
return 20; | ||
@@ -1076,0 +1083,0 @@ }; |
@@ -1,2 +0,2 @@ | ||
(function(D,m){typeof exports=="object"&&typeof module<"u"?m(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],m):(D=typeof globalThis<"u"?globalThis:D||self,m(D.Dropdown={},D.React))})(this,function(D,m){"use strict";var X={exports:{}},Y={};/** | ||
(function(A,m){typeof exports=="object"&&typeof module<"u"?m(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],m):(A=typeof globalThis<"u"?globalThis:A||self,m(A.Dropdown={},A.React))})(this,function(A,m){"use strict";var X={exports:{}},Y={};/** | ||
* @license React | ||
@@ -9,3 +9,3 @@ * react-jsx-runtime.production.min.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/var sr;function Wr(){if(sr)return Y;sr=1;var h=m,g=Symbol.for("react.element"),j=Symbol.for("react.fragment"),y=Object.prototype.hasOwnProperty,C=h.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,P={key:!0,ref:!0,__self:!0,__source:!0};function F(T,p,x){var b,d={},R=null,A=null;x!==void 0&&(R=""+x),p.key!==void 0&&(R=""+p.key),p.ref!==void 0&&(A=p.ref);for(b in p)y.call(p,b)&&!P.hasOwnProperty(b)&&(d[b]=p[b]);if(T&&T.defaultProps)for(b in p=T.defaultProps,p)d[b]===void 0&&(d[b]=p[b]);return{$$typeof:g,type:T,key:R,ref:A,props:d,_owner:C.current}}return Y.Fragment=j,Y.jsx=F,Y.jsxs=F,Y}var z={};/** | ||
*/var ur;function Lr(){if(ur)return Y;ur=1;var v=m,w=Symbol.for("react.element"),R=Symbol.for("react.fragment"),y=Object.prototype.hasOwnProperty,_=v.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,P={key:!0,ref:!0,__self:!0,__source:!0};function F(C,h,I){var c,j={},l=null,T=null;I!==void 0&&(l=""+I),h.key!==void 0&&(l=""+h.key),h.ref!==void 0&&(T=h.ref);for(c in h)y.call(h,c)&&!P.hasOwnProperty(c)&&(j[c]=h[c]);if(C&&C.defaultProps)for(c in h=C.defaultProps,h)j[c]===void 0&&(j[c]=h[c]);return{$$typeof:w,type:C,key:l,ref:T,props:j,_owner:_.current}}return Y.Fragment=R,Y.jsx=F,Y.jsxs=F,Y}var z={};/** | ||
* @license React | ||
@@ -18,13 +18,13 @@ * react-jsx-runtime.development.js | ||
* LICENSE file in the root directory of this source tree. | ||
*/var ur;function Lr(){return ur||(ur=1,process.env.NODE_ENV!=="production"&&function(){var h=m,g=Symbol.for("react.element"),j=Symbol.for("react.portal"),y=Symbol.for("react.fragment"),C=Symbol.for("react.strict_mode"),P=Symbol.for("react.profiler"),F=Symbol.for("react.provider"),T=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),x=Symbol.for("react.suspense"),b=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),R=Symbol.for("react.lazy"),A=Symbol.for("react.offscreen"),U=Symbol.iterator,B="@@iterator";function Z(r){if(r===null||typeof r!="object")return null;var n=U&&r[U]||r[B];return typeof n=="function"?n:null}var I=h.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function v(r){{for(var n=arguments.length,e=new Array(n>1?n-1:0),o=1;o<n;o++)e[o-1]=arguments[o];s("error",r,e)}}function s(r,n,e){{var o=I.ReactDebugCurrentFrame,a=o.getStackAddendum();a!==""&&(n+="%s",e=e.concat([a]));var u=e.map(function(t){return String(t)});u.unshift("Warning: "+n),Function.prototype.apply.call(console[r],console,u)}}var E=!1,$=!1,k=!1,Q=!1,Ur=!1,fr;fr=Symbol.for("react.module.reference");function Br(r){return!!(typeof r=="string"||typeof r=="function"||r===y||r===P||Ur||r===C||r===x||r===b||Q||r===A||E||$||k||typeof r=="object"&&r!==null&&(r.$$typeof===R||r.$$typeof===d||r.$$typeof===F||r.$$typeof===T||r.$$typeof===p||r.$$typeof===fr||r.getModuleId!==void 0))}function $r(r,n,e){var o=r.displayName;if(o)return o;var a=n.displayName||n.name||"";return a!==""?e+"("+a+")":e}function pr(r){return r.displayName||"Context"}function S(r){if(r==null)return null;if(typeof r.tag=="number"&&v("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case y:return"Fragment";case j:return"Portal";case P:return"Profiler";case C:return"StrictMode";case x:return"Suspense";case b:return"SuspenseList"}if(typeof r=="object")switch(r.$$typeof){case T:var n=r;return pr(n)+".Consumer";case F:var e=r;return pr(e._context)+".Provider";case p:return $r(r,r.render,"ForwardRef");case d:var o=r.displayName||null;return o!==null?o:S(r.type)||"Memo";case R:{var a=r,u=a._payload,t=a._init;try{return S(t(u))}catch{return null}}}return null}var W=Object.assign,V=0,hr,vr,gr,br,wr,mr,yr;function xr(){}xr.__reactDisabledLog=!0;function Jr(){{if(V===0){hr=console.log,vr=console.info,gr=console.warn,br=console.error,wr=console.group,mr=console.groupCollapsed,yr=console.groupEnd;var r={configurable:!0,enumerable:!0,value:xr,writable:!0};Object.defineProperties(console,{info:r,log:r,warn:r,error:r,group:r,groupCollapsed:r,groupEnd:r})}V++}}function Gr(){{if(V--,V===0){var r={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:W({},r,{value:hr}),info:W({},r,{value:vr}),warn:W({},r,{value:gr}),error:W({},r,{value:br}),group:W({},r,{value:wr}),groupCollapsed:W({},r,{value:mr}),groupEnd:W({},r,{value:yr})})}V<0&&v("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var rr=I.ReactCurrentDispatcher,nr;function J(r,n,e){{if(nr===void 0)try{throw Error()}catch(a){var o=a.stack.trim().match(/\n( *(at )?)/);nr=o&&o[1]||""}return` | ||
`+nr+r}}var er=!1,G;{var qr=typeof WeakMap=="function"?WeakMap:Map;G=new qr}function Er(r,n){if(!r||er)return"";{var e=G.get(r);if(e!==void 0)return e}var o;er=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var u;u=rr.current,rr.current=null,Jr();try{if(n){var t=function(){throw Error()};if(Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(O){o=O}Reflect.construct(r,[],t)}else{try{t.call()}catch(O){o=O}r.call(t.prototype)}}else{try{throw Error()}catch(O){o=O}r()}}catch(O){if(O&&o&&typeof O.stack=="string"){for(var i=O.stack.split(` | ||
`),w=o.stack.split(` | ||
`),c=i.length-1,f=w.length-1;c>=1&&f>=0&&i[c]!==w[f];)f--;for(;c>=1&&f>=0;c--,f--)if(i[c]!==w[f]){if(c!==1||f!==1)do if(c--,f--,f<0||i[c]!==w[f]){var _=` | ||
`+i[c].replace(" at new "," at ");return r.displayName&&_.includes("<anonymous>")&&(_=_.replace("<anonymous>",r.displayName)),typeof r=="function"&&G.set(r,_),_}while(c>=1&&f>=0);break}}}finally{er=!1,rr.current=u,Gr(),Error.prepareStackTrace=a}var N=r?r.displayName||r.name:"",Ar=N?J(N):"";return typeof r=="function"&&G.set(r,Ar),Ar}function Kr(r,n,e){return Er(r,!1)}function Hr(r){var n=r.prototype;return!!(n&&n.isReactComponent)}function q(r,n,e){if(r==null)return"";if(typeof r=="function")return Er(r,Hr(r));if(typeof r=="string")return J(r);switch(r){case x:return J("Suspense");case b:return J("SuspenseList")}if(typeof r=="object")switch(r.$$typeof){case p:return Kr(r.render);case d:return q(r.type,n,e);case R:{var o=r,a=o._payload,u=o._init;try{return q(u(a),n,e)}catch{}}}return""}var K=Object.prototype.hasOwnProperty,Rr={},_r=I.ReactDebugCurrentFrame;function H(r){if(r){var n=r._owner,e=q(r.type,r._source,n?n.type:null);_r.setExtraStackFrame(e)}else _r.setExtraStackFrame(null)}function Xr(r,n,e,o,a){{var u=Function.call.bind(K);for(var t in r)if(u(r,t)){var i=void 0;try{if(typeof r[t]!="function"){var w=Error((o||"React class")+": "+e+" type `"+t+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof r[t]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw w.name="Invariant Violation",w}i=r[t](n,t,o,e,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(c){i=c}i&&!(i instanceof Error)&&(H(a),v("%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).",o||"React class",e,t,typeof i),H(null)),i instanceof Error&&!(i.message in Rr)&&(Rr[i.message]=!0,H(a),v("Failed %s type: %s",e,i.message),H(null))}}}var Zr=Array.isArray;function or(r){return Zr(r)}function Qr(r){{var n=typeof Symbol=="function"&&Symbol.toStringTag,e=n&&r[Symbol.toStringTag]||r.constructor.name||"Object";return e}}function rn(r){try{return jr(r),!1}catch{return!0}}function jr(r){return""+r}function Cr(r){if(rn(r))return v("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Qr(r)),jr(r)}var M=I.ReactCurrentOwner,nn={key:!0,ref:!0,__self:!0,__source:!0},Tr,kr,ir;ir={};function en(r){if(K.call(r,"ref")){var n=Object.getOwnPropertyDescriptor(r,"ref").get;if(n&&n.isReactWarning)return!1}return r.ref!==void 0}function on(r){if(K.call(r,"key")){var n=Object.getOwnPropertyDescriptor(r,"key").get;if(n&&n.isReactWarning)return!1}return r.key!==void 0}function tn(r,n){if(typeof r.ref=="string"&&M.current&&n&&M.current.stateNode!==n){var e=S(M.current.type);ir[e]||(v('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',S(M.current.type),r.ref),ir[e]=!0)}}function an(r,n){{var e=function(){Tr||(Tr=!0,v("%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))};e.isReactWarning=!0,Object.defineProperty(r,"key",{get:e,configurable:!0})}}function dn(r,n){{var e=function(){kr||(kr=!0,v("%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))};e.isReactWarning=!0,Object.defineProperty(r,"ref",{get:e,configurable:!0})}}var sn=function(r,n,e,o,a,u,t){var i={$$typeof:g,type:r,key:n,ref:e,props:t,_owner:u};return i._store={},Object.defineProperty(i._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(i,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(i,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(i.props),Object.freeze(i)),i};function un(r,n,e,o,a){{var u,t={},i=null,w=null;e!==void 0&&(Cr(e),i=""+e),on(n)&&(Cr(n.key),i=""+n.key),en(n)&&(w=n.ref,tn(n,a));for(u in n)K.call(n,u)&&!nn.hasOwnProperty(u)&&(t[u]=n[u]);if(r&&r.defaultProps){var c=r.defaultProps;for(u in c)t[u]===void 0&&(t[u]=c[u])}if(i||w){var f=typeof r=="function"?r.displayName||r.name||"Unknown":r;i&&an(t,f),w&&dn(t,f)}return sn(r,i,w,a,o,M.current,t)}}var tr=I.ReactCurrentOwner,Sr=I.ReactDebugCurrentFrame;function L(r){if(r){var n=r._owner,e=q(r.type,r._source,n?n.type:null);Sr.setExtraStackFrame(e)}else Sr.setExtraStackFrame(null)}var ar;ar=!1;function dr(r){return typeof r=="object"&&r!==null&&r.$$typeof===g}function Or(){{if(tr.current){var r=S(tr.current.type);if(r)return` | ||
*/var lr;function Nr(){return lr||(lr=1,process.env.NODE_ENV!=="production"&&function(){var v=m,w=Symbol.for("react.element"),R=Symbol.for("react.portal"),y=Symbol.for("react.fragment"),_=Symbol.for("react.strict_mode"),P=Symbol.for("react.profiler"),F=Symbol.for("react.provider"),C=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),I=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),j=Symbol.for("react.memo"),l=Symbol.for("react.lazy"),T=Symbol.for("react.offscreen"),V=Symbol.iterator,Z="@@iterator";function B(r){if(r===null||typeof r!="object")return null;var n=V&&r[V]||r[Z];return typeof n=="function"?n:null}var D=v.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function g(r){{for(var n=arguments.length,e=new Array(n>1?n-1:0),o=1;o<n;o++)e[o-1]=arguments[o];Q("error",r,e)}}function Q(r,n,e){{var o=D.ReactDebugCurrentFrame,a=o.getStackAddendum();a!==""&&(n+="%s",e=e.concat([a]));var s=e.map(function(t){return String(t)});s.unshift("Warning: "+n),Function.prototype.apply.call(console[r],console,s)}}var d=!1,x=!1,$=!1,k=!1,rr=!1,pr;pr=Symbol.for("react.module.reference");function Br(r){return!!(typeof r=="string"||typeof r=="function"||r===y||r===P||rr||r===_||r===I||r===c||k||r===T||d||x||$||typeof r=="object"&&r!==null&&(r.$$typeof===l||r.$$typeof===j||r.$$typeof===F||r.$$typeof===C||r.$$typeof===h||r.$$typeof===pr||r.getModuleId!==void 0))}function $r(r,n,e){var o=r.displayName;if(o)return o;var a=n.displayName||n.name||"";return a!==""?e+"("+a+")":e}function hr(r){return r.displayName||"Context"}function S(r){if(r==null)return null;if(typeof r.tag=="number"&&g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case y:return"Fragment";case R:return"Portal";case P:return"Profiler";case _:return"StrictMode";case I:return"Suspense";case c:return"SuspenseList"}if(typeof r=="object")switch(r.$$typeof){case C:var n=r;return hr(n)+".Consumer";case F:var e=r;return hr(e._context)+".Provider";case h:return $r(r,r.render,"ForwardRef");case j:var o=r.displayName||null;return o!==null?o:S(r.type)||"Memo";case l:{var a=r,s=a._payload,t=a._init;try{return S(t(s))}catch{return null}}}return null}var W=Object.assign,M=0,vr,gr,wr,br,mr,yr,xr;function Er(){}Er.__reactDisabledLog=!0;function Jr(){{if(M===0){vr=console.log,gr=console.info,wr=console.warn,br=console.error,mr=console.group,yr=console.groupCollapsed,xr=console.groupEnd;var r={configurable:!0,enumerable:!0,value:Er,writable:!0};Object.defineProperties(console,{info:r,log:r,warn:r,error:r,group:r,groupCollapsed:r,groupEnd:r})}M++}}function Gr(){{if(M--,M===0){var r={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:W({},r,{value:vr}),info:W({},r,{value:gr}),warn:W({},r,{value:wr}),error:W({},r,{value:br}),group:W({},r,{value:mr}),groupCollapsed:W({},r,{value:yr}),groupEnd:W({},r,{value:xr})})}M<0&&g("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var nr=D.ReactCurrentDispatcher,er;function J(r,n,e){{if(er===void 0)try{throw Error()}catch(a){var o=a.stack.trim().match(/\n( *(at )?)/);er=o&&o[1]||""}return` | ||
`+er+r}}var or=!1,G;{var qr=typeof WeakMap=="function"?WeakMap:Map;G=new qr}function Rr(r,n){if(!r||or)return"";{var e=G.get(r);if(e!==void 0)return e}var o;or=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var s;s=nr.current,nr.current=null,Jr();try{if(n){var t=function(){throw Error()};if(Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(O){o=O}Reflect.construct(r,[],t)}else{try{t.call()}catch(O){o=O}r.call(t.prototype)}}else{try{throw Error()}catch(O){o=O}r()}}catch(O){if(O&&o&&typeof O.stack=="string"){for(var i=O.stack.split(` | ||
`),b=o.stack.split(` | ||
`),f=i.length-1,p=b.length-1;f>=1&&p>=0&&i[f]!==b[p];)p--;for(;f>=1&&p>=0;f--,p--)if(i[f]!==b[p]){if(f!==1||p!==1)do if(f--,p--,p<0||i[f]!==b[p]){var E=` | ||
`+i[f].replace(" at new "," at ");return r.displayName&&E.includes("<anonymous>")&&(E=E.replace("<anonymous>",r.displayName)),typeof r=="function"&&G.set(r,E),E}while(f>=1&&p>=0);break}}}finally{or=!1,nr.current=s,Gr(),Error.prepareStackTrace=a}var N=r?r.displayName||r.name:"",Wr=N?J(N):"";return typeof r=="function"&&G.set(r,Wr),Wr}function Kr(r,n,e){return Rr(r,!1)}function Hr(r){var n=r.prototype;return!!(n&&n.isReactComponent)}function q(r,n,e){if(r==null)return"";if(typeof r=="function")return Rr(r,Hr(r));if(typeof r=="string")return J(r);switch(r){case I:return J("Suspense");case c:return J("SuspenseList")}if(typeof r=="object")switch(r.$$typeof){case h:return Kr(r.render);case j:return q(r.type,n,e);case l:{var o=r,a=o._payload,s=o._init;try{return q(s(a),n,e)}catch{}}}return""}var K=Object.prototype.hasOwnProperty,_r={},jr=D.ReactDebugCurrentFrame;function H(r){if(r){var n=r._owner,e=q(r.type,r._source,n?n.type:null);jr.setExtraStackFrame(e)}else jr.setExtraStackFrame(null)}function Xr(r,n,e,o,a){{var s=Function.call.bind(K);for(var t in r)if(s(r,t)){var i=void 0;try{if(typeof r[t]!="function"){var b=Error((o||"React class")+": "+e+" type `"+t+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof r[t]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw b.name="Invariant Violation",b}i=r[t](n,t,o,e,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(f){i=f}i&&!(i instanceof Error)&&(H(a),g("%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).",o||"React class",e,t,typeof i),H(null)),i instanceof Error&&!(i.message in _r)&&(_r[i.message]=!0,H(a),g("Failed %s type: %s",e,i.message),H(null))}}}var Zr=Array.isArray;function ir(r){return Zr(r)}function Qr(r){{var n=typeof Symbol=="function"&&Symbol.toStringTag,e=n&&r[Symbol.toStringTag]||r.constructor.name||"Object";return e}}function rn(r){try{return Cr(r),!1}catch{return!0}}function Cr(r){return""+r}function Tr(r){if(rn(r))return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Qr(r)),Cr(r)}var U=D.ReactCurrentOwner,nn={key:!0,ref:!0,__self:!0,__source:!0},kr,Sr,tr;tr={};function en(r){if(K.call(r,"ref")){var n=Object.getOwnPropertyDescriptor(r,"ref").get;if(n&&n.isReactWarning)return!1}return r.ref!==void 0}function on(r){if(K.call(r,"key")){var n=Object.getOwnPropertyDescriptor(r,"key").get;if(n&&n.isReactWarning)return!1}return r.key!==void 0}function tn(r,n){if(typeof r.ref=="string"&&U.current&&n&&U.current.stateNode!==n){var e=S(U.current.type);tr[e]||(g('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',S(U.current.type),r.ref),tr[e]=!0)}}function an(r,n){{var e=function(){kr||(kr=!0,g("%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))};e.isReactWarning=!0,Object.defineProperty(r,"key",{get:e,configurable:!0})}}function dn(r,n){{var e=function(){Sr||(Sr=!0,g("%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))};e.isReactWarning=!0,Object.defineProperty(r,"ref",{get:e,configurable:!0})}}var sn=function(r,n,e,o,a,s,t){var i={$$typeof:w,type:r,key:n,ref:e,props:t,_owner:s};return i._store={},Object.defineProperty(i._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(i,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(i,"_source",{configurable:!1,enumerable:!1,writable:!1,value:a}),Object.freeze&&(Object.freeze(i.props),Object.freeze(i)),i};function un(r,n,e,o,a){{var s,t={},i=null,b=null;e!==void 0&&(Tr(e),i=""+e),on(n)&&(Tr(n.key),i=""+n.key),en(n)&&(b=n.ref,tn(n,a));for(s in n)K.call(n,s)&&!nn.hasOwnProperty(s)&&(t[s]=n[s]);if(r&&r.defaultProps){var f=r.defaultProps;for(s in f)t[s]===void 0&&(t[s]=f[s])}if(i||b){var p=typeof r=="function"?r.displayName||r.name||"Unknown":r;i&&an(t,p),b&&dn(t,p)}return sn(r,i,b,a,o,U.current,t)}}var ar=D.ReactCurrentOwner,Or=D.ReactDebugCurrentFrame;function L(r){if(r){var n=r._owner,e=q(r.type,r._source,n?n.type:null);Or.setExtraStackFrame(e)}else Or.setExtraStackFrame(null)}var dr;dr=!1;function sr(r){return typeof r=="object"&&r!==null&&r.$$typeof===w}function Pr(){{if(ar.current){var r=S(ar.current.type);if(r)return` | ||
Check the render method of \``+r+"`."}return""}}function ln(r){{if(r!==void 0){var n=r.fileName.replace(/^.*[\\\/]/,""),e=r.lineNumber;return` | ||
Check your code at `+n+":"+e+"."}return""}}var Pr={};function cn(r){{var n=Or();if(!n){var e=typeof r=="string"?r:r.displayName||r.name;e&&(n=` | ||
Check your code at `+n+":"+e+"."}return""}}var Fr={};function cn(r){{var n=Pr();if(!n){var e=typeof r=="string"?r:r.displayName||r.name;e&&(n=` | ||
Check the top-level render call using <`+e+">.")}return n}}function Fr(r,n){{if(!r._store||r._store.validated||r.key!=null)return;r._store.validated=!0;var e=cn(n);if(Pr[e])return;Pr[e]=!0;var o="";r&&r._owner&&r._owner!==tr.current&&(o=" It was passed a child from "+S(r._owner.type)+"."),L(r),v('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',e,o),L(null)}}function Ir(r,n){{if(typeof r!="object")return;if(or(r))for(var e=0;e<r.length;e++){var o=r[e];dr(o)&&Fr(o,n)}else if(dr(r))r._store&&(r._store.validated=!0);else if(r){var a=Z(r);if(typeof a=="function"&&a!==r.entries)for(var u=a.call(r),t;!(t=u.next()).done;)dr(t.value)&&Fr(t.value,n)}}}function fn(r){{var n=r.type;if(n==null||typeof n=="string")return;var e;if(typeof n=="function")e=n.propTypes;else if(typeof n=="object"&&(n.$$typeof===p||n.$$typeof===d))e=n.propTypes;else return;if(e){var o=S(n);Xr(e,r.props,"prop",o,r)}else if(n.PropTypes!==void 0&&!ar){ar=!0;var a=S(n);v("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",a||"Unknown")}typeof n.getDefaultProps=="function"&&!n.getDefaultProps.isReactClassApproved&&v("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pn(r){{for(var n=Object.keys(r.props),e=0;e<n.length;e++){var o=n[e];if(o!=="children"&&o!=="key"){L(r),v("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",o),L(null);break}}r.ref!==null&&(L(r),v("Invalid attribute `ref` supplied to `React.Fragment`."),L(null))}}function Dr(r,n,e,o,a,u){{var t=Br(r);if(!t){var i="";(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.");var w=ln(a);w?i+=w:i+=Or();var c;r===null?c="null":or(r)?c="array":r!==void 0&&r.$$typeof===g?(c="<"+(S(r.type)||"Unknown")+" />",i=" Did you accidentally export a JSX literal instead of a component?"):c=typeof r,v("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",c,i)}var f=un(r,n,e,a,u);if(f==null)return f;if(t){var _=n.children;if(_!==void 0)if(o)if(or(_)){for(var N=0;N<_.length;N++)Ir(_[N],r);Object.freeze&&Object.freeze(_)}else v("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Ir(_,r)}return r===y?pn(f):fn(f),f}}function hn(r,n,e){return Dr(r,n,e,!0)}function vn(r,n,e){return Dr(r,n,e,!1)}var gn=vn,bn=hn;z.Fragment=y,z.jsx=gn,z.jsxs=bn}()),z}process.env.NODE_ENV==="production"?X.exports=Wr():X.exports=Lr();var l=X.exports;const Nr=`@import url("https://fonts.googleapis.com/css2?family=Poppins&display=swap"); | ||
Check the top-level render call using <`+e+">.")}return n}}function Ir(r,n){{if(!r._store||r._store.validated||r.key!=null)return;r._store.validated=!0;var e=cn(n);if(Fr[e])return;Fr[e]=!0;var o="";r&&r._owner&&r._owner!==ar.current&&(o=" It was passed a child from "+S(r._owner.type)+"."),L(r),g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',e,o),L(null)}}function Dr(r,n){{if(typeof r!="object")return;if(ir(r))for(var e=0;e<r.length;e++){var o=r[e];sr(o)&&Ir(o,n)}else if(sr(r))r._store&&(r._store.validated=!0);else if(r){var a=B(r);if(typeof a=="function"&&a!==r.entries)for(var s=a.call(r),t;!(t=s.next()).done;)sr(t.value)&&Ir(t.value,n)}}}function fn(r){{var n=r.type;if(n==null||typeof n=="string")return;var e;if(typeof n=="function")e=n.propTypes;else if(typeof n=="object"&&(n.$$typeof===h||n.$$typeof===j))e=n.propTypes;else return;if(e){var o=S(n);Xr(e,r.props,"prop",o,r)}else if(n.PropTypes!==void 0&&!dr){dr=!0;var a=S(n);g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",a||"Unknown")}typeof n.getDefaultProps=="function"&&!n.getDefaultProps.isReactClassApproved&&g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pn(r){{for(var n=Object.keys(r.props),e=0;e<n.length;e++){var o=n[e];if(o!=="children"&&o!=="key"){L(r),g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",o),L(null);break}}r.ref!==null&&(L(r),g("Invalid attribute `ref` supplied to `React.Fragment`."),L(null))}}function Ar(r,n,e,o,a,s){{var t=Br(r);if(!t){var i="";(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.");var b=ln(a);b?i+=b:i+=Pr();var f;r===null?f="null":ir(r)?f="array":r!==void 0&&r.$$typeof===w?(f="<"+(S(r.type)||"Unknown")+" />",i=" Did you accidentally export a JSX literal instead of a component?"):f=typeof r,g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",f,i)}var p=un(r,n,e,a,s);if(p==null)return p;if(t){var E=n.children;if(E!==void 0)if(o)if(ir(E)){for(var N=0;N<E.length;N++)Dr(E[N],r);Object.freeze&&Object.freeze(E)}else g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Dr(E,r)}return r===y?pn(p):fn(p),p}}function hn(r,n,e){return Ar(r,n,e,!0)}function vn(r,n,e){return Ar(r,n,e,!1)}var gn=vn,wn=hn;z.Fragment=y,z.jsx=gn,z.jsxs=wn}()),z}process.env.NODE_ENV==="production"?X.exports=Lr():X.exports=Nr();var u=X.exports;const Yr=`@import url("https://fonts.googleapis.com/css2?family=Poppins&display=swap"); | ||
* { | ||
@@ -80,2 +80,4 @@ margin: 0; | ||
--hsd-ui-dropdown-color-secondary-red: var(--hsd-ui-color-red-500, #ef4444); | ||
/* plachoder color */ | ||
@@ -148,2 +150,6 @@ --hsd-ui-dropdown-placholder-color: #d0d6dd; | ||
} | ||
.hsd-input-dropdown-container.error { | ||
border-color: var(--hsd-ui-dropdown-color-secondary-red) !important; | ||
} | ||
.hsd-input-dropdown-container.active { | ||
@@ -258,2 +264,2 @@ border-color: var(--hsd-ui-dropdown-border-color-primary); | ||
} | ||
`;function Yr(h){const[g,j]=m.useState(h),y=m.useRef(null),C=P=>{y.current&&!y.current.contains(P.target)&&j(!1)};return m.useEffect(()=>(document.addEventListener("click",C,!0),()=>{document.removeEventListener("click",C,!0)}),[]),{ref:y,isComponentVisible:g,setIsComponentVisible:j}}const lr="hudoro-input-dropdown-styles";(h=>{if(!document.getElementById(lr)){const g=document.createElement("style");g.id=lr,g.textContent=h,document.head.appendChild(g)}})(Nr);const zr=({dropdownLists:h,onChange:g,defaultValue:j,size:y="md",multiSelect:C,searchAble:P,iconLeft:F,placeholder:T,onSearch:p})=>{const[x,b]=m.useState([]),[d,R]=m.useState([]),{isComponentVisible:A,ref:U,setIsComponentVisible:B}=Yr(!1),Z=()=>{B(s=>!s)},I=(s,E)=>{if(!C)R([{label:s,value:E}]),g([{label:s,value:E}]),B(!1);else if(d==null?void 0:d.find(k=>k.value===E)){const k=[...d?d.filter(Q=>Q.value!==E):[]];R(k),g(k)}else{const k=[...d||[],{label:s,value:E}];R(k),g(k)}};m.useEffect(()=>{j&&(R(j),b(j))},[j]);const v=()=>d.length?C?d==null?void 0:d.map((s,E)=>l.jsx("p",{style:{minWidth:"max-content"},className:"hsd-input-dropdown-preview-item",children:s==null?void 0:s.label},E)):l.jsx("p",{style:{minWidth:"max-content"},children:d==null?void 0:d[0].label}):x.length?C?x==null?void 0:x.map((s,E)=>l.jsx("p",{style:{minWidth:"max-content"},className:"hsd-input-dropdown-preview-item",children:s==null?void 0:s.label},E)):l.jsx("p",{style:{minWidth:"max-content"},children:x==null?void 0:x[0].label}):l.jsx("p",{className:"hsd-input-dropdown-placeholder",children:T||"Search"});return l.jsxs("div",{className:`hsd-input-dropdown-container hsd-input-dropdown-size-${y} ${A?"active":""}`,ref:U,onClick:Z,children:[l.jsxs("div",{className:"hsd-input-dropdown-preview-container",children:[F?l.jsx(l.Fragment,{children:m.cloneElement(F,{width:cr(y),color:"#939E99"})}):null,l.jsx("div",{className:"hsd-input-dropdown-container-preview-item",children:v()}),l.jsx(Mr,{strokeWidth:2,width:cr(y)})]}),A?l.jsxs("div",{className:"hsd-input-dropdown-lists-container",onClick:s=>s.stopPropagation(),children:[P?l.jsxs("div",{className:"hsd-input-dropdown-container-dropdown-search",children:[l.jsx("div",{style:{display:"flex"},children:l.jsx(Vr,{strokeWidth:2,width:20})}),l.jsx("input",{onChange:s=>{p&&p(s.target.value)}})]}):null,l.jsx("div",{className:"hsd-input-dropdwon-item-container",children:h.map((s,E)=>l.jsxs("div",{className:`hsd-input-dropdwon-item ${d!=null&&d.find($=>$.value===s.value)?"active":""} ${s.disable?"hsd-input-dropdwon-item-disable":null}`,onClick:()=>I(s.label,s.value),children:[s.icon?l.jsx("div",{children:m.cloneElement(s.icon,{width:16})}):null,l.jsxs("div",{children:[" ",l.jsx("p",{children:s.label})]})]},E))})]}):null]})},Vr=({...h})=>l.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",...h,viewBox:"0 0 20 20",fill:"none",children:[l.jsx("circle",{cx:"9.80547",cy:"9.8055",r:"7.49047",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round"}),l.jsx("path",{d:"M15.0153 15.4043L17.9519 18.3333",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round"})]}),Mr=({...h})=>l.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",...h,viewBox:"0 0 24 24",fill:"none",color:"#1976D2",children:l.jsx("path",{d:"M4 9L12 17L20 9",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})}),cr=h=>{if(h==="sm")return 16;if(h==="md")return 20;if(h==="lg")return 20};D.Dropdown=zr,Object.defineProperty(D,Symbol.toStringTag,{value:"Module"})}); | ||
`;function zr(v){const[w,R]=m.useState(v),y=m.useRef(null),_=P=>{y.current&&!y.current.contains(P.target)&&R(!1)};return m.useEffect(()=>(document.addEventListener("click",_,!0),()=>{document.removeEventListener("click",_,!0)}),[]),{ref:y,isComponentVisible:w,setIsComponentVisible:R}}const cr="hudoro-input-dropdown-styles";(v=>{if(!document.getElementById(cr)){const w=document.createElement("style");w.id=cr,w.textContent=v,document.head.appendChild(w)}})(Yr);const Vr=({dropdownLists:v,onChange:w,defaultValue:R,size:y="md",multiSelect:_,searchAble:P,iconLeft:F,placeholder:C,onSearch:h,error:I})=>{const[c,j]=m.useState([]),[l,T]=m.useState([]),{isComponentVisible:V,ref:Z,setIsComponentVisible:B}=zr(!1),D=()=>{B(d=>!d)},g=(d,x)=>{if(!_)T([{label:d,value:x}]),w([{label:d,value:x}]),B(!1);else if(l==null?void 0:l.find(k=>k.value===x)){const k=[...l?l.filter(rr=>rr.value!==x):[]];T(k),w(k)}else{const k=[...l||[],{label:d,value:x}];T(k),w(k)}};m.useEffect(()=>{R&&(T(R),j(R))},[R]);const Q=()=>l.length?_?l==null?void 0:l.map((d,x)=>u.jsx("p",{style:{minWidth:"max-content"},className:"hsd-input-dropdown-preview-item",children:d==null?void 0:d.label},x)):u.jsx("p",{style:{minWidth:"max-content"},children:l==null?void 0:l[0].label}):c.length?_?c==null?void 0:c.map((d,x)=>u.jsx("p",{style:{minWidth:"max-content"},className:"hsd-input-dropdown-preview-item",children:d==null?void 0:d.label},x)):u.jsx("p",{style:{minWidth:"max-content"},children:c==null?void 0:c[0].label}):u.jsx("p",{className:"hsd-input-dropdown-placeholder",children:C||"Search"});return u.jsxs("div",{className:`hsd-input-dropdown-container hsd-input-dropdown-size-${y} ${V?"active":""} ${I?"error":""}`,ref:Z,onClick:D,children:[u.jsxs("div",{className:"hsd-input-dropdown-preview-container",children:[F?u.jsx(u.Fragment,{children:m.cloneElement(F,{width:fr(y),color:"#939E99"})}):null,u.jsx("div",{className:"hsd-input-dropdown-container-preview-item",children:Q()}),u.jsx(Ur,{strokeWidth:2,width:fr(y)})]}),V?u.jsxs("div",{className:"hsd-input-dropdown-lists-container",onClick:d=>d.stopPropagation(),children:[P?u.jsxs("div",{className:"hsd-input-dropdown-container-dropdown-search",children:[u.jsx("div",{style:{display:"flex"},children:u.jsx(Mr,{strokeWidth:2,width:20})}),u.jsx("input",{onChange:d=>{h&&h(d.target.value)}})]}):null,u.jsx("div",{className:"hsd-input-dropdwon-item-container",children:v.map((d,x)=>u.jsxs("div",{className:`hsd-input-dropdwon-item ${l!=null&&l.find($=>$.value===d.value)?"active":""} ${d.disable?"hsd-input-dropdwon-item-disable":null}`,onClick:()=>g(d.label,d.value),children:[d.icon?u.jsx("div",{children:m.cloneElement(d.icon,{width:16})}):null,u.jsxs("div",{children:[" ",u.jsx("p",{children:d.label})]})]},x))})]}):null]})},Mr=({...v})=>u.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",...v,viewBox:"0 0 20 20",fill:"none",children:[u.jsx("circle",{cx:"9.80547",cy:"9.8055",r:"7.49047",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round"}),u.jsx("path",{d:"M15.0153 15.4043L17.9519 18.3333",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round",strokeLinejoin:"round"})]}),Ur=({...v})=>u.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",...v,viewBox:"0 0 24 24",fill:"none",color:"#1976D2",children:u.jsx("path",{d:"M4 9L12 17L20 9",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})}),fr=v=>{if(v==="sm")return 16;if(v==="md")return 20;if(v==="lg")return 20};A.Dropdown=Vr,Object.defineProperty(A,Symbol.toStringTag,{value:"Module"})}); |
@@ -19,2 +19,3 @@ export interface IconPropsDropdown extends React.SVGProps<SVGSVGElement> { | ||
size?: "sm" | "md" | "lg"; | ||
error?: boolean; | ||
multiSelect?: boolean; | ||
@@ -21,0 +22,0 @@ searchAble?: boolean; |
{ | ||
"name": "@hudoro/dropdown", | ||
"version": "0.0.3-beta.28", | ||
"version": "0.0.3-beta.29", | ||
"description": "dropdown component for Hudoro UI", | ||
@@ -5,0 +5,0 @@ "author": "Prawito Hudoro", |
64870
1344