@nuskin/chat-bot
Version:
React Chat Bot component for GenAI interaction with Amazon Bedrock
2,022 lines • 226 kB
JavaScript
var es = Object.defineProperty;
var ts = (e, t, r) => t in e ? es(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
var ct = (e, t, r) => ts(e, typeof t != "symbol" ? t + "" : t, r);
import * as M from "react";
import et, { isValidElement as Pt, cloneElement as kt, Children as rs, forwardRef as ns, useState as ue, useEffect as Lr, useRef as Cr } from "react";
import os from "react-dom";
import { jsxs as X, jsx as x, Fragment as is } from "react/jsx-runtime";
import { Snackbar as ss, Box as Ne, Collapse as as, Alert as ls, IconButton as cs, AppBar as us, Toolbar as fs, Typography as ds, Button as Mn, Stack as ps, Card as hs, CardContent as ms, Chip as gs, FormControl as ys, InputLabel as bs, Select as vs, MenuItem as Ss, FormGroup as Cs, TextField as ws } from "@mui/material";
import xs from "@emotion/styled";
import { ThemeContext as Rs, keyframes as De, css as St } from "@emotion/react";
import Es from "react-markdown";
import Ts from "remark-gfm";
import As from "rehype-raw";
function zo(e, t) {
for (var r = 0; r < t.length; r++) {
const n = t[r];
if (typeof n != "string" && !Array.isArray(n)) {
for (const o in n)
if (o !== "default" && !(o in e)) {
const i = Object.getOwnPropertyDescriptor(n, o);
i && Object.defineProperty(e, o, i.get ? i : {
enumerable: !0,
get: () => n[o]
});
}
}
}
return Object.freeze(Object.defineProperty(e, Symbol.toStringTag, { value: "Module" }));
}
var Os = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
function qo(e) {
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
}
var Ho, Ln = os;
Ho = Ln.createRoot, Ln.hydrateRoot;
var Vo = { exports: {} }, G = {};
/**
* @license React
* react-is.production.js
*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
var ln = Symbol.for("react.transitional.element"), cn = Symbol.for("react.portal"), Vt = Symbol.for("react.fragment"), Wt = Symbol.for("react.strict_mode"), Gt = Symbol.for("react.profiler"), Kt = Symbol.for("react.consumer"), Yt = Symbol.for("react.context"), Jt = Symbol.for("react.forward_ref"), Xt = Symbol.for("react.suspense"), Qt = Symbol.for("react.suspense_list"), Zt = Symbol.for("react.memo"), er = Symbol.for("react.lazy"), Ps = Symbol.for("react.offscreen"), ks = Symbol.for("react.client.reference");
function ge(e) {
if (typeof e == "object" && e !== null) {
var t = e.$$typeof;
switch (t) {
case ln:
switch (e = e.type, e) {
case Vt:
case Gt:
case Wt:
case Xt:
case Qt:
return e;
default:
switch (e = e && e.$$typeof, e) {
case Yt:
case Jt:
case er:
case Zt:
return e;
case Kt:
return e;
default:
return t;
}
}
case cn:
return t;
}
}
}
G.ContextConsumer = Kt;
G.ContextProvider = Yt;
G.Element = ln;
G.ForwardRef = Jt;
G.Fragment = Vt;
G.Lazy = er;
G.Memo = Zt;
G.Portal = cn;
G.Profiler = Gt;
G.StrictMode = Wt;
G.Suspense = Xt;
G.SuspenseList = Qt;
G.isContextConsumer = function(e) {
return ge(e) === Kt;
};
G.isContextProvider = function(e) {
return ge(e) === Yt;
};
G.isElement = function(e) {
return typeof e == "object" && e !== null && e.$$typeof === ln;
};
G.isForwardRef = function(e) {
return ge(e) === Jt;
};
G.isFragment = function(e) {
return ge(e) === Vt;
};
G.isLazy = function(e) {
return ge(e) === er;
};
G.isMemo = function(e) {
return ge(e) === Zt;
};
G.isPortal = function(e) {
return ge(e) === cn;
};
G.isProfiler = function(e) {
return ge(e) === Gt;
};
G.isStrictMode = function(e) {
return ge(e) === Wt;
};
G.isSuspense = function(e) {
return ge(e) === Xt;
};
G.isSuspenseList = function(e) {
return ge(e) === Qt;
};
G.isValidElementType = function(e) {
return typeof e == "string" || typeof e == "function" || e === Vt || e === Gt || e === Wt || e === Xt || e === Qt || e === Ps || typeof e == "object" && e !== null && (e.$$typeof === er || e.$$typeof === Zt || e.$$typeof === Yt || e.$$typeof === Kt || e.$$typeof === Jt || e.$$typeof === ks || e.getModuleId !== void 0);
};
G.typeOf = ge;
Vo.exports = G;
var Wo = Vo.exports;
function ke(e) {
if (typeof e != "object" || e === null)
return !1;
const t = Object.getPrototypeOf(e);
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e);
}
function Go(e) {
if (/* @__PURE__ */ M.isValidElement(e) || Wo.isValidElementType(e) || !ke(e))
return e;
const t = {};
return Object.keys(e).forEach((r) => {
t[r] = Go(e[r]);
}), t;
}
function de(e, t, r = {
clone: !0
}) {
const n = r.clone ? {
...e
} : e;
return ke(e) && ke(t) && Object.keys(t).forEach((o) => {
/* @__PURE__ */ M.isValidElement(t[o]) || Wo.isValidElementType(t[o]) ? n[o] = t[o] : ke(t[o]) && // Avoid prototype pollution
Object.prototype.hasOwnProperty.call(e, o) && ke(e[o]) ? n[o] = de(e[o], t[o], r) : r.clone ? n[o] = ke(t[o]) ? Go(t[o]) : t[o] : n[o] = t[o];
}), n;
}
function He(e, ...t) {
const r = new URL(`https://mui.com/production-error/?code=${e}`);
return t.forEach((n) => r.searchParams.append("args[]", n)), `Minified MUI error #${e}; visit ${r} for the full message.`;
}
function q(e) {
if (typeof e != "string")
throw new Error(He(7));
return e.charAt(0).toUpperCase() + e.slice(1);
}
function _s(e, t) {
typeof e == "function" ? e(t) : e && (e.current = t);
}
const Is = typeof window < "u" ? M.useLayoutEffect : M.useEffect;
let Dn = 0;
function $s(e) {
const [t, r] = M.useState(e), n = e || t;
return M.useEffect(() => {
t == null && (Dn += 1, r(`mui-${Dn}`));
}, [t]), n;
}
const Ns = {
...M
}, Fn = Ns.useId;
function Bs(e) {
if (Fn !== void 0) {
const t = Fn();
return e ?? t;
}
return $s(e);
}
function _t(e) {
const t = M.useRef(e);
return Is(() => {
t.current = e;
}), M.useRef((...r) => (
// @ts-expect-error hide `this`
(0, t.current)(...r)
)).current;
}
function Dr(...e) {
return M.useMemo(() => e.every((t) => t == null) ? null : (t) => {
e.forEach((r) => {
_s(r, t);
});
}, e);
}
const jn = {};
function Ko(e, t) {
const r = M.useRef(jn);
return r.current === jn && (r.current = e(t)), r;
}
const Ms = [];
function Ls(e) {
M.useEffect(e, Ms);
}
class un {
constructor() {
ct(this, "currentId", null);
ct(this, "clear", () => {
this.currentId !== null && (clearTimeout(this.currentId), this.currentId = null);
});
ct(this, "disposeEffect", () => this.clear);
}
static create() {
return new un();
}
/**
* Executes `fn` after `delay`, clearing any previously scheduled call.
*/
start(t, r) {
this.clear(), this.currentId = setTimeout(() => {
this.currentId = null, r();
}, t);
}
}
function Ds() {
const e = Ko(un.create).current;
return Ls(e.disposeEffect), e;
}
function Un(e) {
try {
return e.matches(":focus-visible");
} catch {
}
return !1;
}
function Fr(e, t) {
const r = {
...t
};
for (const n in e)
if (Object.prototype.hasOwnProperty.call(e, n)) {
const o = n;
if (o === "components" || o === "slots")
r[o] = {
...e[o],
...r[o]
};
else if (o === "componentsProps" || o === "slotProps") {
const i = e[o], s = t[o];
if (!s)
r[o] = i || {};
else if (!i)
r[o] = s;
else {
r[o] = {
...s
};
for (const a in i)
if (Object.prototype.hasOwnProperty.call(i, a)) {
const u = a;
r[o][u] = Fr(i[u], s[u]);
}
}
} else r[o] === void 0 && (r[o] = e[o]);
}
return r;
}
function We(e, t, r = void 0) {
const n = {};
for (const o in e) {
const i = e[o];
let s = "", a = !0;
for (let u = 0; u < i.length; u += 1) {
const c = i[u];
c && (s += (a === !0 ? "" : " ") + t(c), a = !1, r && r[c] && (s += " " + r[c]));
}
n[o] = s;
}
return n;
}
const zn = (e) => e, Fs = () => {
let e = zn;
return {
configure(t) {
e = t;
},
generate(t) {
return e(t);
},
reset() {
e = zn;
}
};
}, js = Fs(), Us = {
active: "active",
checked: "checked",
completed: "completed",
disabled: "disabled",
error: "error",
expanded: "expanded",
focused: "focused",
focusVisible: "focusVisible",
open: "open",
readOnly: "readOnly",
required: "required",
selected: "selected"
};
function Fe(e, t, r = "Mui") {
const n = Us[t];
return n ? `${r}-${n}` : `${js.generate(e)}-${t}`;
}
function je(e, t, r = "Mui") {
const n = {};
return t.forEach((o) => {
n[o] = Fe(e, o, r);
}), n;
}
function zs(e, t = Number.MIN_SAFE_INTEGER, r = Number.MAX_SAFE_INTEGER) {
return Math.max(t, Math.min(e, r));
}
function qs(e) {
return typeof e == "string";
}
function Hs(e, t, r) {
return e === void 0 || qs(e) ? t : {
...t,
ownerState: {
...t.ownerState,
...r
}
};
}
function Yo(e) {
var t, r, n = "";
if (typeof e == "string" || typeof e == "number") n += e;
else if (typeof e == "object") if (Array.isArray(e)) {
var o = e.length;
for (t = 0; t < o; t++) e[t] && (r = Yo(e[t])) && (n && (n += " "), n += r);
} else for (r in e) e[r] && (n && (n += " "), n += r);
return n;
}
function re() {
for (var e, t, r = 0, n = "", o = arguments.length; r < o; r++) (e = arguments[r]) && (t = Yo(e)) && (n && (n += " "), n += t);
return n;
}
function Vs(e, t = []) {
if (e === void 0)
return {};
const r = {};
return Object.keys(e).filter((n) => n.match(/^on[A-Z]/) && typeof e[n] == "function" && !t.includes(n)).forEach((n) => {
r[n] = e[n];
}), r;
}
function qn(e) {
if (e === void 0)
return {};
const t = {};
return Object.keys(e).filter((r) => !(r.match(/^on[A-Z]/) && typeof e[r] == "function")).forEach((r) => {
t[r] = e[r];
}), t;
}
function Ws(e) {
const {
getSlotProps: t,
additionalProps: r,
externalSlotProps: n,
externalForwardedProps: o,
className: i
} = e;
if (!t) {
const y = re(r == null ? void 0 : r.className, i, o == null ? void 0 : o.className, n == null ? void 0 : n.className), h = {
...r == null ? void 0 : r.style,
...o == null ? void 0 : o.style,
...n == null ? void 0 : n.style
}, m = {
...r,
...o,
...n
};
return y.length > 0 && (m.className = y), Object.keys(h).length > 0 && (m.style = h), {
props: m,
internalRef: void 0
};
}
const s = Vs({
...o,
...n
}), a = qn(n), u = qn(o), c = t(s), f = re(c == null ? void 0 : c.className, r == null ? void 0 : r.className, i, o == null ? void 0 : o.className, n == null ? void 0 : n.className), d = {
...c == null ? void 0 : c.style,
...r == null ? void 0 : r.style,
...o == null ? void 0 : o.style,
...n == null ? void 0 : n.style
}, p = {
...c,
...r,
...u,
...a
};
return f.length > 0 && (p.className = f), Object.keys(d).length > 0 && (p.style = d), {
props: p,
internalRef: c.ref
};
}
function Gs(e, t, r) {
return typeof e == "function" ? e(t, r) : e;
}
function mt(e, t) {
return t ? de(e, t, {
clone: !1
// No need to clone deep, it's way faster.
}) : e;
}
function Ks(e, t) {
if (!e.containerQueries)
return t;
const r = Object.keys(t).filter((n) => n.startsWith("@container")).sort((n, o) => {
var s, a;
const i = /min-width:\s*([0-9.]+)/;
return +(((s = n.match(i)) == null ? void 0 : s[1]) || 0) - +(((a = o.match(i)) == null ? void 0 : a[1]) || 0);
});
return r.length ? r.reduce((n, o) => {
const i = t[o];
return delete n[o], n[o] = i, n;
}, {
...t
}) : t;
}
function Ys(e, t) {
return t === "@" || t.startsWith("@") && (e.some((r) => t.startsWith(`@${r}`)) || !!t.match(/^@\d/));
}
function Js(e, t) {
const r = t.match(/^@([^/]+)?\/?(.+)?$/);
if (!r)
return null;
const [, n, o] = r, i = Number.isNaN(+n) ? n || 0 : +n;
return e.containerQueries(o).up(i);
}
function Xs(e) {
const t = (i, s) => i.replace("@media", s ? `@container ${s}` : "@container");
function r(i, s) {
i.up = (...a) => t(e.breakpoints.up(...a), s), i.down = (...a) => t(e.breakpoints.down(...a), s), i.between = (...a) => t(e.breakpoints.between(...a), s), i.only = (...a) => t(e.breakpoints.only(...a), s), i.not = (...a) => {
const u = t(e.breakpoints.not(...a), s);
return u.includes("not all and") ? u.replace("not all and ", "").replace("min-width:", "width<").replace("max-width:", "width>").replace("and", "or") : u;
};
}
const n = {}, o = (i) => (r(n, i), n);
return r(o), {
...e,
containerQueries: o
};
}
const tr = {
xs: 0,
// phone
sm: 600,
// tablet
md: 900,
// small laptop
lg: 1200,
// desktop
xl: 1536
// large screen
}, Hn = {
// Sorted ASC by size. That's important.
// It can't be configured as it's used statically for propTypes.
keys: ["xs", "sm", "md", "lg", "xl"],
up: (e) => `@media (min-width:${tr[e]}px)`
}, Qs = {
containerQueries: (e) => ({
up: (t) => {
let r = typeof t == "number" ? t : tr[t] || t;
return typeof r == "number" && (r = `${r}px`), e ? `@container ${e} (min-width:${r})` : `@container (min-width:${r})`;
}
})
};
function _e(e, t, r) {
const n = e.theme || {};
if (Array.isArray(t)) {
const i = n.breakpoints || Hn;
return t.reduce((s, a, u) => (s[i.up(i.keys[u])] = r(t[u]), s), {});
}
if (typeof t == "object") {
const i = n.breakpoints || Hn;
return Object.keys(t).reduce((s, a) => {
if (Ys(i.keys, a)) {
const u = Js(n.containerQueries ? n : Qs, a);
u && (s[u] = r(t[a], a));
} else if (Object.keys(i.values || tr).includes(a)) {
const u = i.up(a);
s[u] = r(t[a], a);
} else {
const u = a;
s[u] = t[u];
}
return s;
}, {});
}
return r(t);
}
function Zs(e = {}) {
var r;
return ((r = e.keys) == null ? void 0 : r.reduce((n, o) => {
const i = e.up(o);
return n[i] = {}, n;
}, {})) || {};
}
function ea(e, t) {
return e.reduce((r, n) => {
const o = r[n];
return (!o || Object.keys(o).length === 0) && delete r[n], r;
}, t);
}
function rr(e, t, r = !0) {
if (!t || typeof t != "string")
return null;
if (e && e.vars && r) {
const n = `vars.${t}`.split(".").reduce((o, i) => o && o[i] ? o[i] : null, e);
if (n != null)
return n;
}
return t.split(".").reduce((n, o) => n && n[o] != null ? n[o] : null, e);
}
function Lt(e, t, r, n = r) {
let o;
return typeof e == "function" ? o = e(r) : Array.isArray(e) ? o = e[r] || n : o = rr(e, r) || n, t && (o = t(o, n, e)), o;
}
function ee(e) {
const {
prop: t,
cssProperty: r = e.prop,
themeKey: n,
transform: o
} = e, i = (s) => {
if (s[t] == null)
return null;
const a = s[t], u = s.theme, c = rr(u, n) || {};
return _e(s, a, (d) => {
let p = Lt(c, o, d);
return d === p && typeof d == "string" && (p = Lt(c, o, `${t}${d === "default" ? "" : q(d)}`, d)), r === !1 ? p : {
[r]: p
};
});
};
return i.propTypes = {}, i.filterProps = [t], i;
}
function ta(e) {
const t = {};
return (r) => (t[r] === void 0 && (t[r] = e(r)), t[r]);
}
const ra = {
m: "margin",
p: "padding"
}, na = {
t: "Top",
r: "Right",
b: "Bottom",
l: "Left",
x: ["Left", "Right"],
y: ["Top", "Bottom"]
}, Vn = {
marginX: "mx",
marginY: "my",
paddingX: "px",
paddingY: "py"
}, oa = ta((e) => {
if (e.length > 2)
if (Vn[e])
e = Vn[e];
else
return [e];
const [t, r] = e.split(""), n = ra[t], o = na[r] || "";
return Array.isArray(o) ? o.map((i) => n + i) : [n + o];
}), fn = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], dn = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"];
[...fn, ...dn];
function Ct(e, t, r, n) {
const o = rr(e, t, !0) ?? r;
return typeof o == "number" || typeof o == "string" ? (i) => typeof i == "string" ? i : typeof o == "string" ? `calc(${i} * ${o})` : o * i : Array.isArray(o) ? (i) => {
if (typeof i == "string")
return i;
const s = Math.abs(i), a = o[s];
return i >= 0 ? a : typeof a == "number" ? -a : `-${a}`;
} : typeof o == "function" ? o : () => {
};
}
function pn(e) {
return Ct(e, "spacing", 8);
}
function wt(e, t) {
return typeof t == "string" || t == null ? t : e(t);
}
function ia(e, t) {
return (r) => e.reduce((n, o) => (n[o] = wt(t, r), n), {});
}
function sa(e, t, r, n) {
if (!t.includes(r))
return null;
const o = oa(r), i = ia(o, n), s = e[r];
return _e(e, s, i);
}
function Jo(e, t) {
const r = pn(e.theme);
return Object.keys(e).map((n) => sa(e, t, n, r)).reduce(mt, {});
}
function Q(e) {
return Jo(e, fn);
}
Q.propTypes = {};
Q.filterProps = fn;
function Z(e) {
return Jo(e, dn);
}
Z.propTypes = {};
Z.filterProps = dn;
function nr(...e) {
const t = e.reduce((n, o) => (o.filterProps.forEach((i) => {
n[i] = o;
}), n), {}), r = (n) => Object.keys(n).reduce((o, i) => t[i] ? mt(o, t[i](n)) : o, {});
return r.propTypes = {}, r.filterProps = e.reduce((n, o) => n.concat(o.filterProps), []), r;
}
function me(e) {
return typeof e != "number" ? e : `${e}px solid`;
}
function ye(e, t) {
return ee({
prop: e,
themeKey: "borders",
transform: t
});
}
const aa = ye("border", me), la = ye("borderTop", me), ca = ye("borderRight", me), ua = ye("borderBottom", me), fa = ye("borderLeft", me), da = ye("borderColor"), pa = ye("borderTopColor"), ha = ye("borderRightColor"), ma = ye("borderBottomColor"), ga = ye("borderLeftColor"), ya = ye("outline", me), ba = ye("outlineColor"), or = (e) => {
if (e.borderRadius !== void 0 && e.borderRadius !== null) {
const t = Ct(e.theme, "shape.borderRadius", 4), r = (n) => ({
borderRadius: wt(t, n)
});
return _e(e, e.borderRadius, r);
}
return null;
};
or.propTypes = {};
or.filterProps = ["borderRadius"];
nr(aa, la, ca, ua, fa, da, pa, ha, ma, ga, or, ya, ba);
const ir = (e) => {
if (e.gap !== void 0 && e.gap !== null) {
const t = Ct(e.theme, "spacing", 8), r = (n) => ({
gap: wt(t, n)
});
return _e(e, e.gap, r);
}
return null;
};
ir.propTypes = {};
ir.filterProps = ["gap"];
const sr = (e) => {
if (e.columnGap !== void 0 && e.columnGap !== null) {
const t = Ct(e.theme, "spacing", 8), r = (n) => ({
columnGap: wt(t, n)
});
return _e(e, e.columnGap, r);
}
return null;
};
sr.propTypes = {};
sr.filterProps = ["columnGap"];
const ar = (e) => {
if (e.rowGap !== void 0 && e.rowGap !== null) {
const t = Ct(e.theme, "spacing", 8), r = (n) => ({
rowGap: wt(t, n)
});
return _e(e, e.rowGap, r);
}
return null;
};
ar.propTypes = {};
ar.filterProps = ["rowGap"];
const va = ee({
prop: "gridColumn"
}), Sa = ee({
prop: "gridRow"
}), Ca = ee({
prop: "gridAutoFlow"
}), wa = ee({
prop: "gridAutoColumns"
}), xa = ee({
prop: "gridAutoRows"
}), Ra = ee({
prop: "gridTemplateColumns"
}), Ea = ee({
prop: "gridTemplateRows"
}), Ta = ee({
prop: "gridTemplateAreas"
}), Aa = ee({
prop: "gridArea"
});
nr(ir, sr, ar, va, Sa, Ca, wa, xa, Ra, Ea, Ta, Aa);
function tt(e, t) {
return t === "grey" ? t : e;
}
const Oa = ee({
prop: "color",
themeKey: "palette",
transform: tt
}), Pa = ee({
prop: "bgcolor",
cssProperty: "backgroundColor",
themeKey: "palette",
transform: tt
}), ka = ee({
prop: "backgroundColor",
themeKey: "palette",
transform: tt
});
nr(Oa, Pa, ka);
function fe(e) {
return e <= 1 && e !== 0 ? `${e * 100}%` : e;
}
const _a = ee({
prop: "width",
transform: fe
}), hn = (e) => {
if (e.maxWidth !== void 0 && e.maxWidth !== null) {
const t = (r) => {
var o, i, s, a, u;
const n = ((s = (i = (o = e.theme) == null ? void 0 : o.breakpoints) == null ? void 0 : i.values) == null ? void 0 : s[r]) || tr[r];
return n ? ((u = (a = e.theme) == null ? void 0 : a.breakpoints) == null ? void 0 : u.unit) !== "px" ? {
maxWidth: `${n}${e.theme.breakpoints.unit}`
} : {
maxWidth: n
} : {
maxWidth: fe(r)
};
};
return _e(e, e.maxWidth, t);
}
return null;
};
hn.filterProps = ["maxWidth"];
const Ia = ee({
prop: "minWidth",
transform: fe
}), $a = ee({
prop: "height",
transform: fe
}), Na = ee({
prop: "maxHeight",
transform: fe
}), Ba = ee({
prop: "minHeight",
transform: fe
});
ee({
prop: "size",
cssProperty: "width",
transform: fe
});
ee({
prop: "size",
cssProperty: "height",
transform: fe
});
const Ma = ee({
prop: "boxSizing"
});
nr(_a, hn, Ia, $a, Na, Ba, Ma);
const lr = {
// borders
border: {
themeKey: "borders",
transform: me
},
borderTop: {
themeKey: "borders",
transform: me
},
borderRight: {
themeKey: "borders",
transform: me
},
borderBottom: {
themeKey: "borders",
transform: me
},
borderLeft: {
themeKey: "borders",
transform: me
},
borderColor: {
themeKey: "palette"
},
borderTopColor: {
themeKey: "palette"
},
borderRightColor: {
themeKey: "palette"
},
borderBottomColor: {
themeKey: "palette"
},
borderLeftColor: {
themeKey: "palette"
},
outline: {
themeKey: "borders",
transform: me
},
outlineColor: {
themeKey: "palette"
},
borderRadius: {
themeKey: "shape.borderRadius",
style: or
},
// palette
color: {
themeKey: "palette",
transform: tt
},
bgcolor: {
themeKey: "palette",
cssProperty: "backgroundColor",
transform: tt
},
backgroundColor: {
themeKey: "palette",
transform: tt
},
// spacing
p: {
style: Z
},
pt: {
style: Z
},
pr: {
style: Z
},
pb: {
style: Z
},
pl: {
style: Z
},
px: {
style: Z
},
py: {
style: Z
},
padding: {
style: Z
},
paddingTop: {
style: Z
},
paddingRight: {
style: Z
},
paddingBottom: {
style: Z
},
paddingLeft: {
style: Z
},
paddingX: {
style: Z
},
paddingY: {
style: Z
},
paddingInline: {
style: Z
},
paddingInlineStart: {
style: Z
},
paddingInlineEnd: {
style: Z
},
paddingBlock: {
style: Z
},
paddingBlockStart: {
style: Z
},
paddingBlockEnd: {
style: Z
},
m: {
style: Q
},
mt: {
style: Q
},
mr: {
style: Q
},
mb: {
style: Q
},
ml: {
style: Q
},
mx: {
style: Q
},
my: {
style: Q
},
margin: {
style: Q
},
marginTop: {
style: Q
},
marginRight: {
style: Q
},
marginBottom: {
style: Q
},
marginLeft: {
style: Q
},
marginX: {
style: Q
},
marginY: {
style: Q
},
marginInline: {
style: Q
},
marginInlineStart: {
style: Q
},
marginInlineEnd: {
style: Q
},
marginBlock: {
style: Q
},
marginBlockStart: {
style: Q
},
marginBlockEnd: {
style: Q
},
// display
displayPrint: {
cssProperty: !1,
transform: (e) => ({
"@media print": {
display: e
}
})
},
display: {},
overflow: {},
textOverflow: {},
visibility: {},
whiteSpace: {},
// flexbox
flexBasis: {},
flexDirection: {},
flexWrap: {},
justifyContent: {},
alignItems: {},
alignContent: {},
order: {},
flex: {},
flexGrow: {},
flexShrink: {},
alignSelf: {},
justifyItems: {},
justifySelf: {},
// grid
gap: {
style: ir
},
rowGap: {
style: ar
},
columnGap: {
style: sr
},
gridColumn: {},
gridRow: {},
gridAutoFlow: {},
gridAutoColumns: {},
gridAutoRows: {},
gridTemplateColumns: {},
gridTemplateRows: {},
gridTemplateAreas: {},
gridArea: {},
// positions
position: {},
zIndex: {
themeKey: "zIndex"
},
top: {},
right: {},
bottom: {},
left: {},
// shadows
boxShadow: {
themeKey: "shadows"
},
// sizing
width: {
transform: fe
},
maxWidth: {
style: hn
},
minWidth: {
transform: fe
},
height: {
transform: fe
},
maxHeight: {
transform: fe
},
minHeight: {
transform: fe
},
boxSizing: {},
// typography
font: {
themeKey: "font"
},
fontFamily: {
themeKey: "typography"
},
fontSize: {
themeKey: "typography"
},
fontStyle: {
themeKey: "typography"
},
fontWeight: {
themeKey: "typography"
},
letterSpacing: {},
textTransform: {},
lineHeight: {},
textAlign: {},
typography: {
cssProperty: !1,
themeKey: "typography"
}
};
function La(...e) {
const t = e.reduce((n, o) => n.concat(Object.keys(o)), []), r = new Set(t);
return e.every((n) => r.size === Object.keys(n).length);
}
function Da(e, t) {
return typeof e == "function" ? e(t) : e;
}
function Fa() {
function e(r, n, o, i) {
const s = {
[r]: n,
theme: o
}, a = i[r];
if (!a)
return {
[r]: n
};
const {
cssProperty: u = r,
themeKey: c,
transform: f,
style: d
} = a;
if (n == null)
return null;
if (c === "typography" && n === "inherit")
return {
[r]: n
};
const p = rr(o, c) || {};
return d ? d(s) : _e(s, n, (h) => {
let m = Lt(p, f, h);
return h === m && typeof h == "string" && (m = Lt(p, f, `${r}${h === "default" ? "" : q(h)}`, h)), u === !1 ? m : {
[u]: m
};
});
}
function t(r) {
const {
sx: n,
theme: o = {}
} = r || {};
if (!n)
return null;
const i = o.unstable_sxConfig ?? lr;
function s(a) {
let u = a;
if (typeof a == "function")
u = a(o);
else if (typeof a != "object")
return a;
if (!u)
return null;
const c = Zs(o.breakpoints), f = Object.keys(c);
let d = c;
return Object.keys(u).forEach((p) => {
const y = Da(u[p], o);
if (y != null)
if (typeof y == "object")
if (i[p])
d = mt(d, e(p, y, o, i));
else {
const h = _e({
theme: o
}, y, (m) => ({
[p]: m
}));
La(h, y) ? d[p] = t({
sx: y,
theme: o
}) : d = mt(d, h);
}
else
d = mt(d, e(p, y, o, i));
}), Ks(o, ea(f, d));
}
return Array.isArray(n) ? n.map(s) : s(n);
}
return t;
}
const rt = Fa();
rt.filterProps = ["sx"];
function ja(e) {
for (var t = 0, r, n = 0, o = e.length; o >= 4; ++n, o -= 4)
r = e.charCodeAt(n) & 255 | (e.charCodeAt(++n) & 255) << 8 | (e.charCodeAt(++n) & 255) << 16 | (e.charCodeAt(++n) & 255) << 24, r = /* Math.imul(k, m): */
(r & 65535) * 1540483477 + ((r >>> 16) * 59797 << 16), r ^= /* k >>> r: */
r >>> 24, t = /* Math.imul(k, m): */
(r & 65535) * 1540483477 + ((r >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
(t & 65535) * 1540483477 + ((t >>> 16) * 59797 << 16);
switch (o) {
case 3:
t ^= (e.charCodeAt(n + 2) & 255) << 16;
case 2:
t ^= (e.charCodeAt(n + 1) & 255) << 8;
case 1:
t ^= e.charCodeAt(n) & 255, t = /* Math.imul(h, m): */
(t & 65535) * 1540483477 + ((t >>> 16) * 59797 << 16);
}
return t ^= t >>> 13, t = /* Math.imul(h, m): */
(t & 65535) * 1540483477 + ((t >>> 16) * 59797 << 16), ((t ^ t >>> 15) >>> 0).toString(36);
}
var Ua = {
animationIterationCount: 1,
aspectRatio: 1,
borderImageOutset: 1,
borderImageSlice: 1,
borderImageWidth: 1,
boxFlex: 1,
boxFlexGroup: 1,
boxOrdinalGroup: 1,
columnCount: 1,
columns: 1,
flex: 1,
flexGrow: 1,
flexPositive: 1,
flexShrink: 1,
flexNegative: 1,
flexOrder: 1,
gridRow: 1,
gridRowEnd: 1,
gridRowSpan: 1,
gridRowStart: 1,
gridColumn: 1,
gridColumnEnd: 1,
gridColumnSpan: 1,
gridColumnStart: 1,
msGridRow: 1,
msGridRowSpan: 1,
msGridColumn: 1,
msGridColumnSpan: 1,
fontWeight: 1,
lineHeight: 1,
opacity: 1,
order: 1,
orphans: 1,
scale: 1,
tabSize: 1,
widows: 1,
zIndex: 1,
zoom: 1,
WebkitLineClamp: 1,
// SVG-related properties
fillOpacity: 1,
floodOpacity: 1,
stopOpacity: 1,
strokeDasharray: 1,
strokeDashoffset: 1,
strokeMiterlimit: 1,
strokeOpacity: 1,
strokeWidth: 1
};
function za(e) {
var t = /* @__PURE__ */ Object.create(null);
return function(r) {
return t[r] === void 0 && (t[r] = e(r)), t[r];
};
}
var qa = /[A-Z]|^ms/g, Ha = /_EMO_([^_]+?)_([^]*?)_EMO_/g, Xo = function(t) {
return t.charCodeAt(1) === 45;
}, Wn = function(t) {
return t != null && typeof t != "boolean";
}, wr = /* @__PURE__ */ za(function(e) {
return Xo(e) ? e : e.replace(qa, "-$&").toLowerCase();
}), Gn = function(t, r) {
switch (t) {
case "animation":
case "animationName":
if (typeof r == "string")
return r.replace(Ha, function(n, o, i) {
return Me = {
name: o,
styles: i,
next: Me
}, o;
});
}
return Ua[t] !== 1 && !Xo(t) && typeof r == "number" && r !== 0 ? r + "px" : r;
};
function Dt(e, t, r) {
if (r == null)
return "";
var n = r;
if (n.__emotion_styles !== void 0)
return n;
switch (typeof r) {
case "boolean":
return "";
case "object": {
var o = r;
if (o.anim === 1)
return Me = {
name: o.name,
styles: o.styles,
next: Me
}, o.name;
var i = r;
if (i.styles !== void 0) {
var s = i.next;
if (s !== void 0)
for (; s !== void 0; )
Me = {
name: s.name,
styles: s.styles,
next: Me
}, s = s.next;
var a = i.styles + ";";
return a;
}
return Va(e, t, r);
}
}
var u = r;
return u;
}
function Va(e, t, r) {
var n = "";
if (Array.isArray(r))
for (var o = 0; o < r.length; o++)
n += Dt(e, t, r[o]) + ";";
else
for (var i in r) {
var s = r[i];
if (typeof s != "object") {
var a = s;
Wn(a) && (n += wr(i) + ":" + Gn(i, a) + ";");
} else if (Array.isArray(s) && typeof s[0] == "string" && t == null)
for (var u = 0; u < s.length; u++)
Wn(s[u]) && (n += wr(i) + ":" + Gn(i, s[u]) + ";");
else {
var c = Dt(e, t, s);
switch (i) {
case "animation":
case "animationName": {
n += wr(i) + ":" + c + ";";
break;
}
default:
n += i + "{" + c + "}";
}
}
}
return n;
}
var Kn = /label:\s*([^\s;{]+)\s*(;|$)/g, Me;
function Wa(e, t, r) {
if (e.length === 1 && typeof e[0] == "object" && e[0] !== null && e[0].styles !== void 0)
return e[0];
var n = !0, o = "";
Me = void 0;
var i = e[0];
if (i == null || i.raw === void 0)
n = !1, o += Dt(r, t, i);
else {
var s = i;
o += s[0];
}
for (var a = 1; a < e.length; a++)
if (o += Dt(r, t, e[a]), n) {
var u = i;
o += u[a];
}
Kn.lastIndex = 0;
for (var c = "", f; (f = Kn.exec(o)) !== null; )
c += "-" + f[1];
var d = ja(o) + c;
return {
name: d,
styles: o,
next: Me
};
}
/**
* @mui/styled-engine v6.4.6
*
* @license MIT
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
function Ga(e, t) {
return xs(e, t);
}
function Ka(e, t) {
Array.isArray(e.__emotion_styles) && (e.__emotion_styles = t(e.__emotion_styles));
}
const Yn = [];
function Jn(e) {
return Yn[0] = e, Wa(Yn);
}
const Ya = (e) => {
const t = Object.keys(e).map((r) => ({
key: r,
val: e[r]
})) || [];
return t.sort((r, n) => r.val - n.val), t.reduce((r, n) => ({
...r,
[n.key]: n.val
}), {});
};
function Ja(e) {
const {
// The breakpoint **start** at this value.
// For instance with the first breakpoint xs: [xs, sm).
values: t = {
xs: 0,
// phone
sm: 600,
// tablet
md: 900,
// small laptop
lg: 1200,
// desktop
xl: 1536
// large screen
},
unit: r = "px",
step: n = 5,
...o
} = e, i = Ya(t), s = Object.keys(i);
function a(p) {
return `@media (min-width:${typeof t[p] == "number" ? t[p] : p}${r})`;
}
function u(p) {
return `@media (max-width:${(typeof t[p] == "number" ? t[p] : p) - n / 100}${r})`;
}
function c(p, y) {
const h = s.indexOf(y);
return `@media (min-width:${typeof t[p] == "number" ? t[p] : p}${r}) and (max-width:${(h !== -1 && typeof t[s[h]] == "number" ? t[s[h]] : y) - n / 100}${r})`;
}
function f(p) {
return s.indexOf(p) + 1 < s.length ? c(p, s[s.indexOf(p) + 1]) : a(p);
}
function d(p) {
const y = s.indexOf(p);
return y === 0 ? a(s[1]) : y === s.length - 1 ? u(s[y]) : c(p, s[s.indexOf(p) + 1]).replace("@media", "@media not all and");
}
return {
keys: s,
values: i,
up: a,
down: u,
between: c,
only: f,
not: d,
unit: r,
...o
};
}
const Xa = {
borderRadius: 4
};
function Qo(e = 8, t = pn({
spacing: e
})) {
if (e.mui)
return e;
const r = (...n) => (n.length === 0 ? [1] : n).map((i) => {
const s = t(i);
return typeof s == "number" ? `${s}px` : s;
}).join(" ");
return r.mui = !0, r;
}
function Qa(e, t) {
var n;
const r = this;
if (r.vars) {
if (!((n = r.colorSchemes) != null && n[e]) || typeof r.getColorSchemeSelector != "function")
return {};
let o = r.getColorSchemeSelector(e);
return o === "&" ? t : ((o.includes("data-") || o.includes(".")) && (o = `*:where(${o.replace(/\s*&$/, "")}) &`), {
[o]: t
});
}
return r.palette.mode === e ? t : {};
}
function mn(e = {}, ...t) {
const {
breakpoints: r = {},
palette: n = {},
spacing: o,
shape: i = {},
...s
} = e, a = Ja(r), u = Qo(o);
let c = de({
breakpoints: a,
direction: "ltr",
components: {},
// Inject component definitions.
palette: {
mode: "light",
...n
},
spacing: u,
shape: {
...Xa,
...i
}
}, s);
return c = Xs(c), c.applyStyles = Qa, c = t.reduce((f, d) => de(f, d), c), c.unstable_sxConfig = {
...lr,
...s == null ? void 0 : s.unstable_sxConfig
}, c.unstable_sx = function(d) {
return rt({
sx: d,
theme: this
});
}, c;
}
function Za(e) {
return Object.keys(e).length === 0;
}
function el(e = null) {
const t = M.useContext(Rs);
return !t || Za(t) ? e : t;
}
const tl = mn();
function rl(e = tl) {
return el(e);
}
function Zo(e) {
const {
variants: t,
...r
} = e, n = {
variants: t,
style: Jn(r),
isProcessed: !0
};
return n.style === r || t && t.forEach((o) => {
typeof o.style != "function" && (o.style = Jn(o.style));
}), n;
}
const nl = mn();
function xr(e) {
return e !== "ownerState" && e !== "theme" && e !== "sx" && e !== "as";
}
function ol(e) {
return e ? (t, r) => r[e] : null;
}
function il(e, t, r) {
e.theme = ll(e.theme) ? r : e.theme[t] || e.theme;
}
function It(e, t) {
const r = typeof t == "function" ? t(e) : t;
if (Array.isArray(r))
return r.flatMap((n) => It(e, n));
if (Array.isArray(r == null ? void 0 : r.variants)) {
let n;
if (r.isProcessed)
n = r.style;
else {
const {
variants: o,
...i
} = r;
n = i;
}
return ei(e, r.variants, [n]);
}
return r != null && r.isProcessed ? r.style : r;
}
function ei(e, t, r = []) {
var o;
let n;
e: for (let i = 0; i < t.length; i += 1) {
const s = t[i];
if (typeof s.props == "function") {
if (n ?? (n = {
...e,
...e.ownerState,
ownerState: e.ownerState
}), !s.props(n))
continue;
} else
for (const a in s.props)
if (e[a] !== s.props[a] && ((o = e.ownerState) == null ? void 0 : o[a]) !== s.props[a])
continue e;
typeof s.style == "function" ? (n ?? (n = {
...e,
...e.ownerState,
ownerState: e.ownerState
}), r.push(s.style(n))) : r.push(s.style);
}
return r;
}
function sl(e = {}) {
const {
themeId: t,
defaultTheme: r = nl,
rootShouldForwardProp: n = xr,
slotShouldForwardProp: o = xr
} = e;
function i(a) {
il(a, t, r);
}
return (a, u = {}) => {
Ka(a, (k) => k.filter((P) => P !== rt));
const {
name: c,
slot: f,
skipVariantsResolver: d,
skipSx: p,
// TODO v6: remove `lowercaseFirstLetter()` in the next major release
// For more details: https://github.com/mui/material-ui/pull/37908
overridesResolver: y = ol(ul(f)),
...h
} = u, m = d !== void 0 ? d : (
// TODO v6: remove `Root` in the next major release
// For more details: https://github.com/mui/material-ui/pull/37908
f && f !== "Root" && f !== "root" || !1
), v = p || !1;
let A = xr;
f === "Root" || f === "root" ? A = n : f ? A = o : cl(a) && (A = void 0);
const _ = Ga(a, {
shouldForwardProp: A,
label: al(),
...h
}), R = (k) => {
if (typeof k == "function" && k.__emotion_real !== k)
return function(F) {
return It(F, k);
};
if (ke(k)) {
const P = Zo(k);
return P.variants ? function(B) {
return It(B, P);
} : P.style;
}
return k;
}, S = (...k) => {
const P = [], F = k.map(R), B = [];
if (P.push(i), c && y && B.push(function(N) {
var J, se;
const z = (se = (J = N.theme.components) == null ? void 0 : J[c]) == null ? void 0 : se.styleOverrides;
if (!z)
return null;
const K = {};
for (const ae in z)
K[ae] = It(N, z[ae]);
return y(N, K);
}), c && !m && B.push(function(N) {
var K, J;
const L = N.theme, z = (J = (K = L == null ? void 0 : L.components) == null ? void 0 : K[c]) == null ? void 0 : J.variants;
return z ? ei(N, z) : null;
}), v || B.push(rt), Array.isArray(F[0])) {
const O = F.shift(), N = new Array(P.length).fill(""), L = new Array(B.length).fill("");
let z;
z = [...N, ...O, ...L], z.raw = [...N, ...O.raw, ...L], P.unshift(z);
}
const U = [...P, ...F, ...B], l = _(...U);
return a.muiName && (l.muiName = a.muiName), l;
};
return _.withConfig && (S.withConfig = _.withConfig), S;
};
}
function al(e, t) {
return void 0;
}
function ll(e) {
for (const t in e)
return !1;
return !0;
}
function cl(e) {
return typeof e == "string" && // 96 is one less than the char code
// for "a" so this is checking that
// it's a lowercase character
e.charCodeAt(0) > 96;
}
function ul(e) {
return e && e.charAt(0).toLowerCase() + e.slice(1);
}
function gn(e, t = 0, r = 1) {
return zs(e, t, r);
}
function fl(e) {
e = e.slice(1);
const t = new RegExp(`.{1,${e.length >= 6 ? 2 : 1}}`, "g");
let r = e.match(t);
return r && r[0].length === 1 && (r = r.map((n) => n + n)), r ? `rgb${r.length === 4 ? "a" : ""}(${r.map((n, o) => o < 3 ? parseInt(n, 16) : Math.round(parseInt(n, 16) / 255 * 1e3) / 1e3).join(", ")})` : "";
}
function Le(e) {
if (e.type)
return e;
if (e.charAt(0) === "#")
return Le(fl(e));
const t = e.indexOf("("), r = e.substring(0, t);
if (!["rgb", "rgba", "hsl", "hsla", "color"].includes(r))
throw new Error(He(9, e));
let n = e.substring(t + 1, e.length - 1), o;
if (r === "color") {
if (n = n.split(" "), o = n.shift(), n.length === 4 && n[3].charAt(0) === "/" && (n[3] = n[3].slice(1)), !["srgb", "display-p3", "a98-rgb", "prophoto-rgb", "rec-2020"].includes(o))
throw new Error(He(10, o));
} else
n = n.split(",");
return n = n.map((i) => parseFloat(i)), {
type: r,
values: n,
colorSpace: o
};
}
const dl = (e) => {
const t = Le(e);
return t.values.slice(0, 3).map((r, n) => t.type.includes("hsl") && n !== 0 ? `${r}%` : r).join(" ");
}, dt = (e, t) => {
try {
return dl(e);
} catch {
return e;
}
};
function cr(e) {
const {
type: t,
colorSpace: r
} = e;
let {
values: n
} = e;
return t.includes("rgb") ? n = n.map((o, i) => i < 3 ? parseInt(o, 10) : o) : t.includes("hsl") && (n[1] = `${n[1]}%`, n[2] = `${n[2]}%`), t.includes("color") ? n = `${r} ${n.join(" ")}` : n = `${n.join(", ")}`, `${t}(${n})`;
}
function ti(e) {
e = Le(e);
const {
values: t
} = e, r = t[0], n = t[1] / 100, o = t[2] / 100, i = n * Math.min(o, 1 - o), s = (c, f = (c + r / 30) % 12) => o - i * Math.max(Math.min(f - 3, 9 - f, 1), -1);
let a = "rgb";
const u = [Math.round(s(0) * 255), Math.round(s(8) * 255), Math.round(s(4) * 255)];
return e.type === "hsla" && (a += "a", u.push(t[3])), cr({
type: a,
values: u
});
}
function jr(e) {
e = Le(e);
let t = e.type === "hsl" || e.type === "hsla" ? Le(ti(e)).values : e.values;
return t = t.map((r) => (e.type !== "color" && (r /= 255), r <= 0.03928 ? r / 12.92 : ((r + 0.055) / 1.055) ** 2.4)), Number((0.2126 * t[0] + 0.7152 * t[1] + 0.0722 * t[2]).toFixed(3));
}
function pl(e, t) {
const r = jr(e), n = jr(t);
return (Math.max(r, n) + 0.05) / (Math.min(r, n) + 0.05);
}
function gt(e, t) {
return e = Le(e), t = gn(t), (e.type === "rgb" || e.type === "hsl") && (e.type += "a"), e.type === "color" ? e.values[3] = `/${t}` : e.values[3] = t, cr(e);
}
function Tt(e, t, r) {
try {
return gt(e, t);
} catch {
return e;
}
}
function nt(e, t) {
if (e = Le(e), t = gn(t), e.type.includes("hsl"))
e.values[2] *= 1 - t;
else if (e.type.includes("rgb") || e.type.includes("color"))
for (let r = 0; r < 3; r += 1)
e.values[r] *= 1 - t;
return cr(e);
}
function V(e, t, r) {
try {
return nt(e, t);
} catch {
return e;
}
}
function ot(e, t) {
if (e = Le(e), t = gn(t), e.type.includes("hsl"))
e.values[2] += (100 - e.values[2]) * t;
else if (e.type.includes("rgb"))
for (let r = 0; r < 3; r += 1)
e.values[r] += (255 - e.values[r]) * t;
else if (e.type.includes("color"))
for (let r = 0; r < 3; r += 1)
e.values[r] += (1 - e.values[r]) * t;
return cr(e);
}
function W(e, t, r) {
try {
return ot(e, t);
} catch {
return e;
}
}
function hl(e, t = 0.15) {
return jr(e) > 0.5 ? nt(e, t) : ot(e, t);
}
function At(e, t, r) {
try {
return hl(e, t);
} catch {
return e;
}
}
const ml = /* @__PURE__ */ M.createContext(), gl = () => M.useContext(ml) ?? !1, yl = /* @__PURE__ */ M.createContext(void 0);
function bl(e) {
const {
theme: t,
name: r,
props: n
} = e;
if (!t || !t.components || !t.components[r])
return n;
const o = t.components[r];
return o.defaultProps ? Fr(o.defaultProps, n) : !o.styleOverrides && !o.variants ? Fr(o, n) : n;
}
function vl({
props: e,
name: t
}) {
const r = M.useContext(yl);
return bl({
props: e,
name: t,
theme: {
components: r
}
});
}
const Xn = {
theme: void 0
};
function Sl(e) {
let t, r;
return function(o) {
let i = t;
return (i === void 0 || o.theme !== r) && (Xn.theme = o.theme, i = Zo(e(Xn)), t = i, r = o.theme), i;
};
}
function Cl(e = "") {
function t(...n) {
if (!n.length)
return "";
const o = n[0];
return typeof o == "string" && !o.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/) ? `, var(--${e ? `${e}-` : ""}${o}${t(...n.slice(1))})` : `, ${o}`;
}
return (n, ...o) => `var(--${e ? `${e}-` : ""}${n}${t(...o)})`;
}
const Qn = (e, t, r, n = []) => {
let o = e;
t.forEach((i, s) => {
s === t.length - 1 ? Array.isArray(o) ? o[Number(i)] = r : o && typeof o == "object" && (o[i] = r) : o && typeof o == "object" && (o[i] || (o[i] = n.includes(i) ? [] : {}), o = o[i]);
});
}, wl = (e, t, r) => {
function n(o, i = [], s = []) {
Object.entries(o).forEach(([a, u]) => {
(!r || r && !r([...i, a])) && u != null && (typeof u == "object" && Object.keys(u).length > 0 ? n(u, [...i, a], Array.isArray(u) ? [...s, a] : s) : t([...i, a], u, s));
});
}
n(e);
}, xl = (e, t) => typeof t == "number" ? ["lineHeight", "fontWeight", "opacity", "zIndex"].some((n) => e.includes(n)) || e[e.length - 1].toLowerCase().includes("opacity") ? t : `${t}px` : t;
function Rr(e, t) {
const {
prefix: r,
shouldSkipGeneratingVar: n
} = t || {}, o = {}, i = {}, s = {};
return wl(
e,
(a, u, c) => {
if ((typeof u == "string" || typeof u == "number") && (!n || !n(a, u))) {
const f = `--${r ? `${r}-` : ""}${a.join("-")}`, d = xl(a, u);
Object.assign(o, {
[f]: d
}), Qn(i, a, `var(${f})`, c), Qn(s, a, `var(${f}, ${d})`, c);
}
},
(a) => a[0] === "vars"
// skip 'vars/*' paths
), {
css: o,
vars: i,
varsWithDefaults: s
};
}
function Rl(e, t = {}) {
const {
getSelector: r = v,
disableCssColorScheme: n,
colorSchemeSelector: o
} = t, {
colorSchemes: i = {},
components: s,
defaultColorScheme: a = "light",
...u
} = e, {
vars: c,
css: f,
varsWithDefaults: d
} = Rr(u, t);
let p = d;
const y = {}, {
[a]: h,
...m
} = i;
if (Object.entries(m || {}).forEach(([R, S]) => {
const {
vars: k,
css: P,
varsWithDefaults: F
} = Rr(S, t);
p = de(p, F), y[R] = {
css: P,
vars: k
};
}), h) {
const {
css: R,
vars: S,
varsWithDefaults: k
} = Rr(h, t);
p = de(p, k), y[a] = {
css: R,
vars: S
};
}
function v(R, S) {
var P, F;
let k = o;
if (o === "class" && (k = ".%s"), o === "data" && (k = "[data-%s]"), o != null && o.startsWith("data-") && !o.includes("%s") && (k = `[${o}="%s"]`), R) {
if (k === "media")
return e.defaultColorScheme === R ? ":root" : {
[`@media (prefers-color-scheme: ${((F = (P = i[R]) == null ? void 0 : P.palette) == null ? void 0 : F.mode) || R})`]: {
":root": S
}
};
if (k)
return e.defaultColorScheme === R ? `:root, ${k.replace("%s", String(R))}` : k.replace("%s", String(R));
}
return ":root";
}
return {
vars: p,
generateThemeVars: () => {
let R = {
...c
};
return Object.entries(y).forEach(([, {
vars: S
}]) => {
R = de(R, S);
}), R;
},
generateStyleSheets: () => {
var B, U;
const R = [], S = e.defaultColorScheme || "light";
function k(l, O) {
Object.keys(O).length && R.push(typeof l == "string" ? {
[l]: {
...O
}
} : l);
}
k(r(void 0, {
...f
}), f);
const {
[S]: P,
...F
} = y;
if (P) {
const {
css: l
} = P, O = (U = (B = i[S]) == null ? void 0 : B.palette) == null ? void 0 : U.mode, N = !n && O ? {
colorScheme: O,
...l
} : {
...l
};
k(r(S, {
...N
}), N);
}
return Object.entries(F).forEach(([l, {
css: O
}]) => {
var z, K;
const N = (K = (z = i[l]) == null ? void 0 : z.palette) == null ? void 0 : K.mode, L = !n && N ? {
colorScheme: N,
...O
} : {
...O
};
k(r(l, {
...L
}), L);
}), R;
}
};
}
function El(e) {
return function(r) {
return e === "media" ? `@media (prefers-color-scheme: ${r})` : e ? e.startsWith("data-") && !e.includes("%s") ? `[${e}="${r}"] &` : e === "class" ? `.${r} &` : e === "data" ? `[data-${r}] &` : `${e.replace("%s", r)} &` : "&";
};
}
const yt = {
black: "#000",
white: "#fff"
}, Tl = {
50: "#fafafa",
100: "#f5f5f5",
200: "#eeeeee",
300: "#e0e0e0",
400: "#bdbdbd",
500: "#9e9e9e",
600: "#757575",
700: "#616161",
800: "#424242",
900: "#212121",
A100: "#f5f5f5",
A200: "#eeeeee",
A400: "#bdbdbd",
A700: "#616161"
}, Ke = {
50: "#f3e5f5",
200: "#ce93d8",
300: "#ba68c8",
400: "#ab47bc",
500: "#9c27b0",
700: "#7b1fa2"
}, Ye = {
300: "#e57373",
400: "#ef5350",
500: "#f44336",
700: "#d32f2f",
800: "#c62828"
}, ut = {
300: "#ffb74d",
400: "#ffa726",
500: "#ff9800",
700: "#f57c00",
900: "#e65100"
}, Je = {
50: "#e3f2fd",
200: "#90caf9",
400: "#42a5f5",
700: "#1976d2",
800: "#1565c0"
}, Xe = {
300: "#4fc3f7",
400: "#29b6f6",
500: "#03a9f4",
700: "#0288d1",
900: "#01579b"
}, Qe = {
300: "#81c784",
400: "#66bb6a",
500: "#4caf50",
700: "#388e3c",
800: "#2e7d32",
900: "#1b5e20"
};
function ri() {
return {
// The colors used to style the text.
text: {
// The most important text.
primary: "rgba(0, 0, 0, 0.87)",
// Secondary text.
secondary: "rgba(0, 0, 0, 0.6)",
// Disabled text have even lower visual prominence.
disabled: "rgba(0, 0, 0, 0.38)"
},
// The color used to divide different elements.
divider: "rgba(0, 0, 0, 0.12)",
// The background colors used to style the surfaces.