/") + "/"), R$1(c, b, e, "", function(a2) {
return a2;
})) : null != c && (O$1(c) && (c = N$1(c, e + (!c.key || h && h.key === c.key ? "" : ("" + c.key).replace(P$2, "/") + "/") + a)), b.push(c)), 1;
h = 0;
d = "" === d ? "." : d + ":";
if (I$1(a)) for (var g = 0; g < a.length; g++) {
k2 = a[g];
var f2 = d + Q$1(k2, g);
h += R$1(k2, b, e, f2, c);
}
else if (f2 = A$1(a), "function" === typeof f2) for (a = f2.call(a), g = 0; !(k2 = a.next()).done; ) k2 = k2.value, f2 = d + Q$1(k2, g++), h += R$1(k2, b, e, f2, c);
else if ("object" === k2) throw b = String(a), Error("Objects are not valid as a React child (found: " + ("[object Object]" === b ? "object with keys {" + Object.keys(a).join(", ") + "}" : b) + "). If you meant to render a collection of children, use an array instead.");
return h;
}
function S$1(a, b, e) {
if (null == a) return a;
var d = [], c = 0;
R$1(a, d, "", "", function(a2) {
return b.call(e, a2, c++);
});
return d;
}
function T$1(a) {
if (-1 === a._status) {
var b = a._result;
b = b();
b.then(function(b2) {
if (0 === a._status || -1 === a._status) a._status = 1, a._result = b2;
}, function(b2) {
if (0 === a._status || -1 === a._status) a._status = 2, a._result = b2;
});
-1 === a._status && (a._status = 0, a._result = b);
}
if (1 === a._status) return a._result.default;
throw a._result;
}
var U$1 = { current: null }, V$1 = { transition: null }, W$1 = { ReactCurrentDispatcher: U$1, ReactCurrentBatchConfig: V$1, ReactCurrentOwner: K$1 };
function X$2() {
throw Error("act(...) is not supported in production builds of React.");
}
react_production_min.Children = { map: S$1, forEach: function(a, b, e) {
S$1(a, function() {
b.apply(this, arguments);
}, e);
}, count: function(a) {
var b = 0;
S$1(a, function() {
b++;
});
return b;
}, toArray: function(a) {
return S$1(a, function(a2) {
return a2;
}) || [];
}, only: function(a) {
if (!O$1(a)) throw Error("React.Children.only expected to receive a single React element child.");
return a;
} };
react_production_min.Component = E$2;
react_production_min.Fragment = p$2;
react_production_min.Profiler = r$1;
react_production_min.PureComponent = G$1;
react_production_min.StrictMode = q$1;
react_production_min.Suspense = w;
react_production_min.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = W$1;
react_production_min.act = X$2;
react_production_min.cloneElement = function(a, b, e) {
if (null === a || void 0 === a) throw Error("React.cloneElement(...): The argument must be a React element, but you passed " + a + ".");
var d = C$1({}, a.props), c = a.key, k2 = a.ref, h = a._owner;
if (null != b) {
void 0 !== b.ref && (k2 = b.ref, h = K$1.current);
void 0 !== b.key && (c = "" + b.key);
if (a.type && a.type.defaultProps) var g = a.type.defaultProps;
for (f2 in b) J.call(b, f2) && !L$2.hasOwnProperty(f2) && (d[f2] = void 0 === b[f2] && void 0 !== g ? g[f2] : b[f2]);
}
var f2 = arguments.length - 2;
if (1 === f2) d.children = e;
else if (1 < f2) {
g = Array(f2);
for (var m2 = 0; m2 < f2; m2++) g[m2] = arguments[m2 + 2];
d.children = g;
}
return { $typeof: l$1, type: a.type, key: c, ref: k2, props: d, _owner: h };
};
react_production_min.createContext = function(a) {
a = { $typeof: u, _currentValue: a, _currentValue2: a, _threadCount: 0, Provider: null, Consumer: null, _defaultValue: null, _globalName: null };
a.Provider = { $typeof: t, _context: a };
return a.Consumer = a;
};
react_production_min.createElement = M$2;
react_production_min.createFactory = function(a) {
var b = M$2.bind(null, a);
b.type = a;
return b;
};
react_production_min.createRef = function() {
return { current: null };
};
react_production_min.forwardRef = function(a) {
return { $typeof: v$2, render: a };
};
react_production_min.isValidElement = O$1;
react_production_min.lazy = function(a) {
return { $typeof: y, _payload: { _status: -1, _result: a }, _init: T$1 };
};
react_production_min.memo = function(a, b) {
return { $typeof: x, type: a, compare: void 0 === b ? null : b };
};
react_production_min.startTransition = function(a) {
var b = V$1.transition;
V$1.transition = {};
try {
a();
} finally {
V$1.transition = b;
}
};
react_production_min.unstable_act = X$2;
react_production_min.useCallback = function(a, b) {
return U$1.current.useCallback(a, b);
};
react_production_min.useContext = function(a) {
return U$1.current.useContext(a);
};
react_production_min.useDebugValue = function() {
};
react_production_min.useDeferredValue = function(a) {
return U$1.current.useDeferredValue(a);
};
react_production_min.useEffect = function(a, b) {
return U$1.current.useEffect(a, b);
};
react_production_min.useId = function() {
return U$1.current.useId();
};
react_production_min.useImperativeHandle = function(a, b, e) {
return U$1.current.useImperativeHandle(a, b, e);
};
react_production_min.useInsertionEffect = function(a, b) {
return U$1.current.useInsertionEffect(a, b);
};
react_production_min.useLayoutEffect = function(a, b) {
return U$1.current.useLayoutEffect(a, b);
};
react_production_min.useMemo = function(a, b) {
return U$1.current.useMemo(a, b);
};
react_production_min.useReducer = function(a, b, e) {
return U$1.current.useReducer(a, b, e);
};
react_production_min.useRef = function(a) {
return U$1.current.useRef(a);
};
react_production_min.useState = function(a) {
return U$1.current.useState(a);
};
react_production_min.useSyncExternalStore = function(a, b, e) {
return U$1.current.useSyncExternalStore(a, b, e);
};
react_production_min.useTransition = function() {
return U$1.current.useTransition();
};
react_production_min.version = "18.3.1";
{
react.exports = react_production_min;
}
var reactExports = react.exports;
const React2 = /* @__PURE__ */ getDefaultExportFromCjs(reactExports);
const React = /* @__PURE__ */ _mergeNamespaces({
__proto__: null,
default: React2
}, [reactExports]);
/**
* @license React
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
var f = reactExports, k = Symbol.for("react.element"), l = Symbol.for("react.fragment"), m$1 = Object.prototype.hasOwnProperty, n = f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, p$1 = { key: true, ref: true, __self: true, __source: true };
function q(c, a, g) {
var b, d = {}, e = null, h = null;
void 0 !== g && (e = "" + g);
void 0 !== a.key && (e = "" + a.key);
void 0 !== a.ref && (h = a.ref);
for (b in a) m$1.call(a, b) && !p$1.hasOwnProperty(b) && (d[b] = a[b]);
if (c && c.defaultProps) for (b in a = c.defaultProps, a) void 0 === d[b] && (d[b] = a[b]);
return { $typeof: k, type: c, key: e, ref: h, props: d, _owner: n.current };
}
reactJsxRuntime_production_min.Fragment = l;
reactJsxRuntime_production_min.jsx = q;
reactJsxRuntime_production_min.jsxs = q;
{
jsxRuntime.exports = reactJsxRuntime_production_min;
}
var jsxRuntimeExports = jsxRuntime.exports;
var reactDom = { exports: {} };
var reactDom_production_min = {};
var scheduler = { exports: {} };
var scheduler_production_min = {};
/**
* @license React
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
(function(exports) {
function f2(a, b) {
var c = a.length;
a.push(b);
a: for (; 0 < c; ) {
var d = c - 1 >>> 1, e = a[d];
if (0 < g(e, b)) a[d] = b, a[c] = e, c = d;
else break a;
}
}
function h(a) {
return 0 === a.length ? null : a[0];
}
function k2(a) {
if (0 === a.length) return null;
var b = a[0], c = a.pop();
if (c !== b) {
a[0] = c;
a: for (var d = 0, e = a.length, w2 = e >>> 1; d < w2; ) {
var m2 = 2 * (d + 1) - 1, C2 = a[m2], n2 = m2 + 1, x2 = a[n2];
if (0 > g(C2, c)) n2 < e && 0 > g(x2, C2) ? (a[d] = x2, a[n2] = c, d = n2) : (a[d] = C2, a[m2] = c, d = m2);
else if (n2 < e && 0 > g(x2, c)) a[d] = x2, a[n2] = c, d = n2;
else break a;
}
}
return b;
}
function g(a, b) {
var c = a.sortIndex - b.sortIndex;
return 0 !== c ? c : a.id - b.id;
}
if ("object" === typeof performance && "function" === typeof performance.now) {
var l2 = performance;
exports.unstable_now = function() {
return l2.now();
};
} else {
var p2 = Date, q2 = p2.now();
exports.unstable_now = function() {
return p2.now() - q2;
};
}
var r2 = [], t2 = [], u2 = 1, v2 = null, y2 = 3, z2 = false, A2 = false, B2 = false, D2 = "function" === typeof setTimeout ? setTimeout : null, E2 = "function" === typeof clearTimeout ? clearTimeout : null, F2 = "undefined" !== typeof setImmediate ? setImmediate : null;
"undefined" !== typeof navigator && void 0 !== navigator.scheduling && void 0 !== navigator.scheduling.isInputPending && navigator.scheduling.isInputPending.bind(navigator.scheduling);
function G2(a) {
for (var b = h(t2); null !== b; ) {
if (null === b.callback) k2(t2);
else if (b.startTime <= a) k2(t2), b.sortIndex = b.expirationTime, f2(r2, b);
else break;
b = h(t2);
}
}
function H2(a) {
B2 = false;
G2(a);
if (!A2) if (null !== h(r2)) A2 = true, I2(J2);
else {
var b = h(t2);
null !== b && K2(H2, b.startTime - a);
}
}
function J2(a, b) {
A2 = false;
B2 && (B2 = false, E2(L2), L2 = -1);
z2 = true;
var c = y2;
try {
G2(b);
for (v2 = h(r2); null !== v2 && (!(v2.expirationTime > b) || a && !M2()); ) {
var d = v2.callback;
if ("function" === typeof d) {
v2.callback = null;
y2 = v2.priorityLevel;
var e = d(v2.expirationTime <= b);
b = exports.unstable_now();
"function" === typeof e ? v2.callback = e : v2 === h(r2) && k2(r2);
G2(b);
} else k2(r2);
v2 = h(r2);
}
if (null !== v2) var w2 = true;
else {
var m2 = h(t2);
null !== m2 && K2(H2, m2.startTime - b);
w2 = false;
}
return w2;
} finally {
v2 = null, y2 = c, z2 = false;
}
}
var N2 = false, O2 = null, L2 = -1, P2 = 5, Q2 = -1;
function M2() {
return exports.unstable_now() - Q2 < P2 ? false : true;
}
function R2() {
if (null !== O2) {
var a = exports.unstable_now();
Q2 = a;
var b = true;
try {
b = O2(true, a);
} finally {
b ? S2() : (N2 = false, O2 = null);
}
} else N2 = false;
}
var S2;
if ("function" === typeof F2) S2 = function() {
F2(R2);
};
else if ("undefined" !== typeof MessageChannel) {
var T2 = new MessageChannel(), U2 = T2.port2;
T2.port1.onmessage = R2;
S2 = function() {
U2.postMessage(null);
};
} else S2 = function() {
D2(R2, 0);
};
function I2(a) {
O2 = a;
N2 || (N2 = true, S2());
}
function K2(a, b) {
L2 = D2(function() {
a(exports.unstable_now());
}, b);
}
exports.unstable_IdlePriority = 5;
exports.unstable_ImmediatePriority = 1;
exports.unstable_LowPriority = 4;
exports.unstable_NormalPriority = 3;
exports.unstable_Profiling = null;
exports.unstable_UserBlockingPriority = 2;
exports.unstable_cancelCallback = function(a) {
a.callback = null;
};
exports.unstable_continueExecution = function() {
A2 || z2 || (A2 = true, I2(J2));
};
exports.unstable_forceFrameRate = function(a) {
0 > a || 125 < a ? console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported") : P2 = 0 < a ? Math.floor(1e3 / a) : 5;
};
exports.unstable_getCurrentPriorityLevel = function() {
return y2;
};
exports.unstable_getFirstCallbackNode = function() {
return h(r2);
};
exports.unstable_next = function(a) {
switch (y2) {
case 1:
case 2:
case 3:
var b = 3;
break;
default:
b = y2;
}
var c = y2;
y2 = b;
try {
return a();
} finally {
y2 = c;
}
};
exports.unstable_pauseExecution = function() {
};
exports.unstable_requestPaint = function() {
};
exports.unstable_runWithPriority = function(a, b) {
switch (a) {
case 1:
case 2:
case 3:
case 4:
case 5:
break;
default:
a = 3;
}
var c = y2;
y2 = a;
try {
return b();
} finally {
y2 = c;
}
};
exports.unstable_scheduleCallback = function(a, b, c) {
var d = exports.unstable_now();
"object" === typeof c && null !== c ? (c = c.delay, c = "number" === typeof c && 0 < c ? d + c : d) : c = d;
switch (a) {
case 1:
var e = -1;
break;
case 2:
e = 250;
break;
case 5:
e = 1073741823;
break;
case 4:
e = 1e4;
break;
default:
e = 5e3;
}
e = c + e;
a = { id: u2++, callback: b, priorityLevel: a, startTime: c, expirationTime: e, sortIndex: -1 };
c > d ? (a.sortIndex = c, f2(t2, a), null === h(r2) && a === h(t2) && (B2 ? (E2(L2), L2 = -1) : B2 = true, K2(H2, c - d))) : (a.sortIndex = e, f2(r2, a), A2 || z2 || (A2 = true, I2(J2)));
return a;
};
exports.unstable_shouldYield = M2;
exports.unstable_wrapCallback = function(a) {
var b = y2;
return function() {
var c = y2;
y2 = b;
try {
return a.apply(this, arguments);
} finally {
y2 = c;
}
};
};
})(scheduler_production_min);
{
scheduler.exports = scheduler_production_min;
}
var schedulerExports = scheduler.exports;
/**
* @license React
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
var aa = reactExports, ca = schedulerExports;
function p(a) {
for (var b = "https://reactjs.org/docs/error-decoder.html?invariant=" + a, c = 1; c < arguments.length; c++) b += "&args[]=" + encodeURIComponent(arguments[c]);
return "Minified React error #" + a + "; visit " + b + " for the full message or use the non-minified dev environment for full errors and additional helpful warnings.";
}
var da = /* @__PURE__ */ new Set(), ea = {};
function fa(a, b) {
ha(a, b);
ha(a + "Capture", b);
}
function ha(a, b) {
ea[a] = b;
for (a = 0; a < b.length; a++) da.add(b[a]);
}
var ia = !("undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement), ja = Object.prototype.hasOwnProperty, ka = /^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/, la = {}, ma = {};
function oa(a) {
if (ja.call(ma, a)) return true;
if (ja.call(la, a)) return false;
if (ka.test(a)) return ma[a] = true;
la[a] = true;
return false;
}
function pa(a, b, c, d) {
if (null !== c && 0 === c.type) return false;
switch (typeof b) {
case "function":
case "symbol":
return true;
case "boolean":
if (d) return false;
if (null !== c) return !c.acceptsBooleans;
a = a.toLowerCase().slice(0, 5);
return "data-" !== a && "aria-" !== a;
default:
return false;
}
}
function qa(a, b, c, d) {
if (null === b || "undefined" === typeof b || pa(a, b, c, d)) return true;
if (d) return false;
if (null !== c) switch (c.type) {
case 3:
return !b;
case 4:
return false === b;
case 5:
return isNaN(b);
case 6:
return isNaN(b) || 1 > b;
}
return false;
}
function v$1(a, b, c, d, e, f2, g) {
this.acceptsBooleans = 2 === b || 3 === b || 4 === b;
this.attributeName = d;
this.attributeNamespace = e;
this.mustUseProperty = c;
this.propertyName = a;
this.type = b;
this.sanitizeURL = f2;
this.removeEmptyString = g;
}
var z = {};
"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(a) {
z[a] = new v$1(a, 0, false, a, null, false, false);
});
[["acceptCharset", "accept-charset"], ["className", "class"], ["htmlFor", "for"], ["httpEquiv", "http-equiv"]].forEach(function(a) {
var b = a[0];
z[b] = new v$1(b, 1, false, a[1], null, false, false);
});
["contentEditable", "draggable", "spellCheck", "value"].forEach(function(a) {
z[a] = new v$1(a, 2, false, a.toLowerCase(), null, false, false);
});
["autoReverse", "externalResourcesRequired", "focusable", "preserveAlpha"].forEach(function(a) {
z[a] = new v$1(a, 2, false, a, null, false, false);
});
"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(a) {
z[a] = new v$1(a, 3, false, a.toLowerCase(), null, false, false);
});
["checked", "multiple", "muted", "selected"].forEach(function(a) {
z[a] = new v$1(a, 3, true, a, null, false, false);
});
["capture", "download"].forEach(function(a) {
z[a] = new v$1(a, 4, false, a, null, false, false);
});
["cols", "rows", "size", "span"].forEach(function(a) {
z[a] = new v$1(a, 6, false, a, null, false, false);
});
["rowSpan", "start"].forEach(function(a) {
z[a] = new v$1(a, 5, false, a.toLowerCase(), null, false, false);
});
var ra = /[\-:]([a-z])/g;
function sa(a) {
return a[1].toUpperCase();
}
"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(a) {
var b = a.replace(
ra,
sa
);
z[b] = new v$1(b, 1, false, a, null, false, false);
});
"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(a) {
var b = a.replace(ra, sa);
z[b] = new v$1(b, 1, false, a, "http://www.w3.org/1999/xlink", false, false);
});
["xml:base", "xml:lang", "xml:space"].forEach(function(a) {
var b = a.replace(ra, sa);
z[b] = new v$1(b, 1, false, a, "http://www.w3.org/XML/1998/namespace", false, false);
});
["tabIndex", "crossOrigin"].forEach(function(a) {
z[a] = new v$1(a, 1, false, a.toLowerCase(), null, false, false);
});
z.xlinkHref = new v$1("xlinkHref", 1, false, "xlink:href", "http://www.w3.org/1999/xlink", true, false);
["src", "href", "action", "formAction"].forEach(function(a) {
z[a] = new v$1(a, 1, false, a.toLowerCase(), null, true, true);
});
function ta(a, b, c, d) {
var e = z.hasOwnProperty(b) ? z[b] : null;
if (null !== e ? 0 !== e.type : d || !(2 < b.length) || "o" !== b[0] && "O" !== b[0] || "n" !== b[1] && "N" !== b[1]) qa(b, c, e, d) && (c = null), d || null === e ? oa(b) && (null === c ? a.removeAttribute(b) : a.setAttribute(b, "" + c)) : e.mustUseProperty ? a[e.propertyName] = null === c ? 3 === e.type ? false : "" : c : (b = e.attributeName, d = e.attributeNamespace, null === c ? a.removeAttribute(b) : (e = e.type, c = 3 === e || 4 === e && true === c ? "" : "" + c, d ? a.setAttributeNS(d, b, c) : a.setAttribute(b, c)));
}
var ua = aa.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED, va = Symbol.for("react.element"), wa = Symbol.for("react.portal"), ya = Symbol.for("react.fragment"), za = Symbol.for("react.strict_mode"), Aa = Symbol.for("react.profiler"), Ba = Symbol.for("react.provider"), Ca = Symbol.for("react.context"), Da = Symbol.for("react.forward_ref"), Ea = Symbol.for("react.suspense"), Fa = Symbol.for("react.suspense_list"), Ga = Symbol.for("react.memo"), Ha = Symbol.for("react.lazy");
var Ia = Symbol.for("react.offscreen");
var Ja = Symbol.iterator;
function Ka(a) {
if (null === a || "object" !== typeof a) return null;
a = Ja && a[Ja] || a["@@iterator"];
return "function" === typeof a ? a : null;
}
var A = Object.assign, La;
function Ma(a) {
if (void 0 === La) try {
throw Error();
} catch (c) {
var b = c.stack.trim().match(/\n( *(at )?)/);
La = b && b[1] || "";
}
return "\n" + La + a;
}
var Na = false;
function Oa(a, b) {
if (!a || Na) return "";
Na = true;
var c = Error.prepareStackTrace;
Error.prepareStackTrace = void 0;
try {
if (b) if (b = function() {
throw Error();
}, Object.defineProperty(b.prototype, "props", { set: function() {
throw Error();
} }), "object" === typeof Reflect && Reflect.construct) {
try {
Reflect.construct(b, []);
} catch (l2) {
var d = l2;
}
Reflect.construct(a, [], b);
} else {
try {
b.call();
} catch (l2) {
d = l2;
}
a.call(b.prototype);
}
else {
try {
throw Error();
} catch (l2) {
d = l2;
}
a();
}
} catch (l2) {
if (l2 && d && "string" === typeof l2.stack) {
for (var e = l2.stack.split("\n"), f2 = d.stack.split("\n"), g = e.length - 1, h = f2.length - 1; 1 <= g && 0 <= h && e[g] !== f2[h]; ) h--;
for (; 1 <= g && 0 <= h; g--, h--) if (e[g] !== f2[h]) {
if (1 !== g || 1 !== h) {
do
if (g--, h--, 0 > h || e[g] !== f2[h]) {
var k2 = "\n" + e[g].replace(" at new ", " at ");
a.displayName && k2.includes("") && (k2 = k2.replace("", a.displayName));
return k2;
}
while (1 <= g && 0 <= h);
}
break;
}
}
} finally {
Na = false, Error.prepareStackTrace = c;
}
return (a = a ? a.displayName || a.name : "") ? Ma(a) : "";
}
function Pa(a) {
switch (a.tag) {
case 5:
return Ma(a.type);
case 16:
return Ma("Lazy");
case 13:
return Ma("Suspense");
case 19:
return Ma("SuspenseList");
case 0:
case 2:
case 15:
return a = Oa(a.type, false), a;
case 11:
return a = Oa(a.type.render, false), a;
case 1:
return a = Oa(a.type, true), a;
default:
return "";
}
}
function Qa(a) {
if (null == a) return null;
if ("function" === typeof a) return a.displayName || a.name || null;
if ("string" === typeof a) return a;
switch (a) {
case ya:
return "Fragment";
case wa:
return "Portal";
case Aa:
return "Profiler";
case za:
return "StrictMode";
case Ea:
return "Suspense";
case Fa:
return "SuspenseList";
}
if ("object" === typeof a) switch (a.$typeof) {
case Ca:
return (a.displayName || "Context") + ".Consumer";
case Ba:
return (a._context.displayName || "Context") + ".Provider";
case Da:
var b = a.render;
a = a.displayName;
a || (a = b.displayName || b.name || "", a = "" !== a ? "ForwardRef(" + a + ")" : "ForwardRef");
return a;
case Ga:
return b = a.displayName || null, null !== b ? b : Qa(a.type) || "Memo";
case Ha:
b = a._payload;
a = a._init;
try {
return Qa(a(b));
} catch (c) {
}
}
return null;
}
function Ra(a) {
var b = a.type;
switch (a.tag) {
case 24:
return "Cache";
case 9:
return (b.displayName || "Context") + ".Consumer";
case 10:
return (b._context.displayName || "Context") + ".Provider";
case 18:
return "DehydratedFragment";
case 11:
return a = b.render, a = a.displayName || a.name || "", b.displayName || ("" !== a ? "ForwardRef(" + a + ")" : "ForwardRef");
case 7:
return "Fragment";
case 5:
return b;
case 4:
return "Portal";
case 3:
return "Root";
case 6:
return "Text";
case 16:
return Qa(b);
case 8:
return b === za ? "StrictMode" : "Mode";
case 22:
return "Offscreen";
case 12:
return "Profiler";
case 21:
return "Scope";
case 13:
return "Suspense";
case 19:
return "SuspenseList";
case 25:
return "TracingMarker";
case 1:
case 0:
case 17:
case 2:
case 14:
case 15:
if ("function" === typeof b) return b.displayName || b.name || null;
if ("string" === typeof b) return b;
}
return null;
}
function Sa(a) {
switch (typeof a) {
case "boolean":
case "number":
case "string":
case "undefined":
return a;
case "object":
return a;
default:
return "";
}
}
function Ta(a) {
var b = a.type;
return (a = a.nodeName) && "input" === a.toLowerCase() && ("checkbox" === b || "radio" === b);
}
function Ua(a) {
var b = Ta(a) ? "checked" : "value", c = Object.getOwnPropertyDescriptor(a.constructor.prototype, b), d = "" + a[b];
if (!a.hasOwnProperty(b) && "undefined" !== typeof c && "function" === typeof c.get && "function" === typeof c.set) {
var e = c.get, f2 = c.set;
Object.defineProperty(a, b, { configurable: true, get: function() {
return e.call(this);
}, set: function(a2) {
d = "" + a2;
f2.call(this, a2);
} });
Object.defineProperty(a, b, { enumerable: c.enumerable });
return { getValue: function() {
return d;
}, setValue: function(a2) {
d = "" + a2;
}, stopTracking: function() {
a._valueTracker = null;
delete a[b];
} };
}
}
function Va(a) {
a._valueTracker || (a._valueTracker = Ua(a));
}
function Wa(a) {
if (!a) return false;
var b = a._valueTracker;
if (!b) return true;
var c = b.getValue();
var d = "";
a && (d = Ta(a) ? a.checked ? "true" : "false" : a.value);
a = d;
return a !== c ? (b.setValue(a), true) : false;
}
function Xa(a) {
a = a || ("undefined" !== typeof document ? document : void 0);
if ("undefined" === typeof a) return null;
try {
return a.activeElement || a.body;
} catch (b) {
return a.body;
}
}
function Ya(a, b) {
var c = b.checked;
return A({}, b, { defaultChecked: void 0, defaultValue: void 0, value: void 0, checked: null != c ? c : a._wrapperState.initialChecked });
}
function Za(a, b) {
var c = null == b.defaultValue ? "" : b.defaultValue, d = null != b.checked ? b.checked : b.defaultChecked;
c = Sa(null != b.value ? b.value : c);
a._wrapperState = { initialChecked: d, initialValue: c, controlled: "checkbox" === b.type || "radio" === b.type ? null != b.checked : null != b.value };
}
function ab(a, b) {
b = b.checked;
null != b && ta(a, "checked", b, false);
}
function bb(a, b) {
ab(a, b);
var c = Sa(b.value), d = b.type;
if (null != c) if ("number" === d) {
if (0 === c && "" === a.value || a.value != c) a.value = "" + c;
} else a.value !== "" + c && (a.value = "" + c);
else if ("submit" === d || "reset" === d) {
a.removeAttribute("value");
return;
}
b.hasOwnProperty("value") ? cb(a, b.type, c) : b.hasOwnProperty("defaultValue") && cb(a, b.type, Sa(b.defaultValue));
null == b.checked && null != b.defaultChecked && (a.defaultChecked = !!b.defaultChecked);
}
function db(a, b, c) {
if (b.hasOwnProperty("value") || b.hasOwnProperty("defaultValue")) {
var d = b.type;
if (!("submit" !== d && "reset" !== d || void 0 !== b.value && null !== b.value)) return;
b = "" + a._wrapperState.initialValue;
c || b === a.value || (a.value = b);
a.defaultValue = b;
}
c = a.name;
"" !== c && (a.name = "");
a.defaultChecked = !!a._wrapperState.initialChecked;
"" !== c && (a.name = c);
}
function cb(a, b, c) {
if ("number" !== b || Xa(a.ownerDocument) !== a) null == c ? a.defaultValue = "" + a._wrapperState.initialValue : a.defaultValue !== "" + c && (a.defaultValue = "" + c);
}
var eb = Array.isArray;
function fb(a, b, c, d) {
a = a.options;
if (b) {
b = {};
for (var e = 0; e < c.length; e++) b["$" + c[e]] = true;
for (c = 0; c < a.length; c++) e = b.hasOwnProperty("$" + a[c].value), a[c].selected !== e && (a[c].selected = e), e && d && (a[c].defaultSelected = true);
} else {
c = "" + Sa(c);
b = null;
for (e = 0; e < a.length; e++) {
if (a[e].value === c) {
a[e].selected = true;
d && (a[e].defaultSelected = true);
return;
}
null !== b || a[e].disabled || (b = a[e]);
}
null !== b && (b.selected = true);
}
}
function gb(a, b) {
if (null != b.dangerouslySetInnerHTML) throw Error(p(91));
return A({}, b, { value: void 0, defaultValue: void 0, children: "" + a._wrapperState.initialValue });
}
function hb(a, b) {
var c = b.value;
if (null == c) {
c = b.children;
b = b.defaultValue;
if (null != c) {
if (null != b) throw Error(p(92));
if (eb(c)) {
if (1 < c.length) throw Error(p(93));
c = c[0];
}
b = c;
}
null == b && (b = "");
c = b;
}
a._wrapperState = { initialValue: Sa(c) };
}
function ib(a, b) {
var c = Sa(b.value), d = Sa(b.defaultValue);
null != c && (c = "" + c, c !== a.value && (a.value = c), null == b.defaultValue && a.defaultValue !== c && (a.defaultValue = c));
null != d && (a.defaultValue = "" + d);
}
function jb(a) {
var b = a.textContent;
b === a._wrapperState.initialValue && "" !== b && null !== b && (a.value = b);
}
function kb(a) {
switch (a) {
case "svg":
return "http://www.w3.org/2000/svg";
case "math":
return "http://www.w3.org/1998/Math/MathML";
default:
return "http://www.w3.org/1999/xhtml";
}
}
function lb(a, b) {
return null == a || "http://www.w3.org/1999/xhtml" === a ? kb(b) : "http://www.w3.org/2000/svg" === a && "foreignObject" === b ? "http://www.w3.org/1999/xhtml" : a;
}
var mb, nb = function(a) {
return "undefined" !== typeof MSApp && MSApp.execUnsafeLocalFunction ? function(b, c, d, e) {
MSApp.execUnsafeLocalFunction(function() {
return a(b, c, d, e);
});
} : a;
}(function(a, b) {
if ("http://www.w3.org/2000/svg" !== a.namespaceURI || "innerHTML" in a) a.innerHTML = b;
else {
mb = mb || document.createElement("div");
mb.innerHTML = "";
for (b = mb.firstChild; a.firstChild; ) a.removeChild(a.firstChild);
for (; b.firstChild; ) a.appendChild(b.firstChild);
}
});
function ob(a, b) {
if (b) {
var c = a.firstChild;
if (c && c === a.lastChild && 3 === c.nodeType) {
c.nodeValue = b;
return;
}
}
a.textContent = b;
}
var pb = {
animationIterationCount: true,
aspectRatio: true,
borderImageOutset: true,
borderImageSlice: true,
borderImageWidth: true,
boxFlex: true,
boxFlexGroup: true,
boxOrdinalGroup: true,
columnCount: true,
columns: true,
flex: true,
flexGrow: true,
flexPositive: true,
flexShrink: true,
flexNegative: true,
flexOrder: true,
gridArea: true,
gridRow: true,
gridRowEnd: true,
gridRowSpan: true,
gridRowStart: true,
gridColumn: true,
gridColumnEnd: true,
gridColumnSpan: true,
gridColumnStart: true,
fontWeight: true,
lineClamp: true,
lineHeight: true,
opacity: true,
order: true,
orphans: true,
tabSize: true,
widows: true,
zIndex: true,
zoom: true,
fillOpacity: true,
floodOpacity: true,
stopOpacity: true,
strokeDasharray: true,
strokeDashoffset: true,
strokeMiterlimit: true,
strokeOpacity: true,
strokeWidth: true
}, qb = ["Webkit", "ms", "Moz", "O"];
Object.keys(pb).forEach(function(a) {
qb.forEach(function(b) {
b = b + a.charAt(0).toUpperCase() + a.substring(1);
pb[b] = pb[a];
});
});
function rb(a, b, c) {
return null == b || "boolean" === typeof b || "" === b ? "" : c || "number" !== typeof b || 0 === b || pb.hasOwnProperty(a) && pb[a] ? ("" + b).trim() : b + "px";
}
function sb(a, b) {
a = a.style;
for (var c in b) if (b.hasOwnProperty(c)) {
var d = 0 === c.indexOf("--"), e = rb(c, b[c], d);
"float" === c && (c = "cssFloat");
d ? a.setProperty(c, e) : a[c] = e;
}
}
var tb = A({ menuitem: true }, { area: true, base: true, br: true, col: true, embed: true, hr: true, img: true, input: true, keygen: true, link: true, meta: true, param: true, source: true, track: true, wbr: true });
function ub(a, b) {
if (b) {
if (tb[a] && (null != b.children || null != b.dangerouslySetInnerHTML)) throw Error(p(137, a));
if (null != b.dangerouslySetInnerHTML) {
if (null != b.children) throw Error(p(60));
if ("object" !== typeof b.dangerouslySetInnerHTML || !("__html" in b.dangerouslySetInnerHTML)) throw Error(p(61));
}
if (null != b.style && "object" !== typeof b.style) throw Error(p(62));
}
}
function vb(a, b) {
if (-1 === a.indexOf("-")) return "string" === typeof b.is;
switch (a) {
case "annotation-xml":
case "color-profile":
case "font-face":
case "font-face-src":
case "font-face-uri":
case "font-face-format":
case "font-face-name":
case "missing-glyph":
return false;
default:
return true;
}
}
var wb = null;
function xb(a) {
a = a.target || a.srcElement || window;
a.correspondingUseElement && (a = a.correspondingUseElement);
return 3 === a.nodeType ? a.parentNode : a;
}
var yb = null, zb = null, Ab = null;
function Bb(a) {
if (a = Cb(a)) {
if ("function" !== typeof yb) throw Error(p(280));
var b = a.stateNode;
b && (b = Db(b), yb(a.stateNode, a.type, b));
}
}
function Eb(a) {
zb ? Ab ? Ab.push(a) : Ab = [a] : zb = a;
}
function Fb() {
if (zb) {
var a = zb, b = Ab;
Ab = zb = null;
Bb(a);
if (b) for (a = 0; a < b.length; a++) Bb(b[a]);
}
}
function Gb(a, b) {
return a(b);
}
function Hb() {
}
var Ib = false;
function Jb(a, b, c) {
if (Ib) return a(b, c);
Ib = true;
try {
return Gb(a, b, c);
} finally {
if (Ib = false, null !== zb || null !== Ab) Hb(), Fb();
}
}
function Kb(a, b) {
var c = a.stateNode;
if (null === c) return null;
var d = Db(c);
if (null === d) return null;
c = d[b];
a: switch (b) {
case "onClick":
case "onClickCapture":
case "onDoubleClick":
case "onDoubleClickCapture":
case "onMouseDown":
case "onMouseDownCapture":
case "onMouseMove":
case "onMouseMoveCapture":
case "onMouseUp":
case "onMouseUpCapture":
case "onMouseEnter":
(d = !d.disabled) || (a = a.type, d = !("button" === a || "input" === a || "select" === a || "textarea" === a));
a = !d;
break a;
default:
a = false;
}
if (a) return null;
if (c && "function" !== typeof c) throw Error(p(231, b, typeof c));
return c;
}
var Lb = false;
if (ia) try {
var Mb = {};
Object.defineProperty(Mb, "passive", { get: function() {
Lb = true;
} });
window.addEventListener("test", Mb, Mb);
window.removeEventListener("test", Mb, Mb);
} catch (a) {
Lb = false;
}
function Nb(a, b, c, d, e, f2, g, h, k2) {
var l2 = Array.prototype.slice.call(arguments, 3);
try {
b.apply(c, l2);
} catch (m2) {
this.onError(m2);
}
}
var Ob = false, Pb = null, Qb = false, Rb = null, Sb = { onError: function(a) {
Ob = true;
Pb = a;
} };
function Tb(a, b, c, d, e, f2, g, h, k2) {
Ob = false;
Pb = null;
Nb.apply(Sb, arguments);
}
function Ub(a, b, c, d, e, f2, g, h, k2) {
Tb.apply(this, arguments);
if (Ob) {
if (Ob) {
var l2 = Pb;
Ob = false;
Pb = null;
} else throw Error(p(198));
Qb || (Qb = true, Rb = l2);
}
}
function Vb(a) {
var b = a, c = a;
if (a.alternate) for (; b.return; ) b = b.return;
else {
a = b;
do
b = a, 0 !== (b.flags & 4098) && (c = b.return), a = b.return;
while (a);
}
return 3 === b.tag ? c : null;
}
function Wb(a) {
if (13 === a.tag) {
var b = a.memoizedState;
null === b && (a = a.alternate, null !== a && (b = a.memoizedState));
if (null !== b) return b.dehydrated;
}
return null;
}
function Xb(a) {
if (Vb(a) !== a) throw Error(p(188));
}
function Yb(a) {
var b = a.alternate;
if (!b) {
b = Vb(a);
if (null === b) throw Error(p(188));
return b !== a ? null : a;
}
for (var c = a, d = b; ; ) {
var e = c.return;
if (null === e) break;
var f2 = e.alternate;
if (null === f2) {
d = e.return;
if (null !== d) {
c = d;
continue;
}
break;
}
if (e.child === f2.child) {
for (f2 = e.child; f2; ) {
if (f2 === c) return Xb(e), a;
if (f2 === d) return Xb(e), b;
f2 = f2.sibling;
}
throw Error(p(188));
}
if (c.return !== d.return) c = e, d = f2;
else {
for (var g = false, h = e.child; h; ) {
if (h === c) {
g = true;
c = e;
d = f2;
break;
}
if (h === d) {
g = true;
d = e;
c = f2;
break;
}
h = h.sibling;
}
if (!g) {
for (h = f2.child; h; ) {
if (h === c) {
g = true;
c = f2;
d = e;
break;
}
if (h === d) {
g = true;
d = f2;
c = e;
break;
}
h = h.sibling;
}
if (!g) throw Error(p(189));
}
}
if (c.alternate !== d) throw Error(p(190));
}
if (3 !== c.tag) throw Error(p(188));
return c.stateNode.current === c ? a : b;
}
function Zb(a) {
a = Yb(a);
return null !== a ? $b(a) : null;
}
function $b(a) {
if (5 === a.tag || 6 === a.tag) return a;
for (a = a.child; null !== a; ) {
var b = $b(a);
if (null !== b) return b;
a = a.sibling;
}
return null;
}
var ac = ca.unstable_scheduleCallback, bc = ca.unstable_cancelCallback, cc = ca.unstable_shouldYield, dc = ca.unstable_requestPaint, B = ca.unstable_now, ec = ca.unstable_getCurrentPriorityLevel, fc = ca.unstable_ImmediatePriority, gc = ca.unstable_UserBlockingPriority, hc = ca.unstable_NormalPriority, ic = ca.unstable_LowPriority, jc = ca.unstable_IdlePriority, kc = null, lc = null;
function mc(a) {
if (lc && "function" === typeof lc.onCommitFiberRoot) try {
lc.onCommitFiberRoot(kc, a, void 0, 128 === (a.current.flags & 128));
} catch (b) {
}
}
var oc = Math.clz32 ? Math.clz32 : nc, pc = Math.log, qc = Math.LN2;
function nc(a) {
a >>>= 0;
return 0 === a ? 32 : 31 - (pc(a) / qc | 0) | 0;
}
var rc = 64, sc = 4194304;
function tc(a) {
switch (a & -a) {
case 1:
return 1;
case 2:
return 2;
case 4:
return 4;
case 8:
return 8;
case 16:
return 16;
case 32:
return 32;
case 64:
case 128:
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
return a & 4194240;
case 4194304:
case 8388608:
case 16777216:
case 33554432:
case 67108864:
return a & 130023424;
case 134217728:
return 134217728;
case 268435456:
return 268435456;
case 536870912:
return 536870912;
case 1073741824:
return 1073741824;
default:
return a;
}
}
function uc(a, b) {
var c = a.pendingLanes;
if (0 === c) return 0;
var d = 0, e = a.suspendedLanes, f2 = a.pingedLanes, g = c & 268435455;
if (0 !== g) {
var h = g & ~e;
0 !== h ? d = tc(h) : (f2 &= g, 0 !== f2 && (d = tc(f2)));
} else g = c & ~e, 0 !== g ? d = tc(g) : 0 !== f2 && (d = tc(f2));
if (0 === d) return 0;
if (0 !== b && b !== d && 0 === (b & e) && (e = d & -d, f2 = b & -b, e >= f2 || 16 === e && 0 !== (f2 & 4194240))) return b;
0 !== (d & 4) && (d |= c & 16);
b = a.entangledLanes;
if (0 !== b) for (a = a.entanglements, b &= d; 0 < b; ) c = 31 - oc(b), e = 1 << c, d |= a[c], b &= ~e;
return d;
}
function vc(a, b) {
switch (a) {
case 1:
case 2:
case 4:
return b + 250;
case 8:
case 16:
case 32:
case 64:
case 128:
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
return b + 5e3;
case 4194304:
case 8388608:
case 16777216:
case 33554432:
case 67108864:
return -1;
case 134217728:
case 268435456:
case 536870912:
case 1073741824:
return -1;
default:
return -1;
}
}
function wc(a, b) {
for (var c = a.suspendedLanes, d = a.pingedLanes, e = a.expirationTimes, f2 = a.pendingLanes; 0 < f2; ) {
var g = 31 - oc(f2), h = 1 << g, k2 = e[g];
if (-1 === k2) {
if (0 === (h & c) || 0 !== (h & d)) e[g] = vc(h, b);
} else k2 <= b && (a.expiredLanes |= h);
f2 &= ~h;
}
}
function xc(a) {
a = a.pendingLanes & -1073741825;
return 0 !== a ? a : a & 1073741824 ? 1073741824 : 0;
}
function yc() {
var a = rc;
rc <<= 1;
0 === (rc & 4194240) && (rc = 64);
return a;
}
function zc(a) {
for (var b = [], c = 0; 31 > c; c++) b.push(a);
return b;
}
function Ac(a, b, c) {
a.pendingLanes |= b;
536870912 !== b && (a.suspendedLanes = 0, a.pingedLanes = 0);
a = a.eventTimes;
b = 31 - oc(b);
a[b] = c;
}
function Bc(a, b) {
var c = a.pendingLanes & ~b;
a.pendingLanes = b;
a.suspendedLanes = 0;
a.pingedLanes = 0;
a.expiredLanes &= b;
a.mutableReadLanes &= b;
a.entangledLanes &= b;
b = a.entanglements;
var d = a.eventTimes;
for (a = a.expirationTimes; 0 < c; ) {
var e = 31 - oc(c), f2 = 1 << e;
b[e] = 0;
d[e] = -1;
a[e] = -1;
c &= ~f2;
}
}
function Cc(a, b) {
var c = a.entangledLanes |= b;
for (a = a.entanglements; c; ) {
var d = 31 - oc(c), e = 1 << d;
e & b | a[d] & b && (a[d] |= b);
c &= ~e;
}
}
var C = 0;
function Dc(a) {
a &= -a;
return 1 < a ? 4 < a ? 0 !== (a & 268435455) ? 16 : 536870912 : 4 : 1;
}
var Ec, Fc, Gc, Hc, Ic, Jc = false, Kc = [], Lc = null, Mc = null, Nc = null, Oc = /* @__PURE__ */ new Map(), Pc = /* @__PURE__ */ new Map(), Qc = [], Rc = "mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");
function Sc(a, b) {
switch (a) {
case "focusin":
case "focusout":
Lc = null;
break;
case "dragenter":
case "dragleave":
Mc = null;
break;
case "mouseover":
case "mouseout":
Nc = null;
break;
case "pointerover":
case "pointerout":
Oc.delete(b.pointerId);
break;
case "gotpointercapture":
case "lostpointercapture":
Pc.delete(b.pointerId);
}
}
function Tc(a, b, c, d, e, f2) {
if (null === a || a.nativeEvent !== f2) return a = { blockedOn: b, domEventName: c, eventSystemFlags: d, nativeEvent: f2, targetContainers: [e] }, null !== b && (b = Cb(b), null !== b && Fc(b)), a;
a.eventSystemFlags |= d;
b = a.targetContainers;
null !== e && -1 === b.indexOf(e) && b.push(e);
return a;
}
function Uc(a, b, c, d, e) {
switch (b) {
case "focusin":
return Lc = Tc(Lc, a, b, c, d, e), true;
case "dragenter":
return Mc = Tc(Mc, a, b, c, d, e), true;
case "mouseover":
return Nc = Tc(Nc, a, b, c, d, e), true;
case "pointerover":
var f2 = e.pointerId;
Oc.set(f2, Tc(Oc.get(f2) || null, a, b, c, d, e));
return true;
case "gotpointercapture":
return f2 = e.pointerId, Pc.set(f2, Tc(Pc.get(f2) || null, a, b, c, d, e)), true;
}
return false;
}
function Vc(a) {
var b = Wc(a.target);
if (null !== b) {
var c = Vb(b);
if (null !== c) {
if (b = c.tag, 13 === b) {
if (b = Wb(c), null !== b) {
a.blockedOn = b;
Ic(a.priority, function() {
Gc(c);
});
return;
}
} else if (3 === b && c.stateNode.current.memoizedState.isDehydrated) {
a.blockedOn = 3 === c.tag ? c.stateNode.containerInfo : null;
return;
}
}
}
a.blockedOn = null;
}
function Xc(a) {
if (null !== a.blockedOn) return false;
for (var b = a.targetContainers; 0 < b.length; ) {
var c = Yc(a.domEventName, a.eventSystemFlags, b[0], a.nativeEvent);
if (null === c) {
c = a.nativeEvent;
var d = new c.constructor(c.type, c);
wb = d;
c.target.dispatchEvent(d);
wb = null;
} else return b = Cb(c), null !== b && Fc(b), a.blockedOn = c, false;
b.shift();
}
return true;
}
function Zc(a, b, c) {
Xc(a) && c.delete(b);
}
function $c() {
Jc = false;
null !== Lc && Xc(Lc) && (Lc = null);
null !== Mc && Xc(Mc) && (Mc = null);
null !== Nc && Xc(Nc) && (Nc = null);
Oc.forEach(Zc);
Pc.forEach(Zc);
}
function ad(a, b) {
a.blockedOn === b && (a.blockedOn = null, Jc || (Jc = true, ca.unstable_scheduleCallback(ca.unstable_NormalPriority, $c)));
}
function bd(a) {
function b(b2) {
return ad(b2, a);
}
if (0 < Kc.length) {
ad(Kc[0], a);
for (var c = 1; c < Kc.length; c++) {
var d = Kc[c];
d.blockedOn === a && (d.blockedOn = null);
}
}
null !== Lc && ad(Lc, a);
null !== Mc && ad(Mc, a);
null !== Nc && ad(Nc, a);
Oc.forEach(b);
Pc.forEach(b);
for (c = 0; c < Qc.length; c++) d = Qc[c], d.blockedOn === a && (d.blockedOn = null);
for (; 0 < Qc.length && (c = Qc[0], null === c.blockedOn); ) Vc(c), null === c.blockedOn && Qc.shift();
}
var cd = ua.ReactCurrentBatchConfig, dd = true;
function ed(a, b, c, d) {
var e = C, f2 = cd.transition;
cd.transition = null;
try {
C = 1, fd(a, b, c, d);
} finally {
C = e, cd.transition = f2;
}
}
function gd(a, b, c, d) {
var e = C, f2 = cd.transition;
cd.transition = null;
try {
C = 4, fd(a, b, c, d);
} finally {
C = e, cd.transition = f2;
}
}
function fd(a, b, c, d) {
if (dd) {
var e = Yc(a, b, c, d);
if (null === e) hd(a, b, d, id, c), Sc(a, d);
else if (Uc(e, a, b, c, d)) d.stopPropagation();
else if (Sc(a, d), b & 4 && -1 < Rc.indexOf(a)) {
for (; null !== e; ) {
var f2 = Cb(e);
null !== f2 && Ec(f2);
f2 = Yc(a, b, c, d);
null === f2 && hd(a, b, d, id, c);
if (f2 === e) break;
e = f2;
}
null !== e && d.stopPropagation();
} else hd(a, b, d, null, c);
}
}
var id = null;
function Yc(a, b, c, d) {
id = null;
a = xb(d);
a = Wc(a);
if (null !== a) if (b = Vb(a), null === b) a = null;
else if (c = b.tag, 13 === c) {
a = Wb(b);
if (null !== a) return a;
a = null;
} else if (3 === c) {
if (b.stateNode.current.memoizedState.isDehydrated) return 3 === b.tag ? b.stateNode.containerInfo : null;
a = null;
} else b !== a && (a = null);
id = a;
return null;
}
function jd(a) {
switch (a) {
case "cancel":
case "click":
case "close":
case "contextmenu":
case "copy":
case "cut":
case "auxclick":
case "dblclick":
case "dragend":
case "dragstart":
case "drop":
case "focusin":
case "focusout":
case "input":
case "invalid":
case "keydown":
case "keypress":
case "keyup":
case "mousedown":
case "mouseup":
case "paste":
case "pause":
case "play":
case "pointercancel":
case "pointerdown":
case "pointerup":
case "ratechange":
case "reset":
case "resize":
case "seeked":
case "submit":
case "touchcancel":
case "touchend":
case "touchstart":
case "volumechange":
case "change":
case "selectionchange":
case "textInput":
case "compositionstart":
case "compositionend":
case "compositionupdate":
case "beforeblur":
case "afterblur":
case "beforeinput":
case "blur":
case "fullscreenchange":
case "focus":
case "hashchange":
case "popstate":
case "select":
case "selectstart":
return 1;
case "drag":
case "dragenter":
case "dragexit":
case "dragleave":
case "dragover":
case "mousemove":
case "mouseout":
case "mouseover":
case "pointermove":
case "pointerout":
case "pointerover":
case "scroll":
case "toggle":
case "touchmove":
case "wheel":
case "mouseenter":
case "mouseleave":
case "pointerenter":
case "pointerleave":
return 4;
case "message":
switch (ec()) {
case fc:
return 1;
case gc:
return 4;
case hc:
case ic:
return 16;
case jc:
return 536870912;
default:
return 16;
}
default:
return 16;
}
}
var kd = null, ld = null, md = null;
function nd() {
if (md) return md;
var a, b = ld, c = b.length, d, e = "value" in kd ? kd.value : kd.textContent, f2 = e.length;
for (a = 0; a < c && b[a] === e[a]; a++) ;
var g = c - a;
for (d = 1; d <= g && b[c - d] === e[f2 - d]; d++) ;
return md = e.slice(a, 1 < d ? 1 - d : void 0);
}
function od(a) {
var b = a.keyCode;
"charCode" in a ? (a = a.charCode, 0 === a && 13 === b && (a = 13)) : a = b;
10 === a && (a = 13);
return 32 <= a || 13 === a ? a : 0;
}
function pd() {
return true;
}
function qd() {
return false;
}
function rd(a) {
function b(b2, d, e, f2, g) {
this._reactName = b2;
this._targetInst = e;
this.type = d;
this.nativeEvent = f2;
this.target = g;
this.currentTarget = null;
for (var c in a) a.hasOwnProperty(c) && (b2 = a[c], this[c] = b2 ? b2(f2) : f2[c]);
this.isDefaultPrevented = (null != f2.defaultPrevented ? f2.defaultPrevented : false === f2.returnValue) ? pd : qd;
this.isPropagationStopped = qd;
return this;
}
A(b.prototype, { preventDefault: function() {
this.defaultPrevented = true;
var a2 = this.nativeEvent;
a2 && (a2.preventDefault ? a2.preventDefault() : "unknown" !== typeof a2.returnValue && (a2.returnValue = false), this.isDefaultPrevented = pd);
}, stopPropagation: function() {
var a2 = this.nativeEvent;
a2 && (a2.stopPropagation ? a2.stopPropagation() : "unknown" !== typeof a2.cancelBubble && (a2.cancelBubble = true), this.isPropagationStopped = pd);
}, persist: function() {
}, isPersistent: pd });
return b;
}
var sd = { eventPhase: 0, bubbles: 0, cancelable: 0, timeStamp: function(a) {
return a.timeStamp || Date.now();
}, defaultPrevented: 0, isTrusted: 0 }, td = rd(sd), ud = A({}, sd, { view: 0, detail: 0 }), vd = rd(ud), wd, xd, yd, Ad = A({}, ud, { screenX: 0, screenY: 0, clientX: 0, clientY: 0, pageX: 0, pageY: 0, ctrlKey: 0, shiftKey: 0, altKey: 0, metaKey: 0, getModifierState: zd, button: 0, buttons: 0, relatedTarget: function(a) {
return void 0 === a.relatedTarget ? a.fromElement === a.srcElement ? a.toElement : a.fromElement : a.relatedTarget;
}, movementX: function(a) {
if ("movementX" in a) return a.movementX;
a !== yd && (yd && "mousemove" === a.type ? (wd = a.screenX - yd.screenX, xd = a.screenY - yd.screenY) : xd = wd = 0, yd = a);
return wd;
}, movementY: function(a) {
return "movementY" in a ? a.movementY : xd;
} }), Bd = rd(Ad), Cd = A({}, Ad, { dataTransfer: 0 }), Dd = rd(Cd), Ed = A({}, ud, { relatedTarget: 0 }), Fd = rd(Ed), Gd = A({}, sd, { animationName: 0, elapsedTime: 0, pseudoElement: 0 }), Hd = rd(Gd), Id = A({}, sd, { clipboardData: function(a) {
return "clipboardData" in a ? a.clipboardData : window.clipboardData;
} }), Jd = rd(Id), Kd = A({}, sd, { data: 0 }), Ld = rd(Kd), Md = {
Esc: "Escape",
Spacebar: " ",
Left: "ArrowLeft",
Up: "ArrowUp",
Right: "ArrowRight",
Down: "ArrowDown",
Del: "Delete",
Win: "OS",
Menu: "ContextMenu",
Apps: "ContextMenu",
Scroll: "ScrollLock",
MozPrintableKey: "Unidentified"
}, Nd = {
8: "Backspace",
9: "Tab",
12: "Clear",
13: "Enter",
16: "Shift",
17: "Control",
18: "Alt",
19: "Pause",
20: "CapsLock",
27: "Escape",
32: " ",
33: "PageUp",
34: "PageDown",
35: "End",
36: "Home",
37: "ArrowLeft",
38: "ArrowUp",
39: "ArrowRight",
40: "ArrowDown",
45: "Insert",
46: "Delete",
112: "F1",
113: "F2",
114: "F3",
115: "F4",
116: "F5",
117: "F6",
118: "F7",
119: "F8",
120: "F9",
121: "F10",
122: "F11",
123: "F12",
144: "NumLock",
145: "ScrollLock",
224: "Meta"
}, Od = { Alt: "altKey", Control: "ctrlKey", Meta: "metaKey", Shift: "shiftKey" };
function Pd(a) {
var b = this.nativeEvent;
return b.getModifierState ? b.getModifierState(a) : (a = Od[a]) ? !!b[a] : false;
}
function zd() {
return Pd;
}
var Qd = A({}, ud, { key: function(a) {
if (a.key) {
var b = Md[a.key] || a.key;
if ("Unidentified" !== b) return b;
}
return "keypress" === a.type ? (a = od(a), 13 === a ? "Enter" : String.fromCharCode(a)) : "keydown" === a.type || "keyup" === a.type ? Nd[a.keyCode] || "Unidentified" : "";
}, code: 0, location: 0, ctrlKey: 0, shiftKey: 0, altKey: 0, metaKey: 0, repeat: 0, locale: 0, getModifierState: zd, charCode: function(a) {
return "keypress" === a.type ? od(a) : 0;
}, keyCode: function(a) {
return "keydown" === a.type || "keyup" === a.type ? a.keyCode : 0;
}, which: function(a) {
return "keypress" === a.type ? od(a) : "keydown" === a.type || "keyup" === a.type ? a.keyCode : 0;
} }), Rd = rd(Qd), Sd = A({}, Ad, { pointerId: 0, width: 0, height: 0, pressure: 0, tangentialPressure: 0, tiltX: 0, tiltY: 0, twist: 0, pointerType: 0, isPrimary: 0 }), Td = rd(Sd), Ud = A({}, ud, { touches: 0, targetTouches: 0, changedTouches: 0, altKey: 0, metaKey: 0, ctrlKey: 0, shiftKey: 0, getModifierState: zd }), Vd = rd(Ud), Wd = A({}, sd, { propertyName: 0, elapsedTime: 0, pseudoElement: 0 }), Xd = rd(Wd), Yd = A({}, Ad, {
deltaX: function(a) {
return "deltaX" in a ? a.deltaX : "wheelDeltaX" in a ? -a.wheelDeltaX : 0;
},
deltaY: function(a) {
return "deltaY" in a ? a.deltaY : "wheelDeltaY" in a ? -a.wheelDeltaY : "wheelDelta" in a ? -a.wheelDelta : 0;
},
deltaZ: 0,
deltaMode: 0
}), Zd = rd(Yd), $d = [9, 13, 27, 32], ae$1 = ia && "CompositionEvent" in window, be$1 = null;
ia && "documentMode" in document && (be$1 = document.documentMode);
var ce$1 = ia && "TextEvent" in window && !be$1, de$1 = ia && (!ae$1 || be$1 && 8 < be$1 && 11 >= be$1), ee$1 = String.fromCharCode(32), fe = false;
function ge$1(a, b) {
switch (a) {
case "keyup":
return -1 !== $d.indexOf(b.keyCode);
case "keydown":
return 229 !== b.keyCode;
case "keypress":
case "mousedown":
case "focusout":
return true;
default:
return false;
}
}
function he$1(a) {
a = a.detail;
return "object" === typeof a && "data" in a ? a.data : null;
}
var ie$1 = false;
function je(a, b) {
switch (a) {
case "compositionend":
return he$1(b);
case "keypress":
if (32 !== b.which) return null;
fe = true;
return ee$1;
case "textInput":
return a = b.data, a === ee$1 && fe ? null : a;
default:
return null;
}
}
function ke(a, b) {
if (ie$1) return "compositionend" === a || !ae$1 && ge$1(a, b) ? (a = nd(), md = ld = kd = null, ie$1 = false, a) : null;
switch (a) {
case "paste":
return null;
case "keypress":
if (!(b.ctrlKey || b.altKey || b.metaKey) || b.ctrlKey && b.altKey) {
if (b.char && 1 < b.char.length) return b.char;
if (b.which) return String.fromCharCode(b.which);
}
return null;
case "compositionend":
return de$1 && "ko" !== b.locale ? null : b.data;
default:
return null;
}
}
var le$1 = { color: true, date: true, datetime: true, "datetime-local": true, email: true, month: true, number: true, password: true, range: true, search: true, tel: true, text: true, time: true, url: true, week: true };
function me$1(a) {
var b = a && a.nodeName && a.nodeName.toLowerCase();
return "input" === b ? !!le$1[a.type] : "textarea" === b ? true : false;
}
function ne$1(a, b, c, d) {
Eb(d);
b = oe$1(b, "onChange");
0 < b.length && (c = new td("onChange", "change", null, c, d), a.push({ event: c, listeners: b }));
}
var pe$1 = null, qe = null;
function re(a) {
se$1(a, 0);
}
function te$1(a) {
var b = ue(a);
if (Wa(b)) return a;
}
function ve$1(a, b) {
if ("change" === a) return b;
}
var we$1 = false;
if (ia) {
var xe$1;
if (ia) {
var ye$1 = "oninput" in document;
if (!ye$1) {
var ze = document.createElement("div");
ze.setAttribute("oninput", "return;");
ye$1 = "function" === typeof ze.oninput;
}
xe$1 = ye$1;
} else xe$1 = false;
we$1 = xe$1 && (!document.documentMode || 9 < document.documentMode);
}
function Ae() {
pe$1 && (pe$1.detachEvent("onpropertychange", Be), qe = pe$1 = null);
}
function Be(a) {
if ("value" === a.propertyName && te$1(qe)) {
var b = [];
ne$1(b, qe, a, xb(a));
Jb(re, b);
}
}
function Ce(a, b, c) {
"focusin" === a ? (Ae(), pe$1 = b, qe = c, pe$1.attachEvent("onpropertychange", Be)) : "focusout" === a && Ae();
}
function De(a) {
if ("selectionchange" === a || "keyup" === a || "keydown" === a) return te$1(qe);
}
function Ee(a, b) {
if ("click" === a) return te$1(b);
}
function Fe(a, b) {
if ("input" === a || "change" === a) return te$1(b);
}
function Ge(a, b) {
return a === b && (0 !== a || 1 / a === 1 / b) || a !== a && b !== b;
}
var He = "function" === typeof Object.is ? Object.is : Ge;
function Ie(a, b) {
if (He(a, b)) return true;
if ("object" !== typeof a || null === a || "object" !== typeof b || null === b) return false;
var c = Object.keys(a), d = Object.keys(b);
if (c.length !== d.length) return false;
for (d = 0; d < c.length; d++) {
var e = c[d];
if (!ja.call(b, e) || !He(a[e], b[e])) return false;
}
return true;
}
function Je(a) {
for (; a && a.firstChild; ) a = a.firstChild;
return a;
}
function Ke(a, b) {
var c = Je(a);
a = 0;
for (var d; c; ) {
if (3 === c.nodeType) {
d = a + c.textContent.length;
if (a <= b && d >= b) return { node: c, offset: b - a };
a = d;
}
a: {
for (; c; ) {
if (c.nextSibling) {
c = c.nextSibling;
break a;
}
c = c.parentNode;
}
c = void 0;
}
c = Je(c);
}
}
function Le(a, b) {
return a && b ? a === b ? true : a && 3 === a.nodeType ? false : b && 3 === b.nodeType ? Le(a, b.parentNode) : "contains" in a ? a.contains(b) : a.compareDocumentPosition ? !!(a.compareDocumentPosition(b) & 16) : false : false;
}
function Me() {
for (var a = window, b = Xa(); b instanceof a.HTMLIFrameElement; ) {
try {
var c = "string" === typeof b.contentWindow.location.href;
} catch (d) {
c = false;
}
if (c) a = b.contentWindow;
else break;
b = Xa(a.document);
}
return b;
}
function Ne(a) {
var b = a && a.nodeName && a.nodeName.toLowerCase();
return b && ("input" === b && ("text" === a.type || "search" === a.type || "tel" === a.type || "url" === a.type || "password" === a.type) || "textarea" === b || "true" === a.contentEditable);
}
function Oe(a) {
var b = Me(), c = a.focusedElem, d = a.selectionRange;
if (b !== c && c && c.ownerDocument && Le(c.ownerDocument.documentElement, c)) {
if (null !== d && Ne(c)) {
if (b = d.start, a = d.end, void 0 === a && (a = b), "selectionStart" in c) c.selectionStart = b, c.selectionEnd = Math.min(a, c.value.length);
else if (a = (b = c.ownerDocument || document) && b.defaultView || window, a.getSelection) {
a = a.getSelection();
var e = c.textContent.length, f2 = Math.min(d.start, e);
d = void 0 === d.end ? f2 : Math.min(d.end, e);
!a.extend && f2 > d && (e = d, d = f2, f2 = e);
e = Ke(c, f2);
var g = Ke(
c,
d
);
e && g && (1 !== a.rangeCount || a.anchorNode !== e.node || a.anchorOffset !== e.offset || a.focusNode !== g.node || a.focusOffset !== g.offset) && (b = b.createRange(), b.setStart(e.node, e.offset), a.removeAllRanges(), f2 > d ? (a.addRange(b), a.extend(g.node, g.offset)) : (b.setEnd(g.node, g.offset), a.addRange(b)));
}
}
b = [];
for (a = c; a = a.parentNode; ) 1 === a.nodeType && b.push({ element: a, left: a.scrollLeft, top: a.scrollTop });
"function" === typeof c.focus && c.focus();
for (c = 0; c < b.length; c++) a = b[c], a.element.scrollLeft = a.left, a.element.scrollTop = a.top;
}
}
var Pe = ia && "documentMode" in document && 11 >= document.documentMode, Qe = null, Re = null, Se = null, Te$1 = false;
function Ue(a, b, c) {
var d = c.window === c ? c.document : 9 === c.nodeType ? c : c.ownerDocument;
Te$1 || null == Qe || Qe !== Xa(d) || (d = Qe, "selectionStart" in d && Ne(d) ? d = { start: d.selectionStart, end: d.selectionEnd } : (d = (d.ownerDocument && d.ownerDocument.defaultView || window).getSelection(), d = { anchorNode: d.anchorNode, anchorOffset: d.anchorOffset, focusNode: d.focusNode, focusOffset: d.focusOffset }), Se && Ie(Se, d) || (Se = d, d = oe$1(Re, "onSelect"), 0 < d.length && (b = new td("onSelect", "select", null, b, c), a.push({ event: b, listeners: d }), b.target = Qe)));
}
function Ve(a, b) {
var c = {};
c[a.toLowerCase()] = b.toLowerCase();
c["Webkit" + a] = "webkit" + b;
c["Moz" + a] = "moz" + b;
return c;
}
var We = { animationend: Ve("Animation", "AnimationEnd"), animationiteration: Ve("Animation", "AnimationIteration"), animationstart: Ve("Animation", "AnimationStart"), transitionend: Ve("Transition", "TransitionEnd") }, Xe = {}, Ye = {};
ia && (Ye = document.createElement("div").style, "AnimationEvent" in window || (delete We.animationend.animation, delete We.animationiteration.animation, delete We.animationstart.animation), "TransitionEvent" in window || delete We.transitionend.transition);
function Ze(a) {
if (Xe[a]) return Xe[a];
if (!We[a]) return a;
var b = We[a], c;
for (c in b) if (b.hasOwnProperty(c) && c in Ye) return Xe[a] = b[c];
return a;
}
var $e$1 = Ze("animationend"), af = Ze("animationiteration"), bf = Ze("animationstart"), cf = Ze("transitionend"), df = /* @__PURE__ */ new Map(), ef = "abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");
function ff(a, b) {
df.set(a, b);
fa(b, [a]);
}
for (var gf = 0; gf < ef.length; gf++) {
var hf = ef[gf], jf = hf.toLowerCase(), kf = hf[0].toUpperCase() + hf.slice(1);
ff(jf, "on" + kf);
}
ff($e$1, "onAnimationEnd");
ff(af, "onAnimationIteration");
ff(bf, "onAnimationStart");
ff("dblclick", "onDoubleClick");
ff("focusin", "onFocus");
ff("focusout", "onBlur");
ff(cf, "onTransitionEnd");
ha("onMouseEnter", ["mouseout", "mouseover"]);
ha("onMouseLeave", ["mouseout", "mouseover"]);
ha("onPointerEnter", ["pointerout", "pointerover"]);
ha("onPointerLeave", ["pointerout", "pointerover"]);
fa("onChange", "change click focusin focusout input keydown keyup selectionchange".split(" "));
fa("onSelect", "focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));
fa("onBeforeInput", ["compositionend", "keypress", "textInput", "paste"]);
fa("onCompositionEnd", "compositionend focusout keydown keypress keyup mousedown".split(" "));
fa("onCompositionStart", "compositionstart focusout keydown keypress keyup mousedown".split(" "));
fa("onCompositionUpdate", "compositionupdate focusout keydown keypress keyup mousedown".split(" "));
var lf = "abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "), mf = new Set("cancel close invalid load scroll toggle".split(" ").concat(lf));
function nf(a, b, c) {
var d = a.type || "unknown-event";
a.currentTarget = c;
Ub(d, b, void 0, a);
a.currentTarget = null;
}
function se$1(a, b) {
b = 0 !== (b & 4);
for (var c = 0; c < a.length; c++) {
var d = a[c], e = d.event;
d = d.listeners;
a: {
var f2 = void 0;
if (b) for (var g = d.length - 1; 0 <= g; g--) {
var h = d[g], k2 = h.instance, l2 = h.currentTarget;
h = h.listener;
if (k2 !== f2 && e.isPropagationStopped()) break a;
nf(e, h, l2);
f2 = k2;
}
else for (g = 0; g < d.length; g++) {
h = d[g];
k2 = h.instance;
l2 = h.currentTarget;
h = h.listener;
if (k2 !== f2 && e.isPropagationStopped()) break a;
nf(e, h, l2);
f2 = k2;
}
}
}
if (Qb) throw a = Rb, Qb = false, Rb = null, a;
}
function D$1(a, b) {
var c = b[of];
void 0 === c && (c = b[of] = /* @__PURE__ */ new Set());
var d = a + "__bubble";
c.has(d) || (pf(b, a, 2, false), c.add(d));
}
function qf(a, b, c) {
var d = 0;
b && (d |= 4);
pf(c, a, d, b);
}
var rf = "_reactListening" + Math.random().toString(36).slice(2);
function sf(a) {
if (!a[rf]) {
a[rf] = true;
da.forEach(function(b2) {
"selectionchange" !== b2 && (mf.has(b2) || qf(b2, false, a), qf(b2, true, a));
});
var b = 9 === a.nodeType ? a : a.ownerDocument;
null === b || b[rf] || (b[rf] = true, qf("selectionchange", false, b));
}
}
function pf(a, b, c, d) {
switch (jd(b)) {
case 1:
var e = ed;
break;
case 4:
e = gd;
break;
default:
e = fd;
}
c = e.bind(null, b, c, a);
e = void 0;
!Lb || "touchstart" !== b && "touchmove" !== b && "wheel" !== b || (e = true);
d ? void 0 !== e ? a.addEventListener(b, c, { capture: true, passive: e }) : a.addEventListener(b, c, true) : void 0 !== e ? a.addEventListener(b, c, { passive: e }) : a.addEventListener(b, c, false);
}
function hd(a, b, c, d, e) {
var f2 = d;
if (0 === (b & 1) && 0 === (b & 2) && null !== d) a: for (; ; ) {
if (null === d) return;
var g = d.tag;
if (3 === g || 4 === g) {
var h = d.stateNode.containerInfo;
if (h === e || 8 === h.nodeType && h.parentNode === e) break;
if (4 === g) for (g = d.return; null !== g; ) {
var k2 = g.tag;
if (3 === k2 || 4 === k2) {
if (k2 = g.stateNode.containerInfo, k2 === e || 8 === k2.nodeType && k2.parentNode === e) return;
}
g = g.return;
}
for (; null !== h; ) {
g = Wc(h);
if (null === g) return;
k2 = g.tag;
if (5 === k2 || 6 === k2) {
d = f2 = g;
continue a;
}
h = h.parentNode;
}
}
d = d.return;
}
Jb(function() {
var d2 = f2, e2 = xb(c), g2 = [];
a: {
var h2 = df.get(a);
if (void 0 !== h2) {
var k3 = td, n2 = a;
switch (a) {
case "keypress":
if (0 === od(c)) break a;
case "keydown":
case "keyup":
k3 = Rd;
break;
case "focusin":
n2 = "focus";
k3 = Fd;
break;
case "focusout":
n2 = "blur";
k3 = Fd;
break;
case "beforeblur":
case "afterblur":
k3 = Fd;
break;
case "click":
if (2 === c.button) break a;
case "auxclick":
case "dblclick":
case "mousedown":
case "mousemove":
case "mouseup":
case "mouseout":
case "mouseover":
case "contextmenu":
k3 = Bd;
break;
case "drag":
case "dragend":
case "dragenter":
case "dragexit":
case "dragleave":
case "dragover":
case "dragstart":
case "drop":
k3 = Dd;
break;
case "touchcancel":
case "touchend":
case "touchmove":
case "touchstart":
k3 = Vd;
break;
case $e$1:
case af:
case bf:
k3 = Hd;
break;
case cf:
k3 = Xd;
break;
case "scroll":
k3 = vd;
break;
case "wheel":
k3 = Zd;
break;
case "copy":
case "cut":
case "paste":
k3 = Jd;
break;
case "gotpointercapture":
case "lostpointercapture":
case "pointercancel":
case "pointerdown":
case "pointermove":
case "pointerout":
case "pointerover":
case "pointerup":
k3 = Td;
}
var t2 = 0 !== (b & 4), J2 = !t2 && "scroll" === a, x2 = t2 ? null !== h2 ? h2 + "Capture" : null : h2;
t2 = [];
for (var w2 = d2, u2; null !== w2; ) {
u2 = w2;
var F2 = u2.stateNode;
5 === u2.tag && null !== F2 && (u2 = F2, null !== x2 && (F2 = Kb(w2, x2), null != F2 && t2.push(tf(w2, F2, u2))));
if (J2) break;
w2 = w2.return;
}
0 < t2.length && (h2 = new k3(h2, n2, null, c, e2), g2.push({ event: h2, listeners: t2 }));
}
}
if (0 === (b & 7)) {
a: {
h2 = "mouseover" === a || "pointerover" === a;
k3 = "mouseout" === a || "pointerout" === a;
if (h2 && c !== wb && (n2 = c.relatedTarget || c.fromElement) && (Wc(n2) || n2[uf])) break a;
if (k3 || h2) {
h2 = e2.window === e2 ? e2 : (h2 = e2.ownerDocument) ? h2.defaultView || h2.parentWindow : window;
if (k3) {
if (n2 = c.relatedTarget || c.toElement, k3 = d2, n2 = n2 ? Wc(n2) : null, null !== n2 && (J2 = Vb(n2), n2 !== J2 || 5 !== n2.tag && 6 !== n2.tag)) n2 = null;
} else k3 = null, n2 = d2;
if (k3 !== n2) {
t2 = Bd;
F2 = "onMouseLeave";
x2 = "onMouseEnter";
w2 = "mouse";
if ("pointerout" === a || "pointerover" === a) t2 = Td, F2 = "onPointerLeave", x2 = "onPointerEnter", w2 = "pointer";
J2 = null == k3 ? h2 : ue(k3);
u2 = null == n2 ? h2 : ue(n2);
h2 = new t2(F2, w2 + "leave", k3, c, e2);
h2.target = J2;
h2.relatedTarget = u2;
F2 = null;
Wc(e2) === d2 && (t2 = new t2(x2, w2 + "enter", n2, c, e2), t2.target = u2, t2.relatedTarget = J2, F2 = t2);
J2 = F2;
if (k3 && n2) b: {
t2 = k3;
x2 = n2;
w2 = 0;
for (u2 = t2; u2; u2 = vf(u2)) w2++;
u2 = 0;
for (F2 = x2; F2; F2 = vf(F2)) u2++;
for (; 0 < w2 - u2; ) t2 = vf(t2), w2--;
for (; 0 < u2 - w2; ) x2 = vf(x2), u2--;
for (; w2--; ) {
if (t2 === x2 || null !== x2 && t2 === x2.alternate) break b;
t2 = vf(t2);
x2 = vf(x2);
}
t2 = null;
}
else t2 = null;
null !== k3 && wf(g2, h2, k3, t2, false);
null !== n2 && null !== J2 && wf(g2, J2, n2, t2, true);
}
}
}
a: {
h2 = d2 ? ue(d2) : window;
k3 = h2.nodeName && h2.nodeName.toLowerCase();
if ("select" === k3 || "input" === k3 && "file" === h2.type) var na = ve$1;
else if (me$1(h2)) if (we$1) na = Fe;
else {
na = De;
var xa = Ce;
}
else (k3 = h2.nodeName) && "input" === k3.toLowerCase() && ("checkbox" === h2.type || "radio" === h2.type) && (na = Ee);
if (na && (na = na(a, d2))) {
ne$1(g2, na, c, e2);
break a;
}
xa && xa(a, h2, d2);
"focusout" === a && (xa = h2._wrapperState) && xa.controlled && "number" === h2.type && cb(h2, "number", h2.value);
}
xa = d2 ? ue(d2) : window;
switch (a) {
case "focusin":
if (me$1(xa) || "true" === xa.contentEditable) Qe = xa, Re = d2, Se = null;
break;
case "focusout":
Se = Re = Qe = null;
break;
case "mousedown":
Te$1 = true;
break;
case "contextmenu":
case "mouseup":
case "dragend":
Te$1 = false;
Ue(g2, c, e2);
break;
case "selectionchange":
if (Pe) break;
case "keydown":
case "keyup":
Ue(g2, c, e2);
}
var $a;
if (ae$1) b: {
switch (a) {
case "compositionstart":
var ba = "onCompositionStart";
break b;
case "compositionend":
ba = "onCompositionEnd";
break b;
case "compositionupdate":
ba = "onCompositionUpdate";
break b;
}
ba = void 0;
}
else ie$1 ? ge$1(a, c) && (ba = "onCompositionEnd") : "keydown" === a && 229 === c.keyCode && (ba = "onCompositionStart");
ba && (de$1 && "ko" !== c.locale && (ie$1 || "onCompositionStart" !== ba ? "onCompositionEnd" === ba && ie$1 && ($a = nd()) : (kd = e2, ld = "value" in kd ? kd.value : kd.textContent, ie$1 = true)), xa = oe$1(d2, ba), 0 < xa.length && (ba = new Ld(ba, a, null, c, e2), g2.push({ event: ba, listeners: xa }), $a ? ba.data = $a : ($a = he$1(c), null !== $a && (ba.data = $a))));
if ($a = ce$1 ? je(a, c) : ke(a, c)) d2 = oe$1(d2, "onBeforeInput"), 0 < d2.length && (e2 = new Ld("onBeforeInput", "beforeinput", null, c, e2), g2.push({ event: e2, listeners: d2 }), e2.data = $a);
}
se$1(g2, b);
});
}
function tf(a, b, c) {
return { instance: a, listener: b, currentTarget: c };
}
function oe$1(a, b) {
for (var c = b + "Capture", d = []; null !== a; ) {
var e = a, f2 = e.stateNode;
5 === e.tag && null !== f2 && (e = f2, f2 = Kb(a, c), null != f2 && d.unshift(tf(a, f2, e)), f2 = Kb(a, b), null != f2 && d.push(tf(a, f2, e)));
a = a.return;
}
return d;
}
function vf(a) {
if (null === a) return null;
do
a = a.return;
while (a && 5 !== a.tag);
return a ? a : null;
}
function wf(a, b, c, d, e) {
for (var f2 = b._reactName, g = []; null !== c && c !== d; ) {
var h = c, k2 = h.alternate, l2 = h.stateNode;
if (null !== k2 && k2 === d) break;
5 === h.tag && null !== l2 && (h = l2, e ? (k2 = Kb(c, f2), null != k2 && g.unshift(tf(c, k2, h))) : e || (k2 = Kb(c, f2), null != k2 && g.push(tf(c, k2, h))));
c = c.return;
}
0 !== g.length && a.push({ event: b, listeners: g });
}
var xf = /\r\n?/g, yf = /\u0000|\uFFFD/g;
function zf(a) {
return ("string" === typeof a ? a : "" + a).replace(xf, "\n").replace(yf, "");
}
function Af(a, b, c) {
b = zf(b);
if (zf(a) !== b && c) throw Error(p(425));
}
function Bf() {
}
var Cf = null, Df = null;
function Ef(a, b) {
return "textarea" === a || "noscript" === a || "string" === typeof b.children || "number" === typeof b.children || "object" === typeof b.dangerouslySetInnerHTML && null !== b.dangerouslySetInnerHTML && null != b.dangerouslySetInnerHTML.__html;
}
var Ff = "function" === typeof setTimeout ? setTimeout : void 0, Gf = "function" === typeof clearTimeout ? clearTimeout : void 0, Hf = "function" === typeof Promise ? Promise : void 0, Jf = "function" === typeof queueMicrotask ? queueMicrotask : "undefined" !== typeof Hf ? function(a) {
return Hf.resolve(null).then(a).catch(If);
} : Ff;
function If(a) {
setTimeout(function() {
throw a;
});
}
function Kf(a, b) {
var c = b, d = 0;
do {
var e = c.nextSibling;
a.removeChild(c);
if (e && 8 === e.nodeType) if (c = e.data, "/$" === c) {
if (0 === d) {
a.removeChild(e);
bd(b);
return;
}
d--;
} else "$" !== c && "$?" !== c && "$!" !== c || d++;
c = e;
} while (c);
bd(b);
}
function Lf(a) {
for (; null != a; a = a.nextSibling) {
var b = a.nodeType;
if (1 === b || 3 === b) break;
if (8 === b) {
b = a.data;
if ("$" === b || "$!" === b || "$?" === b) break;
if ("/$" === b) return null;
}
}
return a;
}
function Mf(a) {
a = a.previousSibling;
for (var b = 0; a; ) {
if (8 === a.nodeType) {
var c = a.data;
if ("$" === c || "$!" === c || "$?" === c) {
if (0 === b) return a;
b--;
} else "/$" === c && b++;
}
a = a.previousSibling;
}
return null;
}
var Nf = Math.random().toString(36).slice(2), Of = "__reactFiber$" + Nf, Pf = "__reactProps$" + Nf, uf = "__reactContainer$" + Nf, of = "__reactEvents$" + Nf, Qf = "__reactListeners$" + Nf, Rf = "__reactHandles$" + Nf;
function Wc(a) {
var b = a[Of];
if (b) return b;
for (var c = a.parentNode; c; ) {
if (b = c[uf] || c[Of]) {
c = b.alternate;
if (null !== b.child || null !== c && null !== c.child) for (a = Mf(a); null !== a; ) {
if (c = a[Of]) return c;
a = Mf(a);
}
return b;
}
a = c;
c = a.parentNode;
}
return null;
}
function Cb(a) {
a = a[Of] || a[uf];
return !a || 5 !== a.tag && 6 !== a.tag && 13 !== a.tag && 3 !== a.tag ? null : a;
}
function ue(a) {
if (5 === a.tag || 6 === a.tag) return a.stateNode;
throw Error(p(33));
}
function Db(a) {
return a[Pf] || null;
}
var Sf = [], Tf = -1;
function Uf(a) {
return { current: a };
}
function E$1(a) {
0 > Tf || (a.current = Sf[Tf], Sf[Tf] = null, Tf--);
}
function G(a, b) {
Tf++;
Sf[Tf] = a.current;
a.current = b;
}
var Vf = {}, H = Uf(Vf), Wf = Uf(false), Xf = Vf;
function Yf(a, b) {
var c = a.type.contextTypes;
if (!c) return Vf;
var d = a.stateNode;
if (d && d.__reactInternalMemoizedUnmaskedChildContext === b) return d.__reactInternalMemoizedMaskedChildContext;
var e = {}, f2;
for (f2 in c) e[f2] = b[f2];
d && (a = a.stateNode, a.__reactInternalMemoizedUnmaskedChildContext = b, a.__reactInternalMemoizedMaskedChildContext = e);
return e;
}
function Zf(a) {
a = a.childContextTypes;
return null !== a && void 0 !== a;
}
function $f() {
E$1(Wf);
E$1(H);
}
function ag(a, b, c) {
if (H.current !== Vf) throw Error(p(168));
G(H, b);
G(Wf, c);
}
function bg(a, b, c) {
var d = a.stateNode;
b = b.childContextTypes;
if ("function" !== typeof d.getChildContext) return c;
d = d.getChildContext();
for (var e in d) if (!(e in b)) throw Error(p(108, Ra(a) || "Unknown", e));
return A({}, c, d);
}
function cg(a) {
a = (a = a.stateNode) && a.__reactInternalMemoizedMergedChildContext || Vf;
Xf = H.current;
G(H, a);
G(Wf, Wf.current);
return true;
}
function dg(a, b, c) {
var d = a.stateNode;
if (!d) throw Error(p(169));
c ? (a = bg(a, b, Xf), d.__reactInternalMemoizedMergedChildContext = a, E$1(Wf), E$1(H), G(H, a)) : E$1(Wf);
G(Wf, c);
}
var eg = null, fg = false, gg = false;
function hg(a) {
null === eg ? eg = [a] : eg.push(a);
}
function ig(a) {
fg = true;
hg(a);
}
function jg() {
if (!gg && null !== eg) {
gg = true;
var a = 0, b = C;
try {
var c = eg;
for (C = 1; a < c.length; a++) {
var d = c[a];
do
d = d(true);
while (null !== d);
}
eg = null;
fg = false;
} catch (e) {
throw null !== eg && (eg = eg.slice(a + 1)), ac(fc, jg), e;
} finally {
C = b, gg = false;
}
}
return null;
}
var kg = [], lg = 0, mg = null, ng = 0, og = [], pg = 0, qg = null, rg = 1, sg = "";
function tg(a, b) {
kg[lg++] = ng;
kg[lg++] = mg;
mg = a;
ng = b;
}
function ug(a, b, c) {
og[pg++] = rg;
og[pg++] = sg;
og[pg++] = qg;
qg = a;
var d = rg;
a = sg;
var e = 32 - oc(d) - 1;
d &= ~(1 << e);
c += 1;
var f2 = 32 - oc(b) + e;
if (30 < f2) {
var g = e - e % 5;
f2 = (d & (1 << g) - 1).toString(32);
d >>= g;
e -= g;
rg = 1 << 32 - oc(b) + e | c << e | d;
sg = f2 + a;
} else rg = 1 << f2 | c << e | d, sg = a;
}
function vg(a) {
null !== a.return && (tg(a, 1), ug(a, 1, 0));
}
function wg(a) {
for (; a === mg; ) mg = kg[--lg], kg[lg] = null, ng = kg[--lg], kg[lg] = null;
for (; a === qg; ) qg = og[--pg], og[pg] = null, sg = og[--pg], og[pg] = null, rg = og[--pg], og[pg] = null;
}
var xg = null, yg = null, I = false, zg = null;
function Ag(a, b) {
var c = Bg(5, null, null, 0);
c.elementType = "DELETED";
c.stateNode = b;
c.return = a;
b = a.deletions;
null === b ? (a.deletions = [c], a.flags |= 16) : b.push(c);
}
function Cg(a, b) {
switch (a.tag) {
case 5:
var c = a.type;
b = 1 !== b.nodeType || c.toLowerCase() !== b.nodeName.toLowerCase() ? null : b;
return null !== b ? (a.stateNode = b, xg = a, yg = Lf(b.firstChild), true) : false;
case 6:
return b = "" === a.pendingProps || 3 !== b.nodeType ? null : b, null !== b ? (a.stateNode = b, xg = a, yg = null, true) : false;
case 13:
return b = 8 !== b.nodeType ? null : b, null !== b ? (c = null !== qg ? { id: rg, overflow: sg } : null, a.memoizedState = { dehydrated: b, treeContext: c, retryLane: 1073741824 }, c = Bg(18, null, null, 0), c.stateNode = b, c.return = a, a.child = c, xg = a, yg = null, true) : false;
default:
return false;
}
}
function Dg(a) {
return 0 !== (a.mode & 1) && 0 === (a.flags & 128);
}
function Eg(a) {
if (I) {
var b = yg;
if (b) {
var c = b;
if (!Cg(a, b)) {
if (Dg(a)) throw Error(p(418));
b = Lf(c.nextSibling);
var d = xg;
b && Cg(a, b) ? Ag(d, c) : (a.flags = a.flags & -4097 | 2, I = false, xg = a);
}
} else {
if (Dg(a)) throw Error(p(418));
a.flags = a.flags & -4097 | 2;
I = false;
xg = a;
}
}
}
function Fg(a) {
for (a = a.return; null !== a && 5 !== a.tag && 3 !== a.tag && 13 !== a.tag; ) a = a.return;
xg = a;
}
function Gg(a) {
if (a !== xg) return false;
if (!I) return Fg(a), I = true, false;
var b;
(b = 3 !== a.tag) && !(b = 5 !== a.tag) && (b = a.type, b = "head" !== b && "body" !== b && !Ef(a.type, a.memoizedProps));
if (b && (b = yg)) {
if (Dg(a)) throw Hg(), Error(p(418));
for (; b; ) Ag(a, b), b = Lf(b.nextSibling);
}
Fg(a);
if (13 === a.tag) {
a = a.memoizedState;
a = null !== a ? a.dehydrated : null;
if (!a) throw Error(p(317));
a: {
a = a.nextSibling;
for (b = 0; a; ) {
if (8 === a.nodeType) {
var c = a.data;
if ("/$" === c) {
if (0 === b) {
yg = Lf(a.nextSibling);
break a;
}
b--;
} else "$" !== c && "$!" !== c && "$?" !== c || b++;
}
a = a.nextSibling;
}
yg = null;
}
} else yg = xg ? Lf(a.stateNode.nextSibling) : null;
return true;
}
function Hg() {
for (var a = yg; a; ) a = Lf(a.nextSibling);
}
function Ig() {
yg = xg = null;
I = false;
}
function Jg(a) {
null === zg ? zg = [a] : zg.push(a);
}
var Kg = ua.ReactCurrentBatchConfig;
function Lg(a, b, c) {
a = c.ref;
if (null !== a && "function" !== typeof a && "object" !== typeof a) {
if (c._owner) {
c = c._owner;
if (c) {
if (1 !== c.tag) throw Error(p(309));
var d = c.stateNode;
}
if (!d) throw Error(p(147, a));
var e = d, f2 = "" + a;
if (null !== b && null !== b.ref && "function" === typeof b.ref && b.ref._stringRef === f2) return b.ref;
b = function(a2) {
var b2 = e.refs;
null === a2 ? delete b2[f2] : b2[f2] = a2;
};
b._stringRef = f2;
return b;
}
if ("string" !== typeof a) throw Error(p(284));
if (!c._owner) throw Error(p(290, a));
}
return a;
}
function Mg(a, b) {
a = Object.prototype.toString.call(b);
throw Error(p(31, "[object Object]" === a ? "object with keys {" + Object.keys(b).join(", ") + "}" : a));
}
function Ng(a) {
var b = a._init;
return b(a._payload);
}
function Og(a) {
function b(b2, c2) {
if (a) {
var d2 = b2.deletions;
null === d2 ? (b2.deletions = [c2], b2.flags |= 16) : d2.push(c2);
}
}
function c(c2, d2) {
if (!a) return null;
for (; null !== d2; ) b(c2, d2), d2 = d2.sibling;
return null;
}
function d(a2, b2) {
for (a2 = /* @__PURE__ */ new Map(); null !== b2; ) null !== b2.key ? a2.set(b2.key, b2) : a2.set(b2.index, b2), b2 = b2.sibling;
return a2;
}
function e(a2, b2) {
a2 = Pg(a2, b2);
a2.index = 0;
a2.sibling = null;
return a2;
}
function f2(b2, c2, d2) {
b2.index = d2;
if (!a) return b2.flags |= 1048576, c2;
d2 = b2.alternate;
if (null !== d2) return d2 = d2.index, d2 < c2 ? (b2.flags |= 2, c2) : d2;
b2.flags |= 2;
return c2;
}
function g(b2) {
a && null === b2.alternate && (b2.flags |= 2);
return b2;
}
function h(a2, b2, c2, d2) {
if (null === b2 || 6 !== b2.tag) return b2 = Qg(c2, a2.mode, d2), b2.return = a2, b2;
b2 = e(b2, c2);
b2.return = a2;
return b2;
}
function k2(a2, b2, c2, d2) {
var f3 = c2.type;
if (f3 === ya) return m2(a2, b2, c2.props.children, d2, c2.key);
if (null !== b2 && (b2.elementType === f3 || "object" === typeof f3 && null !== f3 && f3.$typeof === Ha && Ng(f3) === b2.type)) return d2 = e(b2, c2.props), d2.ref = Lg(a2, b2, c2), d2.return = a2, d2;
d2 = Rg(c2.type, c2.key, c2.props, null, a2.mode, d2);
d2.ref = Lg(a2, b2, c2);
d2.return = a2;
return d2;
}
function l2(a2, b2, c2, d2) {
if (null === b2 || 4 !== b2.tag || b2.stateNode.containerInfo !== c2.containerInfo || b2.stateNode.implementation !== c2.implementation) return b2 = Sg(c2, a2.mode, d2), b2.return = a2, b2;
b2 = e(b2, c2.children || []);
b2.return = a2;
return b2;
}
function m2(a2, b2, c2, d2, f3) {
if (null === b2 || 7 !== b2.tag) return b2 = Tg(c2, a2.mode, d2, f3), b2.return = a2, b2;
b2 = e(b2, c2);
b2.return = a2;
return b2;
}
function q2(a2, b2, c2) {
if ("string" === typeof b2 && "" !== b2 || "number" === typeof b2) return b2 = Qg("" + b2, a2.mode, c2), b2.return = a2, b2;
if ("object" === typeof b2 && null !== b2) {
switch (b2.$typeof) {
case va:
return c2 = Rg(b2.type, b2.key, b2.props, null, a2.mode, c2), c2.ref = Lg(a2, null, b2), c2.return = a2, c2;
case wa:
return b2 = Sg(b2, a2.mode, c2), b2.return = a2, b2;
case Ha:
var d2 = b2._init;
return q2(a2, d2(b2._payload), c2);
}
if (eb(b2) || Ka(b2)) return b2 = Tg(b2, a2.mode, c2, null), b2.return = a2, b2;
Mg(a2, b2);
}
return null;
}
function r2(a2, b2, c2, d2) {
var e2 = null !== b2 ? b2.key : null;
if ("string" === typeof c2 && "" !== c2 || "number" === typeof c2) return null !== e2 ? null : h(a2, b2, "" + c2, d2);
if ("object" === typeof c2 && null !== c2) {
switch (c2.$typeof) {
case va:
return c2.key === e2 ? k2(a2, b2, c2, d2) : null;
case wa:
return c2.key === e2 ? l2(a2, b2, c2, d2) : null;
case Ha:
return e2 = c2._init, r2(
a2,
b2,
e2(c2._payload),
d2
);
}
if (eb(c2) || Ka(c2)) return null !== e2 ? null : m2(a2, b2, c2, d2, null);
Mg(a2, c2);
}
return null;
}
function y2(a2, b2, c2, d2, e2) {
if ("string" === typeof d2 && "" !== d2 || "number" === typeof d2) return a2 = a2.get(c2) || null, h(b2, a2, "" + d2, e2);
if ("object" === typeof d2 && null !== d2) {
switch (d2.$typeof) {
case va:
return a2 = a2.get(null === d2.key ? c2 : d2.key) || null, k2(b2, a2, d2, e2);
case wa:
return a2 = a2.get(null === d2.key ? c2 : d2.key) || null, l2(b2, a2, d2, e2);
case Ha:
var f3 = d2._init;
return y2(a2, b2, c2, f3(d2._payload), e2);
}
if (eb(d2) || Ka(d2)) return a2 = a2.get(c2) || null, m2(b2, a2, d2, e2, null);
Mg(b2, d2);
}
return null;
}
function n2(e2, g2, h2, k3) {
for (var l3 = null, m3 = null, u2 = g2, w2 = g2 = 0, x2 = null; null !== u2 && w2 < h2.length; w2++) {
u2.index > w2 ? (x2 = u2, u2 = null) : x2 = u2.sibling;
var n3 = r2(e2, u2, h2[w2], k3);
if (null === n3) {
null === u2 && (u2 = x2);
break;
}
a && u2 && null === n3.alternate && b(e2, u2);
g2 = f2(n3, g2, w2);
null === m3 ? l3 = n3 : m3.sibling = n3;
m3 = n3;
u2 = x2;
}
if (w2 === h2.length) return c(e2, u2), I && tg(e2, w2), l3;
if (null === u2) {
for (; w2 < h2.length; w2++) u2 = q2(e2, h2[w2], k3), null !== u2 && (g2 = f2(u2, g2, w2), null === m3 ? l3 = u2 : m3.sibling = u2, m3 = u2);
I && tg(e2, w2);
return l3;
}
for (u2 = d(e2, u2); w2 < h2.length; w2++) x2 = y2(u2, e2, w2, h2[w2], k3), null !== x2 && (a && null !== x2.alternate && u2.delete(null === x2.key ? w2 : x2.key), g2 = f2(x2, g2, w2), null === m3 ? l3 = x2 : m3.sibling = x2, m3 = x2);
a && u2.forEach(function(a2) {
return b(e2, a2);
});
I && tg(e2, w2);
return l3;
}
function t2(e2, g2, h2, k3) {
var l3 = Ka(h2);
if ("function" !== typeof l3) throw Error(p(150));
h2 = l3.call(h2);
if (null == h2) throw Error(p(151));
for (var u2 = l3 = null, m3 = g2, w2 = g2 = 0, x2 = null, n3 = h2.next(); null !== m3 && !n3.done; w2++, n3 = h2.next()) {
m3.index > w2 ? (x2 = m3, m3 = null) : x2 = m3.sibling;
var t3 = r2(e2, m3, n3.value, k3);
if (null === t3) {
null === m3 && (m3 = x2);
break;
}
a && m3 && null === t3.alternate && b(e2, m3);
g2 = f2(t3, g2, w2);
null === u2 ? l3 = t3 : u2.sibling = t3;
u2 = t3;
m3 = x2;
}
if (n3.done) return c(
e2,
m3
), I && tg(e2, w2), l3;
if (null === m3) {
for (; !n3.done; w2++, n3 = h2.next()) n3 = q2(e2, n3.value, k3), null !== n3 && (g2 = f2(n3, g2, w2), null === u2 ? l3 = n3 : u2.sibling = n3, u2 = n3);
I && tg(e2, w2);
return l3;
}
for (m3 = d(e2, m3); !n3.done; w2++, n3 = h2.next()) n3 = y2(m3, e2, w2, n3.value, k3), null !== n3 && (a && null !== n3.alternate && m3.delete(null === n3.key ? w2 : n3.key), g2 = f2(n3, g2, w2), null === u2 ? l3 = n3 : u2.sibling = n3, u2 = n3);
a && m3.forEach(function(a2) {
return b(e2, a2);
});
I && tg(e2, w2);
return l3;
}
function J2(a2, d2, f3, h2) {
"object" === typeof f3 && null !== f3 && f3.type === ya && null === f3.key && (f3 = f3.props.children);
if ("object" === typeof f3 && null !== f3) {
switch (f3.$typeof) {
case va:
a: {
for (var k3 = f3.key, l3 = d2; null !== l3; ) {
if (l3.key === k3) {
k3 = f3.type;
if (k3 === ya) {
if (7 === l3.tag) {
c(a2, l3.sibling);
d2 = e(l3, f3.props.children);
d2.return = a2;
a2 = d2;
break a;
}
} else if (l3.elementType === k3 || "object" === typeof k3 && null !== k3 && k3.$typeof === Ha && Ng(k3) === l3.type) {
c(a2, l3.sibling);
d2 = e(l3, f3.props);
d2.ref = Lg(a2, l3, f3);
d2.return = a2;
a2 = d2;
break a;
}
c(a2, l3);
break;
} else b(a2, l3);
l3 = l3.sibling;
}
f3.type === ya ? (d2 = Tg(f3.props.children, a2.mode, h2, f3.key), d2.return = a2, a2 = d2) : (h2 = Rg(f3.type, f3.key, f3.props, null, a2.mode, h2), h2.ref = Lg(a2, d2, f3), h2.return = a2, a2 = h2);
}
return g(a2);
case wa:
a: {
for (l3 = f3.key; null !== d2; ) {
if (d2.key === l3) if (4 === d2.tag && d2.stateNode.containerInfo === f3.containerInfo && d2.stateNode.implementation === f3.implementation) {
c(a2, d2.sibling);
d2 = e(d2, f3.children || []);
d2.return = a2;
a2 = d2;
break a;
} else {
c(a2, d2);
break;
}
else b(a2, d2);
d2 = d2.sibling;
}
d2 = Sg(f3, a2.mode, h2);
d2.return = a2;
a2 = d2;
}
return g(a2);
case Ha:
return l3 = f3._init, J2(a2, d2, l3(f3._payload), h2);
}
if (eb(f3)) return n2(a2, d2, f3, h2);
if (Ka(f3)) return t2(a2, d2, f3, h2);
Mg(a2, f3);
}
return "string" === typeof f3 && "" !== f3 || "number" === typeof f3 ? (f3 = "" + f3, null !== d2 && 6 === d2.tag ? (c(a2, d2.sibling), d2 = e(d2, f3), d2.return = a2, a2 = d2) : (c(a2, d2), d2 = Qg(f3, a2.mode, h2), d2.return = a2, a2 = d2), g(a2)) : c(a2, d2);
}
return J2;
}
var Ug = Og(true), Vg = Og(false), Wg = Uf(null), Xg = null, Yg = null, Zg = null;
function $g() {
Zg = Yg = Xg = null;
}
function ah(a) {
var b = Wg.current;
E$1(Wg);
a._currentValue = b;
}
function bh(a, b, c) {
for (; null !== a; ) {
var d = a.alternate;
(a.childLanes & b) !== b ? (a.childLanes |= b, null !== d && (d.childLanes |= b)) : null !== d && (d.childLanes & b) !== b && (d.childLanes |= b);
if (a === c) break;
a = a.return;
}
}
function ch(a, b) {
Xg = a;
Zg = Yg = null;
a = a.dependencies;
null !== a && null !== a.firstContext && (0 !== (a.lanes & b) && (dh = true), a.firstContext = null);
}
function eh(a) {
var b = a._currentValue;
if (Zg !== a) if (a = { context: a, memoizedValue: b, next: null }, null === Yg) {
if (null === Xg) throw Error(p(308));
Yg = a;
Xg.dependencies = { lanes: 0, firstContext: a };
} else Yg = Yg.next = a;
return b;
}
var fh = null;
function gh(a) {
null === fh ? fh = [a] : fh.push(a);
}
function hh(a, b, c, d) {
var e = b.interleaved;
null === e ? (c.next = c, gh(b)) : (c.next = e.next, e.next = c);
b.interleaved = c;
return ih(a, d);
}
function ih(a, b) {
a.lanes |= b;
var c = a.alternate;
null !== c && (c.lanes |= b);
c = a;
for (a = a.return; null !== a; ) a.childLanes |= b, c = a.alternate, null !== c && (c.childLanes |= b), c = a, a = a.return;
return 3 === c.tag ? c.stateNode : null;
}
var jh = false;
function kh(a) {
a.updateQueue = { baseState: a.memoizedState, firstBaseUpdate: null, lastBaseUpdate: null, shared: { pending: null, interleaved: null, lanes: 0 }, effects: null };
}
function lh(a, b) {
a = a.updateQueue;
b.updateQueue === a && (b.updateQueue = { baseState: a.baseState, firstBaseUpdate: a.firstBaseUpdate, lastBaseUpdate: a.lastBaseUpdate, shared: a.shared, effects: a.effects });
}
function mh(a, b) {
return { eventTime: a, lane: b, tag: 0, payload: null, callback: null, next: null };
}
function nh(a, b, c) {
var d = a.updateQueue;
if (null === d) return null;
d = d.shared;
if (0 !== (K & 2)) {
var e = d.pending;
null === e ? b.next = b : (b.next = e.next, e.next = b);
d.pending = b;
return ih(a, c);
}
e = d.interleaved;
null === e ? (b.next = b, gh(d)) : (b.next = e.next, e.next = b);
d.interleaved = b;
return ih(a, c);
}
function oh(a, b, c) {
b = b.updateQueue;
if (null !== b && (b = b.shared, 0 !== (c & 4194240))) {
var d = b.lanes;
d &= a.pendingLanes;
c |= d;
b.lanes = c;
Cc(a, c);
}
}
function ph(a, b) {
var c = a.updateQueue, d = a.alternate;
if (null !== d && (d = d.updateQueue, c === d)) {
var e = null, f2 = null;
c = c.firstBaseUpdate;
if (null !== c) {
do {
var g = { eventTime: c.eventTime, lane: c.lane, tag: c.tag, payload: c.payload, callback: c.callback, next: null };
null === f2 ? e = f2 = g : f2 = f2.next = g;
c = c.next;
} while (null !== c);
null === f2 ? e = f2 = b : f2 = f2.next = b;
} else e = f2 = b;
c = { baseState: d.baseState, firstBaseUpdate: e, lastBaseUpdate: f2, shared: d.shared, effects: d.effects };
a.updateQueue = c;
return;
}
a = c.lastBaseUpdate;
null === a ? c.firstBaseUpdate = b : a.next = b;
c.lastBaseUpdate = b;
}
function qh(a, b, c, d) {
var e = a.updateQueue;
jh = false;
var f2 = e.firstBaseUpdate, g = e.lastBaseUpdate, h = e.shared.pending;
if (null !== h) {
e.shared.pending = null;
var k2 = h, l2 = k2.next;
k2.next = null;
null === g ? f2 = l2 : g.next = l2;
g = k2;
var m2 = a.alternate;
null !== m2 && (m2 = m2.updateQueue, h = m2.lastBaseUpdate, h !== g && (null === h ? m2.firstBaseUpdate = l2 : h.next = l2, m2.lastBaseUpdate = k2));
}
if (null !== f2) {
var q2 = e.baseState;
g = 0;
m2 = l2 = k2 = null;
h = f2;
do {
var r2 = h.lane, y2 = h.eventTime;
if ((d & r2) === r2) {
null !== m2 && (m2 = m2.next = {
eventTime: y2,
lane: 0,
tag: h.tag,
payload: h.payload,
callback: h.callback,
next: null
});
a: {
var n2 = a, t2 = h;
r2 = b;
y2 = c;
switch (t2.tag) {
case 1:
n2 = t2.payload;
if ("function" === typeof n2) {
q2 = n2.call(y2, q2, r2);
break a;
}
q2 = n2;
break a;
case 3:
n2.flags = n2.flags & -65537 | 128;
case 0:
n2 = t2.payload;
r2 = "function" === typeof n2 ? n2.call(y2, q2, r2) : n2;
if (null === r2 || void 0 === r2) break a;
q2 = A({}, q2, r2);
break a;
case 2:
jh = true;
}
}
null !== h.callback && 0 !== h.lane && (a.flags |= 64, r2 = e.effects, null === r2 ? e.effects = [h] : r2.push(h));
} else y2 = { eventTime: y2, lane: r2, tag: h.tag, payload: h.payload, callback: h.callback, next: null }, null === m2 ? (l2 = m2 = y2, k2 = q2) : m2 = m2.next = y2, g |= r2;
h = h.next;
if (null === h) if (h = e.shared.pending, null === h) break;
else r2 = h, h = r2.next, r2.next = null, e.lastBaseUpdate = r2, e.shared.pending = null;
} while (1);
null === m2 && (k2 = q2);
e.baseState = k2;
e.firstBaseUpdate = l2;
e.lastBaseUpdate = m2;
b = e.shared.interleaved;
if (null !== b) {
e = b;
do
g |= e.lane, e = e.next;
while (e !== b);
} else null === f2 && (e.shared.lanes = 0);
rh |= g;
a.lanes = g;
a.memoizedState = q2;
}
}
function sh(a, b, c) {
a = b.effects;
b.effects = null;
if (null !== a) for (b = 0; b < a.length; b++) {
var d = a[b], e = d.callback;
if (null !== e) {
d.callback = null;
d = c;
if ("function" !== typeof e) throw Error(p(191, e));
e.call(d);
}
}
}
var th = {}, uh = Uf(th), vh = Uf(th), wh = Uf(th);
function xh(a) {
if (a === th) throw Error(p(174));
return a;
}
function yh(a, b) {
G(wh, b);
G(vh, a);
G(uh, th);
a = b.nodeType;
switch (a) {
case 9:
case 11:
b = (b = b.documentElement) ? b.namespaceURI : lb(null, "");
break;
default:
a = 8 === a ? b.parentNode : b, b = a.namespaceURI || null, a = a.tagName, b = lb(b, a);
}
E$1(uh);
G(uh, b);
}
function zh() {
E$1(uh);
E$1(vh);
E$1(wh);
}
function Ah(a) {
xh(wh.current);
var b = xh(uh.current);
var c = lb(b, a.type);
b !== c && (G(vh, a), G(uh, c));
}
function Bh(a) {
vh.current === a && (E$1(uh), E$1(vh));
}
var L$1 = Uf(0);
function Ch(a) {
for (var b = a; null !== b; ) {
if (13 === b.tag) {
var c = b.memoizedState;
if (null !== c && (c = c.dehydrated, null === c || "$?" === c.data || "$!" === c.data)) return b;
} else if (19 === b.tag && void 0 !== b.memoizedProps.revealOrder) {
if (0 !== (b.flags & 128)) return b;
} else if (null !== b.child) {
b.child.return = b;
b = b.child;
continue;
}
if (b === a) break;
for (; null === b.sibling; ) {
if (null === b.return || b.return === a) return null;
b = b.return;
}
b.sibling.return = b.return;
b = b.sibling;
}
return null;
}
var Dh = [];
function Eh() {
for (var a = 0; a < Dh.length; a++) Dh[a]._workInProgressVersionPrimary = null;
Dh.length = 0;
}
var Fh = ua.ReactCurrentDispatcher, Gh = ua.ReactCurrentBatchConfig, Hh = 0, M$1 = null, N = null, O = null, Ih = false, Jh = false, Kh = 0, Lh = 0;
function P$1() {
throw Error(p(321));
}
function Mh(a, b) {
if (null === b) return false;
for (var c = 0; c < b.length && c < a.length; c++) if (!He(a[c], b[c])) return false;
return true;
}
function Nh(a, b, c, d, e, f2) {
Hh = f2;
M$1 = b;
b.memoizedState = null;
b.updateQueue = null;
b.lanes = 0;
Fh.current = null === a || null === a.memoizedState ? Oh : Ph;
a = c(d, e);
if (Jh) {
f2 = 0;
do {
Jh = false;
Kh = 0;
if (25 <= f2) throw Error(p(301));
f2 += 1;
O = N = null;
b.updateQueue = null;
Fh.current = Qh;
a = c(d, e);
} while (Jh);
}
Fh.current = Rh;
b = null !== N && null !== N.next;
Hh = 0;
O = N = M$1 = null;
Ih = false;
if (b) throw Error(p(300));
return a;
}
function Sh() {
var a = 0 !== Kh;
Kh = 0;
return a;
}
function Th() {
var a = { memoizedState: null, baseState: null, baseQueue: null, queue: null, next: null };
null === O ? M$1.memoizedState = O = a : O = O.next = a;
return O;
}
function Uh() {
if (null === N) {
var a = M$1.alternate;
a = null !== a ? a.memoizedState : null;
} else a = N.next;
var b = null === O ? M$1.memoizedState : O.next;
if (null !== b) O = b, N = a;
else {
if (null === a) throw Error(p(310));
N = a;
a = { memoizedState: N.memoizedState, baseState: N.baseState, baseQueue: N.baseQueue, queue: N.queue, next: null };
null === O ? M$1.memoizedState = O = a : O = O.next = a;
}
return O;
}
function Vh(a, b) {
return "function" === typeof b ? b(a) : b;
}
function Wh(a) {
var b = Uh(), c = b.queue;
if (null === c) throw Error(p(311));
c.lastRenderedReducer = a;
var d = N, e = d.baseQueue, f2 = c.pending;
if (null !== f2) {
if (null !== e) {
var g = e.next;
e.next = f2.next;
f2.next = g;
}
d.baseQueue = e = f2;
c.pending = null;
}
if (null !== e) {
f2 = e.next;
d = d.baseState;
var h = g = null, k2 = null, l2 = f2;
do {
var m2 = l2.lane;
if ((Hh & m2) === m2) null !== k2 && (k2 = k2.next = { lane: 0, action: l2.action, hasEagerState: l2.hasEagerState, eagerState: l2.eagerState, next: null }), d = l2.hasEagerState ? l2.eagerState : a(d, l2.action);
else {
var q2 = {
lane: m2,
action: l2.action,
hasEagerState: l2.hasEagerState,
eagerState: l2.eagerState,
next: null
};
null === k2 ? (h = k2 = q2, g = d) : k2 = k2.next = q2;
M$1.lanes |= m2;
rh |= m2;
}
l2 = l2.next;
} while (null !== l2 && l2 !== f2);
null === k2 ? g = d : k2.next = h;
He(d, b.memoizedState) || (dh = true);
b.memoizedState = d;
b.baseState = g;
b.baseQueue = k2;
c.lastRenderedState = d;
}
a = c.interleaved;
if (null !== a) {
e = a;
do
f2 = e.lane, M$1.lanes |= f2, rh |= f2, e = e.next;
while (e !== a);
} else null === e && (c.lanes = 0);
return [b.memoizedState, c.dispatch];
}
function Xh(a) {
var b = Uh(), c = b.queue;
if (null === c) throw Error(p(311));
c.lastRenderedReducer = a;
var d = c.dispatch, e = c.pending, f2 = b.memoizedState;
if (null !== e) {
c.pending = null;
var g = e = e.next;
do
f2 = a(f2, g.action), g = g.next;
while (g !== e);
He(f2, b.memoizedState) || (dh = true);
b.memoizedState = f2;
null === b.baseQueue && (b.baseState = f2);
c.lastRenderedState = f2;
}
return [f2, d];
}
function Yh() {
}
function Zh(a, b) {
var c = M$1, d = Uh(), e = b(), f2 = !He(d.memoizedState, e);
f2 && (d.memoizedState = e, dh = true);
d = d.queue;
$h(ai.bind(null, c, d, a), [a]);
if (d.getSnapshot !== b || f2 || null !== O && O.memoizedState.tag & 1) {
c.flags |= 2048;
bi(9, ci.bind(null, c, d, e, b), void 0, null);
if (null === Q) throw Error(p(349));
0 !== (Hh & 30) || di(c, b, e);
}
return e;
}
function di(a, b, c) {
a.flags |= 16384;
a = { getSnapshot: b, value: c };
b = M$1.updateQueue;
null === b ? (b = { lastEffect: null, stores: null }, M$1.updateQueue = b, b.stores = [a]) : (c = b.stores, null === c ? b.stores = [a] : c.push(a));
}
function ci(a, b, c, d) {
b.value = c;
b.getSnapshot = d;
ei(b) && fi(a);
}
function ai(a, b, c) {
return c(function() {
ei(b) && fi(a);
});
}
function ei(a) {
var b = a.getSnapshot;
a = a.value;
try {
var c = b();
return !He(a, c);
} catch (d) {
return true;
}
}
function fi(a) {
var b = ih(a, 1);
null !== b && gi(b, a, 1, -1);
}
function hi(a) {
var b = Th();
"function" === typeof a && (a = a());
b.memoizedState = b.baseState = a;
a = { pending: null, interleaved: null, lanes: 0, dispatch: null, lastRenderedReducer: Vh, lastRenderedState: a };
b.queue = a;
a = a.dispatch = ii.bind(null, M$1, a);
return [b.memoizedState, a];
}
function bi(a, b, c, d) {
a = { tag: a, create: b, destroy: c, deps: d, next: null };
b = M$1.updateQueue;
null === b ? (b = { lastEffect: null, stores: null }, M$1.updateQueue = b, b.lastEffect = a.next = a) : (c = b.lastEffect, null === c ? b.lastEffect = a.next = a : (d = c.next, c.next = a, a.next = d, b.lastEffect = a));
return a;
}
function ji() {
return Uh().memoizedState;
}
function ki(a, b, c, d) {
var e = Th();
M$1.flags |= a;
e.memoizedState = bi(1 | b, c, void 0, void 0 === d ? null : d);
}
function li(a, b, c, d) {
var e = Uh();
d = void 0 === d ? null : d;
var f2 = void 0;
if (null !== N) {
var g = N.memoizedState;
f2 = g.destroy;
if (null !== d && Mh(d, g.deps)) {
e.memoizedState = bi(b, c, f2, d);
return;
}
}
M$1.flags |= a;
e.memoizedState = bi(1 | b, c, f2, d);
}
function mi(a, b) {
return ki(8390656, 8, a, b);
}
function $h(a, b) {
return li(2048, 8, a, b);
}
function ni(a, b) {
return li(4, 2, a, b);
}
function oi(a, b) {
return li(4, 4, a, b);
}
function pi(a, b) {
if ("function" === typeof b) return a = a(), b(a), function() {
b(null);
};
if (null !== b && void 0 !== b) return a = a(), b.current = a, function() {
b.current = null;
};
}
function qi(a, b, c) {
c = null !== c && void 0 !== c ? c.concat([a]) : null;
return li(4, 4, pi.bind(null, b, a), c);
}
function ri() {
}
function si(a, b) {
var c = Uh();
b = void 0 === b ? null : b;
var d = c.memoizedState;
if (null !== d && null !== b && Mh(b, d[1])) return d[0];
c.memoizedState = [a, b];
return a;
}
function ti(a, b) {
var c = Uh();
b = void 0 === b ? null : b;
var d = c.memoizedState;
if (null !== d && null !== b && Mh(b, d[1])) return d[0];
a = a();
c.memoizedState = [a, b];
return a;
}
function ui(a, b, c) {
if (0 === (Hh & 21)) return a.baseState && (a.baseState = false, dh = true), a.memoizedState = c;
He(c, b) || (c = yc(), M$1.lanes |= c, rh |= c, a.baseState = true);
return b;
}
function vi(a, b) {
var c = C;
C = 0 !== c && 4 > c ? c : 4;
a(true);
var d = Gh.transition;
Gh.transition = {};
try {
a(false), b();
} finally {
C = c, Gh.transition = d;
}
}
function wi() {
return Uh().memoizedState;
}
function xi(a, b, c) {
var d = yi(a);
c = { lane: d, action: c, hasEagerState: false, eagerState: null, next: null };
if (zi(a)) Ai(b, c);
else if (c = hh(a, b, c, d), null !== c) {
var e = R();
gi(c, a, d, e);
Bi(c, b, d);
}
}
function ii(a, b, c) {
var d = yi(a), e = { lane: d, action: c, hasEagerState: false, eagerState: null, next: null };
if (zi(a)) Ai(b, e);
else {
var f2 = a.alternate;
if (0 === a.lanes && (null === f2 || 0 === f2.lanes) && (f2 = b.lastRenderedReducer, null !== f2)) try {
var g = b.lastRenderedState, h = f2(g, c);
e.hasEagerState = true;
e.eagerState = h;
if (He(h, g)) {
var k2 = b.interleaved;
null === k2 ? (e.next = e, gh(b)) : (e.next = k2.next, k2.next = e);
b.interleaved = e;
return;
}
} catch (l2) {
} finally {
}
c = hh(a, b, e, d);
null !== c && (e = R(), gi(c, a, d, e), Bi(c, b, d));
}
}
function zi(a) {
var b = a.alternate;
return a === M$1 || null !== b && b === M$1;
}
function Ai(a, b) {
Jh = Ih = true;
var c = a.pending;
null === c ? b.next = b : (b.next = c.next, c.next = b);
a.pending = b;
}
function Bi(a, b, c) {
if (0 !== (c & 4194240)) {
var d = b.lanes;
d &= a.pendingLanes;
c |= d;
b.lanes = c;
Cc(a, c);
}
}
var Rh = { readContext: eh, useCallback: P$1, useContext: P$1, useEffect: P$1, useImperativeHandle: P$1, useInsertionEffect: P$1, useLayoutEffect: P$1, useMemo: P$1, useReducer: P$1, useRef: P$1, useState: P$1, useDebugValue: P$1, useDeferredValue: P$1, useTransition: P$1, useMutableSource: P$1, useSyncExternalStore: P$1, useId: P$1, unstable_isNewReconciler: false }, Oh = { readContext: eh, useCallback: function(a, b) {
Th().memoizedState = [a, void 0 === b ? null : b];
return a;
}, useContext: eh, useEffect: mi, useImperativeHandle: function(a, b, c) {
c = null !== c && void 0 !== c ? c.concat([a]) : null;
return ki(
4194308,
4,
pi.bind(null, b, a),
c
);
}, useLayoutEffect: function(a, b) {
return ki(4194308, 4, a, b);
}, useInsertionEffect: function(a, b) {
return ki(4, 2, a, b);
}, useMemo: function(a, b) {
var c = Th();
b = void 0 === b ? null : b;
a = a();
c.memoizedState = [a, b];
return a;
}, useReducer: function(a, b, c) {
var d = Th();
b = void 0 !== c ? c(b) : b;
d.memoizedState = d.baseState = b;
a = { pending: null, interleaved: null, lanes: 0, dispatch: null, lastRenderedReducer: a, lastRenderedState: b };
d.queue = a;
a = a.dispatch = xi.bind(null, M$1, a);
return [d.memoizedState, a];
}, useRef: function(a) {
var b = Th();
a = { current: a };
return b.memoizedState = a;
}, useState: hi, useDebugValue: ri, useDeferredValue: function(a) {
return Th().memoizedState = a;
}, useTransition: function() {
var a = hi(false), b = a[0];
a = vi.bind(null, a[1]);
Th().memoizedState = a;
return [b, a];
}, useMutableSource: function() {
}, useSyncExternalStore: function(a, b, c) {
var d = M$1, e = Th();
if (I) {
if (void 0 === c) throw Error(p(407));
c = c();
} else {
c = b();
if (null === Q) throw Error(p(349));
0 !== (Hh & 30) || di(d, b, c);
}
e.memoizedState = c;
var f2 = { value: c, getSnapshot: b };
e.queue = f2;
mi(ai.bind(
null,
d,
f2,
a
), [a]);
d.flags |= 2048;
bi(9, ci.bind(null, d, f2, c, b), void 0, null);
return c;
}, useId: function() {
var a = Th(), b = Q.identifierPrefix;
if (I) {
var c = sg;
var d = rg;
c = (d & ~(1 << 32 - oc(d) - 1)).toString(32) + c;
b = ":" + b + "R" + c;
c = Kh++;
0 < c && (b += "H" + c.toString(32));
b += ":";
} else c = Lh++, b = ":" + b + "r" + c.toString(32) + ":";
return a.memoizedState = b;
}, unstable_isNewReconciler: false }, Ph = {
readContext: eh,
useCallback: si,
useContext: eh,
useEffect: $h,
useImperativeHandle: qi,
useInsertionEffect: ni,
useLayoutEffect: oi,
useMemo: ti,
useReducer: Wh,
useRef: ji,
useState: function() {
return Wh(Vh);
},
useDebugValue: ri,
useDeferredValue: function(a) {
var b = Uh();
return ui(b, N.memoizedState, a);
},
useTransition: function() {
var a = Wh(Vh)[0], b = Uh().memoizedState;
return [a, b];
},
useMutableSource: Yh,
useSyncExternalStore: Zh,
useId: wi,
unstable_isNewReconciler: false
}, Qh = { readContext: eh, useCallback: si, useContext: eh, useEffect: $h, useImperativeHandle: qi, useInsertionEffect: ni, useLayoutEffect: oi, useMemo: ti, useReducer: Xh, useRef: ji, useState: function() {
return Xh(Vh);
}, useDebugValue: ri, useDeferredValue: function(a) {
var b = Uh();
return null === N ? b.memoizedState = a : ui(b, N.memoizedState, a);
}, useTransition: function() {
var a = Xh(Vh)[0], b = Uh().memoizedState;
return [a, b];
}, useMutableSource: Yh, useSyncExternalStore: Zh, useId: wi, unstable_isNewReconciler: false };
function Ci(a, b) {
if (a && a.defaultProps) {
b = A({}, b);
a = a.defaultProps;
for (var c in a) void 0 === b[c] && (b[c] = a[c]);
return b;
}
return b;
}
function Di(a, b, c, d) {
b = a.memoizedState;
c = c(d, b);
c = null === c || void 0 === c ? b : A({}, b, c);
a.memoizedState = c;
0 === a.lanes && (a.updateQueue.baseState = c);
}
var Ei = { isMounted: function(a) {
return (a = a._reactInternals) ? Vb(a) === a : false;
}, enqueueSetState: function(a, b, c) {
a = a._reactInternals;
var d = R(), e = yi(a), f2 = mh(d, e);
f2.payload = b;
void 0 !== c && null !== c && (f2.callback = c);
b = nh(a, f2, e);
null !== b && (gi(b, a, e, d), oh(b, a, e));
}, enqueueReplaceState: function(a, b, c) {
a = a._reactInternals;
var d = R(), e = yi(a), f2 = mh(d, e);
f2.tag = 1;
f2.payload = b;
void 0 !== c && null !== c && (f2.callback = c);
b = nh(a, f2, e);
null !== b && (gi(b, a, e, d), oh(b, a, e));
}, enqueueForceUpdate: function(a, b) {
a = a._reactInternals;
var c = R(), d = yi(a), e = mh(c, d);
e.tag = 2;
void 0 !== b && null !== b && (e.callback = b);
b = nh(a, e, d);
null !== b && (gi(b, a, d, c), oh(b, a, d));
} };
function Fi(a, b, c, d, e, f2, g) {
a = a.stateNode;
return "function" === typeof a.shouldComponentUpdate ? a.shouldComponentUpdate(d, f2, g) : b.prototype && b.prototype.isPureReactComponent ? !Ie(c, d) || !Ie(e, f2) : true;
}
function Gi(a, b, c) {
var d = false, e = Vf;
var f2 = b.contextType;
"object" === typeof f2 && null !== f2 ? f2 = eh(f2) : (e = Zf(b) ? Xf : H.current, d = b.contextTypes, f2 = (d = null !== d && void 0 !== d) ? Yf(a, e) : Vf);
b = new b(c, f2);
a.memoizedState = null !== b.state && void 0 !== b.state ? b.state : null;
b.updater = Ei;
a.stateNode = b;
b._reactInternals = a;
d && (a = a.stateNode, a.__reactInternalMemoizedUnmaskedChildContext = e, a.__reactInternalMemoizedMaskedChildContext = f2);
return b;
}
function Hi(a, b, c, d) {
a = b.state;
"function" === typeof b.componentWillReceiveProps && b.componentWillReceiveProps(c, d);
"function" === typeof b.UNSAFE_componentWillReceiveProps && b.UNSAFE_componentWillReceiveProps(c, d);
b.state !== a && Ei.enqueueReplaceState(b, b.state, null);
}
function Ii(a, b, c, d) {
var e = a.stateNode;
e.props = c;
e.state = a.memoizedState;
e.refs = {};
kh(a);
var f2 = b.contextType;
"object" === typeof f2 && null !== f2 ? e.context = eh(f2) : (f2 = Zf(b) ? Xf : H.current, e.context = Yf(a, f2));
e.state = a.memoizedState;
f2 = b.getDerivedStateFromProps;
"function" === typeof f2 && (Di(a, b, f2, c), e.state = a.memoizedState);
"function" === typeof b.getDerivedStateFromProps || "function" === typeof e.getSnapshotBeforeUpdate || "function" !== typeof e.UNSAFE_componentWillMount && "function" !== typeof e.componentWillMount || (b = e.state, "function" === typeof e.componentWillMount && e.componentWillMount(), "function" === typeof e.UNSAFE_componentWillMount && e.UNSAFE_componentWillMount(), b !== e.state && Ei.enqueueReplaceState(e, e.state, null), qh(a, c, e, d), e.state = a.memoizedState);
"function" === typeof e.componentDidMount && (a.flags |= 4194308);
}
function Ji(a, b) {
try {
var c = "", d = b;
do
c += Pa(d), d = d.return;
while (d);
var e = c;
} catch (f2) {
e = "\nError generating stack: " + f2.message + "\n" + f2.stack;
}
return { value: a, source: b, stack: e, digest: null };
}
function Ki(a, b, c) {
return { value: a, source: null, stack: null != c ? c : null, digest: null != b ? b : null };
}
function Li(a, b) {
try {
console.error(b.value);
} catch (c) {
setTimeout(function() {
throw c;
});
}
}
var Mi = "function" === typeof WeakMap ? WeakMap : Map;
function Ni(a, b, c) {
c = mh(-1, c);
c.tag = 3;
c.payload = { element: null };
var d = b.value;
c.callback = function() {
Oi || (Oi = true, Pi = d);
Li(a, b);
};
return c;
}
function Qi(a, b, c) {
c = mh(-1, c);
c.tag = 3;
var d = a.type.getDerivedStateFromError;
if ("function" === typeof d) {
var e = b.value;
c.payload = function() {
return d(e);
};
c.callback = function() {
Li(a, b);
};
}
var f2 = a.stateNode;
null !== f2 && "function" === typeof f2.componentDidCatch && (c.callback = function() {
Li(a, b);
"function" !== typeof d && (null === Ri ? Ri = /* @__PURE__ */ new Set([this]) : Ri.add(this));
var c2 = b.stack;
this.componentDidCatch(b.value, { componentStack: null !== c2 ? c2 : "" });
});
return c;
}
function Si(a, b, c) {
var d = a.pingCache;
if (null === d) {
d = a.pingCache = new Mi();
var e = /* @__PURE__ */ new Set();
d.set(b, e);
} else e = d.get(b), void 0 === e && (e = /* @__PURE__ */ new Set(), d.set(b, e));
e.has(c) || (e.add(c), a = Ti.bind(null, a, b, c), b.then(a, a));
}
function Ui(a) {
do {
var b;
if (b = 13 === a.tag) b = a.memoizedState, b = null !== b ? null !== b.dehydrated ? true : false : true;
if (b) return a;
a = a.return;
} while (null !== a);
return null;
}
function Vi(a, b, c, d, e) {
if (0 === (a.mode & 1)) return a === b ? a.flags |= 65536 : (a.flags |= 128, c.flags |= 131072, c.flags &= -52805, 1 === c.tag && (null === c.alternate ? c.tag = 17 : (b = mh(-1, 1), b.tag = 2, nh(c, b, 1))), c.lanes |= 1), a;
a.flags |= 65536;
a.lanes = e;
return a;
}
var Wi = ua.ReactCurrentOwner, dh = false;
function Xi(a, b, c, d) {
b.child = null === a ? Vg(b, null, c, d) : Ug(b, a.child, c, d);
}
function Yi(a, b, c, d, e) {
c = c.render;
var f2 = b.ref;
ch(b, e);
d = Nh(a, b, c, d, f2, e);
c = Sh();
if (null !== a && !dh) return b.updateQueue = a.updateQueue, b.flags &= -2053, a.lanes &= ~e, Zi(a, b, e);
I && c && vg(b);
b.flags |= 1;
Xi(a, b, d, e);
return b.child;
}
function $i(a, b, c, d, e) {
if (null === a) {
var f2 = c.type;
if ("function" === typeof f2 && !aj(f2) && void 0 === f2.defaultProps && null === c.compare && void 0 === c.defaultProps) return b.tag = 15, b.type = f2, bj(a, b, f2, d, e);
a = Rg(c.type, null, d, b, b.mode, e);
a.ref = b.ref;
a.return = b;
return b.child = a;
}
f2 = a.child;
if (0 === (a.lanes & e)) {
var g = f2.memoizedProps;
c = c.compare;
c = null !== c ? c : Ie;
if (c(g, d) && a.ref === b.ref) return Zi(a, b, e);
}
b.flags |= 1;
a = Pg(f2, d);
a.ref = b.ref;
a.return = b;
return b.child = a;
}
function bj(a, b, c, d, e) {
if (null !== a) {
var f2 = a.memoizedProps;
if (Ie(f2, d) && a.ref === b.ref) if (dh = false, b.pendingProps = d = f2, 0 !== (a.lanes & e)) 0 !== (a.flags & 131072) && (dh = true);
else return b.lanes = a.lanes, Zi(a, b, e);
}
return cj(a, b, c, d, e);
}
function dj(a, b, c) {
var d = b.pendingProps, e = d.children, f2 = null !== a ? a.memoizedState : null;
if ("hidden" === d.mode) if (0 === (b.mode & 1)) b.memoizedState = { baseLanes: 0, cachePool: null, transitions: null }, G(ej, fj), fj |= c;
else {
if (0 === (c & 1073741824)) return a = null !== f2 ? f2.baseLanes | c : c, b.lanes = b.childLanes = 1073741824, b.memoizedState = { baseLanes: a, cachePool: null, transitions: null }, b.updateQueue = null, G(ej, fj), fj |= a, null;
b.memoizedState = { baseLanes: 0, cachePool: null, transitions: null };
d = null !== f2 ? f2.baseLanes : c;
G(ej, fj);
fj |= d;
}
else null !== f2 ? (d = f2.baseLanes | c, b.memoizedState = null) : d = c, G(ej, fj), fj |= d;
Xi(a, b, e, c);
return b.child;
}
function gj(a, b) {
var c = b.ref;
if (null === a && null !== c || null !== a && a.ref !== c) b.flags |= 512, b.flags |= 2097152;
}
function cj(a, b, c, d, e) {
var f2 = Zf(c) ? Xf : H.current;
f2 = Yf(b, f2);
ch(b, e);
c = Nh(a, b, c, d, f2, e);
d = Sh();
if (null !== a && !dh) return b.updateQueue = a.updateQueue, b.flags &= -2053, a.lanes &= ~e, Zi(a, b, e);
I && d && vg(b);
b.flags |= 1;
Xi(a, b, c, e);
return b.child;
}
function hj(a, b, c, d, e) {
if (Zf(c)) {
var f2 = true;
cg(b);
} else f2 = false;
ch(b, e);
if (null === b.stateNode) ij(a, b), Gi(b, c, d), Ii(b, c, d, e), d = true;
else if (null === a) {
var g = b.stateNode, h = b.memoizedProps;
g.props = h;
var k2 = g.context, l2 = c.contextType;
"object" === typeof l2 && null !== l2 ? l2 = eh(l2) : (l2 = Zf(c) ? Xf : H.current, l2 = Yf(b, l2));
var m2 = c.getDerivedStateFromProps, q2 = "function" === typeof m2 || "function" === typeof g.getSnapshotBeforeUpdate;
q2 || "function" !== typeof g.UNSAFE_componentWillReceiveProps && "function" !== typeof g.componentWillReceiveProps || (h !== d || k2 !== l2) && Hi(b, g, d, l2);
jh = false;
var r2 = b.memoizedState;
g.state = r2;
qh(b, d, g, e);
k2 = b.memoizedState;
h !== d || r2 !== k2 || Wf.current || jh ? ("function" === typeof m2 && (Di(b, c, m2, d), k2 = b.memoizedState), (h = jh || Fi(b, c, h, d, r2, k2, l2)) ? (q2 || "function" !== typeof g.UNSAFE_componentWillMount && "function" !== typeof g.componentWillMount || ("function" === typeof g.componentWillMount && g.componentWillMount(), "function" === typeof g.UNSAFE_componentWillMount && g.UNSAFE_componentWillMount()), "function" === typeof g.componentDidMount && (b.flags |= 4194308)) : ("function" === typeof g.componentDidMount && (b.flags |= 4194308), b.memoizedProps = d, b.memoizedState = k2), g.props = d, g.state = k2, g.context = l2, d = h) : ("function" === typeof g.componentDidMount && (b.flags |= 4194308), d = false);
} else {
g = b.stateNode;
lh(a, b);
h = b.memoizedProps;
l2 = b.type === b.elementType ? h : Ci(b.type, h);
g.props = l2;
q2 = b.pendingProps;
r2 = g.context;
k2 = c.contextType;
"object" === typeof k2 && null !== k2 ? k2 = eh(k2) : (k2 = Zf(c) ? Xf : H.current, k2 = Yf(b, k2));
var y2 = c.getDerivedStateFromProps;
(m2 = "function" === typeof y2 || "function" === typeof g.getSnapshotBeforeUpdate) || "function" !== typeof g.UNSAFE_componentWillReceiveProps && "function" !== typeof g.componentWillReceiveProps || (h !== q2 || r2 !== k2) && Hi(b, g, d, k2);
jh = false;
r2 = b.memoizedState;
g.state = r2;
qh(b, d, g, e);
var n2 = b.memoizedState;
h !== q2 || r2 !== n2 || Wf.current || jh ? ("function" === typeof y2 && (Di(b, c, y2, d), n2 = b.memoizedState), (l2 = jh || Fi(b, c, l2, d, r2, n2, k2) || false) ? (m2 || "function" !== typeof g.UNSAFE_componentWillUpdate && "function" !== typeof g.componentWillUpdate || ("function" === typeof g.componentWillUpdate && g.componentWillUpdate(d, n2, k2), "function" === typeof g.UNSAFE_componentWillUpdate && g.UNSAFE_componentWillUpdate(d, n2, k2)), "function" === typeof g.componentDidUpdate && (b.flags |= 4), "function" === typeof g.getSnapshotBeforeUpdate && (b.flags |= 1024)) : ("function" !== typeof g.componentDidUpdate || h === a.memoizedProps && r2 === a.memoizedState || (b.flags |= 4), "function" !== typeof g.getSnapshotBeforeUpdate || h === a.memoizedProps && r2 === a.memoizedState || (b.flags |= 1024), b.memoizedProps = d, b.memoizedState = n2), g.props = d, g.state = n2, g.context = k2, d = l2) : ("function" !== typeof g.componentDidUpdate || h === a.memoizedProps && r2 === a.memoizedState || (b.flags |= 4), "function" !== typeof g.getSnapshotBeforeUpdate || h === a.memoizedProps && r2 === a.memoizedState || (b.flags |= 1024), d = false);
}
return jj(a, b, c, d, f2, e);
}
function jj(a, b, c, d, e, f2) {
gj(a, b);
var g = 0 !== (b.flags & 128);
if (!d && !g) return e && dg(b, c, false), Zi(a, b, f2);
d = b.stateNode;
Wi.current = b;
var h = g && "function" !== typeof c.getDerivedStateFromError ? null : d.render();
b.flags |= 1;
null !== a && g ? (b.child = Ug(b, a.child, null, f2), b.child = Ug(b, null, h, f2)) : Xi(a, b, h, f2);
b.memoizedState = d.state;
e && dg(b, c, true);
return b.child;
}
function kj(a) {
var b = a.stateNode;
b.pendingContext ? ag(a, b.pendingContext, b.pendingContext !== b.context) : b.context && ag(a, b.context, false);
yh(a, b.containerInfo);
}
function lj(a, b, c, d, e) {
Ig();
Jg(e);
b.flags |= 256;
Xi(a, b, c, d);
return b.child;
}
var mj = { dehydrated: null, treeContext: null, retryLane: 0 };
function nj(a) {
return { baseLanes: a, cachePool: null, transitions: null };
}
function oj(a, b, c) {
var d = b.pendingProps, e = L$1.current, f2 = false, g = 0 !== (b.flags & 128), h;
(h = g) || (h = null !== a && null === a.memoizedState ? false : 0 !== (e & 2));
if (h) f2 = true, b.flags &= -129;
else if (null === a || null !== a.memoizedState) e |= 1;
G(L$1, e & 1);
if (null === a) {
Eg(b);
a = b.memoizedState;
if (null !== a && (a = a.dehydrated, null !== a)) return 0 === (b.mode & 1) ? b.lanes = 1 : "$!" === a.data ? b.lanes = 8 : b.lanes = 1073741824, null;
g = d.children;
a = d.fallback;
return f2 ? (d = b.mode, f2 = b.child, g = { mode: "hidden", children: g }, 0 === (d & 1) && null !== f2 ? (f2.childLanes = 0, f2.pendingProps = g) : f2 = pj(g, d, 0, null), a = Tg(a, d, c, null), f2.return = b, a.return = b, f2.sibling = a, b.child = f2, b.child.memoizedState = nj(c), b.memoizedState = mj, a) : qj(b, g);
}
e = a.memoizedState;
if (null !== e && (h = e.dehydrated, null !== h)) return rj(a, b, g, d, h, e, c);
if (f2) {
f2 = d.fallback;
g = b.mode;
e = a.child;
h = e.sibling;
var k2 = { mode: "hidden", children: d.children };
0 === (g & 1) && b.child !== e ? (d = b.child, d.childLanes = 0, d.pendingProps = k2, b.deletions = null) : (d = Pg(e, k2), d.subtreeFlags = e.subtreeFlags & 14680064);
null !== h ? f2 = Pg(h, f2) : (f2 = Tg(f2, g, c, null), f2.flags |= 2);
f2.return = b;
d.return = b;
d.sibling = f2;
b.child = d;
d = f2;
f2 = b.child;
g = a.child.memoizedState;
g = null === g ? nj(c) : { baseLanes: g.baseLanes | c, cachePool: null, transitions: g.transitions };
f2.memoizedState = g;
f2.childLanes = a.childLanes & ~c;
b.memoizedState = mj;
return d;
}
f2 = a.child;
a = f2.sibling;
d = Pg(f2, { mode: "visible", children: d.children });
0 === (b.mode & 1) && (d.lanes = c);
d.return = b;
d.sibling = null;
null !== a && (c = b.deletions, null === c ? (b.deletions = [a], b.flags |= 16) : c.push(a));
b.child = d;
b.memoizedState = null;
return d;
}
function qj(a, b) {
b = pj({ mode: "visible", children: b }, a.mode, 0, null);
b.return = a;
return a.child = b;
}
function sj(a, b, c, d) {
null !== d && Jg(d);
Ug(b, a.child, null, c);
a = qj(b, b.pendingProps.children);
a.flags |= 2;
b.memoizedState = null;
return a;
}
function rj(a, b, c, d, e, f2, g) {
if (c) {
if (b.flags & 256) return b.flags &= -257, d = Ki(Error(p(422))), sj(a, b, g, d);
if (null !== b.memoizedState) return b.child = a.child, b.flags |= 128, null;
f2 = d.fallback;
e = b.mode;
d = pj({ mode: "visible", children: d.children }, e, 0, null);
f2 = Tg(f2, e, g, null);
f2.flags |= 2;
d.return = b;
f2.return = b;
d.sibling = f2;
b.child = d;
0 !== (b.mode & 1) && Ug(b, a.child, null, g);
b.child.memoizedState = nj(g);
b.memoizedState = mj;
return f2;
}
if (0 === (b.mode & 1)) return sj(a, b, g, null);
if ("$!" === e.data) {
d = e.nextSibling && e.nextSibling.dataset;
if (d) var h = d.dgst;
d = h;
f2 = Error(p(419));
d = Ki(f2, d, void 0);
return sj(a, b, g, d);
}
h = 0 !== (g & a.childLanes);
if (dh || h) {
d = Q;
if (null !== d) {
switch (g & -g) {
case 4:
e = 2;
break;
case 16:
e = 8;
break;
case 64:
case 128:
case 256:
case 512:
case 1024:
case 2048:
case 4096:
case 8192:
case 16384:
case 32768:
case 65536:
case 131072:
case 262144:
case 524288:
case 1048576:
case 2097152:
case 4194304:
case 8388608:
case 16777216:
case 33554432:
case 67108864:
e = 32;
break;
case 536870912:
e = 268435456;
break;
default:
e = 0;
}
e = 0 !== (e & (d.suspendedLanes | g)) ? 0 : e;
0 !== e && e !== f2.retryLane && (f2.retryLane = e, ih(a, e), gi(d, a, e, -1));
}
tj();
d = Ki(Error(p(421)));
return sj(a, b, g, d);
}
if ("$?" === e.data) return b.flags |= 128, b.child = a.child, b = uj.bind(null, a), e._reactRetry = b, null;
a = f2.treeContext;
yg = Lf(e.nextSibling);
xg = b;
I = true;
zg = null;
null !== a && (og[pg++] = rg, og[pg++] = sg, og[pg++] = qg, rg = a.id, sg = a.overflow, qg = b);
b = qj(b, d.children);
b.flags |= 4096;
return b;
}
function vj(a, b, c) {
a.lanes |= b;
var d = a.alternate;
null !== d && (d.lanes |= b);
bh(a.return, b, c);
}
function wj(a, b, c, d, e) {
var f2 = a.memoizedState;
null === f2 ? a.memoizedState = { isBackwards: b, rendering: null, renderingStartTime: 0, last: d, tail: c, tailMode: e } : (f2.isBackwards = b, f2.rendering = null, f2.renderingStartTime = 0, f2.last = d, f2.tail = c, f2.tailMode = e);
}
function xj(a, b, c) {
var d = b.pendingProps, e = d.revealOrder, f2 = d.tail;
Xi(a, b, d.children, c);
d = L$1.current;
if (0 !== (d & 2)) d = d & 1 | 2, b.flags |= 128;
else {
if (null !== a && 0 !== (a.flags & 128)) a: for (a = b.child; null !== a; ) {
if (13 === a.tag) null !== a.memoizedState && vj(a, c, b);
else if (19 === a.tag) vj(a, c, b);
else if (null !== a.child) {
a.child.return = a;
a = a.child;
continue;
}
if (a === b) break a;
for (; null === a.sibling; ) {
if (null === a.return || a.return === b) break a;
a = a.return;
}
a.sibling.return = a.return;
a = a.sibling;
}
d &= 1;
}
G(L$1, d);
if (0 === (b.mode & 1)) b.memoizedState = null;
else switch (e) {
case "forwards":
c = b.child;
for (e = null; null !== c; ) a = c.alternate, null !== a && null === Ch(a) && (e = c), c = c.sibling;
c = e;
null === c ? (e = b.child, b.child = null) : (e = c.sibling, c.sibling = null);
wj(b, false, e, c, f2);
break;
case "backwards":
c = null;
e = b.child;
for (b.child = null; null !== e; ) {
a = e.alternate;
if (null !== a && null === Ch(a)) {
b.child = e;
break;
}
a = e.sibling;
e.sibling = c;
c = e;
e = a;
}
wj(b, true, c, null, f2);
break;
case "together":
wj(b, false, null, null, void 0);
break;
default:
b.memoizedState = null;
}
return b.child;
}
function ij(a, b) {
0 === (b.mode & 1) && null !== a && (a.alternate = null, b.alternate = null, b.flags |= 2);
}
function Zi(a, b, c) {
null !== a && (b.dependencies = a.dependencies);
rh |= b.lanes;
if (0 === (c & b.childLanes)) return null;
if (null !== a && b.child !== a.child) throw Error(p(153));
if (null !== b.child) {
a = b.child;
c = Pg(a, a.pendingProps);
b.child = c;
for (c.return = b; null !== a.sibling; ) a = a.sibling, c = c.sibling = Pg(a, a.pendingProps), c.return = b;
c.sibling = null;
}
return b.child;
}
function yj(a, b, c) {
switch (b.tag) {
case 3:
kj(b);
Ig();
break;
case 5:
Ah(b);
break;
case 1:
Zf(b.type) && cg(b);
break;
case 4:
yh(b, b.stateNode.containerInfo);
break;
case 10:
var d = b.type._context, e = b.memoizedProps.value;
G(Wg, d._currentValue);
d._currentValue = e;
break;
case 13:
d = b.memoizedState;
if (null !== d) {
if (null !== d.dehydrated) return G(L$1, L$1.current & 1), b.flags |= 128, null;
if (0 !== (c & b.child.childLanes)) return oj(a, b, c);
G(L$1, L$1.current & 1);
a = Zi(a, b, c);
return null !== a ? a.sibling : null;
}
G(L$1, L$1.current & 1);
break;
case 19:
d = 0 !== (c & b.childLanes);
if (0 !== (a.flags & 128)) {
if (d) return xj(a, b, c);
b.flags |= 128;
}
e = b.memoizedState;
null !== e && (e.rendering = null, e.tail = null, e.lastEffect = null);
G(L$1, L$1.current);
if (d) break;
else return null;
case 22:
case 23:
return b.lanes = 0, dj(a, b, c);
}
return Zi(a, b, c);
}
var zj, Aj, Bj, Cj;
zj = function(a, b) {
for (var c = b.child; null !== c; ) {
if (5 === c.tag || 6 === c.tag) a.appendChild(c.stateNode);
else if (4 !== c.tag && null !== c.child) {
c.child.return = c;
c = c.child;
continue;
}
if (c === b) break;
for (; null === c.sibling; ) {
if (null === c.return || c.return === b) return;
c = c.return;
}
c.sibling.return = c.return;
c = c.sibling;
}
};
Aj = function() {
};
Bj = function(a, b, c, d) {
var e = a.memoizedProps;
if (e !== d) {
a = b.stateNode;
xh(uh.current);
var f2 = null;
switch (c) {
case "input":
e = Ya(a, e);
d = Ya(a, d);
f2 = [];
break;
case "select":
e = A({}, e, { value: void 0 });
d = A({}, d, { value: void 0 });
f2 = [];
break;
case "textarea":
e = gb(a, e);
d = gb(a, d);
f2 = [];
break;
default:
"function" !== typeof e.onClick && "function" === typeof d.onClick && (a.onclick = Bf);
}
ub(c, d);
var g;
c = null;
for (l2 in e) if (!d.hasOwnProperty(l2) && e.hasOwnProperty(l2) && null != e[l2]) if ("style" === l2) {
var h = e[l2];
for (g in h) h.hasOwnProperty(g) && (c || (c = {}), c[g] = "");
} else "dangerouslySetInnerHTML" !== l2 && "children" !== l2 && "suppressContentEditableWarning" !== l2 && "suppressHydrationWarning" !== l2 && "autoFocus" !== l2 && (ea.hasOwnProperty(l2) ? f2 || (f2 = []) : (f2 = f2 || []).push(l2, null));
for (l2 in d) {
var k2 = d[l2];
h = null != e ? e[l2] : void 0;
if (d.hasOwnProperty(l2) && k2 !== h && (null != k2 || null != h)) if ("style" === l2) if (h) {
for (g in h) !h.hasOwnProperty(g) || k2 && k2.hasOwnProperty(g) || (c || (c = {}), c[g] = "");
for (g in k2) k2.hasOwnProperty(g) && h[g] !== k2[g] && (c || (c = {}), c[g] = k2[g]);
} else c || (f2 || (f2 = []), f2.push(
l2,
c
)), c = k2;
else "dangerouslySetInnerHTML" === l2 ? (k2 = k2 ? k2.__html : void 0, h = h ? h.__html : void 0, null != k2 && h !== k2 && (f2 = f2 || []).push(l2, k2)) : "children" === l2 ? "string" !== typeof k2 && "number" !== typeof k2 || (f2 = f2 || []).push(l2, "" + k2) : "suppressContentEditableWarning" !== l2 && "suppressHydrationWarning" !== l2 && (ea.hasOwnProperty(l2) ? (null != k2 && "onScroll" === l2 && D$1("scroll", a), f2 || h === k2 || (f2 = [])) : (f2 = f2 || []).push(l2, k2));
}
c && (f2 = f2 || []).push("style", c);
var l2 = f2;
if (b.updateQueue = l2) b.flags |= 4;
}
};
Cj = function(a, b, c, d) {
c !== d && (b.flags |= 4);
};
function Dj(a, b) {
if (!I) switch (a.tailMode) {
case "hidden":
b = a.tail;
for (var c = null; null !== b; ) null !== b.alternate && (c = b), b = b.sibling;
null === c ? a.tail = null : c.sibling = null;
break;
case "collapsed":
c = a.tail;
for (var d = null; null !== c; ) null !== c.alternate && (d = c), c = c.sibling;
null === d ? b || null === a.tail ? a.tail = null : a.tail.sibling = null : d.sibling = null;
}
}
function S(a) {
var b = null !== a.alternate && a.alternate.child === a.child, c = 0, d = 0;
if (b) for (var e = a.child; null !== e; ) c |= e.lanes | e.childLanes, d |= e.subtreeFlags & 14680064, d |= e.flags & 14680064, e.return = a, e = e.sibling;
else for (e = a.child; null !== e; ) c |= e.lanes | e.childLanes, d |= e.subtreeFlags, d |= e.flags, e.return = a, e = e.sibling;
a.subtreeFlags |= d;
a.childLanes = c;
return b;
}
function Ej(a, b, c) {
var d = b.pendingProps;
wg(b);
switch (b.tag) {
case 2:
case 16:
case 15:
case 0:
case 11:
case 7:
case 8:
case 12:
case 9:
case 14:
return S(b), null;
case 1:
return Zf(b.type) && $f(), S(b), null;
case 3:
d = b.stateNode;
zh();
E$1(Wf);
E$1(H);
Eh();
d.pendingContext && (d.context = d.pendingContext, d.pendingContext = null);
if (null === a || null === a.child) Gg(b) ? b.flags |= 4 : null === a || a.memoizedState.isDehydrated && 0 === (b.flags & 256) || (b.flags |= 1024, null !== zg && (Fj(zg), zg = null));
Aj(a, b);
S(b);
return null;
case 5:
Bh(b);
var e = xh(wh.current);
c = b.type;
if (null !== a && null != b.stateNode) Bj(a, b, c, d, e), a.ref !== b.ref && (b.flags |= 512, b.flags |= 2097152);
else {
if (!d) {
if (null === b.stateNode) throw Error(p(166));
S(b);
return null;
}
a = xh(uh.current);
if (Gg(b)) {
d = b.stateNode;
c = b.type;
var f2 = b.memoizedProps;
d[Of] = b;
d[Pf] = f2;
a = 0 !== (b.mode & 1);
switch (c) {
case "dialog":
D$1("cancel", d);
D$1("close", d);
break;
case "iframe":
case "object":
case "embed":
D$1("load", d);
break;
case "video":
case "audio":
for (e = 0; e < lf.length; e++) D$1(lf[e], d);
break;
case "source":
D$1("error", d);
break;
case "img":
case "image":
case "link":
D$1(
"error",
d
);
D$1("load", d);
break;
case "details":
D$1("toggle", d);
break;
case "input":
Za(d, f2);
D$1("invalid", d);
break;
case "select":
d._wrapperState = { wasMultiple: !!f2.multiple };
D$1("invalid", d);
break;
case "textarea":
hb(d, f2), D$1("invalid", d);
}
ub(c, f2);
e = null;
for (var g in f2) if (f2.hasOwnProperty(g)) {
var h = f2[g];
"children" === g ? "string" === typeof h ? d.textContent !== h && (true !== f2.suppressHydrationWarning && Af(d.textContent, h, a), e = ["children", h]) : "number" === typeof h && d.textContent !== "" + h && (true !== f2.suppressHydrationWarning && Af(
d.textContent,
h,
a
), e = ["children", "" + h]) : ea.hasOwnProperty(g) && null != h && "onScroll" === g && D$1("scroll", d);
}
switch (c) {
case "input":
Va(d);
db(d, f2, true);
break;
case "textarea":
Va(d);
jb(d);
break;
case "select":
case "option":
break;
default:
"function" === typeof f2.onClick && (d.onclick = Bf);
}
d = e;
b.updateQueue = d;
null !== d && (b.flags |= 4);
} else {
g = 9 === e.nodeType ? e : e.ownerDocument;
"http://www.w3.org/1999/xhtml" === a && (a = kb(c));
"http://www.w3.org/1999/xhtml" === a ? "script" === c ? (a = g.createElement("div"), a.innerHTML = "").replace(/\/:([\w-]+)(\?)?/g, (_, paramName, isOptional) => {
params.push({
paramName,
isOptional: isOptional != null
});
return isOptional ? "/?([^\\/]+)?" : "/([^\\/]+)";
});
if (path.endsWith("*")) {
params.push({
paramName: "*"
});
regexpSource += path === "*" || path === "/*" ? "(.*)$" : "(?:\\/(.+)|\\/*)$";
} else if (end) {
regexpSource += "\\/*$";
} else if (path !== "" && path !== "/") {
regexpSource += "(?:(?=\\/|$))";
} else ;
let matcher = new RegExp(regexpSource, caseSensitive ? void 0 : "i");
return [matcher, params];
}
function decodePath(value) {
try {
return value.split("/").map((v2) => decodeURIComponent(v2).replace(/\//g, "%2F")).join("/");
} catch (error) {
warning(false, 'The URL path "' + value + '" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent ' + ("encoding (" + error + ")."));
return value;
}
}
function stripBasename(pathname, basename) {
if (basename === "/") return pathname;
if (!pathname.toLowerCase().startsWith(basename.toLowerCase())) {
return null;
}
let startIndex = basename.endsWith("/") ? basename.length - 1 : basename.length;
let nextChar = pathname.charAt(startIndex);
if (nextChar && nextChar !== "/") {
return null;
}
return pathname.slice(startIndex) || "/";
}
const joinPaths = (paths) => paths.join("/").replace(/\/\/+/g, "/");
const normalizePathname = (pathname) => pathname.replace(/\/+$/, "").replace(/^\/*/, "/");
function isRouteErrorResponse(error) {
return error != null && typeof error.status === "number" && typeof error.statusText === "string" && typeof error.internal === "boolean" && "data" in error;
}
const validMutationMethodsArr = ["post", "put", "patch", "delete"];
new Set(validMutationMethodsArr);
const validRequestMethodsArr = ["get", ...validMutationMethodsArr];
new Set(validRequestMethodsArr);
/**
* React Router v6.30.1
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/
function _extends() {
_extends = Object.assign ? Object.assign.bind() : function(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (Object.prototype.hasOwnProperty.call(source, key)) {
target[key] = source[key];
}
}
}
return target;
};
return _extends.apply(this, arguments);
}
const DataRouterContext = /* @__PURE__ */ reactExports.createContext(null);
const DataRouterStateContext = /* @__PURE__ */ reactExports.createContext(null);
const NavigationContext = /* @__PURE__ */ reactExports.createContext(null);
const LocationContext = /* @__PURE__ */ reactExports.createContext(null);
const RouteContext = /* @__PURE__ */ reactExports.createContext({
outlet: null,
matches: [],
isDataRoute: false
});
const RouteErrorContext = /* @__PURE__ */ reactExports.createContext(null);
function useInRouterContext() {
return reactExports.useContext(LocationContext) != null;
}
function useLocation() {
!useInRouterContext() ? invariant(false) : void 0;
return reactExports.useContext(LocationContext).location;
}
function useRoutes(routes, locationArg) {
return useRoutesImpl(routes, locationArg);
}
function useRoutesImpl(routes, locationArg, dataRouterState, future) {
!useInRouterContext() ? invariant(false) : void 0;
let {
navigator: navigator2
} = reactExports.useContext(NavigationContext);
let {
matches: parentMatches
} = reactExports.useContext(RouteContext);
let routeMatch = parentMatches[parentMatches.length - 1];
let parentParams = routeMatch ? routeMatch.params : {};
routeMatch ? routeMatch.pathname : "/";
let parentPathnameBase = routeMatch ? routeMatch.pathnameBase : "/";
routeMatch && routeMatch.route;
let locationFromContext = useLocation();
let location;
if (locationArg) {
var _parsedLocationArg$pa;
let parsedLocationArg = typeof locationArg === "string" ? parsePath(locationArg) : locationArg;
!(parentPathnameBase === "/" || ((_parsedLocationArg$pa = parsedLocationArg.pathname) == null ? void 0 : _parsedLocationArg$pa.startsWith(parentPathnameBase))) ? invariant(false) : void 0;
location = parsedLocationArg;
} else {
location = locationFromContext;
}
let pathname = location.pathname || "/";
let remainingPathname = pathname;
if (parentPathnameBase !== "/") {
let parentSegments = parentPathnameBase.replace(/^\//, "").split("/");
let segments = pathname.replace(/^\//, "").split("/");
remainingPathname = "/" + segments.slice(parentSegments.length).join("/");
}
let matches = matchRoutes(routes, {
pathname: remainingPathname
});
let renderedMatches = _renderMatches(matches && matches.map((match) => Object.assign({}, match, {
params: Object.assign({}, parentParams, match.params),
pathname: joinPaths([
parentPathnameBase,
// Re-encode pathnames that were decoded inside matchRoutes
navigator2.encodeLocation ? navigator2.encodeLocation(match.pathname).pathname : match.pathname
]),
pathnameBase: match.pathnameBase === "/" ? parentPathnameBase : joinPaths([
parentPathnameBase,
// Re-encode pathnames that were decoded inside matchRoutes
navigator2.encodeLocation ? navigator2.encodeLocation(match.pathnameBase).pathname : match.pathnameBase
])
})), parentMatches, dataRouterState, future);
if (locationArg && renderedMatches) {
return /* @__PURE__ */ reactExports.createElement(LocationContext.Provider, {
value: {
location: _extends({
pathname: "/",
search: "",
hash: "",
state: null,
key: "default"
}, location),
navigationType: Action$1.Pop
}
}, renderedMatches);
}
return renderedMatches;
}
function DefaultErrorComponent() {
let error = useRouteError();
let message = isRouteErrorResponse(error) ? error.status + " " + error.statusText : error instanceof Error ? error.message : JSON.stringify(error);
let stack = error instanceof Error ? error.stack : null;
let lightgrey = "rgba(200,200,200, 0.5)";
let preStyles = {
padding: "0.5rem",
backgroundColor: lightgrey
};
let devInfo = null;
return /* @__PURE__ */ reactExports.createElement(reactExports.Fragment, null, /* @__PURE__ */ reactExports.createElement("h2", null, "Unexpected Application Error!"), /* @__PURE__ */ reactExports.createElement("h3", {
style: {
fontStyle: "italic"
}
}, message), stack ? /* @__PURE__ */ reactExports.createElement("pre", {
style: preStyles
}, stack) : null, devInfo);
}
const defaultErrorElement = /* @__PURE__ */ reactExports.createElement(DefaultErrorComponent, null);
class RenderErrorBoundary extends reactExports.Component {
constructor(props) {
super(props);
this.state = {
location: props.location,
revalidation: props.revalidation,
error: props.error
};
}
static getDerivedStateFromError(error) {
return {
error
};
}
static getDerivedStateFromProps(props, state) {
if (state.location !== props.location || state.revalidation !== "idle" && props.revalidation === "idle") {
return {
error: props.error,
location: props.location,
revalidation: props.revalidation
};
}
return {
error: props.error !== void 0 ? props.error : state.error,
location: state.location,
revalidation: props.revalidation || state.revalidation
};
}
componentDidCatch(error, errorInfo) {
console.error("React Router caught the following error during render", error, errorInfo);
}
render() {
return this.state.error !== void 0 ? /* @__PURE__ */ reactExports.createElement(RouteContext.Provider, {
value: this.props.routeContext
}, /* @__PURE__ */ reactExports.createElement(RouteErrorContext.Provider, {
value: this.state.error,
children: this.props.component
})) : this.props.children;
}
}
function RenderedRoute(_ref) {
let {
routeContext,
match,
children
} = _ref;
let dataRouterContext = reactExports.useContext(DataRouterContext);
if (dataRouterContext && dataRouterContext.static && dataRouterContext.staticContext && (match.route.errorElement || match.route.ErrorBoundary)) {
dataRouterContext.staticContext._deepestRenderedBoundaryId = match.route.id;
}
return /* @__PURE__ */ reactExports.createElement(RouteContext.Provider, {
value: routeContext
}, children);
}
function _renderMatches(matches, parentMatches, dataRouterState, future) {
var _dataRouterState;
if (parentMatches === void 0) {
parentMatches = [];
}
if (dataRouterState === void 0) {
dataRouterState = null;
}
if (future === void 0) {
future = null;
}
if (matches == null) {
var _future;
if (!dataRouterState) {
return null;
}
if (dataRouterState.errors) {
matches = dataRouterState.matches;
} else if ((_future = future) != null && _future.v7_partialHydration && parentMatches.length === 0 && !dataRouterState.initialized && dataRouterState.matches.length > 0) {
matches = dataRouterState.matches;
} else {
return null;
}
}
let renderedMatches = matches;
let errors = (_dataRouterState = dataRouterState) == null ? void 0 : _dataRouterState.errors;
if (errors != null) {
let errorIndex = renderedMatches.findIndex((m2) => m2.route.id && (errors == null ? void 0 : errors[m2.route.id]) !== void 0);
!(errorIndex >= 0) ? invariant(false) : void 0;
renderedMatches = renderedMatches.slice(0, Math.min(renderedMatches.length, errorIndex + 1));
}
let renderFallback = false;
let fallbackIndex = -1;
if (dataRouterState && future && future.v7_partialHydration) {
for (let i = 0; i < renderedMatches.length; i++) {
let match = renderedMatches[i];
if (match.route.HydrateFallback || match.route.hydrateFallbackElement) {
fallbackIndex = i;
}
if (match.route.id) {
let {
loaderData,
errors: errors2
} = dataRouterState;
let needsToRunLoader = match.route.loader && loaderData[match.route.id] === void 0 && (!errors2 || errors2[match.route.id] === void 0);
if (match.route.lazy || needsToRunLoader) {
renderFallback = true;
if (fallbackIndex >= 0) {
renderedMatches = renderedMatches.slice(0, fallbackIndex + 1);
} else {
renderedMatches = [renderedMatches[0]];
}
break;
}
}
}
}
return renderedMatches.reduceRight((outlet, match, index2) => {
let error;
let shouldRenderHydrateFallback = false;
let errorElement = null;
let hydrateFallbackElement = null;
if (dataRouterState) {
error = errors && match.route.id ? errors[match.route.id] : void 0;
errorElement = match.route.errorElement || defaultErrorElement;
if (renderFallback) {
if (fallbackIndex < 0 && index2 === 0) {
shouldRenderHydrateFallback = true;
hydrateFallbackElement = null;
} else if (fallbackIndex === index2) {
shouldRenderHydrateFallback = true;
hydrateFallbackElement = match.route.hydrateFallbackElement || null;
}
}
}
let matches2 = parentMatches.concat(renderedMatches.slice(0, index2 + 1));
let getChildren = () => {
let children;
if (error) {
children = errorElement;
} else if (shouldRenderHydrateFallback) {
children = hydrateFallbackElement;
} else if (match.route.Component) {
children = /* @__PURE__ */ reactExports.createElement(match.route.Component, null);
} else if (match.route.element) {
children = match.route.element;
} else {
children = outlet;
}
return /* @__PURE__ */ reactExports.createElement(RenderedRoute, {
match,
routeContext: {
outlet,
matches: matches2,
isDataRoute: dataRouterState != null
},
children
});
};
return dataRouterState && (match.route.ErrorBoundary || match.route.errorElement || index2 === 0) ? /* @__PURE__ */ reactExports.createElement(RenderErrorBoundary, {
location: dataRouterState.location,
revalidation: dataRouterState.revalidation,
component: errorElement,
error,
children: getChildren(),
routeContext: {
outlet: null,
matches: matches2,
isDataRoute: true
}
}) : getChildren();
}, null);
}
var DataRouterStateHook$1 = /* @__PURE__ */ function(DataRouterStateHook2) {
DataRouterStateHook2["UseBlocker"] = "useBlocker";
DataRouterStateHook2["UseLoaderData"] = "useLoaderData";
DataRouterStateHook2["UseActionData"] = "useActionData";
DataRouterStateHook2["UseRouteError"] = "useRouteError";
DataRouterStateHook2["UseNavigation"] = "useNavigation";
DataRouterStateHook2["UseRouteLoaderData"] = "useRouteLoaderData";
DataRouterStateHook2["UseMatches"] = "useMatches";
DataRouterStateHook2["UseRevalidator"] = "useRevalidator";
DataRouterStateHook2["UseNavigateStable"] = "useNavigate";
DataRouterStateHook2["UseRouteId"] = "useRouteId";
return DataRouterStateHook2;
}(DataRouterStateHook$1 || {});
function useDataRouterState(hookName) {
let state = reactExports.useContext(DataRouterStateContext);
!state ? invariant(false) : void 0;
return state;
}
function useRouteContext(hookName) {
let route = reactExports.useContext(RouteContext);
!route ? invariant(false) : void 0;
return route;
}
function useCurrentRouteId(hookName) {
let route = useRouteContext();
let thisRoute = route.matches[route.matches.length - 1];
!thisRoute.route.id ? invariant(false) : void 0;
return thisRoute.route.id;
}
function useRouteError() {
var _state$errors;
let error = reactExports.useContext(RouteErrorContext);
let state = useDataRouterState(DataRouterStateHook$1.UseRouteError);
let routeId = useCurrentRouteId(DataRouterStateHook$1.UseRouteError);
if (error !== void 0) {
return error;
}
return (_state$errors = state.errors) == null ? void 0 : _state$errors[routeId];
}
function logV6DeprecationWarnings(renderFuture, routerFuture) {
if ((renderFuture == null ? void 0 : renderFuture.v7_startTransition) === void 0) ;
if ((renderFuture == null ? void 0 : renderFuture.v7_relativeSplatPath) === void 0 && !routerFuture) ;
}
function Route(_props) {
invariant(false);
}
function Router(_ref5) {
let {
basename: basenameProp = "/",
children = null,
location: locationProp,
navigationType = Action$1.Pop,
navigator: navigator2,
static: staticProp = false,
future
} = _ref5;
!!useInRouterContext() ? invariant(false) : void 0;
let basename = basenameProp.replace(/^\/*/, "/");
let navigationContext = reactExports.useMemo(() => ({
basename,
navigator: navigator2,
static: staticProp,
future: _extends({
v7_relativeSplatPath: false
}, future)
}), [basename, future, navigator2, staticProp]);
if (typeof locationProp === "string") {
locationProp = parsePath(locationProp);
}
let {
pathname = "/",
search = "",
hash = "",
state = null,
key = "default"
} = locationProp;
let locationContext = reactExports.useMemo(() => {
let trailingPathname = stripBasename(pathname, basename);
if (trailingPathname == null) {
return null;
}
return {
location: {
pathname: trailingPathname,
search,
hash,
state,
key
},
navigationType
};
}, [basename, pathname, search, hash, state, key, navigationType]);
if (locationContext == null) {
return null;
}
return /* @__PURE__ */ reactExports.createElement(NavigationContext.Provider, {
value: navigationContext
}, /* @__PURE__ */ reactExports.createElement(LocationContext.Provider, {
children,
value: locationContext
}));
}
function Routes(_ref6) {
let {
children,
location
} = _ref6;
return useRoutes(createRoutesFromChildren(children), location);
}
new Promise(() => {
});
function createRoutesFromChildren(children, parentPath) {
if (parentPath === void 0) {
parentPath = [];
}
let routes = [];
reactExports.Children.forEach(children, (element, index2) => {
if (!/* @__PURE__ */ reactExports.isValidElement(element)) {
return;
}
let treePath = [...parentPath, index2];
if (element.type === reactExports.Fragment) {
routes.push.apply(routes, createRoutesFromChildren(element.props.children, treePath));
return;
}
!(element.type === Route) ? invariant(false) : void 0;
!(!element.props.index || !element.props.children) ? invariant(false) : void 0;
let route = {
id: element.props.id || treePath.join("-"),
caseSensitive: element.props.caseSensitive,
element: element.props.element,
Component: element.props.Component,
index: element.props.index,
path: element.props.path,
loader: element.props.loader,
action: element.props.action,
errorElement: element.props.errorElement,
ErrorBoundary: element.props.ErrorBoundary,
hasErrorBoundary: element.props.ErrorBoundary != null || element.props.errorElement != null,
shouldRevalidate: element.props.shouldRevalidate,
handle: element.props.handle,
lazy: element.props.lazy
};
if (element.props.children) {
route.children = createRoutesFromChildren(element.props.children, treePath);
}
routes.push(route);
});
return routes;
}
/**
* React Router DOM v6.30.1
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/
const REACT_ROUTER_VERSION = "6";
try {
window.__reactRouterVersion = REACT_ROUTER_VERSION;
} catch (e) {
}
const START_TRANSITION = "startTransition";
const startTransitionImpl = React[START_TRANSITION];
function BrowserRouter(_ref4) {
let {
basename,
children,
future,
window: window2
} = _ref4;
let historyRef = reactExports.useRef();
if (historyRef.current == null) {
historyRef.current = createBrowserHistory({
window: window2,
v5Compat: true
});
}
let history = historyRef.current;
let [state, setStateImpl] = reactExports.useState({
action: history.action,
location: history.location
});
let {
v7_startTransition
} = future || {};
let setState = reactExports.useCallback((newState) => {
v7_startTransition && startTransitionImpl ? startTransitionImpl(() => setStateImpl(newState)) : setStateImpl(newState);
}, [setStateImpl, v7_startTransition]);
reactExports.useLayoutEffect(() => history.listen(setState), [history, setState]);
reactExports.useEffect(() => logV6DeprecationWarnings(future), [future]);
return /* @__PURE__ */ reactExports.createElement(Router, {
basename,
children,
location: state.location,
navigationType: state.action,
navigator: history,
future
});
}
var DataRouterHook;
(function(DataRouterHook2) {
DataRouterHook2["UseScrollRestoration"] = "useScrollRestoration";
DataRouterHook2["UseSubmit"] = "useSubmit";
DataRouterHook2["UseSubmitFetcher"] = "useSubmitFetcher";
DataRouterHook2["UseFetcher"] = "useFetcher";
DataRouterHook2["useViewTransitionState"] = "useViewTransitionState";
})(DataRouterHook || (DataRouterHook = {}));
var DataRouterStateHook;
(function(DataRouterStateHook2) {
DataRouterStateHook2["UseFetcher"] = "useFetcher";
DataRouterStateHook2["UseFetchers"] = "useFetchers";
DataRouterStateHook2["UseScrollRestoration"] = "useScrollRestoration";
})(DataRouterStateHook || (DataRouterStateHook = {}));
var P = ["light", "dark"], E = "(prefers-color-scheme: dark)", L = reactExports.createContext(void 0), D = { setTheme: (e) => {
}, themes: [] }, j = () => {
var e;
return (e = reactExports.useContext(L)) != null ? e : D;
};
reactExports.memo(({ forcedTheme: e, storageKey: a, attribute: n2, enableSystem: g, enableColorScheme: m2, defaultTheme: c, value: o, attrs: y2, nonce: h }) => {
let k2 = c === "system", w2 = n2 === "class" ? `var d=document.documentElement,c=d.classList;${`c.remove(${y2.map((u2) => `'${u2}'`).join(",")})`};` : `var d=document.documentElement,n='${n2}',s='setAttribute';`, i = m2 ? (P.includes(c) ? c : null) ? `if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${c}'` : "if(e==='light'||e==='dark')d.style.colorScheme=e" : "", d = (l2, u2 = false, R2 = true) => {
let f2 = o ? o[l2] : l2, p2 = u2 ? l2 + "|| ''" : `'${f2}'`, $ = "";
return m2 && R2 && !u2 && P.includes(l2) && ($ += `d.style.colorScheme = '${l2}';`), n2 === "class" ? u2 || f2 ? $ += `c.add(${p2})` : $ += "null" : f2 && ($ += `d[s](n,${p2})`), $;
}, S2 = e ? `!function(){${w2}${d(e)}}()` : g ? `!function(){try{${w2}var e=localStorage.getItem('${a}');if('system'===e||(!e&&${k2})){var t='${E}',m=window.matchMedia(t);if(m.media!==t||m.matches){${d("dark")}}else{${d("light")}}}else if(e){${o ? `var x=${JSON.stringify(o)};` : ""}${d(o ? "x[e]" : "e", true)}}${k2 ? "" : "else{" + d(c, false, false) + "}"}${i}}catch(e){}}()` : `!function(){try{${w2}var e=localStorage.getItem('${a}');if(e){${o ? `var x=${JSON.stringify(o)};` : ""}${d(o ? "x[e]" : "e", true)}}else{${d(c, false, false)};}${i}}catch(t){}}();`;
return reactExports.createElement("script", { nonce: h, dangerouslySetInnerHTML: { __html: S2 } });
});
var jt = (n2) => {
switch (n2) {
case "success":
return ee;
case "info":
return ae;
case "warning":
return oe;
case "error":
return se;
default:
return null;
}
}, te = Array(12).fill(0), Yt = ({ visible: n2, className: e }) => React2.createElement("div", { className: ["sonner-loading-wrapper", e].filter(Boolean).join(" "), "data-visible": n2 }, React2.createElement("div", { className: "sonner-spinner" }, te.map((t2, a) => React2.createElement("div", { className: "sonner-loading-bar", key: `spinner-bar-${a}` })))), ee = React2.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", height: "20", width: "20" }, React2.createElement("path", { fillRule: "evenodd", d: "M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z", clipRule: "evenodd" })), oe = React2.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", height: "20", width: "20" }, React2.createElement("path", { fillRule: "evenodd", d: "M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z", clipRule: "evenodd" })), ae = React2.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", height: "20", width: "20" }, React2.createElement("path", { fillRule: "evenodd", d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z", clipRule: "evenodd" })), se = React2.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 20 20", fill: "currentColor", height: "20", width: "20" }, React2.createElement("path", { fillRule: "evenodd", d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z", clipRule: "evenodd" })), Ot = React2.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }, React2.createElement("line", { x1: "18", y1: "6", x2: "6", y2: "18" }), React2.createElement("line", { x1: "6", y1: "6", x2: "18", y2: "18" }));
var Ft = () => {
let [n2, e] = React2.useState(document.hidden);
return React2.useEffect(() => {
let t2 = () => {
e(document.hidden);
};
return document.addEventListener("visibilitychange", t2), () => window.removeEventListener("visibilitychange", t2);
}, []), n2;
};
var bt = 1, yt = class {
constructor() {
this.subscribe = (e) => (this.subscribers.push(e), () => {
let t2 = this.subscribers.indexOf(e);
this.subscribers.splice(t2, 1);
});
this.publish = (e) => {
this.subscribers.forEach((t2) => t2(e));
};
this.addToast = (e) => {
this.publish(e), this.toasts = [...this.toasts, e];
};
this.create = (e) => {
var S2;
let { message: t2, ...a } = e, u2 = typeof (e == null ? void 0 : e.id) == "number" || ((S2 = e.id) == null ? void 0 : S2.length) > 0 ? e.id : bt++, f2 = this.toasts.find((g) => g.id === u2), w2 = e.dismissible === void 0 ? true : e.dismissible;
return this.dismissedToasts.has(u2) && this.dismissedToasts.delete(u2), f2 ? this.toasts = this.toasts.map((g) => g.id === u2 ? (this.publish({ ...g, ...e, id: u2, title: t2 }), { ...g, ...e, id: u2, dismissible: w2, title: t2 }) : g) : this.addToast({ title: t2, ...a, dismissible: w2, id: u2 }), u2;
};
this.dismiss = (e) => (this.dismissedToasts.add(e), e || this.toasts.forEach((t2) => {
this.subscribers.forEach((a) => a({ id: t2.id, dismiss: true }));
}), this.subscribers.forEach((t2) => t2({ id: e, dismiss: true })), e);
this.message = (e, t2) => this.create({ ...t2, message: e });
this.error = (e, t2) => this.create({ ...t2, message: e, type: "error" });
this.success = (e, t2) => this.create({ ...t2, type: "success", message: e });
this.info = (e, t2) => this.create({ ...t2, type: "info", message: e });
this.warning = (e, t2) => this.create({ ...t2, type: "warning", message: e });
this.loading = (e, t2) => this.create({ ...t2, type: "loading", message: e });
this.promise = (e, t2) => {
if (!t2) return;
let a;
t2.loading !== void 0 && (a = this.create({ ...t2, promise: e, type: "loading", message: t2.loading, description: typeof t2.description != "function" ? t2.description : void 0 }));
let u2 = e instanceof Promise ? e : e(), f2 = a !== void 0, w2, S2 = u2.then(async (i) => {
if (w2 = ["resolve", i], React2.isValidElement(i)) f2 = false, this.create({ id: a, type: "default", message: i });
else if (ie(i) && !i.ok) {
f2 = false;
let T2 = typeof t2.error == "function" ? await t2.error(`HTTP error! status: ${i.status}`) : t2.error, F2 = typeof t2.description == "function" ? await t2.description(`HTTP error! status: ${i.status}`) : t2.description;
this.create({ id: a, type: "error", message: T2, description: F2 });
} else if (t2.success !== void 0) {
f2 = false;
let T2 = typeof t2.success == "function" ? await t2.success(i) : t2.success, F2 = typeof t2.description == "function" ? await t2.description(i) : t2.description;
this.create({ id: a, type: "success", message: T2, description: F2 });
}
}).catch(async (i) => {
if (w2 = ["reject", i], t2.error !== void 0) {
f2 = false;
let D2 = typeof t2.error == "function" ? await t2.error(i) : t2.error, T2 = typeof t2.description == "function" ? await t2.description(i) : t2.description;
this.create({ id: a, type: "error", message: D2, description: T2 });
}
}).finally(() => {
var i;
f2 && (this.dismiss(a), a = void 0), (i = t2.finally) == null || i.call(t2);
}), g = () => new Promise((i, D2) => S2.then(() => w2[0] === "reject" ? D2(w2[1]) : i(w2[1])).catch(D2));
return typeof a != "string" && typeof a != "number" ? { unwrap: g } : Object.assign(a, { unwrap: g });
};
this.custom = (e, t2) => {
let a = (t2 == null ? void 0 : t2.id) || bt++;
return this.create({ jsx: e(a), id: a, ...t2 }), a;
};
this.getActiveToasts = () => this.toasts.filter((e) => !this.dismissedToasts.has(e.id));
this.subscribers = [], this.toasts = [], this.dismissedToasts = /* @__PURE__ */ new Set();
}
}, v = new yt(), ne = (n2, e) => {
let t2 = (e == null ? void 0 : e.id) || bt++;
return v.addToast({ title: n2, ...e, id: t2 }), t2;
}, ie = (n2) => n2 && typeof n2 == "object" && "ok" in n2 && typeof n2.ok == "boolean" && "status" in n2 && typeof n2.status == "number", le = ne, ce = () => v.toasts, de = () => v.getActiveToasts();
Object.assign(le, { success: v.success, info: v.info, warning: v.warning, error: v.error, custom: v.custom, message: v.message, promise: v.promise, dismiss: v.dismiss, loading: v.loading }, { getHistory: ce, getToasts: de });
function wt(n2, { insertAt: e } = {}) {
if (typeof document == "undefined") return;
let t2 = document.head || document.getElementsByTagName("head")[0], a = document.createElement("style");
a.type = "text/css", e === "top" && t2.firstChild ? t2.insertBefore(a, t2.firstChild) : t2.appendChild(a), a.styleSheet ? a.styleSheet.cssText = n2 : a.appendChild(document.createTextNode(n2));
}
wt(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
`);
function tt(n2) {
return n2.label !== void 0;
}
var pe = 3, me = "32px", ge = "16px", Wt = 4e3, he = 356, be = 14, ye = 20, we = 200;
function M(...n2) {
return n2.filter(Boolean).join(" ");
}
function xe(n2) {
let [e, t2] = n2.split("-"), a = [];
return e && a.push(e), t2 && a.push(t2), a;
}
var ve = (n2) => {
var Dt, Pt, Nt, Bt, Ct, kt, It, Mt, Ht, At, Lt;
let { invert: e, toast: t2, unstyled: a, interacting: u2, setHeights: f2, visibleToasts: w2, heights: S2, index: g, toasts: i, expanded: D2, removeToast: T2, defaultRichColors: F2, closeButton: et, style: ut, cancelButtonStyle: ft, actionButtonStyle: l2, className: ot = "", descriptionClassName: at = "", duration: X2, position: st, gap: pt, loadingIcon: rt, expandByDefault: B2, classNames: s, icons: P2, closeButtonAriaLabel: nt = "Close toast", pauseWhenPageIsHidden: it } = n2, [Y2, C2] = React2.useState(null), [lt, J2] = React2.useState(null), [W2, H2] = React2.useState(false), [A2, mt] = React2.useState(false), [L2, z2] = React2.useState(false), [ct, d] = React2.useState(false), [h, y2] = React2.useState(false), [R2, j2] = React2.useState(0), [p2, _] = React2.useState(0), O2 = React2.useRef(t2.duration || X2 || Wt), G2 = React2.useRef(null), k2 = React2.useRef(null), Vt = g === 0, Ut = g + 1 <= w2, N2 = t2.type, V2 = t2.dismissible !== false, Kt = t2.className || "", Xt = t2.descriptionClassName || "", dt = React2.useMemo(() => S2.findIndex((r2) => r2.toastId === t2.id) || 0, [S2, t2.id]), Jt = React2.useMemo(() => {
var r2;
return (r2 = t2.closeButton) != null ? r2 : et;
}, [t2.closeButton, et]), Tt = React2.useMemo(() => t2.duration || X2 || Wt, [t2.duration, X2]), gt = React2.useRef(0), U2 = React2.useRef(0), St = React2.useRef(0), K2 = React2.useRef(null), [Gt, Qt] = st.split("-"), Rt = React2.useMemo(() => S2.reduce((r2, m2, c) => c >= dt ? r2 : r2 + m2.height, 0), [S2, dt]), Et = Ft(), qt = t2.invert || e, ht = N2 === "loading";
U2.current = React2.useMemo(() => dt * pt + Rt, [dt, Rt]), React2.useEffect(() => {
O2.current = Tt;
}, [Tt]), React2.useEffect(() => {
H2(true);
}, []), React2.useEffect(() => {
let r2 = k2.current;
if (r2) {
let m2 = r2.getBoundingClientRect().height;
return _(m2), f2((c) => [{ toastId: t2.id, height: m2, position: t2.position }, ...c]), () => f2((c) => c.filter((b) => b.toastId !== t2.id));
}
}, [f2, t2.id]), React2.useLayoutEffect(() => {
if (!W2) return;
let r2 = k2.current, m2 = r2.style.height;
r2.style.height = "auto";
let c = r2.getBoundingClientRect().height;
r2.style.height = m2, _(c), f2((b) => b.find((x2) => x2.toastId === t2.id) ? b.map((x2) => x2.toastId === t2.id ? { ...x2, height: c } : x2) : [{ toastId: t2.id, height: c, position: t2.position }, ...b]);
}, [W2, t2.title, t2.description, f2, t2.id]);
let $ = React2.useCallback(() => {
mt(true), j2(U2.current), f2((r2) => r2.filter((m2) => m2.toastId !== t2.id)), setTimeout(() => {
T2(t2);
}, we);
}, [t2, T2, f2, U2]);
React2.useEffect(() => {
if (t2.promise && N2 === "loading" || t2.duration === 1 / 0 || t2.type === "loading") return;
let r2;
return D2 || u2 || it && Et ? (() => {
if (St.current < gt.current) {
let b = (/* @__PURE__ */ new Date()).getTime() - gt.current;
O2.current = O2.current - b;
}
St.current = (/* @__PURE__ */ new Date()).getTime();
})() : (() => {
O2.current !== 1 / 0 && (gt.current = (/* @__PURE__ */ new Date()).getTime(), r2 = setTimeout(() => {
var b;
(b = t2.onAutoClose) == null || b.call(t2, t2), $();
}, O2.current));
})(), () => clearTimeout(r2);
}, [D2, u2, t2, N2, it, Et, $]), React2.useEffect(() => {
t2.delete && $();
}, [$, t2.delete]);
function Zt() {
var r2, m2, c;
return P2 != null && P2.loading ? React2.createElement("div", { className: M(s == null ? void 0 : s.loader, (r2 = t2 == null ? void 0 : t2.classNames) == null ? void 0 : r2.loader, "sonner-loader"), "data-visible": N2 === "loading" }, P2.loading) : rt ? React2.createElement("div", { className: M(s == null ? void 0 : s.loader, (m2 = t2 == null ? void 0 : t2.classNames) == null ? void 0 : m2.loader, "sonner-loader"), "data-visible": N2 === "loading" }, rt) : React2.createElement(Yt, { className: M(s == null ? void 0 : s.loader, (c = t2 == null ? void 0 : t2.classNames) == null ? void 0 : c.loader), visible: N2 === "loading" });
}
return React2.createElement("li", { tabIndex: 0, ref: k2, className: M(ot, Kt, s == null ? void 0 : s.toast, (Dt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Dt.toast, s == null ? void 0 : s.default, s == null ? void 0 : s[N2], (Pt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Pt[N2]), "data-sonner-toast": "", "data-rich-colors": (Nt = t2.richColors) != null ? Nt : F2, "data-styled": !(t2.jsx || t2.unstyled || a), "data-mounted": W2, "data-promise": !!t2.promise, "data-swiped": h, "data-removed": A2, "data-visible": Ut, "data-y-position": Gt, "data-x-position": Qt, "data-index": g, "data-front": Vt, "data-swiping": L2, "data-dismissible": V2, "data-type": N2, "data-invert": qt, "data-swipe-out": ct, "data-swipe-direction": lt, "data-expanded": !!(D2 || B2 && W2), style: { "--index": g, "--toasts-before": g, "--z-index": i.length - g, "--offset": `${A2 ? R2 : U2.current}px`, "--initial-height": B2 ? "auto" : `${p2}px`, ...ut, ...t2.style }, onDragEnd: () => {
z2(false), C2(null), K2.current = null;
}, onPointerDown: (r2) => {
ht || !V2 || (G2.current = /* @__PURE__ */ new Date(), j2(U2.current), r2.target.setPointerCapture(r2.pointerId), r2.target.tagName !== "BUTTON" && (z2(true), K2.current = { x: r2.clientX, y: r2.clientY }));
}, onPointerUp: () => {
var x2, Q2, q2, Z2;
if (ct || !V2) return;
K2.current = null;
let r2 = Number(((x2 = k2.current) == null ? void 0 : x2.style.getPropertyValue("--swipe-amount-x").replace("px", "")) || 0), m2 = Number(((Q2 = k2.current) == null ? void 0 : Q2.style.getPropertyValue("--swipe-amount-y").replace("px", "")) || 0), c = (/* @__PURE__ */ new Date()).getTime() - ((q2 = G2.current) == null ? void 0 : q2.getTime()), b = Y2 === "x" ? r2 : m2, I2 = Math.abs(b) / c;
if (Math.abs(b) >= ye || I2 > 0.11) {
j2(U2.current), (Z2 = t2.onDismiss) == null || Z2.call(t2, t2), J2(Y2 === "x" ? r2 > 0 ? "right" : "left" : m2 > 0 ? "down" : "up"), $(), d(true), y2(false);
return;
}
z2(false), C2(null);
}, onPointerMove: (r2) => {
var Q2, q2, Z2, zt;
if (!K2.current || !V2 || ((Q2 = window.getSelection()) == null ? void 0 : Q2.toString().length) > 0) return;
let c = r2.clientY - K2.current.y, b = r2.clientX - K2.current.x, I2 = (q2 = n2.swipeDirections) != null ? q2 : xe(st);
!Y2 && (Math.abs(b) > 1 || Math.abs(c) > 1) && C2(Math.abs(b) > Math.abs(c) ? "x" : "y");
let x2 = { x: 0, y: 0 };
Y2 === "y" ? (I2.includes("top") || I2.includes("bottom")) && (I2.includes("top") && c < 0 || I2.includes("bottom") && c > 0) && (x2.y = c) : Y2 === "x" && (I2.includes("left") || I2.includes("right")) && (I2.includes("left") && b < 0 || I2.includes("right") && b > 0) && (x2.x = b), (Math.abs(x2.x) > 0 || Math.abs(x2.y) > 0) && y2(true), (Z2 = k2.current) == null || Z2.style.setProperty("--swipe-amount-x", `${x2.x}px`), (zt = k2.current) == null || zt.style.setProperty("--swipe-amount-y", `${x2.y}px`);
} }, Jt && !t2.jsx ? React2.createElement("button", { "aria-label": nt, "data-disabled": ht, "data-close-button": true, onClick: ht || !V2 ? () => {
} : () => {
var r2;
$(), (r2 = t2.onDismiss) == null || r2.call(t2, t2);
}, className: M(s == null ? void 0 : s.closeButton, (Bt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Bt.closeButton) }, (Ct = P2 == null ? void 0 : P2.close) != null ? Ct : Ot) : null, t2.jsx || reactExports.isValidElement(t2.title) ? t2.jsx ? t2.jsx : typeof t2.title == "function" ? t2.title() : t2.title : React2.createElement(React2.Fragment, null, N2 || t2.icon || t2.promise ? React2.createElement("div", { "data-icon": "", className: M(s == null ? void 0 : s.icon, (kt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : kt.icon) }, t2.promise || t2.type === "loading" && !t2.icon ? t2.icon || Zt() : null, t2.type !== "loading" ? t2.icon || (P2 == null ? void 0 : P2[N2]) || jt(N2) : null) : null, React2.createElement("div", { "data-content": "", className: M(s == null ? void 0 : s.content, (It = t2 == null ? void 0 : t2.classNames) == null ? void 0 : It.content) }, React2.createElement("div", { "data-title": "", className: M(s == null ? void 0 : s.title, (Mt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Mt.title) }, typeof t2.title == "function" ? t2.title() : t2.title), t2.description ? React2.createElement("div", { "data-description": "", className: M(at, Xt, s == null ? void 0 : s.description, (Ht = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Ht.description) }, typeof t2.description == "function" ? t2.description() : t2.description) : null), reactExports.isValidElement(t2.cancel) ? t2.cancel : t2.cancel && tt(t2.cancel) ? React2.createElement("button", { "data-button": true, "data-cancel": true, style: t2.cancelButtonStyle || ft, onClick: (r2) => {
var m2, c;
tt(t2.cancel) && V2 && ((c = (m2 = t2.cancel).onClick) == null || c.call(m2, r2), $());
}, className: M(s == null ? void 0 : s.cancelButton, (At = t2 == null ? void 0 : t2.classNames) == null ? void 0 : At.cancelButton) }, t2.cancel.label) : null, reactExports.isValidElement(t2.action) ? t2.action : t2.action && tt(t2.action) ? React2.createElement("button", { "data-button": true, "data-action": true, style: t2.actionButtonStyle || l2, onClick: (r2) => {
var m2, c;
tt(t2.action) && ((c = (m2 = t2.action).onClick) == null || c.call(m2, r2), !r2.defaultPrevented && $());
}, className: M(s == null ? void 0 : s.actionButton, (Lt = t2 == null ? void 0 : t2.classNames) == null ? void 0 : Lt.actionButton) }, t2.action.label) : null));
};
function _t() {
if (typeof window == "undefined" || typeof document == "undefined") return "ltr";
let n2 = document.documentElement.getAttribute("dir");
return n2 === "auto" || !n2 ? window.getComputedStyle(document.documentElement).direction : n2;
}
function Te(n2, e) {
let t2 = {};
return [n2, e].forEach((a, u2) => {
let f2 = u2 === 1, w2 = f2 ? "--mobile-offset" : "--offset", S2 = f2 ? ge : me;
function g(i) {
["top", "right", "bottom", "left"].forEach((D2) => {
t2[`${w2}-${D2}`] = typeof i == "number" ? `${i}px` : i;
});
}
typeof a == "number" || typeof a == "string" ? g(a) : typeof a == "object" ? ["top", "right", "bottom", "left"].forEach((i) => {
a[i] === void 0 ? t2[`${w2}-${i}`] = S2 : t2[`${w2}-${i}`] = typeof a[i] == "number" ? `${a[i]}px` : a[i];
}) : g(S2);
}), t2;
}
var $e = reactExports.forwardRef(function(e, t2) {
let { invert: a, position: u2 = "bottom-right", hotkey: f2 = ["altKey", "KeyT"], expand: w2, closeButton: S2, className: g, offset: i, mobileOffset: D2, theme: T2 = "light", richColors: F2, duration: et, style: ut, visibleToasts: ft = pe, toastOptions: l2, dir: ot = _t(), gap: at = be, loadingIcon: X2, icons: st, containerAriaLabel: pt = "Notifications", pauseWhenPageIsHidden: rt } = e, [B2, s] = React2.useState([]), P2 = React2.useMemo(() => Array.from(new Set([u2].concat(B2.filter((d) => d.position).map((d) => d.position)))), [B2, u2]), [nt, it] = React2.useState([]), [Y2, C2] = React2.useState(false), [lt, J2] = React2.useState(false), [W2, H2] = React2.useState(T2 !== "system" ? T2 : typeof window != "undefined" && window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light"), A2 = React2.useRef(null), mt = f2.join("+").replace(/Key/g, "").replace(/Digit/g, ""), L2 = React2.useRef(null), z2 = React2.useRef(false), ct = React2.useCallback((d) => {
s((h) => {
var y2;
return (y2 = h.find((R2) => R2.id === d.id)) != null && y2.delete || v.dismiss(d.id), h.filter(({ id: R2 }) => R2 !== d.id);
});
}, []);
return React2.useEffect(() => v.subscribe((d) => {
if (d.dismiss) {
s((h) => h.map((y2) => y2.id === d.id ? { ...y2, delete: true } : y2));
return;
}
setTimeout(() => {
ReactDOM.flushSync(() => {
s((h) => {
let y2 = h.findIndex((R2) => R2.id === d.id);
return y2 !== -1 ? [...h.slice(0, y2), { ...h[y2], ...d }, ...h.slice(y2 + 1)] : [d, ...h];
});
});
});
}), []), React2.useEffect(() => {
if (T2 !== "system") {
H2(T2);
return;
}
if (T2 === "system" && (window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? H2("dark") : H2("light")), typeof window == "undefined") return;
let d = window.matchMedia("(prefers-color-scheme: dark)");
try {
d.addEventListener("change", ({ matches: h }) => {
H2(h ? "dark" : "light");
});
} catch (h) {
d.addListener(({ matches: y2 }) => {
try {
H2(y2 ? "dark" : "light");
} catch (R2) {
console.error(R2);
}
});
}
}, [T2]), React2.useEffect(() => {
B2.length <= 1 && C2(false);
}, [B2]), React2.useEffect(() => {
let d = (h) => {
var R2, j2;
f2.every((p2) => h[p2] || h.code === p2) && (C2(true), (R2 = A2.current) == null || R2.focus()), h.code === "Escape" && (document.activeElement === A2.current || (j2 = A2.current) != null && j2.contains(document.activeElement)) && C2(false);
};
return document.addEventListener("keydown", d), () => document.removeEventListener("keydown", d);
}, [f2]), React2.useEffect(() => {
if (A2.current) return () => {
L2.current && (L2.current.focus({ preventScroll: true }), L2.current = null, z2.current = false);
};
}, [A2.current]), React2.createElement("section", { ref: t2, "aria-label": `${pt} ${mt}`, tabIndex: -1, "aria-live": "polite", "aria-relevant": "additions text", "aria-atomic": "false", suppressHydrationWarning: true }, P2.map((d, h) => {
var j2;
let [y2, R2] = d.split("-");
return B2.length ? React2.createElement("ol", { key: d, dir: ot === "auto" ? _t() : ot, tabIndex: -1, ref: A2, className: g, "data-sonner-toaster": true, "data-theme": W2, "data-y-position": y2, "data-lifted": Y2 && B2.length > 1 && !w2, "data-x-position": R2, style: { "--front-toast-height": `${((j2 = nt[0]) == null ? void 0 : j2.height) || 0}px`, "--width": `${he}px`, "--gap": `${at}px`, ...ut, ...Te(i, D2) }, onBlur: (p2) => {
z2.current && !p2.currentTarget.contains(p2.relatedTarget) && (z2.current = false, L2.current && (L2.current.focus({ preventScroll: true }), L2.current = null));
}, onFocus: (p2) => {
p2.target instanceof HTMLElement && p2.target.dataset.dismissible === "false" || z2.current || (z2.current = true, L2.current = p2.relatedTarget);
}, onMouseEnter: () => C2(true), onMouseMove: () => C2(true), onMouseLeave: () => {
lt || C2(false);
}, onDragEnd: () => C2(false), onPointerDown: (p2) => {
p2.target instanceof HTMLElement && p2.target.dataset.dismissible === "false" || J2(true);
}, onPointerUp: () => J2(false) }, B2.filter((p2) => !p2.position && h === 0 || p2.position === d).map((p2, _) => {
var O2, G2;
return React2.createElement(ve, { key: p2.id, icons: st, index: _, toast: p2, defaultRichColors: F2, duration: (O2 = l2 == null ? void 0 : l2.duration) != null ? O2 : et, className: l2 == null ? void 0 : l2.className, descriptionClassName: l2 == null ? void 0 : l2.descriptionClassName, invert: a, visibleToasts: ft, closeButton: (G2 = l2 == null ? void 0 : l2.closeButton) != null ? G2 : S2, interacting: lt, position: d, style: l2 == null ? void 0 : l2.style, unstyled: l2 == null ? void 0 : l2.unstyled, classNames: l2 == null ? void 0 : l2.classNames, cancelButtonStyle: l2 == null ? void 0 : l2.cancelButtonStyle, actionButtonStyle: l2 == null ? void 0 : l2.actionButtonStyle, removeToast: ct, toasts: B2.filter((k2) => k2.position == p2.position), heights: nt.filter((k2) => k2.position == p2.position), setHeights: it, expandByDefault: w2, gap: at, loadingIcon: X2, expanded: Y2, pauseWhenPageIsHidden: rt, swipeDirections: e.swipeDirections });
})) : null;
}));
});
const Toaster$1 = ({ ...props }) => {
const { theme = "system" } = j();
return /* @__PURE__ */ jsxRuntimeExports.jsx(
$e,
{
theme,
className: "toaster group",
toastOptions: {
classNames: {
toast: "group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",
description: "group-[.toast]:text-muted-foreground",
actionButton: "group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",
cancelButton: "group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"
}
},
...props
}
);
};
const TOAST_LIMIT = 1;
const TOAST_REMOVE_DELAY = 1e6;
let count = 0;
function genId() {
count = (count + 1) % Number.MAX_SAFE_INTEGER;
return count.toString();
}
const toastTimeouts = /* @__PURE__ */ new Map();
const addToRemoveQueue = (toastId) => {
if (toastTimeouts.has(toastId)) {
return;
}
const timeout = setTimeout(() => {
toastTimeouts.delete(toastId);
dispatch({
type: "REMOVE_TOAST",
toastId
});
}, TOAST_REMOVE_DELAY);
toastTimeouts.set(toastId, timeout);
};
const reducer = (state, action) => {
switch (action.type) {
case "ADD_TOAST":
return {
...state,
toasts: [action.toast, ...state.toasts].slice(0, TOAST_LIMIT)
};
case "UPDATE_TOAST":
return {
...state,
toasts: state.toasts.map((t2) => t2.id === action.toast.id ? { ...t2, ...action.toast } : t2)
};
case "DISMISS_TOAST": {
const { toastId } = action;
if (toastId) {
addToRemoveQueue(toastId);
} else {
state.toasts.forEach((toast2) => {
addToRemoveQueue(toast2.id);
});
}
return {
...state,
toasts: state.toasts.map(
(t2) => t2.id === toastId || toastId === void 0 ? {
...t2,
open: false
} : t2
)
};
}
case "REMOVE_TOAST":
if (action.toastId === void 0) {
return {
...state,
toasts: []
};
}
return {
...state,
toasts: state.toasts.filter((t2) => t2.id !== action.toastId)
};
}
};
const listeners = [];
let memoryState = { toasts: [] };
function dispatch(action) {
memoryState = reducer(memoryState, action);
listeners.forEach((listener) => {
listener(memoryState);
});
}
function toast({ ...props }) {
const id2 = genId();
const update = (props2) => dispatch({
type: "UPDATE_TOAST",
toast: { ...props2, id: id2 }
});
const dismiss = () => dispatch({ type: "DISMISS_TOAST", toastId: id2 });
dispatch({
type: "ADD_TOAST",
toast: {
...props,
id: id2,
open: true,
onOpenChange: (open) => {
if (!open) dismiss();
}
}
});
return {
id: id2,
dismiss,
update
};
}
function useToast() {
const [state, setState] = reactExports.useState(memoryState);
reactExports.useEffect(() => {
listeners.push(setState);
return () => {
const index2 = listeners.indexOf(setState);
if (index2 > -1) {
listeners.splice(index2, 1);
}
};
}, [state]);
return {
...state,
toast,
dismiss: (toastId) => dispatch({ type: "DISMISS_TOAST", toastId })
};
}
function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
return function handleEvent(event) {
originalEventHandler == null ? void 0 : originalEventHandler(event);
if (checkForDefaultPrevented === false || !event.defaultPrevented) {
return ourEventHandler == null ? void 0 : ourEventHandler(event);
}
};
}
function setRef(ref, value) {
if (typeof ref === "function") {
return ref(value);
} else if (ref !== null && ref !== void 0) {
ref.current = value;
}
}
function composeRefs(...refs) {
return (node) => {
let hasCleanup = false;
const cleanups = refs.map((ref) => {
const cleanup = setRef(ref, node);
if (!hasCleanup && typeof cleanup == "function") {
hasCleanup = true;
}
return cleanup;
});
if (hasCleanup) {
return () => {
for (let i = 0; i < cleanups.length; i++) {
const cleanup = cleanups[i];
if (typeof cleanup == "function") {
cleanup();
} else {
setRef(refs[i], null);
}
}
};
}
};
}
function useComposedRefs(...refs) {
return reactExports.useCallback(composeRefs(...refs), refs);
}
function createContextScope(scopeName, createContextScopeDeps = []) {
let defaultContexts = [];
function createContext3(rootComponentName, defaultContext) {
const BaseContext = reactExports.createContext(defaultContext);
const index2 = defaultContexts.length;
defaultContexts = [...defaultContexts, defaultContext];
const Provider2 = (props) => {
var _a2;
const { scope, children, ...context } = props;
const Context = ((_a2 = scope == null ? void 0 : scope[scopeName]) == null ? void 0 : _a2[index2]) || BaseContext;
const value = reactExports.useMemo(() => context, Object.values(context));
return /* @__PURE__ */ jsxRuntimeExports.jsx(Context.Provider, { value, children });
};
Provider2.displayName = rootComponentName + "Provider";
function useContext2(consumerName, scope) {
var _a2;
const Context = ((_a2 = scope == null ? void 0 : scope[scopeName]) == null ? void 0 : _a2[index2]) || BaseContext;
const context = reactExports.useContext(Context);
if (context) return context;
if (defaultContext !== void 0) return defaultContext;
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
}
return [Provider2, useContext2];
}
const createScope = () => {
const scopeContexts = defaultContexts.map((defaultContext) => {
return reactExports.createContext(defaultContext);
});
return function useScope(scope) {
const contexts = (scope == null ? void 0 : scope[scopeName]) || scopeContexts;
return reactExports.useMemo(
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
[scope, contexts]
);
};
};
createScope.scopeName = scopeName;
return [createContext3, composeContextScopes(createScope, ...createContextScopeDeps)];
}
function composeContextScopes(...scopes) {
const baseScope = scopes[0];
if (scopes.length === 1) return baseScope;
const createScope = () => {
const scopeHooks = scopes.map((createScope2) => ({
useScope: createScope2(),
scopeName: createScope2.scopeName
}));
return function useComposedScopes(overrideScopes) {
const nextScopes = scopeHooks.reduce((nextScopes2, { useScope, scopeName }) => {
const scopeProps = useScope(overrideScopes);
const currentScope = scopeProps[`__scope${scopeName}`];
return { ...nextScopes2, ...currentScope };
}, {});
return reactExports.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
};
};
createScope.scopeName = baseScope.scopeName;
return createScope;
}
// @__NO_SIDE_EFFECTS__
function createSlot(ownerName) {
const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
const Slot2 = reactExports.forwardRef((props, forwardedRef) => {
const { children, ...slotProps } = props;
const childrenArray = reactExports.Children.toArray(children);
const slottable = childrenArray.find(isSlottable);
if (slottable) {
const newElement = slottable.props.children;
const newChildren = childrenArray.map((child) => {
if (child === slottable) {
if (reactExports.Children.count(newElement) > 1) return reactExports.Children.only(null);
return reactExports.isValidElement(newElement) ? newElement.props.children : null;
} else {
return child;
}
});
return /* @__PURE__ */ jsxRuntimeExports.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: reactExports.isValidElement(newElement) ? reactExports.cloneElement(newElement, void 0, newChildren) : null });
}
return /* @__PURE__ */ jsxRuntimeExports.jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
});
Slot2.displayName = `${ownerName}.Slot`;
return Slot2;
}
var Slot = /* @__PURE__ */ createSlot("Slot");
// @__NO_SIDE_EFFECTS__
function createSlotClone(ownerName) {
const SlotClone = reactExports.forwardRef((props, forwardedRef) => {
const { children, ...slotProps } = props;
if (reactExports.isValidElement(children)) {
const childrenRef = getElementRef$1(children);
const props2 = mergeProps(slotProps, children.props);
if (children.type !== reactExports.Fragment) {
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
}
return reactExports.cloneElement(children, props2);
}
return reactExports.Children.count(children) > 1 ? reactExports.Children.only(null) : null;
});
SlotClone.displayName = `${ownerName}.SlotClone`;
return SlotClone;
}
var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
// @__NO_SIDE_EFFECTS__
function createSlottable(ownerName) {
const Slottable2 = ({ children }) => {
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children });
};
Slottable2.displayName = `${ownerName}.Slottable`;
Slottable2.__radixId = SLOTTABLE_IDENTIFIER;
return Slottable2;
}
function isSlottable(child) {
return reactExports.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
}
function mergeProps(slotProps, childProps) {
const overrideProps = { ...childProps };
for (const propName in childProps) {
const slotPropValue = slotProps[propName];
const childPropValue = childProps[propName];
const isHandler = /^on[A-Z]/.test(propName);
if (isHandler) {
if (slotPropValue && childPropValue) {
overrideProps[propName] = (...args) => {
const result = childPropValue(...args);
slotPropValue(...args);
return result;
};
} else if (slotPropValue) {
overrideProps[propName] = slotPropValue;
}
} else if (propName === "style") {
overrideProps[propName] = { ...slotPropValue, ...childPropValue };
} else if (propName === "className") {
overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(" ");
}
}
return { ...slotProps, ...overrideProps };
}
function getElementRef$1(element) {
var _a2, _b2;
let getter = (_a2 = Object.getOwnPropertyDescriptor(element.props, "ref")) == null ? void 0 : _a2.get;
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
if (mayWarn) {
return element.ref;
}
getter = (_b2 = Object.getOwnPropertyDescriptor(element, "ref")) == null ? void 0 : _b2.get;
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
if (mayWarn) {
return element.props.ref;
}
return element.props.ref || element.ref;
}
function createCollection(name) {
const PROVIDER_NAME2 = name + "CollectionProvider";
const [createCollectionContext, createCollectionScope2] = createContextScope(PROVIDER_NAME2);
const [CollectionProviderImpl, useCollectionContext] = createCollectionContext(
PROVIDER_NAME2,
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
);
const CollectionProvider = (props) => {
const { scope, children } = props;
const ref = React2.useRef(null);
const itemMap = React2.useRef(/* @__PURE__ */ new Map()).current;
return /* @__PURE__ */ jsxRuntimeExports.jsx(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });
};
CollectionProvider.displayName = PROVIDER_NAME2;
const COLLECTION_SLOT_NAME = name + "CollectionSlot";
const CollectionSlotImpl = /* @__PURE__ */ createSlot(COLLECTION_SLOT_NAME);
const CollectionSlot = React2.forwardRef(
(props, forwardedRef) => {
const { scope, children } = props;
const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);
const composedRefs = useComposedRefs(forwardedRef, context.collectionRef);
return /* @__PURE__ */ jsxRuntimeExports.jsx(CollectionSlotImpl, { ref: composedRefs, children });
}
);
CollectionSlot.displayName = COLLECTION_SLOT_NAME;
const ITEM_SLOT_NAME = name + "CollectionItemSlot";
const ITEM_DATA_ATTR = "data-radix-collection-item";
const CollectionItemSlotImpl = /* @__PURE__ */ createSlot(ITEM_SLOT_NAME);
const CollectionItemSlot = React2.forwardRef(
(props, forwardedRef) => {
const { scope, children, ...itemData } = props;
const ref = React2.useRef(null);
const composedRefs = useComposedRefs(forwardedRef, ref);
const context = useCollectionContext(ITEM_SLOT_NAME, scope);
React2.useEffect(() => {
context.itemMap.set(ref, { ref, ...itemData });
return () => void context.itemMap.delete(ref);
});
return /* @__PURE__ */ jsxRuntimeExports.jsx(CollectionItemSlotImpl, { ...{ [ITEM_DATA_ATTR]: "" }, ref: composedRefs, children });
}
);
CollectionItemSlot.displayName = ITEM_SLOT_NAME;
function useCollection2(scope) {
const context = useCollectionContext(name + "CollectionConsumer", scope);
const getItems = React2.useCallback(() => {
const collectionNode = context.collectionRef.current;
if (!collectionNode) return [];
const orderedNodes = Array.from(collectionNode.querySelectorAll(`[${ITEM_DATA_ATTR}]`));
const items2 = Array.from(context.itemMap.values());
const orderedItems = items2.sort(
(a, b) => orderedNodes.indexOf(a.ref.current) - orderedNodes.indexOf(b.ref.current)
);
return orderedItems;
}, [context.collectionRef, context.itemMap]);
return getItems;
}
return [
{ Provider: CollectionProvider, Slot: CollectionSlot, ItemSlot: CollectionItemSlot },
useCollection2,
createCollectionScope2
];
}
var NODES = [
"a",
"button",
"div",
"form",
"h2",
"h3",
"img",
"input",
"label",
"li",
"nav",
"ol",
"p",
"select",
"span",
"svg",
"ul"
];
var Primitive = NODES.reduce((primitive, node) => {
const Slot2 = /* @__PURE__ */ createSlot(`Primitive.${node}`);
const Node2 = reactExports.forwardRef((props, forwardedRef) => {
const { asChild, ...primitiveProps } = props;
const Comp = asChild ? Slot2 : node;
if (typeof window !== "undefined") {
window[Symbol.for("radix-ui")] = true;
}
return /* @__PURE__ */ jsxRuntimeExports.jsx(Comp, { ...primitiveProps, ref: forwardedRef });
});
Node2.displayName = `Primitive.${node}`;
return { ...primitive, [node]: Node2 };
}, {});
function dispatchDiscreteCustomEvent(target, event) {
if (target) reactDomExports.flushSync(() => target.dispatchEvent(event));
}
function useCallbackRef(callback) {
const callbackRef = reactExports.useRef(callback);
reactExports.useEffect(() => {
callbackRef.current = callback;
});
return reactExports.useMemo(() => (...args) => {
var _a2;
return (_a2 = callbackRef.current) == null ? void 0 : _a2.call(callbackRef, ...args);
}, []);
}
function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);
reactExports.useEffect(() => {
const handleKeyDown = (event) => {
if (event.key === "Escape") {
onEscapeKeyDown(event);
}
};
ownerDocument.addEventListener("keydown", handleKeyDown, { capture: true });
return () => ownerDocument.removeEventListener("keydown", handleKeyDown, { capture: true });
}, [onEscapeKeyDown, ownerDocument]);
}
var DISMISSABLE_LAYER_NAME = "DismissableLayer";
var CONTEXT_UPDATE = "dismissableLayer.update";
var POINTER_DOWN_OUTSIDE = "dismissableLayer.pointerDownOutside";
var FOCUS_OUTSIDE = "dismissableLayer.focusOutside";
var originalBodyPointerEvents;
var DismissableLayerContext = reactExports.createContext({
layers: /* @__PURE__ */ new Set(),
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
branches: /* @__PURE__ */ new Set()
});
var DismissableLayer = reactExports.forwardRef(
(props, forwardedRef) => {
const {
disableOutsidePointerEvents = false,
onEscapeKeyDown,
onPointerDownOutside,
onFocusOutside,
onInteractOutside,
onDismiss,
...layerProps
} = props;
const context = reactExports.useContext(DismissableLayerContext);
const [node, setNode] = reactExports.useState(null);
const ownerDocument = (node == null ? void 0 : node.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document);
const [, force] = reactExports.useState({});
const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
const layers = Array.from(context.layers);
const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled);
const index2 = node ? layers.indexOf(node) : -1;
const isBodyPointerEventsDisabled = context.layersWithOutsidePointerEventsDisabled.size > 0;
const isPointerEventsEnabled = index2 >= highestLayerWithOutsidePointerEventsDisabledIndex;
const pointerDownOutside = usePointerDownOutside((event) => {
const target = event.target;
const isPointerDownOnBranch = [...context.branches].some((branch) => branch.contains(target));
if (!isPointerEventsEnabled || isPointerDownOnBranch) return;
onPointerDownOutside == null ? void 0 : onPointerDownOutside(event);
onInteractOutside == null ? void 0 : onInteractOutside(event);
if (!event.defaultPrevented) onDismiss == null ? void 0 : onDismiss();
}, ownerDocument);
const focusOutside = useFocusOutside((event) => {
const target = event.target;
const isFocusInBranch = [...context.branches].some((branch) => branch.contains(target));
if (isFocusInBranch) return;
onFocusOutside == null ? void 0 : onFocusOutside(event);
onInteractOutside == null ? void 0 : onInteractOutside(event);
if (!event.defaultPrevented) onDismiss == null ? void 0 : onDismiss();
}, ownerDocument);
useEscapeKeydown((event) => {
const isHighestLayer = index2 === context.layers.size - 1;
if (!isHighestLayer) return;
onEscapeKeyDown == null ? void 0 : onEscapeKeyDown(event);
if (!event.defaultPrevented && onDismiss) {
event.preventDefault();
onDismiss();
}
}, ownerDocument);
reactExports.useEffect(() => {
if (!node) return;
if (disableOutsidePointerEvents) {
if (context.layersWithOutsidePointerEventsDisabled.size === 0) {
originalBodyPointerEvents = ownerDocument.body.style.pointerEvents;
ownerDocument.body.style.pointerEvents = "none";
}
context.layersWithOutsidePointerEventsDisabled.add(node);
}
context.layers.add(node);
dispatchUpdate();
return () => {
if (disableOutsidePointerEvents && context.layersWithOutsidePointerEventsDisabled.size === 1) {
ownerDocument.body.style.pointerEvents = originalBodyPointerEvents;
}
};
}, [node, ownerDocument, disableOutsidePointerEvents, context]);
reactExports.useEffect(() => {
return () => {
if (!node) return;
context.layers.delete(node);
context.layersWithOutsidePointerEventsDisabled.delete(node);
dispatchUpdate();
};
}, [node, context]);
reactExports.useEffect(() => {
const handleUpdate = () => force({});
document.addEventListener(CONTEXT_UPDATE, handleUpdate);
return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);
}, []);
return /* @__PURE__ */ jsxRuntimeExports.jsx(
Primitive.div,
{
...layerProps,
ref: composedRefs,
style: {
pointerEvents: isBodyPointerEventsDisabled ? isPointerEventsEnabled ? "auto" : "none" : void 0,
...props.style
},
onFocusCapture: composeEventHandlers(props.onFocusCapture, focusOutside.onFocusCapture),
onBlurCapture: composeEventHandlers(props.onBlurCapture, focusOutside.onBlurCapture),
onPointerDownCapture: composeEventHandlers(
props.onPointerDownCapture,
pointerDownOutside.onPointerDownCapture
)
}
);
}
);
DismissableLayer.displayName = DISMISSABLE_LAYER_NAME;
var BRANCH_NAME = "DismissableLayerBranch";
var DismissableLayerBranch = reactExports.forwardRef((props, forwardedRef) => {
const context = reactExports.useContext(DismissableLayerContext);
const ref = reactExports.useRef(null);
const composedRefs = useComposedRefs(forwardedRef, ref);
reactExports.useEffect(() => {
const node = ref.current;
if (node) {
context.branches.add(node);
return () => {
context.branches.delete(node);
};
}
}, [context.branches]);
return /* @__PURE__ */ jsxRuntimeExports.jsx(Primitive.div, { ...props, ref: composedRefs });
});
DismissableLayerBranch.displayName = BRANCH_NAME;
function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);
const isPointerInsideReactTreeRef = reactExports.useRef(false);
const handleClickRef = reactExports.useRef(() => {
});
reactExports.useEffect(() => {
const handlePointerDown = (event) => {
if (event.target && !isPointerInsideReactTreeRef.current) {
let handleAndDispatchPointerDownOutsideEvent2 = function() {
handleAndDispatchCustomEvent$1(
POINTER_DOWN_OUTSIDE,
handlePointerDownOutside,
eventDetail,
{ discrete: true }
);
};
const eventDetail = { originalEvent: event };
if (event.pointerType === "touch") {
ownerDocument.removeEventListener("click", handleClickRef.current);
handleClickRef.current = handleAndDispatchPointerDownOutsideEvent2;
ownerDocument.addEventListener("click", handleClickRef.current, { once: true });
} else {
handleAndDispatchPointerDownOutsideEvent2();
}
} else {
ownerDocument.removeEventListener("click", handleClickRef.current);
}
isPointerInsideReactTreeRef.current = false;
};
const timerId = window.setTimeout(() => {
ownerDocument.addEventListener("pointerdown", handlePointerDown);
}, 0);
return () => {
window.clearTimeout(timerId);
ownerDocument.removeEventListener("pointerdown", handlePointerDown);
ownerDocument.removeEventListener("click", handleClickRef.current);
};
}, [ownerDocument, handlePointerDownOutside]);
return {
// ensures we check React component tree (not just DOM tree)
onPointerDownCapture: () => isPointerInsideReactTreeRef.current = true
};
}
function useFocusOutside(onFocusOutside, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
const handleFocusOutside = useCallbackRef(onFocusOutside);
const isFocusInsideReactTreeRef = reactExports.useRef(false);
reactExports.useEffect(() => {
const handleFocus = (event) => {
if (event.target && !isFocusInsideReactTreeRef.current) {
const eventDetail = { originalEvent: event };
handleAndDispatchCustomEvent$1(FOCUS_OUTSIDE, handleFocusOutside, eventDetail, {
discrete: false
});
}
};
ownerDocument.addEventListener("focusin", handleFocus);
return () => ownerDocument.removeEventListener("focusin", handleFocus);
}, [ownerDocument, handleFocusOutside]);
return {
onFocusCapture: () => isFocusInsideReactTreeRef.current = true,
onBlurCapture: () => isFocusInsideReactTreeRef.current = false
};
}
function dispatchUpdate() {
const event = new CustomEvent(CONTEXT_UPDATE);
document.dispatchEvent(event);
}
function handleAndDispatchCustomEvent$1(name, handler, detail, { discrete }) {
const target = detail.originalEvent.target;
const event = new CustomEvent(name, { bubbles: false, cancelable: true, detail });
if (handler) target.addEventListener(name, handler, { once: true });
if (discrete) {
dispatchDiscreteCustomEvent(target, event);
} else {
target.dispatchEvent(event);
}
}
var Root$2 = DismissableLayer;
var Branch = DismissableLayerBranch;
var useLayoutEffect2 = (globalThis == null ? void 0 : globalThis.document) ? reactExports.useLayoutEffect : () => {
};
var PORTAL_NAME$1 = "Portal";
var Portal = reactExports.forwardRef((props, forwardedRef) => {
var _a2;
const { container: containerProp, ...portalProps } = props;
const [mounted, setMounted] = reactExports.useState(false);
useLayoutEffect2(() => setMounted(true), []);
const container = containerProp || mounted && ((_a2 = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : _a2.body);
return container ? ReactDOM.createPortal(/* @__PURE__ */ jsxRuntimeExports.jsx(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;
});
Portal.displayName = PORTAL_NAME$1;
function useStateMachine(initialState, machine) {
return reactExports.useReducer((state, event) => {
const nextState = machine[state][event];
return nextState ?? state;
}, initialState);
}
var Presence = (props) => {
const { present, children } = props;
const presence = usePresence(present);
const child = typeof children === "function" ? children({ present: presence.isPresent }) : reactExports.Children.only(children);
const ref = useComposedRefs(presence.ref, getElementRef(child));
const forceMount = typeof children === "function";
return forceMount || presence.isPresent ? reactExports.cloneElement(child, { ref }) : null;
};
Presence.displayName = "Presence";
function usePresence(present) {
const [node, setNode] = reactExports.useState();
const stylesRef = reactExports.useRef(null);
const prevPresentRef = reactExports.useRef(present);
const prevAnimationNameRef = reactExports.useRef("none");
const initialState = present ? "mounted" : "unmounted";
const [state, send] = useStateMachine(initialState, {
mounted: {
UNMOUNT: "unmounted",
ANIMATION_OUT: "unmountSuspended"
},
unmountSuspended: {
MOUNT: "mounted",
ANIMATION_END: "unmounted"
},
unmounted: {
MOUNT: "mounted"
}
});
reactExports.useEffect(() => {
const currentAnimationName = getAnimationName(stylesRef.current);
prevAnimationNameRef.current = state === "mounted" ? currentAnimationName : "none";
}, [state]);
useLayoutEffect2(() => {
const styles = stylesRef.current;
const wasPresent = prevPresentRef.current;
const hasPresentChanged = wasPresent !== present;
if (hasPresentChanged) {
const prevAnimationName = prevAnimationNameRef.current;
const currentAnimationName = getAnimationName(styles);
if (present) {
send("MOUNT");
} else if (currentAnimationName === "none" || (styles == null ? void 0 : styles.display) === "none") {
send("UNMOUNT");
} else {
const isAnimating = prevAnimationName !== currentAnimationName;
if (wasPresent && isAnimating) {
send("ANIMATION_OUT");
} else {
send("UNMOUNT");
}
}
prevPresentRef.current = present;
}
}, [present, send]);
useLayoutEffect2(() => {
if (node) {
let timeoutId;
const ownerWindow = node.ownerDocument.defaultView ?? window;
const handleAnimationEnd = (event) => {
const currentAnimationName = getAnimationName(stylesRef.current);
const isCurrentAnimation = currentAnimationName.includes(event.animationName);
if (event.target === node && isCurrentAnimation) {
send("ANIMATION_END");
if (!prevPresentRef.current) {
const currentFillMode = node.style.animationFillMode;
node.style.animationFillMode = "forwards";
timeoutId = ownerWindow.setTimeout(() => {
if (node.style.animationFillMode === "forwards") {
node.style.animationFillMode = currentFillMode;
}
});
}
}
};
const handleAnimationStart = (event) => {
if (event.target === node) {
prevAnimationNameRef.current = getAnimationName(stylesRef.current);
}
};
node.addEventListener("animationstart", handleAnimationStart);
node.addEventListener("animationcancel", handleAnimationEnd);
node.addEventListener("animationend", handleAnimationEnd);
return () => {
ownerWindow.clearTimeout(timeoutId);
node.removeEventListener("animationstart", handleAnimationStart);
node.removeEventListener("animationcancel", handleAnimationEnd);
node.removeEventListener("animationend", handleAnimationEnd);
};
} else {
send("ANIMATION_END");
}
}, [node, send]);
return {
isPresent: ["mounted", "unmountSuspended"].includes(state),
ref: reactExports.useCallback((node2) => {
stylesRef.current = node2 ? getComputedStyle(node2) : null;
setNode(node2);
}, [])
};
}
function getAnimationName(styles) {
return (styles == null ? void 0 : styles.animationName) || "none";
}
function getElementRef(element) {
var _a2, _b2;
let getter = (_a2 = Object.getOwnPropertyDescriptor(element.props, "ref")) == null ? void 0 : _a2.get;
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
if (mayWarn) {
return element.ref;
}
getter = (_b2 = Object.getOwnPropertyDescriptor(element, "ref")) == null ? void 0 : _b2.get;
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
if (mayWarn) {
return element.props.ref;
}
return element.props.ref || element.ref;
}
var useInsertionEffect = React[" useInsertionEffect ".trim().toString()] || useLayoutEffect2;
function useControllableState({
prop,
defaultProp,
onChange = () => {
},
caller
}) {
const [uncontrolledProp, setUncontrolledProp, onChangeRef] = useUncontrolledState({
defaultProp,
onChange
});
const isControlled = prop !== void 0;
const value = isControlled ? prop : uncontrolledProp;
{
const isControlledRef = reactExports.useRef(prop !== void 0);
reactExports.useEffect(() => {
const wasControlled = isControlledRef.current;
if (wasControlled !== isControlled) {
const from = wasControlled ? "controlled" : "uncontrolled";
const to = isControlled ? "controlled" : "uncontrolled";
console.warn(
`${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`
);
}
isControlledRef.current = isControlled;
}, [isControlled, caller]);
}
const setValue = reactExports.useCallback(
(nextValue) => {
var _a2;
if (isControlled) {
const value2 = isFunction(nextValue) ? nextValue(prop) : nextValue;
if (value2 !== prop) {
(_a2 = onChangeRef.current) == null ? void 0 : _a2.call(onChangeRef, value2);
}
} else {
setUncontrolledProp(nextValue);
}
},
[isControlled, prop, setUncontrolledProp, onChangeRef]
);
return [value, setValue];
}
function useUncontrolledState({
defaultProp,
onChange
}) {
const [value, setValue] = reactExports.useState(defaultProp);
const prevValueRef = reactExports.useRef(value);
const onChangeRef = reactExports.useRef(onChange);
useInsertionEffect(() => {
onChangeRef.current = onChange;
}, [onChange]);
reactExports.useEffect(() => {
var _a2;
if (prevValueRef.current !== value) {
(_a2 = onChangeRef.current) == null ? void 0 : _a2.call(onChangeRef, value);
prevValueRef.current = value;
}
}, [value, prevValueRef]);
return [value, setValue, onChangeRef];
}
function isFunction(value) {
return typeof value === "function";
}
var VISUALLY_HIDDEN_STYLES = Object.freeze({
// See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
position: "absolute",
border: 0,
width: 1,
height: 1,
padding: 0,
margin: -1,
overflow: "hidden",
clip: "rect(0, 0, 0, 0)",
whiteSpace: "nowrap",
wordWrap: "normal"
});
var NAME$1 = "VisuallyHidden";
var VisuallyHidden = reactExports.forwardRef(
(props, forwardedRef) => {
return /* @__PURE__ */ jsxRuntimeExports.jsx(
Primitive.span,
{
...props,
ref: forwardedRef,
style: { ...VISUALLY_HIDDEN_STYLES, ...props.style }
}
);
}
);
VisuallyHidden.displayName = NAME$1;
var Root$1 = VisuallyHidden;
var PROVIDER_NAME$1 = "ToastProvider";
var [Collection, useCollection, createCollectionScope] = createCollection("Toast");
var [createToastContext, createToastScope] = createContextScope("Toast", [createCollectionScope]);
var [ToastProviderProvider, useToastProviderContext] = createToastContext(PROVIDER_NAME$1);
var ToastProvider$1 = (props) => {
const {
__scopeToast,
label = "Notification",
duration = 5e3,
swipeDirection = "right",
swipeThreshold = 50,
children
} = props;
const [viewport, setViewport] = reactExports.useState(null);
const [toastCount, setToastCount] = reactExports.useState(0);
const isFocusedToastEscapeKeyDownRef = reactExports.useRef(false);
const isClosePausedRef = reactExports.useRef(false);
if (!label.trim()) {
console.error(
`Invalid prop \`label\` supplied to \`${PROVIDER_NAME$1}\`. Expected non-empty \`string\`.`
);
}
return /* @__PURE__ */ jsxRuntimeExports.jsx(Collection.Provider, { scope: __scopeToast, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
ToastProviderProvider,
{
scope: __scopeToast,
label,
duration,
swipeDirection,
swipeThreshold,
toastCount,
viewport,
onViewportChange: setViewport,
onToastAdd: reactExports.useCallback(() => setToastCount((prevCount) => prevCount + 1), []),
onToastRemove: reactExports.useCallback(() => setToastCount((prevCount) => prevCount - 1), []),
isFocusedToastEscapeKeyDownRef,
isClosePausedRef,
children
}
) });
};
ToastProvider$1.displayName = PROVIDER_NAME$1;
var VIEWPORT_NAME = "ToastViewport";
var VIEWPORT_DEFAULT_HOTKEY = ["F8"];
var VIEWPORT_PAUSE = "toast.viewportPause";
var VIEWPORT_RESUME = "toast.viewportResume";
var ToastViewport$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const {
__scopeToast,
hotkey = VIEWPORT_DEFAULT_HOTKEY,
label = "Notifications ({hotkey})",
...viewportProps
} = props;
const context = useToastProviderContext(VIEWPORT_NAME, __scopeToast);
const getItems = useCollection(__scopeToast);
const wrapperRef = reactExports.useRef(null);
const headFocusProxyRef = reactExports.useRef(null);
const tailFocusProxyRef = reactExports.useRef(null);
const ref = reactExports.useRef(null);
const composedRefs = useComposedRefs(forwardedRef, ref, context.onViewportChange);
const hotkeyLabel = hotkey.join("+").replace(/Key/g, "").replace(/Digit/g, "");
const hasToasts = context.toastCount > 0;
reactExports.useEffect(() => {
const handleKeyDown = (event) => {
var _a2;
const isHotkeyPressed = hotkey.length !== 0 && hotkey.every((key) => event[key] || event.code === key);
if (isHotkeyPressed) (_a2 = ref.current) == null ? void 0 : _a2.focus();
};
document.addEventListener("keydown", handleKeyDown);
return () => document.removeEventListener("keydown", handleKeyDown);
}, [hotkey]);
reactExports.useEffect(() => {
const wrapper = wrapperRef.current;
const viewport = ref.current;
if (hasToasts && wrapper && viewport) {
const handlePause = () => {
if (!context.isClosePausedRef.current) {
const pauseEvent = new CustomEvent(VIEWPORT_PAUSE);
viewport.dispatchEvent(pauseEvent);
context.isClosePausedRef.current = true;
}
};
const handleResume = () => {
if (context.isClosePausedRef.current) {
const resumeEvent = new CustomEvent(VIEWPORT_RESUME);
viewport.dispatchEvent(resumeEvent);
context.isClosePausedRef.current = false;
}
};
const handleFocusOutResume = (event) => {
const isFocusMovingOutside = !wrapper.contains(event.relatedTarget);
if (isFocusMovingOutside) handleResume();
};
const handlePointerLeaveResume = () => {
const isFocusInside = wrapper.contains(document.activeElement);
if (!isFocusInside) handleResume();
};
wrapper.addEventListener("focusin", handlePause);
wrapper.addEventListener("focusout", handleFocusOutResume);
wrapper.addEventListener("pointermove", handlePause);
wrapper.addEventListener("pointerleave", handlePointerLeaveResume);
window.addEventListener("blur", handlePause);
window.addEventListener("focus", handleResume);
return () => {
wrapper.removeEventListener("focusin", handlePause);
wrapper.removeEventListener("focusout", handleFocusOutResume);
wrapper.removeEventListener("pointermove", handlePause);
wrapper.removeEventListener("pointerleave", handlePointerLeaveResume);
window.removeEventListener("blur", handlePause);
window.removeEventListener("focus", handleResume);
};
}
}, [hasToasts, context.isClosePausedRef]);
const getSortedTabbableCandidates = reactExports.useCallback(
({ tabbingDirection }) => {
const toastItems = getItems();
const tabbableCandidates = toastItems.map((toastItem) => {
const toastNode = toastItem.ref.current;
const toastTabbableCandidates = [toastNode, ...getTabbableCandidates(toastNode)];
return tabbingDirection === "forwards" ? toastTabbableCandidates : toastTabbableCandidates.reverse();
});
return (tabbingDirection === "forwards" ? tabbableCandidates.reverse() : tabbableCandidates).flat();
},
[getItems]
);
reactExports.useEffect(() => {
const viewport = ref.current;
if (viewport) {
const handleKeyDown = (event) => {
var _a2, _b2, _c2;
const isMetaKey = event.altKey || event.ctrlKey || event.metaKey;
const isTabKey = event.key === "Tab" && !isMetaKey;
if (isTabKey) {
const focusedElement = document.activeElement;
const isTabbingBackwards = event.shiftKey;
const targetIsViewport = event.target === viewport;
if (targetIsViewport && isTabbingBackwards) {
(_a2 = headFocusProxyRef.current) == null ? void 0 : _a2.focus();
return;
}
const tabbingDirection = isTabbingBackwards ? "backwards" : "forwards";
const sortedCandidates = getSortedTabbableCandidates({ tabbingDirection });
const index2 = sortedCandidates.findIndex((candidate) => candidate === focusedElement);
if (focusFirst(sortedCandidates.slice(index2 + 1))) {
event.preventDefault();
} else {
isTabbingBackwards ? (_b2 = headFocusProxyRef.current) == null ? void 0 : _b2.focus() : (_c2 = tailFocusProxyRef.current) == null ? void 0 : _c2.focus();
}
}
};
viewport.addEventListener("keydown", handleKeyDown);
return () => viewport.removeEventListener("keydown", handleKeyDown);
}
}, [getItems, getSortedTabbableCandidates]);
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
Branch,
{
ref: wrapperRef,
role: "region",
"aria-label": label.replace("{hotkey}", hotkeyLabel),
tabIndex: -1,
style: { pointerEvents: hasToasts ? void 0 : "none" },
children: [
hasToasts && /* @__PURE__ */ jsxRuntimeExports.jsx(
FocusProxy,
{
ref: headFocusProxyRef,
onFocusFromOutsideViewport: () => {
const tabbableCandidates = getSortedTabbableCandidates({
tabbingDirection: "forwards"
});
focusFirst(tabbableCandidates);
}
}
),
/* @__PURE__ */ jsxRuntimeExports.jsx(Collection.Slot, { scope: __scopeToast, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Primitive.ol, { tabIndex: -1, ...viewportProps, ref: composedRefs }) }),
hasToasts && /* @__PURE__ */ jsxRuntimeExports.jsx(
FocusProxy,
{
ref: tailFocusProxyRef,
onFocusFromOutsideViewport: () => {
const tabbableCandidates = getSortedTabbableCandidates({
tabbingDirection: "backwards"
});
focusFirst(tabbableCandidates);
}
}
)
]
}
);
}
);
ToastViewport$1.displayName = VIEWPORT_NAME;
var FOCUS_PROXY_NAME = "ToastFocusProxy";
var FocusProxy = reactExports.forwardRef(
(props, forwardedRef) => {
const { __scopeToast, onFocusFromOutsideViewport, ...proxyProps } = props;
const context = useToastProviderContext(FOCUS_PROXY_NAME, __scopeToast);
return /* @__PURE__ */ jsxRuntimeExports.jsx(
VisuallyHidden,
{
"aria-hidden": true,
tabIndex: 0,
...proxyProps,
ref: forwardedRef,
style: { position: "fixed" },
onFocus: (event) => {
var _a2;
const prevFocusedElement = event.relatedTarget;
const isFocusFromOutsideViewport = !((_a2 = context.viewport) == null ? void 0 : _a2.contains(prevFocusedElement));
if (isFocusFromOutsideViewport) onFocusFromOutsideViewport();
}
}
);
}
);
FocusProxy.displayName = FOCUS_PROXY_NAME;
var TOAST_NAME = "Toast";
var TOAST_SWIPE_START = "toast.swipeStart";
var TOAST_SWIPE_MOVE = "toast.swipeMove";
var TOAST_SWIPE_CANCEL = "toast.swipeCancel";
var TOAST_SWIPE_END = "toast.swipeEnd";
var Toast$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const { forceMount, open: openProp, defaultOpen, onOpenChange, ...toastProps } = props;
const [open, setOpen] = useControllableState({
prop: openProp,
defaultProp: defaultOpen ?? true,
onChange: onOpenChange,
caller: TOAST_NAME
});
return /* @__PURE__ */ jsxRuntimeExports.jsx(Presence, { present: forceMount || open, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
ToastImpl,
{
open,
...toastProps,
ref: forwardedRef,
onClose: () => setOpen(false),
onPause: useCallbackRef(props.onPause),
onResume: useCallbackRef(props.onResume),
onSwipeStart: composeEventHandlers(props.onSwipeStart, (event) => {
event.currentTarget.setAttribute("data-swipe", "start");
}),
onSwipeMove: composeEventHandlers(props.onSwipeMove, (event) => {
const { x: x2, y: y2 } = event.detail.delta;
event.currentTarget.setAttribute("data-swipe", "move");
event.currentTarget.style.setProperty("--radix-toast-swipe-move-x", `${x2}px`);
event.currentTarget.style.setProperty("--radix-toast-swipe-move-y", `${y2}px`);
}),
onSwipeCancel: composeEventHandlers(props.onSwipeCancel, (event) => {
event.currentTarget.setAttribute("data-swipe", "cancel");
event.currentTarget.style.removeProperty("--radix-toast-swipe-move-x");
event.currentTarget.style.removeProperty("--radix-toast-swipe-move-y");
event.currentTarget.style.removeProperty("--radix-toast-swipe-end-x");
event.currentTarget.style.removeProperty("--radix-toast-swipe-end-y");
}),
onSwipeEnd: composeEventHandlers(props.onSwipeEnd, (event) => {
const { x: x2, y: y2 } = event.detail.delta;
event.currentTarget.setAttribute("data-swipe", "end");
event.currentTarget.style.removeProperty("--radix-toast-swipe-move-x");
event.currentTarget.style.removeProperty("--radix-toast-swipe-move-y");
event.currentTarget.style.setProperty("--radix-toast-swipe-end-x", `${x2}px`);
event.currentTarget.style.setProperty("--radix-toast-swipe-end-y", `${y2}px`);
setOpen(false);
})
}
) });
}
);
Toast$1.displayName = TOAST_NAME;
var [ToastInteractiveProvider, useToastInteractiveContext] = createToastContext(TOAST_NAME, {
onClose() {
}
});
var ToastImpl = reactExports.forwardRef(
(props, forwardedRef) => {
const {
__scopeToast,
type = "foreground",
duration: durationProp,
open,
onClose,
onEscapeKeyDown,
onPause,
onResume,
onSwipeStart,
onSwipeMove,
onSwipeCancel,
onSwipeEnd,
...toastProps
} = props;
const context = useToastProviderContext(TOAST_NAME, __scopeToast);
const [node, setNode] = reactExports.useState(null);
const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
const pointerStartRef = reactExports.useRef(null);
const swipeDeltaRef = reactExports.useRef(null);
const duration = durationProp || context.duration;
const closeTimerStartTimeRef = reactExports.useRef(0);
const closeTimerRemainingTimeRef = reactExports.useRef(duration);
const closeTimerRef = reactExports.useRef(0);
const { onToastAdd, onToastRemove } = context;
const handleClose = useCallbackRef(() => {
var _a2;
const isFocusInToast = node == null ? void 0 : node.contains(document.activeElement);
if (isFocusInToast) (_a2 = context.viewport) == null ? void 0 : _a2.focus();
onClose();
});
const startTimer = reactExports.useCallback(
(duration2) => {
if (!duration2 || duration2 === Infinity) return;
window.clearTimeout(closeTimerRef.current);
closeTimerStartTimeRef.current = (/* @__PURE__ */ new Date()).getTime();
closeTimerRef.current = window.setTimeout(handleClose, duration2);
},
[handleClose]
);
reactExports.useEffect(() => {
const viewport = context.viewport;
if (viewport) {
const handleResume = () => {
startTimer(closeTimerRemainingTimeRef.current);
onResume == null ? void 0 : onResume();
};
const handlePause = () => {
const elapsedTime = (/* @__PURE__ */ new Date()).getTime() - closeTimerStartTimeRef.current;
closeTimerRemainingTimeRef.current = closeTimerRemainingTimeRef.current - elapsedTime;
window.clearTimeout(closeTimerRef.current);
onPause == null ? void 0 : onPause();
};
viewport.addEventListener(VIEWPORT_PAUSE, handlePause);
viewport.addEventListener(VIEWPORT_RESUME, handleResume);
return () => {
viewport.removeEventListener(VIEWPORT_PAUSE, handlePause);
viewport.removeEventListener(VIEWPORT_RESUME, handleResume);
};
}
}, [context.viewport, duration, onPause, onResume, startTimer]);
reactExports.useEffect(() => {
if (open && !context.isClosePausedRef.current) startTimer(duration);
}, [open, duration, context.isClosePausedRef, startTimer]);
reactExports.useEffect(() => {
onToastAdd();
return () => onToastRemove();
}, [onToastAdd, onToastRemove]);
const announceTextContent = reactExports.useMemo(() => {
return node ? getAnnounceTextContent(node) : null;
}, [node]);
if (!context.viewport) return null;
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
announceTextContent && /* @__PURE__ */ jsxRuntimeExports.jsx(
ToastAnnounce,
{
__scopeToast,
role: "status",
"aria-live": type === "foreground" ? "assertive" : "polite",
"aria-atomic": true,
children: announceTextContent
}
),
/* @__PURE__ */ jsxRuntimeExports.jsx(ToastInteractiveProvider, { scope: __scopeToast, onClose: handleClose, children: reactDomExports.createPortal(
/* @__PURE__ */ jsxRuntimeExports.jsx(Collection.ItemSlot, { scope: __scopeToast, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
Root$2,
{
asChild: true,
onEscapeKeyDown: composeEventHandlers(onEscapeKeyDown, () => {
if (!context.isFocusedToastEscapeKeyDownRef.current) handleClose();
context.isFocusedToastEscapeKeyDownRef.current = false;
}),
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
Primitive.li,
{
role: "status",
"aria-live": "off",
"aria-atomic": true,
tabIndex: 0,
"data-state": open ? "open" : "closed",
"data-swipe-direction": context.swipeDirection,
...toastProps,
ref: composedRefs,
style: { userSelect: "none", touchAction: "none", ...props.style },
onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {
if (event.key !== "Escape") return;
onEscapeKeyDown == null ? void 0 : onEscapeKeyDown(event.nativeEvent);
if (!event.nativeEvent.defaultPrevented) {
context.isFocusedToastEscapeKeyDownRef.current = true;
handleClose();
}
}),
onPointerDown: composeEventHandlers(props.onPointerDown, (event) => {
if (event.button !== 0) return;
pointerStartRef.current = { x: event.clientX, y: event.clientY };
}),
onPointerMove: composeEventHandlers(props.onPointerMove, (event) => {
if (!pointerStartRef.current) return;
const x2 = event.clientX - pointerStartRef.current.x;
const y2 = event.clientY - pointerStartRef.current.y;
const hasSwipeMoveStarted = Boolean(swipeDeltaRef.current);
const isHorizontalSwipe = ["left", "right"].includes(context.swipeDirection);
const clamp2 = ["left", "up"].includes(context.swipeDirection) ? Math.min : Math.max;
const clampedX = isHorizontalSwipe ? clamp2(0, x2) : 0;
const clampedY = !isHorizontalSwipe ? clamp2(0, y2) : 0;
const moveStartBuffer = event.pointerType === "touch" ? 10 : 2;
const delta = { x: clampedX, y: clampedY };
const eventDetail = { originalEvent: event, delta };
if (hasSwipeMoveStarted) {
swipeDeltaRef.current = delta;
handleAndDispatchCustomEvent(TOAST_SWIPE_MOVE, onSwipeMove, eventDetail, {
discrete: false
});
} else if (isDeltaInDirection(delta, context.swipeDirection, moveStartBuffer)) {
swipeDeltaRef.current = delta;
handleAndDispatchCustomEvent(TOAST_SWIPE_START, onSwipeStart, eventDetail, {
discrete: false
});
event.target.setPointerCapture(event.pointerId);
} else if (Math.abs(x2) > moveStartBuffer || Math.abs(y2) > moveStartBuffer) {
pointerStartRef.current = null;
}
}),
onPointerUp: composeEventHandlers(props.onPointerUp, (event) => {
const delta = swipeDeltaRef.current;
const target = event.target;
if (target.hasPointerCapture(event.pointerId)) {
target.releasePointerCapture(event.pointerId);
}
swipeDeltaRef.current = null;
pointerStartRef.current = null;
if (delta) {
const toast2 = event.currentTarget;
const eventDetail = { originalEvent: event, delta };
if (isDeltaInDirection(delta, context.swipeDirection, context.swipeThreshold)) {
handleAndDispatchCustomEvent(TOAST_SWIPE_END, onSwipeEnd, eventDetail, {
discrete: true
});
} else {
handleAndDispatchCustomEvent(
TOAST_SWIPE_CANCEL,
onSwipeCancel,
eventDetail,
{
discrete: true
}
);
}
toast2.addEventListener("click", (event2) => event2.preventDefault(), {
once: true
});
}
})
}
)
}
) }),
context.viewport
) })
] });
}
);
var ToastAnnounce = (props) => {
const { __scopeToast, children, ...announceProps } = props;
const context = useToastProviderContext(TOAST_NAME, __scopeToast);
const [renderAnnounceText, setRenderAnnounceText] = reactExports.useState(false);
const [isAnnounced, setIsAnnounced] = reactExports.useState(false);
useNextFrame(() => setRenderAnnounceText(true));
reactExports.useEffect(() => {
const timer = window.setTimeout(() => setIsAnnounced(true), 1e3);
return () => window.clearTimeout(timer);
}, []);
return isAnnounced ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(Portal, { asChild: true, children: /* @__PURE__ */ jsxRuntimeExports.jsx(VisuallyHidden, { ...announceProps, children: renderAnnounceText && /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
context.label,
" ",
children
] }) }) });
};
var TITLE_NAME = "ToastTitle";
var ToastTitle$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const { __scopeToast, ...titleProps } = props;
return /* @__PURE__ */ jsxRuntimeExports.jsx(Primitive.div, { ...titleProps, ref: forwardedRef });
}
);
ToastTitle$1.displayName = TITLE_NAME;
var DESCRIPTION_NAME = "ToastDescription";
var ToastDescription$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const { __scopeToast, ...descriptionProps } = props;
return /* @__PURE__ */ jsxRuntimeExports.jsx(Primitive.div, { ...descriptionProps, ref: forwardedRef });
}
);
ToastDescription$1.displayName = DESCRIPTION_NAME;
var ACTION_NAME = "ToastAction";
var ToastAction$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const { altText, ...actionProps } = props;
if (!altText.trim()) {
console.error(
`Invalid prop \`altText\` supplied to \`${ACTION_NAME}\`. Expected non-empty \`string\`.`
);
return null;
}
return /* @__PURE__ */ jsxRuntimeExports.jsx(ToastAnnounceExclude, { altText, asChild: true, children: /* @__PURE__ */ jsxRuntimeExports.jsx(ToastClose$1, { ...actionProps, ref: forwardedRef }) });
}
);
ToastAction$1.displayName = ACTION_NAME;
var CLOSE_NAME = "ToastClose";
var ToastClose$1 = reactExports.forwardRef(
(props, forwardedRef) => {
const { __scopeToast, ...closeProps } = props;
const interactiveContext = useToastInteractiveContext(CLOSE_NAME, __scopeToast);
return /* @__PURE__ */ jsxRuntimeExports.jsx(ToastAnnounceExclude, { asChild: true, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
Primitive.button,
{
type: "button",
...closeProps,
ref: forwardedRef,
onClick: composeEventHandlers(props.onClick, interactiveContext.onClose)
}
) });
}
);
ToastClose$1.displayName = CLOSE_NAME;
var ToastAnnounceExclude = reactExports.forwardRef((props, forwardedRef) => {
const { __scopeToast, altText, ...announceExcludeProps } = props;
return /* @__PURE__ */ jsxRuntimeExports.jsx(
Primitive.div,
{
"data-radix-toast-announce-exclude": "",
"data-radix-toast-announce-alt": altText || void 0,
...announceExcludeProps,
ref: forwardedRef
}
);
});
function getAnnounceTextContent(container) {
const textContent = [];
const childNodes = Array.from(container.childNodes);
childNodes.forEach((node) => {
if (node.nodeType === node.TEXT_NODE && node.textContent) textContent.push(node.textContent);
if (isHTMLElement$1(node)) {
const isHidden = node.ariaHidden || node.hidden || node.style.display === "none";
const isExcluded = node.dataset.radixToastAnnounceExclude === "";
if (!isHidden) {
if (isExcluded) {
const altText = node.dataset.radixToastAnnounceAlt;
if (altText) textContent.push(altText);
} else {
textContent.push(...getAnnounceTextContent(node));
}
}
}
});
return textContent;
}
function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
const currentTarget = detail.originalEvent.currentTarget;
const event = new CustomEvent(name, { bubbles: true, cancelable: true, detail });
if (handler) currentTarget.addEventListener(name, handler, { once: true });
if (discrete) {
dispatchDiscreteCustomEvent(currentTarget, event);
} else {
currentTarget.dispatchEvent(event);
}
}
var isDeltaInDirection = (delta, direction, threshold = 0) => {
const deltaX = Math.abs(delta.x);
const deltaY = Math.abs(delta.y);
const isDeltaX = deltaX > deltaY;
if (direction === "left" || direction === "right") {
return isDeltaX && deltaX > threshold;
} else {
return !isDeltaX && deltaY > threshold;
}
};
function useNextFrame(callback = () => {
}) {
const fn = useCallbackRef(callback);
useLayoutEffect2(() => {
let raf1 = 0;
let raf2 = 0;
raf1 = window.requestAnimationFrame(() => raf2 = window.requestAnimationFrame(fn));
return () => {
window.cancelAnimationFrame(raf1);
window.cancelAnimationFrame(raf2);
};
}, [fn]);
}
function isHTMLElement$1(node) {
return node.nodeType === node.ELEMENT_NODE;
}
function getTabbableCandidates(container) {
const nodes = [];
const walker = document.createTreeWalker(container, NodeFilter.SHOW_ELEMENT, {
acceptNode: (node) => {
const isHiddenInput = node.tagName === "INPUT" && node.type === "hidden";
if (node.disabled || node.hidden || isHiddenInput) return NodeFilter.FILTER_SKIP;
return node.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
}
});
while (walker.nextNode()) nodes.push(walker.currentNode);
return nodes;
}
function focusFirst(candidates) {
const previouslyFocusedElement = document.activeElement;
return candidates.some((candidate) => {
if (candidate === previouslyFocusedElement) return true;
candidate.focus();
return document.activeElement !== previouslyFocusedElement;
});
}
var Provider$1 = ToastProvider$1;
var Viewport = ToastViewport$1;
var Root2 = Toast$1;
var Title = ToastTitle$1;
var Description = ToastDescription$1;
var Action = ToastAction$1;
var Close = ToastClose$1;
function r(e) {
var t2, f2, n2 = "";
if ("string" == typeof e || "number" == typeof e) n2 += e;
else if ("object" == typeof e) if (Array.isArray(e)) {
var o = e.length;
for (t2 = 0; t2 < o; t2++) e[t2] && (f2 = r(e[t2])) && (n2 && (n2 += " "), n2 += f2);
} else for (f2 in e) e[f2] && (n2 && (n2 += " "), n2 += f2);
return n2;
}
function clsx() {
for (var e, t2, f2 = 0, n2 = "", o = arguments.length; f2 < o; f2++) (e = arguments[f2]) && (t2 = r(e)) && (n2 && (n2 += " "), n2 += t2);
return n2;
}
const falsyToString = (value) => typeof value === "boolean" ? `${value}` : value === 0 ? "0" : value;
const cx = clsx;
const cva = (base, config) => (props) => {
var _config_compoundVariants;
if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
const { variants, defaultVariants } = config;
const getVariantClassNames = Object.keys(variants).map((variant) => {
const variantProp = props === null || props === void 0 ? void 0 : props[variant];
const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];
if (variantProp === null) return null;
const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);
return variants[variant][variantKey];
});
const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param) => {
let [key, value] = param;
if (value === void 0) {
return acc;
}
acc[key] = value;
return acc;
}, {});
const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param) => {
let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;
return Object.entries(compoundVariantOptions).every((param2) => {
let [key, value] = param2;
return Array.isArray(value) ? value.includes({
...defaultVariants,
...propsWithoutUndefined
}[key]) : {
...defaultVariants,
...propsWithoutUndefined
}[key] === value;
}) ? [
...acc,
cvClass,
cvClassName
] : acc;
}, []);
return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
};
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase();
const mergeClasses = (...classes) => classes.filter((className, index2, array) => {
return Boolean(className) && className.trim() !== "" && array.indexOf(className) === index2;
}).join(" ").trim();
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
var defaultAttributes = {
xmlns: "http://www.w3.org/2000/svg",
width: 24,
height: 24,
viewBox: "0 0 24 24",
fill: "none",
stroke: "currentColor",
strokeWidth: 2,
strokeLinecap: "round",
strokeLinejoin: "round"
};
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Icon = reactExports.forwardRef(
({
color = "currentColor",
size: size2 = 24,
strokeWidth = 2,
absoluteStrokeWidth,
className = "",
children,
iconNode,
...rest
}, ref) => {
return reactExports.createElement(
"svg",
{
ref,
...defaultAttributes,
width: size2,
height: size2,
stroke: color,
strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size2) : strokeWidth,
className: mergeClasses("lucide", className),
...rest
},
[
...iconNode.map(([tag, attrs]) => reactExports.createElement(tag, attrs)),
...Array.isArray(children) ? children : [children]
]
);
}
);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const createLucideIcon = (iconName, iconNode) => {
const Component = reactExports.forwardRef(
({ className, ...props }, ref) => reactExports.createElement(Icon, {
ref,
iconNode,
className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),
...props
})
);
Component.displayName = `${iconName}`;
return Component;
};
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Award = createLucideIcon("Award", [
[
"path",
{
d: "m15.477 12.89 1.515 8.526a.5.5 0 0 1-.81.47l-3.58-2.687a1 1 0 0 0-1.197 0l-3.586 2.686a.5.5 0 0 1-.81-.469l1.514-8.526",
key: "1yiouv"
}
],
["circle", { cx: "12", cy: "8", r: "6", key: "1vp47v" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const ChefHat = createLucideIcon("ChefHat", [
[
"path",
{
d: "M17 21a1 1 0 0 0 1-1v-5.35c0-.457.316-.844.727-1.041a4 4 0 0 0-2.134-7.589 5 5 0 0 0-9.186 0 4 4 0 0 0-2.134 7.588c.411.198.727.585.727 1.041V20a1 1 0 0 0 1 1Z",
key: "1qvrer"
}
],
["path", { d: "M6 17h12", key: "1jwigz" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Clock = createLucideIcon("Clock", [
["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
["polyline", { points: "12 6 12 12 16 14", key: "68esgv" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Facebook = createLucideIcon("Facebook", [
[
"path",
{ d: "M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z", key: "1jg4f8" }
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Flame = createLucideIcon("Flame", [
[
"path",
{
d: "M8.5 14.5A2.5 2.5 0 0 0 11 12c0-1.38-.5-2-1-3-1.072-2.143-.224-4.054 2-6 .5 2.5 2 4.9 4 6.5 2 1.6 3 3.5 3 5.5a7 7 0 1 1-14 0c0-1.153.433-2.294 1-3a2.5 2.5 0 0 0 2.5 2.5z",
key: "96xj49"
}
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Instagram = createLucideIcon("Instagram", [
["rect", { width: "20", height: "20", x: "2", y: "2", rx: "5", ry: "5", key: "2e1cvw" }],
["path", { d: "M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z", key: "9exkf1" }],
["line", { x1: "17.5", x2: "17.51", y1: "6.5", y2: "6.5", key: "r4j83e" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Leaf = createLucideIcon("Leaf", [
[
"path",
{
d: "M11 20A7 7 0 0 1 9.8 6.1C15.5 5 17 4.48 19 2c1 2 2 4.18 2 8 0 5.5-4.78 10-10 10Z",
key: "nnexq3"
}
],
["path", { d: "M2 21c0-3 1.85-5.36 5.08-6C9.5 14.52 12 13 13 12", key: "mt58a7" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const MapPin = createLucideIcon("MapPin", [
[
"path",
{
d: "M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",
key: "1r0f0z"
}
],
["circle", { cx: "12", cy: "10", r: "3", key: "ilqhr7" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Menu$1 = createLucideIcon("Menu", [
["line", { x1: "4", x2: "20", y1: "12", y2: "12", key: "1e0a9i" }],
["line", { x1: "4", x2: "20", y1: "6", y2: "6", key: "1owob3" }],
["line", { x1: "4", x2: "20", y1: "18", y2: "18", key: "yk5zj1" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Phone = createLucideIcon("Phone", [
[
"path",
{
d: "M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",
key: "foiqr5"
}
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Quote = createLucideIcon("Quote", [
[
"path",
{
d: "M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z",
key: "rib7q0"
}
],
[
"path",
{
d: "M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z",
key: "1ymkrd"
}
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Soup = createLucideIcon("Soup", [
["path", { d: "M12 21a9 9 0 0 0 9-9H3a9 9 0 0 0 9 9Z", key: "4rw317" }],
["path", { d: "M7 21h10", key: "1b0cd5" }],
["path", { d: "M19.5 12 22 6", key: "shfsr5" }],
[
"path",
{
d: "M16.25 3c.27.1.8.53.75 1.36-.06.83-.93 1.2-1 2.02-.05.78.34 1.24.73 1.62",
key: "rpc6vp"
}
],
[
"path",
{
d: "M11.25 3c.27.1.8.53.74 1.36-.05.83-.93 1.2-.98 2.02-.06.78.33 1.24.72 1.62",
key: "1lf63m"
}
],
[
"path",
{ d: "M6.25 3c.27.1.8.53.75 1.36-.06.83-.93 1.2-1 2.02-.05.78.34 1.24.74 1.62", key: "97tijn" }
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Star = createLucideIcon("Star", [
[
"path",
{
d: "M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",
key: "r04s7s"
}
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Twitter = createLucideIcon("Twitter", [
[
"path",
{
d: "M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z",
key: "pff0z6"
}
]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Users = createLucideIcon("Users", [
["path", { d: "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2", key: "1yyitq" }],
["circle", { cx: "9", cy: "7", r: "4", key: "nufk8" }],
["path", { d: "M22 21v-2a4 4 0 0 0-3-3.87", key: "kshegd" }],
["path", { d: "M16 3.13a4 4 0 0 1 0 7.75", key: "1da9ce" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const Utensils = createLucideIcon("Utensils", [
["path", { d: "M3 2v7c0 1.1.9 2 2 2h4a2 2 0 0 0 2-2V2", key: "cjf0a3" }],
["path", { d: "M7 2v20", key: "1473qp" }],
["path", { d: "M21 15V2a5 5 0 0 0-5 5v6c0 1.1.9 2 2 2h3Zm0 0v7", key: "j28e5" }]
]);
/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
const X = createLucideIcon("X", [
["path", { d: "M18 6 6 18", key: "1bl5f8" }],
["path", { d: "m6 6 12 12", key: "d8bk6v" }]
]);
const CLASS_PART_SEPARATOR = "-";
const createClassGroupUtils = (config) => {
const classMap = createClassMap(config);
const {
conflictingClassGroups,
conflictingClassGroupModifiers
} = config;
const getClassGroupId = (className) => {
const classParts = className.split(CLASS_PART_SEPARATOR);
if (classParts[0] === "" && classParts.length !== 1) {
classParts.shift();
}
return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);
};
const getConflictingClassGroupIds = (classGroupId, hasPostfixModifier) => {
const conflicts = conflictingClassGroups[classGroupId] || [];
if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {
return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];
}
return conflicts;
};
return {
getClassGroupId,
getConflictingClassGroupIds
};
};
const getGroupRecursive = (classParts, classPartObject) => {
var _a2;
if (classParts.length === 0) {
return classPartObject.classGroupId;
}
const currentClassPart = classParts[0];
const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);
const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : void 0;
if (classGroupFromNextClassPart) {
return classGroupFromNextClassPart;
}
if (classPartObject.validators.length === 0) {
return void 0;
}
const classRest = classParts.join(CLASS_PART_SEPARATOR);
return (_a2 = classPartObject.validators.find(({
validator
}) => validator(classRest))) == null ? void 0 : _a2.classGroupId;
};
const arbitraryPropertyRegex = /^\[(.+)\]$/;
const getGroupIdForArbitraryProperty = (className) => {
if (arbitraryPropertyRegex.test(className)) {
const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];
const property = arbitraryPropertyClassName == null ? void 0 : arbitraryPropertyClassName.substring(0, arbitraryPropertyClassName.indexOf(":"));
if (property) {
return "arbitrary.." + property;
}
}
};
const createClassMap = (config) => {
const {
theme,
prefix
} = config;
const classMap = {
nextPart: /* @__PURE__ */ new Map(),
validators: []
};
const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config.classGroups), prefix);
prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {
processClassesRecursively(classGroup, classMap, classGroupId, theme);
});
return classMap;
};
const processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {
classGroup.forEach((classDefinition) => {
if (typeof classDefinition === "string") {
const classPartObjectToEdit = classDefinition === "" ? classPartObject : getPart(classPartObject, classDefinition);
classPartObjectToEdit.classGroupId = classGroupId;
return;
}
if (typeof classDefinition === "function") {
if (isThemeGetter(classDefinition)) {
processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);
return;
}
classPartObject.validators.push({
validator: classDefinition,
classGroupId
});
return;
}
Object.entries(classDefinition).forEach(([key, classGroup2]) => {
processClassesRecursively(classGroup2, getPart(classPartObject, key), classGroupId, theme);
});
});
};
const getPart = (classPartObject, path) => {
let currentClassPartObject = classPartObject;
path.split(CLASS_PART_SEPARATOR).forEach((pathPart) => {
if (!currentClassPartObject.nextPart.has(pathPart)) {
currentClassPartObject.nextPart.set(pathPart, {
nextPart: /* @__PURE__ */ new Map(),
validators: []
});
}
currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);
});
return currentClassPartObject;
};
const isThemeGetter = (func) => func.isThemeGetter;
const getPrefixedClassGroupEntries = (classGroupEntries, prefix) => {
if (!prefix) {
return classGroupEntries;
}
return classGroupEntries.map(([classGroupId, classGroup]) => {
const prefixedClassGroup = classGroup.map((classDefinition) => {
if (typeof classDefinition === "string") {
return prefix + classDefinition;
}
if (typeof classDefinition === "object") {
return Object.fromEntries(Object.entries(classDefinition).map(([key, value]) => [prefix + key, value]));
}
return classDefinition;
});
return [classGroupId, prefixedClassGroup];
});
};
const createLruCache = (maxCacheSize) => {
if (maxCacheSize < 1) {
return {
get: () => void 0,
set: () => {
}
};
}
let cacheSize = 0;
let cache = /* @__PURE__ */ new Map();
let previousCache = /* @__PURE__ */ new Map();
const update = (key, value) => {
cache.set(key, value);
cacheSize++;
if (cacheSize > maxCacheSize) {
cacheSize = 0;
previousCache = cache;
cache = /* @__PURE__ */ new Map();
}
};
return {
get(key) {
let value = cache.get(key);
if (value !== void 0) {
return value;
}
if ((value = previousCache.get(key)) !== void 0) {
update(key, value);
return value;
}
},
set(key, value) {
if (cache.has(key)) {
cache.set(key, value);
} else {
update(key, value);
}
}
};
};
const IMPORTANT_MODIFIER = "!";
const createParseClassName = (config) => {
const {
separator,
experimentalParseClassName
} = config;
const isSeparatorSingleCharacter = separator.length === 1;
const firstSeparatorCharacter = separator[0];
const separatorLength = separator.length;
const parseClassName = (className) => {
const modifiers = [];
let bracketDepth = 0;
let modifierStart = 0;
let postfixModifierPosition;
for (let index2 = 0; index2 < className.length; index2++) {
let currentCharacter = className[index2];
if (bracketDepth === 0) {
if (currentCharacter === firstSeparatorCharacter && (isSeparatorSingleCharacter || className.slice(index2, index2 + separatorLength) === separator)) {
modifiers.push(className.slice(modifierStart, index2));
modifierStart = index2 + separatorLength;
continue;
}
if (currentCharacter === "/") {
postfixModifierPosition = index2;
continue;
}
}
if (currentCharacter === "[") {
bracketDepth++;
} else if (currentCharacter === "]") {
bracketDepth--;
}
}
const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);
const hasImportantModifier = baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER);
const baseClassName = hasImportantModifier ? baseClassNameWithImportantModifier.substring(1) : baseClassNameWithImportantModifier;
const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : void 0;
return {
modifiers,
hasImportantModifier,
baseClassName,
maybePostfixModifierPosition
};
};
if (experimentalParseClassName) {
return (className) => experimentalParseClassName({
className,
parseClassName
});
}
return parseClassName;
};
const sortModifiers = (modifiers) => {
if (modifiers.length <= 1) {
return modifiers;
}
const sortedModifiers = [];
let unsortedModifiers = [];
modifiers.forEach((modifier) => {
const isArbitraryVariant = modifier[0] === "[";
if (isArbitraryVariant) {
sortedModifiers.push(...unsortedModifiers.sort(), modifier);
unsortedModifiers = [];
} else {
unsortedModifiers.push(modifier);
}
});
sortedModifiers.push(...unsortedModifiers.sort());
return sortedModifiers;
};
const createConfigUtils = (config) => ({
cache: createLruCache(config.cacheSize),
parseClassName: createParseClassName(config),
...createClassGroupUtils(config)
});
const SPLIT_CLASSES_REGEX = /\s+/;
const mergeClassList = (classList, configUtils) => {
const {
parseClassName,
getClassGroupId,
getConflictingClassGroupIds
} = configUtils;
const classGroupsInConflict = [];
const classNames = classList.trim().split(SPLIT_CLASSES_REGEX);
let result = "";
for (let index2 = classNames.length - 1; index2 >= 0; index2 -= 1) {
const originalClassName = classNames[index2];
const {
modifiers,
hasImportantModifier,
baseClassName,
maybePostfixModifierPosition
} = parseClassName(originalClassName);
let hasPostfixModifier = Boolean(maybePostfixModifierPosition);
let classGroupId = getClassGroupId(hasPostfixModifier ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);
if (!classGroupId) {
if (!hasPostfixModifier) {
result = originalClassName + (result.length > 0 ? " " + result : result);
continue;
}
classGroupId = getClassGroupId(baseClassName);
if (!classGroupId) {
result = originalClassName + (result.length > 0 ? " " + result : result);
continue;
}
hasPostfixModifier = false;
}
const variantModifier = sortModifiers(modifiers).join(":");
const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;
const classId = modifierId + classGroupId;
if (classGroupsInConflict.includes(classId)) {
continue;
}
classGroupsInConflict.push(classId);
const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier);
for (let i = 0; i < conflictGroups.length; ++i) {
const group = conflictGroups[i];
classGroupsInConflict.push(modifierId + group);
}
result = originalClassName + (result.length > 0 ? " " + result : result);
}
return result;
};
function twJoin() {
let index2 = 0;
let argument;
let resolvedValue;
let string = "";
while (index2 < arguments.length) {
if (argument = arguments[index2++]) {
if (resolvedValue = toValue(argument)) {
string && (string += " ");
string += resolvedValue;
}
}
}
return string;
}
const toValue = (mix) => {
if (typeof mix === "string") {
return mix;
}
let resolvedValue;
let string = "";
for (let k2 = 0; k2 < mix.length; k2++) {
if (mix[k2]) {
if (resolvedValue = toValue(mix[k2])) {
string && (string += " ");
string += resolvedValue;
}
}
}
return string;
};
function createTailwindMerge(createConfigFirst, ...createConfigRest) {
let configUtils;
let cacheGet;
let cacheSet;
let functionToCall = initTailwindMerge;
function initTailwindMerge(classList) {
const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());
configUtils = createConfigUtils(config);
cacheGet = configUtils.cache.get;
cacheSet = configUtils.cache.set;
functionToCall = tailwindMerge;
return tailwindMerge(classList);
}
function tailwindMerge(classList) {
const cachedResult = cacheGet(classList);
if (cachedResult) {
return cachedResult;
}
const result = mergeClassList(classList, configUtils);
cacheSet(classList, result);
return result;
}
return function callTailwindMerge() {
return functionToCall(twJoin.apply(null, arguments));
};
}
const fromTheme = (key) => {
const themeGetter = (theme) => theme[key] || [];
themeGetter.isThemeGetter = true;
return themeGetter;
};
const arbitraryValueRegex = /^\[(?:([a-z-]+):)?(.+)\]$/i;
const fractionRegex = /^\d+\/\d+$/;
const stringLengths = /* @__PURE__ */ new Set(["px", "full", "screen"]);
const tshirtUnitRegex = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/;
const lengthUnitRegex = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/;
const colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/;
const shadowRegex = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;
const imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;
const isLength = (value) => isNumber(value) || stringLengths.has(value) || fractionRegex.test(value);
const isArbitraryLength = (value) => getIsArbitraryValue(value, "length", isLengthOnly);
const isNumber = (value) => Boolean(value) && !Number.isNaN(Number(value));
const isArbitraryNumber = (value) => getIsArbitraryValue(value, "number", isNumber);
const isInteger = (value) => Boolean(value) && Number.isInteger(Number(value));
const isPercent = (value) => value.endsWith("%") && isNumber(value.slice(0, -1));
const isArbitraryValue = (value) => arbitraryValueRegex.test(value);
const isTshirtSize = (value) => tshirtUnitRegex.test(value);
const sizeLabels = /* @__PURE__ */ new Set(["length", "size", "percentage"]);
const isArbitrarySize = (value) => getIsArbitraryValue(value, sizeLabels, isNever);
const isArbitraryPosition = (value) => getIsArbitraryValue(value, "position", isNever);
const imageLabels = /* @__PURE__ */ new Set(["image", "url"]);
const isArbitraryImage = (value) => getIsArbitraryValue(value, imageLabels, isImage);
const isArbitraryShadow = (value) => getIsArbitraryValue(value, "", isShadow);
const isAny = () => true;
const getIsArbitraryValue = (value, label, testValue) => {
const result = arbitraryValueRegex.exec(value);
if (result) {
if (result[1]) {
return typeof label === "string" ? result[1] === label : label.has(result[1]);
}
return testValue(result[2]);
}
return false;
};
const isLengthOnly = (value) => (
// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
lengthUnitRegex.test(value) && !colorFunctionRegex.test(value)
);
const isNever = () => false;
const isShadow = (value) => shadowRegex.test(value);
const isImage = (value) => imageRegex.test(value);
const getDefaultConfig = () => {
const colors = fromTheme("colors");
const spacing = fromTheme("spacing");
const blur = fromTheme("blur");
const brightness = fromTheme("brightness");
const borderColor = fromTheme("borderColor");
const borderRadius = fromTheme("borderRadius");
const borderSpacing = fromTheme("borderSpacing");
const borderWidth = fromTheme("borderWidth");
const contrast = fromTheme("contrast");
const grayscale = fromTheme("grayscale");
const hueRotate = fromTheme("hueRotate");
const invert = fromTheme("invert");
const gap = fromTheme("gap");
const gradientColorStops = fromTheme("gradientColorStops");
const gradientColorStopPositions = fromTheme("gradientColorStopPositions");
const inset = fromTheme("inset");
const margin = fromTheme("margin");
const opacity = fromTheme("opacity");
const padding = fromTheme("padding");
const saturate = fromTheme("saturate");
const scale = fromTheme("scale");
const sepia = fromTheme("sepia");
const skew = fromTheme("skew");
const space = fromTheme("space");
const translate = fromTheme("translate");
const getOverscroll = () => ["auto", "contain", "none"];
const getOverflow = () => ["auto", "hidden", "clip", "visible", "scroll"];
const getSpacingWithAutoAndArbitrary = () => ["auto", isArbitraryValue, spacing];
const getSpacingWithArbitrary = () => [isArbitraryValue, spacing];
const getLengthWithEmptyAndArbitrary = () => ["", isLength, isArbitraryLength];
const getNumberWithAutoAndArbitrary = () => ["auto", isNumber, isArbitraryValue];
const getPositions = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"];
const getLineStyles = () => ["solid", "dashed", "dotted", "double", "none"];
const getBlendModes = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"];
const getAlign = () => ["start", "end", "center", "between", "around", "evenly", "stretch"];
const getZeroAndEmpty = () => ["", "0", isArbitraryValue];
const getBreaks = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"];
const getNumberAndArbitrary = () => [isNumber, isArbitraryValue];
return {
cacheSize: 500,
separator: ":",
theme: {
colors: [isAny],
spacing: [isLength, isArbitraryLength],
blur: ["none", "", isTshirtSize, isArbitraryValue],
brightness: getNumberAndArbitrary(),
borderColor: [colors],
borderRadius: ["none", "", "full", isTshirtSize, isArbitraryValue],
borderSpacing: getSpacingWithArbitrary(),
borderWidth: getLengthWithEmptyAndArbitrary(),
contrast: getNumberAndArbitrary(),
grayscale: getZeroAndEmpty(),
hueRotate: getNumberAndArbitrary(),
invert: getZeroAndEmpty(),
gap: getSpacingWithArbitrary(),
gradientColorStops: [colors],
gradientColorStopPositions: [isPercent, isArbitraryLength],
inset: getSpacingWithAutoAndArbitrary(),
margin: getSpacingWithAutoAndArbitrary(),
opacity: getNumberAndArbitrary(),
padding: getSpacingWithArbitrary(),
saturate: getNumberAndArbitrary(),
scale: getNumberAndArbitrary(),
sepia: getZeroAndEmpty(),
skew: getNumberAndArbitrary(),
space: getSpacingWithArbitrary(),
translate: getSpacingWithArbitrary()
},
classGroups: {
// Layout
/**
* Aspect Ratio
* @see https://tailwindcss.com/docs/aspect-ratio
*/
aspect: [{
aspect: ["auto", "square", "video", isArbitraryValue]
}],
/**
* Container
* @see https://tailwindcss.com/docs/container
*/
container: ["container"],
/**
* Columns
* @see https://tailwindcss.com/docs/columns
*/
columns: [{
columns: [isTshirtSize]
}],
/**
* Break After
* @see https://tailwindcss.com/docs/break-after
*/
"break-after": [{
"break-after": getBreaks()
}],
/**
* Break Before
* @see https://tailwindcss.com/docs/break-before
*/
"break-before": [{
"break-before": getBreaks()
}],
/**
* Break Inside
* @see https://tailwindcss.com/docs/break-inside
*/
"break-inside": [{
"break-inside": ["auto", "avoid", "avoid-page", "avoid-column"]
}],
/**
* Box Decoration Break
* @see https://tailwindcss.com/docs/box-decoration-break
*/
"box-decoration": [{
"box-decoration": ["slice", "clone"]
}],
/**
* Box Sizing
* @see https://tailwindcss.com/docs/box-sizing
*/
box: [{
box: ["border", "content"]
}],
/**
* Display
* @see https://tailwindcss.com/docs/display
*/
display: ["block", "inline-block", "inline", "flex", "inline-flex", "table", "inline-table", "table-caption", "table-cell", "table-column", "table-column-group", "table-footer-group", "table-header-group", "table-row-group", "table-row", "flow-root", "grid", "inline-grid", "contents", "list-item", "hidden"],
/**
* Floats
* @see https://tailwindcss.com/docs/float
*/
float: [{
float: ["right", "left", "none", "start", "end"]
}],
/**
* Clear
* @see https://tailwindcss.com/docs/clear
*/
clear: [{
clear: ["left", "right", "both", "none", "start", "end"]
}],
/**
* Isolation
* @see https://tailwindcss.com/docs/isolation
*/
isolation: ["isolate", "isolation-auto"],
/**
* Object Fit
* @see https://tailwindcss.com/docs/object-fit
*/
"object-fit": [{
object: ["contain", "cover", "fill", "none", "scale-down"]
}],
/**
* Object Position
* @see https://tailwindcss.com/docs/object-position
*/
"object-position": [{
object: [...getPositions(), isArbitraryValue]
}],
/**
* Overflow
* @see https://tailwindcss.com/docs/overflow
*/
overflow: [{
overflow: getOverflow()
}],
/**
* Overflow X
* @see https://tailwindcss.com/docs/overflow
*/
"overflow-x": [{
"overflow-x": getOverflow()
}],
/**
* Overflow Y
* @see https://tailwindcss.com/docs/overflow
*/
"overflow-y": [{
"overflow-y": getOverflow()
}],
/**
* Overscroll Behavior
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
overscroll: [{
overscroll: getOverscroll()
}],
/**
* Overscroll Behavior X
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
"overscroll-x": [{
"overscroll-x": getOverscroll()
}],
/**
* Overscroll Behavior Y
* @see https://tailwindcss.com/docs/overscroll-behavior
*/
"overscroll-y": [{
"overscroll-y": getOverscroll()
}],
/**
* Position
* @see https://tailwindcss.com/docs/position
*/
position: ["static", "fixed", "absolute", "relative", "sticky"],
/**
* Top / Right / Bottom / Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
inset: [{
inset: [inset]
}],
/**
* Right / Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
"inset-x": [{
"inset-x": [inset]
}],
/**
* Top / Bottom
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
"inset-y": [{
"inset-y": [inset]
}],
/**
* Start
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
start: [{
start: [inset]
}],
/**
* End
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
end: [{
end: [inset]
}],
/**
* Top
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
top: [{
top: [inset]
}],
/**
* Right
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
right: [{
right: [inset]
}],
/**
* Bottom
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
bottom: [{
bottom: [inset]
}],
/**
* Left
* @see https://tailwindcss.com/docs/top-right-bottom-left
*/
left: [{
left: [inset]
}],
/**
* Visibility
* @see https://tailwindcss.com/docs/visibility
*/
visibility: ["visible", "invisible", "collapse"],
/**
* Z-Index
* @see https://tailwindcss.com/docs/z-index
*/
z: [{
z: ["auto", isInteger, isArbitraryValue]
}],
// Flexbox and Grid
/**
* Flex Basis
* @see https://tailwindcss.com/docs/flex-basis
*/
basis: [{
basis: getSpacingWithAutoAndArbitrary()
}],
/**
* Flex Direction
* @see https://tailwindcss.com/docs/flex-direction
*/
"flex-direction": [{
flex: ["row", "row-reverse", "col", "col-reverse"]
}],
/**
* Flex Wrap
* @see https://tailwindcss.com/docs/flex-wrap
*/
"flex-wrap": [{
flex: ["wrap", "wrap-reverse", "nowrap"]
}],
/**
* Flex
* @see https://tailwindcss.com/docs/flex
*/
flex: [{
flex: ["1", "auto", "initial", "none", isArbitraryValue]
}],
/**
* Flex Grow
* @see https://tailwindcss.com/docs/flex-grow
*/
grow: [{
grow: getZeroAndEmpty()
}],
/**
* Flex Shrink
* @see https://tailwindcss.com/docs/flex-shrink
*/
shrink: [{
shrink: getZeroAndEmpty()
}],
/**
* Order
* @see https://tailwindcss.com/docs/order
*/
order: [{
order: ["first", "last", "none", isInteger, isArbitraryValue]
}],
/**
* Grid Template Columns
* @see https://tailwindcss.com/docs/grid-template-columns
*/
"grid-cols": [{
"grid-cols": [isAny]
}],
/**
* Grid Column Start / End
* @see https://tailwindcss.com/docs/grid-column
*/
"col-start-end": [{
col: ["auto", {
span: ["full", isInteger, isArbitraryValue]
}, isArbitraryValue]
}],
/**
* Grid Column Start
* @see https://tailwindcss.com/docs/grid-column
*/
"col-start": [{
"col-start": getNumberWithAutoAndArbitrary()
}],
/**
* Grid Column End
* @see https://tailwindcss.com/docs/grid-column
*/
"col-end": [{
"col-end": getNumberWithAutoAndArbitrary()
}],
/**
* Grid Template Rows
* @see https://tailwindcss.com/docs/grid-template-rows
*/
"grid-rows": [{
"grid-rows": [isAny]
}],
/**
* Grid Row Start / End
* @see https://tailwindcss.com/docs/grid-row
*/
"row-start-end": [{
row: ["auto", {
span: [isInteger, isArbitraryValue]
}, isArbitraryValue]
}],
/**
* Grid Row Start
* @see https://tailwindcss.com/docs/grid-row
*/
"row-start": [{
"row-start": getNumberWithAutoAndArbitrary()
}],
/**
* Grid Row End
* @see https://tailwindcss.com/docs/grid-row
*/
"row-end": [{
"row-end": getNumberWithAutoAndArbitrary()
}],
/**
* Grid Auto Flow
* @see https://tailwindcss.com/docs/grid-auto-flow
*/
"grid-flow": [{
"grid-flow": ["row", "col", "dense", "row-dense", "col-dense"]
}],
/**
* Grid Auto Columns
* @see https://tailwindcss.com/docs/grid-auto-columns
*/
"auto-cols": [{
"auto-cols": ["auto", "min", "max", "fr", isArbitraryValue]
}],
/**
* Grid Auto Rows
* @see https://tailwindcss.com/docs/grid-auto-rows
*/
"auto-rows": [{
"auto-rows": ["auto", "min", "max", "fr", isArbitraryValue]
}],
/**
* Gap
* @see https://tailwindcss.com/docs/gap
*/
gap: [{
gap: [gap]
}],
/**
* Gap X
* @see https://tailwindcss.com/docs/gap
*/
"gap-x": [{
"gap-x": [gap]
}],
/**
* Gap Y
* @see https://tailwindcss.com/docs/gap
*/
"gap-y": [{
"gap-y": [gap]
}],
/**
* Justify Content
* @see https://tailwindcss.com/docs/justify-content
*/
"justify-content": [{
justify: ["normal", ...getAlign()]
}],
/**
* Justify Items
* @see https://tailwindcss.com/docs/justify-items
*/
"justify-items": [{
"justify-items": ["start", "end", "center", "stretch"]
}],
/**
* Justify Self
* @see https://tailwindcss.com/docs/justify-self
*/
"justify-self": [{
"justify-self": ["auto", "start", "end", "center", "stretch"]
}],
/**
* Align Content
* @see https://tailwindcss.com/docs/align-content
*/
"align-content": [{
content: ["normal", ...getAlign(), "baseline"]
}],
/**
* Align Items
* @see https://tailwindcss.com/docs/align-items
*/
"align-items": [{
items: ["start", "end", "center", "baseline", "stretch"]
}],
/**
* Align Self
* @see https://tailwindcss.com/docs/align-self
*/
"align-self": [{
self: ["auto", "start", "end", "center", "stretch", "baseline"]
}],
/**
* Place Content
* @see https://tailwindcss.com/docs/place-content
*/
"place-content": [{
"place-content": [...getAlign(), "baseline"]
}],
/**
* Place Items
* @see https://tailwindcss.com/docs/place-items
*/
"place-items": [{
"place-items": ["start", "end", "center", "baseline", "stretch"]
}],
/**
* Place Self
* @see https://tailwindcss.com/docs/place-self
*/
"place-self": [{
"place-self": ["auto", "start", "end", "center", "stretch"]
}],
// Spacing
/**
* Padding
* @see https://tailwindcss.com/docs/padding
*/
p: [{
p: [padding]
}],
/**
* Padding X
* @see https://tailwindcss.com/docs/padding
*/
px: [{
px: [padding]
}],
/**
* Padding Y
* @see https://tailwindcss.com/docs/padding
*/
py: [{
py: [padding]
}],
/**
* Padding Start
* @see https://tailwindcss.com/docs/padding
*/
ps: [{
ps: [padding]
}],
/**
* Padding End
* @see https://tailwindcss.com/docs/padding
*/
pe: [{
pe: [padding]
}],
/**
* Padding Top
* @see https://tailwindcss.com/docs/padding
*/
pt: [{
pt: [padding]
}],
/**
* Padding Right
* @see https://tailwindcss.com/docs/padding
*/
pr: [{
pr: [padding]
}],
/**
* Padding Bottom
* @see https://tailwindcss.com/docs/padding
*/
pb: [{
pb: [padding]
}],
/**
* Padding Left
* @see https://tailwindcss.com/docs/padding
*/
pl: [{
pl: [padding]
}],
/**
* Margin
* @see https://tailwindcss.com/docs/margin
*/
m: [{
m: [margin]
}],
/**
* Margin X
* @see https://tailwindcss.com/docs/margin
*/
mx: [{
mx: [margin]
}],
/**
* Margin Y
* @see https://tailwindcss.com/docs/margin
*/
my: [{
my: [margin]
}],
/**
* Margin Start
* @see https://tailwindcss.com/docs/margin
*/
ms: [{
ms: [margin]
}],
/**
* Margin End
* @see https://tailwindcss.com/docs/margin
*/
me: [{
me: [margin]
}],
/**
* Margin Top
* @see https://tailwindcss.com/docs/margin
*/
mt: [{
mt: [margin]
}],
/**
* Margin Right
* @see https://tailwindcss.com/docs/margin
*/
mr: [{
mr: [margin]
}],
/**
* Margin Bottom
* @see https://tailwindcss.com/docs/margin
*/
mb: [{
mb: [margin]
}],
/**
* Margin Left
* @see https://tailwindcss.com/docs/margin
*/
ml: [{
ml: [margin]
}],
/**
* Space Between X
* @see https://tailwindcss.com/docs/space
*/
"space-x": [{
"space-x": [space]
}],
/**
* Space Between X Reverse
* @see https://tailwindcss.com/docs/space
*/
"space-x-reverse": ["space-x-reverse"],
/**
* Space Between Y
* @see https://tailwindcss.com/docs/space
*/
"space-y": [{
"space-y": [space]
}],
/**
* Space Between Y Reverse
* @see https://tailwindcss.com/docs/space
*/
"space-y-reverse": ["space-y-reverse"],
// Sizing
/**
* Width
* @see https://tailwindcss.com/docs/width
*/
w: [{
w: ["auto", "min", "max", "fit", "svw", "lvw", "dvw", isArbitraryValue, spacing]
}],
/**
* Min-Width
* @see https://tailwindcss.com/docs/min-width
*/
"min-w": [{
"min-w": [isArbitraryValue, spacing, "min", "max", "fit"]
}],
/**
* Max-Width
* @see https://tailwindcss.com/docs/max-width
*/
"max-w": [{
"max-w": [isArbitraryValue, spacing, "none", "full", "min", "max", "fit", "prose", {
screen: [isTshirtSize]
}, isTshirtSize]
}],
/**
* Height
* @see https://tailwindcss.com/docs/height
*/
h: [{
h: [isArbitraryValue, spacing, "auto", "min", "max", "fit", "svh", "lvh", "dvh"]
}],
/**
* Min-Height
* @see https://tailwindcss.com/docs/min-height
*/
"min-h": [{
"min-h": [isArbitraryValue, spacing, "min", "max", "fit", "svh", "lvh", "dvh"]
}],
/**
* Max-Height
* @see https://tailwindcss.com/docs/max-height
*/
"max-h": [{
"max-h": [isArbitraryValue, spacing, "min", "max", "fit", "svh", "lvh", "dvh"]
}],
/**
* Size
* @see https://tailwindcss.com/docs/size
*/
size: [{
size: [isArbitraryValue, spacing, "auto", "min", "max", "fit"]
}],
// Typography
/**
* Font Size
* @see https://tailwindcss.com/docs/font-size
*/
"font-size": [{
text: ["base", isTshirtSize, isArbitraryLength]
}],
/**
* Font Smoothing
* @see https://tailwindcss.com/docs/font-smoothing
*/
"font-smoothing": ["antialiased", "subpixel-antialiased"],
/**
* Font Style
* @see https://tailwindcss.com/docs/font-style
*/
"font-style": ["italic", "not-italic"],
/**
* Font Weight
* @see https://tailwindcss.com/docs/font-weight
*/
"font-weight": [{
font: ["thin", "extralight", "light", "normal", "medium", "semibold", "bold", "extrabold", "black", isArbitraryNumber]
}],
/**
* Font Family
* @see https://tailwindcss.com/docs/font-family
*/
"font-family": [{
font: [isAny]
}],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-normal": ["normal-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-ordinal": ["ordinal"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-slashed-zero": ["slashed-zero"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-figure": ["lining-nums", "oldstyle-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-spacing": ["proportional-nums", "tabular-nums"],
/**
* Font Variant Numeric
* @see https://tailwindcss.com/docs/font-variant-numeric
*/
"fvn-fraction": ["diagonal-fractions", "stacked-fractions"],
/**
* Letter Spacing
* @see https://tailwindcss.com/docs/letter-spacing
*/
tracking: [{
tracking: ["tighter", "tight", "normal", "wide", "wider", "widest", isArbitraryValue]
}],
/**
* Line Clamp
* @see https://tailwindcss.com/docs/line-clamp
*/
"line-clamp": [{
"line-clamp": ["none", isNumber, isArbitraryNumber]
}],
/**
* Line Height
* @see https://tailwindcss.com/docs/line-height
*/
leading: [{
leading: ["none", "tight", "snug", "normal", "relaxed", "loose", isLength, isArbitraryValue]
}],
/**
* List Style Image
* @see https://tailwindcss.com/docs/list-style-image
*/
"list-image": [{
"list-image": ["none", isArbitraryValue]
}],
/**
* List Style Type
* @see https://tailwindcss.com/docs/list-style-type
*/
"list-style-type": [{
list: ["none", "disc", "decimal", isArbitraryValue]
}],
/**
* List Style Position
* @see https://tailwindcss.com/docs/list-style-position
*/
"list-style-position": [{
list: ["inside", "outside"]
}],
/**
* Placeholder Color
* @deprecated since Tailwind CSS v3.0.0
* @see https://tailwindcss.com/docs/placeholder-color
*/
"placeholder-color": [{
placeholder: [colors]
}],
/**
* Placeholder Opacity
* @see https://tailwindcss.com/docs/placeholder-opacity
*/
"placeholder-opacity": [{
"placeholder-opacity": [opacity]
}],
/**
* Text Alignment
* @see https://tailwindcss.com/docs/text-align
*/
"text-alignment": [{
text: ["left", "center", "right", "justify", "start", "end"]
}],
/**
* Text Color
* @see https://tailwindcss.com/docs/text-color
*/
"text-color": [{
text: [colors]
}],
/**
* Text Opacity
* @see https://tailwindcss.com/docs/text-opacity
*/
"text-opacity": [{
"text-opacity": [opacity]
}],
/**
* Text Decoration
* @see https://tailwindcss.com/docs/text-decoration
*/
"text-decoration": ["underline", "overline", "line-through", "no-underline"],
/**
* Text Decoration Style
* @see https://tailwindcss.com/docs/text-decoration-style
*/
"text-decoration-style": [{
decoration: [...getLineStyles(), "wavy"]
}],
/**
* Text Decoration Thickness
* @see https://tailwindcss.com/docs/text-decoration-thickness
*/
"text-decoration-thickness": [{
decoration: ["auto", "from-font", isLength, isArbitraryLength]
}],
/**
* Text Underline Offset
* @see https://tailwindcss.com/docs/text-underline-offset
*/
"underline-offset": [{
"underline-offset": ["auto", isLength, isArbitraryValue]
}],
/**
* Text Decoration Color
* @see https://tailwindcss.com/docs/text-decoration-color
*/
"text-decoration-color": [{
decoration: [colors]
}],
/**
* Text Transform
* @see https://tailwindcss.com/docs/text-transform
*/
"text-transform": ["uppercase", "lowercase", "capitalize", "normal-case"],
/**
* Text Overflow
* @see https://tailwindcss.com/docs/text-overflow
*/
"text-overflow": ["truncate", "text-ellipsis", "text-clip"],
/**
* Text Wrap
* @see https://tailwindcss.com/docs/text-wrap
*/
"text-wrap": [{
text: ["wrap", "nowrap", "balance", "pretty"]
}],
/**
* Text Indent
* @see https://tailwindcss.com/docs/text-indent
*/
indent: [{
indent: getSpacingWithArbitrary()
}],
/**
* Vertical Alignment
* @see https://tailwindcss.com/docs/vertical-align
*/
"vertical-align": [{
align: ["baseline", "top", "middle", "bottom", "text-top", "text-bottom", "sub", "super", isArbitraryValue]
}],
/**
* Whitespace
* @see https://tailwindcss.com/docs/whitespace
*/
whitespace: [{
whitespace: ["normal", "nowrap", "pre", "pre-line", "pre-wrap", "break-spaces"]
}],
/**
* Word Break
* @see https://tailwindcss.com/docs/word-break
*/
break: [{
break: ["normal", "words", "all", "keep"]
}],
/**
* Hyphens
* @see https://tailwindcss.com/docs/hyphens
*/
hyphens: [{
hyphens: ["none", "manual", "auto"]
}],
/**
* Content
* @see https://tailwindcss.com/docs/content
*/
content: [{
content: ["none", isArbitraryValue]
}],
// Backgrounds
/**
* Background Attachment
* @see https://tailwindcss.com/docs/background-attachment
*/
"bg-attachment": [{
bg: ["fixed", "local", "scroll"]
}],
/**
* Background Clip
* @see https://tailwindcss.com/docs/background-clip
*/
"bg-clip": [{
"bg-clip": ["border", "padding", "content", "text"]
}],
/**
* Background Opacity
* @deprecated since Tailwind CSS v3.0.0
* @see https://tailwindcss.com/docs/background-opacity
*/
"bg-opacity": [{
"bg-opacity": [opacity]
}],
/**
* Background Origin
* @see https://tailwindcss.com/docs/background-origin
*/
"bg-origin": [{
"bg-origin": ["border", "padding", "content"]
}],
/**
* Background Position
* @see https://tailwindcss.com/docs/background-position
*/
"bg-position": [{
bg: [...getPositions(), isArbitraryPosition]
}],
/**
* Background Repeat
* @see https://tailwindcss.com/docs/background-repeat
*/
"bg-repeat": [{
bg: ["no-repeat", {
repeat: ["", "x", "y", "round", "space"]
}]
}],
/**
* Background Size
* @see https://tailwindcss.com/docs/background-size
*/
"bg-size": [{
bg: ["auto", "cover", "contain", isArbitrarySize]
}],
/**
* Background Image
* @see https://tailwindcss.com/docs/background-image
*/
"bg-image": [{
bg: ["none", {
"gradient-to": ["t", "tr", "r", "br", "b", "bl", "l", "tl"]
}, isArbitraryImage]
}],
/**
* Background Color
* @see https://tailwindcss.com/docs/background-color
*/
"bg-color": [{
bg: [colors]
}],
/**
* Gradient Color Stops From Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-from-pos": [{
from: [gradientColorStopPositions]
}],
/**
* Gradient Color Stops Via Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-via-pos": [{
via: [gradientColorStopPositions]
}],
/**
* Gradient Color Stops To Position
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-to-pos": [{
to: [gradientColorStopPositions]
}],
/**
* Gradient Color Stops From
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-from": [{
from: [gradientColorStops]
}],
/**
* Gradient Color Stops Via
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-via": [{
via: [gradientColorStops]
}],
/**
* Gradient Color Stops To
* @see https://tailwindcss.com/docs/gradient-color-stops
*/
"gradient-to": [{
to: [gradientColorStops]
}],
// Borders
/**
* Border Radius
* @see https://tailwindcss.com/docs/border-radius
*/
rounded: [{
rounded: [borderRadius]
}],
/**
* Border Radius Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-s": [{
"rounded-s": [borderRadius]
}],
/**
* Border Radius End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-e": [{
"rounded-e": [borderRadius]
}],
/**
* Border Radius Top
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-t": [{
"rounded-t": [borderRadius]
}],
/**
* Border Radius Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-r": [{
"rounded-r": [borderRadius]
}],
/**
* Border Radius Bottom
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-b": [{
"rounded-b": [borderRadius]
}],
/**
* Border Radius Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-l": [{
"rounded-l": [borderRadius]
}],
/**
* Border Radius Start Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-ss": [{
"rounded-ss": [borderRadius]
}],
/**
* Border Radius Start End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-se": [{
"rounded-se": [borderRadius]
}],
/**
* Border Radius End End
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-ee": [{
"rounded-ee": [borderRadius]
}],
/**
* Border Radius End Start
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-es": [{
"rounded-es": [borderRadius]
}],
/**
* Border Radius Top Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-tl": [{
"rounded-tl": [borderRadius]
}],
/**
* Border Radius Top Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-tr": [{
"rounded-tr": [borderRadius]
}],
/**
* Border Radius Bottom Right
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-br": [{
"rounded-br": [borderRadius]
}],
/**
* Border Radius Bottom Left
* @see https://tailwindcss.com/docs/border-radius
*/
"rounded-bl": [{
"rounded-bl": [borderRadius]
}],
/**
* Border Width
* @see https://tailwindcss.com/docs/border-width
*/
"border-w": [{
border: [borderWidth]
}],
/**
* Border Width X
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-x": [{
"border-x": [borderWidth]
}],
/**
* Border Width Y
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-y": [{
"border-y": [borderWidth]
}],
/**
* Border Width Start
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-s": [{
"border-s": [borderWidth]
}],
/**
* Border Width End
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-e": [{
"border-e": [borderWidth]
}],
/**
* Border Width Top
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-t": [{
"border-t": [borderWidth]
}],
/**
* Border Width Right
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-r": [{
"border-r": [borderWidth]
}],
/**
* Border Width Bottom
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-b": [{
"border-b": [borderWidth]
}],
/**
* Border Width Left
* @see https://tailwindcss.com/docs/border-width
*/
"border-w-l": [{
"border-l": [borderWidth]
}],
/**
* Border Opacity
* @see https://tailwindcss.com/docs/border-opacity
*/
"border-opacity": [{
"border-opacity": [opacity]
}],
/**
* Border Style
* @see https://tailwindcss.com/docs/border-style
*/
"border-style": [{
border: [...getLineStyles(), "hidden"]
}],
/**
* Divide Width X
* @see https://tailwindcss.com/docs/divide-width
*/
"divide-x": [{
"divide-x": [borderWidth]
}],
/**
* Divide Width X Reverse
* @see https://tailwindcss.com/docs/divide-width
*/
"divide-x-reverse": ["divide-x-reverse"],
/**
* Divide Width Y
* @see https://tailwindcss.com/docs/divide-width
*/
"divide-y": [{
"divide-y": [borderWidth]
}],
/**
* Divide Width Y Reverse
* @see https://tailwindcss.com/docs/divide-width
*/
"divide-y-reverse": ["divide-y-reverse"],
/**
* Divide Opacity
* @see https://tailwindcss.com/docs/divide-opacity
*/
"divide-opacity": [{
"divide-opacity": [opacity]
}],
/**
* Divide Style
* @see https://tailwindcss.com/docs/divide-style
*/
"divide-style": [{
divide: getLineStyles()
}],
/**
* Border Color
* @see https://tailwindcss.com/docs/border-color
*/
"border-color": [{
border: [borderColor]
}],
/**
* Border Color X
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-x": [{
"border-x": [borderColor]
}],
/**
* Border Color Y
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-y": [{
"border-y": [borderColor]
}],
/**
* Border Color S
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-s": [{
"border-s": [borderColor]
}],
/**
* Border Color E
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-e": [{
"border-e": [borderColor]
}],
/**
* Border Color Top
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-t": [{
"border-t": [borderColor]
}],
/**
* Border Color Right
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-r": [{
"border-r": [borderColor]
}],
/**
* Border Color Bottom
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-b": [{
"border-b": [borderColor]
}],
/**
* Border Color Left
* @see https://tailwindcss.com/docs/border-color
*/
"border-color-l": [{
"border-l": [borderColor]
}],
/**
* Divide Color
* @see https://tailwindcss.com/docs/divide-color
*/
"divide-color": [{
divide: [borderColor]
}],
/**
* Outline Style
* @see https://tailwindcss.com/docs/outline-style
*/
"outline-style": [{
outline: ["", ...getLineStyles()]
}],
/**
* Outline Offset
* @see https://tailwindcss.com/docs/outline-offset
*/
"outline-offset": [{
"outline-offset": [isLength, isArbitraryValue]
}],
/**
* Outline Width
* @see https://tailwindcss.com/docs/outline-width
*/
"outline-w": [{
outline: [isLength, isArbitraryLength]
}],
/**
* Outline Color
* @see https://tailwindcss.com/docs/outline-color
*/
"outline-color": [{
outline: [colors]
}],
/**
* Ring Width
* @see https://tailwindcss.com/docs/ring-width
*/
"ring-w": [{
ring: getLengthWithEmptyAndArbitrary()
}],
/**
* Ring Width Inset
* @see https://tailwindcss.com/docs/ring-width
*/
"ring-w-inset": ["ring-inset"],
/**
* Ring Color
* @see https://tailwindcss.com/docs/ring-color
*/
"ring-color": [{
ring: [colors]
}],
/**
* Ring Opacity
* @see https://tailwindcss.com/docs/ring-opacity
*/
"ring-opacity": [{
"ring-opacity": [opacity]
}],
/**
* Ring Offset Width
* @see https://tailwindcss.com/docs/ring-offset-width
*/
"ring-offset-w": [{
"ring-offset": [isLength, isArbitraryLength]
}],
/**
* Ring Offset Color
* @see https://tailwindcss.com/docs/ring-offset-color
*/
"ring-offset-color": [{
"ring-offset": [colors]
}],
// Effects
/**
* Box Shadow
* @see https://tailwindcss.com/docs/box-shadow
*/
shadow: [{
shadow: ["", "inner", "none", isTshirtSize, isArbitraryShadow]
}],
/**
* Box Shadow Color
* @see https://tailwindcss.com/docs/box-shadow-color
*/
"shadow-color": [{
shadow: [isAny]
}],
/**
* Opacity
* @see https://tailwindcss.com/docs/opacity
*/
opacity: [{
opacity: [opacity]
}],
/**
* Mix Blend Mode
* @see https://tailwindcss.com/docs/mix-blend-mode
*/
"mix-blend": [{
"mix-blend": [...getBlendModes(), "plus-lighter", "plus-darker"]
}],
/**
* Background Blend Mode
* @see https://tailwindcss.com/docs/background-blend-mode
*/
"bg-blend": [{
"bg-blend": getBlendModes()
}],
// Filters
/**
* Filter
* @deprecated since Tailwind CSS v3.0.0
* @see https://tailwindcss.com/docs/filter
*/
filter: [{
filter: ["", "none"]
}],
/**
* Blur
* @see https://tailwindcss.com/docs/blur
*/
blur: [{
blur: [blur]
}],
/**
* Brightness
* @see https://tailwindcss.com/docs/brightness
*/
brightness: [{
brightness: [brightness]
}],
/**
* Contrast
* @see https://tailwindcss.com/docs/contrast
*/
contrast: [{
contrast: [contrast]
}],
/**
* Drop Shadow
* @see https://tailwindcss.com/docs/drop-shadow
*/
"drop-shadow": [{
"drop-shadow": ["", "none", isTshirtSize, isArbitraryValue]
}],
/**
* Grayscale
* @see https://tailwindcss.com/docs/grayscale
*/
grayscale: [{
grayscale: [grayscale]
}],
/**
* Hue Rotate
* @see https://tailwindcss.com/docs/hue-rotate
*/
"hue-rotate": [{
"hue-rotate": [hueRotate]
}],
/**
* Invert
* @see https://tailwindcss.com/docs/invert
*/
invert: [{
invert: [invert]
}],
/**
* Saturate
* @see https://tailwindcss.com/docs/saturate
*/
saturate: [{
saturate: [saturate]
}],
/**
* Sepia
* @see https://tailwindcss.com/docs/sepia
*/
sepia: [{
sepia: [sepia]
}],
/**
* Backdrop Filter
* @deprecated since Tailwind CSS v3.0.0
* @see https://tailwindcss.com/docs/backdrop-filter
*/
"backdrop-filter": [{
"backdrop-filter": ["", "none"]
}],
/**
* Backdrop Blur
* @see https://tailwindcss.com/docs/backdrop-blur
*/
"backdrop-blur": [{
"backdrop-blur": [blur]
}],
/**
* Backdrop Brightness
* @see https://tailwindcss.com/docs/backdrop-brightness
*/
"backdrop-brightness": [{
"backdrop-brightness": [brightness]
}],
/**
* Backdrop Contrast
* @see https://tailwindcss.com/docs/backdrop-contrast
*/
"backdrop-contrast": [{
"backdrop-contrast": [contrast]
}],
/**
* Backdrop Grayscale
* @see https://tailwindcss.com/docs/backdrop-grayscale
*/
"backdrop-grayscale": [{
"backdrop-grayscale": [grayscale]
}],
/**
* Backdrop Hue Rotate
* @see https://tailwindcss.com/docs/backdrop-hue-rotate
*/
"backdrop-hue-rotate": [{
"backdrop-hue-rotate": [hueRotate]
}],
/**
* Backdrop Invert
* @see https://tailwindcss.com/docs/backdrop-invert
*/
"backdrop-invert": [{
"backdrop-invert": [invert]
}],
/**
* Backdrop Opacity
* @see https://tailwindcss.com/docs/backdrop-opacity
*/
"backdrop-opacity": [{
"backdrop-opacity": [opacity]
}],
/**
* Backdrop Saturate
* @see https://tailwindcss.com/docs/backdrop-saturate
*/
"backdrop-saturate": [{
"backdrop-saturate": [saturate]
}],
/**
* Backdrop Sepia
* @see https://tailwindcss.com/docs/backdrop-sepia
*/
"backdrop-sepia": [{
"backdrop-sepia": [sepia]
}],
// Tables
/**
* Border Collapse
* @see https://tailwindcss.com/docs/border-collapse
*/
"border-collapse": [{
border: ["collapse", "separate"]
}],
/**
* Border Spacing
* @see https://tailwindcss.com/docs/border-spacing
*/
"border-spacing": [{
"border-spacing": [borderSpacing]
}],
/**
* Border Spacing X
* @see https://tailwindcss.com/docs/border-spacing
*/
"border-spacing-x": [{
"border-spacing-x": [borderSpacing]
}],
/**
* Border Spacing Y
* @see https://tailwindcss.com/docs/border-spacing
*/
"border-spacing-y": [{
"border-spacing-y": [borderSpacing]
}],
/**
* Table Layout
* @see https://tailwindcss.com/docs/table-layout
*/
"table-layout": [{
table: ["auto", "fixed"]
}],
/**
* Caption Side
* @see https://tailwindcss.com/docs/caption-side
*/
caption: [{
caption: ["top", "bottom"]
}],
// Transitions and Animation
/**
* Tranisition Property
* @see https://tailwindcss.com/docs/transition-property
*/
transition: [{
transition: ["none", "all", "", "colors", "opacity", "shadow", "transform", isArbitraryValue]
}],
/**
* Transition Duration
* @see https://tailwindcss.com/docs/transition-duration
*/
duration: [{
duration: getNumberAndArbitrary()
}],
/**
* Transition Timing Function
* @see https://tailwindcss.com/docs/transition-timing-function
*/
ease: [{
ease: ["linear", "in", "out", "in-out", isArbitraryValue]
}],
/**
* Transition Delay
* @see https://tailwindcss.com/docs/transition-delay
*/
delay: [{
delay: getNumberAndArbitrary()
}],
/**
* Animation
* @see https://tailwindcss.com/docs/animation
*/
animate: [{
animate: ["none", "spin", "ping", "pulse", "bounce", isArbitraryValue]
}],
// Transforms
/**
* Transform
* @see https://tailwindcss.com/docs/transform
*/
transform: [{
transform: ["", "gpu", "none"]
}],
/**
* Scale
* @see https://tailwindcss.com/docs/scale
*/
scale: [{
scale: [scale]
}],
/**
* Scale X
* @see https://tailwindcss.com/docs/scale
*/
"scale-x": [{
"scale-x": [scale]
}],
/**
* Scale Y
* @see https://tailwindcss.com/docs/scale
*/
"scale-y": [{
"scale-y": [scale]
}],
/**
* Rotate
* @see https://tailwindcss.com/docs/rotate
*/
rotate: [{
rotate: [isInteger, isArbitraryValue]
}],
/**
* Translate X
* @see https://tailwindcss.com/docs/translate
*/
"translate-x": [{
"translate-x": [translate]
}],
/**
* Translate Y
* @see https://tailwindcss.com/docs/translate
*/
"translate-y": [{
"translate-y": [translate]
}],
/**
* Skew X
* @see https://tailwindcss.com/docs/skew
*/
"skew-x": [{
"skew-x": [skew]
}],
/**
* Skew Y
* @see https://tailwindcss.com/docs/skew
*/
"skew-y": [{
"skew-y": [skew]
}],
/**
* Transform Origin
* @see https://tailwindcss.com/docs/transform-origin
*/
"transform-origin": [{
origin: ["center", "top", "top-right", "right", "bottom-right", "bottom", "bottom-left", "left", "top-left", isArbitraryValue]
}],
// Interactivity
/**
* Accent Color
* @see https://tailwindcss.com/docs/accent-color
*/
accent: [{
accent: ["auto", colors]
}],
/**
* Appearance
* @see https://tailwindcss.com/docs/appearance
*/
appearance: [{
appearance: ["none", "auto"]
}],
/**
* Cursor
* @see https://tailwindcss.com/docs/cursor
*/
cursor: [{
cursor: ["auto", "default", "pointer", "wait", "text", "move", "help", "not-allowed", "none", "context-menu", "progress", "cell", "crosshair", "vertical-text", "alias", "copy", "no-drop", "grab", "grabbing", "all-scroll", "col-resize", "row-resize", "n-resize", "e-resize", "s-resize", "w-resize", "ne-resize", "nw-resize", "se-resize", "sw-resize", "ew-resize", "ns-resize", "nesw-resize", "nwse-resize", "zoom-in", "zoom-out", isArbitraryValue]
}],
/**
* Caret Color
* @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities
*/
"caret-color": [{
caret: [colors]
}],
/**
* Pointer Events
* @see https://tailwindcss.com/docs/pointer-events
*/
"pointer-events": [{
"pointer-events": ["none", "auto"]
}],
/**
* Resize
* @see https://tailwindcss.com/docs/resize
*/
resize: [{
resize: ["none", "y", "x", ""]
}],
/**
* Scroll Behavior
* @see https://tailwindcss.com/docs/scroll-behavior
*/
"scroll-behavior": [{
scroll: ["auto", "smooth"]
}],
/**
* Scroll Margin
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-m": [{
"scroll-m": getSpacingWithArbitrary()
}],
/**
* Scroll Margin X
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-mx": [{
"scroll-mx": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Y
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-my": [{
"scroll-my": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Start
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-ms": [{
"scroll-ms": getSpacingWithArbitrary()
}],
/**
* Scroll Margin End
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-me": [{
"scroll-me": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Top
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-mt": [{
"scroll-mt": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Right
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-mr": [{
"scroll-mr": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Bottom
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-mb": [{
"scroll-mb": getSpacingWithArbitrary()
}],
/**
* Scroll Margin Left
* @see https://tailwindcss.com/docs/scroll-margin
*/
"scroll-ml": [{
"scroll-ml": getSpacingWithArbitrary()
}],
/**
* Scroll Padding
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-p": [{
"scroll-p": getSpacingWithArbitrary()
}],
/**
* Scroll Padding X
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-px": [{
"scroll-px": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Y
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-py": [{
"scroll-py": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Start
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-ps": [{
"scroll-ps": getSpacingWithArbitrary()
}],
/**
* Scroll Padding End
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-pe": [{
"scroll-pe": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Top
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-pt": [{
"scroll-pt": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Right
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-pr": [{
"scroll-pr": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Bottom
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-pb": [{
"scroll-pb": getSpacingWithArbitrary()
}],
/**
* Scroll Padding Left
* @see https://tailwindcss.com/docs/scroll-padding
*/
"scroll-pl": [{
"scroll-pl": getSpacingWithArbitrary()
}],
/**
* Scroll Snap Align
* @see https://tailwindcss.com/docs/scroll-snap-align
*/
"snap-align": [{
snap: ["start", "end", "center", "align-none"]
}],
/**
* Scroll Snap Stop
* @see https://tailwindcss.com/docs/scroll-snap-stop
*/
"snap-stop": [{
snap: ["normal", "always"]
}],
/**
* Scroll Snap Type
* @see https://tailwindcss.com/docs/scroll-snap-type
*/
"snap-type": [{
snap: ["none", "x", "y", "both"]
}],
/**
* Scroll Snap Type Strictness
* @see https://tailwindcss.com/docs/scroll-snap-type
*/
"snap-strictness": [{
snap: ["mandatory", "proximity"]
}],
/**
* Touch Action
* @see https://tailwindcss.com/docs/touch-action
*/
touch: [{
touch: ["auto", "none", "manipulation"]
}],
/**
* Touch Action X
* @see https://tailwindcss.com/docs/touch-action
*/
"touch-x": [{
"touch-pan": ["x", "left", "right"]
}],
/**
* Touch Action Y
* @see https://tailwindcss.com/docs/touch-action
*/
"touch-y": [{
"touch-pan": ["y", "up", "down"]
}],
/**
* Touch Action Pinch Zoom
* @see https://tailwindcss.com/docs/touch-action
*/
"touch-pz": ["touch-pinch-zoom"],
/**
* User Select
* @see https://tailwindcss.com/docs/user-select
*/
select: [{
select: ["none", "text", "all", "auto"]
}],
/**
* Will Change
* @see https://tailwindcss.com/docs/will-change
*/
"will-change": [{
"will-change": ["auto", "scroll", "contents", "transform", isArbitraryValue]
}],
// SVG
/**
* Fill
* @see https://tailwindcss.com/docs/fill
*/
fill: [{
fill: [colors, "none"]
}],
/**
* Stroke Width
* @see https://tailwindcss.com/docs/stroke-width
*/
"stroke-w": [{
stroke: [isLength, isArbitraryLength, isArbitraryNumber]
}],
/**
* Stroke
* @see https://tailwindcss.com/docs/stroke
*/
stroke: [{
stroke: [colors, "none"]
}],
// Accessibility
/**
* Screen Readers
* @see https://tailwindcss.com/docs/screen-readers
*/
sr: ["sr-only", "not-sr-only"],
/**
* Forced Color Adjust
* @see https://tailwindcss.com/docs/forced-color-adjust
*/
"forced-color-adjust": [{
"forced-color-adjust": ["auto", "none"]
}]
},
conflictingClassGroups: {
overflow: ["overflow-x", "overflow-y"],
overscroll: ["overscroll-x", "overscroll-y"],
inset: ["inset-x", "inset-y", "start", "end", "top", "right", "bottom", "left"],
"inset-x": ["right", "left"],
"inset-y": ["top", "bottom"],
flex: ["basis", "grow", "shrink"],
gap: ["gap-x", "gap-y"],
p: ["px", "py", "ps", "pe", "pt", "pr", "pb", "pl"],
px: ["pr", "pl"],
py: ["pt", "pb"],
m: ["mx", "my", "ms", "me", "mt", "mr", "mb", "ml"],
mx: ["mr", "ml"],
my: ["mt", "mb"],
size: ["w", "h"],
"font-size": ["leading"],
"fvn-normal": ["fvn-ordinal", "fvn-slashed-zero", "fvn-figure", "fvn-spacing", "fvn-fraction"],
"fvn-ordinal": ["fvn-normal"],
"fvn-slashed-zero": ["fvn-normal"],
"fvn-figure": ["fvn-normal"],
"fvn-spacing": ["fvn-normal"],
"fvn-fraction": ["fvn-normal"],
"line-clamp": ["display", "overflow"],
rounded: ["rounded-s", "rounded-e", "rounded-t", "rounded-r", "rounded-b", "rounded-l", "rounded-ss", "rounded-se", "rounded-ee", "rounded-es", "rounded-tl", "rounded-tr", "rounded-br", "rounded-bl"],
"rounded-s": ["rounded-ss", "rounded-es"],
"rounded-e": ["rounded-se", "rounded-ee"],
"rounded-t": ["rounded-tl", "rounded-tr"],
"rounded-r": ["rounded-tr", "rounded-br"],
"rounded-b": ["rounded-br", "rounded-bl"],
"rounded-l": ["rounded-tl", "rounded-bl"],
"border-spacing": ["border-spacing-x", "border-spacing-y"],
"border-w": ["border-w-s", "border-w-e", "border-w-t", "border-w-r", "border-w-b", "border-w-l"],
"border-w-x": ["border-w-r", "border-w-l"],
"border-w-y": ["border-w-t", "border-w-b"],
"border-color": ["border-color-s", "border-color-e", "border-color-t", "border-color-r", "border-color-b", "border-color-l"],
"border-color-x": ["border-color-r", "border-color-l"],
"border-color-y": ["border-color-t", "border-color-b"],
"scroll-m": ["scroll-mx", "scroll-my", "scroll-ms", "scroll-me", "scroll-mt", "scroll-mr", "scroll-mb", "scroll-ml"],
"scroll-mx": ["scroll-mr", "scroll-ml"],
"scroll-my": ["scroll-mt", "scroll-mb"],
"scroll-p": ["scroll-px", "scroll-py", "scroll-ps", "scroll-pe", "scroll-pt", "scroll-pr", "scroll-pb", "scroll-pl"],
"scroll-px": ["scroll-pr", "scroll-pl"],
"scroll-py": ["scroll-pt", "scroll-pb"],
touch: ["touch-x", "touch-y", "touch-pz"],
"touch-x": ["touch"],
"touch-y": ["touch"],
"touch-pz": ["touch"]
},
conflictingClassGroupModifiers: {
"font-size": ["leading"]
}
};
};
const twMerge = /* @__PURE__ */ createTailwindMerge(getDefaultConfig);
function cn(...inputs) {
return twMerge(clsx(inputs));
}
const ToastProvider = Provider$1;
const ToastViewport = reactExports.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(
Viewport,
{
ref,
className: cn(
"fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",
className
),
...props
}
));
ToastViewport.displayName = Viewport.displayName;
const toastVariants = cva(
"group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",
{
variants: {
variant: {
default: "border bg-background text-foreground",
destructive: "destructive group border-destructive bg-destructive text-destructive-foreground"
}
},
defaultVariants: {
variant: "default"
}
}
);
const Toast = reactExports.forwardRef(({ className, variant, ...props }, ref) => {
return /* @__PURE__ */ jsxRuntimeExports.jsx(Root2, { ref, className: cn(toastVariants({ variant }), className), ...props });
});
Toast.displayName = Root2.displayName;
const ToastAction = reactExports.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(
Action,
{
ref,
className: cn(
"inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors group-[.destructive]:border-muted/40 hover:bg-secondary group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 group-[.destructive]:focus:ring-destructive disabled:pointer-events-none disabled:opacity-50",
className
),
...props
}
));
ToastAction.displayName = Action.displayName;
const ToastClose = reactExports.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(
Close,
{
ref,
className: cn(
"absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",
className
),
"toast-close": "",
...props,
children: /* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "h-4 w-4" })
}
));
ToastClose.displayName = Close.displayName;
const ToastTitle = reactExports.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(Title, { ref, className: cn("text-sm font-semibold", className), ...props }));
ToastTitle.displayName = Title.displayName;
const ToastDescription = reactExports.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntimeExports.jsx(Description, { ref, className: cn("text-sm opacity-90", className), ...props }));
ToastDescription.displayName = Description.displayName;
function Toaster() {
const { toasts } = useToast();
return /* @__PURE__ */ jsxRuntimeExports.jsxs(ToastProvider, { children: [
toasts.map(function({ id: id2, title, description, action, ...props }) {
return /* @__PURE__ */ jsxRuntimeExports.jsxs(Toast, { ...props, children: [
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid gap-1", children: [
title && /* @__PURE__ */ jsxRuntimeExports.jsx(ToastTitle, { children: title }),
description && /* @__PURE__ */ jsxRuntimeExports.jsx(ToastDescription, { children: description })
] }),
action,
/* @__PURE__ */ jsxRuntimeExports.jsx(ToastClose, {})
] }, id2);
}),
/* @__PURE__ */ jsxRuntimeExports.jsx(ToastViewport, {})
] });
}
const sides = ["top", "right", "bottom", "left"];
const min = Math.min;
const max = Math.max;
const round = Math.round;
const floor = Math.floor;
const createCoords = (v2) => ({
x: v2,
y: v2
});
const oppositeSideMap = {
left: "right",
right: "left",
bottom: "top",
top: "bottom"
};
const oppositeAlignmentMap = {
start: "end",
end: "start"
};
function clamp(start, value, end) {
return max(start, min(value, end));
}
function evaluate(value, param) {
return typeof value === "function" ? value(param) : value;
}
function getSide(placement) {
return placement.split("-")[0];
}
function getAlignment(placement) {
return placement.split("-")[1];
}
function getOppositeAxis(axis) {
return axis === "x" ? "y" : "x";
}
function getAxisLength(axis) {
return axis === "y" ? "height" : "width";
}
const yAxisSides = /* @__PURE__ */ new Set(["top", "bottom"]);
function getSideAxis(placement) {
return yAxisSides.has(getSide(placement)) ? "y" : "x";
}
function getAlignmentAxis(placement) {
return getOppositeAxis(getSideAxis(placement));
}
function getAlignmentSides(placement, rects, rtl) {
if (rtl === void 0) {
rtl = false;
}
const alignment = getAlignment(placement);
const alignmentAxis = getAlignmentAxis(placement);
const length = getAxisLength(alignmentAxis);
let mainAlignmentSide = alignmentAxis === "x" ? alignment === (rtl ? "end" : "start") ? "right" : "left" : alignment === "start" ? "bottom" : "top";
if (rects.reference[length] > rects.floating[length]) {
mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
}
return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
}
function getExpandedPlacements(placement) {
const oppositePlacement = getOppositePlacement(placement);
return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
}
function getOppositeAlignmentPlacement(placement) {
return placement.replace(/start|end/g, (alignment) => oppositeAlignmentMap[alignment]);
}
const lrPlacement = ["left", "right"];
const rlPlacement = ["right", "left"];
const tbPlacement = ["top", "bottom"];
const btPlacement = ["bottom", "top"];
function getSideList(side, isStart, rtl) {
switch (side) {
case "top":
case "bottom":
if (rtl) return isStart ? rlPlacement : lrPlacement;
return isStart ? lrPlacement : rlPlacement;
case "left":
case "right":
return isStart ? tbPlacement : btPlacement;
default:
return [];
}
}
function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
const alignment = getAlignment(placement);
let list = getSideList(getSide(placement), direction === "start", rtl);
if (alignment) {
list = list.map((side) => side + "-" + alignment);
if (flipAlignment) {
list = list.concat(list.map(getOppositeAlignmentPlacement));
}
}
return list;
}
function getOppositePlacement(placement) {
return placement.replace(/left|right|bottom|top/g, (side) => oppositeSideMap[side]);
}
function expandPaddingObject(padding) {
return {
top: 0,
right: 0,
bottom: 0,
left: 0,
...padding
};
}
function getPaddingObject(padding) {
return typeof padding !== "number" ? expandPaddingObject(padding) : {
top: padding,
right: padding,
bottom: padding,
left: padding
};
}
function rectToClientRect(rect) {
const {
x: x2,
y: y2,
width,
height
} = rect;
return {
width,
height,
top: y2,
left: x2,
right: x2 + width,
bottom: y2 + height,
x: x2,
y: y2
};
}
function computeCoordsFromPlacement(_ref, placement, rtl) {
let {
reference,
floating
} = _ref;
const sideAxis = getSideAxis(placement);
const alignmentAxis = getAlignmentAxis(placement);
const alignLength = getAxisLength(alignmentAxis);
const side = getSide(placement);
const isVertical = sideAxis === "y";
const commonX = reference.x + reference.width / 2 - floating.width / 2;
const commonY = reference.y + reference.height / 2 - floating.height / 2;
const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
let coords;
switch (side) {
case "top":
coords = {
x: commonX,
y: reference.y - floating.height
};
break;
case "bottom":
coords = {
x: commonX,
y: reference.y + reference.height
};
break;
case "right":
coords = {
x: reference.x + reference.width,
y: commonY
};
break;
case "left":
coords = {
x: reference.x - floating.width,
y: commonY
};
break;
default:
coords = {
x: reference.x,
y: reference.y
};
}
switch (getAlignment(placement)) {
case "start":
coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);
break;
case "end":
coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
break;
}
return coords;
}
const computePosition$1 = async (reference, floating, config) => {
const {
placement = "bottom",
strategy = "absolute",
middleware = [],
platform: platform2
} = config;
const validMiddleware = middleware.filter(Boolean);
const rtl = await (platform2.isRTL == null ? void 0 : platform2.isRTL(floating));
let rects = await platform2.getElementRects({
reference,
floating,
strategy
});
let {
x: x2,
y: y2
} = computeCoordsFromPlacement(rects, placement, rtl);
let statefulPlacement = placement;
let middlewareData = {};
let resetCount = 0;
for (let i = 0; i < validMiddleware.length; i++) {
const {
name,
fn
} = validMiddleware[i];
const {
x: nextX,
y: nextY,
data,
reset
} = await fn({
x: x2,
y: y2,
initialPlacement: placement,
placement: statefulPlacement,
strategy,
middlewareData,
rects,
platform: platform2,
elements: {
reference,
floating
}
});
x2 = nextX != null ? nextX : x2;
y2 = nextY != null ? nextY : y2;
middlewareData = {
...middlewareData,
[name]: {
...middlewareData[name],
...data
}
};
if (reset && resetCount <= 50) {
resetCount++;
if (typeof reset === "object") {
if (reset.placement) {
statefulPlacement = reset.placement;
}
if (reset.rects) {
rects = reset.rects === true ? await platform2.getElementRects({
reference,
floating,
strategy
}) : reset.rects;
}
({
x: x2,
y: y2
} = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
}
i = -1;
}
}
return {
x: x2,
y: y2,
placement: statefulPlacement,
strategy,
middlewareData
};
};
async function detectOverflow(state, options) {
var _await$platform$isEle;
if (options === void 0) {
options = {};
}
const {
x: x2,
y: y2,
platform: platform2,
rects,
elements,
strategy
} = state;
const {
boundary = "clippingAncestors",
rootBoundary = "viewport",
elementContext = "floating",
altBoundary = false,
padding = 0
} = evaluate(options, state);
const paddingObject = getPaddingObject(padding);
const altContext = elementContext === "floating" ? "reference" : "floating";
const element = elements[altBoundary ? altContext : elementContext];
const clippingClientRect = rectToClientRect(await platform2.getClippingRect({
element: ((_await$platform$isEle = await (platform2.isElement == null ? void 0 : platform2.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || await (platform2.getDocumentElement == null ? void 0 : platform2.getDocumentElement(elements.floating)),
boundary,
rootBoundary,
strategy
}));
const rect = elementContext === "floating" ? {
x: x2,
y: y2,
width: rects.floating.width,
height: rects.floating.height
} : rects.reference;
const offsetParent = await (platform2.getOffsetParent == null ? void 0 : platform2.getOffsetParent(elements.floating));
const offsetScale = await (platform2.isElement == null ? void 0 : platform2.isElement(offsetParent)) ? await (platform2.getScale == null ? void 0 : platform2.getScale(offsetParent)) || {
x: 1,
y: 1
} : {
x: 1,
y: 1
};
const elementClientRect = rectToClientRect(platform2.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform2.convertOffsetParentRelativeRectToViewportRelativeRect({
elements,
rect,
offsetParent,
strategy
}) : rect);
return {
top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
};
}
const arrow$3 = (options) => ({
name: "arrow",
options,
async fn(state) {
const {
x: x2,
y: y2,
placement,
rects,
platform: platform2,
elements,
middlewareData
} = state;
const {
element,
padding = 0
} = evaluate(options, state) || {};
if (element == null) {
return {};
}
const paddingObject = getPaddingObject(padding);
const coords = {
x: x2,
y: y2
};
const axis = getAlignmentAxis(placement);
const length = getAxisLength(axis);
const arrowDimensions = await platform2.getDimensions(element);
const isYAxis = axis === "y";
const minProp = isYAxis ? "top" : "left";
const maxProp = isYAxis ? "bottom" : "right";
const clientProp = isYAxis ? "clientHeight" : "clientWidth";
const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];
const startDiff = coords[axis] - rects.reference[axis];
const arrowOffsetParent = await (platform2.getOffsetParent == null ? void 0 : platform2.getOffsetParent(element));
let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;
if (!clientSize || !await (platform2.isElement == null ? void 0 : platform2.isElement(arrowOffsetParent))) {
clientSize = elements.floating[clientProp] || rects.floating[length];
}
const centerToReference = endDiff / 2 - startDiff / 2;
const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;
const minPadding = min(paddingObject[minProp], largestPossiblePadding);
const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);
const min$1 = minPadding;
const max2 = clientSize - arrowDimensions[length] - maxPadding;
const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;
const offset2 = clamp(min$1, center, max2);
const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset2 && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;
const alignmentOffset = shouldAddOffset ? center < min$1 ? center - min$1 : center - max2 : 0;
return {
[axis]: coords[axis] + alignmentOffset,
data: {
[axis]: offset2,
centerOffset: center - offset2 - alignmentOffset,
...shouldAddOffset && {
alignmentOffset
}
},
reset: shouldAddOffset
};
}
});
const flip$2 = function(options) {
if (options === void 0) {
options = {};
}
return {
name: "flip",
options,
async fn(state) {
var _middlewareData$arrow, _middlewareData$flip;
const {
placement,
middlewareData,
rects,
initialPlacement,
platform: platform2,
elements
} = state;
const {
mainAxis: checkMainAxis = true,
crossAxis: checkCrossAxis = true,
fallbackPlacements: specifiedFallbackPlacements,
fallbackStrategy = "bestFit",
fallbackAxisSideDirection = "none",
flipAlignment = true,
...detectOverflowOptions
} = evaluate(options, state);
if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
return {};
}
const side = getSide(placement);
const initialSideAxis = getSideAxis(initialPlacement);
const isBasePlacement = getSide(initialPlacement) === initialPlacement;
const rtl = await (platform2.isRTL == null ? void 0 : platform2.isRTL(elements.floating));
const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));
const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== "none";
if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {
fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
}
const placements = [initialPlacement, ...fallbackPlacements];
const overflow = await detectOverflow(state, detectOverflowOptions);
const overflows = [];
let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
if (checkMainAxis) {
overflows.push(overflow[side]);
}
if (checkCrossAxis) {
const sides2 = getAlignmentSides(placement, rects, rtl);
overflows.push(overflow[sides2[0]], overflow[sides2[1]]);
}
overflowsData = [...overflowsData, {
placement,
overflows
}];
if (!overflows.every((side2) => side2 <= 0)) {
var _middlewareData$flip2, _overflowsData$filter;
const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
const nextPlacement = placements[nextIndex];
if (nextPlacement) {
const ignoreCrossAxisOverflow = checkCrossAxis === "alignment" ? initialSideAxis !== getSideAxis(nextPlacement) : false;
if (!ignoreCrossAxisOverflow || // We leave the current main axis only if every placement on that axis
// overflows the main axis.
overflowsData.every((d) => d.overflows[0] > 0 && getSideAxis(d.placement) === initialSideAxis)) {
return {
data: {
index: nextIndex,
overflows: overflowsData
},
reset: {
placement: nextPlacement
}
};
}
}
let resetPlacement = (_overflowsData$filter = overflowsData.filter((d) => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
if (!resetPlacement) {
switch (fallbackStrategy) {
case "bestFit": {
var _overflowsData$filter2;
const placement2 = (_overflowsData$filter2 = overflowsData.filter((d) => {
if (hasFallbackAxisSideDirection) {
const currentSideAxis = getSideAxis(d.placement);
return currentSideAxis === initialSideAxis || // Create a bias to the `y` side axis due to horizontal
// reading directions favoring greater width.
currentSideAxis === "y";
}
return true;
}).map((d) => [d.placement, d.overflows.filter((overflow2) => overflow2 > 0).reduce((acc, overflow2) => acc + overflow2, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];
if (placement2) {
resetPlacement = placement2;
}
break;
}
case "initialPlacement":
resetPlacement = initialPlacement;
break;
}
}
if (placement !== resetPlacement) {
return {
reset: {
placement: resetPlacement
}
};
}
}
return {};
}
};
};
function getSideOffsets(overflow, rect) {
return {
top: overflow.top - rect.height,
right: overflow.right - rect.width,
bottom: overflow.bottom - rect.height,
left: overflow.left - rect.width
};
}
function isAnySideFullyClipped(overflow) {
return sides.some((side) => overflow[side] >= 0);
}
const hide$2 = function(options) {
if (options === void 0) {
options = {};
}
return {
name: "hide",
options,
async fn(state) {
const {
rects
} = state;
const {
strategy = "referenceHidden",
...detectOverflowOptions
} = evaluate(options, state);
switch (strategy) {
case "referenceHidden": {
const overflow = await detectOverflow(state, {
...detectOverflowOptions,
elementContext: "reference"
});
const offsets = getSideOffsets(overflow, rects.reference);
return {
data: {
referenceHiddenOffsets: offsets,
referenceHidden: isAnySideFullyClipped(offsets)
}
};
}
case "escaped": {
const overflow = await detectOverflow(state, {
...detectOverflowOptions,
altBoundary: true
});
const offsets = getSideOffsets(overflow, rects.floating);
return {
data: {
escapedOffsets: offsets,
escaped: isAnySideFullyClipped(offsets)
}
};
}
default: {
return {};
}
}
}
};
};
const originSides = /* @__PURE__ */ new Set(["left", "top"]);
async function convertValueToCoords(state, options) {
const {
placement,
platform: platform2,
elements
} = state;
const rtl = await (platform2.isRTL == null ? void 0 : platform2.isRTL(elements.floating));
const side = getSide(placement);
const alignment = getAlignment(placement);
const isVertical = getSideAxis(placement) === "y";
const mainAxisMulti = originSides.has(side) ? -1 : 1;
const crossAxisMulti = rtl && isVertical ? -1 : 1;
const rawValue = evaluate(options, state);
let {
mainAxis,
crossAxis,
alignmentAxis
} = typeof rawValue === "number" ? {
mainAxis: rawValue,
crossAxis: 0,
alignmentAxis: null
} : {
mainAxis: rawValue.mainAxis || 0,
crossAxis: rawValue.crossAxis || 0,
alignmentAxis: rawValue.alignmentAxis
};
if (alignment && typeof alignmentAxis === "number") {
crossAxis = alignment === "end" ? alignmentAxis * -1 : alignmentAxis;
}
return isVertical ? {
x: crossAxis * crossAxisMulti,
y: mainAxis * mainAxisMulti
} : {
x: mainAxis * mainAxisMulti,
y: crossAxis * crossAxisMulti
};
}
const offset$2 = function(options) {
if (options === void 0) {
options = 0;
}
return {
name: "offset",
options,
async fn(state) {
var _middlewareData$offse, _middlewareData$arrow;
const {
x: x2,
y: y2,
placement,
middlewareData
} = state;
const diffCoords = await convertValueToCoords(state, options);
if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
return {};
}
return {
x: x2 + diffCoords.x,
y: y2 + diffCoords.y,
data: {
...diffCoords,
placement
}
};
}
};
};
const shift$2 = function(options) {
if (options === void 0) {
options = {};
}
return {
name: "shift",
options,
async fn(state) {
const {
x: x2,
y: y2,
placement
} = state;
const {
mainAxis: checkMainAxis = true,
crossAxis: checkCrossAxis = false,
limiter = {
fn: (_ref) => {
let {
x: x3,
y: y3
} = _ref;
return {
x: x3,
y: y3
};
}
},
...detectOverflowOptions
} = evaluate(options, state);
const coords = {
x: x2,
y: y2
};
const overflow = await detectOverflow(state, detectOverflowOptions);
const crossAxis = getSideAxis(getSide(placement));
const mainAxis = getOppositeAxis(crossAxis);
let mainAxisCoord = coords[mainAxis];
let crossAxisCoord = coords[crossAxis];
if (checkMainAxis) {
const minSide = mainAxis === "y" ? "top" : "left";
const maxSide = mainAxis === "y" ? "bottom" : "right";
const min2 = mainAxisCoord + overflow[minSide];
const max2 = mainAxisCoord - overflow[maxSide];
mainAxisCoord = clamp(min2, mainAxisCoord, max2);
}
if (checkCrossAxis) {
const minSide = crossAxis === "y" ? "top" : "left";
const maxSide = crossAxis === "y" ? "bottom" : "right";
const min2 = crossAxisCoord + overflow[minSide];
const max2 = crossAxisCoord - overflow[maxSide];
crossAxisCoord = clamp(min2, crossAxisCoord, max2);
}
const limitedCoords = limiter.fn({
...state,
[mainAxis]: mainAxisCoord,
[crossAxis]: crossAxisCoord
});
return {
...limitedCoords,
data: {
x: limitedCoords.x - x2,
y: limitedCoords.y - y2,
enabled: {
[mainAxis]: checkMainAxis,
[crossAxis]: checkCrossAxis
}
}
};
}
};
};
const limitShift$2 = function(options) {
if (options === void 0) {
options = {};
}
return {
options,
fn(state) {
const {
x: x2,
y: y2,
placement,
rects,
middlewareData
} = state;
const {
offset: offset2 = 0,
mainAxis: checkMainAxis = true,
crossAxis: checkCrossAxis = true
} = evaluate(options, state);
const coords = {
x: x2,
y: y2
};
const crossAxis = getSideAxis(placement);
const mainAxis = getOppositeAxis(crossAxis);
let mainAxisCoord = coords[mainAxis];
let crossAxisCoord = coords[crossAxis];
const rawOffset = evaluate(offset2, state);
const computedOffset = typeof rawOffset === "number" ? {
mainAxis: rawOffset,
crossAxis: 0
} : {
mainAxis: 0,
crossAxis: 0,
...rawOffset
};
if (checkMainAxis) {
const len = mainAxis === "y" ? "height" : "width";
const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;
const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;
if (mainAxisCoord < limitMin) {
mainAxisCoord = limitMin;
} else if (mainAxisCoord > limitMax) {
mainAxisCoord = limitMax;
}
}
if (checkCrossAxis) {
var _middlewareData$offse, _middlewareData$offse2;
const len = mainAxis === "y" ? "width" : "height";
const isOriginSide = originSides.has(getSide(placement));
const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
if (crossAxisCoord < limitMin) {
crossAxisCoord = limitMin;
} else if (crossAxisCoord > limitMax) {
crossAxisCoord = limitMax;
}
}
return {
[mainAxis]: mainAxisCoord,
[crossAxis]: crossAxisCoord
};
}
};
};
const size$2 = function(options) {
if (options === void 0) {
options = {};
}
return {
name: "size",
options,
async fn(state) {
var _state$middlewareData, _state$middlewareData2;
const {
placement,
rects,
platform: platform2,
elements
} = state;
const {
apply = () => {
},
...detectOverflowOptions
} = evaluate(options, state);
const overflow = await detectOverflow(state, detectOverflowOptions);
const side = getSide(placement);
const alignment = getAlignment(placement);
const isYAxis = getSideAxis(placement) === "y";
const {
width,
height
} = rects.floating;
let heightSide;
let widthSide;
if (side === "top" || side === "bottom") {
heightSide = side;
widthSide = alignment === (await (platform2.isRTL == null ? void 0 : platform2.isRTL(elements.floating)) ? "start" : "end") ? "left" : "right";
} else {
widthSide = side;
heightSide = alignment === "end" ? "top" : "bottom";
}
const maximumClippingHeight = height - overflow.top - overflow.bottom;
const maximumClippingWidth = width - overflow.left - overflow.right;
const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);
const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);
const noShift = !state.middlewareData.shift;
let availableHeight = overflowAvailableHeight;
let availableWidth = overflowAvailableWidth;
if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {
availableWidth = maximumClippingWidth;
}
if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {
availableHeight = maximumClippingHeight;
}
if (noShift && !alignment) {
const xMin = max(overflow.left, 0);
const xMax = max(overflow.right, 0);
const yMin = max(overflow.top, 0);
const yMax = max(overflow.bottom, 0);
if (isYAxis) {
availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));
} else {
availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));
}
}
await apply({
...state,
availableWidth,
availableHeight
});
const nextDimensions = await platform2.getDimensions(elements.floating);
if (width !== nextDimensions.width || height !== nextDimensions.height) {
return {
reset: {
rects: true
}
};
}
return {};
}
};
};
function hasWindow() {
return typeof window !== "undefined";
}
function getNodeName(node) {
if (isNode(node)) {
return (node.nodeName || "").toLowerCase();
}
return "#document";
}
function getWindow(node) {
var _node$ownerDocument;
return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
}
function getDocumentElement(node) {
var _ref;
return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
}
function isNode(value) {
if (!hasWindow()) {
return false;
}
return value instanceof Node || value instanceof getWindow(value).Node;
}
function isElement(value) {
if (!hasWindow()) {
return false;
}
return value instanceof Element || value instanceof getWindow(value).Element;
}
function isHTMLElement(value) {
if (!hasWindow()) {
return false;
}
return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
}
function isShadowRoot(value) {
if (!hasWindow() || typeof ShadowRoot === "undefined") {
return false;
}
return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
}
const invalidOverflowDisplayValues = /* @__PURE__ */ new Set(["inline", "contents"]);
function isOverflowElement(element) {
const {
overflow,
overflowX,
overflowY,
display
} = getComputedStyle$1(element);
return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);
}
const tableElements = /* @__PURE__ */ new Set(["table", "td", "th"]);
function isTableElement(element) {
return tableElements.has(getNodeName(element));
}
const topLayerSelectors = [":popover-open", ":modal"];
function isTopLayer(element) {
return topLayerSelectors.some((selector) => {
try {
return element.matches(selector);
} catch (_e2) {
return false;
}
});
}
const transformProperties = ["transform", "translate", "scale", "rotate", "perspective"];
const willChangeValues = ["transform", "translate", "scale", "rotate", "perspective", "filter"];
const containValues = ["paint", "layout", "strict", "content"];
function isContainingBlock(elementOrCss) {
const webkit = isWebKit();
const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
return transformProperties.some((value) => css[value] ? css[value] !== "none" : false) || (css.containerType ? css.containerType !== "normal" : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== "none" : false) || !webkit && (css.filter ? css.filter !== "none" : false) || willChangeValues.some((value) => (css.willChange || "").includes(value)) || containValues.some((value) => (css.contain || "").includes(value));
}
function getContainingBlock(element) {
let currentNode = getParentNode(element);
while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
if (isContainingBlock(currentNode)) {
return currentNode;
} else if (isTopLayer(currentNode)) {
return null;
}
currentNode = getParentNode(currentNode);
}
return null;
}
function isWebKit() {
if (typeof CSS === "undefined" || !CSS.supports) return false;
return CSS.supports("-webkit-backdrop-filter", "none");
}
const lastTraversableNodeNames = /* @__PURE__ */ new Set(["html", "body", "#document"]);
function isLastTraversableNode(node) {
return lastTraversableNodeNames.has(getNodeName(node));
}
function getComputedStyle$1(element) {
return getWindow(element).getComputedStyle(element);
}
function getNodeScroll(element) {
if (isElement(element)) {
return {
scrollLeft: element.scrollLeft,
scrollTop: element.scrollTop
};
}
return {
scrollLeft: element.scrollX,
scrollTop: element.scrollY
};
}
function getParentNode(node) {
if (getNodeName(node) === "html") {
return node;
}
const result = (
// Step into the shadow DOM of the parent of a slotted node.
node.assignedSlot || // DOM Element detected.
node.parentNode || // ShadowRoot detected.
isShadowRoot(node) && node.host || // Fallback.
getDocumentElement(node)
);
return isShadowRoot(result) ? result.host : result;
}
function getNearestOverflowAncestor(node) {
const parentNode = getParentNode(node);
if (isLastTraversableNode(parentNode)) {
return node.ownerDocument ? node.ownerDocument.body : node.body;
}
if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
return parentNode;
}
return getNearestOverflowAncestor(parentNode);
}
function getOverflowAncestors(node, list, traverseIframes) {
var _node$ownerDocument2;
if (list === void 0) {
list = [];
}
if (traverseIframes === void 0) {
traverseIframes = true;
}
const scrollableAncestor = getNearestOverflowAncestor(node);
const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
const win = getWindow(scrollableAncestor);
if (isBody) {
const frameElement = getFrameElement(win);
return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
}
return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
}
function getFrameElement(win) {
return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
}
function getCssDimensions(element) {
const css = getComputedStyle$1(element);
let width = parseFloat(css.width) || 0;
let height = parseFloat(css.height) || 0;
const hasOffset = isHTMLElement(element);
const offsetWidth = hasOffset ? element.offsetWidth : width;
const offsetHeight = hasOffset ? element.offsetHeight : height;
const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
if (shouldFallback) {
width = offsetWidth;
height = offsetHeight;
}
return {
width,
height,
$: shouldFallback
};
}
function unwrapElement(element) {
return !isElement(element) ? element.contextElement : element;
}
function getScale(element) {
const domElement = unwrapElement(element);
if (!isHTMLElement(domElement)) {
return createCoords(1);
}
const rect = domElement.getBoundingClientRect();
const {
width,
height,
$
} = getCssDimensions(domElement);
let x2 = ($ ? round(rect.width) : rect.width) / width;
let y2 = ($ ? round(rect.height) : rect.height) / height;
if (!x2 || !Number.isFinite(x2)) {
x2 = 1;
}
if (!y2 || !Number.isFinite(y2)) {
y2 = 1;
}
return {
x: x2,
y: y2
};
}
const noOffsets = /* @__PURE__ */ createCoords(0);
function getVisualOffsets(element) {
const win = getWindow(element);
if (!isWebKit() || !win.visualViewport) {
return noOffsets;
}
return {
x: win.visualViewport.offsetLeft,
y: win.visualViewport.offsetTop
};
}
function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
if (isFixed === void 0) {
isFixed = false;
}
if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {
return false;
}
return isFixed;
}
function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {
if (includeScale === void 0) {
includeScale = false;
}
if (isFixedStrategy === void 0) {
isFixedStrategy = false;
}
const clientRect = element.getBoundingClientRect();
const domElement = unwrapElement(element);
let scale = createCoords(1);
if (includeScale) {
if (offsetParent) {
if (isElement(offsetParent)) {
scale = getScale(offsetParent);
}
} else {
scale = getScale(element);
}
}
const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
let x2 = (clientRect.left + visualOffsets.x) / scale.x;
let y2 = (clientRect.top + visualOffsets.y) / scale.y;
let width = clientRect.width / scale.x;
let height = clientRect.height / scale.y;
if (domElement) {
const win = getWindow(domElement);
const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;
let currentWin = win;
let currentIFrame = getFrameElement(currentWin);
while (currentIFrame && offsetParent && offsetWin !== currentWin) {
const iframeScale = getScale(currentIFrame);
const iframeRect = currentIFrame.getBoundingClientRect();
const css = getComputedStyle$1(currentIFrame);
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
x2 *= iframeScale.x;
y2 *= iframeScale.y;
width *= iframeScale.x;
height *= iframeScale.y;
x2 += left;
y2 += top;
currentWin = getWindow(currentIFrame);
currentIFrame = getFrameElement(currentWin);
}
}
return rectToClientRect({
width,
height,
x: x2,
y: y2
});
}
function getWindowScrollBarX(element, rect) {
const leftScroll = getNodeScroll(element).scrollLeft;
if (!rect) {
return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
}
return rect.left + leftScroll;
}
function getHTMLOffset(documentElement, scroll, ignoreScrollbarX) {
if (ignoreScrollbarX === void 0) {
ignoreScrollbarX = false;
}
const htmlRect = documentElement.getBoundingClientRect();
const x2 = htmlRect.left + scroll.scrollLeft - (ignoreScrollbarX ? 0 : (
// RTL scrollbar.
getWindowScrollBarX(documentElement, htmlRect)
));
const y2 = htmlRect.top + scroll.scrollTop;
return {
x: x2,
y: y2
};
}
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
let {
elements,
rect,
offsetParent,
strategy
} = _ref;
const isFixed = strategy === "fixed";
const documentElement = getDocumentElement(offsetParent);
const topLayer = elements ? isTopLayer(elements.floating) : false;
if (offsetParent === documentElement || topLayer && isFixed) {
return rect;
}
let scroll = {
scrollLeft: 0,
scrollTop: 0
};
let scale = createCoords(1);
const offsets = createCoords(0);
const isOffsetParentAnElement = isHTMLElement(offsetParent);
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
if (getNodeName(offsetParent) !== "body" || isOverflowElement(documentElement)) {
scroll = getNodeScroll(offsetParent);
}
if (isHTMLElement(offsetParent)) {
const offsetRect = getBoundingClientRect(offsetParent);
scale = getScale(offsetParent);
offsets.x = offsetRect.x + offsetParent.clientLeft;
offsets.y = offsetRect.y + offsetParent.clientTop;
}
}
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll, true) : createCoords(0);
return {
width: rect.width * scale.x,
height: rect.height * scale.y,
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
};
}
function getClientRects(element) {
return Array.from(element.getClientRects());
}
function getDocumentRect(element) {
const html = getDocumentElement(element);
const scroll = getNodeScroll(element);
const body = element.ownerDocument.body;
const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
let x2 = -scroll.scrollLeft + getWindowScrollBarX(element);
const y2 = -scroll.scrollTop;
if (getComputedStyle$1(body).direction === "rtl") {
x2 += max(html.clientWidth, body.clientWidth) - width;
}
return {
width,
height,
x: x2,
y: y2
};
}
function getViewportRect(element, strategy) {
const win = getWindow(element);
const html = getDocumentElement(element);
const visualViewport = win.visualViewport;
let width = html.clientWidth;
let height = html.clientHeight;
let x2 = 0;
let y2 = 0;
if (visualViewport) {
width = visualViewport.width;
height = visualViewport.height;
const visualViewportBased = isWebKit();
if (!visualViewportBased || visualViewportBased && strategy === "fixed") {
x2 = visualViewport.offsetLeft;
y2 = visualViewport.offsetTop;
}
}
return {
width,
height,
x: x2,
y: y2
};
}
const absoluteOrFixed = /* @__PURE__ */ new Set(["absolute", "fixed"]);
function getInnerBoundingClientRect(element, strategy) {
const clientRect = getBoundingClientRect(element, true, strategy === "fixed");
const top = clientRect.top + element.clientTop;
const left = clientRect.left + element.clientLeft;
const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
const width = element.clientWidth * scale.x;
const height = element.clientHeight * scale.y;
const x2 = left * scale.x;
const y2 = top * scale.y;
return {
width,
height,
x: x2,
y: y2
};
}
function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
let rect;
if (clippingAncestor === "viewport") {
rect = getViewportRect(element, strategy);
} else if (clippingAncestor === "document") {
rect = getDocumentRect(getDocumentElement(element));
} else if (isElement(clippingAncestor)) {
rect = getInnerBoundingClientRect(clippingAncestor, strategy);
} else {
const visualOffsets = getVisualOffsets(element);
rect = {
x: clippingAncestor.x - visualOffsets.x,
y: clippingAncestor.y - visualOffsets.y,
width: clippingAncestor.width,
height: clippingAncestor.height
};
}
return rectToClientRect(rect);
}
function hasFixedPositionAncestor(element, stopNode) {
const parentNode = getParentNode(element);
if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
return false;
}
return getComputedStyle$1(parentNode).position === "fixed" || hasFixedPositionAncestor(parentNode, stopNode);
}
function getClippingElementAncestors(element, cache) {
const cachedResult = cache.get(element);
if (cachedResult) {
return cachedResult;
}
let result = getOverflowAncestors(element, [], false).filter((el2) => isElement(el2) && getNodeName(el2) !== "body");
let currentContainingBlockComputedStyle = null;
const elementIsFixed = getComputedStyle$1(element).position === "fixed";
let currentNode = elementIsFixed ? getParentNode(element) : element;
while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
const computedStyle = getComputedStyle$1(currentNode);
const currentNodeIsContaining = isContainingBlock(currentNode);
if (!currentNodeIsContaining && computedStyle.position === "fixed") {
currentContainingBlockComputedStyle = null;
}
const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === "static" && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
if (shouldDropCurrentNode) {
result = result.filter((ancestor) => ancestor !== currentNode);
} else {
currentContainingBlockComputedStyle = computedStyle;
}
currentNode = getParentNode(currentNode);
}
cache.set(element, result);
return result;
}
function getClippingRect(_ref) {
let {
element,
boundary,
rootBoundary,
strategy
} = _ref;
const elementClippingAncestors = boundary === "clippingAncestors" ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);
const clippingAncestors = [...elementClippingAncestors, rootBoundary];
const firstClippingAncestor = clippingAncestors[0];
const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {
const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);
accRect.top = max(rect.top, accRect.top);
accRect.right = min(rect.right, accRect.right);
accRect.bottom = min(rect.bottom, accRect.bottom);
accRect.left = max(rect.left, accRect.left);
return accRect;
}, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));
return {
width: clippingRect.right - clippingRect.left,
height: clippingRect.bottom - clippingRect.top,
x: clippingRect.left,
y: clippingRect.top
};
}
function getDimensions(element) {
const {
width,
height
} = getCssDimensions(element);
return {
width,
height
};
}
function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
const isOffsetParentAnElement = isHTMLElement(offsetParent);
const documentElement = getDocumentElement(offsetParent);
const isFixed = strategy === "fixed";
const rect = getBoundingClientRect(element, true, isFixed, offsetParent);
let scroll = {
scrollLeft: 0,
scrollTop: 0
};
const offsets = createCoords(0);
function setLeftRTLScrollbarOffset() {
offsets.x = getWindowScrollBarX(documentElement);
}
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
if (getNodeName(offsetParent) !== "body" || isOverflowElement(documentElement)) {
scroll = getNodeScroll(offsetParent);
}
if (isOffsetParentAnElement) {
const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);
offsets.x = offsetRect.x + offsetParent.clientLeft;
offsets.y = offsetRect.y + offsetParent.clientTop;
} else if (documentElement) {
setLeftRTLScrollbarOffset();
}
}
if (isFixed && !isOffsetParentAnElement && documentElement) {
setLeftRTLScrollbarOffset();
}
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
const x2 = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
const y2 = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
return {
x: x2,
y: y2,
width: rect.width,
height: rect.height
};
}
function isStaticPositioned(element) {
return getComputedStyle$1(element).position === "static";
}
function getTrueOffsetParent(element, polyfill2) {
if (!isHTMLElement(element) || getComputedStyle$1(element).position === "fixed") {
return null;
}
if (polyfill2) {
return polyfill2(element);
}
let rawOffsetParent = element.offsetParent;
if (getDocumentElement(element) === rawOffsetParent) {
rawOffsetParent = rawOffsetParent.ownerDocument.body;
}
return rawOffsetParent;
}
function getOffsetParent(element, polyfill2) {
const win = getWindow(element);
if (isTopLayer(element)) {
return win;
}
if (!isHTMLElement(element)) {
let svgOffsetParent = getParentNode(element);
while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {
if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {
return svgOffsetParent;
}
svgOffsetParent = getParentNode(svgOffsetParent);
}
return win;
}
let offsetParent = getTrueOffsetParent(element, polyfill2);
while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {
offsetParent = getTrueOffsetParent(offsetParent, polyfill2);
}
if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {
return win;
}
return offsetParent || getContainingBlock(element) || win;
}
const getElementRects = async function(data) {
const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
const getDimensionsFn = this.getDimensions;
const floatingDimensions = await getDimensionsFn(data.floating);
return {
reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),
floating: {
x: 0,
y: 0,
width: floatingDimensions.width,
height: floatingDimensions.height
}
};
};
function isRTL(element) {
return getComputedStyle$1(element).direction === "rtl";
}
const platform = {
convertOffsetParentRelativeRectToViewportRelativeRect,
getDocumentElement,
getClippingRect,
getOffsetParent,
getElementRects,
getClientRects,
getDimensions,
getScale,
isElement,
isRTL
};
function rectsAreEqual(a, b) {
return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;
}
function observeMove(element, onMove) {
let io = null;
let timeoutId;
const root = getDocumentElement(element);
function cleanup() {
var _io;
clearTimeout(timeoutId);
(_io = io) == null || _io.disconnect();
io = null;
}
function refresh(skip, threshold) {
if (skip === void 0) {
skip = false;
}
if (threshold === void 0) {
threshold = 1;
}
cleanup();
const elementRectForRootMargin = element.getBoundingClientRect();
const {
left,
top,
width,
height
} = elementRectForRootMargin;
if (!skip) {
onMove();
}
if (!width || !height) {
return;
}
const insetTop = floor(top);
const insetRight = floor(root.clientWidth - (left + width));
const insetBottom = floor(root.clientHeight - (top + height));
const insetLeft = floor(left);
const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
const options = {
rootMargin,
threshold: max(0, min(1, threshold)) || 1
};
let isFirstUpdate = true;
function handleObserve(entries) {
const ratio = entries[0].intersectionRatio;
if (ratio !== threshold) {
if (!isFirstUpdate) {
return refresh();
}
if (!ratio) {
timeoutId = setTimeout(() => {
refresh(false, 1e-7);
}, 1e3);
} else {
refresh(false, ratio);
}
}
if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {
refresh();
}
isFirstUpdate = false;
}
try {
io = new IntersectionObserver(handleObserve, {
...options,
// Handle