var l$ = Object.defineProperty;
var c$ = (e, t, r) => t in e ? l$(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
var Za = (e, t, r) => c$(e, typeof t != "symbol" ? t + "" : t, r);
import { jsx as P, jsxs as ue, Fragment as Wt } from "react/jsx-runtime";
import * as M from "react";
import pn, { createElement as u$, Component as Ji, useState as Or, useCallback as Pt, useEffect as Ml, useReducer as d$, useMemo as f$, createRef as p$, forwardRef as cy, useContext as h$, Children as m$, isValidElement as Ks, cloneElement as Gs, useRef as uy } from "react";
import * as g$ from "react-dom";
import Cs from "react-dom";
function St(e) {
  return typeof e != "object" || e === null || typeof e.lastModified == "number" && typeof File < "u" && e instanceof File || typeof e.getMonth == "function" && typeof Date < "u" && e instanceof Date ? !1 : !Array.isArray(e);
}
function y$(e) {
  return e.additionalItems === !0 && console.warn("additionalItems=true is currently not supported"), St(e.additionalItems);
}
function Kp(e) {
  if (e === "")
    return;
  if (e === null)
    return null;
  if (/\.$/.test(e) || /\.0$/.test(e) || /\.\d*0$/.test(e))
    return e;
  const t = Number(e);
  return typeof t == "number" && !Number.isNaN(t) ? t : e;
}
const ka = "__additional_property", Su = "additionalProperties", Yi = "allOf", hn = "anyOf", ha = "const", b$ = "default", Nl = "dependencies", v$ = "enum", kr = "__errors", Zn = "$id", $$ = "if", eo = "items", S$ = "_$junk_option_schema_id$_", Hs = "$name", zr = "oneOf", Mt = "properties", w$ = "required", cl = "submitButtonOptions", Ht = "$ref", gd = "__rjsf_additionalProperties", dy = "__rjsf_rootSchema", C$ = "ui:field", yd = "ui:widget", Si = "ui:options", E$ = "ui:globalOptions";
function Qe(e = {}, t = {}) {
  return Object.keys(e).filter((r) => r.indexOf("ui:") === 0).reduce((r, n) => {
    const o = e[n];
    return n === yd && St(o) ? (console.error("Setting options via ui:widget object is no longer supported, use ui:options instead"), r) : n === Si && St(o) ? { ...r, ...o } : { ...r, [n.substring(3)]: o };
  }, { ...t });
}
function fy(e, t = {}, r) {
  if (!e.additionalProperties)
    return !1;
  const { expandable: n = !0 } = Qe(t);
  return n === !1 ? n : e.maxProperties !== void 0 && r ? Object.keys(r).length < e.maxProperties : !0;
}
var hi = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
function pt(e) {
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
}
var _$ = typeof hi == "object" && hi && hi.Object === Object && hi, py = _$, x$ = py, P$ = typeof self == "object" && self && self.Object === Object && self, k$ = x$ || P$ || Function("return this")(), $n = k$, O$ = $n, A$ = O$.Symbol, Oa = A$, Gp = Oa, hy = Object.prototype, I$ = hy.hasOwnProperty, R$ = hy.toString, Qa = Gp ? Gp.toStringTag : void 0;
function T$(e) {
  var t = I$.call(e, Qa), r = e[Qa];
  try {
    e[Qa] = void 0;
    var n = !0;
  } catch {
  }
  var o = R$.call(e);
  return n && (t ? e[Qa] = r : delete e[Qa]), o;
}
var M$ = T$, N$ = Object.prototype, F$ = N$.toString;
function j$(e) {
  return F$.call(e);
}
var D$ = j$, Hp = Oa, L$ = M$, B$ = D$, z$ = "[object Null]", U$ = "[object Undefined]", Jp = Hp ? Hp.toStringTag : void 0;
function V$(e) {
  return e == null ? e === void 0 ? U$ : z$ : Jp && Jp in Object(e) ? L$(e) : B$(e);
}
var Un = V$;
function q$(e, t) {
  return function(r) {
    return e(t(r));
  };
}
var my = q$, W$ = my, K$ = W$(Object.getPrototypeOf, Object), Fl = K$;
function G$(e) {
  return e != null && typeof e == "object";
}
var Kr = G$, H$ = Un, J$ = Fl, Y$ = Kr, X$ = "[object Object]", Z$ = Function.prototype, Q$ = Object.prototype, gy = Z$.toString, e2 = Q$.hasOwnProperty, t2 = gy.call(Object);
function r2(e) {
  if (!Y$(e) || H$(e) != X$)
    return !1;
  var t = J$(e);
  if (t === null)
    return !0;
  var r = e2.call(t, "constructor") && t.constructor;
  return typeof r == "function" && r instanceof r && gy.call(r) == t2;
}
var Aa = r2;
const bd = /* @__PURE__ */ pt(Aa);
function wu(e) {
  const t = {
    // We store the list of errors for this node in a property named __errors
    // to avoid name collision with a possible sub schema field named
    // 'errors' (see `utils.toErrorSchema`).
    [kr]: [],
    addError(r) {
      this[kr].push(r);
    }
  };
  if (Array.isArray(e))
    return e.reduce((r, n, o) => ({ ...r, [o]: wu(n) }), t);
  if (bd(e)) {
    const r = e;
    return Object.keys(r).reduce((n, o) => ({ ...n, [o]: wu(r[o]) }), t);
  }
  return t;
}
function n2() {
  this.__data__ = [], this.size = 0;
}
var o2 = n2;
function a2(e, t) {
  return e === t || e !== e && t !== t;
}
var Ia = a2, i2 = Ia;
function s2(e, t) {
  for (var r = e.length; r--; )
    if (i2(e[r][0], t))
      return r;
  return -1;
}
var jl = s2, l2 = jl, c2 = Array.prototype, u2 = c2.splice;
function d2(e) {
  var t = this.__data__, r = l2(t, e);
  if (r < 0)
    return !1;
  var n = t.length - 1;
  return r == n ? t.pop() : u2.call(t, r, 1), --this.size, !0;
}
var f2 = d2, p2 = jl;
function h2(e) {
  var t = this.__data__, r = p2(t, e);
  return r < 0 ? void 0 : t[r][1];
}
var m2 = h2, g2 = jl;
function y2(e) {
  return g2(this.__data__, e) > -1;
}
var b2 = y2, v2 = jl;
function $2(e, t) {
  var r = this.__data__, n = v2(r, e);
  return n < 0 ? (++this.size, r.push([e, t])) : r[n][1] = t, this;
}
var S2 = $2, w2 = o2, C2 = f2, E2 = m2, _2 = b2, x2 = S2;
function Ra(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var n = e[t];
    this.set(n[0], n[1]);
  }
}
Ra.prototype.clear = w2;
Ra.prototype.delete = C2;
Ra.prototype.get = E2;
Ra.prototype.has = _2;
Ra.prototype.set = x2;
var Dl = Ra, P2 = Dl;
function k2() {
  this.__data__ = new P2(), this.size = 0;
}
var O2 = k2;
function A2(e) {
  var t = this.__data__, r = t.delete(e);
  return this.size = t.size, r;
}
var I2 = A2;
function R2(e) {
  return this.__data__.get(e);
}
var T2 = R2;
function M2(e) {
  return this.__data__.has(e);
}
var N2 = M2;
function F2(e) {
  var t = typeof e;
  return e != null && (t == "object" || t == "function");
}
var Er = F2;
const Ur = /* @__PURE__ */ pt(Er);
var j2 = Un, D2 = Er, L2 = "[object AsyncFunction]", B2 = "[object Function]", z2 = "[object GeneratorFunction]", U2 = "[object Proxy]";
function V2(e) {
  if (!D2(e))
    return !1;
  var t = j2(e);
  return t == B2 || t == z2 || t == L2 || t == U2;
}
var Ll = V2, q2 = $n, W2 = q2["__core-js_shared__"], K2 = W2, Uc = K2, Yp = function() {
  var e = /[^.]+$/.exec(Uc && Uc.keys && Uc.keys.IE_PROTO || "");
  return e ? "Symbol(src)_1." + e : "";
}();
function G2(e) {
  return !!Yp && Yp in e;
}
var H2 = G2, J2 = Function.prototype, Y2 = J2.toString;
function X2(e) {
  if (e != null) {
    try {
      return Y2.call(e);
    } catch {
    }
    try {
      return e + "";
    } catch {
    }
  }
  return "";
}
var yy = X2, Z2 = Ll, Q2 = H2, eS = Er, tS = yy, rS = /[\\^$.*+?()[\]{}|]/g, nS = /^\[object .+?Constructor\]$/, oS = Function.prototype, aS = Object.prototype, iS = oS.toString, sS = aS.hasOwnProperty, lS = RegExp(
  "^" + iS.call(sS).replace(rS, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
);
function cS(e) {
  if (!eS(e) || Q2(e))
    return !1;
  var t = Z2(e) ? lS : nS;
  return t.test(tS(e));
}
var uS = cS;
function dS(e, t) {
  return e == null ? void 0 : e[t];
}
var fS = dS, pS = uS, hS = fS;
function mS(e, t) {
  var r = hS(e, t);
  return pS(r) ? r : void 0;
}
var No = mS, gS = No, yS = $n, bS = gS(yS, "Map"), vd = bS, vS = No, $S = vS(Object, "create"), Bl = $S, Xp = Bl;
function SS() {
  this.__data__ = Xp ? Xp(null) : {}, this.size = 0;
}
var wS = SS;
function CS(e) {
  var t = this.has(e) && delete this.__data__[e];
  return this.size -= t ? 1 : 0, t;
}
var ES = CS, _S = Bl, xS = "__lodash_hash_undefined__", PS = Object.prototype, kS = PS.hasOwnProperty;
function OS(e) {
  var t = this.__data__;
  if (_S) {
    var r = t[e];
    return r === xS ? void 0 : r;
  }
  return kS.call(t, e) ? t[e] : void 0;
}
var AS = OS, IS = Bl, RS = Object.prototype, TS = RS.hasOwnProperty;
function MS(e) {
  var t = this.__data__;
  return IS ? t[e] !== void 0 : TS.call(t, e);
}
var NS = MS, FS = Bl, jS = "__lodash_hash_undefined__";
function DS(e, t) {
  var r = this.__data__;
  return this.size += this.has(e) ? 0 : 1, r[e] = FS && t === void 0 ? jS : t, this;
}
var LS = DS, BS = wS, zS = ES, US = AS, VS = NS, qS = LS;
function Ta(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var n = e[t];
    this.set(n[0], n[1]);
  }
}
Ta.prototype.clear = BS;
Ta.prototype.delete = zS;
Ta.prototype.get = US;
Ta.prototype.has = VS;
Ta.prototype.set = qS;
var WS = Ta, Zp = WS, KS = Dl, GS = vd;
function HS() {
  this.size = 0, this.__data__ = {
    hash: new Zp(),
    map: new (GS || KS)(),
    string: new Zp()
  };
}
var JS = HS;
function YS(e) {
  var t = typeof e;
  return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
}
var XS = YS, ZS = XS;
function QS(e, t) {
  var r = e.__data__;
  return ZS(t) ? r[typeof t == "string" ? "string" : "hash"] : r.map;
}
var zl = QS, ew = zl;
function tw(e) {
  var t = ew(this, e).delete(e);
  return this.size -= t ? 1 : 0, t;
}
var rw = tw, nw = zl;
function ow(e) {
  return nw(this, e).get(e);
}
var aw = ow, iw = zl;
function sw(e) {
  return iw(this, e).has(e);
}
var lw = sw, cw = zl;
function uw(e, t) {
  var r = cw(this, e), n = r.size;
  return r.set(e, t), this.size += r.size == n ? 0 : 1, this;
}
var dw = uw, fw = JS, pw = rw, hw = aw, mw = lw, gw = dw;
function Ma(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.clear(); ++t < r; ) {
    var n = e[t];
    this.set(n[0], n[1]);
  }
}
Ma.prototype.clear = fw;
Ma.prototype.delete = pw;
Ma.prototype.get = hw;
Ma.prototype.has = mw;
Ma.prototype.set = gw;
var $d = Ma, yw = Dl, bw = vd, vw = $d, $w = 200;
function Sw(e, t) {
  var r = this.__data__;
  if (r instanceof yw) {
    var n = r.__data__;
    if (!bw || n.length < $w - 1)
      return n.push([e, t]), this.size = ++r.size, this;
    r = this.__data__ = new vw(n);
  }
  return r.set(e, t), this.size = r.size, this;
}
var ww = Sw, Cw = Dl, Ew = O2, _w = I2, xw = T2, Pw = N2, kw = ww;
function Na(e) {
  var t = this.__data__ = new Cw(e);
  this.size = t.size;
}
Na.prototype.clear = Ew;
Na.prototype.delete = _w;
Na.prototype.get = xw;
Na.prototype.has = Pw;
Na.prototype.set = kw;
var Ul = Na, Ow = "__lodash_hash_undefined__";
function Aw(e) {
  return this.__data__.set(e, Ow), this;
}
var Iw = Aw;
function Rw(e) {
  return this.__data__.has(e);
}
var Tw = Rw, Mw = $d, Nw = Iw, Fw = Tw;
function ul(e) {
  var t = -1, r = e == null ? 0 : e.length;
  for (this.__data__ = new Mw(); ++t < r; )
    this.add(e[t]);
}
ul.prototype.add = ul.prototype.push = Nw;
ul.prototype.has = Fw;
var Vl = ul;
function jw(e, t) {
  for (var r = -1, n = e == null ? 0 : e.length; ++r < n; )
    if (t(e[r], r, e))
      return !0;
  return !1;
}
var Dw = jw;
function Lw(e, t) {
  return e.has(t);
}
var ql = Lw, Bw = Vl, zw = Dw, Uw = ql, Vw = 1, qw = 2;
function Ww(e, t, r, n, o, a) {
  var i = r & Vw, s = e.length, l = t.length;
  if (s != l && !(i && l > s))
    return !1;
  var c = a.get(e), u = a.get(t);
  if (c && u)
    return c == t && u == e;
  var f = -1, d = !0, p = r & qw ? new Bw() : void 0;
  for (a.set(e, t), a.set(t, e); ++f < s; ) {
    var h = e[f], $ = t[f];
    if (n)
      var b = i ? n($, h, f, t, e, a) : n(h, $, f, e, t, a);
    if (b !== void 0) {
      if (b)
        continue;
      d = !1;
      break;
    }
    if (p) {
      if (!zw(t, function(g, y) {
        if (!Uw(p, y) && (h === g || o(h, g, r, n, a)))
          return p.push(y);
      })) {
        d = !1;
        break;
      }
    } else if (!(h === $ || o(h, $, r, n, a))) {
      d = !1;
      break;
    }
  }
  return a.delete(e), a.delete(t), d;
}
var by = Ww, Kw = $n, Gw = Kw.Uint8Array, vy = Gw;
function Hw(e) {
  var t = -1, r = Array(e.size);
  return e.forEach(function(n, o) {
    r[++t] = [o, n];
  }), r;
}
var Jw = Hw;
function Yw(e) {
  var t = -1, r = Array(e.size);
  return e.forEach(function(n) {
    r[++t] = n;
  }), r;
}
var Sd = Yw, Qp = Oa, eh = vy, Xw = Ia, Zw = by, Qw = Jw, eC = Sd, tC = 1, rC = 2, nC = "[object Boolean]", oC = "[object Date]", aC = "[object Error]", iC = "[object Map]", sC = "[object Number]", lC = "[object RegExp]", cC = "[object Set]", uC = "[object String]", dC = "[object Symbol]", fC = "[object ArrayBuffer]", pC = "[object DataView]", th = Qp ? Qp.prototype : void 0, Vc = th ? th.valueOf : void 0;
function hC(e, t, r, n, o, a, i) {
  switch (r) {
    case pC:
      if (e.byteLength != t.byteLength || e.byteOffset != t.byteOffset)
        return !1;
      e = e.buffer, t = t.buffer;
    case fC:
      return !(e.byteLength != t.byteLength || !a(new eh(e), new eh(t)));
    case nC:
    case oC:
    case sC:
      return Xw(+e, +t);
    case aC:
      return e.name == t.name && e.message == t.message;
    case lC:
    case uC:
      return e == t + "";
    case iC:
      var s = Qw;
    case cC:
      var l = n & tC;
      if (s || (s = eC), e.size != t.size && !l)
        return !1;
      var c = i.get(e);
      if (c)
        return c == t;
      n |= rC, i.set(e, t);
      var u = Zw(s(e), s(t), n, o, a, i);
      return i.delete(e), u;
    case dC:
      if (Vc)
        return Vc.call(e) == Vc.call(t);
  }
  return !1;
}
var mC = hC;
function gC(e, t) {
  for (var r = -1, n = t.length, o = e.length; ++r < n; )
    e[o + r] = t[r];
  return e;
}
var wd = gC, yC = Array.isArray, Xt = yC, bC = wd, vC = Xt;
function $C(e, t, r) {
  var n = t(e);
  return vC(e) ? n : bC(n, r(e));
}
var $y = $C;
function SC(e, t) {
  for (var r = -1, n = e == null ? 0 : e.length, o = 0, a = []; ++r < n; ) {
    var i = e[r];
    t(i, r, e) && (a[o++] = i);
  }
  return a;
}
var wC = SC;
function CC() {
  return [];
}
var Sy = CC, EC = wC, _C = Sy, xC = Object.prototype, PC = xC.propertyIsEnumerable, rh = Object.getOwnPropertySymbols, kC = rh ? function(e) {
  return e == null ? [] : (e = Object(e), EC(rh(e), function(t) {
    return PC.call(e, t);
  }));
} : _C, Cd = kC;
function OC(e, t) {
  for (var r = -1, n = Array(e); ++r < e; )
    n[r] = t(r);
  return n;
}
var wy = OC, AC = Un, IC = Kr, RC = "[object Arguments]";
function TC(e) {
  return IC(e) && AC(e) == RC;
}
var MC = TC, nh = MC, NC = Kr, Cy = Object.prototype, FC = Cy.hasOwnProperty, jC = Cy.propertyIsEnumerable, DC = nh(/* @__PURE__ */ function() {
  return arguments;
}()) ? nh : function(e) {
  return NC(e) && FC.call(e, "callee") && !jC.call(e, "callee");
}, Xi = DC, dl = { exports: {} };
function LC() {
  return !1;
}
var BC = LC;
dl.exports;
(function(e, t) {
  var r = $n, n = BC, o = t && !t.nodeType && t, a = o && !0 && e && !e.nodeType && e, i = a && a.exports === o, s = i ? r.Buffer : void 0, l = s ? s.isBuffer : void 0, c = l || n;
  e.exports = c;
})(dl, dl.exports);
var Fa = dl.exports, zC = 9007199254740991, UC = /^(?:0|[1-9]\d*)$/;
function VC(e, t) {
  var r = typeof e;
  return t = t ?? zC, !!t && (r == "number" || r != "symbol" && UC.test(e)) && e > -1 && e % 1 == 0 && e < t;
}
var Wl = VC, qC = 9007199254740991;
function WC(e) {
  return typeof e == "number" && e > -1 && e % 1 == 0 && e <= qC;
}
var Ed = WC, KC = Un, GC = Ed, HC = Kr, JC = "[object Arguments]", YC = "[object Array]", XC = "[object Boolean]", ZC = "[object Date]", QC = "[object Error]", eE = "[object Function]", tE = "[object Map]", rE = "[object Number]", nE = "[object Object]", oE = "[object RegExp]", aE = "[object Set]", iE = "[object String]", sE = "[object WeakMap]", lE = "[object ArrayBuffer]", cE = "[object DataView]", uE = "[object Float32Array]", dE = "[object Float64Array]", fE = "[object Int8Array]", pE = "[object Int16Array]", hE = "[object Int32Array]", mE = "[object Uint8Array]", gE = "[object Uint8ClampedArray]", yE = "[object Uint16Array]", bE = "[object Uint32Array]", _t = {};
_t[uE] = _t[dE] = _t[fE] = _t[pE] = _t[hE] = _t[mE] = _t[gE] = _t[yE] = _t[bE] = !0;
_t[JC] = _t[YC] = _t[lE] = _t[XC] = _t[cE] = _t[ZC] = _t[QC] = _t[eE] = _t[tE] = _t[rE] = _t[nE] = _t[oE] = _t[aE] = _t[iE] = _t[sE] = !1;
function vE(e) {
  return HC(e) && GC(e.length) && !!_t[KC(e)];
}
var $E = vE;
function SE(e) {
  return function(t) {
    return e(t);
  };
}
var Fo = SE, fl = { exports: {} };
fl.exports;
(function(e, t) {
  var r = py, n = t && !t.nodeType && t, o = n && !0 && e && !e.nodeType && e, a = o && o.exports === n, i = a && r.process, s = function() {
    try {
      var l = o && o.require && o.require("util").types;
      return l || i && i.binding && i.binding("util");
    } catch {
    }
  }();
  e.exports = s;
})(fl, fl.exports);
var _d = fl.exports, wE = $E, CE = Fo, oh = _d, ah = oh && oh.isTypedArray, EE = ah ? CE(ah) : wE, Zi = EE, _E = wy, xE = Xi, PE = Xt, kE = Fa, OE = Wl, AE = Zi, IE = Object.prototype, RE = IE.hasOwnProperty;
function TE(e, t) {
  var r = PE(e), n = !r && xE(e), o = !r && !n && kE(e), a = !r && !n && !o && AE(e), i = r || n || o || a, s = i ? _E(e.length, String) : [], l = s.length;
  for (var c in e)
    (t || RE.call(e, c)) && !(i && // Safari 9 has enumerable `arguments.length` in strict mode.
    (c == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
    o && (c == "offset" || c == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
    a && (c == "buffer" || c == "byteLength" || c == "byteOffset") || // Skip index properties.
    OE(c, l))) && s.push(c);
  return s;
}
var Ey = TE, ME = Object.prototype;
function NE(e) {
  var t = e && e.constructor, r = typeof t == "function" && t.prototype || ME;
  return e === r;
}
var Kl = NE, FE = my, jE = FE(Object.keys, Object), DE = jE, LE = Kl, BE = DE, zE = Object.prototype, UE = zE.hasOwnProperty;
function VE(e) {
  if (!LE(e))
    return BE(e);
  var t = [];
  for (var r in Object(e))
    UE.call(e, r) && r != "constructor" && t.push(r);
  return t;
}
var _y = VE, qE = Ll, WE = Ed;
function KE(e) {
  return e != null && WE(e.length) && !qE(e);
}
var jo = KE, GE = Ey, HE = _y, JE = jo;
function YE(e) {
  return JE(e) ? GE(e) : HE(e);
}
var Qi = YE, XE = $y, ZE = Cd, QE = Qi;
function e_(e) {
  return XE(e, QE, ZE);
}
var xy = e_, ih = xy, t_ = 1, r_ = Object.prototype, n_ = r_.hasOwnProperty;
function o_(e, t, r, n, o, a) {
  var i = r & t_, s = ih(e), l = s.length, c = ih(t), u = c.length;
  if (l != u && !i)
    return !1;
  for (var f = l; f--; ) {
    var d = s[f];
    if (!(i ? d in t : n_.call(t, d)))
      return !1;
  }
  var p = a.get(e), h = a.get(t);
  if (p && h)
    return p == t && h == e;
  var $ = !0;
  a.set(e, t), a.set(t, e);
  for (var b = i; ++f < l; ) {
    d = s[f];
    var g = e[d], y = t[d];
    if (n)
      var S = i ? n(y, g, d, t, e, a) : n(g, y, d, e, t, a);
    if (!(S === void 0 ? g === y || o(g, y, r, n, a) : S)) {
      $ = !1;
      break;
    }
    b || (b = d == "constructor");
  }
  if ($ && !b) {
    var m = e.constructor, w = t.constructor;
    m != w && "constructor" in e && "constructor" in t && !(typeof m == "function" && m instanceof m && typeof w == "function" && w instanceof w) && ($ = !1);
  }
  return a.delete(e), a.delete(t), $;
}
var a_ = o_, i_ = No, s_ = $n, l_ = i_(s_, "DataView"), c_ = l_, u_ = No, d_ = $n, f_ = u_(d_, "Promise"), p_ = f_, h_ = No, m_ = $n, g_ = h_(m_, "Set"), Py = g_, y_ = No, b_ = $n, v_ = y_(b_, "WeakMap"), $_ = v_, Cu = c_, Eu = vd, _u = p_, xu = Py, Pu = $_, ky = Un, ja = yy, sh = "[object Map]", S_ = "[object Object]", lh = "[object Promise]", ch = "[object Set]", uh = "[object WeakMap]", dh = "[object DataView]", w_ = ja(Cu), C_ = ja(Eu), E_ = ja(_u), __ = ja(xu), x_ = ja(Pu), yo = ky;
(Cu && yo(new Cu(new ArrayBuffer(1))) != dh || Eu && yo(new Eu()) != sh || _u && yo(_u.resolve()) != lh || xu && yo(new xu()) != ch || Pu && yo(new Pu()) != uh) && (yo = function(e) {
  var t = ky(e), r = t == S_ ? e.constructor : void 0, n = r ? ja(r) : "";
  if (n)
    switch (n) {
      case w_:
        return dh;
      case C_:
        return sh;
      case E_:
        return lh;
      case __:
        return ch;
      case x_:
        return uh;
    }
  return t;
});
var es = yo, qc = Ul, P_ = by, k_ = mC, O_ = a_, fh = es, ph = Xt, hh = Fa, A_ = Zi, I_ = 1, mh = "[object Arguments]", gh = "[object Array]", Es = "[object Object]", R_ = Object.prototype, yh = R_.hasOwnProperty;
function T_(e, t, r, n, o, a) {
  var i = ph(e), s = ph(t), l = i ? gh : fh(e), c = s ? gh : fh(t);
  l = l == mh ? Es : l, c = c == mh ? Es : c;
  var u = l == Es, f = c == Es, d = l == c;
  if (d && hh(e)) {
    if (!hh(t))
      return !1;
    i = !0, u = !1;
  }
  if (d && !u)
    return a || (a = new qc()), i || A_(e) ? P_(e, t, r, n, o, a) : k_(e, t, l, r, n, o, a);
  if (!(r & I_)) {
    var p = u && yh.call(e, "__wrapped__"), h = f && yh.call(t, "__wrapped__");
    if (p || h) {
      var $ = p ? e.value() : e, b = h ? t.value() : t;
      return a || (a = new qc()), o($, b, r, n, a);
    }
  }
  return d ? (a || (a = new qc()), O_(e, t, r, n, o, a)) : !1;
}
var M_ = T_, N_ = M_, bh = Kr;
function Oy(e, t, r, n, o) {
  return e === t ? !0 : e == null || t == null || !bh(e) && !bh(t) ? e !== e && t !== t : N_(e, t, r, n, Oy, o);
}
var Gl = Oy, F_ = Gl;
function j_(e, t, r) {
  r = typeof r == "function" ? r : void 0;
  var n = r ? r(e, t) : void 0;
  return n === void 0 ? F_(e, t, void 0, r) : !!n;
}
var D_ = j_;
const L_ = /* @__PURE__ */ pt(D_);
function pr(e, t) {
  return L_(e, t, (r, n) => {
    if (typeof r == "function" && typeof n == "function")
      return !0;
  });
}
var B_ = Un, z_ = Kr, U_ = "[object Symbol]";
function V_(e) {
  return typeof e == "symbol" || z_(e) && B_(e) == U_;
}
var Da = V_, q_ = Xt, W_ = Da, K_ = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, G_ = /^\w*$/;
function H_(e, t) {
  if (q_(e))
    return !1;
  var r = typeof e;
  return r == "number" || r == "symbol" || r == "boolean" || e == null || W_(e) ? !0 : G_.test(e) || !K_.test(e) || t != null && e in Object(t);
}
var xd = H_, Ay = $d, J_ = "Expected a function";
function Pd(e, t) {
  if (typeof e != "function" || t != null && typeof t != "function")
    throw new TypeError(J_);
  var r = function() {
    var n = arguments, o = t ? t.apply(this, n) : n[0], a = r.cache;
    if (a.has(o))
      return a.get(o);
    var i = e.apply(this, n);
    return r.cache = a.set(o, i) || a, i;
  };
  return r.cache = new (Pd.Cache || Ay)(), r;
}
Pd.Cache = Ay;
var Y_ = Pd, X_ = Y_, Z_ = 500;
function Q_(e) {
  var t = X_(e, function(n) {
    return r.size === Z_ && r.clear(), n;
  }), r = t.cache;
  return t;
}
var e5 = Q_, t5 = e5, r5 = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, n5 = /\\(\\)?/g, o5 = t5(function(e) {
  var t = [];
  return e.charCodeAt(0) === 46 && t.push(""), e.replace(r5, function(r, n, o, a) {
    t.push(o ? a.replace(n5, "$1") : n || r);
  }), t;
}), Iy = o5;
function a5(e, t) {
  for (var r = -1, n = e == null ? 0 : e.length, o = Array(n); ++r < n; )
    o[r] = t(e[r], r, e);
  return o;
}
var Vn = a5, vh = Oa, i5 = Vn, s5 = Xt, l5 = Da, $h = vh ? vh.prototype : void 0, Sh = $h ? $h.toString : void 0;
function Ry(e) {
  if (typeof e == "string")
    return e;
  if (s5(e))
    return i5(e, Ry) + "";
  if (l5(e))
    return Sh ? Sh.call(e) : "";
  var t = e + "";
  return t == "0" && 1 / e == -1 / 0 ? "-0" : t;
}
var c5 = Ry, u5 = c5;
function d5(e) {
  return e == null ? "" : u5(e);
}
var Ty = d5, f5 = Xt, p5 = xd, h5 = Iy, m5 = Ty;
function g5(e, t) {
  return f5(e) ? e : p5(e, t) ? [e] : h5(m5(e));
}
var La = g5, y5 = Da;
function b5(e) {
  if (typeof e == "string" || y5(e))
    return e;
  var t = e + "";
  return t == "0" && 1 / e == -1 / 0 ? "-0" : t;
}
var Do = b5, v5 = La, $5 = Do;
function S5(e, t) {
  t = v5(t, e);
  for (var r = 0, n = t.length; e != null && r < n; )
    e = e[$5(t[r++])];
  return r && r == n ? e : void 0;
}
var ts = S5, w5 = ts;
function C5(e, t, r) {
  var n = e == null ? void 0 : w5(e, t);
  return n === void 0 ? r : n;
}
var My = C5;
const xe = /* @__PURE__ */ pt(My);
var E5 = _y, _5 = es, x5 = Xi, P5 = Xt, k5 = jo, O5 = Fa, A5 = Kl, I5 = Zi, R5 = "[object Map]", T5 = "[object Set]", M5 = Object.prototype, N5 = M5.hasOwnProperty;
function F5(e) {
  if (e == null)
    return !0;
  if (k5(e) && (P5(e) || typeof e == "string" || typeof e.splice == "function" || O5(e) || I5(e) || x5(e)))
    return !e.length;
  var t = _5(e);
  if (t == R5 || t == T5)
    return !e.size;
  if (A5(e))
    return !E5(e).length;
  for (var r in e)
    if (N5.call(e, r))
      return !1;
  return !0;
}
var j5 = F5;
const io = /* @__PURE__ */ pt(j5);
var Hl = {}, D5 = /~/, L5 = /~[01]/g;
function B5(e) {
  switch (e) {
    case "~1":
      return "/";
    case "~0":
      return "~";
  }
  throw new Error("Invalid tilde escape: " + e);
}
function Ny(e) {
  return D5.test(e) ? e.replace(L5, B5) : e;
}
function z5(e, t, r) {
  for (var n, o, a = 1, i = t.length; a < i; ) {
    if (t[a] === "constructor" || t[a] === "prototype" || t[a] === "__proto__") return e;
    if (n = Ny(t[a++]), o = i > a, typeof e[n] > "u" && (Array.isArray(e) && n === "-" && (n = e.length), o && (t[a] !== "" && t[a] < 1 / 0 || t[a] === "-" ? e[n] = [] : e[n] = {})), !o) break;
    e = e[n];
  }
  var s = e[n];
  return r === void 0 ? delete e[n] : e[n] = r, s;
}
function kd(e) {
  if (typeof e == "string") {
    if (e = e.split("/"), e[0] === "") return e;
    throw new Error("Invalid JSON pointer.");
  } else if (Array.isArray(e)) {
    for (const t of e)
      if (typeof t != "string" && typeof t != "number")
        throw new Error("Invalid JSON pointer. Must be of type string or number.");
    return e;
  }
  throw new Error("Invalid JSON pointer.");
}
function Fy(e, t) {
  if (typeof e != "object") throw new Error("Invalid input object.");
  t = kd(t);
  var r = t.length;
  if (r === 1) return e;
  for (var n = 1; n < r; ) {
    if (e = e[Ny(t[n++])], r === n) return e;
    if (typeof e != "object" || e === null) return;
  }
}
function jy(e, t, r) {
  if (typeof e != "object") throw new Error("Invalid input object.");
  if (t = kd(t), t.length === 0) throw new Error("Invalid JSON pointer for set.");
  return z5(e, t, r);
}
function U5(e) {
  var t = kd(e);
  return {
    get: function(r) {
      return Fy(r, t);
    },
    set: function(r, n) {
      return jy(r, t, n);
    }
  };
}
Hl.get = Fy;
Hl.set = jy;
Hl.compile = U5;
function V5(e, t) {
  for (var r = -1, n = e == null ? 0 : e.length; ++r < n && t(e[r], r, e) !== !1; )
    ;
  return e;
}
var Od = V5, q5 = No, W5 = function() {
  try {
    var e = q5(Object, "defineProperty");
    return e({}, "", {}), e;
  } catch {
  }
}(), Dy = W5, wh = Dy;
function K5(e, t, r) {
  t == "__proto__" && wh ? wh(e, t, {
    configurable: !0,
    enumerable: !0,
    value: r,
    writable: !0
  }) : e[t] = r;
}
var Ad = K5, G5 = Ad, H5 = Ia, J5 = Object.prototype, Y5 = J5.hasOwnProperty;
function X5(e, t, r) {
  var n = e[t];
  (!(Y5.call(e, t) && H5(n, r)) || r === void 0 && !(t in e)) && G5(e, t, r);
}
var Id = X5, Z5 = Id, Q5 = Ad;
function ex(e, t, r, n) {
  var o = !r;
  r || (r = {});
  for (var a = -1, i = t.length; ++a < i; ) {
    var s = t[a], l = n ? n(r[s], e[s], s, r, e) : void 0;
    l === void 0 && (l = e[s]), o ? Q5(r, s, l) : Z5(r, s, l);
  }
  return r;
}
var Ba = ex, tx = Ba, rx = Qi;
function nx(e, t) {
  return e && tx(t, rx(t), e);
}
var ox = nx;
function ax(e) {
  var t = [];
  if (e != null)
    for (var r in Object(e))
      t.push(r);
  return t;
}
var ix = ax, sx = Er, lx = Kl, cx = ix, ux = Object.prototype, dx = ux.hasOwnProperty;
function fx(e) {
  if (!sx(e))
    return cx(e);
  var t = lx(e), r = [];
  for (var n in e)
    n == "constructor" && (t || !dx.call(e, n)) || r.push(n);
  return r;
}
var px = fx, hx = Ey, mx = px, gx = jo;
function yx(e) {
  return gx(e) ? hx(e, !0) : mx(e);
}
var za = yx, bx = Ba, vx = za;
function $x(e, t) {
  return e && bx(t, vx(t), e);
}
var Sx = $x, pl = { exports: {} };
pl.exports;
(function(e, t) {
  var r = $n, n = t && !t.nodeType && t, o = n && !0 && e && !e.nodeType && e, a = o && o.exports === n, i = a ? r.Buffer : void 0, s = i ? i.allocUnsafe : void 0;
  function l(c, u) {
    if (u)
      return c.slice();
    var f = c.length, d = s ? s(f) : new c.constructor(f);
    return c.copy(d), d;
  }
  e.exports = l;
})(pl, pl.exports);
var Ly = pl.exports;
function wx(e, t) {
  var r = -1, n = e.length;
  for (t || (t = Array(n)); ++r < n; )
    t[r] = e[r];
  return t;
}
var Jl = wx, Cx = Ba, Ex = Cd;
function _x(e, t) {
  return Cx(e, Ex(e), t);
}
var xx = _x, Px = wd, kx = Fl, Ox = Cd, Ax = Sy, Ix = Object.getOwnPropertySymbols, Rx = Ix ? function(e) {
  for (var t = []; e; )
    Px(t, Ox(e)), e = kx(e);
  return t;
} : Ax, By = Rx, Tx = Ba, Mx = By;
function Nx(e, t) {
  return Tx(e, Mx(e), t);
}
var Fx = Nx, jx = $y, Dx = By, Lx = za;
function Bx(e) {
  return jx(e, Lx, Dx);
}
var zy = Bx, zx = Object.prototype, Ux = zx.hasOwnProperty;
function Vx(e) {
  var t = e.length, r = new e.constructor(t);
  return t && typeof e[0] == "string" && Ux.call(e, "index") && (r.index = e.index, r.input = e.input), r;
}
var qx = Vx, Ch = vy;
function Wx(e) {
  var t = new e.constructor(e.byteLength);
  return new Ch(t).set(new Ch(e)), t;
}
var Rd = Wx, Kx = Rd;
function Gx(e, t) {
  var r = t ? Kx(e.buffer) : e.buffer;
  return new e.constructor(r, e.byteOffset, e.byteLength);
}
var Hx = Gx, Jx = /\w*$/;
function Yx(e) {
  var t = new e.constructor(e.source, Jx.exec(e));
  return t.lastIndex = e.lastIndex, t;
}
var Xx = Yx, Eh = Oa, _h = Eh ? Eh.prototype : void 0, xh = _h ? _h.valueOf : void 0;
function Zx(e) {
  return xh ? Object(xh.call(e)) : {};
}
var Qx = Zx, eP = Rd;
function tP(e, t) {
  var r = t ? eP(e.buffer) : e.buffer;
  return new e.constructor(r, e.byteOffset, e.length);
}
var Uy = tP, rP = Rd, nP = Hx, oP = Xx, aP = Qx, iP = Uy, sP = "[object Boolean]", lP = "[object Date]", cP = "[object Map]", uP = "[object Number]", dP = "[object RegExp]", fP = "[object Set]", pP = "[object String]", hP = "[object Symbol]", mP = "[object ArrayBuffer]", gP = "[object DataView]", yP = "[object Float32Array]", bP = "[object Float64Array]", vP = "[object Int8Array]", $P = "[object Int16Array]", SP = "[object Int32Array]", wP = "[object Uint8Array]", CP = "[object Uint8ClampedArray]", EP = "[object Uint16Array]", _P = "[object Uint32Array]";
function xP(e, t, r) {
  var n = e.constructor;
  switch (t) {
    case mP:
      return rP(e);
    case sP:
    case lP:
      return new n(+e);
    case gP:
      return nP(e, r);
    case yP:
    case bP:
    case vP:
    case $P:
    case SP:
    case wP:
    case CP:
    case EP:
    case _P:
      return iP(e, r);
    case cP:
      return new n();
    case uP:
    case pP:
      return new n(e);
    case dP:
      return oP(e);
    case fP:
      return new n();
    case hP:
      return aP(e);
  }
}
var PP = xP, kP = Er, Ph = Object.create, OP = /* @__PURE__ */ function() {
  function e() {
  }
  return function(t) {
    if (!kP(t))
      return {};
    if (Ph)
      return Ph(t);
    e.prototype = t;
    var r = new e();
    return e.prototype = void 0, r;
  };
}(), Vy = OP, AP = Vy, IP = Fl, RP = Kl;
function TP(e) {
  return typeof e.constructor == "function" && !RP(e) ? AP(IP(e)) : {};
}
var qy = TP, MP = es, NP = Kr, FP = "[object Map]";
function jP(e) {
  return NP(e) && MP(e) == FP;
}
var DP = jP, LP = DP, BP = Fo, kh = _d, Oh = kh && kh.isMap, zP = Oh ? BP(Oh) : LP, UP = zP, VP = es, qP = Kr, WP = "[object Set]";
function KP(e) {
  return qP(e) && VP(e) == WP;
}
var GP = KP, HP = GP, JP = Fo, Ah = _d, Ih = Ah && Ah.isSet, YP = Ih ? JP(Ih) : HP, XP = YP, ZP = Ul, QP = Od, ek = Id, tk = ox, rk = Sx, nk = Ly, ok = Jl, ak = xx, ik = Fx, sk = xy, lk = zy, ck = es, uk = qx, dk = PP, fk = qy, pk = Xt, hk = Fa, mk = UP, gk = Er, yk = XP, bk = Qi, vk = za, $k = 1, Sk = 2, wk = 4, Wy = "[object Arguments]", Ck = "[object Array]", Ek = "[object Boolean]", _k = "[object Date]", xk = "[object Error]", Ky = "[object Function]", Pk = "[object GeneratorFunction]", kk = "[object Map]", Ok = "[object Number]", Gy = "[object Object]", Ak = "[object RegExp]", Ik = "[object Set]", Rk = "[object String]", Tk = "[object Symbol]", Mk = "[object WeakMap]", Nk = "[object ArrayBuffer]", Fk = "[object DataView]", jk = "[object Float32Array]", Dk = "[object Float64Array]", Lk = "[object Int8Array]", Bk = "[object Int16Array]", zk = "[object Int32Array]", Uk = "[object Uint8Array]", Vk = "[object Uint8ClampedArray]", qk = "[object Uint16Array]", Wk = "[object Uint32Array]", Ct = {};
Ct[Wy] = Ct[Ck] = Ct[Nk] = Ct[Fk] = Ct[Ek] = Ct[_k] = Ct[jk] = Ct[Dk] = Ct[Lk] = Ct[Bk] = Ct[zk] = Ct[kk] = Ct[Ok] = Ct[Gy] = Ct[Ak] = Ct[Ik] = Ct[Rk] = Ct[Tk] = Ct[Uk] = Ct[Vk] = Ct[qk] = Ct[Wk] = !0;
Ct[xk] = Ct[Ky] = Ct[Mk] = !1;
function Js(e, t, r, n, o, a) {
  var i, s = t & $k, l = t & Sk, c = t & wk;
  if (r && (i = o ? r(e, n, o, a) : r(e)), i !== void 0)
    return i;
  if (!gk(e))
    return e;
  var u = pk(e);
  if (u) {
    if (i = uk(e), !s)
      return ok(e, i);
  } else {
    var f = ck(e), d = f == Ky || f == Pk;
    if (hk(e))
      return nk(e, s);
    if (f == Gy || f == Wy || d && !o) {
      if (i = l || d ? {} : fk(e), !s)
        return l ? ik(e, rk(i, e)) : ak(e, tk(i, e));
    } else {
      if (!Ct[f])
        return o ? e : {};
      i = dk(e, f, s);
    }
  }
  a || (a = new ZP());
  var p = a.get(e);
  if (p)
    return p;
  a.set(e, i), yk(e) ? e.forEach(function(b) {
    i.add(Js(b, t, r, b, e, a));
  }) : mk(e) && e.forEach(function(b, g) {
    i.set(g, Js(b, t, r, g, e, a));
  });
  var h = c ? l ? lk : sk : l ? vk : bk, $ = u ? void 0 : h(e);
  return QP($ || e, function(b, g) {
    $ && (g = b, b = e[g]), ek(i, g, Js(b, t, r, g, e, a));
  }), i;
}
var Hy = Js;
function Kk(e) {
  var t = e == null ? 0 : e.length;
  return t ? e[t - 1] : void 0;
}
var Jy = Kk;
function Gk(e, t, r) {
  var n = -1, o = e.length;
  t < 0 && (t = -t > o ? 0 : o + t), r = r > o ? o : r, r < 0 && (r += o), o = t > r ? 0 : r - t >>> 0, t >>>= 0;
  for (var a = Array(o); ++n < o; )
    a[n] = e[n + t];
  return a;
}
var Hk = Gk, Jk = ts, Yk = Hk;
function Xk(e, t) {
  return t.length < 2 ? e : Jk(e, Yk(t, 0, -1));
}
var Zk = Xk, Qk = La, eO = Jy, tO = Zk, rO = Do;
function nO(e, t) {
  return t = Qk(t, e), e = tO(e, t), e == null || delete e[rO(eO(t))];
}
var Yy = nO, oO = Aa;
function aO(e) {
  return oO(e) ? void 0 : e;
}
var iO = aO, Rh = Oa, sO = Xi, lO = Xt, Th = Rh ? Rh.isConcatSpreadable : void 0;
function cO(e) {
  return lO(e) || sO(e) || !!(Th && e && e[Th]);
}
var uO = cO, dO = wd, fO = uO;
function Xy(e, t, r, n, o) {
  var a = -1, i = e.length;
  for (r || (r = fO), o || (o = []); ++a < i; ) {
    var s = e[a];
    t > 0 && r(s) ? t > 1 ? Xy(s, t - 1, r, n, o) : dO(o, s) : n || (o[o.length] = s);
  }
  return o;
}
var Yl = Xy, pO = Yl;
function hO(e) {
  var t = e == null ? 0 : e.length;
  return t ? pO(e, 1) : [];
}
var Td = hO;
function mO(e, t, r) {
  switch (r.length) {
    case 0:
      return e.call(t);
    case 1:
      return e.call(t, r[0]);
    case 2:
      return e.call(t, r[0], r[1]);
    case 3:
      return e.call(t, r[0], r[1], r[2]);
  }
  return e.apply(t, r);
}
var Zy = mO, gO = Zy, Mh = Math.max;
function yO(e, t, r) {
  return t = Mh(t === void 0 ? e.length - 1 : t, 0), function() {
    for (var n = arguments, o = -1, a = Mh(n.length - t, 0), i = Array(a); ++o < a; )
      i[o] = n[t + o];
    o = -1;
    for (var s = Array(t + 1); ++o < t; )
      s[o] = n[o];
    return s[t] = r(i), gO(e, this, s);
  };
}
var Qy = yO;
function bO(e) {
  return function() {
    return e;
  };
}
var vO = bO;
function $O(e) {
  return e;
}
var rs = $O, SO = vO, Nh = Dy, wO = rs, CO = Nh ? function(e, t) {
  return Nh(e, "toString", {
    configurable: !0,
    enumerable: !1,
    value: SO(t),
    writable: !0
  });
} : wO, EO = CO, _O = 800, xO = 16, PO = Date.now;
function kO(e) {
  var t = 0, r = 0;
  return function() {
    var n = PO(), o = xO - (n - r);
    if (r = n, o > 0) {
      if (++t >= _O)
        return arguments[0];
    } else
      t = 0;
    return e.apply(void 0, arguments);
  };
}
var OO = kO, AO = EO, IO = OO, RO = IO(AO), e0 = RO, TO = Td, MO = Qy, NO = e0;
function FO(e) {
  return NO(MO(e, void 0, TO), e + "");
}
var t0 = FO, jO = Vn, DO = Hy, LO = Yy, BO = La, zO = Ba, UO = iO, VO = t0, qO = zy, WO = 1, KO = 2, GO = 4, HO = VO(function(e, t) {
  var r = {};
  if (e == null)
    return r;
  var n = !1;
  t = jO(t, function(a) {
    return a = BO(a, e), n || (n = a.length > 1), a;
  }), zO(e, qO(e), r), n && (r = DO(r, WO | KO | GO, UO));
  for (var o = t.length; o--; )
    LO(r, t[o]);
  return r;
}), JO = HO;
const hl = /* @__PURE__ */ pt(JO);
function Md(e, t) {
  const r = t[e];
  return [hl(t, [e]), r];
}
function r0(e, t = {}, r = []) {
  const n = e || "";
  let o;
  if (n.startsWith("#"))
    o = decodeURIComponent(n.substring(1));
  else
    throw new Error(`Could not find a definition for ${e}.`);
  const a = Hl.get(t, o);
  if (a === void 0)
    throw new Error(`Could not find a definition for ${e}.`);
  const i = a[Ht];
  if (i) {
    if (r.includes(i)) {
      if (r.length === 1)
        throw new Error(`Definition for ${e} is a circular reference`);
      const [u, ...f] = r, d = [...f, n, u].join(" -> ");
      throw new Error(`Definition for ${u} contains a circular reference through ${d}`);
    }
    const [s, l] = Md(Ht, a), c = r0(l, t, [...r, n]);
    return Object.keys(s).length > 0 ? { ...s, ...c } : c;
  }
  return a;
}
function n0(e, t = {}) {
  return r0(e, t, []);
}
var YO = Object.prototype, XO = YO.hasOwnProperty;
function ZO(e, t) {
  return e != null && XO.call(e, t);
}
var QO = ZO, eA = La, tA = Xi, rA = Xt, nA = Wl, oA = Ed, aA = Do;
function iA(e, t, r) {
  t = eA(t, e);
  for (var n = -1, o = t.length, a = !1; ++n < o; ) {
    var i = aA(t[n]);
    if (!(a = e != null && r(e, i)))
      break;
    e = e[i];
  }
  return a || ++n != o ? a : (o = e == null ? 0 : e.length, !!o && oA(o) && nA(i, o) && (rA(e) || tA(e)));
}
var o0 = iA, sA = QO, lA = o0;
function cA(e, t) {
  return e != null && lA(e, t, sA);
}
var uA = cA;
const fr = /* @__PURE__ */ pt(uA);
var dA = Un, fA = Kr, pA = "[object Number]";
function hA(e) {
  return typeof e == "number" || fA(e) && dA(e) == pA;
}
var mA = hA;
const a0 = /* @__PURE__ */ pt(mA);
var gA = Un, yA = Xt, bA = Kr, vA = "[object String]";
function $A(e) {
  return typeof e == "string" || !yA(e) && bA(e) && gA(e) == vA;
}
var SA = $A;
const Nd = /* @__PURE__ */ pt(SA);
function wA(e, t, r, n) {
  var o = -1, a = e == null ? 0 : e.length;
  for (n && a && (r = e[++o]); ++o < a; )
    r = t(r, e[o], o, e);
  return r;
}
var CA = wA;
function EA(e) {
  return function(t, r, n) {
    for (var o = -1, a = Object(t), i = n(t), s = i.length; s--; ) {
      var l = i[e ? s : ++o];
      if (r(a[l], l, a) === !1)
        break;
    }
    return t;
  };
}
var _A = EA, xA = _A, PA = xA(), i0 = PA, kA = i0, OA = Qi;
function AA(e, t) {
  return e && kA(e, t, OA);
}
var s0 = AA, IA = jo;
function RA(e, t) {
  return function(r, n) {
    if (r == null)
      return r;
    if (!IA(r))
      return e(r, n);
    for (var o = r.length, a = t ? o : -1, i = Object(r); (t ? a-- : ++a < o) && n(i[a], a, i) !== !1; )
      ;
    return r;
  };
}
var TA = RA, MA = s0, NA = TA, FA = NA(MA), Fd = FA, jA = Ul, DA = Gl, LA = 1, BA = 2;
function zA(e, t, r, n) {
  var o = r.length, a = o, i = !n;
  if (e == null)
    return !a;
  for (e = Object(e); o--; ) {
    var s = r[o];
    if (i && s[2] ? s[1] !== e[s[0]] : !(s[0] in e))
      return !1;
  }
  for (; ++o < a; ) {
    s = r[o];
    var l = s[0], c = e[l], u = s[1];
    if (i && s[2]) {
      if (c === void 0 && !(l in e))
        return !1;
    } else {
      var f = new jA();
      if (n)
        var d = n(c, u, l, e, t, f);
      if (!(d === void 0 ? DA(u, c, LA | BA, n, f) : d))
        return !1;
    }
  }
  return !0;
}
var UA = zA, VA = Er;
function qA(e) {
  return e === e && !VA(e);
}
var l0 = qA, WA = l0, KA = Qi;
function GA(e) {
  for (var t = KA(e), r = t.length; r--; ) {
    var n = t[r], o = e[n];
    t[r] = [n, o, WA(o)];
  }
  return t;
}
var HA = GA;
function JA(e, t) {
  return function(r) {
    return r == null ? !1 : r[e] === t && (t !== void 0 || e in Object(r));
  };
}
var c0 = JA, YA = UA, XA = HA, ZA = c0;
function QA(e) {
  var t = XA(e);
  return t.length == 1 && t[0][2] ? ZA(t[0][0], t[0][1]) : function(r) {
    return r === e || YA(r, e, t);
  };
}
var eI = QA;
function tI(e, t) {
  return e != null && t in Object(e);
}
var rI = tI, nI = rI, oI = o0;
function aI(e, t) {
  return e != null && oI(e, t, nI);
}
var u0 = aI, iI = Gl, sI = My, lI = u0, cI = xd, uI = l0, dI = c0, fI = Do, pI = 1, hI = 2;
function mI(e, t) {
  return cI(e) && uI(t) ? dI(fI(e), t) : function(r) {
    var n = sI(r, e);
    return n === void 0 && n === t ? lI(r, e) : iI(t, n, pI | hI);
  };
}
var gI = mI;
function yI(e) {
  return function(t) {
    return t == null ? void 0 : t[e];
  };
}
var bI = yI, vI = ts;
function $I(e) {
  return function(t) {
    return vI(t, e);
  };
}
var SI = $I, wI = bI, CI = SI, EI = xd, _I = Do;
function xI(e) {
  return EI(e) ? wI(_I(e)) : CI(e);
}
var PI = xI, kI = eI, OI = gI, AI = rs, II = Xt, RI = PI;
function TI(e) {
  return typeof e == "function" ? e : e == null ? AI : typeof e == "object" ? II(e) ? OI(e[0], e[1]) : kI(e) : RI(e);
}
var jd = TI;
function MI(e, t, r, n, o) {
  return o(e, function(a, i, s) {
    r = n ? (n = !1, a) : t(r, a, i, s);
  }), r;
}
var NI = MI, FI = CA, jI = Fd, DI = jd, LI = NI, BI = Xt;
function zI(e, t, r) {
  var n = BI(e) ? FI : LI, o = arguments.length < 3;
  return n(e, DI(t), r, o, jI);
}
var UI = zI;
const VI = /* @__PURE__ */ pt(UI);
var qI = rs;
function WI(e) {
  return typeof e == "function" ? e : qI;
}
var d0 = WI, KI = /\s/;
function GI(e) {
  for (var t = e.length; t-- && KI.test(e.charAt(t)); )
    ;
  return t;
}
var HI = GI, JI = HI, YI = /^\s+/;
function XI(e) {
  return e && e.slice(0, JI(e) + 1).replace(YI, "");
}
var ZI = XI, QI = ZI, Fh = Er, eR = Da, jh = NaN, tR = /^[-+]0x[0-9a-f]+$/i, rR = /^0b[01]+$/i, nR = /^0o[0-7]+$/i, oR = parseInt;
function aR(e) {
  if (typeof e == "number")
    return e;
  if (eR(e))
    return jh;
  if (Fh(e)) {
    var t = typeof e.valueOf == "function" ? e.valueOf() : e;
    e = Fh(t) ? t + "" : t;
  }
  if (typeof e != "string")
    return e === 0 ? e : +e;
  e = QI(e);
  var r = rR.test(e);
  return r || nR.test(e) ? oR(e.slice(2), r ? 2 : 8) : tR.test(e) ? jh : +e;
}
var iR = aR, sR = iR, lR = 1 / 0, cR = 17976931348623157e292;
function uR(e) {
  if (!e)
    return e === 0 ? e : 0;
  if (e = sR(e), e === lR || e === -1 / 0) {
    var t = e < 0 ? -1 : 1;
    return t * cR;
  }
  return e === e ? e : 0;
}
var dR = uR, fR = dR;
function pR(e) {
  var t = fR(e), r = t % 1;
  return t === t ? r ? t - r : t : 0;
}
var hR = pR, mR = wy, gR = d0, yR = hR, bR = 9007199254740991, Wc = 4294967295, vR = Math.min;
function $R(e, t) {
  if (e = yR(e), e < 1 || e > bR)
    return [];
  var r = Wc, n = vR(e, Wc);
  t = gR(t), e -= Wc;
  for (var o = mR(n, t); ++r < e; )
    t(r);
  return o;
}
var SR = $R;
const f0 = /* @__PURE__ */ pt(SR);
function p0(e, t, r) {
  var n;
  if (e && r) {
    const o = xe(e, r);
    if (o === void 0)
      return;
    for (let a = 0; a < t.length; a++) {
      const i = t[a], s = xe(i, [Mt, r], {});
      if (!(s.type === "object" || s.type === "array") && (s.const === o || !((n = s.enum) === null || n === void 0) && n.includes(o)))
        return a;
    }
  }
}
function h0(e, t, r, n, o) {
  if (t === void 0)
    return 0;
  const a = p0(t, r, o);
  if (a0(a))
    return a;
  for (let i = 0; i < r.length; i++) {
    const s = r[i];
    if (o && fr(s, [Mt, o])) {
      const l = xe(t, o), c = xe(s, [Mt, o], {});
      if (e.isValid(c, l, n))
        return i;
    } else if (s[Mt]) {
      const l = {
        anyOf: Object.keys(s[Mt]).map((u) => ({
          required: [u]
        }))
      };
      let c;
      if (s.anyOf) {
        const { ...u } = s;
        u.allOf ? u.allOf = u.allOf.slice() : u.allOf = [], u.allOf.push(l), c = u;
      } else
        c = Object.assign({}, s, l);
      if (delete c.required, e.isValid(c, t, n))
        return i;
    } else if (e.isValid(s, t, n))
      return i;
  }
  return 0;
}
function Dd(e, t, r, n, o) {
  return h0(e, t, r, n, o);
}
var wR = Gl;
function CR(e, t) {
  return wR(e, t);
}
var Ld = CR;
const Po = /* @__PURE__ */ pt(Ld);
var ER = Id, _R = La, xR = Wl, Dh = Er, PR = Do;
function kR(e, t, r, n) {
  if (!Dh(e))
    return e;
  t = _R(t, e);
  for (var o = -1, a = t.length, i = a - 1, s = e; s != null && ++o < a; ) {
    var l = PR(t[o]), c = r;
    if (l === "__proto__" || l === "constructor" || l === "prototype")
      return e;
    if (o != i) {
      var u = s[l];
      c = n ? n(u, l, s) : void 0, c === void 0 && (c = Dh(u) ? u : xR(t[o + 1]) ? [] : {});
    }
    ER(s, l, c), s = s[l];
  }
  return e;
}
var Bd = kR, OR = Bd;
function AR(e, t, r) {
  return e == null ? e : OR(e, t, r);
}
var IR = AR;
const er = /* @__PURE__ */ pt(IR);
var RR = Od, TR = Vy, MR = s0, NR = jd, FR = Fl, jR = Xt, DR = Fa, LR = Ll, BR = Er, zR = Zi;
function UR(e, t, r) {
  var n = jR(e), o = n || DR(e) || zR(e);
  if (t = NR(t), r == null) {
    var a = e && e.constructor;
    o ? r = n ? new a() : [] : BR(e) ? r = LR(a) ? TR(FR(e)) : {} : r = {};
  }
  return (o ? RR : MR)(e, function(i, s, l) {
    return t(r, i, s, l);
  }), r;
}
var VR = UR;
const qR = /* @__PURE__ */ pt(VR);
var WR = Ad, KR = Ia;
function GR(e, t, r) {
  (r !== void 0 && !KR(e[t], r) || r === void 0 && !(t in e)) && WR(e, t, r);
}
var m0 = GR, HR = jo, JR = Kr;
function YR(e) {
  return JR(e) && HR(e);
}
var Xl = YR;
function XR(e, t) {
  if (!(t === "constructor" && typeof e[t] == "function") && t != "__proto__")
    return e[t];
}
var g0 = XR, ZR = Ba, QR = za;
function eT(e) {
  return ZR(e, QR(e));
}
var tT = eT, Lh = m0, rT = Ly, nT = Uy, oT = Jl, aT = qy, Bh = Xi, zh = Xt, iT = Xl, sT = Fa, lT = Ll, cT = Er, uT = Aa, dT = Zi, Uh = g0, fT = tT;
function pT(e, t, r, n, o, a, i) {
  var s = Uh(e, r), l = Uh(t, r), c = i.get(l);
  if (c) {
    Lh(e, r, c);
    return;
  }
  var u = a ? a(s, l, r + "", e, t, i) : void 0, f = u === void 0;
  if (f) {
    var d = zh(l), p = !d && sT(l), h = !d && !p && dT(l);
    u = l, d || p || h ? zh(s) ? u = s : iT(s) ? u = oT(s) : p ? (f = !1, u = rT(l, !0)) : h ? (f = !1, u = nT(l, !0)) : u = [] : uT(l) || Bh(l) ? (u = s, Bh(s) ? u = fT(s) : (!cT(s) || lT(s)) && (u = aT(l))) : f = !1;
  }
  f && (i.set(l, u), o(u, l, n, a, i), i.delete(l)), Lh(e, r, u);
}
var hT = pT, mT = Ul, gT = m0, yT = i0, bT = hT, vT = Er, $T = za, ST = g0;
function y0(e, t, r, n, o) {
  e !== t && yT(t, function(a, i) {
    if (o || (o = new mT()), vT(a))
      bT(e, t, i, r, y0, n, o);
    else {
      var s = n ? n(ST(e, i), a, i + "", e, t, o) : void 0;
      s === void 0 && (s = a), gT(e, i, s);
    }
  }, $T);
}
var zd = y0, wT = rs, CT = Qy, ET = e0;
function _T(e, t) {
  return ET(CT(e, t, wT), e + "");
}
var uo = _T, xT = Ia, PT = jo, kT = Wl, OT = Er;
function AT(e, t, r) {
  if (!OT(r))
    return !1;
  var n = typeof t;
  return (n == "number" ? PT(r) && kT(t, r.length) : n == "string" && t in r) ? xT(r[t], e) : !1;
}
var Ud = AT, IT = uo, RT = Ud;
function TT(e) {
  return IT(function(t, r) {
    var n = -1, o = r.length, a = o > 1 ? r[o - 1] : void 0, i = o > 2 ? r[2] : void 0;
    for (a = e.length > 3 && typeof a == "function" ? (o--, a) : void 0, i && RT(r[0], r[1], i) && (a = o < 3 ? void 0 : a, o = 1), t = Object(t); ++n < o; ) {
      var s = r[n];
      s && e(t, s, n, a);
    }
    return t;
  });
}
var b0 = TT, MT = zd, NT = b0, FT = NT(function(e, t, r) {
  MT(e, t, r);
}), jT = FT;
const DT = /* @__PURE__ */ pt(jT);
var LT = Yl, BT = 1 / 0;
function zT(e) {
  var t = e == null ? 0 : e.length;
  return t ? LT(e, BT) : [];
}
var Vd = zT;
const UT = /* @__PURE__ */ pt(Vd);
function VT(e, t, r, n) {
  for (var o = e.length, a = r + (n ? 1 : -1); n ? a-- : ++a < o; )
    if (t(e[a], a, e))
      return a;
  return -1;
}
var qT = VT;
function WT(e) {
  return e !== e;
}
var KT = WT;
function GT(e, t, r) {
  for (var n = r - 1, o = e.length; ++n < o; )
    if (e[n] === t)
      return n;
  return -1;
}
var HT = GT, JT = qT, YT = KT, XT = HT;
function ZT(e, t, r) {
  return t === t ? XT(e, t, r) : JT(e, YT, r);
}
var v0 = ZT, QT = v0;
function eM(e, t) {
  var r = e == null ? 0 : e.length;
  return !!r && QT(e, t, 0) > -1;
}
var qd = eM;
function tM(e, t, r) {
  for (var n = -1, o = e == null ? 0 : e.length; ++n < o; )
    if (r(t, e[n]))
      return !0;
  return !1;
}
var Wd = tM;
function rM() {
}
var nM = rM, Kc = Py, oM = nM, aM = Sd, iM = 1 / 0, sM = Kc && 1 / aM(new Kc([, -0]))[1] == iM ? function(e) {
  return new Kc(e);
} : oM, lM = sM, cM = Vl, uM = qd, dM = Wd, fM = ql, pM = lM, hM = Sd, mM = 200;
function gM(e, t, r) {
  var n = -1, o = uM, a = e.length, i = !0, s = [], l = s;
  if (r)
    i = !1, o = dM;
  else if (a >= mM) {
    var c = t ? null : pM(e);
    if (c)
      return hM(c);
    i = !1, o = fM, l = new cM();
  } else
    l = t ? [] : s;
  e:
    for (; ++n < a; ) {
      var u = e[n], f = t ? t(u) : u;
      if (u = r || u !== 0 ? u : 0, i && f === f) {
        for (var d = l.length; d--; )
          if (l[d] === f)
            continue e;
        t && l.push(f), s.push(u);
      } else o(l, f, r) || (l !== s && l.push(f), s.push(u));
    }
  return s;
}
var Kd = gM, yM = Kd;
function bM(e) {
  return e && e.length ? yM(e) : [];
}
var Zl = bM;
const vM = /* @__PURE__ */ pt(Zl);
var $M = Hy, SM = 1, wM = 4;
function CM(e) {
  return $M(e, SM | wM);
}
var $0 = CM;
const S0 = /* @__PURE__ */ pt($0);
var EM = Fd, _M = jo;
function xM(e, t) {
  var r = -1, n = _M(e) ? Array(e.length) : [];
  return EM(e, function(o, a, i) {
    n[++r] = t(o, a, i);
  }), n;
}
var PM = xM;
function kM(e, t) {
  var r = e.length;
  for (e.sort(t); r--; )
    e[r] = e[r].value;
  return e;
}
var OM = kM, Vh = Da;
function AM(e, t) {
  if (e !== t) {
    var r = e !== void 0, n = e === null, o = e === e, a = Vh(e), i = t !== void 0, s = t === null, l = t === t, c = Vh(t);
    if (!s && !c && !a && e > t || a && i && l && !s && !c || n && i && l || !r && l || !o)
      return 1;
    if (!n && !a && !c && e < t || c && r && o && !n && !a || s && r && o || !i && o || !l)
      return -1;
  }
  return 0;
}
var IM = AM, RM = IM;
function TM(e, t, r) {
  for (var n = -1, o = e.criteria, a = t.criteria, i = o.length, s = r.length; ++n < i; ) {
    var l = RM(o[n], a[n]);
    if (l) {
      if (n >= s)
        return l;
      var c = r[n];
      return l * (c == "desc" ? -1 : 1);
    }
  }
  return e.index - t.index;
}
var MM = TM, Gc = Vn, NM = ts, FM = jd, jM = PM, DM = OM, LM = Fo, BM = MM, zM = rs, UM = Xt;
function VM(e, t, r) {
  t.length ? t = Gc(t, function(a) {
    return UM(a) ? function(i) {
      return NM(i, a.length === 1 ? a[0] : a);
    } : a;
  }) : t = [zM];
  var n = -1;
  t = Gc(t, LM(FM));
  var o = jM(e, function(a, i, s) {
    var l = Gc(t, function(c) {
      return c(a);
    });
    return { criteria: l, index: ++n, value: a };
  });
  return DM(o, function(a, i) {
    return BM(a, i, r);
  });
}
var qM = VM, WM = Yl, KM = qM, GM = uo, qh = Ud, HM = GM(function(e, t) {
  if (e == null)
    return [];
  var r = t.length;
  return r > 1 && qh(e, t[0], t[1]) ? t = [] : r > 2 && qh(t[0], t[1], t[2]) && (t = [t[0]]), KM(e, WM(t, 1), []);
}), w0 = HM, JM = Kd;
function YM(e, t) {
  return t = typeof t == "function" ? t : void 0, e && e.length ? JM(e, void 0, t) : [];
}
var Gd = YM, XM = uo, ZM = Ia, QM = Ud, e3 = za, C0 = Object.prototype, t3 = C0.hasOwnProperty, r3 = XM(function(e, t) {
  e = Object(e);
  var r = -1, n = t.length, o = n > 2 ? t[2] : void 0;
  for (o && QM(t[0], t[1], o) && (n = 1); ++r < n; )
    for (var a = t[r], i = e3(a), s = -1, l = i.length; ++s < l; ) {
      var c = i[s], u = e[c];
      (u === void 0 || ZM(u, C0[c]) && !t3.call(e, c)) && (e[c] = a[c]);
    }
  return e;
}), n3 = r3, o3 = Vl, a3 = qd, i3 = Wd, s3 = Vn, l3 = Fo, Wh = ql, c3 = Math.min;
function u3(e, t, r) {
  for (var n = r ? i3 : a3, o = e[0].length, a = e.length, i = a, s = Array(a), l = 1 / 0, c = []; i--; ) {
    var u = e[i];
    i && t && (u = s3(u, l3(t))), l = c3(u.length, l), s[i] = !r && (t || o >= 120 && u.length >= 120) ? new o3(i && u) : void 0;
  }
  u = e[0];
  var f = -1, d = s[0];
  e:
    for (; ++f < o && c.length < l; ) {
      var p = u[f], h = t ? t(p) : p;
      if (p = r || p !== 0 ? p : 0, !(d ? Wh(d, h) : n(c, h, r))) {
        for (i = a; --i; ) {
          var $ = s[i];
          if (!($ ? Wh($, h) : n(e[i], h, r)))
            continue e;
        }
        d && d.push(h), c.push(p);
      }
    }
  return c;
}
var E0 = u3, d3 = Xl;
function f3(e) {
  return d3(e) ? e : [];
}
var _0 = f3, p3 = Vn, h3 = E0, m3 = uo, g3 = _0, y3 = Jy, b3 = m3(function(e) {
  var t = y3(e), r = p3(e, g3);
  return t = typeof t == "function" ? t : void 0, t && r.pop(), r.length && r[0] === e[0] ? h3(r, void 0, t) : [];
}), x0 = b3, v3 = Un, $3 = Kr, S3 = "[object Boolean]";
function w3(e) {
  return e === !0 || e === !1 || $3(e) && v3(e) == S3;
}
var C3 = w3, Qr = Ld, E3 = w0, Hd = Zl, Kh = Gd, _3 = n3, x3 = x0, ml = Aa, Hc = C3, Gh = (e) => Array.isArray(e) ? e : [e], Vr = (e) => e === void 0, _s = (e) => ml(e) || Array.isArray(e) ? Object.keys(e) : [], aa = (e, t) => e.hasOwnProperty(t), ma = (e) => E3(Hd(e)), Hh = (e) => Vr(e) || Array.isArray(e) && e.length === 0, P3 = (e, t, r, n) => t && aa(t, r) && e && aa(e, r) && n(e[r], t[r]), Jc = (e, t) => Vr(e) && t === 0 || Vr(t) && e === 0 || Qr(e, t), k3 = (e, t) => Vr(e) && t === !1 || Vr(t) && e === !1 || Qr(e, t), Jh = (e) => Vr(e) || Qr(e, {}) || e === !0, xs = (e) => Vr(e) || Qr(e, {}), Yh = (e) => Vr(e) || ml(e) || e === !0 || e === !1;
function Xh(e, t) {
  return Hh(e) && Hh(t) ? !0 : Qr(ma(e), ma(t));
}
function O3(e, t) {
  return e = Gh(e), t = Gh(t), Qr(ma(e), ma(t));
}
function Ys(e, t, r, n) {
  var o = Hd(_s(e).concat(_s(t)));
  return xs(e) && xs(t) ? !0 : xs(e) && _s(t).length || xs(t) && _s(e).length ? !1 : o.every(function(a) {
    var i = e[a], s = t[a];
    return Array.isArray(i) && Array.isArray(s) ? Qr(ma(e), ma(t)) : Array.isArray(i) && !Array.isArray(s) || Array.isArray(s) && !Array.isArray(i) ? !1 : P3(e, t, a, n);
  });
}
function A3(e, t, r, n) {
  return ml(e) && ml(t) ? n(e, t) : Array.isArray(e) && Array.isArray(t) ? Ys(e, t, r, n) : Qr(e, t);
}
function Yc(e, t, r, n) {
  var o = Kh(e, n), a = Kh(t, n), i = x3(o, a, n);
  return i.length === Math.max(o.length, a.length);
}
var I3 = {
  title: Qr,
  uniqueItems: k3,
  minLength: Jc,
  minItems: Jc,
  minProperties: Jc,
  required: Xh,
  enum: Xh,
  type: O3,
  items: A3,
  anyOf: Yc,
  allOf: Yc,
  oneOf: Yc,
  properties: Ys,
  patternProperties: Ys,
  dependencies: Ys
}, R3 = [
  "properties",
  "patternProperties",
  "dependencies",
  "uniqueItems",
  "minLength",
  "minItems",
  "minProperties",
  "required"
], T3 = ["additionalProperties", "additionalItems", "contains", "propertyNames", "not"];
function ku(e, t, r) {
  if (r = _3(r, {
    ignore: []
  }), Jh(e) && Jh(t))
    return !0;
  if (!Yh(e) || !Yh(t))
    throw new Error("Either of the values are not a JSON schema.");
  if (e === t)
    return !0;
  if (Hc(e) && Hc(t))
    return e === t;
  if (e === void 0 && t === !1 || t === void 0 && e === !1 || Vr(e) && !Vr(t) || !Vr(e) && Vr(t))
    return !1;
  var n = Hd(Object.keys(e).concat(Object.keys(t)));
  if (r.ignore.length && (n = n.filter((a) => r.ignore.indexOf(a) === -1)), !n.length)
    return !0;
  function o(a, i) {
    return ku(a, i, r);
  }
  return n.every(function(a) {
    var i = e[a], s = t[a];
    if (T3.indexOf(a) !== -1)
      return ku(i, s, r);
    var l = I3[a];
    if (l || (l = Qr), Qr(i, s))
      return !0;
    if (R3.indexOf(a) === -1 && (!aa(e, a) && aa(t, a) || aa(e, a) && !aa(t, a)))
      return i === s;
    var c = l(i, s, a, o);
    if (!Hc(c))
      throw new Error("Comparer must return true or false");
    return c;
  });
}
var Jd = ku;
function M3(e) {
  return Object.prototype.toString.call(e) === "[object Array]";
}
var Yd = Array.isArray || M3;
function N3(e) {
  return (typeof e == "number" || Object.prototype.toString.call(e) === "[object Number]") && e.valueOf() === e.valueOf();
}
var F3 = N3, j3 = F3;
function D3(e) {
  return j3(e) && e % 1 === 0;
}
var L3 = D3, B3 = Yd, z3 = L3;
function U3(e) {
  var t;
  if (!B3(e) || (t = e.length, !t))
    return !1;
  for (var r = 0; r < t; r++)
    if (!z3(e[r]))
      return !1;
  return !0;
}
var P0 = U3;
function V3(e) {
  return typeof e == "function";
}
var k0 = V3, q3 = Yd, Zh = P0, W3 = k0, Ps = Math.pow(2, 31) - 1;
function Qh(e, t) {
  var r = 1, n;
  if (e === 0)
    return t;
  if (t === 0)
    return e;
  for (; e % 2 === 0 && t % 2 === 0; )
    e = e / 2, t = t / 2, r = r * 2;
  for (; e % 2 === 0; )
    e = e / 2;
  for (; t; ) {
    for (; t % 2 === 0; )
      t = t / 2;
    e > t && (n = t, t = e, e = n), t = t - e;
  }
  return r * e;
}
function em(e, t) {
  var r = 0, n;
  if (e === 0)
    return t;
  if (t === 0)
    return e;
  for (; !(e & 1) && !(t & 1); )
    e >>>= 1, t >>>= 1, r++;
  for (; !(e & 1); )
    e >>>= 1;
  for (; t; ) {
    for (; !(t & 1); )
      t >>>= 1;
    e > t && (n = t, t = e, e = n), t = t - e;
  }
  return e << r;
}
function K3() {
  var e = arguments.length, t, r, n, o, a, i, s;
  for (t = new Array(e), s = 0; s < e; s++)
    t[s] = arguments[s];
  if (Zh(t)) {
    if (e === 2)
      return a = t[0], i = t[1], a < 0 && (a = -a), i < 0 && (i = -i), a <= Ps && i <= Ps ? em(a, i) : Qh(a, i);
    n = t;
  } else if (q3(t[0]))
    if (e > 1) {
      if (n = t[0], r = t[1], !W3(r))
        throw new TypeError("gcd()::invalid input argument. Accessor must be a function. Value: `" + r + "`.");
    } else
      n = t[0];
  else throw new TypeError("gcd()::invalid input argument. Must provide an array of integers. Value: `" + t[0] + "`.");
  if (o = n.length, o < 2)
    return null;
  if (r) {
    for (a = new Array(o), s = 0; s < o; s++)
      a[s] = r(n[s], s);
    n = a;
  }
  if (e < 3 && !Zh(n))
    throw new TypeError("gcd()::invalid input argument. Accessed array values must be integers. Value: `" + n + "`.");
  for (s = 0; s < o; s++)
    a = n[s], a < 0 && (n[s] = -a);
  for (a = n[0], s = 1; s < o; s++)
    i = n[s], i <= Ps && a <= Ps ? a = em(a, i) : a = Qh(a, i);
  return a;
}
var G3 = K3, tm = G3, H3 = Yd, rm = P0, J3 = k0;
function Y3() {
  var e = arguments.length, t, r, n, o, a, i, s;
  for (t = new Array(e), s = 0; s < e; s++)
    t[s] = arguments[s];
  if (rm(t)) {
    if (e === 2)
      return a = t[0], i = t[1], a < 0 && (a = -a), i < 0 && (i = -i), a === 0 || i === 0 ? 0 : a / tm(a, i) * i;
    n = t;
  } else if (H3(t[0]))
    if (e > 1) {
      if (n = t[0], r = t[1], !J3(r))
        throw new TypeError("lcm()::invalid input argument. Accessor must be a function. Value: `" + r + "`.");
    } else
      n = t[0];
  else throw new TypeError("lcm()::invalid input argument. Must provide an array of integers. Value: `" + t[0] + "`.");
  if (o = n.length, o < 2)
    return null;
  if (r) {
    for (a = new Array(o), s = 0; s < o; s++)
      a[s] = r(n[s], s);
    n = a;
  }
  if (e < 3 && !rm(n))
    throw new TypeError("lcm()::invalid input argument. Accessed array values must be integers. Value: `" + n + "`.");
  for (s = 0; s < o; s++)
    a = n[s], a < 0 && (n[s] = -a);
  for (a = n[0], s = 1; s < o; s++) {
    if (i = n[s], a === 0 || i === 0)
      return 0;
    a = a / tm(a, i) * i;
  }
  return a;
}
var X3 = Y3, Z3 = zd, nm = Er;
function O0(e, t, r, n, o, a) {
  return nm(e) && nm(t) && (a.set(t, e), Z3(e, t, void 0, O0, a), a.delete(t)), e;
}
var Q3 = O0, e4 = zd, t4 = b0, r4 = t4(function(e, t, r, n) {
  e4(e, t, r, n);
}), n4 = r4, o4 = Zy, a4 = uo, i4 = Q3, s4 = n4, l4 = a4(function(e) {
  return e.push(void 0, i4), o4(s4, void 0, e);
}), c4 = l4, u4 = Vn, d4 = E0, f4 = uo, p4 = _0, h4 = f4(function(e) {
  var t = u4(e, p4);
  return t.length && t[0] === e[0] ? d4(t) : [];
}), m4 = h4;
function g4(e, t, r, n) {
  for (var o = r - 1, a = e.length; ++o < a; )
    if (n(e[o], t))
      return o;
  return -1;
}
var y4 = g4, b4 = Vn, v4 = v0, $4 = y4, S4 = Fo, w4 = Jl, C4 = Array.prototype, om = C4.splice;
function E4(e, t, r, n) {
  var o = n ? $4 : v4, a = -1, i = t.length, s = e;
  for (e === t && (t = w4(t)), r && (s = b4(e, S4(r))); ++a < i; )
    for (var l = 0, c = t[a], u = r ? r(c) : c; (l = o(s, u, l, n)) > -1; )
      s !== e && om.call(s, l, 1), om.call(e, l, 1);
  return e;
}
var _4 = E4, x4 = _4;
function P4(e, t) {
  return e && e.length && t && t.length ? x4(e, t) : e;
}
var k4 = P4, O4 = Od, A4 = Fd, I4 = d0, R4 = Xt;
function T4(e, t) {
  var r = R4(e) ? O4 : A4;
  return r(e, I4(t));
}
var Xd = T4;
const M4 = /* @__PURE__ */ pt(Xd);
var N4 = Vl, F4 = qd, j4 = Wd, D4 = Vn, L4 = Fo, B4 = ql, z4 = 200;
function U4(e, t, r, n) {
  var o = -1, a = F4, i = !0, s = e.length, l = [], c = t.length;
  if (!s)
    return l;
  r && (t = D4(t, L4(r))), n ? (a = j4, i = !1) : t.length >= z4 && (a = B4, i = !1, t = new N4(t));
  e:
    for (; ++o < s; ) {
      var u = e[o], f = r == null ? u : r(u);
      if (u = n || u !== 0 ? u : 0, i && f === f) {
        for (var d = c; d--; )
          if (t[d] === f)
            continue e;
        l.push(u);
      } else a(t, f, n) || l.push(u);
    }
  return l;
}
var V4 = U4, q4 = V4, W4 = uo, K4 = Xl, G4 = W4(function(e, t) {
  return K4(e) ? q4(e, t) : [];
}), H4 = G4;
const J4 = Td, Y4 = Vd, A0 = Aa, X4 = Zl, Z4 = Gd, Q4 = H4;
function eN(e) {
  for (const t in e)
    I0(e, t) && R0(e[t]) && delete e[t];
  return e;
}
const tN = (e) => X4(Y4(e.map(Zd))), rN = (e, t) => e.map((r) => r && r[t]), I0 = (e, t) => Object.prototype.hasOwnProperty.call(e, t), Zd = (e) => A0(e) || Array.isArray(e) ? Object.keys(e) : [], nN = (e) => e !== void 0, oN = (e) => A0(e) || e === !0 || e === !1, R0 = (e) => !Zd(e).length && e !== !1 && e !== !0, aN = (e, ...t) => Q4.apply(null, [e].concat(J4(t)));
var T0 = {
  allUniqueKeys: tN,
  deleteUndefinedProps: eN,
  getValues: rN,
  has: I0,
  isEmptySchema: R0,
  isSchema: oN,
  keys: Zd,
  notUndefined: nN,
  uniqWith: Z4,
  withoutArr: aN
};
const iN = Jd, sN = Xd, {
  allUniqueKeys: lN,
  deleteUndefinedProps: cN,
  getValues: uN,
  keys: ei,
  notUndefined: dN,
  uniqWith: fN,
  withoutArr: am
} = T0;
function pN(e) {
  sN(e, function(t, r) {
    t === !1 && delete e[r];
  });
}
function im(e, t) {
  return lN(e).reduce(function(n, o) {
    const a = uN(e, o), i = fN(a.filter(dN), iN);
    return n[o] = t(i, o), n;
  }, {});
}
var hN = {
  keywords: ["properties", "patternProperties", "additionalProperties"],
  resolver(e, t, r, n) {
    n.ignoreAdditionalProperties || (e.forEach(function(a) {
      const i = e.filter((u) => u !== a), s = ei(a.properties), c = ei(a.patternProperties).map((u) => new RegExp(u));
      i.forEach(function(u) {
        const f = ei(u.properties), d = f.filter((h) => c.some(($) => $.test(h)));
        am(f, s, d).forEach(function(h) {
          u.properties[h] = r.properties([
            u.properties[h],
            a.additionalProperties
          ], h);
        });
      });
    }), e.forEach(function(a) {
      const i = e.filter((l) => l !== a), s = ei(a.patternProperties);
      a.additionalProperties === !1 && i.forEach(function(l) {
        const c = ei(l.patternProperties);
        am(c, s).forEach((f) => delete l.patternProperties[f]);
      });
    }));
    const o = {
      additionalProperties: r.additionalProperties(e.map((a) => a.additionalProperties)),
      patternProperties: im(e.map((a) => a.patternProperties), r.patternProperties),
      properties: im(e.map((a) => a.properties), r.properties)
    };
    return o.additionalProperties === !1 && pN(o.properties), cN(o);
  }
};
const mN = Jd, gN = Xd, {
  allUniqueKeys: yN,
  deleteUndefinedProps: bN,
  has: vN,
  isSchema: M0,
  notUndefined: N0,
  uniqWith: $N
} = T0;
function SN(e) {
  gN(e, function(t, r) {
    t === !1 && e.splice(r, 1);
  });
}
function wN(e, t) {
  return e.map(function(r) {
    if (r)
      if (Array.isArray(r.items)) {
        const n = r.items[t];
        if (M0(n))
          return n;
        if (vN(r, "additionalItems"))
          return r.additionalItems;
      } else
        return r.items;
  });
}
function CN(e) {
  return e.map(function(t) {
    if (t)
      return Array.isArray(t.items) ? t.additionalItems : t.items;
  });
}
function EN(e, t, r) {
  return yN(r).reduce(function(o, a) {
    const i = wN(e, a), s = $N(i.filter(N0), mN);
    return o[a] = t(s, a), o;
  }, []);
}
var _N = {
  keywords: ["items", "additionalItems"],
  resolver(e, t, r) {
    const n = e.map((s) => s.items), o = n.filter(N0), a = {};
    o.every(M0) ? a.items = r.items(n) : a.items = EN(e, r.items, n);
    let i;
    return o.every(Array.isArray) ? i = e.map((s) => s.additionalItems) : o.some(Array.isArray) && (i = CN(e)), i && (a.additionalItems = r.additionalItems(i)), a.additionalItems === !1 && Array.isArray(a.items) && SN(a.items), bN(a);
  }
};
const F0 = $0, gl = Jd, xN = X3, PN = c4, j0 = Td, Qd = Vd, kN = m4, ON = x0, Ou = Ld, ga = Aa, AN = k4, D0 = w0, ef = Zl, sa = Gd, L0 = hN, B0 = _N, ks = (e, t) => e.indexOf(t) !== -1, IN = (e) => ga(e) || e === !0 || e === !1, RN = (e) => e === !1, z0 = (e) => e === !0, Ql = (e, t, r) => r(e), U0 = (e) => D0(ef(Qd(e))), yl = (e) => e !== void 0, V0 = (e) => ef(Qd(e.map(DN))), Ua = (e) => e[0], TN = (e) => U0(e), ns = (e) => Math.max.apply(Math, e), os = (e) => Math.min.apply(Math, e), MN = (e) => e.some(z0), NN = (e) => sa(j0(e), Ou);
function FN(e) {
  return function(t, r) {
    return gl({
      [e]: t
    }, { [e]: r });
  };
}
function q0(e) {
  let { allOf: t = [], ...r } = e;
  return r = ga(e) ? r : e, [r, ...t.map(q0)];
}
function W0(e, t) {
  return e.map((r) => r && r[t]);
}
function jN(e, t) {
  return e.map(function(r, n) {
    try {
      return t(r, n);
    } catch {
      return;
    }
  }).filter(yl);
}
function DN(e) {
  return ga(e) || Array.isArray(e) ? Object.keys(e) : [];
}
function Au(e, t) {
  if (t = t || [], !e.length)
    return t;
  const r = e.slice(0).shift(), n = e.slice(1);
  return t.length ? Au(n, j0(t.map((o) => r.map((a) => [a].concat(o))))) : Au(n, r.map((o) => o));
}
function K0(e, t) {
  let r;
  try {
    r = e.map(function(n) {
      return JSON.stringify(n, null, 2);
    }).join(`
`);
  } catch {
    r = e.join(", ");
  }
  throw new Error('Could not resolve values for path:"' + t.join(".") + `". They are probably incompatible. Values: 
` + r);
}
function LN(e, t, r, n, o, a) {
  if (e.length) {
    const i = o.complexResolvers[t];
    if (!i || !i.resolver)
      throw new Error("No resolver found for " + t);
    const s = r.map((f) => e.reduce((d, p) => (f[p] !== void 0 && (d[p] = f[p]), d), {})), l = sa(s, gl), c = i.keywords.reduce((f, d) => ({
      ...f,
      [d]: (p, h = []) => n(p, null, a.concat(d, h))
    }), {}), u = i.resolver(l, a.concat(t), c, o);
    return ga(u) || K0(l, a.concat(t)), u;
  }
}
function BN(e) {
  return { required: e };
}
const zN = ["properties", "patternProperties", "definitions", "dependencies"], UN = ["anyOf", "oneOf"], VN = [
  "additionalProperties",
  "additionalItems",
  "contains",
  "propertyNames",
  "not",
  "items"
], ct = {
  type(e) {
    if (e.some(Array.isArray)) {
      const t = e.map(function(n) {
        return Array.isArray(n) ? n : [n];
      }), r = kN.apply(null, t);
      if (r.length === 1)
        return r[0];
      if (r.length > 1)
        return ef(r);
    }
  },
  dependencies(e, t, r) {
    return V0(e).reduce(function(o, a) {
      const i = W0(e, a);
      let s = sa(i.filter(yl), Ou);
      const l = s.filter(Array.isArray);
      if (l.length) {
        if (l.length === s.length)
          o[a] = U0(s);
        else {
          const c = s.filter(IN), u = l.map(BN);
          o[a] = r(c.concat(u), a);
        }
        return o;
      }
      return s = sa(s, gl), o[a] = r(s, a), o;
    }, {});
  },
  oneOf(e, t, r) {
    const n = Au(F0(e)), o = jN(n, r), a = sa(o, gl);
    if (a.length)
      return a;
  },
  not(e) {
    return { anyOf: e };
  },
  pattern(e) {
    return e.map((t) => "(?=" + t + ")").join("");
  },
  multipleOf(e) {
    let t = e.slice(0), r = 1;
    for (; t.some((n) => !Number.isInteger(n)); )
      t = t.map((n) => n * 10), r = r * 10;
    return xN(t) / r;
  },
  enum(e) {
    const t = ON.apply(null, e.concat(Ou));
    if (t.length)
      return D0(t);
  }
};
ct.$id = Ua;
ct.$ref = Ua;
ct.$schema = Ua;
ct.additionalItems = Ql;
ct.additionalProperties = Ql;
ct.anyOf = ct.oneOf;
ct.contains = Ql;
ct.default = Ua;
ct.definitions = ct.dependencies;
ct.description = Ua;
ct.examples = NN;
ct.exclusiveMaximum = os;
ct.exclusiveMinimum = ns;
ct.items = B0;
ct.maximum = os;
ct.maxItems = os;
ct.maxLength = os;
ct.maxProperties = os;
ct.minimum = ns;
ct.minItems = ns;
ct.minLength = ns;
ct.minProperties = ns;
ct.properties = L0;
ct.propertyNames = Ql;
ct.required = TN;
ct.title = Ua;
ct.uniqueItems = MN;
const qN = {
  properties: L0,
  items: B0
};
function tf(e, t, r) {
  t = PN(t, {
    ignoreAdditionalProperties: !1,
    resolvers: ct,
    complexResolvers: qN,
    deep: !0
  });
  const n = Object.entries(t.complexResolvers);
  function o(s, l, c) {
    s = F0(s.filter(yl)), c = c || [];
    const u = ga(l) ? l : {};
    if (!s.length)
      return;
    if (s.some(RN))
      return !1;
    if (s.every(z0))
      return !0;
    s = s.filter(ga);
    const f = V0(s);
    if (t.deep && ks(f, "allOf"))
      return tf({
        allOf: s
      }, t);
    const d = n.map(([p, h]) => f.filter(($) => h.keywords.includes($)));
    return d.forEach((p) => AN(f, p)), f.forEach(function(p) {
      const h = W0(s, p), $ = sa(h.filter(yl), FN(p));
      if ($.length === 1 && ks(UN, p))
        u[p] = $[0].map((b) => o([b], b));
      else if ($.length === 1 && !ks(zN, p) && !ks(VN, p))
        u[p] = $[0];
      else {
        const b = t.resolvers[p] || t.resolvers.defaultResolver;
        if (!b) throw new Error("No resolver found for key " + p + ". You can provide a resolver for this keyword in the options, or provide a default resolver.");
        const g = (y, S = []) => o(y, null, c.concat(p, S));
        u[p] = b($, c.concat(p), g, t), u[p] === void 0 ? K0($, c.concat(p)) : u[p] === void 0 && delete u[p];
      }
    }), n.reduce((p, [h, $], b) => ({
      ...p,
      ...LN(d[b], h, s, o, t, c)
    }), u);
  }
  const a = Qd(q0(e));
  return o(a);
}
tf.options = {
  resolvers: ct
};
var WN = tf;
const KN = /* @__PURE__ */ pt(WN);
function ya(e) {
  let t;
  const r = xe(e, "discriminator.propertyName", void 0);
  return Nd(r) ? t = r : r !== void 0 && console.warn(`Expecting discriminator to be a string, got "${typeof r}" instead`), t;
}
function Ti(e) {
  return Array.isArray(e) ? "array" : typeof e == "string" ? "string" : e == null ? "null" : typeof e == "boolean" ? "boolean" : isNaN(e) ? typeof e == "object" ? "object" : "string" : "number";
}
var GN = Yl, HN = uo, JN = Kd, YN = Xl, XN = HN(function(e) {
  return JN(GN(e, 1, YN, !0));
}), ZN = XN;
const QN = /* @__PURE__ */ pt(ZN);
function so(e) {
  let { type: t } = e;
  return !t && e.const ? Ti(e.const) : !t && e.enum ? "string" : !t && (e.properties || e.additionalProperties) ? "object" : (Array.isArray(t) && (t.length === 2 && t.includes("null") ? t = t.find((r) => r !== "null") : t = t[0]), t);
}
function jn(e, t) {
  const r = Object.assign({}, e);
  return Object.keys(t).reduce((n, o) => {
    const a = e ? e[o] : {}, i = t[o];
    return e && o in e && St(i) ? n[o] = jn(a, i) : e && t && (so(e) === "object" || so(t) === "object") && o === w$ && Array.isArray(a) && Array.isArray(i) ? n[o] = QN(a, i) : n[o] = i, n;
  }, r);
}
function Ir(e, t, r = {}, n, o) {
  return mn(e, t, r, n, void 0, void 0, o)[0];
}
function eF(e, t, r, n, o, a, i) {
  const { if: s, then: l, else: c, ...u } = t, f = e.isValid(s, a || {}, r);
  let d = [u], p = [];
  if (n)
    l && typeof l != "boolean" && (p = p.concat(mn(e, l, r, a, n, o, i))), c && typeof c != "boolean" && (p = p.concat(mn(e, c, r, a, n, o, i)));
  else {
    const h = f ? l : c;
    h && typeof h != "boolean" && (p = p.concat(mn(e, h, r, a, n, o, i)));
  }
  return p.length && (d = p.map((h) => jn(u, h))), d.flatMap((h) => mn(e, h, r, a, n, o, i));
}
function G0(e) {
  return e.reduce(
    (r, n) => n.length > 1 ? n.flatMap((o) => f0(r.length, (a) => [...r[a]].concat(o))) : (r.forEach((o) => o.push(n[0])), r),
    [[]]
    // Start with an empty list
  );
}
function tF(e, t, r, n, o, a, i) {
  const s = H0(e, t, r, n, o, a);
  if (s.length > 1 || s[0] !== t)
    return s;
  if (Nl in t)
    return J0(e, t, r, n, o, a).flatMap((c) => mn(e, c, r, a, n, o, i));
  if (Yi in t && Array.isArray(t.allOf)) {
    const l = t.allOf.map((u) => mn(e, u, r, a, n, o, i));
    return G0(l).map((u) => ({ ...t, allOf: u }));
  }
  return [t];
}
function H0(e, t, r, n, o, a, i) {
  const s = Mi(t, r, o);
  return s !== t ? mn(e, s, r, a, n, o, i) : [t];
}
function Mi(e, t, r) {
  if (!St(e))
    return e;
  let n = e;
  if (Ht in n) {
    const { $ref: o, ...a } = n;
    if (r.includes(o))
      return n;
    r.push(o), n = { ...n0(o, t), ...a };
  }
  if (Mt in n) {
    const o = [], a = qR(n[Mt], (i, s, l) => {
      const c = [...r];
      i[l] = Mi(s, t, c), o.push(c);
    }, {});
    DT(r, vM(UT(o))), n = { ...n, [Mt]: a };
  }
  return eo in n && !Array.isArray(n.items) && typeof n.items != "boolean" && (n = {
    ...n,
    items: Mi(n.items, t, r)
  }), Po(e, n) ? e : n;
}
function rF(e, t, r, n, o) {
  const a = {
    ...t,
    properties: { ...t.properties }
  }, i = n && St(n) ? n : {};
  return Object.keys(i).forEach((s) => {
    if (s in a.properties)
      return;
    let l = {};
    typeof a.additionalProperties != "boolean" ? Ht in a.additionalProperties ? l = Ir(e, { $ref: xe(a.additionalProperties, [Ht]) }, r, i, o) : "type" in a.additionalProperties ? l = { ...a.additionalProperties } : hn in a.additionalProperties || zr in a.additionalProperties ? l = {
      type: "object",
      ...a.additionalProperties
    } : l = { type: Ti(xe(i, [s])) } : l = { type: Ti(xe(i, [s])) }, a.properties[s] = l, er(a.properties, [s, ka], !0);
  }), a;
}
function mn(e, t, r, n, o = !1, a = [], i) {
  return St(t) ? tF(e, t, r, o, a, n, i).flatMap((l) => {
    var c;
    let u = l;
    if ($$ in u)
      return eF(e, u, r, o, a, n, i);
    if (Yi in u) {
      if (o) {
        const { allOf: d, ...p } = u;
        return [...d, p];
      }
      try {
        const d = [], p = [];
        (c = u.allOf) === null || c === void 0 || c.forEach((h) => {
          typeof h == "object" && h.contains ? d.push(h) : p.push(h);
        }), d.length && (u = { ...u, allOf: p }), u = i ? i(u) : KN(u, {
          deep: !1
        }), d.length && (u.allOf = d);
      } catch (d) {
        console.warn(`could not merge subschemas in allOf:
`, d);
        const { allOf: p, ...h } = u;
        return h;
      }
    }
    return Su in u && u.additionalProperties !== !1 ? rF(e, u, r, n, i) : u;
  }) : [{}];
}
function nF(e, t, r, n, o) {
  let a;
  const { oneOf: i, anyOf: s, ...l } = t;
  if (Array.isArray(i) ? a = i : Array.isArray(s) && (a = s), a) {
    const c = o === void 0 && n ? {} : o, u = ya(t);
    a = a.map((d) => Mi(d, r, []));
    const f = Dd(e, c, a, r, u);
    if (n)
      return a.map((d) => jn(l, d));
    t = jn(l, a[f]);
  }
  return [t];
}
function J0(e, t, r, n, o, a, i) {
  const { dependencies: s, ...l } = t;
  return nF(e, l, r, n, a).flatMap((u) => Y0(e, s, u, r, n, o, a, i));
}
function Y0(e, t, r, n, o, a, i, s) {
  let l = [r];
  for (const c in t) {
    if (!o && xe(i, [c]) === void 0 || r.properties && !(c in r.properties))
      continue;
    const [u, f] = Md(c, t);
    return Array.isArray(f) ? l[0] = oF(r, f) : St(f) && (l = aF(e, r, n, c, f, o, a, i, s)), l.flatMap((d) => Y0(e, u, d, n, o, a, i, s));
  }
  return l;
}
function oF(e, t) {
  if (!t)
    return e;
  const r = Array.isArray(e.required) ? Array.from(/* @__PURE__ */ new Set([...e.required, ...t])) : t;
  return { ...e, required: r };
}
function aF(e, t, r, n, o, a, i, s, l) {
  return mn(e, o, r, s, a, i, l).flatMap((u) => {
    const { oneOf: f, ...d } = u;
    if (t = jn(t, d), f === void 0)
      return t;
    const p = f.map(($) => typeof $ == "boolean" || !(Ht in $) ? [$] : H0(e, $, r, a, i, s));
    return G0(p).flatMap(($) => iF(e, t, r, n, $, a, i, s, l));
  });
}
function iF(e, t, r, n, o, a, i, s, l) {
  const c = o.filter((u) => {
    if (typeof u == "boolean" || !u || !u.properties)
      return !1;
    const { [n]: f } = u.properties;
    if (f) {
      const d = {
        type: "object",
        properties: {
          [n]: f
        }
      };
      return e.isValid(d, s, r) || a;
    }
    return !1;
  });
  return !a && c.length !== 1 ? (console.warn("ignoring oneOf in dependencies because there isn't exactly one subschema that is valid"), [t]) : c.flatMap((u) => {
    const f = u, [d] = Md(n, f.properties), p = { ...f, properties: d };
    return mn(e, p, r, s, a, i, l).map(($) => jn(t, $));
  });
}
const sF = {
  type: "object",
  $id: S$,
  properties: {
    __not_really_there__: {
      type: "number"
    }
  }
};
function Iu(e, t, r, n, o) {
  let a = 0;
  return r && (Ur(r.properties) ? a += VI(r.properties, (i, s, l) => {
    const c = xe(n, l);
    if (typeof s == "boolean")
      return i;
    if (fr(s, Ht)) {
      const u = Ir(e, s, t, c, o);
      return i + Iu(e, t, u, c || {}, o);
    }
    if ((fr(s, zr) || fr(s, hn)) && c) {
      const u = fr(s, zr) ? zr : hn, f = ya(s);
      return i + Ni(e, t, c, xe(s, u), -1, f, o);
    }
    if (s.type === "object")
      return Ur(c) && (i += 1), i + Iu(e, t, s, c, o);
    if (s.type === Ti(c)) {
      let u = i + 1;
      return s.default ? u += c === s.default ? 1 : -1 : s.const && (u += c === s.const ? 1 : -1), u;
    }
    return i;
  }, 0) : Nd(r.type) && r.type === Ti(n) && (a += 1)), a;
}
function Ni(e, t, r, n, o = -1, a, i) {
  const s = n.map((d) => Mi(d, t, [])), l = p0(r, n, a);
  if (a0(l))
    return l;
  const c = s.reduce((d, p, h) => (Dd(e, r, [sF, p], t, a) === 1 && d.push(h), d), []);
  if (c.length === 1)
    return c[0];
  c.length || f0(s.length, (d) => c.push(d));
  const u = /* @__PURE__ */ new Set(), { bestIndex: f } = c.reduce((d, p) => {
    const { bestScore: h } = d, $ = s[p], b = Iu(e, t, $, r, i);
    return u.add(b), b > h ? { bestIndex: p, bestScore: b } : d;
  }, { bestIndex: o, bestScore: 0 });
  return u.size === 1 && o >= 0 ? o : f;
}
function Ru(e) {
  return Array.isArray(e.items) && e.items.length > 0 && e.items.every((t) => St(t));
}
function Fi(e, t, r = !1, n = !1) {
  if (Array.isArray(t)) {
    const o = Array.isArray(e) ? e : [], a = t.map((i, s) => o[s] ? Fi(o[s], i, r, n) : i);
    return r && a.length < o.length && a.push(...o.slice(a.length)), a;
  }
  if (St(t)) {
    const o = Object.assign({}, e);
    return Object.keys(t).reduce((a, i) => (a[i] = Fi(e ? xe(e, i) : {}, xe(t, i), r, n), a), o);
  }
  return n && t === void 0 ? e : t;
}
function to(e, t, r = !1) {
  return Object.keys(t).reduce((n, o) => {
    const a = e ? e[o] : {}, i = t[o];
    if (e && o in e && St(i))
      n[o] = to(a, i, r);
    else if (r && Array.isArray(a) && Array.isArray(i)) {
      let s = i;
      r === "preventDuplicates" && (s = i.reduce((l, c) => (a.includes(c) || l.push(c), l), [])), n[o] = a.concat(s);
    } else
      n[o] = i;
    return n;
  }, Object.assign({}, e));
}
function lF(e) {
  return Array.isArray(e.enum) && e.enum.length === 1 || ha in e;
}
function X0(e, t, r = {}, n) {
  const o = Ir(e, t, r, void 0, n), a = o.oneOf || o.anyOf;
  return Array.isArray(o.enum) ? !0 : Array.isArray(a) ? a.every((i) => typeof i != "boolean" && lF(i)) : !1;
}
function rf(e, t, r, n) {
  return !t.uniqueItems || !t.items || typeof t.items == "boolean" ? !1 : X0(e, t.items, r, n);
}
const cF = ["string", "number", "integer", "boolean", "null"];
var ba;
(function(e) {
  e[e.Ignore = 0] = "Ignore", e[e.Invert = 1] = "Invert", e[e.Fallback = 2] = "Fallback";
})(ba || (ba = {}));
function Xc(e, t = ba.Ignore, r = -1) {
  if (r >= 0) {
    if (Array.isArray(e.items) && r < e.items.length) {
      const n = e.items[r];
      if (typeof n != "boolean")
        return n;
    }
  } else if (e.items && !Array.isArray(e.items) && typeof e.items != "boolean")
    return e.items;
  return t !== ba.Ignore && St(e.additionalItems) ? e.additionalItems : {};
}
function sm(e, t, r, n, o, a = [], i = {}, s = !1) {
  const { emptyObjectFields: l = "populateAllDefaults" } = i;
  if (n || s)
    e[t] = r;
  else if (l !== "skipDefaults")
    if (St(r)) {
      const c = o === void 0 ? a.includes(t) : o;
      l === "skipEmptyDefaults" ? io(r) || (e[t] = r) : (!io(r) || a.includes(t)) && (c || l !== "populateRequiredDefaults") && (e[t] = r);
    } else // Store computedDefault if it's a defined primitive (e.g., true) and satisfies certain conditions
    // Condition 1: computedDefault is not undefined
    // Condition 2: If emptyObjectFields is 'populateAllDefaults' or 'skipEmptyDefaults) or if the key is a required field
    r !== void 0 && (l === "populateAllDefaults" || l === "skipEmptyDefaults" || a.includes(t)) && (e[t] = r);
}
function ro(e, t, r = {}) {
  const { parentDefaults: n, rawFormData: o, rootSchema: a = {}, includeUndefinedValues: i = !1, _recurseList: s = [], experimental_defaultFormStateBehavior: l = void 0, experimental_customMergeAllOf: c = void 0, required: u } = r, f = St(o) ? o : {}, d = St(t) ? t : {};
  let p = n, h = null, $ = l, b = s;
  if (d[ha] && (l == null ? void 0 : l.constAsDefaults) !== "never")
    p = d.const;
  else if (St(p) && St(d.default))
    p = to(p, d.default);
  else if (b$ in d)
    p = d.default;
  else if (Ht in d) {
    const y = d[Ht];
    s.includes(y) || (b = s.concat(y), h = n0(y, a));
  } else if (Nl in d) {
    const y = {
      ...lm(e, d, r, p),
      ...f
    };
    h = J0(e, d, a, !1, [], y, c)[0];
  } else if (Ru(d))
    p = d.items.map((y, S) => ro(e, y, {
      rootSchema: a,
      includeUndefinedValues: i,
      _recurseList: s,
      experimental_defaultFormStateBehavior: l,
      experimental_customMergeAllOf: c,
      parentDefaults: Array.isArray(n) ? n[S] : void 0,
      rawFormData: f,
      required: u
    }));
  else if (zr in d) {
    const { oneOf: y, ...S } = d;
    if (y.length === 0)
      return;
    const m = ya(d), { type: w = "null" } = S;
    !Array.isArray(w) && cF.includes(w) && ($ == null ? void 0 : $.constAsDefaults) === "skipOneOf" && ($ = { ...$, constAsDefaults: "never" }), h = y[Ni(e, a, io(f) ? void 0 : f, y, 0, m, c)], h = jn(S, h);
  } else if (hn in d) {
    const { anyOf: y, ...S } = d;
    if (y.length === 0)
      return;
    const m = ya(d);
    h = y[Ni(e, a, io(f) ? void 0 : f, y, 0, m, c)], h = jn(S, h);
  }
  if (h)
    return ro(e, h, {
      rootSchema: a,
      includeUndefinedValues: i,
      _recurseList: b,
      experimental_defaultFormStateBehavior: $,
      experimental_customMergeAllOf: c,
      parentDefaults: p,
      rawFormData: f,
      required: u
    });
  p === void 0 && (p = d.default);
  const g = lm(e, d, r, p);
  return g ?? p;
}
function uF(e, t, { rawFormData: r, rootSchema: n = {}, includeUndefinedValues: o = !1, _recurseList: a = [], experimental_defaultFormStateBehavior: i = void 0, experimental_customMergeAllOf: s = void 0, required: l } = {}, c) {
  {
    const u = St(r) ? r : {}, f = t, d = (i == null ? void 0 : i.allOf) === "populateDefaults" && Yi in f ? Ir(e, f, n, u, s) : f, p = d[ha], h = Object.keys(d.properties || {}).reduce(($, b) => {
      var g;
      const y = xe(d, [Mt, b]), S = St(p) && p[b] !== void 0, m = (St(y) && ha in y || S) && (i == null ? void 0 : i.constAsDefaults) !== "never", w = ro(e, y, {
        rootSchema: n,
        _recurseList: a,
        experimental_defaultFormStateBehavior: i,
        experimental_customMergeAllOf: s,
        includeUndefinedValues: o === !0,
        parentDefaults: xe(c, [b]),
        rawFormData: xe(u, [b]),
        required: (g = d.required) === null || g === void 0 ? void 0 : g.includes(b)
      });
      return sm($, b, w, o, l, d.required, i, m), $;
    }, {});
    if (d.additionalProperties) {
      const $ = St(d.additionalProperties) ? d.additionalProperties : {}, b = /* @__PURE__ */ new Set();
      St(c) && Object.keys(c).filter((y) => !d.properties || !d.properties[y]).forEach((y) => b.add(y));
      const g = [];
      Object.keys(u).filter((y) => !d.properties || !d.properties[y]).forEach((y) => {
        b.add(y), g.push(y);
      }), b.forEach((y) => {
        var S;
        const m = ro(e, $, {
          rootSchema: n,
          _recurseList: a,
          experimental_defaultFormStateBehavior: i,
          experimental_customMergeAllOf: s,
          includeUndefinedValues: o === !0,
          parentDefaults: xe(c, [y]),
          rawFormData: xe(u, [y]),
          required: (S = d.required) === null || S === void 0 ? void 0 : S.includes(y)
        });
        sm(h, y, m, o, l, g);
      });
    }
    return h;
  }
}
function dF(e, t, { rawFormData: r, rootSchema: n = {}, _recurseList: o = [], experimental_defaultFormStateBehavior: a = void 0, experimental_customMergeAllOf: i = void 0, required: s } = {}, l) {
  var c, u;
  const f = t, d = (c = a == null ? void 0 : a.arrayMinItems) !== null && c !== void 0 ? c : {}, { populate: p, mergeExtraDefaults: h } = d, $ = p === "never", b = p === "requiredOnly", g = p === "all" || !$ && !b, y = (u = d == null ? void 0 : d.computeSkipPopulate) !== null && u !== void 0 ? u : () => !1, m = (a == null ? void 0 : a.emptyObjectFields) === "skipEmptyDefaults" ? void 0 : [];
  if (Array.isArray(l) && (l = l.map((T, F) => {
    const D = Xc(f, ba.Fallback, F);
    return ro(e, D, {
      rootSchema: n,
      _recurseList: o,
      experimental_defaultFormStateBehavior: a,
      experimental_customMergeAllOf: i,
      parentDefaults: T,
      required: s
    });
  })), Array.isArray(r)) {
    const T = Xc(f);
    if ($)
      l = r;
    else {
      const F = r.map((z, L) => ro(e, T, {
        rootSchema: n,
        _recurseList: o,
        experimental_defaultFormStateBehavior: a,
        experimental_customMergeAllOf: i,
        rawFormData: z,
        parentDefaults: xe(l, [L]),
        required: s
      }));
      l = Fi(l, F, (b && s || g) && h);
    }
  }
  if ((St(f) && ha in f && (a == null ? void 0 : a.constAsDefaults) !== "never") === !1) {
    if ($)
      return l ?? m;
    if (b && !s)
      return l || void 0;
  }
  const v = Array.isArray(l) ? l.length : 0;
  if (!f.minItems || rf(e, f, n, i) || y(e, f, n) || f.minItems <= v)
    return l || m;
  const E = l || [], I = Xc(f, ba.Invert), R = I.default, C = new Array(f.minItems - v).fill(ro(e, I, {
    parentDefaults: R,
    rootSchema: n,
    _recurseList: o,
    experimental_defaultFormStateBehavior: a,
    experimental_customMergeAllOf: i,
    required: s
  }));
  return E.concat(C);
}
function lm(e, t, r = {}, n) {
  switch (so(t)) {
    case "object":
      return uF(e, t, r, n);
    case "array":
      return dF(e, t, r, n);
  }
}
function Z0(e, t, r, n, o = !1, a, i) {
  if (!St(t))
    throw new Error("Invalid schema: " + t);
  const s = Ir(e, t, n, r, i), l = ro(e, s, {
    rootSchema: n,
    includeUndefinedValues: o,
    experimental_defaultFormStateBehavior: a,
    experimental_customMergeAllOf: i,
    rawFormData: r
  });
  if (r == null || typeof r == "number" && isNaN(r))
    return l;
  const { mergeDefaultsIntoFormData: c, arrayMinItems: u = {} } = a || {}, { mergeExtraDefaults: f } = u, d = c === "useDefaultIfFormDataUndefined";
  return St(r) || Array.isArray(r) ? Fi(l, r, f, d) : r;
}
function Q0(e = {}) {
  return (
    // TODO: Remove the `&& uiSchema['ui:widget'] !== 'hidden'` once we support hidden widgets for arrays.
    // https://rjsf-team.github.io/react-jsonschema-form/docs/usage/widgets/#hidden-widgets
    "widget" in Qe(e) && Qe(e).widget !== "hidden"
  );
}
function eb(e, t, r = {}, n, o) {
  if (r[yd] === "files")
    return !0;
  if (t.items) {
    const a = Ir(e, t.items, n, void 0, o);
    return a.type === "string" && a.format === "data-url";
  }
  return !1;
}
function fF(e, t, r = {}, n, o, a) {
  const i = Qe(r, o), { label: s = !0 } = i;
  let l = !!s;
  const c = so(t);
  return c === "array" && (l = rf(e, t, n, a) || eb(e, t, r, n, a) || Q0(r)), c === "object" && (l = !1), c === "boolean" && !r[yd] && (l = !1), r[C$] && (l = !1), l;
}
function pF(e, t, r) {
  if (!r)
    return t;
  const { errors: n, errorSchema: o } = t;
  let a = e.toErrorList(r), i = r;
  return io(o) || (i = to(o, r, !0), a = [...n].concat(a)), { errorSchema: i, errors: a };
}
const Vo = Symbol("no Value");
function Tu(e, t, r, n, o = {}, a) {
  let i;
  if (fr(r, Mt)) {
    const s = {};
    if (fr(n, Mt)) {
      const u = xe(n, Mt, {});
      Object.keys(u).forEach((f) => {
        fr(o, f) && (s[f] = void 0);
      });
    }
    const l = Object.keys(xe(r, Mt, {})), c = {};
    l.forEach((u) => {
      const f = xe(o, u);
      let d = xe(n, [Mt, u], {}), p = xe(r, [Mt, u], {});
      fr(d, Ht) && (d = Ir(e, d, t, f, a)), fr(p, Ht) && (p = Ir(e, p, t, f, a));
      const h = xe(d, "type"), $ = xe(p, "type");
      if (!h || h === $)
        if (fr(s, u) && delete s[u], $ === "object" || $ === "array" && Array.isArray(f)) {
          const b = Tu(e, t, p, d, f, a);
          (b !== void 0 || $ === "array") && (c[u] = b);
        } else {
          const b = xe(p, "default", Vo), g = xe(d, "default", Vo);
          b !== Vo && b !== f && (g === f ? s[u] = b : xe(p, "readOnly") === !0 && (s[u] = void 0));
          const y = xe(p, "const", Vo), S = xe(d, "const", Vo);
          y !== Vo && y !== f && (s[u] = S === f ? y : void 0);
        }
    }), i = {
      ...typeof o == "string" || Array.isArray(o) ? void 0 : o,
      ...s,
      ...c
    };
  } else if (xe(n, "type") === "array" && xe(r, "type") === "array" && Array.isArray(o)) {
    let s = xe(n, "items"), l = xe(r, "items");
    if (typeof s == "object" && typeof l == "object" && !Array.isArray(s) && !Array.isArray(l)) {
      fr(s, Ht) && (s = Ir(e, s, t, o, a)), fr(l, Ht) && (l = Ir(e, l, t, o, a));
      const c = xe(s, "type"), u = xe(l, "type");
      if (!c || c === u) {
        const f = xe(r, "maxItems", -1);
        u === "object" ? i = o.reduce((d, p) => {
          const h = Tu(e, t, l, s, p, a);
          return h !== void 0 && (f < 0 || d.length < f) && d.push(h), d;
        }, []) : i = f > 0 && o.length > f ? o.slice(0, f) : o;
      }
    } else typeof s == "boolean" && typeof l == "boolean" && s === l && (i = o);
  }
  return i;
}
function Xs(e, t, r, n, o, a, i, s = [], l) {
  if (Ht in t || Nl in t || Yi in t) {
    const f = Ir(e, t, a, i, l);
    if (s.findIndex((p) => Po(p, f)) === -1)
      return Xs(e, f, r, n, o, a, i, s.concat(f), l);
  }
  if (eo in t && !xe(t, [eo, Ht]))
    return Xs(e, xe(t, eo), r, n, o, a, i, s, l);
  const u = { $id: o || r };
  if (so(t) === "object" && Mt in t)
    for (const f in t.properties) {
      const d = xe(t, [Mt, f]), p = u[Zn] + n + f;
      u[f] = Xs(
        e,
        St(d) ? d : {},
        r,
        n,
        p,
        a,
        // It's possible that formData is not an object -- this can happen if an
        // array item has just been added, but not populated with data yet
        xe(i, [f]),
        s,
        l
      );
    }
  return u;
}
function hF(e, t, r, n, o, a = "root", i = "_", s) {
  return Xs(e, t, a, i, r, n, o, void 0, s);
}
function bo(e, t, r, n, o, a = [], i) {
  if (Ht in t || Nl in t || Yi in t) {
    const l = Ir(e, t, n, o, i);
    if (a.findIndex((u) => Po(u, l)) === -1)
      return bo(e, l, r, n, o, a.concat(l), i);
  }
  let s = {
    [Hs]: r.replace(/^\./, "")
  };
  if (zr in t || hn in t) {
    const l = zr in t ? t.oneOf : t.anyOf, c = ya(t), u = Ni(e, n, o, l, 0, c, i), f = l[u];
    s = {
      ...s,
      ...bo(e, f, r, n, o, a, i)
    };
  }
  if (Su in t && t[Su] !== !1 && er(s, gd, !0), eo in t && Array.isArray(o)) {
    const { items: l, additionalItems: c } = t;
    Array.isArray(l) ? o.forEach((u, f) => {
      l[f] ? s[f] = bo(e, l[f], `${r}.${f}`, n, u, a, i) : c ? s[f] = bo(e, c, `${r}.${f}`, n, u, a, i) : console.warn(`Unable to generate path schema for "${r}.${f}". No schema defined for it`);
    }) : o.forEach((u, f) => {
      s[f] = bo(e, l, `${r}.${f}`, n, u, a, i);
    });
  } else if (Mt in t)
    for (const l in t.properties) {
      const c = xe(t, [Mt, l]);
      s[l] = bo(
        e,
        c,
        `${r}.${l}`,
        n,
        // It's possible that formData is not an object -- this can happen if an
        // array item has just been added, but not populated with data yet
        xe(o, [l]),
        a,
        i
      );
    }
  return s;
}
function mF(e, t, r = "", n, o, a) {
  return bo(e, t, r, n, o, void 0, a);
}
class gF {
  /** Constructs the `SchemaUtils` instance with the given `validator` and `rootSchema` stored as instance variables
   *
   * @param validator - An implementation of the `ValidatorType` interface that will be forwarded to all the APIs
   * @param rootSchema - The root schema that will be forwarded to all the APIs
   * @param experimental_defaultFormStateBehavior - Configuration flags to allow users to override default form state behavior
   * @param [experimental_customMergeAllOf] - Optional function that allows for custom merging of `allOf` schemas
   */
  constructor(t, r, n, o) {
    this.rootSchema = r, this.validator = t, this.experimental_defaultFormStateBehavior = n, this.experimental_customMergeAllOf = o;
  }
  /** Returns the `ValidatorType` in the `SchemaUtilsType`
   *
   * @returns - The `ValidatorType`
   */
  getValidator() {
    return this.validator;
  }
  /** Determines whether either the `validator` and `rootSchema` differ from the ones associated with this instance of
   * the `SchemaUtilsType`. If either `validator` or `rootSchema` are falsy, then return false to prevent the creation
   * of a new `SchemaUtilsType` with incomplete properties.
   *
   * @param validator - An implementation of the `ValidatorType` interface that will be compared against the current one
   * @param rootSchema - The root schema that will be compared against the current one
   * @param [experimental_defaultFormStateBehavior] Optional configuration object, if provided, allows users to override default form state behavior
   * @param [experimental_customMergeAllOf] - Optional function that allows for custom merging of `allOf` schemas
   * @returns - True if the `SchemaUtilsType` differs from the given `validator` or `rootSchema`
   */
  doesSchemaUtilsDiffer(t, r, n = {}, o) {
    return !t || !r ? !1 : this.validator !== t || !pr(this.rootSchema, r) || !pr(this.experimental_defaultFormStateBehavior, n) || this.experimental_customMergeAllOf !== o;
  }
  /** Returns the superset of `formData` that includes the given set updated to include any missing fields that have
   * computed to have defaults provided in the `schema`.
   *
   * @param schema - The schema for which the default state is desired
   * @param [formData] - The current formData, if any, onto which to provide any missing defaults
   * @param [includeUndefinedValues=false] - Optional flag, if true, cause undefined values to be added as defaults.
   *          If "excludeObjectChildren", pass `includeUndefinedValues` as false when computing defaults for any nested
   *          object properties.
   * @returns - The resulting `formData` with all the defaults provided
   */
  getDefaultFormState(t, r, n = !1) {
    return Z0(this.validator, t, r, this.rootSchema, n, this.experimental_defaultFormStateBehavior, this.experimental_customMergeAllOf);
  }
  /** Determines whether the combination of `schema` and `uiSchema` properties indicates that the label for the `schema`
   * should be displayed in a UI.
   *
   * @param schema - The schema for which the display label flag is desired
   * @param [uiSchema] - The UI schema from which to derive potentially displayable information
   * @param [globalOptions={}] - The optional Global UI Schema from which to get any fallback `xxx` options
   * @returns - True if the label should be displayed or false if it should not
   */
  getDisplayLabel(t, r, n) {
    return fF(this.validator, t, r, this.rootSchema, n, this.experimental_customMergeAllOf);
  }
  /** Determines which of the given `options` provided most closely matches the `formData`.
   * Returns the index of the option that is valid and is the closest match, or 0 if there is no match.
   *
   * The closest match is determined using the number of matching properties, and more heavily favors options with
   * matching readOnly, default, or const values.
   *
   * @param formData - The form data associated with the schema
   * @param options - The list of options that can be selected from
   * @param [selectedOption] - The index of the currently selected option, defaulted to -1 if not specified
   * @param [discriminatorField] - The optional name of the field within the options object whose value is used to
   *          determine which option is selected
   * @returns - The index of the option that is the closest match to the `formData` or the `selectedOption` if no match
   */
  getClosestMatchingOption(t, r, n, o) {
    return Ni(this.validator, this.rootSchema, t, r, n, o, this.experimental_customMergeAllOf);
  }
  /** Given the `formData` and list of `options`, attempts to find the index of the first option that matches the data.
   * Always returns the first option if there is nothing that matches.
   *
   * @param formData - The current formData, if any, used to figure out a match
   * @param options - The list of options to find a matching options from
   * @param [discriminatorField] - The optional name of the field within the options object whose value is used to
   *          determine which option is selected
   * @returns - The firstindex of the matched option or 0 if none is available
   */
  getFirstMatchingOption(t, r, n) {
    return Dd(this.validator, t, r, this.rootSchema, n);
  }
  /** Given the `formData` and list of `options`, attempts to find the index of the option that best matches the data.
   * Deprecated, use `getFirstMatchingOption()` instead.
   *
   * @param formData - The current formData, if any, onto which to provide any missing defaults
   * @param options - The list of options to find a matching options from
   * @param [discriminatorField] - The optional name of the field within the options object whose value is used to
   *          determine which option is selected
   * @returns - The index of the matched option or 0 if none is available
   * @deprecated
   */
  getMatchingOption(t, r, n) {
    return h0(this.validator, t, r, this.rootSchema, n);
  }
  /** Checks to see if the `schema` and `uiSchema` combination represents an array of files
   *
   * @param schema - The schema for which check for array of files flag is desired
   * @param [uiSchema] - The UI schema from which to check the widget
   * @returns - True if schema/uiSchema contains an array of files, otherwise false
   */
  isFilesArray(t, r) {
    return eb(this.validator, t, r, this.rootSchema, this.experimental_customMergeAllOf);
  }
  /** Checks to see if the `schema` combination represents a multi-select
   *
   * @param schema - The schema for which check for a multi-select flag is desired
   * @returns - True if schema contains a multi-select, otherwise false
   */
  isMultiSelect(t) {
    return rf(this.validator, t, this.rootSchema, this.experimental_customMergeAllOf);
  }
  /** Checks to see if the `schema` combination represents a select
   *
   * @param schema - The schema for which check for a select flag is desired
   * @returns - True if schema contains a select, otherwise false
   */
  isSelect(t) {
    return X0(this.validator, t, this.rootSchema, this.experimental_customMergeAllOf);
  }
  /** Merges the errors in `additionalErrorSchema` into the existing `validationData` by combining the hierarchies in
   * the two `ErrorSchema`s and then appending the error list from the `additionalErrorSchema` obtained by calling
   * `getValidator().toErrorList()` onto the `errors` in the `validationData`. If no `additionalErrorSchema` is passed,
   * then `validationData` is returned.
   *
   * @param validationData - The current `ValidationData` into which to merge the additional errors
   * @param [additionalErrorSchema] - The additional set of errors
   * @returns - The `validationData` with the additional errors from `additionalErrorSchema` merged into it, if provided.
   * @deprecated - Use the `validationDataMerge()` function exported from `@rjsf/utils` instead. This function will be
   *        removed in the next major release.
   */
  mergeValidationData(t, r) {
    return pF(this.validator, t, r);
  }
  /** Retrieves an expanded schema that has had all of its conditions, additional properties, references and
   * dependencies resolved and merged into the `schema` given a `rawFormData` that is used to do the potentially
   * recursive resolution.
   *
   * @param schema - The schema for which retrieving a schema is desired
   * @param [rawFormData] - The current formData, if any, to assist retrieving a schema
   * @returns - The schema having its conditions, additional properties, references and dependencies resolved
   */
  retrieveSchema(t, r) {
    return Ir(this.validator, t, this.rootSchema, r, this.experimental_customMergeAllOf);
  }
  /** Sanitize the `data` associated with the `oldSchema` so it is considered appropriate for the `newSchema`. If the
   * new schema does not contain any properties, then `undefined` is returned to clear all the form data. Due to the
   * nature of schemas, this sanitization happens recursively for nested objects of data. Also, any properties in the
   * old schemas that are non-existent in the new schema are set to `undefined`.
   *
   * @param [newSchema] - The new schema for which the data is being sanitized
   * @param [oldSchema] - The old schema from which the data originated
   * @param [data={}] - The form data associated with the schema, defaulting to an empty object when undefined
   * @returns - The new form data, with all the fields uniquely associated with the old schema set
   *      to `undefined`. Will return `undefined` if the new schema is not an object containing properties.
   */
  sanitizeDataForNewSchema(t, r, n) {
    return Tu(this.validator, this.rootSchema, t, r, n, this.experimental_customMergeAllOf);
  }
  /** Generates an `IdSchema` object for the `schema`, recursively
   *
   * @param schema - The schema for which the display label flag is desired
   * @param [id] - The base id for the schema
   * @param [formData] - The current formData, if any, onto which to provide any missing defaults
   * @param [idPrefix='root'] - The prefix to use for the id
   * @param [idSeparator='_'] - The separator to use for the path segments in the id
   * @returns - The `IdSchema` object for the `schema`
   */
  toIdSchema(t, r, n, o = "root", a = "_") {
    return hF(this.validator, t, r, this.rootSchema, n, o, a, this.experimental_customMergeAllOf);
  }
  /** Generates an `PathSchema` object for the `schema`, recursively
   *
   * @param schema - The schema for which the display label flag is desired
   * @param [name] - The base name for the schema
   * @param [formData] - The current formData, if any, onto which to provide any missing defaults
   * @returns - The `PathSchema` object for the `schema`
   */
  toPathSchema(t, r, n) {
    return mF(this.validator, t, r, this.rootSchema, n, this.experimental_customMergeAllOf);
  }
}
function yF(e, t, r = {}, n) {
  return new gF(e, t, r, n);
}
function bF(e) {
  var t;
  if (e.indexOf("data:") === -1)
    throw new Error("File is invalid: URI must be a dataURI");
  const n = e.slice(5).split(";base64,");
  if (n.length !== 2)
    throw new Error("File is invalid: dataURI must be base64");
  const [o, a] = n, [i, ...s] = o.split(";"), l = i || "", c = decodeURI(
    // parse the parameters into key-value pairs, find a key, and extract a value
    // if no key is found, then the name is unknown
    ((t = s.map((u) => u.split("=")).find(([u]) => u === "name")) === null || t === void 0 ? void 0 : t[1]) || "unknown"
  );
  try {
    const u = atob(a), f = new Array(u.length);
    for (let p = 0; p < u.length; p++)
      f[p] = u.charCodeAt(p);
    return { blob: new window.Blob([new Uint8Array(f)], { type: l }), name: c };
  } catch (u) {
    throw new Error("File is invalid: " + u.message);
  }
}
function Xn(e, t) {
  let r = String(e);
  for (; r.length < t; )
    r = "0" + r;
  return r;
}
function tb(e, t) {
  if (e <= 0 && t <= 0)
    e = (/* @__PURE__ */ new Date()).getFullYear() + e, t = (/* @__PURE__ */ new Date()).getFullYear() + t;
  else if (e < 0 || t < 0)
    throw new Error(`Both start (${e}) and stop (${t}) must both be <= 0 or > 0, got one of each`);
  if (e > t)
    return tb(t, e).reverse();
  const r = [];
  for (let n = e; n <= t; n++)
    r.push({ value: n, label: Xn(n, 2) });
  return r;
}
function vF(e, t) {
  let r = e;
  if (Array.isArray(t)) {
    const n = r.split(/(%\d)/);
    t.forEach((o, a) => {
      const i = n.findIndex((s) => s === `%${a + 1}`);
      i >= 0 && (n[i] = o);
    }), r = n.join("");
  }
  return r;
}
function $F(e, t) {
  return vF(e, t);
}
function Yt(e, t = [], r) {
  if (Array.isArray(e))
    return e.map((a) => Yt(a, t)).filter((a) => a !== r);
  const n = e === "" || e === null ? -1 : Number(e), o = t[n];
  return o ? o.value : r;
}
function rb(e, t, r = []) {
  const n = Yt(e, r);
  return Array.isArray(t) ? t.filter((o) => !Po(o, n)) : Po(n, t) ? void 0 : t;
}
function ec(e, t) {
  return Array.isArray(t) ? t.some((r) => Po(r, e)) : Po(t, e);
}
function nf(e, t = [], r = !1) {
  const n = t.map((o, a) => ec(o.value, e) ? String(a) : void 0).filter((o) => typeof o < "u");
  return r ? n : n[0];
}
function SF(e) {
  return e == null;
}
var wF = SF;
const nb = /* @__PURE__ */ pt(wF);
function ob(e, t, r = []) {
  const n = Yt(e, r);
  if (!nb(n)) {
    const o = r.findIndex((s) => n === s.value), a = r.map(({ value: s }) => s);
    return t.slice(0, o).concat(n, t.slice(o)).sort((s, l) => +(a.indexOf(s) > a.indexOf(l)));
  }
  return t;
}
var CF = Bd;
function EF(e, t, r, n) {
  return n = typeof n == "function" ? n : void 0, e == null ? e : CF(e, t, r, n);
}
var _F = EF;
const xF = /* @__PURE__ */ pt(_F);
class PF {
  /** Construct an `ErrorSchemaBuilder` with an optional initial set of errors in an `ErrorSchema`.
   *
   * @param [initialSchema] - The optional set of initial errors, that will be cloned into the class
   */
  constructor(t) {
    this.errorSchema = {}, this.resetAllErrors(t);
  }
  /** Returns the `ErrorSchema` that has been updated by the methods of the `ErrorSchemaBuilder`
   */
  get ErrorSchema() {
    return this.errorSchema;
  }
  /** Will get an existing `ErrorSchema` at the specified `pathOfError` or create and return one.
   *
   * @param [pathOfError] - The optional path into the `ErrorSchema` at which to add the error(s)
   * @returns - The error block for the given `pathOfError` or the root if not provided
   * @private
   */
  getOrCreateErrorBlock(t) {
    let n = Array.isArray(t) && t.length > 0 || typeof t == "string" ? xe(this.errorSchema, t) : this.errorSchema;
    return !n && t && (n = {}, xF(this.errorSchema, t, n, Object)), n;
  }
  /** Resets all errors in the `ErrorSchemaBuilder` back to the `initialSchema` if provided, otherwise an empty set.
   *
   * @param [initialSchema] - The optional set of initial errors, that will be cloned into the class
   * @returns - The `ErrorSchemaBuilder` object for chaining purposes
   */
  resetAllErrors(t) {
    return this.errorSchema = t ? S0(t) : {}, this;
  }
  /** Adds the `errorOrList` to the list of errors in the `ErrorSchema` at either the root level or the location within
   * the schema described by the `pathOfError`. For more information about how to specify the path see the
   * [eslint lodash plugin docs](https://github.com/wix/eslint-plugin-lodash/blob/master/docs/rules/path-style.md).
   *
   * @param errorOrList - The error or list of errors to add into the `ErrorSchema`
   * @param [pathOfError] - The optional path into the `ErrorSchema` at which to add the error(s)
   * @returns - The `ErrorSchemaBuilder` object for chaining purposes
   */
  addErrors(t, r) {
    const n = this.getOrCreateErrorBlock(r);
    let o = xe(n, kr);
    return Array.isArray(o) || (o = [], n[kr] = o), Array.isArray(t) ? er(n, kr, [.../* @__PURE__ */ new Set([...o, ...t])]) : er(n, kr, [.../* @__PURE__ */ new Set([...o, t])]), this;
  }
  /** Sets/replaces the `errorOrList` as the error(s) in the `ErrorSchema` at either the root level or the location
   * within the schema described by the `pathOfError`. For more information about how to specify the path see the
   * [eslint lodash plugin docs](https://github.com/wix/eslint-plugin-lodash/blob/master/docs/rules/path-style.md).
   *
   * @param errorOrList - The error or list of errors to set into the `ErrorSchema`
   * @param [pathOfError] - The optional path into the `ErrorSchema` at which to set the error(s)
   * @returns - The `ErrorSchemaBuilder` object for chaining purposes
   */
  setErrors(t, r) {
    const n = this.getOrCreateErrorBlock(r), o = Array.isArray(t) ? [.../* @__PURE__ */ new Set([...t])] : [t];
    return er(n, kr, o), this;
  }
  /** Clears the error(s) in the `ErrorSchema` at either the root level or the location within the schema described by
   * the `pathOfError`. For more information about how to specify the path see the
   * [eslint lodash plugin docs](https://github.com/wix/eslint-plugin-lodash/blob/master/docs/rules/path-style.md).
   *
   * @param [pathOfError] - The optional path into the `ErrorSchema` at which to clear the error(s)
   * @returns - The `ErrorSchemaBuilder` object for chaining purposes
   */
  clearErrors(t) {
    const r = this.getOrCreateErrorBlock(t);
    return er(r, kr, []), this;
  }
}
function kF(e, t, r = [1900, (/* @__PURE__ */ new Date()).getFullYear() + 2], n = "YMD") {
  const { day: o, month: a, year: i, hour: s, minute: l, second: c } = e, u = { type: "day", range: [1, 31], value: o }, f = { type: "month", range: [1, 12], value: a }, d = { type: "year", range: r, value: i }, p = [];
  switch (n) {
    case "MDY":
      p.push(f, u, d);
      break;
    case "DMY":
      p.push(u, f, d);
      break;
    case "YMD":
    default:
      p.push(d, f, u);
  }
  return t && p.push({ type: "hour", range: [0, 23], value: s }, { type: "minute", range: [0, 59], value: l }, { type: "second", range: [0, 59], value: c }), p;
}
function ab(e) {
  const t = {};
  return e.multipleOf && (t.step = e.multipleOf), (e.minimum || e.minimum === 0) && (t.min = e.minimum), (e.maximum || e.maximum === 0) && (t.max = e.maximum), t;
}
function ib(e, t, r = {}, n = !0) {
  const o = {
    type: t || "text",
    ...ab(e)
  };
  return r.inputType ? o.type = r.inputType : t || (e.type === "number" ? (o.type = "number", n && o.step === void 0 && (o.step = "any")) : e.type === "integer" && (o.type = "number", o.step === void 0 && (o.step = 1))), r.autocomplete && (o.autoComplete = r.autocomplete), o;
}
const cm = {
  props: {
    disabled: !1
  },
  submitText: "Submit",
  norender: !1
};
function sb(e = {}) {
  const t = Qe(e);
  if (t && t[cl]) {
    const r = t[cl];
    return { ...cm, ...r };
  }
  return cm;
}
function Ye(e, t, r = {}) {
  const { templates: n } = t;
  return e === "ButtonTemplates" ? n[e] : (
    // Evaluating uiOptions[name] results in TS2590: Expression produces a union type that is too complex to represent
    // To avoid that, we cast uiOptions to `any` before accessing the name field
    r[e] || n[e]
  );
}
var lb = { exports: {} }, dt = {};
/**
 * @license React
 * react-is.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 um;
function OF() {
  if (um) return dt;
  um = 1;
  var e = Symbol.for("react.element"), t = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), n = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.provider"), i = Symbol.for("react.context"), s = Symbol.for("react.server_context"), l = Symbol.for("react.forward_ref"), c = Symbol.for("react.suspense"), u = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), d = Symbol.for("react.lazy"), p = Symbol.for("react.offscreen"), h;
  h = Symbol.for("react.module.reference");
  function $(b) {
    if (typeof b == "object" && b !== null) {
      var g = b.$$typeof;
      switch (g) {
        case e:
          switch (b = b.type, b) {
            case r:
            case o:
            case n:
            case c:
            case u:
              return b;
            default:
              switch (b = b && b.$$typeof, b) {
                case s:
                case i:
                case l:
                case d:
                case f:
                case a:
                  return b;
                default:
                  return g;
              }
          }
        case t:
          return g;
      }
    }
  }
  return dt.ContextConsumer = i, dt.ContextProvider = a, dt.Element = e, dt.ForwardRef = l, dt.Fragment = r, dt.Lazy = d, dt.Memo = f, dt.Portal = t, dt.Profiler = o, dt.StrictMode = n, dt.Suspense = c, dt.SuspenseList = u, dt.isAsyncMode = function() {
    return !1;
  }, dt.isConcurrentMode = function() {
    return !1;
  }, dt.isContextConsumer = function(b) {
    return $(b) === i;
  }, dt.isContextProvider = function(b) {
    return $(b) === a;
  }, dt.isElement = function(b) {
    return typeof b == "object" && b !== null && b.$$typeof === e;
  }, dt.isForwardRef = function(b) {
    return $(b) === l;
  }, dt.isFragment = function(b) {
    return $(b) === r;
  }, dt.isLazy = function(b) {
    return $(b) === d;
  }, dt.isMemo = function(b) {
    return $(b) === f;
  }, dt.isPortal = function(b) {
    return $(b) === t;
  }, dt.isProfiler = function(b) {
    return $(b) === o;
  }, dt.isStrictMode = function(b) {
    return $(b) === n;
  }, dt.isSuspense = function(b) {
    return $(b) === c;
  }, dt.isSuspenseList = function(b) {
    return $(b) === u;
  }, dt.isValidElementType = function(b) {
    return typeof b == "string" || typeof b == "function" || b === r || b === o || b === n || b === c || b === u || b === p || typeof b == "object" && b !== null && (b.$$typeof === d || b.$$typeof === f || b.$$typeof === a || b.$$typeof === i || b.$$typeof === l || b.$$typeof === h || b.getModuleId !== void 0);
  }, dt.typeOf = $, dt;
}
lb.exports = OF();
var AF = lb.exports;
const dm = /* @__PURE__ */ pt(AF), Zc = {
  boolean: {
    checkbox: "CheckboxWidget",
    radio: "RadioWidget",
    select: "SelectWidget",
    hidden: "HiddenWidget"
  },
  string: {
    text: "TextWidget",
    password: "PasswordWidget",
    email: "EmailWidget",
    hostname: "TextWidget",
    ipv4: "TextWidget",
    ipv6: "TextWidget",
    uri: "URLWidget",
    "data-url": "FileWidget",
    radio: "RadioWidget",
    select: "SelectWidget",
    textarea: "TextareaWidget",
    hidden: "HiddenWidget",
    date: "DateWidget",
    datetime: "DateTimeWidget",
    "date-time": "DateTimeWidget",
    "alt-date": "AltDateWidget",
    "alt-datetime": "AltDateTimeWidget",
    time: "TimeWidget",
    color: "ColorWidget",
    file: "FileWidget"
  },
  number: {
    text: "TextWidget",
    select: "SelectWidget",
    updown: "UpDownWidget",
    range: "RangeWidget",
    radio: "RadioWidget",
    hidden: "HiddenWidget"
  },
  integer: {
    text: "TextWidget",
    select: "SelectWidget",
    updown: "UpDownWidget",
    range: "RangeWidget",
    radio: "RadioWidget",
    hidden: "HiddenWidget"
  },
  array: {
    select: "SelectWidget",
    checkboxes: "CheckboxesWidget",
    files: "FileWidget",
    hidden: "HiddenWidget"
  }
};
function IF(e) {
  let t = xe(e, "MergedWidget");
  if (!t) {
    const r = e.defaultProps && e.defaultProps.options || {};
    t = ({ options: n, ...o }) => P(e, { options: { ...r, ...n }, ...o }), er(e, "MergedWidget", t);
  }
  return t;
}
function In(e, t, r = {}) {
  const n = so(e);
  if (typeof t == "function" || t && dm.isForwardRef(u$(t)) || dm.isMemo(t))
    return IF(t);
  if (typeof t != "string")
    throw new Error(`Unsupported widget definition: ${typeof t}`);
  if (t in r) {
    const o = r[t];
    return In(e, o, r);
  }
  if (typeof n == "string") {
    if (!(n in Zc))
      throw new Error(`No widget for type '${n}'`);
    if (t in Zc[n]) {
      const o = r[Zc[n][t]];
      return In(e, o, r);
    }
  }
  throw new Error(`No widget '${t}' for type '${n}'`);
}
function RF(e) {
  let t = 0;
  for (let r = 0; r < e.length; r += 1) {
    const n = e.charCodeAt(r);
    t = (t << 5) - t + n, t = t & t;
  }
  return t.toString(16);
}
function TF(e) {
  const t = /* @__PURE__ */ new Set();
  return JSON.stringify(e, (r, n) => (t.add(r), n)), RF(JSON.stringify(e, Array.from(t).sort()));
}
function MF(e, t, r = {}) {
  try {
    return In(e, t, r), !0;
  } catch (n) {
    const o = n;
    if (o.message && (o.message.startsWith("No widget") || o.message.startsWith("Unsupported widget")))
      return !1;
    throw n;
  }
}
function as(e, t) {
  return `${Nd(e) ? e : e[Zn]}__${t}`;
}
function Lo(e) {
  return as(e, "description");
}
function of(e) {
  return as(e, "error");
}
function ji(e) {
  return as(e, "examples");
}
function af(e) {
  return as(e, "help");
}
function sf(e) {
  return as(e, "title");
}
function Mr(e, t = !1) {
  const r = t ? ` ${ji(e)}` : "";
  return `${of(e)} ${Lo(e)} ${af(e)}${r}`;
}
function tc(e, t) {
  return `${e}-${t}`;
}
function Bo(e, t, r) {
  return t ? r : e;
}
function NF(e) {
  return e ? new Date(e).toJSON() : void 0;
}
function FF(e) {
  if (v$ in e && Array.isArray(e.enum) && e.enum.length === 1)
    return e.enum[0];
  if (ha in e)
    return e.const;
  throw new Error("schema cannot be inferred as a constant");
}
function bl(e, t) {
  const r = e;
  if (e.enum) {
    let a;
    if (t) {
      const { enumNames: i } = Qe(t);
      a = i;
    }
    return !a && r.enumNames && (a = r.enumNames), e.enum.map((i, s) => ({ label: (a == null ? void 0 : a[s]) || String(i), value: i }));
  }
  let n, o;
  return e.anyOf ? (n = e.anyOf, o = t == null ? void 0 : t.anyOf) : e.oneOf && (n = e.oneOf, o = t == null ? void 0 : t.oneOf), n && n.map((a, i) => {
    const { title: s } = Qe(o == null ? void 0 : o[i]), l = a, c = FF(l), u = s || l.title || String(c);
    return {
      schema: l,
      label: u,
      value: c
    };
  });
}
function jF(e, t) {
  if (!Array.isArray(t))
    return e;
  const r = (u) => u.reduce((f, d) => (f[d] = !0, f), {}), n = (u) => u.length > 1 ? `properties '${u.join("', '")}'` : `property '${u[0]}'`, o = r(e), a = t.filter((u) => u === "*" || o[u]), i = r(a), s = e.filter((u) => !i[u]), l = a.indexOf("*");
  if (l === -1) {
    if (s.length)
      throw new Error(`uiSchema order list does not contain ${n(s)}`);
    return a;
  }
  if (l !== a.lastIndexOf("*"))
    throw new Error("uiSchema order list contains more than one wildcard item");
  const c = [...a];
  return c.splice(l, 1, ...s), c;
}
function Qc(e, t = !0) {
  if (!e)
    return {
      year: -1,
      month: -1,
      day: -1,
      hour: t ? -1 : 0,
      minute: t ? -1 : 0,
      second: t ? -1 : 0
    };
  const r = new Date(e);
  if (Number.isNaN(r.getTime()))
    throw new Error("Unable to parse date " + e);
  return {
    year: r.getUTCFullYear(),
    month: r.getUTCMonth() + 1,
    day: r.getUTCDate(),
    hour: t ? r.getUTCHours() : 0,
    minute: t ? r.getUTCMinutes() : 0,
    second: t ? r.getUTCSeconds() : 0
  };
}
function wi(e) {
  if (e.const || e.enum && e.enum.length === 1 && e.enum[0] === !0)
    return !0;
  if (e.anyOf && e.anyOf.length === 1)
    return wi(e.anyOf[0]);
  if (e.oneOf && e.oneOf.length === 1)
    return wi(e.oneOf[0]);
  if (e.allOf) {
    const t = (r) => wi(r);
    return e.allOf.some(t);
  }
  return !1;
}
function DF(e, t, r) {
  const { props: n, state: o } = e;
  return !pr(n, t) || !pr(o, r);
}
function fm(e, t = !0) {
  const { year: r, month: n, day: o, hour: a = 0, minute: i = 0, second: s = 0 } = e, l = Date.UTC(r, n - 1, o, a, i, s), c = new Date(l).toJSON();
  return t ? c : c.slice(0, 10);
}
function Di(e, t = []) {
  if (!e)
    return [];
  let r = [];
  return kr in e && (r = r.concat(e[kr].map((n) => {
    const o = `.${t.join(".")}`;
    return {
      property: o,
      message: n,
      stack: `${o} ${n}`
    };
  }))), Object.keys(e).reduce((n, o) => {
    if (o !== kr) {
      const a = e[o];
      bd(a) && (n = n.concat(Di(a, [...t, o])));
    }
    return n;
  }, r);
}
var LF = Vn, BF = Jl, zF = Xt, UF = Da, VF = Iy, qF = Do, WF = Ty;
function KF(e) {
  return zF(e) ? LF(e, qF) : UF(e) ? [e] : BF(VF(WF(e)));
}
var GF = KF;
const cb = /* @__PURE__ */ pt(GF);
function HF(e) {
  const t = new PF();
  return e.length && e.forEach((r) => {
    const { property: n, message: o } = r, a = n === "." ? [] : cb(n);
    a.length > 0 && a[0] === "" && a.splice(0, 1), o && t.addErrors(o, a);
  }), t.ErrorSchema;
}
function ub(e) {
  return Object.keys(e).reduce((t, r) => {
    if (r === "addError")
      return t;
    {
      const n = e[r];
      return bd(n) ? {
        ...t,
        [r]: ub(n)
      } : { ...t, [r]: n };
    }
  }, {});
}
function JF(e) {
  if (!e)
    return "";
  const t = new Date(e), r = Xn(t.getFullYear(), 4), n = Xn(t.getMonth() + 1, 2), o = Xn(t.getDate(), 2), a = Xn(t.getHours(), 2), i = Xn(t.getMinutes(), 2), s = Xn(t.getSeconds(), 2), l = Xn(t.getMilliseconds(), 3);
  return `${r}-${n}-${o}T${a}:${i}:${s}.${l}`;
}
function Zs(e, t) {
  if (!t)
    return e;
  const { errors: r, errorSchema: n } = e;
  let o = Di(t), a = t;
  return io(n) || (a = to(n, t, !0), o = [...r].concat(o)), { errorSchema: a, errors: o };
}
function YF(e) {
  for (const t in e) {
    const r = e, n = r[t];
    t === Ht && typeof n == "string" && n.startsWith("#") ? r[t] = dy + n : r[t] = lf(n);
  }
  return e;
}
function XF(e) {
  for (let t = 0; t < e.length; t++)
    e[t] = lf(e[t]);
  return e;
}
function lf(e) {
  return Array.isArray(e) ? XF([...e]) : Ur(e) ? YF({ ...e }) : e;
}
var ot;
(function(e) {
  e.ArrayItemTitle = "Item", e.MissingItems = "Missing items definition", e.YesLabel = "Yes", e.NoLabel = "No", e.CloseLabel = "Close", e.ErrorsLabel = "Errors", e.NewStringDefault = "New Value", e.AddButton = "Add", e.AddItemButton = "Add Item", e.CopyButton = "Copy", e.MoveDownButton = "Move down", e.MoveUpButton = "Move up", e.RemoveButton = "Remove", e.NowLabel = "Now", e.ClearLabel = "Clear", e.AriaDateLabel = "Select a date", e.PreviewLabel = "Preview", e.DecrementAriaLabel = "Decrease value by 1", e.IncrementAriaLabel = "Increase value by 1", e.UnknownFieldType = "Unknown field type %1", e.OptionPrefix = "Option %1", e.TitleOptionPrefix = "%1 option %2", e.KeyLabel = "%1 Key", e.InvalidObjectField = 'Invalid "%1" object field configuration: _%2_.', e.UnsupportedField = "Unsupported field schema.", e.UnsupportedFieldWithId = "Unsupported field schema for field `%1`.", e.UnsupportedFieldWithReason = "Unsupported field schema: _%1_.", e.UnsupportedFieldWithIdAndReason = "Unsupported field schema for field `%1`: _%2_.", e.FilesInfo = "**%1** (%2, %3 bytes)";
})(ot || (ot = {}));
var ZF = ts, QF = Bd, ej = La;
function tj(e, t, r) {
  for (var n = -1, o = t.length, a = {}; ++n < o; ) {
    var i = t[n], s = ZF(e, i);
    r(s, i) && QF(a, ej(i, e), s);
  }
  return a;
}
var rj = tj, nj = rj, oj = u0;
function aj(e, t) {
  return nj(e, t, function(r, n) {
    return oj(e, n);
  });
}
var ij = aj, sj = ij, lj = t0, cj = lj(function(e, t) {
  return e == null ? {} : sj(e, t);
}), uj = cj;
const pm = /* @__PURE__ */ pt(uj);
let dj = (e = 21) => crypto.getRandomValues(new Uint8Array(e)).reduce((t, r) => (r &= 63, r < 36 ? t += r.toString(36) : r < 62 ? t += (r - 26).toString(36).toUpperCase() : r > 62 ? t += "-" : t += "_", t), "");
function Mu() {
  return dj();
}
function hm(e) {
  return Array.isArray(e) ? e.map((t) => ({
    key: Mu(),
    item: t
  })) : [];
}
function ti(e) {
  return Array.isArray(e) ? e.map((t) => t.item) : [];
}
class fj extends Ji {
  /** Constructs an `ArrayField` from the `props`, generating the initial keyed data from the `formData`
   *
   * @param props - The `FieldProps` for this template
   */
  constructor(t) {
    super(t), this._getNewFormDataRow = () => {
      const { schema: o, registry: a } = this.props, { schemaUtils: i } = a;
      let s = o.items;
      return Ru(o) && y$(o) && (s = o.additionalItems), i.getDefaultFormState(s);
    }, this.onAddClick = (o) => {
      this._handleAddClick(o);
    }, this.onAddIndexClick = (o) => (a) => {
      this._handleAddClick(a, o);
    }, this.onCopyIndexClick = (o) => (a) => {
      a && a.preventDefault();
      const { onChange: i, errorSchema: s } = this.props, { keyedFormData: l } = this.state;
      let c;
      if (s) {
        c = {};
        for (const d in s) {
          const p = parseInt(d);
          p <= o ? er(c, [p], s[d]) : p > o && er(c, [p + 1], s[d]);
        }
      }
      const u = {
        key: Mu(),
        item: S0(l[o].item)
      }, f = [...l];
      o !== void 0 ? f.splice(o + 1, 0, u) : f.push(u), this.setState({
        keyedFormData: f,
        updatedKeyedFormData: !0
      }, () => i(ti(f), c));
    }, this.onDropIndexClick = (o) => (a) => {
      a && a.preventDefault();
      const { onChange: i, errorSchema: s } = this.props, { keyedFormData: l } = this.state;
      let c;
      if (s) {
        c = {};
        for (const f in s) {
          const d = parseInt(f);
          d < o ? er(c, [d], s[f]) : d > o && er(c, [d - 1], s[f]);
        }
      }
      const u = l.filter((f, d) => d !== o);
      this.setState({
        keyedFormData: u,
        updatedKeyedFormData: !0
      }, () => i(ti(u), c));
    }, this.onReorderClick = (o, a) => (i) => {
      i && (i.preventDefault(), i.currentTarget.blur());
      const { onChange: s, errorSchema: l } = this.props;
      let c;
      if (l) {
        c = {};
        for (const p in l) {
          const h = parseInt(p);
          h == o ? er(c, [a], l[o]) : h == a ? er(c, [o], l[a]) : er(c, [p], l[h]);
        }
      }
      const { keyedFormData: u } = this.state;
      function f() {
        const p = u.slice();
        return p.splice(o, 1), p.splice(a, 0, u[o]), p;
      }
      const d = f();
      this.setState({
        keyedFormData: d
      }, () => s(ti(d), c));
    }, this.onChangeForIndex = (o) => (a, i, s) => {
      const { formData: l, onChange: c, errorSchema: u } = this.props, d = (Array.isArray(l) ? l : []).map((p, h) => o === h ? typeof a > "u" ? null : a : p);
      c(d, u && u && {
        ...u,
        [o]: i
      }, s);
    }, this.onSelectChange = (o) => {
      const { onChange: a, idSchema: i } = this.props;
      a(o, void 0, i && i.$id);
    };
    const { formData: r = [] } = t, n = hm(r);
    this.state = {
      keyedFormData: n,
      updatedKeyedFormData: !1
    };
  }
  /** React lifecycle method that is called when the props are about to change allowing the state to be updated. It
   * regenerates the keyed form data and returns it
   *
   * @param nextProps - The next set of props data
   * @param prevState - The previous set of state data
   */
  static getDerivedStateFromProps(t, r) {
    if (r.updatedKeyedFormData)
      return {
        updatedKeyedFormData: !1
      };
    const n = Array.isArray(t.formData) ? t.formData : [], o = r.keyedFormData || [];
    return {
      keyedFormData: n.length === o.length ? o.map((i, s) => ({
        key: i.key,
        item: n[s]
      })) : hm(n)
    };
  }
  /** Returns the appropriate title for an item by getting first the title from the schema.items, then falling back to
   * the description from the schema.items, and finally the string "Item"
   */
  get itemTitle() {
    const { schema: t, registry: r } = this.props, { translateString: n } = r;
    return xe(t, [eo, "title"], xe(t, [eo, "description"], n(ot.ArrayItemTitle)));
  }
  /** Determines whether the item described in the schema is always required, which is determined by whether any item
   * may be null.
   *
   * @param itemSchema - The schema for the item
   * @return - True if the item schema type does not contain the "null" type
   */
  isItemRequired(t) {
    return Array.isArray(t.type) ? !t.type.includes("null") : t.type !== "null";
  }
  /** Determines whether more items can be added to the array. If the uiSchema indicates the array doesn't allow adding
   * then false is returned. Otherwise, if the schema indicates that there are a maximum number of items and the
   * `formData` matches that value, then false is returned, otherwise true is returned.
   *
   * @param formItems - The list of items in the form
   * @returns - True if the item is addable otherwise false
   */
  canAddItem(t) {
    const { schema: r, uiSchema: n, registry: o } = this.props;
    let { addable: a } = Qe(n, o.globalUiOptions);
    return a !== !1 && (r.maxItems !== void 0 ? a = t.length < r.maxItems : a = !0), a;
  }
  /** Callback handler for when the user clicks on the add or add at index buttons. Creates a new row of keyed form data
   * either at the end of the list (when index is not specified) or inserted at the `index` when it is, adding it into
   * the state, and then returning `onChange()` with the plain form data converted from the keyed data
   *
   * @param event - The event for the click
   * @param [index] - The optional index at which to add the new data
   */
  _handleAddClick(t, r) {
    t && t.preventDefault();
    const { onChange: n, errorSchema: o } = this.props, { keyedFormData: a } = this.state;
    let i;
    if (o) {
      i = {};
      for (const c in o) {
        const u = parseInt(c);
        r === void 0 || u < r ? er(i, [u], o[c]) : u >= r && er(i, [u + 1], o[c]);
      }
    }
    const s = {
      key: Mu(),
      item: this._getNewFormDataRow()
    }, l = [...a];
    r !== void 0 ? l.splice(r, 0, s) : l.push(s), this.setState({
      keyedFormData: l,
      updatedKeyedFormData: !0
    }, () => n(ti(l), i));
  }
  /** Renders the `ArrayField` depending on the specific needs of the schema and uischema elements
   */
  render() {
    const { schema: t, uiSchema: r, idSchema: n, registry: o } = this.props, { schemaUtils: a, translateString: i } = o;
    if (!(eo in t)) {
      const s = Qe(r), l = Ye("UnsupportedFieldTemplate", o, s);
      return P(l, { schema: t, idSchema: n, reason: i(ot.MissingItems), registry: o });
    }
    return a.isMultiSelect(t) ? this.renderMultiSelect() : Q0(r) ? this.renderCustomWidget() : Ru(t) ? this.renderFixedArray() : a.isFilesArray(t, r) ? this.renderFiles() : this.renderNormalArray();
  }
  /** Renders a normal array without any limitations of length
   */
  renderNormalArray() {
    const { schema: t, uiSchema: r = {}, errorSchema: n, idSchema: o, name: a, title: i, disabled: s = !1, readonly: l = !1, autofocus: c = !1, required: u = !1, registry: f, onBlur: d, onFocus: p, idPrefix: h, idSeparator: $ = "_", rawErrors: b } = this.props, { keyedFormData: g } = this.state, y = t.title || i || a, { schemaUtils: S, formContext: m } = f, w = Qe(r), v = Ur(t.items) ? t.items : {}, E = S.retrieveSchema(v), I = ti(this.state.keyedFormData), R = this.canAddItem(I), C = {
      canAdd: R,
      items: g.map((F, D) => {
        const { key: z, item: L } = F, X = L, V = S.retrieveSchema(v, X), ie = n ? n[D] : void 0, Y = o.$id + $ + D, H = S.toIdSchema(V, Y, X, h, $);
        return this.renderArrayFieldItem({
          key: z,
          index: D,
          name: a && `${a}-${D}`,
          title: y ? `${y}-${D + 1}` : void 0,
          canAdd: R,
          canMoveUp: D > 0,
          canMoveDown: D < I.length - 1,
          itemSchema: V,
          itemIdSchema: H,
          itemErrorSchema: ie,
          itemData: X,
          itemUiSchema: r.items,
          autofocus: c && D === 0,
          onBlur: d,
          onFocus: p,
          rawErrors: b,
          totalItems: g.length
        });
      }),
      className: `field field-array field-array-of-${E.type}`,
      disabled: s,
      idSchema: o,
      uiSchema: r,
      onAddClick: this.onAddClick,
      readonly: l,
      required: u,
      schema: t,
      title: y,
      formContext: m,
      formData: I,
      rawErrors: b,
      registry: f
    }, T = Ye("ArrayFieldTemplate", f, w);
    return P(T, { ...C });
  }
  /** Renders an array using the custom widget provided by the user in the `uiSchema`
   */
  renderCustomWidget() {
    var t;
    const { schema: r, idSchema: n, uiSchema: o, disabled: a = !1, readonly: i = !1, autofocus: s = !1, required: l = !1, hideError: c, placeholder: u, onBlur: f, onFocus: d, formData: p = [], registry: h, rawErrors: $, name: b } = this.props, { widgets: g, formContext: y, globalUiOptions: S, schemaUtils: m } = h, { widget: w, title: v, ...E } = Qe(o, S), I = In(r, w, g), R = (t = v ?? r.title) !== null && t !== void 0 ? t : b, C = m.getDisplayLabel(r, o, S);
    return P(I, { id: n.$id, name: b, multiple: !0, onChange: this.onSelectChange, onBlur: f, onFocus: d, options: E, schema: r, uiSchema: o, registry: h, value: p, disabled: a, readonly: i, hideError: c, required: l, label: R, hideLabel: !C, placeholder: u, formContext: y, autofocus: s, rawErrors: $ });
  }
  /** Renders an array as a set of checkboxes
   */
  renderMultiSelect() {
    var t;
    const { schema: r, idSchema: n, uiSchema: o, formData: a = [], disabled: i = !1, readonly: s = !1, autofocus: l = !1, required: c = !1, placeholder: u, onBlur: f, onFocus: d, registry: p, rawErrors: h, name: $ } = this.props, { widgets: b, schemaUtils: g, formContext: y, globalUiOptions: S } = p, m = g.retrieveSchema(r.items, a), w = bl(m, o), { widget: v = "select", title: E, ...I } = Qe(o, S), R = In(r, v, b), C = (t = E ?? r.title) !== null && t !== void 0 ? t : $, T = g.getDisplayLabel(r, o, S);
    return P(R, { id: n.$id, name: $, multiple: !0, onChange: this.onSelectChange, onBlur: f, onFocus: d, options: { ...I, enumOptions: w }, schema: r, uiSchema: o, registry: p, value: a, disabled: i, readonly: s, required: c, label: C, hideLabel: !T, placeholder: u, formContext: y, autofocus: l, rawErrors: h });
  }
  /** Renders an array of files using the `FileWidget`
   */
  renderFiles() {
    var t;
    const { schema: r, uiSchema: n, idSchema: o, name: a, disabled: i = !1, readonly: s = !1, autofocus: l = !1, required: c = !1, onBlur: u, onFocus: f, registry: d, formData: p = [], rawErrors: h } = this.props, { widgets: $, formContext: b, globalUiOptions: g, schemaUtils: y } = d, { widget: S = "files", title: m, ...w } = Qe(n, g), v = In(r, S, $), E = (t = m ?? r.title) !== null && t !== void 0 ? t : a, I = y.getDisplayLabel(r, n, g);
    return P(v, { options: w, id: o.$id, name: a, multiple: !0, onChange: this.onSelectChange, onBlur: u, onFocus: f, schema: r, uiSchema: n, value: p, disabled: i, readonly: s, required: c, registry: d, formContext: b, autofocus: l, rawErrors: h, label: E, hideLabel: !I });
  }
  /** Renders an array that has a maximum limit of items
   */
  renderFixedArray() {
    const { schema: t, uiSchema: r = {}, formData: n = [], errorSchema: o, idPrefix: a, idSeparator: i = "_", idSchema: s, name: l, title: c, disabled: u = !1, readonly: f = !1, autofocus: d = !1, required: p = !1, registry: h, onBlur: $, onFocus: b, rawErrors: g } = this.props, { keyedFormData: y } = this.state;
    let { formData: S = [] } = this.props;
    const m = t.title || c || l, w = Qe(r), { schemaUtils: v, formContext: E } = h, R = (Ur(t.items) ? t.items : []).map((z, L) => v.retrieveSchema(z, n[L])), C = Ur(t.additionalItems) ? v.retrieveSchema(t.additionalItems, n) : null;
    (!S || S.length < R.length) && (S = S || [], S = S.concat(new Array(R.length - S.length)));
    const T = this.canAddItem(S) && !!C, F = {
      canAdd: T,
      className: "field field-array field-array-fixed-items",
      disabled: u,
      idSchema: s,
      formData: n,
      items: y.map((z, L) => {
        const { key: X, item: V } = z, ie = V, Y = L >= R.length, H = (Y && Ur(t.additionalItems) ? v.retrieveSchema(t.additionalItems, ie) : R[L]) || {}, j = s.$id + i + L, Q = v.toIdSchema(H, j, ie, a, i), q = Y ? r.additionalItems || {} : Array.isArray(r.items) ? r.items[L] : r.items || {}, O = o ? o[L] : void 0;
        return this.renderArrayFieldItem({
          key: X,
          index: L,
          name: l && `${l}-${L}`,
          title: m ? `${m}-${L + 1}` : void 0,
          canAdd: T,
          canRemove: Y,
          canMoveUp: L >= R.length + 1,
          canMoveDown: Y && L < S.length - 1,
          itemSchema: H,
          itemData: ie,
          itemUiSchema: q,
          itemIdSchema: Q,
          itemErrorSchema: O,
          autofocus: d && L === 0,
          onBlur: $,
          onFocus: b,
          rawErrors: g,
          totalItems: y.length
        });
      }),
      onAddClick: this.onAddClick,
      readonly: f,
      required: p,
      registry: h,
      schema: t,
      uiSchema: r,
      title: m,
      formContext: E,
      errorSchema: o,
      rawErrors: g
    }, D = Ye("ArrayFieldTemplate", h, w);
    return P(D, { ...F });
  }
  /** Renders the individual array item using a `SchemaField` along with the additional properties required to be send
   * back to the `ArrayFieldItemTemplate`.
   *
   * @param props - The props for the individual array item to be rendered
   */
  renderArrayFieldItem(t) {
    const { key: r, index: n, name: o, canAdd: a, canRemove: i = !0, canMoveUp: s, canMoveDown: l, itemSchema: c, itemData: u, itemUiSchema: f, itemIdSchema: d, itemErrorSchema: p, autofocus: h, onBlur: $, onFocus: b, rawErrors: g, totalItems: y, title: S } = t, { disabled: m, hideError: w, idPrefix: v, idSeparator: E, readonly: I, uiSchema: R, registry: C, formContext: T } = this.props, { fields: { ArraySchemaField: F, SchemaField: D }, globalUiOptions: z } = C, L = F || D, { orderable: X = !0, removable: V = !0, copyable: ie = !1 } = Qe(R, z), Y = {
      moveUp: X && s,
      moveDown: X && l,
      copy: ie && a,
      remove: V && i,
      toolbar: !1
    };
    return Y.toolbar = Object.keys(Y).some((H) => Y[H]), {
      children: P(L, { name: o, title: S, index: n, schema: c, uiSchema: f, formData: u, formContext: T, errorSchema: p, idPrefix: v, idSeparator: E, idSchema: d, required: this.isItemRequired(c), onChange: this.onChangeForIndex(n), onBlur: $, onFocus: b, registry: C, disabled: m, readonly: I, hideError: w, autofocus: h, rawErrors: g }),
      className: "array-item",
      disabled: m,
      canAdd: a,
      hasCopy: Y.copy,
      hasToolbar: Y.toolbar,
      hasMoveUp: Y.moveUp,
      hasMoveDown: Y.moveDown,
      hasRemove: Y.remove,
      index: n,
      totalItems: y,
      key: r,
      onAddIndexClick: this.onAddIndexClick,
      onCopyIndexClick: this.onCopyIndexClick,
      onDropIndexClick: this.onDropIndexClick,
      onReorderClick: this.onReorderClick,
      readonly: I,
      registry: C,
      schema: c,
      uiSchema: f
    };
  }
}
function pj(e) {
  var t, r, n;
  const { schema: o, name: a, uiSchema: i, idSchema: s, formData: l, registry: c, required: u, disabled: f, readonly: d, hideError: p, autofocus: h, title: $, onChange: b, onFocus: g, onBlur: y, rawErrors: S } = e, { title: m } = o, { widgets: w, formContext: v, translateString: E, globalUiOptions: I } = c, {
    widget: R = "checkbox",
    title: C,
    // Unlike the other fields, don't use `getDisplayLabel()` since it always returns false for the boolean type
    label: T = !0,
    ...F
  } = Qe(i, I), D = In(o, R, w), z = E(ot.YesLabel), L = E(ot.NoLabel);
  let X;
  const V = (r = (t = C ?? m) !== null && t !== void 0 ? t : $) !== null && r !== void 0 ? r : a;
  if (Array.isArray(o.oneOf))
    X = bl({
      oneOf: o.oneOf.map((ie) => {
        if (Ur(ie))
          return {
            ...ie,
            title: ie.title || (ie.const === !0 ? z : L)
          };
      }).filter((ie) => ie)
      // cast away the error that typescript can't grok is fixed
    }, i);
  else {
    const ie = o, Y = (n = o.enum) !== null && n !== void 0 ? n : [!0, !1];
    !ie.enumNames && Y.length === 2 && Y.every((H) => typeof H == "boolean") ? X = [
      {
        value: Y[0],
        label: Y[0] ? z : L
      },
      {
        value: Y[1],
        label: Y[1] ? z : L
      }
    ] : X = bl({
      enum: Y,
      // NOTE: enumNames is deprecated, but still supported for now.
      enumNames: ie.enumNames
    }, i);
  }
  return P(D, { options: { ...F, enumOptions: X }, schema: o, uiSchema: i, id: s.$id, name: a, onChange: b, onFocus: g, onBlur: y, label: V, hideLabel: !T, value: l, required: u, disabled: f, readonly: d, hideError: p, registry: c, formContext: v, autofocus: h, rawErrors: S });
}
class mm extends Ji {
  /** Constructs an `AnyOfField` with the given `props` to initialize the initially selected option in state
   *
   * @param props - The `FieldProps` for this template
   */
  constructor(t) {
    super(t), this.onOptionChange = (i) => {
      const { selectedOption: s, retrievedOptions: l } = this.state, { formData: c, onChange: u, registry: f } = this.props, { schemaUtils: d } = f, p = i !== void 0 ? parseInt(i, 10) : -1;
      if (p === s)
        return;
      const h = p >= 0 ? l[p] : void 0, $ = s >= 0 ? l[s] : void 0;
      let b = d.sanitizeDataForNewSchema(h, $, c);
      h && (b = d.getDefaultFormState(h, b, "excludeObjectChildren")), this.setState({ selectedOption: p }, () => {
        u(b, void 0, this.getFieldId());
      });
    };
    const { formData: r, options: n, registry: { schemaUtils: o } } = this.props, a = n.map((i) => o.retrieveSchema(i, r));
    this.state = {
      retrievedOptions: a,
      selectedOption: this.getMatchingOption(0, r, a)
    };
  }
  /** React lifecycle method that is called when the props and/or state for this component is updated. It recomputes the
   * currently selected option based on the overall `formData`
   *
   * @param prevProps - The previous `FieldProps` for this template
   * @param prevState - The previous `AnyOfFieldState` for this template
   */
  componentDidUpdate(t, r) {
    const { formData: n, options: o, idSchema: a } = this.props, { selectedOption: i } = this.state;
    let s = this.state;
    if (!pr(t.options, o)) {
      const { registry: { schemaUtils: l } } = this.props, c = o.map((u) => l.retrieveSchema(u, n));
      s = { selectedOption: i, retrievedOptions: c };
    }
    if (!pr(n, t.formData) && a.$id === t.idSchema.$id) {
      const { retrievedOptions: l } = s, c = this.getMatchingOption(i, n, l);
      r && c !== i && (s = { selectedOption: c, retrievedOptions: l });
    }
    s !== this.state && this.setState(s);
  }
  /** Determines the best matching option for the given `formData` and `options`.
   *
   * @param formData - The new formData
   * @param options - The list of options to choose from
   * @return - The index of the `option` that best matches the `formData`
   */
  getMatchingOption(t, r, n) {
    const { schema: o, registry: { schemaUtils: a } } = this.props, i = ya(o);
    return a.getClosestMatchingOption(r, n, t, i);
  }
  getFieldId() {
    const { idSchema: t, schema: r } = this.props;
    return `${t.$id}${r.oneOf ? "__oneof_select" : "__anyof_select"}`;
  }
  /** Renders the `AnyOfField` selector along with a `SchemaField` for the value of the `formData`
   */
  render() {
    const { name: t, disabled: r = !1, errorSchema: n = {}, formContext: o, onBlur: a, onFocus: i, registry: s, schema: l, uiSchema: c } = this.props, { widgets: u, fields: f, translateString: d, globalUiOptions: p, schemaUtils: h } = s, { SchemaField: $ } = f, { selectedOption: b, retrievedOptions: g } = this.state, { widget: y = "select", placeholder: S, autofocus: m, autocomplete: w, title: v = l.title, ...E } = Qe(c, p), I = In({ type: "number" }, y, u), R = xe(n, kr, []), C = hl(n, [kr]), T = h.getDisplayLabel(l, c, p), F = b >= 0 && g[b] || null;
    let D;
    if (F) {
      const { required: Y } = l;
      D = Y ? jn({ required: Y }, F) : F;
    }
    let z = [];
    zr in l && c && zr in c ? Array.isArray(c[zr]) ? z = c[zr] : console.warn(`uiSchema.oneOf is not an array for "${v || t}"`) : hn in l && c && hn in c && (Array.isArray(c[hn]) ? z = c[hn] : console.warn(`uiSchema.anyOf is not an array for "${v || t}"`));
    let L = c;
    b >= 0 && z.length > b && (L = z[b]);
    const X = v ? ot.TitleOptionPrefix : ot.OptionPrefix, V = v ? [v] : [], ie = g.map((Y, H) => {
      const { title: j = Y.title } = Qe(z[H]);
      return {
        label: j || d(X, V.concat(String(H + 1))),
        value: H
      };
    });
    return ue("div", { className: "panel panel-default panel-body", children: [P("div", { className: "form-group", children: P(I, { id: this.getFieldId(), name: `${t}${l.oneOf ? "__oneof_select" : "__anyof_select"}`, schema: { type: "number", default: 0 }, onChange: this.onOptionChange, onBlur: a, onFocus: i, disabled: r || io(ie), multiple: !1, rawErrors: R, errorSchema: C, value: b >= 0 ? b : void 0, options: { enumOptions: ie, ...E }, registry: s, formContext: o, placeholder: S, autocomplete: w, autofocus: m, label: v ?? t, hideLabel: !T }) }), D && P($, { ...this.props, schema: D, uiSchema: L })] });
  }
}
const hj = /\.([0-9]*0)*$/, mj = /[0.]0*$/;
function gj(e) {
  const { registry: t, onChange: r, formData: n, value: o } = e, [a, i] = Or(o), { StringField: s } = t.fields;
  let l = n;
  const c = Pt((u, f, d) => {
    i(u), `${u}`.charAt(0) === "." && (u = `0${u}`);
    const p = typeof u == "string" && u.match(hj) ? Kp(u.replace(mj, "")) : Kp(u);
    r(p, f, d);
  }, [r]);
  if (typeof a == "string" && typeof l == "number") {
    const u = new RegExp(`^(${String(l).replace(".", "\\.")})?\\.?0*$`);
    a.match(u) && (l = a);
  }
  return P(s, { ...e, formData: l, onChange: c });
}
function So() {
  return So = Object.assign ? Object.assign.bind() : function(e) {
    for (var t = 1; t < arguments.length; t++) {
      var r = arguments[t];
      for (var n in r) Object.prototype.hasOwnProperty.call(r, n) && (e[n] = r[n]);
    }
    return e;
  }, So.apply(this, arguments);
}
const yj = ["children", "options"], Te = { blockQuote: "0", breakLine: "1", breakThematic: "2", codeBlock: "3", codeFenced: "4", codeInline: "5", footnote: "6", footnoteReference: "7", gfmTask: "8", heading: "9", headingSetext: "10", htmlBlock: "11", htmlComment: "12", htmlSelfClosing: "13", image: "14", link: "15", linkAngleBraceStyleDetector: "16", linkBareUrlDetector: "17", linkMailtoDetector: "18", newlineCoalescer: "19", orderedList: "20", paragraph: "21", ref: "22", refImage: "23", refLink: "24", table: "25", tableSeparator: "26", text: "27", textBolded: "28", textEmphasized: "29", textEscaped: "30", textMarked: "31", textStrikethroughed: "32", unorderedList: "33" };
var gm;
(function(e) {
  e[e.MAX = 0] = "MAX", e[e.HIGH = 1] = "HIGH", e[e.MED = 2] = "MED", e[e.LOW = 3] = "LOW", e[e.MIN = 4] = "MIN";
})(gm || (gm = {}));
const ym = ["allowFullScreen", "allowTransparency", "autoComplete", "autoFocus", "autoPlay", "cellPadding", "cellSpacing", "charSet", "classId", "colSpan", "contentEditable", "contextMenu", "crossOrigin", "encType", "formAction", "formEncType", "formMethod", "formNoValidate", "formTarget", "frameBorder", "hrefLang", "inputMode", "keyParams", "keyType", "marginHeight", "marginWidth", "maxLength", "mediaGroup", "minLength", "noValidate", "radioGroup", "readOnly", "rowSpan", "spellCheck", "srcDoc", "srcLang", "srcSet", "tabIndex", "useMap"].reduce((e, t) => (e[t.toLowerCase()] = t, e), { class: "className", for: "htmlFor" }), bm = { amp: "&", apos: "'", gt: ">", lt: "<", nbsp: " ", quot: "“" }, bj = ["style", "script"], vj = /([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi, $j = /mailto:/i, Sj = /\n{2,}$/, db = /^(\s*>[\s\S]*?)(?=\n\n|$)/, wj = /^ *> ?/gm, Cj = /^(?:\[!([^\]]*)\]\n)?([\s\S]*)/, Ej = /^ {2,}\n/, _j = /^(?:( *[-*_])){3,} *(?:\n *)+\n/, fb = /^(?: {1,3})?(`{3,}|~{3,}) *(\S+)? *([^\n]*?)?\n([\s\S]*?)(?:\1\n?|$)/, pb = /^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/, xj = /^(`+)((?:\\`|[^`])+)\1/, Pj = /^(?:\n *)*\n/, kj = /\r\n?/g, Oj = /^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/, Aj = /^\[\^([^\]]+)]/, Ij = /\f/g, Rj = /^---[ \t]*\n(.|\n)*\n---[ \t]*\n/, Tj = /^\s*?\[(x|\s)\]/, hb = /^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, mb = /^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, gb = /^([^\n]+)\n *(=|-){3,} *(?:\n *)+\n/, Nu = /^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i, Mj = /&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi, yb = /^<!--[\s\S]*?(?:-->)/, Nj = /^(data|aria|x)-[a-z_][a-z\d_.-]*$/, Fu = /^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i, Fj = /^\{.*\}$/, jj = /^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/, Dj = /^<([^ >]+@[^ >]+)>/, Lj = /^<([^ >]+:\/[^ >]+)>/, Bj = /-([a-z])?/gi, bb = /^(\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/, zj = /^\[([^\]]*)\]:\s+<?([^\s>]+)>?\s*("([^"]*)")?/, Uj = /^!\[([^\]]*)\] ?\[([^\]]*)\]/, Vj = /^\[([^\]]*)\] ?\[([^\]]*)\]/, qj = /(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/, Wj = /\t/g, Kj = /(^ *\||\| *$)/g, Gj = /^ *:-+: *$/, Hj = /^ *:-+ *$/, Jj = /^ *-+: *$/, rc = "((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|\\\\\\1|[\\s\\S])+?)", Yj = new RegExp(`^([*_])\\1${rc}\\1\\1(?!\\1)`), Xj = new RegExp(`^([*_])${rc}\\1(?!\\1)`), Zj = new RegExp(`^(==)${rc}\\1`), Qj = new RegExp(`^(~~)${rc}\\1`), e6 = /^\\([^0-9A-Za-z\s])/, eu = /\\([^0-9A-Za-z\s])/g, t6 = /^([\s\S](?:(?!  |[0-9]\.)[^*_~\-\n<`\\\[!])*)/, r6 = /^\n+/, n6 = /^([ \t]*)/, o6 = /\\([^\\])/g, a6 = /(?:^|\n)( *)$/, cf = "(?:\\d+\\.)", uf = "(?:[*+-])";
function vb(e) {
  return "( *)(" + (e === 1 ? cf : uf) + ") +";
}
const $b = vb(1), Sb = vb(2);
function wb(e) {
  return new RegExp("^" + (e === 1 ? $b : Sb));
}
const i6 = wb(1), s6 = wb(2);
function Cb(e) {
  return new RegExp("^" + (e === 1 ? $b : Sb) + "[^\\n]*(?:\\n(?!\\1" + (e === 1 ? cf : uf) + " )[^\\n]*)*(\\n|$)", "gm");
}
const l6 = Cb(1), c6 = Cb(2);
function Eb(e) {
  const t = e === 1 ? cf : uf;
  return new RegExp("^( *)(" + t + ") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1" + t + " (?!" + t + " ))\\n*|\\s*\\n*$)");
}
const _b = Eb(1), xb = Eb(2);
function vm(e, t) {
  const r = t === 1, n = r ? _b : xb, o = r ? l6 : c6, a = r ? i6 : s6;
  return { match: va(function(i, s) {
    const l = a6.exec(s.prevCapture);
    return l && (s.list || !s.inline && !s.simple) ? n.exec(i = l[1] + i) : null;
  }), order: 1, parse(i, s, l) {
    const c = r ? +i[2] : void 0, u = i[0].replace(Sj, `
`).match(o);
    let f = !1;
    return { items: u.map(function(d, p) {
      const h = a.exec(d)[0].length, $ = new RegExp("^ {1," + h + "}", "gm"), b = d.replace($, "").replace(a, ""), g = p === u.length - 1, y = b.indexOf(`

`) !== -1 || g && f;
      f = y;
      const S = l.inline, m = l.list;
      let w;
      l.list = !0, y ? (l.inline = !1, w = Li(b) + `

`) : (l.inline = !0, w = Li(b));
      const v = s(w, l);
      return l.inline = S, l.list = m, v;
    }), ordered: r, start: c };
  }, render: (i, s, l) => e(i.ordered ? "ol" : "ul", { key: l.key, start: i.type === Te.orderedList ? i.start : void 0 }, i.items.map(function(c, u) {
    return e("li", { key: u }, s(c, l));
  })) };
}
const u6 = new RegExp(`^\\[((?:\\[[^\\]]*\\]|[^\\[\\]]|\\](?=[^\\[]*\\]))*)\\]\\(\\s*<?((?:\\([^)]*\\)|[^\\s\\\\]|\\\\.)*?)>?(?:\\s+['"]([\\s\\S]*?)['"])?\\s*\\)`), d6 = /^!\[(.*?)\]\( *((?:\([^)]*\)|[^() ])*) *"?([^)"]*)?"?\)/, Pb = [db, fb, pb, hb, gb, mb, bb, _b, xb], f6 = [...Pb, /^[^\n]+(?:  \n|\n{2,})/, Nu, yb, Fu];
function Li(e) {
  let t = e.length;
  for (; t > 0 && e[t - 1] <= " "; ) t--;
  return e.slice(0, t);
}
function ri(e) {
  return e.replace(/[ÀÁÂÃÄÅàáâãäåæÆ]/g, "a").replace(/[çÇ]/g, "c").replace(/[ðÐ]/g, "d").replace(/[ÈÉÊËéèêë]/g, "e").replace(/[ÏïÎîÍíÌì]/g, "i").replace(/[Ññ]/g, "n").replace(/[øØœŒÕõÔôÓóÒò]/g, "o").replace(/[ÜüÛûÚúÙù]/g, "u").replace(/[ŸÿÝý]/g, "y").replace(/[^a-z0-9- ]/gi, "").replace(/ /gi, "-").toLowerCase();
}
function p6(e) {
  return Jj.test(e) ? "right" : Gj.test(e) ? "center" : Hj.test(e) ? "left" : null;
}
function $m(e, t, r, n) {
  const o = r.inTable;
  r.inTable = !0;
  let a = [[]], i = "";
  function s() {
    if (!i) return;
    const l = a[a.length - 1];
    l.push.apply(l, t(i, r)), i = "";
  }
  return e.trim().split(/(`[^`]*`|\\\||\|)/).filter(Boolean).forEach((l, c, u) => {
    l.trim() === "|" && (s(), n) ? c !== 0 && c !== u.length - 1 && a.push([]) : i += l;
  }), s(), r.inTable = o, a;
}
function h6(e, t, r) {
  r.inline = !0;
  const n = e[2] ? e[2].replace(Kj, "").split("|").map(p6) : [], o = e[3] ? function(i, s, l) {
    return i.trim().split(`
`).map(function(c) {
      return $m(c, s, l, !0);
    });
  }(e[3], t, r) : [], a = $m(e[1], t, r, !!o.length);
  return r.inline = !1, o.length ? { align: n, cells: o, header: a, type: Te.table } : { children: a, type: Te.paragraph };
}
function Sm(e, t) {
  return e.align[t] == null ? {} : { textAlign: e.align[t] };
}
function va(e) {
  return e.inline = 1, e;
}
function Kn(e) {
  return va(function(t, r) {
    return r.inline ? e.exec(t) : null;
  });
}
function Gn(e) {
  return va(function(t, r) {
    return r.inline || r.simple ? e.exec(t) : null;
  });
}
function kn(e) {
  return function(t, r) {
    return r.inline || r.simple ? null : e.exec(t);
  };
}
function ni(e) {
  return va(function(t) {
    return e.exec(t);
  });
}
function m6(e, t) {
  if (t.inline || t.simple) return null;
  let r = "";
  e.split(`
`).every((o) => (o += `
`, !Pb.some((a) => a.test(o)) && (r += o, !!o.trim())));
  const n = Li(r);
  return n == "" ? null : [r, , n];
}
function g6(e) {
  try {
    if (decodeURIComponent(e).replace(/[^A-Za-z0-9/:]/g, "").match(/^\s*(javascript|vbscript|data(?!:image)):/i)) return null;
  } catch {
    return null;
  }
  return e;
}
function wm(e) {
  return e.replace(o6, "$1");
}
function Qs(e, t, r) {
  const n = r.inline || !1, o = r.simple || !1;
  r.inline = !0, r.simple = !0;
  const a = e(t, r);
  return r.inline = n, r.simple = o, a;
}
function y6(e, t, r) {
  const n = r.inline || !1, o = r.simple || !1;
  r.inline = !1, r.simple = !0;
  const a = e(t, r);
  return r.inline = n, r.simple = o, a;
}
function b6(e, t, r) {
  const n = r.inline || !1;
  r.inline = !1;
  const o = e(t, r);
  return r.inline = n, o;
}
const tu = (e, t, r) => ({ children: Qs(t, e[2], r) });
function ru() {
  return {};
}
function nu() {
  return null;
}
function v6(...e) {
  return e.filter(Boolean).join(" ");
}
function ou(e, t, r) {
  let n = e;
  const o = t.split(".");
  for (; o.length && (n = n[o[0]], n !== void 0); ) o.shift();
  return n || r;
}
function $6(e = "", t = {}) {
  function r(d, p, ...h) {
    const $ = ou(t.overrides, `${d}.props`, {});
    return t.createElement(function(b, g) {
      const y = ou(g, b);
      return y ? typeof y == "function" || typeof y == "object" && "render" in y ? y : ou(g, `${b}.component`, b) : b;
    }(d, t.overrides), So({}, p, $, { className: v6(p == null ? void 0 : p.className, $.className) || void 0 }), ...h);
  }
  function n(d) {
    d = d.replace(Rj, "");
    let p = !1;
    t.forceInline ? p = !0 : t.forceBlock || (p = qj.test(d) === !1);
    const h = c(l(p ? d : `${Li(d).replace(r6, "")}

`, { inline: p }));
    for (; typeof h[h.length - 1] == "string" && !h[h.length - 1].trim(); ) h.pop();
    if (t.wrapper === null) return h;
    const $ = t.wrapper || (p ? "span" : "div");
    let b;
    if (h.length > 1 || t.forceWrapper) b = h;
    else {
      if (h.length === 1) return b = h[0], typeof b == "string" ? r("span", { key: "outer" }, b) : b;
      b = null;
    }
    return t.createElement($, { key: "outer" }, b);
  }
  function o(d, p) {
    const h = p.match(vj);
    return h ? h.reduce(function($, b) {
      const g = b.indexOf("=");
      if (g !== -1) {
        const y = function(v) {
          return v.indexOf("-") !== -1 && v.match(Nj) === null && (v = v.replace(Bj, function(E, I) {
            return I.toUpperCase();
          })), v;
        }(b.slice(0, g)).trim(), S = function(v) {
          const E = v[0];
          return (E === '"' || E === "'") && v.length >= 2 && v[v.length - 1] === E ? v.slice(1, -1) : v;
        }(b.slice(g + 1).trim()), m = ym[y] || y;
        if (m === "ref") return $;
        const w = $[m] = function(v, E, I, R) {
          return E === "style" ? I.split(/;\s?/).reduce(function(C, T) {
            const F = T.slice(0, T.indexOf(":"));
            return C[F.trim().replace(/(-[a-z])/g, (D) => D[1].toUpperCase())] = T.slice(F.length + 1).trim(), C;
          }, {}) : E === "href" || E === "src" ? R(I, v, E) : (I.match(Fj) && (I = I.slice(1, I.length - 1)), I === "true" || I !== "false" && I);
        }(d, y, S, t.sanitizer);
        typeof w == "string" && (Nu.test(w) || Fu.test(w)) && ($[m] = n(w.trim()));
      } else b !== "style" && ($[ym[b] || b] = !0);
      return $;
    }, {}) : null;
  }
  t.overrides = t.overrides || {}, t.sanitizer = t.sanitizer || g6, t.slugify = t.slugify || ri, t.namedCodesToUnicode = t.namedCodesToUnicode ? So({}, bm, t.namedCodesToUnicode) : bm, t.createElement = t.createElement || M.createElement;
  const a = [], i = {}, s = { [Te.blockQuote]: { match: kn(db), order: 1, parse(d, p, h) {
    const [, $, b] = d[0].replace(wj, "").match(Cj);
    return { alert: $, children: p(b, h) };
  }, render(d, p, h) {
    const $ = { key: h.key };
    return d.alert && ($.className = "markdown-alert-" + t.slugify(d.alert.toLowerCase(), ri), d.children.unshift({ attrs: {}, children: [{ type: Te.text, text: d.alert }], noInnerParse: !0, type: Te.htmlBlock, tag: "header" })), r("blockquote", $, p(d.children, h));
  } }, [Te.breakLine]: { match: ni(Ej), order: 1, parse: ru, render: (d, p, h) => r("br", { key: h.key }) }, [Te.breakThematic]: { match: kn(_j), order: 1, parse: ru, render: (d, p, h) => r("hr", { key: h.key }) }, [Te.codeBlock]: { match: kn(pb), order: 0, parse: (d) => ({ lang: void 0, text: Li(d[0].replace(/^ {4}/gm, "")).replace(eu, "$1") }), render: (d, p, h) => r("pre", { key: h.key }, r("code", So({}, d.attrs, { className: d.lang ? `lang-${d.lang}` : "" }), d.text)) }, [Te.codeFenced]: { match: kn(fb), order: 0, parse: (d) => ({ attrs: o("code", d[3] || ""), lang: d[2] || void 0, text: d[4].replace(eu, "$1"), type: Te.codeBlock }) }, [Te.codeInline]: { match: Gn(xj), order: 3, parse: (d) => ({ text: d[2].replace(eu, "$1") }), render: (d, p, h) => r("code", { key: h.key }, d.text) }, [Te.footnote]: { match: kn(Oj), order: 0, parse: (d) => (a.push({ footnote: d[2], identifier: d[1] }), {}), render: nu }, [Te.footnoteReference]: { match: Kn(Aj), order: 1, parse: (d) => ({ target: `#${t.slugify(d[1], ri)}`, text: d[1] }), render: (d, p, h) => r("a", { key: h.key, href: t.sanitizer(d.target, "a", "href") }, r("sup", { key: h.key }, d.text)) }, [Te.gfmTask]: { match: Kn(Tj), order: 1, parse: (d) => ({ completed: d[1].toLowerCase() === "x" }), render: (d, p, h) => r("input", { checked: d.completed, key: h.key, readOnly: !0, type: "checkbox" }) }, [Te.heading]: { match: kn(t.enforceAtxHeadings ? mb : hb), order: 1, parse: (d, p, h) => ({ children: Qs(p, d[2], h), id: t.slugify(d[2], ri), level: d[1].length }), render: (d, p, h) => r(`h${d.level}`, { id: d.id, key: h.key }, p(d.children, h)) }, [Te.headingSetext]: { match: kn(gb), order: 0, parse: (d, p, h) => ({ children: Qs(p, d[1], h), level: d[2] === "=" ? 1 : 2, type: Te.heading }) }, [Te.htmlBlock]: { match: ni(Nu), order: 1, parse(d, p, h) {
    const [, $] = d[3].match(n6), b = new RegExp(`^${$}`, "gm"), g = d[3].replace(b, ""), y = (S = g, f6.some((I) => I.test(S)) ? b6 : Qs);
    var S;
    const m = d[1].toLowerCase(), w = bj.indexOf(m) !== -1, v = (w ? m : d[1]).trim(), E = { attrs: o(v, d[2]), noInnerParse: w, tag: v };
    return h.inAnchor = h.inAnchor || m === "a", w ? E.text = d[3] : E.children = y(p, g, h), h.inAnchor = !1, E;
  }, render: (d, p, h) => r(d.tag, So({ key: h.key }, d.attrs), d.text || (d.children ? p(d.children, h) : "")) }, [Te.htmlSelfClosing]: { match: ni(Fu), order: 1, parse(d) {
    const p = d[1].trim();
    return { attrs: o(p, d[2] || ""), tag: p };
  }, render: (d, p, h) => r(d.tag, So({}, d.attrs, { key: h.key })) }, [Te.htmlComment]: { match: ni(yb), order: 1, parse: () => ({}), render: nu }, [Te.image]: { match: Gn(d6), order: 1, parse: (d) => ({ alt: d[1], target: wm(d[2]), title: d[3] }), render: (d, p, h) => r("img", { key: h.key, alt: d.alt || void 0, title: d.title || void 0, src: t.sanitizer(d.target, "img", "src") }) }, [Te.link]: { match: Kn(u6), order: 3, parse: (d, p, h) => ({ children: y6(p, d[1], h), target: wm(d[2]), title: d[3] }), render: (d, p, h) => r("a", { key: h.key, href: t.sanitizer(d.target, "a", "href"), title: d.title }, p(d.children, h)) }, [Te.linkAngleBraceStyleDetector]: { match: Kn(Lj), order: 0, parse: (d) => ({ children: [{ text: d[1], type: Te.text }], target: d[1], type: Te.link }) }, [Te.linkBareUrlDetector]: { match: va((d, p) => p.inAnchor || t.disableAutoLink ? null : Kn(jj)(d, p)), order: 0, parse: (d) => ({ children: [{ text: d[1], type: Te.text }], target: d[1], title: void 0, type: Te.link }) }, [Te.linkMailtoDetector]: { match: Kn(Dj), order: 0, parse(d) {
    let p = d[1], h = d[1];
    return $j.test(h) || (h = "mailto:" + h), { children: [{ text: p.replace("mailto:", ""), type: Te.text }], target: h, type: Te.link };
  } }, [Te.orderedList]: vm(r, 1), [Te.unorderedList]: vm(r, 2), [Te.newlineCoalescer]: { match: kn(Pj), order: 3, parse: ru, render: () => `
` }, [Te.paragraph]: { match: va(m6), order: 3, parse: tu, render: (d, p, h) => r("p", { key: h.key }, p(d.children, h)) }, [Te.ref]: { match: Kn(zj), order: 0, parse: (d) => (i[d[1]] = { target: d[2], title: d[4] }, {}), render: nu }, [Te.refImage]: { match: Gn(Uj), order: 0, parse: (d) => ({ alt: d[1] || void 0, ref: d[2] }), render: (d, p, h) => i[d.ref] ? r("img", { key: h.key, alt: d.alt, src: t.sanitizer(i[d.ref].target, "img", "src"), title: i[d.ref].title }) : null }, [Te.refLink]: { match: Kn(Vj), order: 0, parse: (d, p, h) => ({ children: p(d[1], h), fallbackChildren: d[0], ref: d[2] }), render: (d, p, h) => i[d.ref] ? r("a", { key: h.key, href: t.sanitizer(i[d.ref].target, "a", "href"), title: i[d.ref].title }, p(d.children, h)) : r("span", { key: h.key }, d.fallbackChildren) }, [Te.table]: { match: kn(bb), order: 1, parse: h6, render(d, p, h) {
    const $ = d;
    return r("table", { key: h.key }, r("thead", null, r("tr", null, $.header.map(function(b, g) {
      return r("th", { key: g, style: Sm($, g) }, p(b, h));
    }))), r("tbody", null, $.cells.map(function(b, g) {
      return r("tr", { key: g }, b.map(function(y, S) {
        return r("td", { key: S, style: Sm($, S) }, p(y, h));
      }));
    })));
  } }, [Te.text]: { match: ni(t6), order: 4, parse: (d) => ({ text: d[0].replace(Mj, (p, h) => t.namedCodesToUnicode[h] ? t.namedCodesToUnicode[h] : p) }), render: (d) => d.text }, [Te.textBolded]: { match: Gn(Yj), order: 2, parse: (d, p, h) => ({ children: p(d[2], h) }), render: (d, p, h) => r("strong", { key: h.key }, p(d.children, h)) }, [Te.textEmphasized]: { match: Gn(Xj), order: 3, parse: (d, p, h) => ({ children: p(d[2], h) }), render: (d, p, h) => r("em", { key: h.key }, p(d.children, h)) }, [Te.textEscaped]: { match: Gn(e6), order: 1, parse: (d) => ({ text: d[1], type: Te.text }) }, [Te.textMarked]: { match: Gn(Zj), order: 3, parse: tu, render: (d, p, h) => r("mark", { key: h.key }, p(d.children, h)) }, [Te.textStrikethroughed]: { match: Gn(Qj), order: 3, parse: tu, render: (d, p, h) => r("del", { key: h.key }, p(d.children, h)) } };
  t.disableParsingRawHTML === !0 && (delete s[Te.htmlBlock], delete s[Te.htmlSelfClosing]);
  const l = function(d) {
    let p = Object.keys(d);
    function h($, b) {
      let g, y, S = [], m = "", w = "";
      for (b.prevCapture = b.prevCapture || ""; $; ) {
        let v = 0;
        for (; v < p.length; ) {
          if (m = p[v], g = d[m], b.inline && !g.match.inline) {
            v++;
            continue;
          }
          const E = g.match($, b);
          if (E) {
            w = E[0], b.prevCapture += w, $ = $.substring(w.length), y = g.parse(E, h, b), y.type == null && (y.type = m), S.push(y);
            break;
          }
          v++;
        }
      }
      return b.prevCapture = "", S;
    }
    return p.sort(function($, b) {
      let g = d[$].order, y = d[b].order;
      return g !== y ? g - y : $ < b ? -1 : 1;
    }), function($, b) {
      return h(function(g) {
        return g.replace(kj, `
`).replace(Ij, "").replace(Wj, "    ");
      }($), b);
    };
  }(s), c = (u = /* @__PURE__ */ function(d, p) {
    return function(h, $, b) {
      const g = d[h.type].render;
      return p ? p(() => g(h, $, b), h, $, b) : g(h, $, b);
    };
  }(s, t.renderRule), function d(p, h = {}) {
    if (Array.isArray(p)) {
      const $ = h.key, b = [];
      let g = !1;
      for (let y = 0; y < p.length; y++) {
        h.key = y;
        const S = d(p[y], h), m = typeof S == "string";
        m && g ? b[b.length - 1] += S : S !== null && b.push(S), g = m;
      }
      return h.key = $, b;
    }
    return u(p, d, h);
  });
  var u;
  const f = n(e);
  return a.length ? r("div", null, f, r("footer", { key: "footer" }, a.map(function(d) {
    return r("div", { id: t.slugify(d.identifier, ri), key: d.identifier }, d.identifier, c(l(d.footnote, { inline: !0 })));
  }))) : f;
}
const nc = (e) => {
  let { children: t = "", options: r } = e, n = function(o, a) {
    if (o == null) return {};
    var i, s, l = {}, c = Object.keys(o);
    for (s = 0; s < c.length; s++) a.indexOf(i = c[s]) >= 0 || (l[i] = o[i]);
    return l;
  }(e, yj);
  return M.cloneElement($6(t, r), n);
};
var S6 = Yy;
function w6(e, t) {
  return e == null ? !0 : S6(e, t);
}
var C6 = w6;
const E6 = /* @__PURE__ */ pt(C6);
class _6 extends Ji {
  constructor() {
    super(...arguments), this.state = {
      wasPropertyKeyModified: !1,
      additionalProperties: {}
    }, this.onPropertyChange = (t, r = !1) => (n, o, a) => {
      const { formData: i, onChange: s, errorSchema: l } = this.props;
      n === void 0 && r && (n = "");
      const c = { ...i, [t]: n };
      s(c, l && l && {
        ...l,
        [t]: o
      }, a);
    }, this.onDropPropertyClick = (t) => (r) => {
      r.preventDefault();
      const { onChange: n, formData: o } = this.props, a = { ...o };
      E6(a, t), n(a);
    }, this.getAvailableKey = (t, r) => {
      const { uiSchema: n, registry: o } = this.props, { duplicateKeySuffixSeparator: a = "-" } = Qe(n, o.globalUiOptions);
      let i = 0, s = t;
      for (; fr(r, s); )
        s = `${t}${a}${++i}`;
      return s;
    }, this.onKeyChange = (t) => (r, n) => {
      if (t === r)
        return;
      const { formData: o, onChange: a, errorSchema: i } = this.props;
      r = this.getAvailableKey(r, o);
      const s = {
        ...o
      }, l = { [t]: r }, c = Object.keys(s).map((f) => ({ [l[f] || f]: s[f] })), u = Object.assign({}, ...c);
      this.setState({ wasPropertyKeyModified: !0 }), a(u, i && i && {
        ...i,
        [r]: n
      });
    }, this.handleAddClick = (t) => () => {
      var r;
      if (!t.additionalProperties)
        return;
      const { formData: n, onChange: o, registry: a } = this.props, i = { ...n };
      let s, l, c;
      if (Ur(t.additionalProperties)) {
        s = t.additionalProperties.type, l = t.additionalProperties.const, c = t.additionalProperties.default;
        let d = t.additionalProperties;
        if (Ht in d) {
          const { schemaUtils: p } = a;
          d = p.retrieveSchema({ $ref: d[Ht] }, n), s = d.type, l = d.const, c = d.default;
        }
        !s && (hn in d || zr in d) && (s = "object");
      }
      const u = this.getAvailableKey("newKey", i), f = (r = l ?? c) !== null && r !== void 0 ? r : this.getDefaultValue(s);
      er(i, u, f), o(i);
    };
  }
  /** Returns a flag indicating whether the `name` field is required in the object schema
   *
   * @param name - The name of the field to check for required-ness
   * @returns - True if the field `name` is required, false otherwise
   */
  isRequired(t) {
    const { schema: r } = this.props;
    return Array.isArray(r.required) && r.required.indexOf(t) !== -1;
  }
  /** Returns a default value to be used for a new additional schema property of the given `type`
   *
   * @param type - The type of the new additional schema property
   */
  getDefaultValue(t) {
    const { registry: { translateString: r } } = this.props;
    switch (t) {
      case "array":
        return [];
      case "boolean":
        return !1;
      case "null":
        return null;
      case "number":
        return 0;
      case "object":
        return {};
      case "string":
      default:
        return r(ot.NewStringDefault);
    }
  }
  /** Renders the `ObjectField` from the given props
   */
  render() {
    var t, r, n, o;
    const { schema: a, uiSchema: i = {}, formData: s, errorSchema: l, idSchema: c, name: u, required: f = !1, disabled: d, readonly: p, hideError: h, idPrefix: $, idSeparator: b, onBlur: g, onFocus: y, registry: S, title: m } = this.props, { fields: w, formContext: v, schemaUtils: E, translateString: I, globalUiOptions: R } = S, { SchemaField: C } = w, T = E.retrieveSchema(a, s), F = Qe(i, R), { properties: D = {} } = T, z = (n = (r = (t = F.title) !== null && t !== void 0 ? t : T.title) !== null && r !== void 0 ? r : m) !== null && n !== void 0 ? n : u, L = (o = F.description) !== null && o !== void 0 ? o : T.description;
    let X;
    try {
      const Y = Object.keys(D);
      X = jF(Y, F.order);
    } catch (Y) {
      return ue("div", { children: [P("p", { className: "config-error", style: { color: "red" }, children: P(nc, { options: { disableParsingRawHTML: !0 }, children: I(ot.InvalidObjectField, [u || "root", Y.message]) }) }), P("pre", { children: JSON.stringify(T) })] });
    }
    const V = Ye("ObjectFieldTemplate", S, F), ie = {
      // getDisplayLabel() always returns false for object types, so just check the `uiOptions.label`
      title: F.label === !1 ? "" : z,
      description: F.label === !1 ? void 0 : L,
      properties: X.map((Y) => {
        const H = fr(T, [Mt, Y, ka]), j = H ? i.additionalProperties : i[Y], Q = Qe(j).widget === "hidden", q = xe(c, [Y], {});
        return {
          content: P(C, { name: Y, required: this.isRequired(Y), schema: xe(T, [Mt, Y], {}), uiSchema: j, errorSchema: xe(l, Y), idSchema: q, idPrefix: $, idSeparator: b, formData: xe(s, Y), formContext: v, wasPropertyKeyModified: this.state.wasPropertyKeyModified, onKeyChange: this.onKeyChange(Y), onChange: this.onPropertyChange(Y, H), onBlur: g, onFocus: y, registry: S, disabled: d, readonly: p, hideError: h, onDropPropertyClick: this.onDropPropertyClick }, Y),
          name: Y,
          readonly: p,
          disabled: d,
          required: f,
          hidden: Q
        };
      }),
      readonly: p,
      disabled: d,
      required: f,
      idSchema: c,
      uiSchema: i,
      errorSchema: l,
      schema: T,
      formData: s,
      formContext: v,
      registry: S
    };
    return P(V, { ...ie, onAddClick: this.handleAddClick });
  }
}
const x6 = {
  array: "ArrayField",
  boolean: "BooleanField",
  integer: "NumberField",
  number: "NumberField",
  object: "ObjectField",
  string: "StringField",
  null: "NullField"
};
function P6(e, t, r, n) {
  const o = t.field, { fields: a, translateString: i } = n;
  if (typeof o == "function")
    return o;
  if (typeof o == "string" && o in a)
    return a[o];
  const s = so(e), l = Array.isArray(s) ? s[0] : s || "", c = e.$id;
  let u = x6[l];
  return c && c in a && (u = c), !u && (e.anyOf || e.oneOf) ? () => null : u in a ? a[u] : () => {
    const f = Ye("UnsupportedFieldTemplate", n, t);
    return P(f, { schema: e, idSchema: r, reason: i(ot.UnknownFieldType, [String(e.type)]), registry: n });
  };
}
function k6(e) {
  var t, r, n;
  const { schema: o, idSchema: a, uiSchema: i, formData: s, errorSchema: l, idPrefix: c, idSeparator: u, name: f, onChange: d, onKeyChange: p, onDropPropertyClick: h, required: $, registry: b, wasPropertyKeyModified: g = !1 } = e, { formContext: y, schemaUtils: S, globalUiOptions: m } = b, w = Qe(i, m), v = Ye("FieldTemplate", b, w), E = Ye("DescriptionFieldTemplate", b, w), I = Ye("FieldHelpTemplate", b, w), R = Ye("FieldErrorTemplate", b, w), C = S.retrieveSchema(o, s), T = a[Zn], F = to(S.toIdSchema(C, T, s, c, u), a), D = Pt((qe, se, Ze) => d(qe, se, Ze || T), [T, d]), z = P6(C, w, F, b), L = !!((t = w.disabled) !== null && t !== void 0 ? t : e.disabled), X = !!((r = w.readonly) !== null && r !== void 0 ? r : e.readonly || e.schema.readOnly || C.readOnly), V = w.hideError, ie = V === void 0 ? e.hideError : !!V, Y = !!((n = w.autofocus) !== null && n !== void 0 ? n : e.autofocus);
  if (Object.keys(C).length === 0)
    return null;
  const H = S.getDisplayLabel(C, i, m), { __errors: j, ...Q } = l || {}, q = hl(i, ["ui:classNames", "classNames", "ui:style"]);
  Si in q && (q[Si] = hl(q[Si], ["classNames", "style"]));
  const O = P(z, { ...e, onChange: D, idSchema: F, schema: C, uiSchema: q, disabled: L, readonly: X, hideError: ie, autofocus: Y, errorSchema: Q, formContext: y, rawErrors: j }), N = F[Zn];
  let W;
  g ? W = f : W = ka in C ? f : w.title || e.schema.title || C.title || e.title || f;
  const ne = w.description || e.schema.description || C.description || "", ee = w.enableMarkdownInDescription ? P(nc, { options: { disableParsingRawHTML: !0 }, children: ne }) : ne, pe = w.help, ce = w.widget === "hidden", ye = ["form-group", "field", `field-${so(C)}`];
  !ie && j && j.length > 0 && ye.push("field-error has-error has-danger"), i != null && i.classNames && ye.push(i.classNames), w.classNames && ye.push(w.classNames);
  const _e = P(I, { help: pe, idSchema: F, schema: C, uiSchema: i, hasErrors: !ie && j && j.length > 0, registry: b }), Me = ie || (C.anyOf || C.oneOf) && !S.isSelect(C) ? void 0 : P(R, { errors: j, errorSchema: l, idSchema: F, schema: C, uiSchema: i, registry: b }), Re = {
    description: P(E, { id: Lo(N), description: ee, schema: C, uiSchema: i, registry: b }),
    rawDescription: ne,
    help: _e,
    rawHelp: typeof pe == "string" ? pe : void 0,
    errors: Me,
    rawErrors: ie ? void 0 : j,
    id: N,
    label: W,
    hidden: ce,
    onChange: d,
    onKeyChange: p,
    onDropPropertyClick: h,
    required: $,
    disabled: L,
    readonly: X,
    hideError: ie,
    displayLabel: H,
    classNames: ye.join(" ").trim(),
    style: w.style,
    formContext: y,
    formData: s,
    schema: C,
    uiSchema: i,
    registry: b
  }, Ve = b.fields.AnyOfField, mt = b.fields.OneOfField, Ue = (i == null ? void 0 : i["ui:field"]) && (i == null ? void 0 : i["ui:fieldReplacesAnyOrOneOf"]) === !0;
  return P(v, { ...Re, children: ue(Wt, { children: [O, C.anyOf && !Ue && !S.isSelect(C) && P(Ve, { name: f, disabled: L, readonly: X, hideError: ie, errorSchema: l, formData: s, formContext: y, idPrefix: c, idSchema: F, idSeparator: u, onBlur: e.onBlur, onChange: e.onChange, onFocus: e.onFocus, options: C.anyOf.map((qe) => S.retrieveSchema(Ur(qe) ? qe : {}, s)), registry: b, required: $, schema: C, uiSchema: i }), C.oneOf && !Ue && !S.isSelect(C) && P(mt, { name: f, disabled: L, readonly: X, hideError: ie, errorSchema: l, formData: s, formContext: y, idPrefix: c, idSchema: F, idSeparator: u, onBlur: e.onBlur, onChange: e.onChange, onFocus: e.onFocus, options: C.oneOf.map((qe) => S.retrieveSchema(Ur(qe) ? qe : {}, s)), registry: b, required: $, schema: C, uiSchema: i })] }) });
}
let O6 = class extends Ji {
  shouldComponentUpdate(t) {
    return !pr(this.props, t);
  }
  render() {
    return P(k6, { ...this.props });
  }
};
function A6(e) {
  var t;
  const { schema: r, name: n, uiSchema: o, idSchema: a, formData: i, required: s, disabled: l = !1, readonly: c = !1, autofocus: u = !1, onChange: f, onBlur: d, onFocus: p, registry: h, rawErrors: $, hideError: b } = e, { title: g, format: y } = r, { widgets: S, formContext: m, schemaUtils: w, globalUiOptions: v } = h, E = w.isSelect(r) ? bl(r, o) : void 0;
  let I = E ? "select" : "text";
  y && MF(r, y, S) && (I = y);
  const { widget: R = I, placeholder: C = "", title: T, ...F } = Qe(o), D = w.getDisplayLabel(r, o, v), z = (t = T ?? g) !== null && t !== void 0 ? t : n, L = In(r, R, S);
  return P(L, { options: { ...F, enumOptions: E }, schema: r, uiSchema: o, id: a.$id, name: n, label: z, hideLabel: !D, hideError: b, value: i, onChange: f, onBlur: d, onFocus: p, required: s, disabled: l, readonly: c, formContext: m, autofocus: u, registry: h, placeholder: C, rawErrors: $ });
}
function I6(e) {
  const { formData: t, onChange: r } = e;
  return Ml(() => {
    t === void 0 && r(null);
  }, [t, r]), null;
}
function R6() {
  return {
    AnyOfField: mm,
    ArrayField: fj,
    // ArrayField falls back to SchemaField if ArraySchemaField is not defined, which it isn't by default
    BooleanField: pj,
    NumberField: gj,
    ObjectField: _6,
    OneOfField: mm,
    SchemaField: O6,
    StringField: A6,
    NullField: I6
  };
}
function T6(e) {
  const { idSchema: t, description: r, registry: n, schema: o, uiSchema: a } = e, i = Qe(a, n.globalUiOptions), { label: s = !0 } = i;
  if (!r || !s)
    return null;
  const l = Ye("DescriptionFieldTemplate", n, i);
  return P(l, { id: Lo(t), description: r, schema: o, uiSchema: a, registry: n });
}
function M6(e) {
  const { children: t, className: r, disabled: n, hasToolbar: o, hasMoveDown: a, hasMoveUp: i, hasRemove: s, hasCopy: l, index: c, onCopyIndexClick: u, onDropIndexClick: f, onReorderClick: d, readonly: p, registry: h, uiSchema: $ } = e, { CopyButton: b, MoveDownButton: g, MoveUpButton: y, RemoveButton: S } = h.templates.ButtonTemplates, m = {
    flex: 1,
    paddingLeft: 6,
    paddingRight: 6,
    fontWeight: "bold"
  };
  return ue("div", { className: r, children: [P("div", { className: o ? "col-xs-9" : "col-xs-12", children: t }), o && P("div", { className: "col-xs-3 array-item-toolbox", children: ue("div", { className: "btn-group", style: {
    display: "flex",
    justifyContent: "space-around"
  }, children: [(i || a) && P(y, { style: m, disabled: n || p || !i, onClick: d(c, c - 1), uiSchema: $, registry: h }), (i || a) && P(g, { style: m, disabled: n || p || !a, onClick: d(c, c + 1), uiSchema: $, registry: h }), l && P(b, { style: m, disabled: n || p, onClick: u(c), uiSchema: $, registry: h }), s && P(S, { style: m, disabled: n || p, onClick: f(c), uiSchema: $, registry: h })] }) })] });
}
function N6(e) {
  const { canAdd: t, className: r, disabled: n, idSchema: o, uiSchema: a, items: i, onAddClick: s, readonly: l, registry: c, required: u, schema: f, title: d } = e, p = Qe(a), h = Ye("ArrayFieldDescriptionTemplate", c, p), $ = Ye("ArrayFieldItemTemplate", c, p), b = Ye("ArrayFieldTitleTemplate", c, p), { ButtonTemplates: { AddButton: g } } = c.templates;
  return ue("fieldset", { className: r, id: o.$id, children: [P(b, { idSchema: o, title: p.title || d, required: u, schema: f, uiSchema: a, registry: c }), P(h, { idSchema: o, description: p.description || f.description, schema: f, uiSchema: a, registry: c }), P("div", { className: "row array-item-list", children: i && i.map(({ key: y, ...S }) => P($, { ...S }, y)) }), t && P(g, { className: "array-item-add", onClick: s, disabled: n || l, uiSchema: a, registry: c })] });
}
function F6(e) {
  const { idSchema: t, title: r, schema: n, uiSchema: o, required: a, registry: i } = e, s = Qe(o, i.globalUiOptions), { label: l = !0 } = s;
  if (!r || !l)
    return null;
  const c = Ye("TitleFieldTemplate", i, s);
  return P(c, { id: sf(t), title: r, required: a, schema: n, uiSchema: o, registry: i });
}
function j6(e) {
  const {
    id: t,
    name: r,
    // remove this from ...rest
    value: n,
    readonly: o,
    disabled: a,
    autofocus: i,
    onBlur: s,
    onFocus: l,
    onChange: c,
    onChangeOverride: u,
    options: f,
    schema: d,
    uiSchema: p,
    formContext: h,
    registry: $,
    rawErrors: b,
    type: g,
    hideLabel: y,
    // remove this from ...rest
    hideError: S,
    // remove this from ...rest
    ...m
  } = e;
  if (!t)
    throw console.log("No id for", e), new Error(`no id for props ${JSON.stringify(e)}`);
  const w = {
    ...m,
    ...ib(d, g, f)
  };
  let v;
  w.type === "number" || w.type === "integer" ? v = n || n === 0 ? n : "" : v = n ?? "";
  const E = Pt(({ target: { value: C } }) => c(C === "" ? f.emptyValue : C), [c, f]), I = Pt(({ target: C }) => s(t, C && C.value), [s, t]), R = Pt(({ target: C }) => l(t, C && C.value), [l, t]);
  return ue(Wt, { children: [P("input", { id: t, name: t, className: "form-control", readOnly: o, disabled: a, autoFocus: i, value: v, ...w, list: d.examples ? ji(t) : void 0, onChange: u || E, onBlur: I, onFocus: R, "aria-describedby": Mr(t, !!d.examples) }), Array.isArray(d.examples) && P("datalist", { id: ji(t), children: d.examples.concat(d.default && !d.examples.includes(d.default) ? [d.default] : []).map((C) => P("option", { value: C }, C)) }, `datalist_${t}`)] });
}
function D6({ uiSchema: e }) {
  const { submitText: t, norender: r, props: n = {} } = sb(e);
  return r ? null : P("div", { children: P("button", { type: "submit", ...n, className: `btn btn-info ${n.className || ""}`, children: t }) });
}
function is(e) {
  const { iconType: t = "default", icon: r, className: n, uiSchema: o, registry: a, ...i } = e;
  return P("button", { type: "button", className: `btn btn-${t} ${n}`, ...i, children: P("i", { className: `glyphicon glyphicon-${r}` }) });
}
function L6(e) {
  const { registry: { translateString: t } } = e;
  return P(is, { title: t(ot.CopyButton), className: "array-item-copy", ...e, icon: "copy" });
}
function B6(e) {
  const { registry: { translateString: t } } = e;
  return P(is, { title: t(ot.MoveDownButton), className: "array-item-move-down", ...e, icon: "arrow-down" });
}
function z6(e) {
  const { registry: { translateString: t } } = e;
  return P(is, { title: t(ot.MoveUpButton), className: "array-item-move-up", ...e, icon: "arrow-up" });
}
function U6(e) {
  const { registry: { translateString: t } } = e;
  return P(is, { title: t(ot.RemoveButton), className: "array-item-remove", ...e, iconType: "danger", icon: "remove" });
}
function V6({ className: e, onClick: t, disabled: r, registry: n }) {
  const { translateString: o } = n;
  return P("div", { className: "row", children: P("p", { className: `col-xs-3 col-xs-offset-9 text-right ${e}`, children: P(is, { iconType: "info", icon: "plus", className: "btn-add col-xs-12", title: o(ot.AddButton), onClick: t, disabled: r, registry: n }) }) });
}
function q6() {
  return {
    SubmitButton: D6,
    AddButton: V6,
    CopyButton: L6,
    MoveDownButton: B6,
    MoveUpButton: z6,
    RemoveButton: U6
  };
}
function W6(e) {
  const { id: t, description: r } = e;
  return r ? typeof r == "string" ? P("p", { id: t, className: "field-description", children: r }) : P("div", { id: t, className: "field-description", children: r }) : null;
}
function K6({ errors: e, registry: t }) {
  const { translateString: r } = t;
  return ue("div", { className: "panel panel-danger errors", children: [P("div", { className: "panel-heading", children: P("h3", { className: "panel-title", children: r(ot.ErrorsLabel) }) }), P("ul", { className: "list-group", children: e.map((n, o) => P("li", { className: "list-group-item text-danger", children: n.stack }, o)) })] });
}
const G6 = "*";
function kb(e) {
  const { label: t, required: r, id: n } = e;
  return t ? ue("label", { className: "control-label", htmlFor: n, children: [t, r && P("span", { className: "required", children: G6 })] }) : null;
}
function H6(e) {
  const { id: t, label: r, children: n, errors: o, help: a, description: i, hidden: s, required: l, displayLabel: c, registry: u, uiSchema: f } = e, d = Qe(f), p = Ye("WrapIfAdditionalTemplate", u, d);
  return s ? P("div", { className: "hidden", children: n }) : ue(p, { ...e, children: [c && P(kb, { label: r, required: l, id: t }), c && i ? i : null, n, o, a] });
}
function J6(e) {
  const { errors: t = [], idSchema: r } = e;
  if (t.length === 0)
    return null;
  const n = of(r);
  return P("div", { children: P("ul", { id: n, className: "error-detail bs-callout bs-callout-info", children: t.filter((o) => !!o).map((o, a) => P("li", { className: "text-danger", children: o }, a)) }) });
}
function Y6(e) {
  const { idSchema: t, help: r } = e;
  if (!r)
    return null;
  const n = af(t);
  return typeof r == "string" ? P("p", { id: n, className: "help-block", children: r }) : P("div", { id: n, className: "help-block", children: r });
}
function X6(e) {
  const { description: t, disabled: r, formData: n, idSchema: o, onAddClick: a, properties: i, readonly: s, registry: l, required: c, schema: u, title: f, uiSchema: d } = e, p = Qe(d), h = Ye("TitleFieldTemplate", l, p), $ = Ye("DescriptionFieldTemplate", l, p), { ButtonTemplates: { AddButton: b } } = l.templates;
  return ue("fieldset", { id: o.$id, children: [f && P(h, { id: sf(o), title: f, required: c, schema: u, uiSchema: d, registry: l }), t && P($, { id: Lo(o), description: t, schema: u, uiSchema: d, registry: l }), i.map((g) => g.content), fy(u, d, n) && P(b, { className: "object-property-expand", onClick: a(u), disabled: r || s, uiSchema: d, registry: l })] });
}
const Z6 = "*";
function Q6(e) {
  const { id: t, title: r, required: n } = e;
  return ue("legend", { id: t, children: [r, n && P("span", { className: "required", children: Z6 })] });
}
function e9(e) {
  const { schema: t, idSchema: r, reason: n, registry: o } = e, { translateString: a } = o;
  let i = ot.UnsupportedField;
  const s = [];
  return r && r.$id && (i = ot.UnsupportedFieldWithId, s.push(r.$id)), n && (i = i === ot.UnsupportedField ? ot.UnsupportedFieldWithReason : ot.UnsupportedFieldWithIdAndReason, s.push(n)), ue("div", { className: "unsupported-field", children: [P("p", { children: P(nc, { options: { disableParsingRawHTML: !0 }, children: a(i, s) }) }), t && P("pre", { children: JSON.stringify(t, null, 2) })] });
}
function t9(e) {
  const { id: t, classNames: r, style: n, disabled: o, label: a, onKeyChange: i, onDropPropertyClick: s, readonly: l, required: c, schema: u, children: f, uiSchema: d, registry: p } = e, { templates: h, translateString: $ } = p, { RemoveButton: b } = h.ButtonTemplates, g = $(ot.KeyLabel, [a]);
  return ka in u ? P("div", { className: r, style: n, children: ue("div", { className: "row", children: [P("div", { className: "col-xs-5 form-additional", children: ue("div", { className: "form-group", children: [P(kb, { label: g, required: c, id: `${t}-key` }), P("input", { className: "form-control", type: "text", id: `${t}-key`, onBlur: ({ target: S }) => i(S && S.value), defaultValue: a })] }) }), P("div", { className: "form-additional form-group col-xs-5", children: f }), P("div", { className: "col-xs-2", children: P(b, { className: "array-item-remove btn-block", style: { border: "0" }, disabled: o || l, onClick: s(a), uiSchema: d, registry: p }) })] }) }) : P("div", { className: r, style: n, children: f });
}
function r9() {
  return {
    ArrayFieldDescriptionTemplate: T6,
    ArrayFieldItemTemplate: M6,
    ArrayFieldTemplate: N6,
    ArrayFieldTitleTemplate: F6,
    ButtonTemplates: q6(),
    BaseInputTemplate: j6,
    DescriptionFieldTemplate: W6,
    ErrorListTemplate: K6,
    FieldTemplate: H6,
    FieldErrorTemplate: J6,
    FieldHelpTemplate: Y6,
    ObjectFieldTemplate: X6,
    TitleFieldTemplate: Q6,
    UnsupportedFieldTemplate: e9,
    WrapIfAdditionalTemplate: t9
  };
}
function n9(e) {
  return Object.values(e).every((t) => t !== -1);
}
function o9({ type: e, range: t, value: r, select: n, rootId: o, name: a, disabled: i, readonly: s, autofocus: l, registry: c, onBlur: u, onFocus: f }) {
  const d = o + "_" + e, { SelectWidget: p } = c.widgets;
  return P(p, { schema: { type: "integer" }, id: d, name: a, className: "form-control", options: { enumOptions: tb(t[0], t[1]) }, placeholder: e, value: r, disabled: i, readonly: s, autofocus: l, onChange: (h) => n(e, h), onBlur: u, onFocus: f, registry: c, label: "", "aria-describedby": Mr(o) });
}
function a9({ time: e = !1, disabled: t = !1, readonly: r = !1, autofocus: n = !1, options: o, id: a, name: i, registry: s, onBlur: l, onFocus: c, onChange: u, value: f }) {
  const { translateString: d } = s, [p, h] = Or(f), [$, b] = d$((m, w) => ({ ...m, ...w }), Qc(f, e));
  Ml(() => {
    const m = fm($, e);
    n9($) && m !== f ? u(m) : p !== f && (h(f), b(Qc(f, e)));
  }, [e, f, u, $, p]);
  const g = Pt((m, w) => {
    b({ [m]: w });
  }, []), y = Pt((m) => {
    if (m.preventDefault(), t || r)
      return;
    const w = Qc((/* @__PURE__ */ new Date()).toJSON(), e);
    u(fm(w, e));
  }, [t, r, e]), S = Pt((m) => {
    m.preventDefault(), !(t || r) && u(void 0);
  }, [t, r, u]);
  return ue("ul", { className: "list-inline", children: [kF($, e, o.yearsRange, o.format).map((m, w) => P("li", { className: "list-inline-item", children: P(o9, { rootId: a, name: i, select: g, ...m, disabled: t, readonly: r, registry: s, onBlur: l, onFocus: c, autofocus: n && w === 0 }) }, w)), (o.hideNowButton !== "undefined" ? !o.hideNowButton : !0) && P("li", { className: "list-inline-item", children: P("a", { href: "#", className: "btn btn-info btn-now", onClick: y, children: d(ot.NowLabel) }) }), (o.hideClearButton !== "undefined" ? !o.hideClearButton : !0) && P("li", { className: "list-inline-item", children: P("a", { href: "#", className: "btn btn-warning btn-clear", onClick: S, children: d(ot.ClearLabel) }) })] });
}
function i9({ time: e = !0, ...t }) {
  const { AltDateWidget: r } = t.registry.widgets;
  return P(r, { time: e, ...t });
}
function s9({ schema: e, uiSchema: t, options: r, id: n, value: o, disabled: a, readonly: i, label: s, hideLabel: l, autofocus: c = !1, onBlur: u, onFocus: f, onChange: d, registry: p }) {
  var h;
  const $ = Ye("DescriptionFieldTemplate", p, r), b = wi(e), g = Pt((w) => d(w.target.checked), [d]), y = Pt((w) => u(n, w.target.checked), [u, n]), S = Pt((w) => f(n, w.target.checked), [f, n]), m = (h = r.description) !== null && h !== void 0 ? h : e.description;
  return ue("div", { className: `checkbox ${a || i ? "disabled" : ""}`, children: [!l && !!m && P($, { id: Lo(n), description: m, schema: e, uiSchema: t, registry: p }), ue("label", { children: [P("input", { type: "checkbox", id: n, name: n, checked: typeof o > "u" ? !1 : o, required: b, disabled: a || i, autoFocus: c, onChange: g, onBlur: y, onFocus: S, "aria-describedby": Mr(n) }), Bo(P("span", { children: s }), l)] })] });
}
function l9({ id: e, disabled: t, options: { inline: r = !1, enumOptions: n, enumDisabled: o, emptyValue: a }, value: i, autofocus: s = !1, readonly: l, onChange: c, onBlur: u, onFocus: f }) {
  const d = Array.isArray(i) ? i : [i], p = Pt(({ target: $ }) => u(e, Yt($ && $.value, n, a)), [u, e]), h = Pt(({ target: $ }) => f(e, Yt($ && $.value, n, a)), [f, e]);
  return P("div", { className: "checkboxes", id: e, children: Array.isArray(n) && n.map(($, b) => {
    const g = ec($.value, d), y = Array.isArray(o) && o.indexOf($.value) !== -1, S = t || y || l ? "disabled" : "", m = (v) => {
      v.target.checked ? c(ob(b, d, n)) : c(rb(b, d, n));
    }, w = ue("span", { children: [P("input", { type: "checkbox", id: tc(e, b), name: e, checked: g, value: String(b), disabled: t || y || l, autoFocus: s && b === 0, onChange: m, onBlur: p, onFocus: h, "aria-describedby": Mr(e) }), P("span", { children: $.label })] });
    return r ? P("label", { className: `checkbox-inline ${S}`, children: w }, b) : P("div", { className: `checkbox ${S}`, children: P("label", { children: w }) }, b);
  }) });
}
function c9(e) {
  const { disabled: t, readonly: r, options: n, registry: o } = e, a = Ye("BaseInputTemplate", o, n);
  return P(a, { type: "color", ...e, disabled: t || r });
}
function u9(e) {
  const { onChange: t, options: r, registry: n } = e, o = Ye("BaseInputTemplate", n, r), a = Pt((i) => t(i || void 0), [t]);
  return P(o, { type: "date", ...e, onChange: a });
}
function d9(e) {
  const { onChange: t, value: r, options: n, registry: o } = e, a = Ye("BaseInputTemplate", o, n);
  return P(a, { type: "datetime-local", ...e, value: JF(r), onChange: (i) => t(NF(i)) });
}
function f9(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  return P(n, { type: "email", ...e });
}
function p9(e, t) {
  return e === null ? null : e.replace(";base64", `;name=${encodeURIComponent(t)};base64`);
}
function h9(e) {
  const { name: t, size: r, type: n } = e;
  return new Promise((o, a) => {
    const i = new window.FileReader();
    i.onerror = a, i.onload = (s) => {
      var l;
      typeof ((l = s.target) === null || l === void 0 ? void 0 : l.result) == "string" ? o({
        dataURL: p9(s.target.result, t),
        name: t,
        size: r,
        type: n
      }) : o({
        dataURL: null,
        name: t,
        size: r,
        type: n
      });
    }, i.readAsDataURL(e);
  });
}
function m9(e) {
  return Promise.all(Array.from(e).map(h9));
}
function g9({ fileInfo: e, registry: t }) {
  const { translateString: r } = t, { dataURL: n, type: o, name: a } = e;
  return n ? ["image/jpeg", "image/png"].includes(o) ? P("img", { src: n, style: { maxWidth: "100%" }, className: "file-preview" }) : ue(Wt, { children: [" ", P("a", { download: `preview-${a}`, href: n, className: "file-download", children: r(ot.PreviewLabel) })] }) : null;
}
function y9({ filesInfo: e, registry: t, preview: r, onRemove: n, options: o }) {
  if (e.length === 0)
    return null;
  const { translateString: a } = t, { RemoveButton: i } = Ye("ButtonTemplates", t, o);
  return P("ul", { className: "file-info", children: e.map((s, l) => {
    const { name: c, size: u, type: f } = s, d = () => n(l);
    return ue("li", { children: [P(nc, { children: a(ot.FilesInfo, [c, f, String(u)]) }), r && P(g9, { fileInfo: s, registry: t }), P(i, { onClick: d, registry: t })] }, l);
  }) });
}
function b9(e) {
  return e.reduce((t, r) => {
    if (!r)
      return t;
    try {
      const { blob: n, name: o } = bF(r);
      return [
        ...t,
        {
          dataURL: r,
          name: o,
          size: n.size,
          type: n.type
        }
      ];
    } catch {
      return t;
    }
  }, []);
}
function v9(e) {
  const { disabled: t, readonly: r, required: n, multiple: o, onChange: a, value: i, options: s, registry: l } = e, c = Ye("BaseInputTemplate", l, s), u = Pt((p) => {
    p.target.files && m9(p.target.files).then((h) => {
      const $ = h.map((b) => b.dataURL);
      a(o ? i.concat($) : $[0]);
    });
  }, [o, i, a]), f = f$(() => b9(Array.isArray(i) ? i : [i]), [i]), d = Pt((p) => {
    if (o) {
      const h = i.filter(($, b) => b !== p);
      a(h);
    } else
      a(void 0);
  }, [o, i, a]);
  return ue("div", { children: [P(c, { ...e, disabled: t || r, type: "file", required: i ? !1 : n, onChangeOverride: u, value: "", accept: s.accept ? String(s.accept) : void 0 }), P(y9, { filesInfo: f, onRemove: d, registry: l, preview: s.filePreview, options: s })] });
}
function $9({ id: e, value: t }) {
  return P("input", { type: "hidden", id: e, name: e, value: typeof t > "u" ? "" : t });
}
function S9(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  return P(n, { type: "password", ...e });
}
function w9({ options: e, value: t, required: r, disabled: n, readonly: o, autofocus: a = !1, onBlur: i, onFocus: s, onChange: l, id: c }) {
  const { enumOptions: u, enumDisabled: f, inline: d, emptyValue: p } = e, h = Pt(({ target: b }) => i(c, Yt(b && b.value, u, p)), [i, c]), $ = Pt(({ target: b }) => s(c, Yt(b && b.value, u, p)), [s, c]);
  return P("div", { className: "field-radio-group", id: c, children: Array.isArray(u) && u.map((b, g) => {
    const y = ec(b.value, t), S = Array.isArray(f) && f.indexOf(b.value) !== -1, m = n || S || o ? "disabled" : "", w = () => l(b.value), v = ue("span", { children: [P("input", { type: "radio", id: tc(c, g), checked: y, name: c, required: r, value: String(g), disabled: n || S || o, autoFocus: a && g === 0, onChange: w, onBlur: h, onFocus: $, "aria-describedby": Mr(c) }), P("span", { children: b.label })] });
    return d ? P("label", { className: `radio-inline ${m}`, children: v }, g) : P("div", { className: `radio ${m}`, children: P("label", { children: v }) }, g);
  }) });
}
function C9(e) {
  const { value: t, registry: { templates: { BaseInputTemplate: r } } } = e;
  return ue("div", { className: "field-range-wrapper", children: [P(r, { type: "range", ...e }), P("span", { className: "range-view", children: t })] });
}
function au(e, t) {
  return t ? Array.from(e.target.options).slice().filter((r) => r.selected).map((r) => r.value) : e.target.value;
}
function E9({ schema: e, id: t, options: r, value: n, required: o, disabled: a, readonly: i, multiple: s = !1, autofocus: l = !1, onChange: c, onBlur: u, onFocus: f, placeholder: d }) {
  const { enumOptions: p, enumDisabled: h, emptyValue: $ } = r, b = s ? [] : "", g = Pt((v) => {
    const E = au(v, s);
    return f(t, Yt(E, p, $));
  }, [f, t, e, s, p, $]), y = Pt((v) => {
    const E = au(v, s);
    return u(t, Yt(E, p, $));
  }, [u, t, e, s, p, $]), S = Pt((v) => {
    const E = au(v, s);
    return c(Yt(E, p, $));
  }, [c, e, s, p, $]), m = nf(n, p, s), w = !s && e.default === void 0;
  return ue("select", { id: t, name: t, multiple: s, className: "form-control", value: typeof m > "u" ? b : m, required: o, disabled: a || i, autoFocus: l, onBlur: y, onFocus: g, onChange: S, "aria-describedby": Mr(t), children: [w && P("option", { value: "", children: d }), Array.isArray(p) && p.map(({ value: v, label: E }, I) => {
    const R = h && h.indexOf(v) !== -1;
    return P("option", { value: String(I), disabled: R, children: E }, I);
  })] });
}
function Ob({ id: e, options: t = {}, placeholder: r, value: n, required: o, disabled: a, readonly: i, autofocus: s = !1, onChange: l, onBlur: c, onFocus: u }) {
  const f = Pt(({ target: { value: h } }) => l(h === "" ? t.emptyValue : h), [l, t.emptyValue]), d = Pt(({ target: h }) => c(e, h && h.value), [c, e]), p = Pt(({ target: h }) => u(e, h && h.value), [e, u]);
  return P("textarea", { id: e, name: e, className: "form-control", value: n || "", placeholder: r, required: o, disabled: a, readOnly: i, autoFocus: s, rows: t.rows, onBlur: d, onFocus: p, onChange: f, "aria-describedby": Mr(e) });
}
Ob.defaultProps = {
  autofocus: !1,
  options: {}
};
function _9(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  return P(n, { ...e });
}
function x9(e) {
  const { onChange: t, options: r, registry: n } = e, o = Ye("BaseInputTemplate", n, r), a = Pt((i) => t(i ? `${i}:00` : void 0), [t]);
  return P(o, { type: "time", ...e, onChange: a });
}
function P9(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  return P(n, { type: "url", ...e });
}
function k9(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  return P(n, { type: "number", ...e });
}
function O9() {
  return {
    AltDateWidget: a9,
    AltDateTimeWidget: i9,
    CheckboxWidget: s9,
    CheckboxesWidget: l9,
    ColorWidget: c9,
    DateWidget: u9,
    DateTimeWidget: d9,
    EmailWidget: f9,
    FileWidget: v9,
    HiddenWidget: $9,
    PasswordWidget: S9,
    RadioWidget: w9,
    RangeWidget: C9,
    SelectWidget: E9,
    TextWidget: _9,
    TextareaWidget: Ob,
    TimeWidget: x9,
    UpDownWidget: k9,
    URLWidget: P9
  };
}
function Ab() {
  return {
    fields: R6(),
    templates: r9(),
    widgets: O9(),
    rootSchema: {},
    formContext: {},
    translateString: $F
  };
}
class A9 extends Ji {
  /** Constructs the `Form` from the `props`. Will setup the initial state from the props. It will also call the
   * `onChange` handler if the initially provided `formData` is modified to add missing default values as part of the
   * state construction.
   *
   * @param props - The initial props for the `Form`
   */
  constructor(t) {
    if (super(t), this.getUsedFormData = (r, n) => {
      if (n.length === 0 && typeof r != "object")
        return r;
      const o = pm(r, n);
      return Array.isArray(r) ? Object.keys(o).map((a) => o[a]) : o;
    }, this.getFieldNames = (r, n) => {
      const o = (a, i = [], s = [[]]) => (Object.keys(a).forEach((l) => {
        if (typeof a[l] == "object") {
          const c = s.map((u) => [...u, l]);
          a[l][gd] && a[l][Hs] !== "" ? i.push(a[l][Hs]) : o(a[l], i, c);
        } else l === Hs && a[l] !== "" && s.forEach((c) => {
          const u = xe(n, c);
          (typeof u != "object" || io(u) || Array.isArray(u) && u.every((f) => typeof f != "object")) && i.push(c);
        });
      }), i);
      return o(r);
    }, this.omitExtraData = (r) => {
      const { schema: n, schemaUtils: o } = this.state, a = o.retrieveSchema(n, r), i = o.toPathSchema(a, "", r), s = this.getFieldNames(i, r);
      return this.getUsedFormData(r, s);
    }, this.onChange = (r, n, o) => {
      const { extraErrors: a, omitExtraData: i, liveOmit: s, noValidate: l, liveValidate: c, onChange: u } = this.props, { schemaUtils: f, schema: d, retrievedSchema: p } = this.state;
      (St(r) || Array.isArray(r)) && (r = this.getStateFromProps(this.props, r, p).formData);
      const h = !l && c;
      let $ = { formData: r, schema: d }, b = r;
      if (i === !0 && s === !0 && (b = this.omitExtraData(r), $ = {
        formData: b
      }), h) {
        const g = this.validate(b, d, f, p);
        let y = g.errors, S = g.errorSchema;
        const m = y, w = S;
        if (a) {
          const v = Zs(g, a);
          S = v.errorSchema, y = v.errors;
        }
        if (n) {
          const v = this.filterErrorsBasedOnSchema(n, p, b);
          S = to(S, v, "preventDuplicates");
        }
        $ = {
          formData: b,
          errors: y,
          errorSchema: S,
          schemaValidationErrors: m,
          schemaValidationErrorSchema: w
        };
      } else if (!l && n) {
        const g = a ? to(n, a, "preventDuplicates") : n;
        $ = {
          formData: b,
          errorSchema: g,
          errors: Di(g)
        };
      }
      this.setState($, () => u && u({ ...this.state, ...$ }, o));
    }, this.reset = () => {
      const { onChange: r } = this.props, a = {
        formData: this.getStateFromProps(this.props, void 0).formData,
        errorSchema: {},
        errors: [],
        schemaValidationErrors: [],
        schemaValidationErrorSchema: {}
      };
      this.setState(a, () => r && r({ ...this.state, ...a }));
    }, this.onBlur = (r, n) => {
      const { onBlur: o } = this.props;
      o && o(r, n);
    }, this.onFocus = (r, n) => {
      const { onFocus: o } = this.props;
      o && o(r, n);
    }, this.onSubmit = (r) => {
      if (r.preventDefault(), r.target !== r.currentTarget)
        return;
      r.persist();
      const { omitExtraData: n, extraErrors: o, noValidate: a, onSubmit: i } = this.props;
      let { formData: s } = this.state;
      if (n === !0 && (s = this.omitExtraData(s)), a || this.validateFormWithFormData(s)) {
        const l = o || {}, c = o ? Di(o) : [];
        this.setState({
          formData: s,
          errors: c,
          errorSchema: l,
          schemaValidationErrors: [],
          schemaValidationErrorSchema: {}
        }, () => {
          i && i({ ...this.state, formData: s, status: "submitted" }, r);
        });
      }
    }, this.submit = () => {
      if (this.formElement.current) {
        const r = new CustomEvent("submit", {
          cancelable: !0
        });
        r.preventDefault(), this.formElement.current.dispatchEvent(r), this.formElement.current.requestSubmit();
      }
    }, this.validateFormWithFormData = (r) => {
      const { extraErrors: n, extraErrorsBlockSubmit: o, focusOnFirstError: a, onError: i } = this.props, { errors: s } = this.state, l = this.validate(r);
      let c = l.errors, u = l.errorSchema;
      const f = c, d = u, p = c.length > 0 || n && o;
      if (p) {
        if (n) {
          const h = Zs(l, n);
          u = h.errorSchema, c = h.errors;
        }
        a && (typeof a == "function" ? a(c[0]) : this.focusOnError(c[0])), this.setState({
          errors: c,
          errorSchema: u,
          schemaValidationErrors: f,
          schemaValidationErrorSchema: d
        }, () => {
          i ? i(c) : console.error("Form validation failed", c);
        });
      } else s.length > 0 && this.setState({
        errors: [],
        errorSchema: {},
        schemaValidationErrors: [],
        schemaValidationErrorSchema: {}
      });
      return !p;
    }, !t.validator)
      throw new Error("A validator is required for Form functionality to work");
    this.state = this.getStateFromProps(t, t.formData), this.props.onChange && !pr(this.state.formData, this.props.formData) && this.props.onChange(this.state), this.formElement = p$();
  }
  /**
   * `getSnapshotBeforeUpdate` is a React lifecycle method that is invoked right before the most recently rendered
   * output is committed to the DOM. It enables your component to capture current values (e.g., scroll position) before
   * they are potentially changed.
   *
   * In this case, it checks if the props have changed since the last render. If they have, it computes the next state
   * of the component using `getStateFromProps` method and returns it along with a `shouldUpdate` flag set to `true` IF
   * the `nextState` and `prevState` are different, otherwise `false`. This ensures that we have the most up-to-date
   * state ready to be applied in `componentDidUpdate`.
   *
   * If `formData` hasn't changed, it simply returns an object with `shouldUpdate` set to `false`, indicating that a
   * state update is not necessary.
   *
   * @param prevProps - The previous set of props before the update.
   * @param prevState - The previous state before the update.
   * @returns Either an object containing the next state and a flag indicating that an update should occur, or an object
   *        with a flag indicating that an update is not necessary.
   */
  getSnapshotBeforeUpdate(t, r) {
    if (!pr(this.props, t)) {
      const n = !pr(t.schema, this.props.schema), o = !pr(t.formData, this.props.formData), a = this.getStateFromProps(
        this.props,
        this.props.formData,
        // If the `schema` has changed, we need to update the retrieved schema.
        // Or if the `formData` changes, for example in the case of a schema with dependencies that need to
        //  match one of the subSchemas, the retrieved schema must be updated.
        n || o ? void 0 : this.state.retrievedSchema,
        n
      ), i = !pr(a, r);
      return { nextState: a, shouldUpdate: i };
    }
    return { shouldUpdate: !1 };
  }
  /**
   * `componentDidUpdate` is a React lifecycle method that is invoked immediately after updating occurs. This method is
   * not called for the initial render.
   *
   * Here, it checks if an update is necessary based on the `shouldUpdate` flag received from `getSnapshotBeforeUpdate`.
   * If an update is required, it applies the next state and, if needed, triggers the `onChange` handler to inform about
   * changes.
   *
   * This method effectively replaces the deprecated `UNSAFE_componentWillReceiveProps`, providing a safer alternative
   * to handle prop changes and state updates.
   *
   * @param _ - The previous set of props.
   * @param prevState - The previous state of the component before the update.
   * @param snapshot - The value returned from `getSnapshotBeforeUpdate`.
   */
  componentDidUpdate(t, r, n) {
    if (n.shouldUpdate) {
      const { nextState: o } = n;
      !pr(o.formData, this.props.formData) && !pr(o.formData, r.formData) && this.props.onChange && this.props.onChange(o), this.setState(o);
    }
  }
  /** Extracts the updated state from the given `props` and `inputFormData`. As part of this process, the
   * `inputFormData` is first processed to add any missing required defaults. After that, the data is run through the
   * validation process IF required by the `props`.
   *
   * @param props - The props passed to the `Form`
   * @param inputFormData - The new or current data for the `Form`
   * @param retrievedSchema - An expanded schema, if not provided, it will be retrieved from the `schema` and `formData`.
   * @param isSchemaChanged - A flag indicating whether the schema has changed.
   * @returns - The new state for the `Form`
   */
  getStateFromProps(t, r, n, o = !1) {
    var a;
    const i = this.state || {}, s = "schema" in t ? t.schema : this.props.schema, l = ("uiSchema" in t ? t.uiSchema : this.props.uiSchema) || {}, c = typeof r < "u", u = "liveValidate" in t ? t.liveValidate : this.props.liveValidate, f = c && !t.noValidate && u, d = s, p = "experimental_defaultFormStateBehavior" in t ? t.experimental_defaultFormStateBehavior : this.props.experimental_defaultFormStateBehavior, h = "experimental_customMergeAllOf" in t ? t.experimental_customMergeAllOf : this.props.experimental_customMergeAllOf;
    let $ = i.schemaUtils;
    (!$ || $.doesSchemaUtilsDiffer(t.validator, d, p, h)) && ($ = yF(t.validator, d, p, h));
    const b = $.getDefaultFormState(s, r), g = n ?? $.retrieveSchema(s, b), y = () => t.noValidate || o ? { errors: [], errorSchema: {} } : t.liveValidate ? {
      errors: i.errors || [],
      errorSchema: i.errorSchema || {}
    } : {
      errors: i.schemaValidationErrors || [],
      errorSchema: i.schemaValidationErrorSchema || {}
    };
    let S, m, w = i.schemaValidationErrors, v = i.schemaValidationErrorSchema;
    if (f) {
      const R = this.validate(b, s, $, g);
      S = R.errors, n === void 0 ? m = R.errorSchema : m = to((a = this.state) === null || a === void 0 ? void 0 : a.errorSchema, R.errorSchema, "preventDuplicates"), w = S, v = m;
    } else {
      const R = y();
      S = R.errors, m = R.errorSchema;
    }
    if (t.extraErrors) {
      const R = Zs({ errorSchema: m, errors: S }, t.extraErrors);
      m = R.errorSchema, S = R.errors;
    }
    const E = $.toIdSchema(g, l["ui:rootFieldId"], b, t.idPrefix, t.idSeparator);
    return {
      schemaUtils: $,
      schema: s,
      uiSchema: l,
      idSchema: E,
      formData: b,
      edit: c,
      errors: S,
      errorSchema: m,
      schemaValidationErrors: w,
      schemaValidationErrorSchema: v,
      retrievedSchema: g
    };
  }
  /** React lifecycle method that is used to determine whether component should be updated.
   *
   * @param nextProps - The next version of the props
   * @param nextState - The next version of the state
   * @returns - True if the component should be updated, false otherwise
   */
  shouldComponentUpdate(t, r) {
    return DF(this, t, r);
  }
  /** Validates the `formData` against the `schema` using the `altSchemaUtils` (if provided otherwise it uses the
   * `schemaUtils` in the state), returning the results.
   *
   * @param formData - The new form data to validate
   * @param schema - The schema used to validate against
   * @param altSchemaUtils - The alternate schemaUtils to use for validation
   */
  validate(t, r = this.props.schema, n, o) {
    const a = n || this.state.schemaUtils, { customValidate: i, transformErrors: s, uiSchema: l } = this.props, c = o ?? a.retrieveSchema(r, t);
    return a.getValidator().validateFormData(t, c, i, s, l);
  }
  /** Renders any errors contained in the `state` in using the `ErrorList`, if not disabled by `showErrorList`. */
  renderErrors(t) {
    const { errors: r, errorSchema: n, schema: o, uiSchema: a } = this.state, { formContext: i } = this.props, s = Qe(a), l = Ye("ErrorListTemplate", t, s);
    return r && r.length ? P(l, { errors: r, errorSchema: n || {}, schema: o, uiSchema: a, formContext: i, registry: t }) : null;
  }
  // Filtering errors based on your retrieved schema to only show errors for properties in the selected branch.
  filterErrorsBasedOnSchema(t, r, n) {
    const { retrievedSchema: o, schemaUtils: a } = this.state, i = r ?? o, s = a.toPathSchema(i, "", n), l = this.getFieldNames(s, n), c = pm(t, l);
    (r == null ? void 0 : r.type) !== "object" && (r == null ? void 0 : r.type) !== "array" && (c.__errors = t.__errors);
    const u = (f) => (M4(f, (d, p) => {
      nb(d) ? delete f[p] : typeof d == "object" && !Array.isArray(d.__errors) && u(d);
    }), f);
    return u(c);
  }
  /** Returns the registry for the form */
  getRegistry() {
    var t;
    const { translateString: r, uiSchema: n = {} } = this.props, { schemaUtils: o } = this.state, { fields: a, templates: i, widgets: s, formContext: l, translateString: c } = Ab();
    return {
      fields: { ...a, ...this.props.fields },
      templates: {
        ...i,
        ...this.props.templates,
        ButtonTemplates: {
          ...i.ButtonTemplates,
          ...(t = this.props.templates) === null || t === void 0 ? void 0 : t.ButtonTemplates
        }
      },
      widgets: { ...s, ...this.props.widgets },
      rootSchema: this.props.schema,
      formContext: this.props.formContext || l,
      schemaUtils: o,
      translateString: r || c,
      globalUiOptions: n[E$]
    };
  }
  /** Attempts to focus on the field associated with the `error`. Uses the `property` field to compute path of the error
   * field, then, using the `idPrefix` and `idSeparator` converts that path into an id. Then the input element with that
   * id is attempted to be found using the `formElement` ref. If it is located, then it is focused.
   *
   * @param error - The error on which to focus
   */
  focusOnError(t) {
    const { idPrefix: r = "root", idSeparator: n = "_" } = this.props, { property: o } = t, a = cb(o);
    a[0] === "" ? a[0] = r : a.unshift(r);
    const i = a.join(n);
    let s = this.formElement.current.elements[i];
    s || (s = this.formElement.current.querySelector(`input[id^="${i}"`)), s && s.length && (s = s[0]), s && s.focus();
  }
  /** Programmatically validate the form.  If `omitExtraData` is true, the `formData` will first be filtered to remove
   * any extra data not in a form field. If `onError` is provided, then it will be called with the list of errors the
   * same way as would happen on form submission.
   *
   * @returns - True if the form is valid, false otherwise.
   */
  validateForm() {
    const { omitExtraData: t } = this.props;
    let { formData: r } = this.state;
    return t === !0 && (r = this.omitExtraData(r)), this.validateFormWithFormData(r);
  }
  /** Renders the `Form` fields inside the <form> | `tagName` or `_internalFormWrapper`, rendering any errors if
   * needed along with the submit button or any children of the form.
   */
  render() {
    const { children: t, id: r, idPrefix: n, idSeparator: o, className: a = "", tagName: i, name: s, method: l, target: c, action: u, autoComplete: f, enctype: d, acceptcharset: p, acceptCharset: h, noHtml5Validate: $ = !1, disabled: b, readonly: g, formContext: y, showErrorList: S = "top", _internalFormWrapper: m } = this.props, { schema: w, uiSchema: v, formData: E, errorSchema: I, idSchema: R } = this.state, C = this.getRegistry(), { SchemaField: T } = C.fields, { SubmitButton: F } = C.templates.ButtonTemplates, D = m ? i : void 0, z = m || i || "form";
    let { [cl]: L = {} } = Qe(v);
    b && (L = { ...L, props: { ...L.props, disabled: !0 } });
    const X = { [Si]: { [cl]: L } };
    return ue(z, { className: a || "rjsf", id: r, name: s, method: l, target: c, action: u, autoComplete: f, encType: d, acceptCharset: h || p, noValidate: $, onSubmit: this.onSubmit, as: D, ref: this.formElement, children: [S === "top" && this.renderErrors(C), P(T, { name: "", schema: w, uiSchema: v, errorSchema: I, idSchema: R, idPrefix: n, idSeparator: o, formContext: y, formData: E, onChange: this.onChange, onBlur: this.onBlur, onFocus: this.onFocus, registry: C, disabled: b, readonly: g }), t || P(F, { uiSchema: X, registry: C }), S === "bottom" && this.renderErrors(C)] });
  }
}
function I9(e) {
  return cy(({ fields: t, widgets: r, templates: n, ...o }, a) => {
    var i;
    return t = { ...e == null ? void 0 : e.fields, ...t }, r = { ...e == null ? void 0 : e.widgets, ...r }, n = {
      ...e == null ? void 0 : e.templates,
      ...n,
      ButtonTemplates: {
        ...(i = e == null ? void 0 : e.templates) === null || i === void 0 ? void 0 : i.ButtonTemplates,
        ...n == null ? void 0 : n.ButtonTemplates
      }
    }, P(A9, { ...e, ...o, fields: t, widgets: r, templates: n, ref: a });
  });
}
var Ib = { exports: {} }, gt = {};
/**
 * @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 Cm;
function R9() {
  if (Cm) return gt;
  Cm = 1;
  var e = Symbol.for("react.transitional.element"), t = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), n = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), a = Symbol.for("react.consumer"), i = Symbol.for("react.context"), s = Symbol.for("react.forward_ref"), l = Symbol.for("react.suspense"), c = Symbol.for("react.suspense_list"), u = Symbol.for("react.memo"), f = Symbol.for("react.lazy"), d = Symbol.for("react.offscreen"), p = Symbol.for("react.client.reference");
  function h($) {
    if (typeof $ == "object" && $ !== null) {
      var b = $.$$typeof;
      switch (b) {
        case e:
          switch ($ = $.type, $) {
            case r:
            case o:
            case n:
            case l:
            case c:
              return $;
            default:
              switch ($ = $ && $.$$typeof, $) {
                case i:
                case s:
                case f:
                case u:
                  return $;
                case a:
                  return $;
                default:
                  return b;
              }
          }
        case t:
          return b;
      }
    }
  }
  return gt.ContextConsumer = a, gt.ContextProvider = i, gt.Element = e, gt.ForwardRef = s, gt.Fragment = r, gt.Lazy = f, gt.Memo = u, gt.Portal = t, gt.Profiler = o, gt.StrictMode = n, gt.Suspense = l, gt.SuspenseList = c, gt.isContextConsumer = function($) {
    return h($) === a;
  }, gt.isContextProvider = function($) {
    return h($) === i;
  }, gt.isElement = function($) {
    return typeof $ == "object" && $ !== null && $.$$typeof === e;
  }, gt.isForwardRef = function($) {
    return h($) === s;
  }, gt.isFragment = function($) {
    return h($) === r;
  }, gt.isLazy = function($) {
    return h($) === f;
  }, gt.isMemo = function($) {
    return h($) === u;
  }, gt.isPortal = function($) {
    return h($) === t;
  }, gt.isProfiler = function($) {
    return h($) === o;
  }, gt.isStrictMode = function($) {
    return h($) === n;
  }, gt.isSuspense = function($) {
    return h($) === l;
  }, gt.isSuspenseList = function($) {
    return h($) === c;
  }, gt.isValidElementType = function($) {
    return typeof $ == "string" || typeof $ == "function" || $ === r || $ === o || $ === n || $ === l || $ === c || $ === d || typeof $ == "object" && $ !== null && ($.$$typeof === f || $.$$typeof === u || $.$$typeof === i || $.$$typeof === a || $.$$typeof === s || $.$$typeof === p || $.getModuleId !== void 0);
  }, gt.typeOf = h, gt;
}
Ib.exports = R9();
var Rb = Ib.exports;
function dn(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 Tb(e) {
  if (/* @__PURE__ */ M.isValidElement(e) || Rb.isValidElementType(e) || !dn(e))
    return e;
  const t = {};
  return Object.keys(e).forEach((r) => {
    t[r] = Tb(e[r]);
  }), t;
}
function lr(e, t, r = {
  clone: !0
}) {
  const n = r.clone ? {
    ...e
  } : e;
  return dn(e) && dn(t) && Object.keys(t).forEach((o) => {
    /* @__PURE__ */ M.isValidElement(t[o]) || Rb.isValidElementType(t[o]) ? n[o] = t[o] : dn(t[o]) && // Avoid prototype pollution
    Object.prototype.hasOwnProperty.call(e, o) && dn(e[o]) ? n[o] = lr(e[o], t[o], r) : r.clone ? n[o] = dn(t[o]) ? Tb(t[o]) : t[o] : n[o] = t[o];
  }), n;
}
function Dn(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 $e(e) {
  if (typeof e != "string")
    throw new Error(Dn(7));
  return e.charAt(0).toUpperCase() + e.slice(1);
}
function ju(...e) {
  return e.reduce((t, r) => r == null ? t : function(...o) {
    t.apply(this, o), r.apply(this, o);
  }, () => {
  });
}
function Mb(e, t = 166) {
  let r;
  function n(...o) {
    const a = () => {
      e.apply(this, o);
    };
    clearTimeout(r), r = setTimeout(a, t);
  }
  return n.clear = () => {
    clearTimeout(r);
  }, n;
}
function Ci(e, t) {
  var r, n, o;
  return /* @__PURE__ */ M.isValidElement(e) && t.indexOf(
    // For server components `muiName` is avaialble in element.type._payload.value.muiName
    // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45
    // eslint-disable-next-line no-underscore-dangle
    e.type.muiName ?? ((o = (n = (r = e.type) == null ? void 0 : r._payload) == null ? void 0 : n.value) == null ? void 0 : o.muiName)
  ) !== -1;
}
function mr(e) {
  return e && e.ownerDocument || document;
}
function Ln(e) {
  return mr(e).defaultView || window;
}
function Em(e, t) {
  typeof e == "function" ? e(t) : e && (e.current = t);
}
const Bn = typeof window < "u" ? M.useLayoutEffect : M.useEffect;
let _m = 0;
function T9(e) {
  const [t, r] = M.useState(e), n = e || t;
  return M.useEffect(() => {
    t == null && (_m += 1, r(`mui-${_m}`));
  }, [t]), n;
}
const M9 = {
  ...M
}, xm = M9.useId;
function df(e) {
  if (xm !== void 0) {
    const t = xm();
    return e ?? t;
  }
  return T9(e);
}
function Bi({
  controlled: e,
  default: t,
  name: r,
  state: n = "value"
}) {
  const {
    current: o
  } = M.useRef(e !== void 0), [a, i] = M.useState(t), s = o ? e : a, l = M.useCallback((c) => {
    o || i(c);
  }, []);
  return [s, l];
}
function Rn(e) {
  const t = M.useRef(e);
  return Bn(() => {
    t.current = e;
  }), M.useRef((...r) => (
    // @ts-expect-error hide `this`
    (0, t.current)(...r)
  )).current;
}
function Bt(...e) {
  const t = M.useRef(void 0), r = M.useCallback((n) => {
    const o = e.map((a) => {
      if (a == null)
        return null;
      if (typeof a == "function") {
        const i = a, s = i(n);
        return typeof s == "function" ? s : () => {
          i(null);
        };
      }
      return a.current = n, () => {
        a.current = null;
      };
    });
    return () => {
      o.forEach((a) => a == null ? void 0 : a());
    };
  }, e);
  return M.useMemo(() => e.every((n) => n == null) ? null : (n) => {
    t.current && (t.current(), t.current = void 0), n != null && (t.current = r(n));
  }, e);
}
const Pm = {};
function Nb(e, t) {
  const r = M.useRef(Pm);
  return r.current === Pm && (r.current = e(t)), r;
}
const N9 = [];
function F9(e) {
  M.useEffect(e, N9);
}
class ff {
  constructor() {
    Za(this, "currentId", null);
    Za(this, "clear", () => {
      this.currentId !== null && (clearTimeout(this.currentId), this.currentId = null);
    });
    Za(this, "disposeEffect", () => this.clear);
  }
  static create() {
    return new ff();
  }
  /**
   * Executes `fn` after `delay`, clearing any previously scheduled call.
   */
  start(t, r) {
    this.clear(), this.currentId = setTimeout(() => {
      this.currentId = null, r();
    }, t);
  }
}
function pf() {
  const e = Nb(ff.create).current;
  return F9(e.disposeEffect), e;
}
function vl(e) {
  try {
    return e.matches(":focus-visible");
  } catch {
  }
  return !1;
}
function Fb(e = window) {
  const t = e.document.documentElement.clientWidth;
  return e.innerWidth - t;
}
const j9 = {
  border: 0,
  clip: "rect(0 0 0 0)",
  height: "1px",
  margin: "-1px",
  overflow: "hidden",
  padding: 0,
  position: "absolute",
  whiteSpace: "nowrap",
  width: "1px"
};
function zi(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 a = e[o], i = t[o];
        if (!i)
          r[o] = a || {};
        else if (!a)
          r[o] = i;
        else {
          r[o] = {
            ...i
          };
          for (const s in a)
            if (Object.prototype.hasOwnProperty.call(a, s)) {
              const l = s;
              r[o][l] = zi(a[l], i[l]);
            }
        }
      } else r[o] === void 0 && (r[o] = e[o]);
    }
  return r;
}
function ze(e, t, r = void 0) {
  const n = {};
  for (const o in e) {
    const a = e[o];
    let i = "", s = !0;
    for (let l = 0; l < a.length; l += 1) {
      const c = a[l];
      c && (i += (s === !0 ? "" : " ") + t(c), s = !1, r && r[c] && (i += " " + r[c]));
    }
    n[o] = i;
  }
  return n;
}
const km = (e) => e, D9 = () => {
  let e = km;
  return {
    configure(t) {
      e = t;
    },
    generate(t) {
      return e(t);
    },
    reset() {
      e = km;
    }
  };
}, jb = D9(), L9 = {
  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 Be(e, t, r = "Mui") {
  const n = L9[t];
  return n ? `${r}-${n}` : `${jb.generate(e)}-${t}`;
}
function De(e, t, r = "Mui") {
  const n = {};
  return t.forEach((o) => {
    n[o] = Be(e, o, r);
  }), n;
}
function ta(e, t = Number.MIN_SAFE_INTEGER, r = Number.MAX_SAFE_INTEGER) {
  return Math.max(t, Math.min(e, r));
}
function B9(e) {
  return typeof e == "string";
}
function Db(e, t, r) {
  return e === void 0 || B9(e) ? t : {
    ...t,
    ownerState: {
      ...t.ownerState,
      ...r
    }
  };
}
function Lb(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 = Lb(e[t])) && (n && (n += " "), n += r);
  } else for (r in e) e[r] && (n && (n += " "), n += r);
  return n;
}
function Ee() {
  for (var e, t, r = 0, n = "", o = arguments.length; r < o; r++) (e = arguments[r]) && (t = Lb(e)) && (n && (n += " "), n += t);
  return n;
}
function Ei(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 Om(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 Bb(e) {
  const {
    getSlotProps: t,
    additionalProps: r,
    externalSlotProps: n,
    externalForwardedProps: o,
    className: a
  } = e;
  if (!t) {
    const p = Ee(r == null ? void 0 : r.className, a, 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
    }, $ = {
      ...r,
      ...o,
      ...n
    };
    return p.length > 0 && ($.className = p), Object.keys(h).length > 0 && ($.style = h), {
      props: $,
      internalRef: void 0
    };
  }
  const i = Ei({
    ...o,
    ...n
  }), s = Om(n), l = Om(o), c = t(i), u = Ee(c == null ? void 0 : c.className, r == null ? void 0 : r.className, a, o == null ? void 0 : o.className, n == null ? void 0 : n.className), f = {
    ...c == null ? void 0 : c.style,
    ...r == null ? void 0 : r.style,
    ...o == null ? void 0 : o.style,
    ...n == null ? void 0 : n.style
  }, d = {
    ...c,
    ...r,
    ...l,
    ...s
  };
  return u.length > 0 && (d.className = u), Object.keys(f).length > 0 && (d.style = f), {
    props: d,
    internalRef: c.ref
  };
}
function zb(e, t, r) {
  return typeof e == "function" ? e(t, r) : e;
}
function ln(e) {
  var f;
  const {
    elementType: t,
    externalSlotProps: r,
    ownerState: n,
    skipResolvingSlotProps: o = !1,
    ...a
  } = e, i = o ? {} : zb(r, n), {
    props: s,
    internalRef: l
  } = Bb({
    ...a,
    externalSlotProps: i
  }), c = Bt(l, i == null ? void 0 : i.ref, (f = e.additionalProps) == null ? void 0 : f.ref);
  return Db(t, {
    ...s,
    ref: c
  }, n);
}
function ss(e) {
  var t;
  return parseInt(M.version, 10) >= 19 ? ((t = e == null ? void 0 : e.props) == null ? void 0 : t.ref) || null : (e == null ? void 0 : e.ref) || null;
}
function _i(e, t) {
  return t ? lr(e, t, {
    clone: !1
    // No need to clone deep, it's way faster.
  }) : e;
}
function z9(e, t) {
  if (!e.containerQueries)
    return t;
  const r = Object.keys(t).filter((n) => n.startsWith("@container")).sort((n, o) => {
    var i, s;
    const a = /min-width:\s*([0-9.]+)/;
    return +(((i = n.match(a)) == null ? void 0 : i[1]) || 0) - +(((s = o.match(a)) == null ? void 0 : s[1]) || 0);
  });
  return r.length ? r.reduce((n, o) => {
    const a = t[o];
    return delete n[o], n[o] = a, n;
  }, {
    ...t
  }) : t;
}
function U9(e, t) {
  return t === "@" || t.startsWith("@") && (e.some((r) => t.startsWith(`@${r}`)) || !!t.match(/^@\d/));
}
function V9(e, t) {
  const r = t.match(/^@([^/]+)?\/?(.+)?$/);
  if (!r)
    return null;
  const [, n, o] = r, a = Number.isNaN(+n) ? n || 0 : +n;
  return e.containerQueries(o).up(a);
}
function q9(e) {
  const t = (a, i) => a.replace("@media", i ? `@container ${i}` : "@container");
  function r(a, i) {
    a.up = (...s) => t(e.breakpoints.up(...s), i), a.down = (...s) => t(e.breakpoints.down(...s), i), a.between = (...s) => t(e.breakpoints.between(...s), i), a.only = (...s) => t(e.breakpoints.only(...s), i), a.not = (...s) => {
      const l = t(e.breakpoints.not(...s), i);
      return l.includes("not all and") ? l.replace("not all and ", "").replace("min-width:", "width<").replace("max-width:", "width>").replace("and", "or") : l;
    };
  }
  const n = {}, o = (a) => (r(n, a), n);
  return r(o), {
    ...e,
    containerQueries: o
  };
}
const oc = {
  xs: 0,
  // phone
  sm: 600,
  // tablet
  md: 900,
  // small laptop
  lg: 1200,
  // desktop
  xl: 1536
  // large screen
}, Am = {
  // 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:${oc[e]}px)`
}, W9 = {
  containerQueries: (e) => ({
    up: (t) => {
      let r = typeof t == "number" ? t : oc[t] || t;
      return typeof r == "number" && (r = `${r}px`), e ? `@container ${e} (min-width:${r})` : `@container (min-width:${r})`;
    }
  })
};
function Wr(e, t, r) {
  const n = e.theme || {};
  if (Array.isArray(t)) {
    const a = n.breakpoints || Am;
    return t.reduce((i, s, l) => (i[a.up(a.keys[l])] = r(t[l]), i), {});
  }
  if (typeof t == "object") {
    const a = n.breakpoints || Am;
    return Object.keys(t).reduce((i, s) => {
      if (U9(a.keys, s)) {
        const l = V9(n.containerQueries ? n : W9, s);
        l && (i[l] = r(t[s], s));
      } else if (Object.keys(a.values || oc).includes(s)) {
        const l = a.up(s);
        i[l] = r(t[s], s);
      } else {
        const l = s;
        i[l] = t[l];
      }
      return i;
    }, {});
  }
  return r(t);
}
function K9(e = {}) {
  var r;
  return ((r = e.keys) == null ? void 0 : r.reduce((n, o) => {
    const a = e.up(o);
    return n[a] = {}, n;
  }, {})) || {};
}
function G9(e, t) {
  return e.reduce((r, n) => {
    const o = r[n];
    return (!o || Object.keys(o).length === 0) && delete r[n], r;
  }, t);
}
function H9(e, t) {
  if (typeof e != "object")
    return {};
  const r = {}, n = Object.keys(t);
  return Array.isArray(e) ? n.forEach((o, a) => {
    a < e.length && (r[o] = !0);
  }) : n.forEach((o) => {
    e[o] != null && (r[o] = !0);
  }), r;
}
function ac({
  values: e,
  breakpoints: t,
  base: r
}) {
  const n = r || H9(e, t), o = Object.keys(n);
  if (o.length === 0)
    return e;
  let a;
  return o.reduce((i, s, l) => (Array.isArray(e) ? (i[s] = e[l] != null ? e[l] : e[a], a = l) : typeof e == "object" ? (i[s] = e[s] != null ? e[s] : e[a], a = s) : i[s] = e, i), {});
}
function ic(e, t, r = !0) {
  if (!t || typeof t != "string")
    return null;
  if (e && e.vars && r) {
    const n = `vars.${t}`.split(".").reduce((o, a) => o && o[a] ? o[a] : null, e);
    if (n != null)
      return n;
  }
  return t.split(".").reduce((n, o) => n && n[o] != null ? n[o] : null, e);
}
function $l(e, t, r, n = r) {
  let o;
  return typeof e == "function" ? o = e(r) : Array.isArray(e) ? o = e[r] || n : o = ic(e, r) || n, t && (o = t(o, n, e)), o;
}
function Ut(e) {
  const {
    prop: t,
    cssProperty: r = e.prop,
    themeKey: n,
    transform: o
  } = e, a = (i) => {
    if (i[t] == null)
      return null;
    const s = i[t], l = i.theme, c = ic(l, n) || {};
    return Wr(i, s, (f) => {
      let d = $l(c, o, f);
      return f === d && typeof f == "string" && (d = $l(c, o, `${t}${f === "default" ? "" : $e(f)}`, f)), r === !1 ? d : {
        [r]: d
      };
    });
  };
  return a.propTypes = {}, a.filterProps = [t], a;
}
function J9(e) {
  const t = {};
  return (r) => (t[r] === void 0 && (t[r] = e(r)), t[r]);
}
const Y9 = {
  m: "margin",
  p: "padding"
}, X9 = {
  t: "Top",
  r: "Right",
  b: "Bottom",
  l: "Left",
  x: ["Left", "Right"],
  y: ["Top", "Bottom"]
}, Im = {
  marginX: "mx",
  marginY: "my",
  paddingX: "px",
  paddingY: "py"
}, Z9 = J9((e) => {
  if (e.length > 2)
    if (Im[e])
      e = Im[e];
    else
      return [e];
  const [t, r] = e.split(""), n = Y9[t], o = X9[r] || "";
  return Array.isArray(o) ? o.map((a) => n + a) : [n + o];
}), hf = ["m", "mt", "mr", "mb", "ml", "mx", "my", "margin", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "marginInline", "marginInlineStart", "marginInlineEnd", "marginBlock", "marginBlockStart", "marginBlockEnd"], mf = ["p", "pt", "pr", "pb", "pl", "px", "py", "padding", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "paddingInline", "paddingInlineStart", "paddingInlineEnd", "paddingBlock", "paddingBlockStart", "paddingBlockEnd"];
[...hf, ...mf];
function ls(e, t, r, n) {
  const o = ic(e, t, !0) ?? r;
  return typeof o == "number" || typeof o == "string" ? (a) => typeof a == "string" ? a : typeof o == "string" ? `calc(${a} * ${o})` : o * a : Array.isArray(o) ? (a) => {
    if (typeof a == "string")
      return a;
    const i = Math.abs(a), s = o[i];
    return a >= 0 ? s : typeof s == "number" ? -s : `-${s}`;
  } : typeof o == "function" ? o : () => {
  };
}
function gf(e) {
  return ls(e, "spacing", 8);
}
function cs(e, t) {
  return typeof t == "string" || t == null ? t : e(t);
}
function Q9(e, t) {
  return (r) => e.reduce((n, o) => (n[o] = cs(t, r), n), {});
}
function eD(e, t, r, n) {
  if (!t.includes(r))
    return null;
  const o = Z9(r), a = Q9(o, n), i = e[r];
  return Wr(e, i, a);
}
function Ub(e, t) {
  const r = gf(e.theme);
  return Object.keys(e).map((n) => eD(e, t, n, r)).reduce(_i, {});
}
function Rt(e) {
  return Ub(e, hf);
}
Rt.propTypes = {};
Rt.filterProps = hf;
function Tt(e) {
  return Ub(e, mf);
}
Tt.propTypes = {};
Tt.filterProps = mf;
function sc(...e) {
  const t = e.reduce((n, o) => (o.filterProps.forEach((a) => {
    n[a] = o;
  }), n), {}), r = (n) => Object.keys(n).reduce((o, a) => t[a] ? _i(o, t[a](n)) : o, {});
  return r.propTypes = {}, r.filterProps = e.reduce((n, o) => n.concat(o.filterProps), []), r;
}
function Br(e) {
  return typeof e != "number" ? e : `${e}px solid`;
}
function Gr(e, t) {
  return Ut({
    prop: e,
    themeKey: "borders",
    transform: t
  });
}
const tD = Gr("border", Br), rD = Gr("borderTop", Br), nD = Gr("borderRight", Br), oD = Gr("borderBottom", Br), aD = Gr("borderLeft", Br), iD = Gr("borderColor"), sD = Gr("borderTopColor"), lD = Gr("borderRightColor"), cD = Gr("borderBottomColor"), uD = Gr("borderLeftColor"), dD = Gr("outline", Br), fD = Gr("outlineColor"), lc = (e) => {
  if (e.borderRadius !== void 0 && e.borderRadius !== null) {
    const t = ls(e.theme, "shape.borderRadius", 4), r = (n) => ({
      borderRadius: cs(t, n)
    });
    return Wr(e, e.borderRadius, r);
  }
  return null;
};
lc.propTypes = {};
lc.filterProps = ["borderRadius"];
sc(tD, rD, nD, oD, aD, iD, sD, lD, cD, uD, lc, dD, fD);
const cc = (e) => {
  if (e.gap !== void 0 && e.gap !== null) {
    const t = ls(e.theme, "spacing", 8), r = (n) => ({
      gap: cs(t, n)
    });
    return Wr(e, e.gap, r);
  }
  return null;
};
cc.propTypes = {};
cc.filterProps = ["gap"];
const uc = (e) => {
  if (e.columnGap !== void 0 && e.columnGap !== null) {
    const t = ls(e.theme, "spacing", 8), r = (n) => ({
      columnGap: cs(t, n)
    });
    return Wr(e, e.columnGap, r);
  }
  return null;
};
uc.propTypes = {};
uc.filterProps = ["columnGap"];
const dc = (e) => {
  if (e.rowGap !== void 0 && e.rowGap !== null) {
    const t = ls(e.theme, "spacing", 8), r = (n) => ({
      rowGap: cs(t, n)
    });
    return Wr(e, e.rowGap, r);
  }
  return null;
};
dc.propTypes = {};
dc.filterProps = ["rowGap"];
const pD = Ut({
  prop: "gridColumn"
}), hD = Ut({
  prop: "gridRow"
}), mD = Ut({
  prop: "gridAutoFlow"
}), gD = Ut({
  prop: "gridAutoColumns"
}), yD = Ut({
  prop: "gridAutoRows"
}), bD = Ut({
  prop: "gridTemplateColumns"
}), vD = Ut({
  prop: "gridTemplateRows"
}), $D = Ut({
  prop: "gridTemplateAreas"
}), SD = Ut({
  prop: "gridArea"
});
sc(cc, uc, dc, pD, hD, mD, gD, yD, bD, vD, $D, SD);
function la(e, t) {
  return t === "grey" ? t : e;
}
const wD = Ut({
  prop: "color",
  themeKey: "palette",
  transform: la
}), CD = Ut({
  prop: "bgcolor",
  cssProperty: "backgroundColor",
  themeKey: "palette",
  transform: la
}), ED = Ut({
  prop: "backgroundColor",
  themeKey: "palette",
  transform: la
});
sc(wD, CD, ED);
function Ar(e) {
  return e <= 1 && e !== 0 ? `${e * 100}%` : e;
}
const _D = Ut({
  prop: "width",
  transform: Ar
}), yf = (e) => {
  if (e.maxWidth !== void 0 && e.maxWidth !== null) {
    const t = (r) => {
      var o, a, i, s, l;
      const n = ((i = (a = (o = e.theme) == null ? void 0 : o.breakpoints) == null ? void 0 : a.values) == null ? void 0 : i[r]) || oc[r];
      return n ? ((l = (s = e.theme) == null ? void 0 : s.breakpoints) == null ? void 0 : l.unit) !== "px" ? {
        maxWidth: `${n}${e.theme.breakpoints.unit}`
      } : {
        maxWidth: n
      } : {
        maxWidth: Ar(r)
      };
    };
    return Wr(e, e.maxWidth, t);
  }
  return null;
};
yf.filterProps = ["maxWidth"];
const xD = Ut({
  prop: "minWidth",
  transform: Ar
}), PD = Ut({
  prop: "height",
  transform: Ar
}), kD = Ut({
  prop: "maxHeight",
  transform: Ar
}), OD = Ut({
  prop: "minHeight",
  transform: Ar
});
Ut({
  prop: "size",
  cssProperty: "width",
  transform: Ar
});
Ut({
  prop: "size",
  cssProperty: "height",
  transform: Ar
});
const AD = Ut({
  prop: "boxSizing"
});
sc(_D, yf, xD, PD, kD, OD, AD);
const us = {
  // borders
  border: {
    themeKey: "borders",
    transform: Br
  },
  borderTop: {
    themeKey: "borders",
    transform: Br
  },
  borderRight: {
    themeKey: "borders",
    transform: Br
  },
  borderBottom: {
    themeKey: "borders",
    transform: Br
  },
  borderLeft: {
    themeKey: "borders",
    transform: Br
  },
  borderColor: {
    themeKey: "palette"
  },
  borderTopColor: {
    themeKey: "palette"
  },
  borderRightColor: {
    themeKey: "palette"
  },
  borderBottomColor: {
    themeKey: "palette"
  },
  borderLeftColor: {
    themeKey: "palette"
  },
  outline: {
    themeKey: "borders",
    transform: Br
  },
  outlineColor: {
    themeKey: "palette"
  },
  borderRadius: {
    themeKey: "shape.borderRadius",
    style: lc
  },
  // palette
  color: {
    themeKey: "palette",
    transform: la
  },
  bgcolor: {
    themeKey: "palette",
    cssProperty: "backgroundColor",
    transform: la
  },
  backgroundColor: {
    themeKey: "palette",
    transform: la
  },
  // spacing
  p: {
    style: Tt
  },
  pt: {
    style: Tt
  },
  pr: {
    style: Tt
  },
  pb: {
    style: Tt
  },
  pl: {
    style: Tt
  },
  px: {
    style: Tt
  },
  py: {
    style: Tt
  },
  padding: {
    style: Tt
  },
  paddingTop: {
    style: Tt
  },
  paddingRight: {
    style: Tt
  },
  paddingBottom: {
    style: Tt
  },
  paddingLeft: {
    style: Tt
  },
  paddingX: {
    style: Tt
  },
  paddingY: {
    style: Tt
  },
  paddingInline: {
    style: Tt
  },
  paddingInlineStart: {
    style: Tt
  },
  paddingInlineEnd: {
    style: Tt
  },
  paddingBlock: {
    style: Tt
  },
  paddingBlockStart: {
    style: Tt
  },
  paddingBlockEnd: {
    style: Tt
  },
  m: {
    style: Rt
  },
  mt: {
    style: Rt
  },
  mr: {
    style: Rt
  },
  mb: {
    style: Rt
  },
  ml: {
    style: Rt
  },
  mx: {
    style: Rt
  },
  my: {
    style: Rt
  },
  margin: {
    style: Rt
  },
  marginTop: {
    style: Rt
  },
  marginRight: {
    style: Rt
  },
  marginBottom: {
    style: Rt
  },
  marginLeft: {
    style: Rt
  },
  marginX: {
    style: Rt
  },
  marginY: {
    style: Rt
  },
  marginInline: {
    style: Rt
  },
  marginInlineStart: {
    style: Rt
  },
  marginInlineEnd: {
    style: Rt
  },
  marginBlock: {
    style: Rt
  },
  marginBlockStart: {
    style: Rt
  },
  marginBlockEnd: {
    style: Rt
  },
  // 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: cc
  },
  rowGap: {
    style: dc
  },
  columnGap: {
    style: uc
  },
  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: Ar
  },
  maxWidth: {
    style: yf
  },
  minWidth: {
    transform: Ar
  },
  height: {
    transform: Ar
  },
  maxHeight: {
    transform: Ar
  },
  minHeight: {
    transform: Ar
  },
  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 ID(...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 RD(e, t) {
  return typeof e == "function" ? e(t) : e;
}
function TD() {
  function e(r, n, o, a) {
    const i = {
      [r]: n,
      theme: o
    }, s = a[r];
    if (!s)
      return {
        [r]: n
      };
    const {
      cssProperty: l = r,
      themeKey: c,
      transform: u,
      style: f
    } = s;
    if (n == null)
      return null;
    if (c === "typography" && n === "inherit")
      return {
        [r]: n
      };
    const d = ic(o, c) || {};
    return f ? f(i) : Wr(i, n, (h) => {
      let $ = $l(d, u, h);
      return h === $ && typeof h == "string" && ($ = $l(d, u, `${r}${h === "default" ? "" : $e(h)}`, h)), l === !1 ? $ : {
        [l]: $
      };
    });
  }
  function t(r) {
    const {
      sx: n,
      theme: o = {}
    } = r || {};
    if (!n)
      return null;
    const a = o.unstable_sxConfig ?? us;
    function i(s) {
      let l = s;
      if (typeof s == "function")
        l = s(o);
      else if (typeof s != "object")
        return s;
      if (!l)
        return null;
      const c = K9(o.breakpoints), u = Object.keys(c);
      let f = c;
      return Object.keys(l).forEach((d) => {
        const p = RD(l[d], o);
        if (p != null)
          if (typeof p == "object")
            if (a[d])
              f = _i(f, e(d, p, o, a));
            else {
              const h = Wr({
                theme: o
              }, p, ($) => ({
                [d]: $
              }));
              ID(h, p) ? f[d] = t({
                sx: p,
                theme: o
              }) : f = _i(f, h);
            }
          else
            f = _i(f, e(d, p, o, a));
      }), z9(o, G9(u, f));
    }
    return Array.isArray(n) ? n.map(i) : i(n);
  }
  return t;
}
const ko = TD();
ko.filterProps = ["sx"];
const MD = (e) => {
  var n;
  const t = {
    systemProps: {},
    otherProps: {}
  }, r = ((n = e == null ? void 0 : e.theme) == null ? void 0 : n.unstable_sxConfig) ?? us;
  return Object.keys(e).forEach((o) => {
    r[o] ? t.systemProps[o] = e[o] : t.otherProps[o] = e[o];
  }), t;
};
function fc(e) {
  const {
    sx: t,
    ...r
  } = e, {
    systemProps: n,
    otherProps: o
  } = MD(r);
  let a;
  return Array.isArray(t) ? a = [n, ...t] : typeof t == "function" ? a = (...i) => {
    const s = t(...i);
    return dn(s) ? {
      ...n,
      ...s
    } : n;
  } : a = {
    ...n,
    ...t
  }, {
    ...o,
    sx: a
  };
}
function Sl() {
  return Sl = Object.assign ? Object.assign.bind() : function(e) {
    for (var t = 1; t < arguments.length; t++) {
      var r = arguments[t];
      for (var n in r) ({}).hasOwnProperty.call(r, n) && (e[n] = r[n]);
    }
    return e;
  }, Sl.apply(null, arguments);
}
function ND(e) {
  if (e.sheet)
    return e.sheet;
  for (var t = 0; t < document.styleSheets.length; t++)
    if (document.styleSheets[t].ownerNode === e)
      return document.styleSheets[t];
}
function FD(e) {
  var t = document.createElement("style");
  return t.setAttribute("data-emotion", e.key), e.nonce !== void 0 && t.setAttribute("nonce", e.nonce), t.appendChild(document.createTextNode("")), t.setAttribute("data-s", ""), t;
}
var jD = /* @__PURE__ */ function() {
  function e(r) {
    var n = this;
    this._insertTag = function(o) {
      var a;
      n.tags.length === 0 ? n.insertionPoint ? a = n.insertionPoint.nextSibling : n.prepend ? a = n.container.firstChild : a = n.before : a = n.tags[n.tags.length - 1].nextSibling, n.container.insertBefore(o, a), n.tags.push(o);
    }, this.isSpeedy = r.speedy === void 0 ? !0 : r.speedy, this.tags = [], this.ctr = 0, this.nonce = r.nonce, this.key = r.key, this.container = r.container, this.prepend = r.prepend, this.insertionPoint = r.insertionPoint, this.before = null;
  }
  var t = e.prototype;
  return t.hydrate = function(n) {
    n.forEach(this._insertTag);
  }, t.insert = function(n) {
    this.ctr % (this.isSpeedy ? 65e3 : 1) === 0 && this._insertTag(FD(this));
    var o = this.tags[this.tags.length - 1];
    if (this.isSpeedy) {
      var a = ND(o);
      try {
        a.insertRule(n, a.cssRules.length);
      } catch {
      }
    } else
      o.appendChild(document.createTextNode(n));
    this.ctr++;
  }, t.flush = function() {
    this.tags.forEach(function(n) {
      var o;
      return (o = n.parentNode) == null ? void 0 : o.removeChild(n);
    }), this.tags = [], this.ctr = 0;
  }, e;
}(), ir = "-ms-", wl = "-moz-", st = "-webkit-", Vb = "comm", bf = "rule", vf = "decl", DD = "@import", qb = "@keyframes", LD = "@layer", BD = Math.abs, pc = String.fromCharCode, zD = Object.assign;
function UD(e, t) {
  return tr(e, 0) ^ 45 ? (((t << 2 ^ tr(e, 0)) << 2 ^ tr(e, 1)) << 2 ^ tr(e, 2)) << 2 ^ tr(e, 3) : 0;
}
function Wb(e) {
  return e.trim();
}
function VD(e, t) {
  return (e = t.exec(e)) ? e[0] : e;
}
function lt(e, t, r) {
  return e.replace(t, r);
}
function Du(e, t) {
  return e.indexOf(t);
}
function tr(e, t) {
  return e.charCodeAt(t) | 0;
}
function Ui(e, t, r) {
  return e.slice(t, r);
}
function cn(e) {
  return e.length;
}
function $f(e) {
  return e.length;
}
function Os(e, t) {
  return t.push(e), e;
}
function qD(e, t) {
  return e.map(t).join("");
}
var hc = 1, $a = 1, Kb = 0, Cr = 0, qt = 0, Va = "";
function mc(e, t, r, n, o, a, i) {
  return { value: e, root: t, parent: r, type: n, props: o, children: a, line: hc, column: $a, length: i, return: "" };
}
function oi(e, t) {
  return zD(mc("", null, null, "", null, null, 0), e, { length: -e.length }, t);
}
function WD() {
  return qt;
}
function KD() {
  return qt = Cr > 0 ? tr(Va, --Cr) : 0, $a--, qt === 10 && ($a = 1, hc--), qt;
}
function Tr() {
  return qt = Cr < Kb ? tr(Va, Cr++) : 0, $a++, qt === 10 && ($a = 1, hc++), qt;
}
function bn() {
  return tr(Va, Cr);
}
function el() {
  return Cr;
}
function ds(e, t) {
  return Ui(Va, e, t);
}
function Vi(e) {
  switch (e) {
    case 0:
    case 9:
    case 10:
    case 13:
    case 32:
      return 5;
    case 33:
    case 43:
    case 44:
    case 47:
    case 62:
    case 64:
    case 126:
    case 59:
    case 123:
    case 125:
      return 4;
    case 58:
      return 3;
    case 34:
    case 39:
    case 40:
    case 91:
      return 2;
    case 41:
    case 93:
      return 1;
  }
  return 0;
}
function Gb(e) {
  return hc = $a = 1, Kb = cn(Va = e), Cr = 0, [];
}
function Hb(e) {
  return Va = "", e;
}
function tl(e) {
  return Wb(ds(Cr - 1, Lu(e === 91 ? e + 2 : e === 40 ? e + 1 : e)));
}
function GD(e) {
  for (; (qt = bn()) && qt < 33; )
    Tr();
  return Vi(e) > 2 || Vi(qt) > 3 ? "" : " ";
}
function HD(e, t) {
  for (; --t && Tr() && !(qt < 48 || qt > 102 || qt > 57 && qt < 65 || qt > 70 && qt < 97); )
    ;
  return ds(e, el() + (t < 6 && bn() == 32 && Tr() == 32));
}
function Lu(e) {
  for (; Tr(); )
    switch (qt) {
      case e:
        return Cr;
      case 34:
      case 39:
        e !== 34 && e !== 39 && Lu(qt);
        break;
      case 40:
        e === 41 && Lu(e);
        break;
      case 92:
        Tr();
        break;
    }
  return Cr;
}
function JD(e, t) {
  for (; Tr() && e + qt !== 57; )
    if (e + qt === 84 && bn() === 47)
      break;
  return "/*" + ds(t, Cr - 1) + "*" + pc(e === 47 ? e : Tr());
}
function YD(e) {
  for (; !Vi(bn()); )
    Tr();
  return ds(e, Cr);
}
function XD(e) {
  return Hb(rl("", null, null, null, [""], e = Gb(e), 0, [0], e));
}
function rl(e, t, r, n, o, a, i, s, l) {
  for (var c = 0, u = 0, f = i, d = 0, p = 0, h = 0, $ = 1, b = 1, g = 1, y = 0, S = "", m = o, w = a, v = n, E = S; b; )
    switch (h = y, y = Tr()) {
      case 40:
        if (h != 108 && tr(E, f - 1) == 58) {
          Du(E += lt(tl(y), "&", "&\f"), "&\f") != -1 && (g = -1);
          break;
        }
      case 34:
      case 39:
      case 91:
        E += tl(y);
        break;
      case 9:
      case 10:
      case 13:
      case 32:
        E += GD(h);
        break;
      case 92:
        E += HD(el() - 1, 7);
        continue;
      case 47:
        switch (bn()) {
          case 42:
          case 47:
            Os(ZD(JD(Tr(), el()), t, r), l);
            break;
          default:
            E += "/";
        }
        break;
      case 123 * $:
        s[c++] = cn(E) * g;
      case 125 * $:
      case 59:
      case 0:
        switch (y) {
          case 0:
          case 125:
            b = 0;
          case 59 + u:
            g == -1 && (E = lt(E, /\f/g, "")), p > 0 && cn(E) - f && Os(p > 32 ? Tm(E + ";", n, r, f - 1) : Tm(lt(E, " ", "") + ";", n, r, f - 2), l);
            break;
          case 59:
            E += ";";
          default:
            if (Os(v = Rm(E, t, r, c, u, o, s, S, m = [], w = [], f), a), y === 123)
              if (u === 0)
                rl(E, t, v, v, m, a, f, s, w);
              else
                switch (d === 99 && tr(E, 3) === 110 ? 100 : d) {
                  case 100:
                  case 108:
                  case 109:
                  case 115:
                    rl(e, v, v, n && Os(Rm(e, v, v, 0, 0, o, s, S, o, m = [], f), w), o, w, f, s, n ? m : w);
                    break;
                  default:
                    rl(E, v, v, v, [""], w, 0, s, w);
                }
        }
        c = u = p = 0, $ = g = 1, S = E = "", f = i;
        break;
      case 58:
        f = 1 + cn(E), p = h;
      default:
        if ($ < 1) {
          if (y == 123)
            --$;
          else if (y == 125 && $++ == 0 && KD() == 125)
            continue;
        }
        switch (E += pc(y), y * $) {
          case 38:
            g = u > 0 ? 1 : (E += "\f", -1);
            break;
          case 44:
            s[c++] = (cn(E) - 1) * g, g = 1;
            break;
          case 64:
            bn() === 45 && (E += tl(Tr())), d = bn(), u = f = cn(S = E += YD(el())), y++;
            break;
          case 45:
            h === 45 && cn(E) == 2 && ($ = 0);
        }
    }
  return a;
}
function Rm(e, t, r, n, o, a, i, s, l, c, u) {
  for (var f = o - 1, d = o === 0 ? a : [""], p = $f(d), h = 0, $ = 0, b = 0; h < n; ++h)
    for (var g = 0, y = Ui(e, f + 1, f = BD($ = i[h])), S = e; g < p; ++g)
      (S = Wb($ > 0 ? d[g] + " " + y : lt(y, /&\f/g, d[g]))) && (l[b++] = S);
  return mc(e, t, r, o === 0 ? bf : s, l, c, u);
}
function ZD(e, t, r) {
  return mc(e, t, r, Vb, pc(WD()), Ui(e, 2, -2), 0);
}
function Tm(e, t, r, n) {
  return mc(e, t, r, vf, Ui(e, 0, n), Ui(e, n + 1, -1), n);
}
function ca(e, t) {
  for (var r = "", n = $f(e), o = 0; o < n; o++)
    r += t(e[o], o, e, t) || "";
  return r;
}
function QD(e, t, r, n) {
  switch (e.type) {
    case LD:
      if (e.children.length) break;
    case DD:
    case vf:
      return e.return = e.return || e.value;
    case Vb:
      return "";
    case qb:
      return e.return = e.value + "{" + ca(e.children, n) + "}";
    case bf:
      e.value = e.props.join(",");
  }
  return cn(r = ca(e.children, n)) ? e.return = e.value + "{" + r + "}" : "";
}
function eL(e) {
  var t = $f(e);
  return function(r, n, o, a) {
    for (var i = "", s = 0; s < t; s++)
      i += e[s](r, n, o, a) || "";
    return i;
  };
}
function tL(e) {
  return function(t) {
    t.root || (t = t.return) && e(t);
  };
}
function Jb(e) {
  var t = /* @__PURE__ */ Object.create(null);
  return function(r) {
    return t[r] === void 0 && (t[r] = e(r)), t[r];
  };
}
var rL = function(t, r, n) {
  for (var o = 0, a = 0; o = a, a = bn(), o === 38 && a === 12 && (r[n] = 1), !Vi(a); )
    Tr();
  return ds(t, Cr);
}, nL = function(t, r) {
  var n = -1, o = 44;
  do
    switch (Vi(o)) {
      case 0:
        o === 38 && bn() === 12 && (r[n] = 1), t[n] += rL(Cr - 1, r, n);
        break;
      case 2:
        t[n] += tl(o);
        break;
      case 4:
        if (o === 44) {
          t[++n] = bn() === 58 ? "&\f" : "", r[n] = t[n].length;
          break;
        }
      default:
        t[n] += pc(o);
    }
  while (o = Tr());
  return t;
}, oL = function(t, r) {
  return Hb(nL(Gb(t), r));
}, Mm = /* @__PURE__ */ new WeakMap(), aL = function(t) {
  if (!(t.type !== "rule" || !t.parent || // positive .length indicates that this rule contains pseudo
  // negative .length indicates that this rule has been already prefixed
  t.length < 1)) {
    for (var r = t.value, n = t.parent, o = t.column === n.column && t.line === n.line; n.type !== "rule"; )
      if (n = n.parent, !n) return;
    if (!(t.props.length === 1 && r.charCodeAt(0) !== 58 && !Mm.get(n)) && !o) {
      Mm.set(t, !0);
      for (var a = [], i = oL(r, a), s = n.props, l = 0, c = 0; l < i.length; l++)
        for (var u = 0; u < s.length; u++, c++)
          t.props[c] = a[l] ? i[l].replace(/&\f/g, s[u]) : s[u] + " " + i[l];
    }
  }
}, iL = function(t) {
  if (t.type === "decl") {
    var r = t.value;
    // charcode for l
    r.charCodeAt(0) === 108 && // charcode for b
    r.charCodeAt(2) === 98 && (t.return = "", t.value = "");
  }
};
function Yb(e, t) {
  switch (UD(e, t)) {
    case 5103:
      return st + "print-" + e + e;
    case 5737:
    case 4201:
    case 3177:
    case 3433:
    case 1641:
    case 4457:
    case 2921:
    case 5572:
    case 6356:
    case 5844:
    case 3191:
    case 6645:
    case 3005:
    case 6391:
    case 5879:
    case 5623:
    case 6135:
    case 4599:
    case 4855:
    case 4215:
    case 6389:
    case 5109:
    case 5365:
    case 5621:
    case 3829:
      return st + e + e;
    case 5349:
    case 4246:
    case 4810:
    case 6968:
    case 2756:
      return st + e + wl + e + ir + e + e;
    case 6828:
    case 4268:
      return st + e + ir + e + e;
    case 6165:
      return st + e + ir + "flex-" + e + e;
    case 5187:
      return st + e + lt(e, /(\w+).+(:[^]+)/, st + "box-$1$2" + ir + "flex-$1$2") + e;
    case 5443:
      return st + e + ir + "flex-item-" + lt(e, /flex-|-self/, "") + e;
    case 4675:
      return st + e + ir + "flex-line-pack" + lt(e, /align-content|flex-|-self/, "") + e;
    case 5548:
      return st + e + ir + lt(e, "shrink", "negative") + e;
    case 5292:
      return st + e + ir + lt(e, "basis", "preferred-size") + e;
    case 6060:
      return st + "box-" + lt(e, "-grow", "") + st + e + ir + lt(e, "grow", "positive") + e;
    case 4554:
      return st + lt(e, /([^-])(transform)/g, "$1" + st + "$2") + e;
    case 6187:
      return lt(lt(lt(e, /(zoom-|grab)/, st + "$1"), /(image-set)/, st + "$1"), e, "") + e;
    case 5495:
    case 3959:
      return lt(e, /(image-set\([^]*)/, st + "$1$`$1");
    case 4968:
      return lt(lt(e, /(.+:)(flex-)?(.*)/, st + "box-pack:$3" + ir + "flex-pack:$3"), /s.+-b[^;]+/, "justify") + st + e + e;
    case 4095:
    case 3583:
    case 4068:
    case 2532:
      return lt(e, /(.+)-inline(.+)/, st + "$1$2") + e;
    case 8116:
    case 7059:
    case 5753:
    case 5535:
    case 5445:
    case 5701:
    case 4933:
    case 4677:
    case 5533:
    case 5789:
    case 5021:
    case 4765:
      if (cn(e) - 1 - t > 6) switch (tr(e, t + 1)) {
        case 109:
          if (tr(e, t + 4) !== 45) break;
        case 102:
          return lt(e, /(.+:)(.+)-([^]+)/, "$1" + st + "$2-$3$1" + wl + (tr(e, t + 3) == 108 ? "$3" : "$2-$3")) + e;
        case 115:
          return ~Du(e, "stretch") ? Yb(lt(e, "stretch", "fill-available"), t) + e : e;
      }
      break;
    case 4949:
      if (tr(e, t + 1) !== 115) break;
    case 6444:
      switch (tr(e, cn(e) - 3 - (~Du(e, "!important") && 10))) {
        case 107:
          return lt(e, ":", ":" + st) + e;
        case 101:
          return lt(e, /(.+:)([^;!]+)(;|!.+)?/, "$1" + st + (tr(e, 14) === 45 ? "inline-" : "") + "box$3$1" + st + "$2$3$1" + ir + "$2box$3") + e;
      }
      break;
    case 5936:
      switch (tr(e, t + 11)) {
        case 114:
          return st + e + ir + lt(e, /[svh]\w+-[tblr]{2}/, "tb") + e;
        case 108:
          return st + e + ir + lt(e, /[svh]\w+-[tblr]{2}/, "tb-rl") + e;
        case 45:
          return st + e + ir + lt(e, /[svh]\w+-[tblr]{2}/, "lr") + e;
      }
      return st + e + ir + e + e;
  }
  return e;
}
var sL = function(t, r, n, o) {
  if (t.length > -1 && !t.return) switch (t.type) {
    case vf:
      t.return = Yb(t.value, t.length);
      break;
    case qb:
      return ca([oi(t, {
        value: lt(t.value, "@", "@" + st)
      })], o);
    case bf:
      if (t.length) return qD(t.props, function(a) {
        switch (VD(a, /(::plac\w+|:read-\w+)/)) {
          case ":read-only":
          case ":read-write":
            return ca([oi(t, {
              props: [lt(a, /:(read-\w+)/, ":" + wl + "$1")]
            })], o);
          case "::placeholder":
            return ca([oi(t, {
              props: [lt(a, /:(plac\w+)/, ":" + st + "input-$1")]
            }), oi(t, {
              props: [lt(a, /:(plac\w+)/, ":" + wl + "$1")]
            }), oi(t, {
              props: [lt(a, /:(plac\w+)/, ir + "input-$1")]
            })], o);
        }
        return "";
      });
  }
}, lL = [sL], cL = function(t) {
  var r = t.key;
  if (r === "css") {
    var n = document.querySelectorAll("style[data-emotion]:not([data-s])");
    Array.prototype.forEach.call(n, function($) {
      var b = $.getAttribute("data-emotion");
      b.indexOf(" ") !== -1 && (document.head.appendChild($), $.setAttribute("data-s", ""));
    });
  }
  var o = t.stylisPlugins || lL, a = {}, i, s = [];
  i = t.container || document.head, Array.prototype.forEach.call(
    // this means we will ignore elements which don't have a space in them which
    // means that the style elements we're looking at are only Emotion 11 server-rendered style elements
    document.querySelectorAll('style[data-emotion^="' + r + ' "]'),
    function($) {
      for (var b = $.getAttribute("data-emotion").split(" "), g = 1; g < b.length; g++)
        a[b[g]] = !0;
      s.push($);
    }
  );
  var l, c = [aL, iL];
  {
    var u, f = [QD, tL(function($) {
      u.insert($);
    })], d = eL(c.concat(o, f)), p = function(b) {
      return ca(XD(b), d);
    };
    l = function(b, g, y, S) {
      u = y, p(b ? b + "{" + g.styles + "}" : g.styles), S && (h.inserted[g.name] = !0);
    };
  }
  var h = {
    key: r,
    sheet: new jD({
      key: r,
      container: i,
      nonce: t.nonce,
      speedy: t.speedy,
      prepend: t.prepend,
      insertionPoint: t.insertionPoint
    }),
    nonce: t.nonce,
    inserted: a,
    registered: {},
    insert: l
  };
  return h.sheet.hydrate(s), h;
}, Xb = { exports: {} }, ft = {};
/** @license React v16.13.1
 * react-is.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 Nm;
function uL() {
  if (Nm) return ft;
  Nm = 1;
  var e = typeof Symbol == "function" && Symbol.for, t = e ? Symbol.for("react.element") : 60103, r = e ? Symbol.for("react.portal") : 60106, n = e ? Symbol.for("react.fragment") : 60107, o = e ? Symbol.for("react.strict_mode") : 60108, a = e ? Symbol.for("react.profiler") : 60114, i = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, l = e ? Symbol.for("react.async_mode") : 60111, c = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, f = e ? Symbol.for("react.suspense") : 60113, d = e ? Symbol.for("react.suspense_list") : 60120, p = e ? Symbol.for("react.memo") : 60115, h = e ? Symbol.for("react.lazy") : 60116, $ = e ? Symbol.for("react.block") : 60121, b = e ? Symbol.for("react.fundamental") : 60117, g = e ? Symbol.for("react.responder") : 60118, y = e ? Symbol.for("react.scope") : 60119;
  function S(w) {
    if (typeof w == "object" && w !== null) {
      var v = w.$$typeof;
      switch (v) {
        case t:
          switch (w = w.type, w) {
            case l:
            case c:
            case n:
            case a:
            case o:
            case f:
              return w;
            default:
              switch (w = w && w.$$typeof, w) {
                case s:
                case u:
                case h:
                case p:
                case i:
                  return w;
                default:
                  return v;
              }
          }
        case r:
          return v;
      }
    }
  }
  function m(w) {
    return S(w) === c;
  }
  return ft.AsyncMode = l, ft.ConcurrentMode = c, ft.ContextConsumer = s, ft.ContextProvider = i, ft.Element = t, ft.ForwardRef = u, ft.Fragment = n, ft.Lazy = h, ft.Memo = p, ft.Portal = r, ft.Profiler = a, ft.StrictMode = o, ft.Suspense = f, ft.isAsyncMode = function(w) {
    return m(w) || S(w) === l;
  }, ft.isConcurrentMode = m, ft.isContextConsumer = function(w) {
    return S(w) === s;
  }, ft.isContextProvider = function(w) {
    return S(w) === i;
  }, ft.isElement = function(w) {
    return typeof w == "object" && w !== null && w.$$typeof === t;
  }, ft.isForwardRef = function(w) {
    return S(w) === u;
  }, ft.isFragment = function(w) {
    return S(w) === n;
  }, ft.isLazy = function(w) {
    return S(w) === h;
  }, ft.isMemo = function(w) {
    return S(w) === p;
  }, ft.isPortal = function(w) {
    return S(w) === r;
  }, ft.isProfiler = function(w) {
    return S(w) === a;
  }, ft.isStrictMode = function(w) {
    return S(w) === o;
  }, ft.isSuspense = function(w) {
    return S(w) === f;
  }, ft.isValidElementType = function(w) {
    return typeof w == "string" || typeof w == "function" || w === n || w === c || w === a || w === o || w === f || w === d || typeof w == "object" && w !== null && (w.$$typeof === h || w.$$typeof === p || w.$$typeof === i || w.$$typeof === s || w.$$typeof === u || w.$$typeof === b || w.$$typeof === g || w.$$typeof === y || w.$$typeof === $);
  }, ft.typeOf = S, ft;
}
Xb.exports = uL();
var dL = Xb.exports, Zb = dL, fL = {
  $$typeof: !0,
  render: !0,
  defaultProps: !0,
  displayName: !0,
  propTypes: !0
}, pL = {
  $$typeof: !0,
  compare: !0,
  defaultProps: !0,
  displayName: !0,
  propTypes: !0,
  type: !0
}, Qb = {};
Qb[Zb.ForwardRef] = fL;
Qb[Zb.Memo] = pL;
var hL = !0;
function ev(e, t, r) {
  var n = "";
  return r.split(" ").forEach(function(o) {
    e[o] !== void 0 ? t.push(e[o] + ";") : o && (n += o + " ");
  }), n;
}
var Sf = function(t, r, n) {
  var o = t.key + "-" + r.name;
  // we only need to add the styles to the registered cache if the
  // class name could be used further down
  // the tree but if it's a string tag, we know it won't
  // so we don't have to add it to registered cache.
  // this improves memory usage since we can avoid storing the whole style string
  (n === !1 || // we need to always store it if we're in compat mode and
  // in node since emotion-server relies on whether a style is in
  // the registered cache to know whether a style is global or not
  // also, note that this check will be dead code eliminated in the browser
  hL === !1) && t.registered[o] === void 0 && (t.registered[o] = r.styles);
}, wf = function(t, r, n) {
  Sf(t, r, n);
  var o = t.key + "-" + r.name;
  if (t.inserted[r.name] === void 0) {
    var a = r;
    do
      t.insert(r === a ? "." + o : "", a, t.sheet, !0), a = a.next;
    while (a !== void 0);
  }
};
function mL(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 gL = {
  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
}, yL = /[A-Z]|^ms/g, bL = /_EMO_([^_]+?)_([^]*?)_EMO_/g, tv = function(t) {
  return t.charCodeAt(1) === 45;
}, Fm = function(t) {
  return t != null && typeof t != "boolean";
}, iu = /* @__PURE__ */ Jb(function(e) {
  return tv(e) ? e : e.replace(yL, "-$&").toLowerCase();
}), jm = function(t, r) {
  switch (t) {
    case "animation":
    case "animationName":
      if (typeof r == "string")
        return r.replace(bL, function(n, o, a) {
          return un = {
            name: o,
            styles: a,
            next: un
          }, o;
        });
  }
  return gL[t] !== 1 && !tv(t) && typeof r == "number" && r !== 0 ? r + "px" : r;
};
function qi(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 un = {
          name: o.name,
          styles: o.styles,
          next: un
        }, o.name;
      var a = r;
      if (a.styles !== void 0) {
        var i = a.next;
        if (i !== void 0)
          for (; i !== void 0; )
            un = {
              name: i.name,
              styles: i.styles,
              next: un
            }, i = i.next;
        var s = a.styles + ";";
        return s;
      }
      return vL(e, t, r);
    }
    case "function": {
      if (e !== void 0) {
        var l = un, c = r(e);
        return un = l, qi(e, t, c);
      }
      break;
    }
  }
  var u = r;
  if (t == null)
    return u;
  var f = t[u];
  return f !== void 0 ? f : u;
}
function vL(e, t, r) {
  var n = "";
  if (Array.isArray(r))
    for (var o = 0; o < r.length; o++)
      n += qi(e, t, r[o]) + ";";
  else
    for (var a in r) {
      var i = r[a];
      if (typeof i != "object") {
        var s = i;
        t != null && t[s] !== void 0 ? n += a + "{" + t[s] + "}" : Fm(s) && (n += iu(a) + ":" + jm(a, s) + ";");
      } else if (Array.isArray(i) && typeof i[0] == "string" && (t == null || t[i[0]] === void 0))
        for (var l = 0; l < i.length; l++)
          Fm(i[l]) && (n += iu(a) + ":" + jm(a, i[l]) + ";");
      else {
        var c = qi(e, t, i);
        switch (a) {
          case "animation":
          case "animationName": {
            n += iu(a) + ":" + c + ";";
            break;
          }
          default:
            n += a + "{" + c + "}";
        }
      }
    }
  return n;
}
var Dm = /label:\s*([^\s;{]+)\s*(;|$)/g, un;
function fs(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 = "";
  un = void 0;
  var a = e[0];
  if (a == null || a.raw === void 0)
    n = !1, o += qi(r, t, a);
  else {
    var i = a;
    o += i[0];
  }
  for (var s = 1; s < e.length; s++)
    if (o += qi(r, t, e[s]), n) {
      var l = a;
      o += l[s];
    }
  Dm.lastIndex = 0;
  for (var c = "", u; (u = Dm.exec(o)) !== null; )
    c += "-" + u[1];
  var f = mL(o) + c;
  return {
    name: f,
    styles: o,
    next: un
  };
}
var $L = function(t) {
  return t();
}, rv = M.useInsertionEffect ? M.useInsertionEffect : !1, SL = rv || $L, Lm = rv || M.useLayoutEffect, nv = /* @__PURE__ */ M.createContext(
  // we're doing this to avoid preconstruct's dead code elimination in this one case
  // because this module is primarily intended for the browser and node
  // but it's also required in react native and similar environments sometimes
  // and we could have a special build just for that
  // but this is much easier and the native packages
  // might use a different theme context in the future anyway
  typeof HTMLElement < "u" ? /* @__PURE__ */ cL({
    key: "css"
  }) : null
);
nv.Provider;
var Cf = function(t) {
  return /* @__PURE__ */ cy(function(r, n) {
    var o = h$(nv);
    return t(r, o, n);
  });
}, gc = /* @__PURE__ */ M.createContext({}), Ef = {}.hasOwnProperty, Bu = "__EMOTION_TYPE_PLEASE_DO_NOT_USE__", wL = function(t, r) {
  var n = {};
  for (var o in r)
    Ef.call(r, o) && (n[o] = r[o]);
  return n[Bu] = t, n;
}, CL = function(t) {
  var r = t.cache, n = t.serialized, o = t.isStringTag;
  return Sf(r, n, o), SL(function() {
    return wf(r, n, o);
  }), null;
}, EL = /* @__PURE__ */ Cf(function(e, t, r) {
  var n = e.css;
  typeof n == "string" && t.registered[n] !== void 0 && (n = t.registered[n]);
  var o = e[Bu], a = [n], i = "";
  typeof e.className == "string" ? i = ev(t.registered, a, e.className) : e.className != null && (i = e.className + " ");
  var s = fs(a, void 0, M.useContext(gc));
  i += t.key + "-" + s.name;
  var l = {};
  for (var c in e)
    Ef.call(e, c) && c !== "css" && c !== Bu && (l[c] = e[c]);
  return l.className = i, r && (l.ref = r), /* @__PURE__ */ M.createElement(M.Fragment, null, /* @__PURE__ */ M.createElement(CL, {
    cache: t,
    serialized: s,
    isStringTag: typeof o == "string"
  }), /* @__PURE__ */ M.createElement(o, l));
}), _L = EL, xL = function(t, r) {
  var n = arguments;
  if (r == null || !Ef.call(r, "css"))
    return M.createElement.apply(void 0, n);
  var o = n.length, a = new Array(o);
  a[0] = _L, a[1] = wL(t, r);
  for (var i = 2; i < o; i++)
    a[i] = n[i];
  return M.createElement.apply(null, a);
};
(function(e) {
  var t;
  t || (t = e.JSX || (e.JSX = {}));
})(xL);
var PL = /* @__PURE__ */ Cf(function(e, t) {
  var r = e.styles, n = fs([r], void 0, M.useContext(gc)), o = M.useRef();
  return Lm(function() {
    var a = t.key + "-global", i = new t.sheet.constructor({
      key: a,
      nonce: t.sheet.nonce,
      container: t.sheet.container,
      speedy: t.sheet.isSpeedy
    }), s = !1, l = document.querySelector('style[data-emotion="' + a + " " + n.name + '"]');
    return t.sheet.tags.length && (i.before = t.sheet.tags[0]), l !== null && (s = !0, l.setAttribute("data-emotion", a), i.hydrate([l])), o.current = [i, s], function() {
      i.flush();
    };
  }, [t]), Lm(function() {
    var a = o.current, i = a[0], s = a[1];
    if (s) {
      a[1] = !1;
      return;
    }
    if (n.next !== void 0 && wf(t, n.next, !0), i.tags.length) {
      var l = i.tags[i.tags.length - 1].nextElementSibling;
      i.before = l, i.flush();
    }
    t.insert("", n, i, !1);
  }, [t, n.name]), null;
});
function qa() {
  for (var e = arguments.length, t = new Array(e), r = 0; r < e; r++)
    t[r] = arguments[r];
  return fs(t);
}
function fo() {
  var e = qa.apply(void 0, arguments), t = "animation-" + e.name;
  return {
    name: t,
    styles: "@keyframes " + t + "{" + e.styles + "}",
    anim: 1,
    toString: function() {
      return "_EMO_" + this.name + "_" + this.styles + "_EMO_";
    }
  };
}
var kL = function(t) {
  return t();
}, OL = M.useInsertionEffect ? M.useInsertionEffect : !1, AL = OL || kL, IL = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/, RL = /* @__PURE__ */ Jb(
  function(e) {
    return IL.test(e) || e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && e.charCodeAt(2) < 91;
  }
  /* Z+1 */
), TL = RL, ML = function(t) {
  return t !== "theme";
}, Bm = function(t) {
  return typeof t == "string" && // 96 is one less than the char code
  // for "a" so this is checking that
  // it's a lowercase character
  t.charCodeAt(0) > 96 ? TL : ML;
}, zm = function(t, r, n) {
  var o;
  if (r) {
    var a = r.shouldForwardProp;
    o = t.__emotion_forwardProp && a ? function(i) {
      return t.__emotion_forwardProp(i) && a(i);
    } : a;
  }
  return typeof o != "function" && n && (o = t.__emotion_forwardProp), o;
}, NL = function(t) {
  var r = t.cache, n = t.serialized, o = t.isStringTag;
  return Sf(r, n, o), AL(function() {
    return wf(r, n, o);
  }), null;
}, FL = function e(t, r) {
  var n = t.__emotion_real === t, o = n && t.__emotion_base || t, a, i;
  r !== void 0 && (a = r.label, i = r.target);
  var s = zm(t, r, n), l = s || Bm(o), c = !l("as");
  return function() {
    var u = arguments, f = n && t.__emotion_styles !== void 0 ? t.__emotion_styles.slice(0) : [];
    if (a !== void 0 && f.push("label:" + a + ";"), u[0] == null || u[0].raw === void 0)
      f.push.apply(f, u);
    else {
      var d = u[0];
      f.push(d[0]);
      for (var p = u.length, h = 1; h < p; h++)
        f.push(u[h], d[h]);
    }
    var $ = Cf(function(b, g, y) {
      var S = c && b.as || o, m = "", w = [], v = b;
      if (b.theme == null) {
        v = {};
        for (var E in b)
          v[E] = b[E];
        v.theme = M.useContext(gc);
      }
      typeof b.className == "string" ? m = ev(g.registered, w, b.className) : b.className != null && (m = b.className + " ");
      var I = fs(f.concat(w), g.registered, v);
      m += g.key + "-" + I.name, i !== void 0 && (m += " " + i);
      var R = c && s === void 0 ? Bm(S) : l, C = {};
      for (var T in b)
        c && T === "as" || R(T) && (C[T] = b[T]);
      return C.className = m, y && (C.ref = y), /* @__PURE__ */ M.createElement(M.Fragment, null, /* @__PURE__ */ M.createElement(NL, {
        cache: g,
        serialized: I,
        isStringTag: typeof S == "string"
      }), /* @__PURE__ */ M.createElement(S, C));
    });
    return $.displayName = a !== void 0 ? a : "Styled(" + (typeof o == "string" ? o : o.displayName || o.name || "Component") + ")", $.defaultProps = t.defaultProps, $.__emotion_real = $, $.__emotion_base = o, $.__emotion_styles = f, $.__emotion_forwardProp = s, Object.defineProperty($, "toString", {
      value: function() {
        return "." + i;
      }
    }), $.withComponent = function(b, g) {
      var y = e(b, Sl({}, r, g, {
        shouldForwardProp: zm($, g, !0)
      }));
      return y.apply(void 0, f);
    }, $;
  };
}, jL = [
  "a",
  "abbr",
  "address",
  "area",
  "article",
  "aside",
  "audio",
  "b",
  "base",
  "bdi",
  "bdo",
  "big",
  "blockquote",
  "body",
  "br",
  "button",
  "canvas",
  "caption",
  "cite",
  "code",
  "col",
  "colgroup",
  "data",
  "datalist",
  "dd",
  "del",
  "details",
  "dfn",
  "dialog",
  "div",
  "dl",
  "dt",
  "em",
  "embed",
  "fieldset",
  "figcaption",
  "figure",
  "footer",
  "form",
  "h1",
  "h2",
  "h3",
  "h4",
  "h5",
  "h6",
  "head",
  "header",
  "hgroup",
  "hr",
  "html",
  "i",
  "iframe",
  "img",
  "input",
  "ins",
  "kbd",
  "keygen",
  "label",
  "legend",
  "li",
  "link",
  "main",
  "map",
  "mark",
  "marquee",
  "menu",
  "menuitem",
  "meta",
  "meter",
  "nav",
  "noscript",
  "object",
  "ol",
  "optgroup",
  "option",
  "output",
  "p",
  "param",
  "picture",
  "pre",
  "progress",
  "q",
  "rp",
  "rt",
  "ruby",
  "s",
  "samp",
  "script",
  "section",
  "select",
  "small",
  "source",
  "span",
  "strong",
  "style",
  "sub",
  "summary",
  "sup",
  "table",
  "tbody",
  "td",
  "textarea",
  "tfoot",
  "th",
  "thead",
  "time",
  "title",
  "tr",
  "track",
  "u",
  "ul",
  "var",
  "video",
  "wbr",
  // SVG
  "circle",
  "clipPath",
  "defs",
  "ellipse",
  "foreignObject",
  "g",
  "image",
  "line",
  "linearGradient",
  "mask",
  "path",
  "pattern",
  "polygon",
  "polyline",
  "radialGradient",
  "rect",
  "stop",
  "svg",
  "text",
  "tspan"
], zu = FL.bind(null);
jL.forEach(function(e) {
  zu[e] = zu(e);
});
function DL(e) {
  return e == null || Object.keys(e).length === 0;
}
function LL(e) {
  const {
    styles: t,
    defaultTheme: r = {}
  } = e;
  return /* @__PURE__ */ P(PL, {
    styles: typeof t == "function" ? (o) => t(DL(o) ? r : o) : t
  });
}
function ov(e, t) {
  return zu(e, t);
}
function BL(e, t) {
  Array.isArray(e.__emotion_styles) && (e.__emotion_styles = t(e.__emotion_styles));
}
const Um = [];
function Vm(e) {
  return Um[0] = e, fs(Um);
}
const zL = (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 UL(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, a = zL(t), i = Object.keys(a);
  function s(d) {
    return `@media (min-width:${typeof t[d] == "number" ? t[d] : d}${r})`;
  }
  function l(d) {
    return `@media (max-width:${(typeof t[d] == "number" ? t[d] : d) - n / 100}${r})`;
  }
  function c(d, p) {
    const h = i.indexOf(p);
    return `@media (min-width:${typeof t[d] == "number" ? t[d] : d}${r}) and (max-width:${(h !== -1 && typeof t[i[h]] == "number" ? t[i[h]] : p) - n / 100}${r})`;
  }
  function u(d) {
    return i.indexOf(d) + 1 < i.length ? c(d, i[i.indexOf(d) + 1]) : s(d);
  }
  function f(d) {
    const p = i.indexOf(d);
    return p === 0 ? s(i[1]) : p === i.length - 1 ? l(i[p]) : c(d, i[i.indexOf(d) + 1]).replace("@media", "@media not all and");
  }
  return {
    keys: i,
    values: a,
    up: s,
    down: l,
    between: c,
    only: u,
    not: f,
    unit: r,
    ...o
  };
}
const VL = {
  borderRadius: 4
};
function av(e = 8, t = gf({
  spacing: e
})) {
  if (e.mui)
    return e;
  const r = (...n) => (n.length === 0 ? [1] : n).map((a) => {
    const i = t(a);
    return typeof i == "number" ? `${i}px` : i;
  }).join(" ");
  return r.mui = !0, r;
}
function qL(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 yc(e = {}, ...t) {
  const {
    breakpoints: r = {},
    palette: n = {},
    spacing: o,
    shape: a = {},
    ...i
  } = e, s = UL(r), l = av(o);
  let c = lr({
    breakpoints: s,
    direction: "ltr",
    components: {},
    // Inject component definitions.
    palette: {
      mode: "light",
      ...n
    },
    spacing: l,
    shape: {
      ...VL,
      ...a
    }
  }, i);
  return c = q9(c), c.applyStyles = qL, c = t.reduce((u, f) => lr(u, f), c), c.unstable_sxConfig = {
    ...us,
    ...i == null ? void 0 : i.unstable_sxConfig
  }, c.unstable_sx = function(f) {
    return ko({
      sx: f,
      theme: this
    });
  }, c;
}
function WL(e) {
  return Object.keys(e).length === 0;
}
function KL(e = null) {
  const t = M.useContext(gc);
  return !t || WL(t) ? e : t;
}
const GL = yc();
function ps(e = GL) {
  return KL(e);
}
function HL({
  styles: e,
  themeId: t,
  defaultTheme: r = {}
}) {
  const n = ps(r), o = typeof e == "function" ? e(t && n[t] || n) : e;
  return /* @__PURE__ */ P(LL, {
    styles: o
  });
}
function JL(e = {}) {
  const {
    themeId: t,
    defaultTheme: r,
    defaultClassName: n = "MuiBox-root",
    generateClassName: o
  } = e, a = ov("div", {
    shouldForwardProp: (s) => s !== "theme" && s !== "sx" && s !== "as"
  })(ko);
  return /* @__PURE__ */ M.forwardRef(function(l, c) {
    const u = ps(r), {
      className: f,
      component: d = "div",
      ...p
    } = fc(l);
    return /* @__PURE__ */ P(a, {
      as: d,
      ref: c,
      className: Ee(f, o ? o(n) : n),
      theme: t && u[t] || u,
      ...p
    });
  });
}
function iv(e) {
  const {
    variants: t,
    ...r
  } = e, n = {
    variants: t,
    style: Vm(r),
    isProcessed: !0
  };
  return n.style === r || t && t.forEach((o) => {
    typeof o.style != "function" && (o.style = Vm(o.style));
  }), n;
}
const YL = yc();
function su(e) {
  return e !== "ownerState" && e !== "theme" && e !== "sx" && e !== "as";
}
function XL(e) {
  return e ? (t, r) => r[e] : null;
}
function ZL(e, t, r) {
  e.theme = e8(e.theme) ? r : e.theme[t] || e.theme;
}
function nl(e, t) {
  const r = typeof t == "function" ? t(e) : t;
  if (Array.isArray(r))
    return r.flatMap((n) => nl(e, n));
  if (Array.isArray(r == null ? void 0 : r.variants)) {
    let n;
    if (r.isProcessed)
      n = r.style;
    else {
      const {
        variants: o,
        ...a
      } = r;
      n = a;
    }
    return sv(e, r.variants, [n]);
  }
  return r != null && r.isProcessed ? r.style : r;
}
function sv(e, t, r = []) {
  var o;
  let n;
  e: for (let a = 0; a < t.length; a += 1) {
    const i = t[a];
    if (typeof i.props == "function") {
      if (n ?? (n = {
        ...e,
        ...e.ownerState,
        ownerState: e.ownerState
      }), !i.props(n))
        continue;
    } else
      for (const s in i.props)
        if (e[s] !== i.props[s] && ((o = e.ownerState) == null ? void 0 : o[s]) !== i.props[s])
          continue e;
    typeof i.style == "function" ? (n ?? (n = {
      ...e,
      ...e.ownerState,
      ownerState: e.ownerState
    }), r.push(i.style(n))) : r.push(i.style);
  }
  return r;
}
function lv(e = {}) {
  const {
    themeId: t,
    defaultTheme: r = YL,
    rootShouldForwardProp: n = su,
    slotShouldForwardProp: o = su
  } = e;
  function a(s) {
    ZL(s, t, r);
  }
  return (s, l = {}) => {
    BL(s, (w) => w.filter((v) => v !== ko));
    const {
      name: c,
      slot: u,
      skipVariantsResolver: f,
      skipSx: d,
      // TODO v6: remove `lowercaseFirstLetter()` in the next major release
      // For more details: https://github.com/mui/material-ui/pull/37908
      overridesResolver: p = XL(r8(u)),
      ...h
    } = l, $ = f !== void 0 ? f : (
      // TODO v6: remove `Root` in the next major release
      // For more details: https://github.com/mui/material-ui/pull/37908
      u && u !== "Root" && u !== "root" || !1
    ), b = d || !1;
    let g = su;
    u === "Root" || u === "root" ? g = n : u ? g = o : t8(s) && (g = void 0);
    const y = ov(s, {
      shouldForwardProp: g,
      label: QL(),
      ...h
    }), S = (w) => {
      if (typeof w == "function" && w.__emotion_real !== w)
        return function(E) {
          return nl(E, w);
        };
      if (dn(w)) {
        const v = iv(w);
        return v.variants ? function(I) {
          return nl(I, v);
        } : v.style;
      }
      return w;
    }, m = (...w) => {
      const v = [], E = w.map(S), I = [];
      if (v.push(a), c && p && I.push(function(F) {
        var X, V;
        const z = (V = (X = F.theme.components) == null ? void 0 : X[c]) == null ? void 0 : V.styleOverrides;
        if (!z)
          return null;
        const L = {};
        for (const ie in z)
          L[ie] = nl(F, z[ie]);
        return p(F, L);
      }), c && !$ && I.push(function(F) {
        var L, X;
        const D = F.theme, z = (X = (L = D == null ? void 0 : D.components) == null ? void 0 : L[c]) == null ? void 0 : X.variants;
        return z ? sv(F, z) : null;
      }), b || I.push(ko), Array.isArray(E[0])) {
        const T = E.shift(), F = new Array(v.length).fill(""), D = new Array(I.length).fill("");
        let z;
        z = [...F, ...T, ...D], z.raw = [...F, ...T.raw, ...D], v.unshift(z);
      }
      const R = [...v, ...E, ...I], C = y(...R);
      return s.muiName && (C.muiName = s.muiName), C;
    };
    return y.withConfig && (m.withConfig = y.withConfig), m;
  };
}
function QL(e, t) {
  return void 0;
}
function e8(e) {
  for (const t in e)
    return !1;
  return !0;
}
function t8(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 r8(e) {
  return e && e.charAt(0).toLowerCase() + e.slice(1);
}
const n8 = lv();
function o8(e) {
  const {
    theme: t,
    name: r,
    props: n
  } = e;
  return !t || !t.components || !t.components[r] || !t.components[r].defaultProps ? n : zi(t.components[r].defaultProps, n);
}
function a8({
  props: e,
  name: t,
  defaultTheme: r,
  themeId: n
}) {
  let o = ps(r);
  return n && (o = o[n] || o), o8({
    theme: o,
    name: t,
    props: e
  });
}
function _f(e, t = 0, r = 1) {
  return ta(e, t, r);
}
function i8(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 lo(e) {
  if (e.type)
    return e;
  if (e.charAt(0) === "#")
    return lo(i8(e));
  const t = e.indexOf("("), r = e.substring(0, t);
  if (!["rgb", "rgba", "hsl", "hsla", "color"].includes(r))
    throw new Error(Dn(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(Dn(10, o));
  } else
    n = n.split(",");
  return n = n.map((a) => parseFloat(a)), {
    type: r,
    values: n,
    colorSpace: o
  };
}
const s8 = (e) => {
  const t = lo(e);
  return t.values.slice(0, 3).map((r, n) => t.type.includes("hsl") && n !== 0 ? `${r}%` : r).join(" ");
}, mi = (e, t) => {
  try {
    return s8(e);
  } catch {
    return e;
  }
};
function bc(e) {
  const {
    type: t,
    colorSpace: r
  } = e;
  let {
    values: n
  } = e;
  return t.includes("rgb") ? n = n.map((o, a) => a < 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 cv(e) {
  e = lo(e);
  const {
    values: t
  } = e, r = t[0], n = t[1] / 100, o = t[2] / 100, a = n * Math.min(o, 1 - o), i = (c, u = (c + r / 30) % 12) => o - a * Math.max(Math.min(u - 3, 9 - u, 1), -1);
  let s = "rgb";
  const l = [Math.round(i(0) * 255), Math.round(i(8) * 255), Math.round(i(4) * 255)];
  return e.type === "hsla" && (s += "a", l.push(t[3])), bc({
    type: s,
    values: l
  });
}
function Uu(e) {
  e = lo(e);
  let t = e.type === "hsl" || e.type === "hsla" ? lo(cv(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 l8(e, t) {
  const r = Uu(e), n = Uu(t);
  return (Math.max(r, n) + 0.05) / (Math.min(r, n) + 0.05);
}
function Lt(e, t) {
  return e = lo(e), t = _f(t), (e.type === "rgb" || e.type === "hsl") && (e.type += "a"), e.type === "color" ? e.values[3] = `/${t}` : e.values[3] = t, bc(e);
}
function As(e, t, r) {
  try {
    return Lt(e, t);
  } catch {
    return e;
  }
}
function Sa(e, t) {
  if (e = lo(e), t = _f(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 bc(e);
}
function bt(e, t, r) {
  try {
    return Sa(e, t);
  } catch {
    return e;
  }
}
function wa(e, t) {
  if (e = lo(e), t = _f(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 bc(e);
}
function vt(e, t, r) {
  try {
    return wa(e, t);
  } catch {
    return e;
  }
}
function c8(e, t = 0.15) {
  return Uu(e) > 0.5 ? Sa(e, t) : wa(e, t);
}
function Is(e, t, r) {
  try {
    return c8(e, t);
  } catch {
    return e;
  }
}
const u8 = /* @__PURE__ */ M.createContext(), xf = () => M.useContext(u8) ?? !1, d8 = /* @__PURE__ */ M.createContext(void 0);
function f8(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 ? zi(o.defaultProps, n) : !o.styleOverrides && !o.variants ? zi(o, n) : n;
}
function p8({
  props: e,
  name: t
}) {
  const r = M.useContext(d8);
  return f8({
    props: e,
    name: t,
    theme: {
      components: r
    }
  });
}
const qm = {
  theme: void 0
};
function h8(e) {
  let t, r;
  return function(o) {
    let a = t;
    return (a === void 0 || o.theme !== r) && (qm.theme = o.theme, a = iv(e(qm)), t = a, r = o.theme), a;
  };
}
function m8(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 Wm = (e, t, r, n = []) => {
  let o = e;
  t.forEach((a, i) => {
    i === t.length - 1 ? Array.isArray(o) ? o[Number(a)] = r : o && typeof o == "object" && (o[a] = r) : o && typeof o == "object" && (o[a] || (o[a] = n.includes(a) ? [] : {}), o = o[a]);
  });
}, g8 = (e, t, r) => {
  function n(o, a = [], i = []) {
    Object.entries(o).forEach(([s, l]) => {
      (!r || !r([...a, s])) && l != null && (typeof l == "object" && Object.keys(l).length > 0 ? n(l, [...a, s], Array.isArray(l) ? [...i, s] : i) : t([...a, s], l, i));
    });
  }
  n(e);
}, y8 = (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 lu(e, t) {
  const {
    prefix: r,
    shouldSkipGeneratingVar: n
  } = t || {}, o = {}, a = {}, i = {};
  return g8(
    e,
    (s, l, c) => {
      if ((typeof l == "string" || typeof l == "number") && (!n || !n(s, l))) {
        const u = `--${r ? `${r}-` : ""}${s.join("-")}`, f = y8(s, l);
        Object.assign(o, {
          [u]: f
        }), Wm(a, s, `var(${u})`, c), Wm(i, s, `var(${u}, ${f})`, c);
      }
    },
    (s) => s[0] === "vars"
    // skip 'vars/*' paths
  ), {
    css: o,
    vars: a,
    varsWithDefaults: i
  };
}
function b8(e, t = {}) {
  const {
    getSelector: r = b,
    disableCssColorScheme: n,
    colorSchemeSelector: o
  } = t, {
    colorSchemes: a = {},
    components: i,
    defaultColorScheme: s = "light",
    ...l
  } = e, {
    vars: c,
    css: u,
    varsWithDefaults: f
  } = lu(l, t);
  let d = f;
  const p = {}, {
    [s]: h,
    ...$
  } = a;
  if (Object.entries($ || {}).forEach(([S, m]) => {
    const {
      vars: w,
      css: v,
      varsWithDefaults: E
    } = lu(m, t);
    d = lr(d, E), p[S] = {
      css: v,
      vars: w
    };
  }), h) {
    const {
      css: S,
      vars: m,
      varsWithDefaults: w
    } = lu(h, t);
    d = lr(d, w), p[s] = {
      css: S,
      vars: m
    };
  }
  function b(S, m) {
    var v, E;
    let w = o;
    if (o === "class" && (w = ".%s"), o === "data" && (w = "[data-%s]"), o != null && o.startsWith("data-") && !o.includes("%s") && (w = `[${o}="%s"]`), S) {
      if (w === "media")
        return e.defaultColorScheme === S ? ":root" : {
          [`@media (prefers-color-scheme: ${((E = (v = a[S]) == null ? void 0 : v.palette) == null ? void 0 : E.mode) || S})`]: {
            ":root": m
          }
        };
      if (w)
        return e.defaultColorScheme === S ? `:root, ${w.replace("%s", String(S))}` : w.replace("%s", String(S));
    }
    return ":root";
  }
  return {
    vars: d,
    generateThemeVars: () => {
      let S = {
        ...c
      };
      return Object.entries(p).forEach(([, {
        vars: m
      }]) => {
        S = lr(S, m);
      }), S;
    },
    generateStyleSheets: () => {
      var I, R;
      const S = [], m = e.defaultColorScheme || "light";
      function w(C, T) {
        Object.keys(T).length && S.push(typeof C == "string" ? {
          [C]: {
            ...T
          }
        } : C);
      }
      w(r(void 0, {
        ...u
      }), u);
      const {
        [m]: v,
        ...E
      } = p;
      if (v) {
        const {
          css: C
        } = v, T = (R = (I = a[m]) == null ? void 0 : I.palette) == null ? void 0 : R.mode, F = !n && T ? {
          colorScheme: T,
          ...C
        } : {
          ...C
        };
        w(r(m, {
          ...F
        }), F);
      }
      return Object.entries(E).forEach(([C, {
        css: T
      }]) => {
        var z, L;
        const F = (L = (z = a[C]) == null ? void 0 : z.palette) == null ? void 0 : L.mode, D = !n && F ? {
          colorScheme: F,
          ...T
        } : {
          ...T
        };
        w(r(C, {
          ...D
        }), D);
      }), S;
    }
  };
}
function v8(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 $8 = (e, t) => e.filter((r) => t.includes(r)), Wa = (e, t, r) => {
  const n = e.keys[0];
  Array.isArray(t) ? t.forEach((o, a) => {
    r((i, s) => {
      a <= e.keys.length - 1 && (a === 0 ? Object.assign(i, s) : i[e.up(e.keys[a])] = s);
    }, o);
  }) : t && typeof t == "object" ? (Object.keys(t).length > e.keys.length ? e.keys : $8(e.keys, Object.keys(t))).forEach((a) => {
    if (e.keys.includes(a)) {
      const i = t[a];
      i !== void 0 && r((s, l) => {
        n === a ? Object.assign(s, l) : s[e.up(a)] = l;
      }, i);
    }
  }) : (typeof t == "number" || typeof t == "string") && r((o, a) => {
    Object.assign(o, a);
  }, t);
};
function Cl(e) {
  return `--Grid-${e}Spacing`;
}
function vc(e) {
  return `--Grid-parent-${e}Spacing`;
}
const Km = "--Grid-columns", ua = "--Grid-parent-columns", S8 = ({
  theme: e,
  ownerState: t
}) => {
  const r = {};
  return Wa(e.breakpoints, t.size, (n, o) => {
    let a = {};
    o === "grow" && (a = {
      flexBasis: 0,
      flexGrow: 1,
      maxWidth: "100%"
    }), o === "auto" && (a = {
      flexBasis: "auto",
      flexGrow: 0,
      flexShrink: 0,
      maxWidth: "none",
      width: "auto"
    }), typeof o == "number" && (a = {
      flexGrow: 0,
      flexBasis: "auto",
      width: `calc(100% * ${o} / var(${ua}) - (var(${ua}) - ${o}) * (var(${vc("column")}) / var(${ua})))`
    }), n(r, a);
  }), r;
}, w8 = ({
  theme: e,
  ownerState: t
}) => {
  const r = {};
  return Wa(e.breakpoints, t.offset, (n, o) => {
    let a = {};
    o === "auto" && (a = {
      marginLeft: "auto"
    }), typeof o == "number" && (a = {
      marginLeft: o === 0 ? "0px" : `calc(100% * ${o} / var(${ua}) + var(${vc("column")}) * ${o} / var(${ua}))`
    }), n(r, a);
  }), r;
}, C8 = ({
  theme: e,
  ownerState: t
}) => {
  if (!t.container)
    return {};
  const r = {
    [Km]: 12
  };
  return Wa(e.breakpoints, t.columns, (n, o) => {
    const a = o ?? 12;
    n(r, {
      [Km]: a,
      "> *": {
        [ua]: a
      }
    });
  }), r;
}, E8 = ({
  theme: e,
  ownerState: t
}) => {
  if (!t.container)
    return {};
  const r = {};
  return Wa(e.breakpoints, t.rowSpacing, (n, o) => {
    var i;
    const a = typeof o == "string" ? o : (i = e.spacing) == null ? void 0 : i.call(e, o);
    n(r, {
      [Cl("row")]: a,
      "> *": {
        [vc("row")]: a
      }
    });
  }), r;
}, _8 = ({
  theme: e,
  ownerState: t
}) => {
  if (!t.container)
    return {};
  const r = {};
  return Wa(e.breakpoints, t.columnSpacing, (n, o) => {
    var i;
    const a = typeof o == "string" ? o : (i = e.spacing) == null ? void 0 : i.call(e, o);
    n(r, {
      [Cl("column")]: a,
      "> *": {
        [vc("column")]: a
      }
    });
  }), r;
}, x8 = ({
  theme: e,
  ownerState: t
}) => {
  if (!t.container)
    return {};
  const r = {};
  return Wa(e.breakpoints, t.direction, (n, o) => {
    n(r, {
      flexDirection: o
    });
  }), r;
}, P8 = ({
  ownerState: e
}) => ({
  minWidth: 0,
  boxSizing: "border-box",
  ...e.container && {
    display: "flex",
    flexWrap: "wrap",
    ...e.wrap && e.wrap !== "wrap" && {
      flexWrap: e.wrap
    },
    gap: `var(${Cl("row")}) var(${Cl("column")})`
  }
}), k8 = (e) => {
  const t = [];
  return Object.entries(e).forEach(([r, n]) => {
    n !== !1 && n !== void 0 && t.push(`grid-${r}-${String(n)}`);
  }), t;
}, O8 = (e, t = "xs") => {
  function r(n) {
    return n === void 0 ? !1 : typeof n == "string" && !Number.isNaN(Number(n)) || typeof n == "number" && n > 0;
  }
  if (r(e))
    return [`spacing-${t}-${String(e)}`];
  if (typeof e == "object" && !Array.isArray(e)) {
    const n = [];
    return Object.entries(e).forEach(([o, a]) => {
      r(a) && n.push(`spacing-${o}-${String(a)}`);
    }), n;
  }
  return [];
}, A8 = (e) => e === void 0 ? [] : typeof e == "object" ? Object.entries(e).map(([t, r]) => `direction-${t}-${r}`) : [`direction-xs-${String(e)}`];
function I8(e, t) {
  e.item !== void 0 && delete e.item, e.zeroMinWidth !== void 0 && delete e.zeroMinWidth, t.keys.forEach((r) => {
    e[r] !== void 0 && delete e[r];
  });
}
const R8 = yc(), T8 = n8("div", {
  name: "MuiGrid",
  slot: "Root",
  overridesResolver: (e, t) => t.root
});
function M8(e) {
  return a8({
    props: e,
    name: "MuiGrid",
    defaultTheme: R8
  });
}
function N8(e = {}) {
  const {
    // This will allow adding custom styled fn (for example for custom sx style function)
    createStyledComponent: t = T8,
    useThemeProps: r = M8,
    useTheme: n = ps,
    componentName: o = "MuiGrid"
  } = e, a = (c, u) => {
    const {
      container: f,
      direction: d,
      spacing: p,
      wrap: h,
      size: $
    } = c, b = {
      root: ["root", f && "container", h !== "wrap" && `wrap-xs-${String(h)}`, ...A8(d), ...k8($), ...f ? O8(p, u.breakpoints.keys[0]) : []]
    };
    return ze(b, (g) => Be(o, g), {});
  };
  function i(c, u, f = () => !0) {
    const d = {};
    return c === null || (Array.isArray(c) ? c.forEach((p, h) => {
      p !== null && f(p) && u.keys[h] && (d[u.keys[h]] = p);
    }) : typeof c == "object" ? Object.keys(c).forEach((p) => {
      const h = c[p];
      h != null && f(h) && (d[p] = h);
    }) : d[u.keys[0]] = c), d;
  }
  const s = t(C8, _8, E8, S8, x8, P8, w8), l = /* @__PURE__ */ M.forwardRef(function(u, f) {
    const d = n(), p = r(u), h = fc(p);
    I8(h, d.breakpoints);
    const {
      className: $,
      children: b,
      columns: g = 12,
      container: y = !1,
      component: S = "div",
      direction: m = "row",
      wrap: w = "wrap",
      size: v = {},
      offset: E = {},
      spacing: I = 0,
      rowSpacing: R = I,
      columnSpacing: C = I,
      unstable_level: T = 0,
      ...F
    } = h, D = i(v, d.breakpoints, (j) => j !== !1), z = i(E, d.breakpoints), L = u.columns ?? (T ? void 0 : g), X = u.spacing ?? (T ? void 0 : I), V = u.rowSpacing ?? u.spacing ?? (T ? void 0 : R), ie = u.columnSpacing ?? u.spacing ?? (T ? void 0 : C), Y = {
      ...h,
      level: T,
      columns: L,
      container: y,
      direction: m,
      wrap: w,
      spacing: X,
      rowSpacing: V,
      columnSpacing: ie,
      size: D,
      offset: z
    }, H = a(Y, d);
    return /* @__PURE__ */ P(s, {
      ref: f,
      as: S,
      ownerState: Y,
      className: Ee(H.root, $),
      ...F,
      children: M.Children.map(b, (j) => {
        var Q;
        return /* @__PURE__ */ M.isValidElement(j) && Ci(j, ["Grid"]) && y && j.props.container ? /* @__PURE__ */ M.cloneElement(j, {
          unstable_level: ((Q = j.props) == null ? void 0 : Q.unstable_level) ?? T + 1
        }) : j;
      })
    });
  });
  return l.muiName = "Grid", l;
}
const Wi = {
  black: "#000",
  white: "#fff"
}, F8 = {
  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"
}, qo = {
  50: "#f3e5f5",
  100: "#e1bee7",
  200: "#ce93d8",
  300: "#ba68c8",
  400: "#ab47bc",
  500: "#9c27b0",
  600: "#8e24aa",
  700: "#7b1fa2",
  800: "#6a1b9a",
  900: "#4a148c",
  A100: "#ea80fc",
  A200: "#e040fb",
  A400: "#d500f9",
  A700: "#aa00ff"
}, Wo = {
  50: "#ffebee",
  100: "#ffcdd2",
  200: "#ef9a9a",
  300: "#e57373",
  400: "#ef5350",
  500: "#f44336",
  600: "#e53935",
  700: "#d32f2f",
  800: "#c62828",
  900: "#b71c1c",
  A100: "#ff8a80",
  A200: "#ff5252",
  A400: "#ff1744",
  A700: "#d50000"
}, ai = {
  50: "#fff3e0",
  100: "#ffe0b2",
  200: "#ffcc80",
  300: "#ffb74d",
  400: "#ffa726",
  500: "#ff9800",
  600: "#fb8c00",
  700: "#f57c00",
  800: "#ef6c00",
  900: "#e65100",
  A100: "#ffd180",
  A200: "#ffab40",
  A400: "#ff9100",
  A700: "#ff6d00"
}, Ko = {
  50: "#e3f2fd",
  100: "#bbdefb",
  200: "#90caf9",
  300: "#64b5f6",
  400: "#42a5f5",
  500: "#2196f3",
  600: "#1e88e5",
  700: "#1976d2",
  800: "#1565c0",
  900: "#0d47a1",
  A100: "#82b1ff",
  A200: "#448aff",
  A400: "#2979ff",
  A700: "#2962ff"
}, Go = {
  50: "#e1f5fe",
  100: "#b3e5fc",
  200: "#81d4fa",
  300: "#4fc3f7",
  400: "#29b6f6",
  500: "#03a9f4",
  600: "#039be5",
  700: "#0288d1",
  800: "#0277bd",
  900: "#01579b",
  A100: "#80d8ff",
  A200: "#40c4ff",
  A400: "#00b0ff",
  A700: "#0091ea"
}, Ho = {
  50: "#e8f5e9",
  100: "#c8e6c9",
  200: "#a5d6a7",
  300: "#81c784",
  400: "#66bb6a",
  500: "#4caf50",
  600: "#43a047",
  700: "#388e3c",
  800: "#2e7d32",
  900: "#1b5e20",
  A100: "#b9f6ca",
  A200: "#69f0ae",
  A400: "#00e676",
  A700: "#00c853"
};
function uv() {
  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.
    // Consistency between these values is important.
    background: {
      paper: Wi.white,
      default: Wi.white
    },
    // The colors used to style the action elements.
    action: {
      // The color of an active action like an icon button.
      active: "rgba(0, 0, 0, 0.54)",
      // The color of an hovered action.
      hover: "rgba(0, 0, 0, 0.04)",
      hoverOpacity: 0.04,
      // The color of a selected action.
      selected: "rgba(0, 0, 0, 0.08)",
      selectedOpacity: 0.08,
      // The color of a disabled action.
      disabled: "rgba(0, 0, 0, 0.26)",
      // The background color of a disabled action.
      disabledBackground: "rgba(0, 0, 0, 0.12)",
      disabledOpacity: 0.38,
      focus: "rgba(0, 0, 0, 0.12)",
      focusOpacity: 0.12,
      activatedOpacity: 0.12
    }
  };
}
const j8 = uv();
function dv() {
  return {
    text: {
      primary: Wi.white,
      secondary: "rgba(255, 255, 255, 0.7)",
      disabled: "rgba(255, 255, 255, 0.5)",
      icon: "rgba(255, 255, 255, 0.5)"
    },
    divider: "rgba(255, 255, 255, 0.12)",
    background: {
      paper: "#121212",
      default: "#121212"
    },
    action: {
      active: Wi.white,
      hover: "rgba(255, 255, 255, 0.08)",
      hoverOpacity: 0.08,
      selected: "rgba(255, 255, 255, 0.16)",
      selectedOpacity: 0.16,
      disabled: "rgba(255, 255, 255, 0.3)",
      disabledBackground: "rgba(255, 255, 255, 0.12)",
      disabledOpacity: 0.38,
      focus: "rgba(255, 255, 255, 0.12)",
      focusOpacity: 0.12,
      activatedOpacity: 0.24
    }
  };
}
const Gm = dv();
function Hm(e, t, r, n) {
  const o = n.light || n, a = n.dark || n * 1.5;
  e[t] || (e.hasOwnProperty(r) ? e[t] = e[r] : t === "light" ? e.light = wa(e.main, o) : t === "dark" && (e.dark = Sa(e.main, a)));
}
function D8(e = "light") {
  return e === "dark" ? {
    main: Ko[200],
    light: Ko[50],
    dark: Ko[400]
  } : {
    main: Ko[700],
    light: Ko[400],
    dark: Ko[800]
  };
}
function L8(e = "light") {
  return e === "dark" ? {
    main: qo[200],
    light: qo[50],
    dark: qo[400]
  } : {
    main: qo[500],
    light: qo[300],
    dark: qo[700]
  };
}
function B8(e = "light") {
  return e === "dark" ? {
    main: Wo[500],
    light: Wo[300],
    dark: Wo[700]
  } : {
    main: Wo[700],
    light: Wo[400],
    dark: Wo[800]
  };
}
function z8(e = "light") {
  return e === "dark" ? {
    main: Go[400],
    light: Go[300],
    dark: Go[700]
  } : {
    main: Go[700],
    light: Go[500],
    dark: Go[900]
  };
}
function U8(e = "light") {
  return e === "dark" ? {
    main: Ho[400],
    light: Ho[300],
    dark: Ho[700]
  } : {
    main: Ho[800],
    light: Ho[500],
    dark: Ho[900]
  };
}
function V8(e = "light") {
  return e === "dark" ? {
    main: ai[400],
    light: ai[300],
    dark: ai[700]
  } : {
    main: "#ed6c02",
    // closest to orange[800] that pass 3:1.
    light: ai[500],
    dark: ai[900]
  };
}
function Pf(e) {
  const {
    mode: t = "light",
    contrastThreshold: r = 3,
    tonalOffset: n = 0.2,
    ...o
  } = e, a = e.primary || D8(t), i = e.secondary || L8(t), s = e.error || B8(t), l = e.info || z8(t), c = e.success || U8(t), u = e.warning || V8(t);
  function f($) {
    return l8($, Gm.text.primary) >= r ? Gm.text.primary : j8.text.primary;
  }
  const d = ({
    color: $,
    name: b,
    mainShade: g = 500,
    lightShade: y = 300,
    darkShade: S = 700
  }) => {
    if ($ = {
      ...$
    }, !$.main && $[g] && ($.main = $[g]), !$.hasOwnProperty("main"))
      throw new Error(Dn(11, b ? ` (${b})` : "", g));
    if (typeof $.main != "string")
      throw new Error(Dn(12, b ? ` (${b})` : "", JSON.stringify($.main)));
    return Hm($, "light", y, n), Hm($, "dark", S, n), $.contrastText || ($.contrastText = f($.main)), $;
  };
  let p;
  return t === "light" ? p = uv() : t === "dark" && (p = dv()), lr({
    // A collection of common colors.
    common: {
      ...Wi
    },
    // prevent mutable object.
    // The palette mode, can be light or dark.
    mode: t,
    // The colors used to represent primary interface elements for a user.
    primary: d({
      color: a,
      name: "primary"
    }),
    // The colors used to represent secondary interface elements for a user.
    secondary: d({
      color: i,
      name: "secondary",
      mainShade: "A400",
      lightShade: "A200",
      darkShade: "A700"
    }),
    // The colors used to represent interface elements that the user should be made aware of.
    error: d({
      color: s,
      name: "error"
    }),
    // The colors used to represent potentially dangerous actions or important messages.
    warning: d({
      color: u,
      name: "warning"
    }),
    // The colors used to present information to the user that is neutral and not necessarily important.
    info: d({
      color: l,
      name: "info"
    }),
    // The colors used to indicate the successful completion of an action that user triggered.
    success: d({
      color: c,
      name: "success"
    }),
    // The grey colors.
    grey: F8,
    // Used by `getContrastText()` to maximize the contrast between
    // the background and the text.
    contrastThreshold: r,
    // Takes a background color and returns the text color that maximizes the contrast.
    getContrastText: f,
    // Generate a rich color object.
    augmentColor: d,
    // Used by the functions below to shift a color's luminance by approximately
    // two indexes within its tonal palette.
    // E.g., shift from Red 500 to Red 300 or Red 700.
    tonalOffset: n,
    // The light and dark mode object.
    ...p
  }, o);
}
function q8(e) {
  const t = {};
  return Object.entries(e).forEach((n) => {
    const [o, a] = n;
    typeof a == "object" && (t[o] = `${a.fontStyle ? `${a.fontStyle} ` : ""}${a.fontVariant ? `${a.fontVariant} ` : ""}${a.fontWeight ? `${a.fontWeight} ` : ""}${a.fontStretch ? `${a.fontStretch} ` : ""}${a.fontSize || ""}${a.lineHeight ? `/${a.lineHeight} ` : ""}${a.fontFamily || ""}`);
  }), t;
}
function W8(e, t) {
  return {
    toolbar: {
      minHeight: 56,
      [e.up("xs")]: {
        "@media (orientation: landscape)": {
          minHeight: 48
        }
      },
      [e.up("sm")]: {
        minHeight: 64
      }
    },
    ...t
  };
}
function K8(e) {
  return Math.round(e * 1e5) / 1e5;
}
const Jm = {
  textTransform: "uppercase"
}, Ym = '"Roboto", "Helvetica", "Arial", sans-serif';
function G8(e, t) {
  const {
    fontFamily: r = Ym,
    // The default font size of the Material Specification.
    fontSize: n = 14,
    // px
    fontWeightLight: o = 300,
    fontWeightRegular: a = 400,
    fontWeightMedium: i = 500,
    fontWeightBold: s = 700,
    // Tell MUI what's the font-size on the html element.
    // 16px is the default font-size used by browsers.
    htmlFontSize: l = 16,
    // Apply the CSS properties to all the variants.
    allVariants: c,
    pxToRem: u,
    ...f
  } = typeof t == "function" ? t(e) : t, d = n / 14, p = u || ((b) => `${b / l * d}rem`), h = (b, g, y, S, m) => ({
    fontFamily: r,
    fontWeight: b,
    fontSize: p(g),
    // Unitless following https://meyerweb.com/eric/thoughts/2006/02/08/unitless-line-heights/
    lineHeight: y,
    // The letter spacing was designed for the Roboto font-family. Using the same letter-spacing
    // across font-families can cause issues with the kerning.
    ...r === Ym ? {
      letterSpacing: `${K8(S / g)}em`
    } : {},
    ...m,
    ...c
  }), $ = {
    h1: h(o, 96, 1.167, -1.5),
    h2: h(o, 60, 1.2, -0.5),
    h3: h(a, 48, 1.167, 0),
    h4: h(a, 34, 1.235, 0.25),
    h5: h(a, 24, 1.334, 0),
    h6: h(i, 20, 1.6, 0.15),
    subtitle1: h(a, 16, 1.75, 0.15),
    subtitle2: h(i, 14, 1.57, 0.1),
    body1: h(a, 16, 1.5, 0.15),
    body2: h(a, 14, 1.43, 0.15),
    button: h(i, 14, 1.75, 0.4, Jm),
    caption: h(a, 12, 1.66, 0.4),
    overline: h(a, 12, 2.66, 1, Jm),
    // TODO v6: Remove handling of 'inherit' variant from the theme as it is already handled in Material UI's Typography component. Also, remember to remove the associated types.
    inherit: {
      fontFamily: "inherit",
      fontWeight: "inherit",
      fontSize: "inherit",
      lineHeight: "inherit",
      letterSpacing: "inherit"
    }
  };
  return lr({
    htmlFontSize: l,
    pxToRem: p,
    fontFamily: r,
    fontSize: n,
    fontWeightLight: o,
    fontWeightRegular: a,
    fontWeightMedium: i,
    fontWeightBold: s,
    ...$
  }, f, {
    clone: !1
    // No need to clone deep
  });
}
const H8 = 0.2, J8 = 0.14, Y8 = 0.12;
function At(...e) {
  return [`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${H8})`, `${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${J8})`, `${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${Y8})`].join(",");
}
const X8 = ["none", At(0, 2, 1, -1, 0, 1, 1, 0, 0, 1, 3, 0), At(0, 3, 1, -2, 0, 2, 2, 0, 0, 1, 5, 0), At(0, 3, 3, -2, 0, 3, 4, 0, 0, 1, 8, 0), At(0, 2, 4, -1, 0, 4, 5, 0, 0, 1, 10, 0), At(0, 3, 5, -1, 0, 5, 8, 0, 0, 1, 14, 0), At(0, 3, 5, -1, 0, 6, 10, 0, 0, 1, 18, 0), At(0, 4, 5, -2, 0, 7, 10, 1, 0, 2, 16, 1), At(0, 5, 5, -3, 0, 8, 10, 1, 0, 3, 14, 2), At(0, 5, 6, -3, 0, 9, 12, 1, 0, 3, 16, 2), At(0, 6, 6, -3, 0, 10, 14, 1, 0, 4, 18, 3), At(0, 6, 7, -4, 0, 11, 15, 1, 0, 4, 20, 3), At(0, 7, 8, -4, 0, 12, 17, 2, 0, 5, 22, 4), At(0, 7, 8, -4, 0, 13, 19, 2, 0, 5, 24, 4), At(0, 7, 9, -4, 0, 14, 21, 2, 0, 5, 26, 4), At(0, 8, 9, -5, 0, 15, 22, 2, 0, 6, 28, 5), At(0, 8, 10, -5, 0, 16, 24, 2, 0, 6, 30, 5), At(0, 8, 11, -5, 0, 17, 26, 2, 0, 6, 32, 5), At(0, 9, 11, -5, 0, 18, 28, 2, 0, 7, 34, 6), At(0, 9, 12, -6, 0, 19, 29, 2, 0, 7, 36, 6), At(0, 10, 13, -6, 0, 20, 31, 3, 0, 8, 38, 7), At(0, 10, 13, -6, 0, 21, 33, 3, 0, 8, 40, 7), At(0, 10, 14, -6, 0, 22, 35, 3, 0, 8, 42, 7), At(0, 11, 14, -7, 0, 23, 36, 3, 0, 9, 44, 8), At(0, 11, 15, -7, 0, 24, 38, 3, 0, 9, 46, 8)], Z8 = {
  // This is the most common easing curve.
  easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)",
  // Objects enter the screen at full velocity from off-screen and
  // slowly decelerate to a resting point.
  easeOut: "cubic-bezier(0.0, 0, 0.2, 1)",
  // Objects leave the screen at full velocity. They do not decelerate when off-screen.
  easeIn: "cubic-bezier(0.4, 0, 1, 1)",
  // The sharp curve is used by objects that may return to the screen at any time.
  sharp: "cubic-bezier(0.4, 0, 0.6, 1)"
}, fv = {
  shortest: 150,
  shorter: 200,
  short: 250,
  // most basic recommended timing
  standard: 300,
  // this is to be used in complex animations
  complex: 375,
  // recommended when something is entering screen
  enteringScreen: 225,
  // recommended when something is leaving screen
  leavingScreen: 195
};
function Xm(e) {
  return `${Math.round(e)}ms`;
}
function Q8(e) {
  if (!e)
    return 0;
  const t = e / 36;
  return Math.min(Math.round((4 + 15 * t ** 0.25 + t / 5) * 10), 3e3);
}
function eB(e) {
  const t = {
    ...Z8,
    ...e.easing
  }, r = {
    ...fv,
    ...e.duration
  };
  return {
    getAutoHeightDuration: Q8,
    create: (o = ["all"], a = {}) => {
      const {
        duration: i = r.standard,
        easing: s = t.easeInOut,
        delay: l = 0,
        ...c
      } = a;
      return (Array.isArray(o) ? o : [o]).map((u) => `${u} ${typeof i == "string" ? i : Xm(i)} ${s} ${typeof l == "string" ? l : Xm(l)}`).join(",");
    },
    ...e,
    easing: t,
    duration: r
  };
}
const tB = {
  mobileStepper: 1e3,
  fab: 1050,
  speedDial: 1050,
  appBar: 1100,
  drawer: 1200,
  modal: 1300,
  snackbar: 1400,
  tooltip: 1500
};
function rB(e) {
  return dn(e) || typeof e > "u" || typeof e == "string" || typeof e == "boolean" || typeof e == "number" || Array.isArray(e);
}
function pv(e = {}) {
  const t = {
    ...e
  };
  function r(n) {
    const o = Object.entries(n);
    for (let a = 0; a < o.length; a++) {
      const [i, s] = o[a];
      !rB(s) || i.startsWith("unstable_") ? delete n[i] : dn(s) && (n[i] = {
        ...s
      }, r(n[i]));
    }
  }
  return r(t), `import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';

const theme = ${JSON.stringify(t, null, 2)};

theme.breakpoints = createBreakpoints(theme.breakpoints || {});
theme.transitions = createTransitions(theme.transitions || {});

export default theme;`;
}
function Vu(e = {}, ...t) {
  const {
    breakpoints: r,
    mixins: n = {},
    spacing: o,
    palette: a = {},
    transitions: i = {},
    typography: s = {},
    shape: l,
    ...c
  } = e;
  if (e.vars)
    throw new Error(Dn(20));
  const u = Pf(a), f = yc(e);
  let d = lr(f, {
    mixins: W8(f.breakpoints, n),
    palette: u,
    // Don't use [...shadows] until you've verified its transpiled code is not invoking the iterator protocol.
    shadows: X8.slice(),
    typography: G8(u, s),
    transitions: eB(i),
    zIndex: {
      ...tB
    }
  });
  return d = lr(d, c), d = t.reduce((p, h) => lr(p, h), d), d.unstable_sxConfig = {
    ...us,
    ...c == null ? void 0 : c.unstable_sxConfig
  }, d.unstable_sx = function(h) {
    return ko({
      sx: h,
      theme: this
    });
  }, d.toRuntimeSource = pv, d;
}
function qu(e) {
  let t;
  return e < 1 ? t = 5.11916 * e ** 2 : t = 4.5 * Math.log(e + 1) + 2, Math.round(t * 10) / 1e3;
}
const nB = [...Array(25)].map((e, t) => {
  if (t === 0)
    return "none";
  const r = qu(t);
  return `linear-gradient(rgba(255 255 255 / ${r}), rgba(255 255 255 / ${r}))`;
});
function hv(e) {
  return {
    inputPlaceholder: e === "dark" ? 0.5 : 0.42,
    inputUnderline: e === "dark" ? 0.7 : 0.42,
    switchTrackDisabled: e === "dark" ? 0.2 : 0.12,
    switchTrack: e === "dark" ? 0.3 : 0.38
  };
}
function mv(e) {
  return e === "dark" ? nB : [];
}
function oB(e) {
  const {
    palette: t = {
      mode: "light"
    },
    // need to cast to avoid module augmentation test
    opacity: r,
    overlays: n,
    ...o
  } = e, a = Pf(t);
  return {
    palette: a,
    opacity: {
      ...hv(a.mode),
      ...r
    },
    overlays: n || mv(a.mode),
    ...o
  };
}
function aB(e) {
  var t;
  return !!e[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/) || !!e[0].match(/sxConfig$/) || // ends with sxConfig
  e[0] === "palette" && !!((t = e[1]) != null && t.match(/(mode|contrastThreshold|tonalOffset)/));
}
const iB = (e) => [...[...Array(25)].map((t, r) => `--${e ? `${e}-` : ""}overlays-${r}`), `--${e ? `${e}-` : ""}palette-AppBar-darkBg`, `--${e ? `${e}-` : ""}palette-AppBar-darkColor`], sB = (e) => (t, r) => {
  const n = e.rootSelector || ":root", o = e.colorSchemeSelector;
  let a = o;
  if (o === "class" && (a = ".%s"), o === "data" && (a = "[data-%s]"), o != null && o.startsWith("data-") && !o.includes("%s") && (a = `[${o}="%s"]`), e.defaultColorScheme === t) {
    if (t === "dark") {
      const i = {};
      return iB(e.cssVarPrefix).forEach((s) => {
        i[s] = r[s], delete r[s];
      }), a === "media" ? {
        [n]: r,
        "@media (prefers-color-scheme: dark)": {
          [n]: i
        }
      } : a ? {
        [a.replace("%s", t)]: i,
        [`${n}, ${a.replace("%s", t)}`]: r
      } : {
        [n]: {
          ...r,
          ...i
        }
      };
    }
    if (a && a !== "media")
      return `${n}, ${a.replace("%s", String(t))}`;
  } else if (t) {
    if (a === "media")
      return {
        [`@media (prefers-color-scheme: ${String(t)})`]: {
          [n]: r
        }
      };
    if (a)
      return a.replace("%s", String(t));
  }
  return n;
};
function lB(e, t) {
  t.forEach((r) => {
    e[r] || (e[r] = {});
  });
}
function te(e, t, r) {
  !e[t] && r && (e[t] = r);
}
function gi(e) {
  return typeof e != "string" || !e.startsWith("hsl") ? e : cv(e);
}
function On(e, t) {
  `${t}Channel` in e || (e[`${t}Channel`] = mi(gi(e[t])));
}
function cB(e) {
  return typeof e == "number" ? `${e}px` : typeof e == "string" || typeof e == "function" || Array.isArray(e) ? e : "8px";
}
const on = (e) => {
  try {
    return e();
  } catch {
  }
}, uB = (e = "mui") => m8(e);
function cu(e, t, r, n) {
  if (!t)
    return;
  t = t === !0 ? {} : t;
  const o = n === "dark" ? "dark" : "light";
  if (!r) {
    e[n] = oB({
      ...t,
      palette: {
        mode: o,
        ...t == null ? void 0 : t.palette
      }
    });
    return;
  }
  const {
    palette: a,
    ...i
  } = Vu({
    ...r,
    palette: {
      mode: o,
      ...t == null ? void 0 : t.palette
    }
  });
  return e[n] = {
    ...t,
    palette: a,
    opacity: {
      ...hv(o),
      ...t == null ? void 0 : t.opacity
    },
    overlays: (t == null ? void 0 : t.overlays) || mv(o)
  }, i;
}
function dB(e = {}, ...t) {
  const {
    colorSchemes: r = {
      light: !0
    },
    defaultColorScheme: n,
    disableCssColorScheme: o = !1,
    cssVarPrefix: a = "mui",
    shouldSkipGeneratingVar: i = aB,
    colorSchemeSelector: s = r.light && r.dark ? "media" : void 0,
    rootSelector: l = ":root",
    ...c
  } = e, u = Object.keys(r)[0], f = n || (r.light && u !== "light" ? "light" : u), d = uB(a), {
    [f]: p,
    light: h,
    dark: $,
    ...b
  } = r, g = {
    ...b
  };
  let y = p;
  if ((f === "dark" && !("dark" in r) || f === "light" && !("light" in r)) && (y = !0), !y)
    throw new Error(Dn(21, f));
  const S = cu(g, y, c, f);
  h && !g.light && cu(g, h, void 0, "light"), $ && !g.dark && cu(g, $, void 0, "dark");
  let m = {
    defaultColorScheme: f,
    ...S,
    cssVarPrefix: a,
    colorSchemeSelector: s,
    rootSelector: l,
    getCssVar: d,
    colorSchemes: g,
    font: {
      ...q8(S.typography),
      ...S.font
    },
    spacing: cB(c.spacing)
  };
  Object.keys(m.colorSchemes).forEach((R) => {
    const C = m.colorSchemes[R].palette, T = (F) => {
      const D = F.split("-"), z = D[1], L = D[2];
      return d(F, C[z][L]);
    };
    if (C.mode === "light" && (te(C.common, "background", "#fff"), te(C.common, "onBackground", "#000")), C.mode === "dark" && (te(C.common, "background", "#000"), te(C.common, "onBackground", "#fff")), lB(C, ["Alert", "AppBar", "Avatar", "Button", "Chip", "FilledInput", "LinearProgress", "Skeleton", "Slider", "SnackbarContent", "SpeedDialAction", "StepConnector", "StepContent", "Switch", "TableCell", "Tooltip"]), C.mode === "light") {
      te(C.Alert, "errorColor", bt(C.error.light, 0.6)), te(C.Alert, "infoColor", bt(C.info.light, 0.6)), te(C.Alert, "successColor", bt(C.success.light, 0.6)), te(C.Alert, "warningColor", bt(C.warning.light, 0.6)), te(C.Alert, "errorFilledBg", T("palette-error-main")), te(C.Alert, "infoFilledBg", T("palette-info-main")), te(C.Alert, "successFilledBg", T("palette-success-main")), te(C.Alert, "warningFilledBg", T("palette-warning-main")), te(C.Alert, "errorFilledColor", on(() => C.getContrastText(C.error.main))), te(C.Alert, "infoFilledColor", on(() => C.getContrastText(C.info.main))), te(C.Alert, "successFilledColor", on(() => C.getContrastText(C.success.main))), te(C.Alert, "warningFilledColor", on(() => C.getContrastText(C.warning.main))), te(C.Alert, "errorStandardBg", vt(C.error.light, 0.9)), te(C.Alert, "infoStandardBg", vt(C.info.light, 0.9)), te(C.Alert, "successStandardBg", vt(C.success.light, 0.9)), te(C.Alert, "warningStandardBg", vt(C.warning.light, 0.9)), te(C.Alert, "errorIconColor", T("palette-error-main")), te(C.Alert, "infoIconColor", T("palette-info-main")), te(C.Alert, "successIconColor", T("palette-success-main")), te(C.Alert, "warningIconColor", T("palette-warning-main")), te(C.AppBar, "defaultBg", T("palette-grey-100")), te(C.Avatar, "defaultBg", T("palette-grey-400")), te(C.Button, "inheritContainedBg", T("palette-grey-300")), te(C.Button, "inheritContainedHoverBg", T("palette-grey-A100")), te(C.Chip, "defaultBorder", T("palette-grey-400")), te(C.Chip, "defaultAvatarColor", T("palette-grey-700")), te(C.Chip, "defaultIconColor", T("palette-grey-700")), te(C.FilledInput, "bg", "rgba(0, 0, 0, 0.06)"), te(C.FilledInput, "hoverBg", "rgba(0, 0, 0, 0.09)"), te(C.FilledInput, "disabledBg", "rgba(0, 0, 0, 0.12)"), te(C.LinearProgress, "primaryBg", vt(C.primary.main, 0.62)), te(C.LinearProgress, "secondaryBg", vt(C.secondary.main, 0.62)), te(C.LinearProgress, "errorBg", vt(C.error.main, 0.62)), te(C.LinearProgress, "infoBg", vt(C.info.main, 0.62)), te(C.LinearProgress, "successBg", vt(C.success.main, 0.62)), te(C.LinearProgress, "warningBg", vt(C.warning.main, 0.62)), te(C.Skeleton, "bg", `rgba(${T("palette-text-primaryChannel")} / 0.11)`), te(C.Slider, "primaryTrack", vt(C.primary.main, 0.62)), te(C.Slider, "secondaryTrack", vt(C.secondary.main, 0.62)), te(C.Slider, "errorTrack", vt(C.error.main, 0.62)), te(C.Slider, "infoTrack", vt(C.info.main, 0.62)), te(C.Slider, "successTrack", vt(C.success.main, 0.62)), te(C.Slider, "warningTrack", vt(C.warning.main, 0.62));
      const F = Is(C.background.default, 0.8);
      te(C.SnackbarContent, "bg", F), te(C.SnackbarContent, "color", on(() => C.getContrastText(F))), te(C.SpeedDialAction, "fabHoverBg", Is(C.background.paper, 0.15)), te(C.StepConnector, "border", T("palette-grey-400")), te(C.StepContent, "border", T("palette-grey-400")), te(C.Switch, "defaultColor", T("palette-common-white")), te(C.Switch, "defaultDisabledColor", T("palette-grey-100")), te(C.Switch, "primaryDisabledColor", vt(C.primary.main, 0.62)), te(C.Switch, "secondaryDisabledColor", vt(C.secondary.main, 0.62)), te(C.Switch, "errorDisabledColor", vt(C.error.main, 0.62)), te(C.Switch, "infoDisabledColor", vt(C.info.main, 0.62)), te(C.Switch, "successDisabledColor", vt(C.success.main, 0.62)), te(C.Switch, "warningDisabledColor", vt(C.warning.main, 0.62)), te(C.TableCell, "border", vt(As(C.divider, 1), 0.88)), te(C.Tooltip, "bg", As(C.grey[700], 0.92));
    }
    if (C.mode === "dark") {
      te(C.Alert, "errorColor", vt(C.error.light, 0.6)), te(C.Alert, "infoColor", vt(C.info.light, 0.6)), te(C.Alert, "successColor", vt(C.success.light, 0.6)), te(C.Alert, "warningColor", vt(C.warning.light, 0.6)), te(C.Alert, "errorFilledBg", T("palette-error-dark")), te(C.Alert, "infoFilledBg", T("palette-info-dark")), te(C.Alert, "successFilledBg", T("palette-success-dark")), te(C.Alert, "warningFilledBg", T("palette-warning-dark")), te(C.Alert, "errorFilledColor", on(() => C.getContrastText(C.error.dark))), te(C.Alert, "infoFilledColor", on(() => C.getContrastText(C.info.dark))), te(C.Alert, "successFilledColor", on(() => C.getContrastText(C.success.dark))), te(C.Alert, "warningFilledColor", on(() => C.getContrastText(C.warning.dark))), te(C.Alert, "errorStandardBg", bt(C.error.light, 0.9)), te(C.Alert, "infoStandardBg", bt(C.info.light, 0.9)), te(C.Alert, "successStandardBg", bt(C.success.light, 0.9)), te(C.Alert, "warningStandardBg", bt(C.warning.light, 0.9)), te(C.Alert, "errorIconColor", T("palette-error-main")), te(C.Alert, "infoIconColor", T("palette-info-main")), te(C.Alert, "successIconColor", T("palette-success-main")), te(C.Alert, "warningIconColor", T("palette-warning-main")), te(C.AppBar, "defaultBg", T("palette-grey-900")), te(C.AppBar, "darkBg", T("palette-background-paper")), te(C.AppBar, "darkColor", T("palette-text-primary")), te(C.Avatar, "defaultBg", T("palette-grey-600")), te(C.Button, "inheritContainedBg", T("palette-grey-800")), te(C.Button, "inheritContainedHoverBg", T("palette-grey-700")), te(C.Chip, "defaultBorder", T("palette-grey-700")), te(C.Chip, "defaultAvatarColor", T("palette-grey-300")), te(C.Chip, "defaultIconColor", T("palette-grey-300")), te(C.FilledInput, "bg", "rgba(255, 255, 255, 0.09)"), te(C.FilledInput, "hoverBg", "rgba(255, 255, 255, 0.13)"), te(C.FilledInput, "disabledBg", "rgba(255, 255, 255, 0.12)"), te(C.LinearProgress, "primaryBg", bt(C.primary.main, 0.5)), te(C.LinearProgress, "secondaryBg", bt(C.secondary.main, 0.5)), te(C.LinearProgress, "errorBg", bt(C.error.main, 0.5)), te(C.LinearProgress, "infoBg", bt(C.info.main, 0.5)), te(C.LinearProgress, "successBg", bt(C.success.main, 0.5)), te(C.LinearProgress, "warningBg", bt(C.warning.main, 0.5)), te(C.Skeleton, "bg", `rgba(${T("palette-text-primaryChannel")} / 0.13)`), te(C.Slider, "primaryTrack", bt(C.primary.main, 0.5)), te(C.Slider, "secondaryTrack", bt(C.secondary.main, 0.5)), te(C.Slider, "errorTrack", bt(C.error.main, 0.5)), te(C.Slider, "infoTrack", bt(C.info.main, 0.5)), te(C.Slider, "successTrack", bt(C.success.main, 0.5)), te(C.Slider, "warningTrack", bt(C.warning.main, 0.5));
      const F = Is(C.background.default, 0.98);
      te(C.SnackbarContent, "bg", F), te(C.SnackbarContent, "color", on(() => C.getContrastText(F))), te(C.SpeedDialAction, "fabHoverBg", Is(C.background.paper, 0.15)), te(C.StepConnector, "border", T("palette-grey-600")), te(C.StepContent, "border", T("palette-grey-600")), te(C.Switch, "defaultColor", T("palette-grey-300")), te(C.Switch, "defaultDisabledColor", T("palette-grey-600")), te(C.Switch, "primaryDisabledColor", bt(C.primary.main, 0.55)), te(C.Switch, "secondaryDisabledColor", bt(C.secondary.main, 0.55)), te(C.Switch, "errorDisabledColor", bt(C.error.main, 0.55)), te(C.Switch, "infoDisabledColor", bt(C.info.main, 0.55)), te(C.Switch, "successDisabledColor", bt(C.success.main, 0.55)), te(C.Switch, "warningDisabledColor", bt(C.warning.main, 0.55)), te(C.TableCell, "border", bt(As(C.divider, 1), 0.68)), te(C.Tooltip, "bg", As(C.grey[700], 0.92));
    }
    On(C.background, "default"), On(C.background, "paper"), On(C.common, "background"), On(C.common, "onBackground"), On(C, "divider"), Object.keys(C).forEach((F) => {
      const D = C[F];
      F !== "tonalOffset" && D && typeof D == "object" && (D.main && te(C[F], "mainChannel", mi(gi(D.main))), D.light && te(C[F], "lightChannel", mi(gi(D.light))), D.dark && te(C[F], "darkChannel", mi(gi(D.dark))), D.contrastText && te(C[F], "contrastTextChannel", mi(gi(D.contrastText))), F === "text" && (On(C[F], "primary"), On(C[F], "secondary")), F === "action" && (D.active && On(C[F], "active"), D.selected && On(C[F], "selected")));
    });
  }), m = t.reduce((R, C) => lr(R, C), m);
  const w = {
    prefix: a,
    disableCssColorScheme: o,
    shouldSkipGeneratingVar: i,
    getSelector: sB(m)
  }, {
    vars: v,
    generateThemeVars: E,
    generateStyleSheets: I
  } = b8(m, w);
  return m.vars = v, Object.entries(m.colorSchemes[m.defaultColorScheme]).forEach(([R, C]) => {
    m[R] = C;
  }), m.generateThemeVars = E, m.generateStyleSheets = I, m.generateSpacing = function() {
    return av(c.spacing, gf(this));
  }, m.getColorSchemeSelector = v8(s), m.spacing = m.generateSpacing(), m.shouldSkipGeneratingVar = i, m.unstable_sxConfig = {
    ...us,
    ...c == null ? void 0 : c.unstable_sxConfig
  }, m.unstable_sx = function(C) {
    return ko({
      sx: C,
      theme: this
    });
  }, m.toRuntimeSource = pv, m;
}
function Zm(e, t, r) {
  e.colorSchemes && r && (e.colorSchemes[t] = {
    ...r !== !0 && r,
    palette: Pf({
      ...r === !0 ? {} : r.palette,
      mode: t
    })
    // cast type to skip module augmentation test
  });
}
function gv(e = {}, ...t) {
  const {
    palette: r,
    cssVariables: n = !1,
    colorSchemes: o = r ? void 0 : {
      light: !0
    },
    defaultColorScheme: a = r == null ? void 0 : r.mode,
    ...i
  } = e, s = a || "light", l = o == null ? void 0 : o[s], c = {
    ...o,
    ...r ? {
      [s]: {
        ...typeof l != "boolean" && l,
        palette: r
      }
    } : void 0
  };
  if (n === !1) {
    if (!("colorSchemes" in e))
      return Vu(e, ...t);
    let u = r;
    "palette" in e || c[s] && (c[s] !== !0 ? u = c[s].palette : s === "dark" && (u = {
      mode: "dark"
    }));
    const f = Vu({
      ...e,
      palette: u
    }, ...t);
    return f.defaultColorScheme = s, f.colorSchemes = c, f.palette.mode === "light" && (f.colorSchemes.light = {
      ...c.light !== !0 && c.light,
      palette: f.palette
    }, Zm(f, "dark", c.dark)), f.palette.mode === "dark" && (f.colorSchemes.dark = {
      ...c.dark !== !0 && c.dark,
      palette: f.palette
    }, Zm(f, "light", c.light)), f;
  }
  return !r && !("light" in c) && s === "light" && (c.light = !0), dB({
    ...i,
    colorSchemes: c,
    defaultColorScheme: s,
    ...typeof n != "boolean" && n
  }, ...t);
}
const kf = gv(), $c = "$$material";
function Ka() {
  const e = ps(kf);
  return e[$c] || e;
}
function fB(e) {
  return /* @__PURE__ */ P(HL, {
    ...e,
    defaultTheme: kf,
    themeId: $c
  });
}
function Sc(e) {
  return e !== "ownerState" && e !== "theme" && e !== "sx" && e !== "as";
}
const cr = (e) => Sc(e) && e !== "classes", de = lv({
  themeId: $c,
  defaultTheme: kf,
  rootShouldForwardProp: cr
});
function pB(e) {
  return function(r) {
    return (
      // Pigment CSS `globalCss` support callback with theme inside an object but `GlobalStyles` support theme as a callback value.
      /* @__PURE__ */ P(fB, {
        styles: typeof e == "function" ? (n) => e({
          theme: n,
          ...r
        }) : e
      })
    );
  };
}
function hB() {
  return fc;
}
const je = h8;
function Ke(e) {
  return p8(e);
}
function mB(e) {
  return Be("MuiSvgIcon", e);
}
De("MuiSvgIcon", ["root", "colorPrimary", "colorSecondary", "colorAction", "colorError", "colorDisabled", "fontSizeInherit", "fontSizeSmall", "fontSizeMedium", "fontSizeLarge"]);
const gB = (e) => {
  const {
    color: t,
    fontSize: r,
    classes: n
  } = e, o = {
    root: ["root", t !== "inherit" && `color${$e(t)}`, `fontSize${$e(r)}`]
  };
  return ze(o, mB, n);
}, yB = de("svg", {
  name: "MuiSvgIcon",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.color !== "inherit" && t[`color${$e(r.color)}`], t[`fontSize${$e(r.fontSize)}`]];
  }
})(je(({
  theme: e
}) => {
  var t, r, n, o, a, i, s, l, c, u, f, d, p, h;
  return {
    userSelect: "none",
    width: "1em",
    height: "1em",
    display: "inline-block",
    flexShrink: 0,
    transition: (o = (t = e.transitions) == null ? void 0 : t.create) == null ? void 0 : o.call(t, "fill", {
      duration: (n = (r = (e.vars ?? e).transitions) == null ? void 0 : r.duration) == null ? void 0 : n.shorter
    }),
    variants: [
      {
        props: ($) => !$.hasSvgAsChild,
        style: {
          // the <svg> will define the property that has `currentColor`
          // for example heroicons uses fill="none" and stroke="currentColor"
          fill: "currentColor"
        }
      },
      {
        props: {
          fontSize: "inherit"
        },
        style: {
          fontSize: "inherit"
        }
      },
      {
        props: {
          fontSize: "small"
        },
        style: {
          fontSize: ((i = (a = e.typography) == null ? void 0 : a.pxToRem) == null ? void 0 : i.call(a, 20)) || "1.25rem"
        }
      },
      {
        props: {
          fontSize: "medium"
        },
        style: {
          fontSize: ((l = (s = e.typography) == null ? void 0 : s.pxToRem) == null ? void 0 : l.call(s, 24)) || "1.5rem"
        }
      },
      {
        props: {
          fontSize: "large"
        },
        style: {
          fontSize: ((u = (c = e.typography) == null ? void 0 : c.pxToRem) == null ? void 0 : u.call(c, 35)) || "2.1875rem"
        }
      },
      // TODO v5 deprecate color prop, v6 remove for sx
      ...Object.entries((e.vars ?? e).palette).filter(([, $]) => $ && $.main).map(([$]) => {
        var b, g;
        return {
          props: {
            color: $
          },
          style: {
            color: (g = (b = (e.vars ?? e).palette) == null ? void 0 : b[$]) == null ? void 0 : g.main
          }
        };
      }),
      {
        props: {
          color: "action"
        },
        style: {
          color: (d = (f = (e.vars ?? e).palette) == null ? void 0 : f.action) == null ? void 0 : d.active
        }
      },
      {
        props: {
          color: "disabled"
        },
        style: {
          color: (h = (p = (e.vars ?? e).palette) == null ? void 0 : p.action) == null ? void 0 : h.disabled
        }
      },
      {
        props: {
          color: "inherit"
        },
        style: {
          color: void 0
        }
      }
    ]
  };
})), Wu = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiSvgIcon"
  }), {
    children: o,
    className: a,
    color: i = "inherit",
    component: s = "svg",
    fontSize: l = "medium",
    htmlColor: c,
    inheritViewBox: u = !1,
    titleAccess: f,
    viewBox: d = "0 0 24 24",
    ...p
  } = n, h = /* @__PURE__ */ M.isValidElement(o) && o.type === "svg", $ = {
    ...n,
    color: i,
    component: s,
    fontSize: l,
    instanceFontSize: t.fontSize,
    inheritViewBox: u,
    viewBox: d,
    hasSvgAsChild: h
  }, b = {};
  u || (b.viewBox = d);
  const g = gB($);
  return /* @__PURE__ */ ue(yB, {
    as: s,
    className: Ee(g.root, a),
    focusable: "false",
    color: c,
    "aria-hidden": f ? void 0 : !0,
    role: f ? "img" : void 0,
    ref: r,
    ...b,
    ...p,
    ...h && o.props,
    ownerState: $,
    children: [h ? o.props.children : o, f ? /* @__PURE__ */ P("title", {
      children: f
    }) : null]
  });
});
Wu.muiName = "SvgIcon";
function gr(e, t) {
  function r(n, o) {
    return /* @__PURE__ */ P(Wu, {
      "data-testid": `${t}Icon`,
      ref: o,
      ...n,
      children: e
    });
  }
  return r.muiName = Wu.muiName, /* @__PURE__ */ M.memo(/* @__PURE__ */ M.forwardRef(r));
}
const bB = gr(/* @__PURE__ */ P("path", {
  d: "M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6z"
}), "Add");
function vB(e) {
  return typeof e.main == "string";
}
function $B(e, t = []) {
  if (!vB(e))
    return !1;
  for (const r of t)
    if (!e.hasOwnProperty(r) || typeof e[r] != "string")
      return !1;
  return !0;
}
function zt(e = []) {
  return ([, t]) => t && $B(t, e);
}
class El {
  constructor() {
    Za(this, "mountEffect", () => {
      this.shouldMount && !this.didMount && this.ref.current !== null && (this.didMount = !0, this.mounted.resolve());
    });
    this.ref = {
      current: null
    }, this.mounted = null, this.didMount = !1, this.shouldMount = !1, this.setShouldMount = null;
  }
  /** React ref to the ripple instance */
  /** If the ripple component should be mounted */
  /** Promise that resolves when the ripple component is mounted */
  /** If the ripple component has been mounted */
  /** React state hook setter */
  static create() {
    return new El();
  }
  static use() {
    const t = Nb(El.create).current, [r, n] = M.useState(!1);
    return t.shouldMount = r, t.setShouldMount = n, M.useEffect(t.mountEffect, [r]), t;
  }
  mount() {
    return this.mounted || (this.mounted = wB(), this.shouldMount = !0, this.setShouldMount(this.shouldMount)), this.mounted;
  }
  /* Ripple API */
  start(...t) {
    this.mount().then(() => {
      var r;
      return (r = this.ref.current) == null ? void 0 : r.start(...t);
    });
  }
  stop(...t) {
    this.mount().then(() => {
      var r;
      return (r = this.ref.current) == null ? void 0 : r.stop(...t);
    });
  }
  pulsate(...t) {
    this.mount().then(() => {
      var r;
      return (r = this.ref.current) == null ? void 0 : r.pulsate(...t);
    });
  }
}
function SB() {
  return El.use();
}
function wB() {
  let e, t;
  const r = new Promise((n, o) => {
    e = n, t = o;
  });
  return r.resolve = e, r.reject = t, r;
}
function yv(e, t) {
  if (e == null) return {};
  var r = {};
  for (var n in e) if ({}.hasOwnProperty.call(e, n)) {
    if (t.includes(n)) continue;
    r[n] = e[n];
  }
  return r;
}
function Ku(e, t) {
  return Ku = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(r, n) {
    return r.__proto__ = n, r;
  }, Ku(e, t);
}
function bv(e, t) {
  e.prototype = Object.create(t.prototype), e.prototype.constructor = e, Ku(e, t);
}
const Qm = {
  disabled: !1
}, _l = pn.createContext(null);
var CB = function(t) {
  return t.scrollTop;
}, yi = "unmounted", vo = "exited", $o = "entering", ra = "entered", Gu = "exiting", en = /* @__PURE__ */ function(e) {
  bv(t, e);
  function t(n, o) {
    var a;
    a = e.call(this, n, o) || this;
    var i = o, s = i && !i.isMounting ? n.enter : n.appear, l;
    return a.appearStatus = null, n.in ? s ? (l = vo, a.appearStatus = $o) : l = ra : n.unmountOnExit || n.mountOnEnter ? l = yi : l = vo, a.state = {
      status: l
    }, a.nextCallback = null, a;
  }
  t.getDerivedStateFromProps = function(o, a) {
    var i = o.in;
    return i && a.status === yi ? {
      status: vo
    } : null;
  };
  var r = t.prototype;
  return r.componentDidMount = function() {
    this.updateStatus(!0, this.appearStatus);
  }, r.componentDidUpdate = function(o) {
    var a = null;
    if (o !== this.props) {
      var i = this.state.status;
      this.props.in ? i !== $o && i !== ra && (a = $o) : (i === $o || i === ra) && (a = Gu);
    }
    this.updateStatus(!1, a);
  }, r.componentWillUnmount = function() {
    this.cancelNextCallback();
  }, r.getTimeouts = function() {
    var o = this.props.timeout, a, i, s;
    return a = i = s = o, o != null && typeof o != "number" && (a = o.exit, i = o.enter, s = o.appear !== void 0 ? o.appear : i), {
      exit: a,
      enter: i,
      appear: s
    };
  }, r.updateStatus = function(o, a) {
    if (o === void 0 && (o = !1), a !== null)
      if (this.cancelNextCallback(), a === $o) {
        if (this.props.unmountOnExit || this.props.mountOnEnter) {
          var i = this.props.nodeRef ? this.props.nodeRef.current : Cs.findDOMNode(this);
          i && CB(i);
        }
        this.performEnter(o);
      } else
        this.performExit();
    else this.props.unmountOnExit && this.state.status === vo && this.setState({
      status: yi
    });
  }, r.performEnter = function(o) {
    var a = this, i = this.props.enter, s = this.context ? this.context.isMounting : o, l = this.props.nodeRef ? [s] : [Cs.findDOMNode(this), s], c = l[0], u = l[1], f = this.getTimeouts(), d = s ? f.appear : f.enter;
    if (!o && !i || Qm.disabled) {
      this.safeSetState({
        status: ra
      }, function() {
        a.props.onEntered(c);
      });
      return;
    }
    this.props.onEnter(c, u), this.safeSetState({
      status: $o
    }, function() {
      a.props.onEntering(c, u), a.onTransitionEnd(d, function() {
        a.safeSetState({
          status: ra
        }, function() {
          a.props.onEntered(c, u);
        });
      });
    });
  }, r.performExit = function() {
    var o = this, a = this.props.exit, i = this.getTimeouts(), s = this.props.nodeRef ? void 0 : Cs.findDOMNode(this);
    if (!a || Qm.disabled) {
      this.safeSetState({
        status: vo
      }, function() {
        o.props.onExited(s);
      });
      return;
    }
    this.props.onExit(s), this.safeSetState({
      status: Gu
    }, function() {
      o.props.onExiting(s), o.onTransitionEnd(i.exit, function() {
        o.safeSetState({
          status: vo
        }, function() {
          o.props.onExited(s);
        });
      });
    });
  }, r.cancelNextCallback = function() {
    this.nextCallback !== null && (this.nextCallback.cancel(), this.nextCallback = null);
  }, r.safeSetState = function(o, a) {
    a = this.setNextCallback(a), this.setState(o, a);
  }, r.setNextCallback = function(o) {
    var a = this, i = !0;
    return this.nextCallback = function(s) {
      i && (i = !1, a.nextCallback = null, o(s));
    }, this.nextCallback.cancel = function() {
      i = !1;
    }, this.nextCallback;
  }, r.onTransitionEnd = function(o, a) {
    this.setNextCallback(a);
    var i = this.props.nodeRef ? this.props.nodeRef.current : Cs.findDOMNode(this), s = o == null && !this.props.addEndListener;
    if (!i || s) {
      setTimeout(this.nextCallback, 0);
      return;
    }
    if (this.props.addEndListener) {
      var l = this.props.nodeRef ? [this.nextCallback] : [i, this.nextCallback], c = l[0], u = l[1];
      this.props.addEndListener(c, u);
    }
    o != null && setTimeout(this.nextCallback, o);
  }, r.render = function() {
    var o = this.state.status;
    if (o === yi)
      return null;
    var a = this.props, i = a.children;
    a.in, a.mountOnEnter, a.unmountOnExit, a.appear, a.enter, a.exit, a.timeout, a.addEndListener, a.onEnter, a.onEntering, a.onEntered, a.onExit, a.onExiting, a.onExited, a.nodeRef;
    var s = yv(a, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]);
    return (
      // allows for nested Transitions
      /* @__PURE__ */ pn.createElement(_l.Provider, {
        value: null
      }, typeof i == "function" ? i(o, s) : pn.cloneElement(pn.Children.only(i), s))
    );
  }, t;
}(pn.Component);
en.contextType = _l;
en.propTypes = {};
function Jo() {
}
en.defaultProps = {
  in: !1,
  mountOnEnter: !1,
  unmountOnExit: !1,
  appear: !1,
  enter: !0,
  exit: !0,
  onEnter: Jo,
  onEntering: Jo,
  onEntered: Jo,
  onExit: Jo,
  onExiting: Jo,
  onExited: Jo
};
en.UNMOUNTED = yi;
en.EXITED = vo;
en.ENTERING = $o;
en.ENTERED = ra;
en.EXITING = Gu;
function EB(e) {
  if (e === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
  return e;
}
function Of(e, t) {
  var r = function(a) {
    return t && Ks(a) ? t(a) : a;
  }, n = /* @__PURE__ */ Object.create(null);
  return e && m$.map(e, function(o) {
    return o;
  }).forEach(function(o) {
    n[o.key] = r(o);
  }), n;
}
function _B(e, t) {
  e = e || {}, t = t || {};
  function r(u) {
    return u in t ? t[u] : e[u];
  }
  var n = /* @__PURE__ */ Object.create(null), o = [];
  for (var a in e)
    a in t ? o.length && (n[a] = o, o = []) : o.push(a);
  var i, s = {};
  for (var l in t) {
    if (n[l])
      for (i = 0; i < n[l].length; i++) {
        var c = n[l][i];
        s[n[l][i]] = r(c);
      }
    s[l] = r(l);
  }
  for (i = 0; i < o.length; i++)
    s[o[i]] = r(o[i]);
  return s;
}
function _o(e, t, r) {
  return r[t] != null ? r[t] : e.props[t];
}
function xB(e, t) {
  return Of(e.children, function(r) {
    return Gs(r, {
      onExited: t.bind(null, r),
      in: !0,
      appear: _o(r, "appear", e),
      enter: _o(r, "enter", e),
      exit: _o(r, "exit", e)
    });
  });
}
function PB(e, t, r) {
  var n = Of(e.children), o = _B(t, n);
  return Object.keys(o).forEach(function(a) {
    var i = o[a];
    if (Ks(i)) {
      var s = a in t, l = a in n, c = t[a], u = Ks(c) && !c.props.in;
      l && (!s || u) ? o[a] = Gs(i, {
        onExited: r.bind(null, i),
        in: !0,
        exit: _o(i, "exit", e),
        enter: _o(i, "enter", e)
      }) : !l && s && !u ? o[a] = Gs(i, {
        in: !1
      }) : l && s && Ks(c) && (o[a] = Gs(i, {
        onExited: r.bind(null, i),
        in: c.props.in,
        exit: _o(i, "exit", e),
        enter: _o(i, "enter", e)
      }));
    }
  }), o;
}
var kB = Object.values || function(e) {
  return Object.keys(e).map(function(t) {
    return e[t];
  });
}, OB = {
  component: "div",
  childFactory: function(t) {
    return t;
  }
}, Af = /* @__PURE__ */ function(e) {
  bv(t, e);
  function t(n, o) {
    var a;
    a = e.call(this, n, o) || this;
    var i = a.handleExited.bind(EB(a));
    return a.state = {
      contextValue: {
        isMounting: !0
      },
      handleExited: i,
      firstRender: !0
    }, a;
  }
  var r = t.prototype;
  return r.componentDidMount = function() {
    this.mounted = !0, this.setState({
      contextValue: {
        isMounting: !1
      }
    });
  }, r.componentWillUnmount = function() {
    this.mounted = !1;
  }, t.getDerivedStateFromProps = function(o, a) {
    var i = a.children, s = a.handleExited, l = a.firstRender;
    return {
      children: l ? xB(o, s) : PB(o, i, s),
      firstRender: !1
    };
  }, r.handleExited = function(o, a) {
    var i = Of(this.props.children);
    o.key in i || (o.props.onExited && o.props.onExited(a), this.mounted && this.setState(function(s) {
      var l = Sl({}, s.children);
      return delete l[o.key], {
        children: l
      };
    }));
  }, r.render = function() {
    var o = this.props, a = o.component, i = o.childFactory, s = yv(o, ["component", "childFactory"]), l = this.state.contextValue, c = kB(this.state.children).map(i);
    return delete s.appear, delete s.enter, delete s.exit, a === null ? /* @__PURE__ */ pn.createElement(_l.Provider, {
      value: l
    }, c) : /* @__PURE__ */ pn.createElement(_l.Provider, {
      value: l
    }, /* @__PURE__ */ pn.createElement(a, s, c));
  }, t;
}(pn.Component);
Af.propTypes = {};
Af.defaultProps = OB;
function AB(e) {
  const {
    className: t,
    classes: r,
    pulsate: n = !1,
    rippleX: o,
    rippleY: a,
    rippleSize: i,
    in: s,
    onExited: l,
    timeout: c
  } = e, [u, f] = M.useState(!1), d = Ee(t, r.ripple, r.rippleVisible, n && r.ripplePulsate), p = {
    width: i,
    height: i,
    top: -(i / 2) + a,
    left: -(i / 2) + o
  }, h = Ee(r.child, u && r.childLeaving, n && r.childPulsate);
  return !s && !u && f(!0), M.useEffect(() => {
    if (!s && l != null) {
      const $ = setTimeout(l, c);
      return () => {
        clearTimeout($);
      };
    }
  }, [l, s, c]), /* @__PURE__ */ P("span", {
    className: d,
    style: p,
    children: /* @__PURE__ */ P("span", {
      className: h
    })
  });
}
const Lr = De("MuiTouchRipple", ["root", "ripple", "rippleVisible", "ripplePulsate", "child", "childLeaving", "childPulsate"]), Hu = 550, IB = 80, RB = fo`
  0% {
    transform: scale(0);
    opacity: 0.1;
  }

  100% {
    transform: scale(1);
    opacity: 0.3;
  }
`, TB = fo`
  0% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
`, MB = fo`
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(0.92);
  }

  100% {
    transform: scale(1);
  }
`, NB = de("span", {
  name: "MuiTouchRipple",
  slot: "Root"
})({
  overflow: "hidden",
  pointerEvents: "none",
  position: "absolute",
  zIndex: 0,
  top: 0,
  right: 0,
  bottom: 0,
  left: 0,
  borderRadius: "inherit"
}), FB = de(AB, {
  name: "MuiTouchRipple",
  slot: "Ripple"
})`
  opacity: 0;
  position: absolute;

  &.${Lr.rippleVisible} {
    opacity: 0.3;
    transform: scale(1);
    animation-name: ${RB};
    animation-duration: ${Hu}ms;
    animation-timing-function: ${({
  theme: e
}) => e.transitions.easing.easeInOut};
  }

  &.${Lr.ripplePulsate} {
    animation-duration: ${({
  theme: e
}) => e.transitions.duration.shorter}ms;
  }

  & .${Lr.child} {
    opacity: 1;
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: currentColor;
  }

  & .${Lr.childLeaving} {
    opacity: 0;
    animation-name: ${TB};
    animation-duration: ${Hu}ms;
    animation-timing-function: ${({
  theme: e
}) => e.transitions.easing.easeInOut};
  }

  & .${Lr.childPulsate} {
    position: absolute;
    /* @noflip */
    left: 0px;
    top: 0;
    animation-name: ${MB};
    animation-duration: 2500ms;
    animation-timing-function: ${({
  theme: e
}) => e.transitions.easing.easeInOut};
    animation-iteration-count: infinite;
    animation-delay: 200ms;
  }
`, jB = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiTouchRipple"
  }), {
    center: o = !1,
    classes: a = {},
    className: i,
    ...s
  } = n, [l, c] = M.useState([]), u = M.useRef(0), f = M.useRef(null);
  M.useEffect(() => {
    f.current && (f.current(), f.current = null);
  }, [l]);
  const d = M.useRef(!1), p = pf(), h = M.useRef(null), $ = M.useRef(null), b = M.useCallback((m) => {
    const {
      pulsate: w,
      rippleX: v,
      rippleY: E,
      rippleSize: I,
      cb: R
    } = m;
    c((C) => [...C, /* @__PURE__ */ P(FB, {
      classes: {
        ripple: Ee(a.ripple, Lr.ripple),
        rippleVisible: Ee(a.rippleVisible, Lr.rippleVisible),
        ripplePulsate: Ee(a.ripplePulsate, Lr.ripplePulsate),
        child: Ee(a.child, Lr.child),
        childLeaving: Ee(a.childLeaving, Lr.childLeaving),
        childPulsate: Ee(a.childPulsate, Lr.childPulsate)
      },
      timeout: Hu,
      pulsate: w,
      rippleX: v,
      rippleY: E,
      rippleSize: I
    }, u.current)]), u.current += 1, f.current = R;
  }, [a]), g = M.useCallback((m = {}, w = {}, v = () => {
  }) => {
    const {
      pulsate: E = !1,
      center: I = o || w.pulsate,
      fakeElement: R = !1
      // For test purposes
    } = w;
    if ((m == null ? void 0 : m.type) === "mousedown" && d.current) {
      d.current = !1;
      return;
    }
    (m == null ? void 0 : m.type) === "touchstart" && (d.current = !0);
    const C = R ? null : $.current, T = C ? C.getBoundingClientRect() : {
      width: 0,
      height: 0,
      left: 0,
      top: 0
    };
    let F, D, z;
    if (I || m === void 0 || m.clientX === 0 && m.clientY === 0 || !m.clientX && !m.touches)
      F = Math.round(T.width / 2), D = Math.round(T.height / 2);
    else {
      const {
        clientX: L,
        clientY: X
      } = m.touches && m.touches.length > 0 ? m.touches[0] : m;
      F = Math.round(L - T.left), D = Math.round(X - T.top);
    }
    if (I)
      z = Math.sqrt((2 * T.width ** 2 + T.height ** 2) / 3), z % 2 === 0 && (z += 1);
    else {
      const L = Math.max(Math.abs((C ? C.clientWidth : 0) - F), F) * 2 + 2, X = Math.max(Math.abs((C ? C.clientHeight : 0) - D), D) * 2 + 2;
      z = Math.sqrt(L ** 2 + X ** 2);
    }
    m != null && m.touches ? h.current === null && (h.current = () => {
      b({
        pulsate: E,
        rippleX: F,
        rippleY: D,
        rippleSize: z,
        cb: v
      });
    }, p.start(IB, () => {
      h.current && (h.current(), h.current = null);
    })) : b({
      pulsate: E,
      rippleX: F,
      rippleY: D,
      rippleSize: z,
      cb: v
    });
  }, [o, b, p]), y = M.useCallback(() => {
    g({}, {
      pulsate: !0
    });
  }, [g]), S = M.useCallback((m, w) => {
    if (p.clear(), (m == null ? void 0 : m.type) === "touchend" && h.current) {
      h.current(), h.current = null, p.start(0, () => {
        S(m, w);
      });
      return;
    }
    h.current = null, c((v) => v.length > 0 ? v.slice(1) : v), f.current = w;
  }, [p]);
  return M.useImperativeHandle(r, () => ({
    pulsate: y,
    start: g,
    stop: S
  }), [y, g, S]), /* @__PURE__ */ P(NB, {
    className: Ee(Lr.root, a.root, i),
    ref: $,
    ...s,
    children: /* @__PURE__ */ P(Af, {
      component: null,
      exit: !0,
      children: l
    })
  });
});
function DB(e) {
  return Be("MuiButtonBase", e);
}
const LB = De("MuiButtonBase", ["root", "disabled", "focusVisible"]), BB = (e) => {
  const {
    disabled: t,
    focusVisible: r,
    focusVisibleClassName: n,
    classes: o
  } = e, i = ze({
    root: ["root", t && "disabled", r && "focusVisible"]
  }, DB, o);
  return r && n && (i.root += ` ${n}`), i;
}, zB = de("button", {
  name: "MuiButtonBase",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({
  display: "inline-flex",
  alignItems: "center",
  justifyContent: "center",
  position: "relative",
  boxSizing: "border-box",
  WebkitTapHighlightColor: "transparent",
  backgroundColor: "transparent",
  // Reset default value
  // We disable the focus ring for mouse, touch and keyboard users.
  outline: 0,
  border: 0,
  margin: 0,
  // Remove the margin in Safari
  borderRadius: 0,
  padding: 0,
  // Remove the padding in Firefox
  cursor: "pointer",
  userSelect: "none",
  verticalAlign: "middle",
  MozAppearance: "none",
  // Reset
  WebkitAppearance: "none",
  // Reset
  textDecoration: "none",
  // So we take precedent over the style of a native <a /> element.
  color: "inherit",
  "&::-moz-focus-inner": {
    borderStyle: "none"
    // Remove Firefox dotted outline.
  },
  [`&.${LB.disabled}`]: {
    pointerEvents: "none",
    // Disable link interactions
    cursor: "default"
  },
  "@media print": {
    colorAdjust: "exact"
  }
}), hs = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiButtonBase"
  }), {
    action: o,
    centerRipple: a = !1,
    children: i,
    className: s,
    component: l = "button",
    disabled: c = !1,
    disableRipple: u = !1,
    disableTouchRipple: f = !1,
    focusRipple: d = !1,
    focusVisibleClassName: p,
    LinkComponent: h = "a",
    onBlur: $,
    onClick: b,
    onContextMenu: g,
    onDragLeave: y,
    onFocus: S,
    onFocusVisible: m,
    onKeyDown: w,
    onKeyUp: v,
    onMouseDown: E,
    onMouseLeave: I,
    onMouseUp: R,
    onTouchEnd: C,
    onTouchMove: T,
    onTouchStart: F,
    tabIndex: D = 0,
    TouchRippleProps: z,
    touchRippleRef: L,
    type: X,
    ...V
  } = n, ie = M.useRef(null), Y = SB(), H = Bt(Y.ref, L), [j, Q] = M.useState(!1);
  c && j && Q(!1), M.useImperativeHandle(o, () => ({
    focusVisible: () => {
      Q(!0), ie.current.focus();
    }
  }), []);
  const q = Y.shouldMount && !u && !c;
  M.useEffect(() => {
    j && d && !u && Y.pulsate();
  }, [u, d, j, Y]);
  const O = An(Y, "start", E, f), N = An(Y, "stop", g, f), W = An(Y, "stop", y, f), ne = An(Y, "stop", R, f), ee = An(Y, "stop", (Ce) => {
    j && Ce.preventDefault(), I && I(Ce);
  }, f), pe = An(Y, "start", F, f), ce = An(Y, "stop", C, f), ye = An(Y, "stop", T, f), _e = An(Y, "stop", (Ce) => {
    vl(Ce.target) || Q(!1), $ && $(Ce);
  }, !1), Me = Rn((Ce) => {
    ie.current || (ie.current = Ce.currentTarget), vl(Ce.target) && (Q(!0), m && m(Ce)), S && S(Ce);
  }), Re = () => {
    const Ce = ie.current;
    return l && l !== "button" && !(Ce.tagName === "A" && Ce.href);
  }, Ve = Rn((Ce) => {
    d && !Ce.repeat && j && Ce.key === " " && Y.stop(Ce, () => {
      Y.start(Ce);
    }), Ce.target === Ce.currentTarget && Re() && Ce.key === " " && Ce.preventDefault(), w && w(Ce), Ce.target === Ce.currentTarget && Re() && Ce.key === "Enter" && !c && (Ce.preventDefault(), b && b(Ce));
  }), mt = Rn((Ce) => {
    d && Ce.key === " " && j && !Ce.defaultPrevented && Y.stop(Ce, () => {
      Y.pulsate(Ce);
    }), v && v(Ce), b && Ce.target === Ce.currentTarget && Re() && Ce.key === " " && !Ce.defaultPrevented && b(Ce);
  });
  let Ue = l;
  Ue === "button" && (V.href || V.to) && (Ue = h);
  const qe = {};
  Ue === "button" ? (qe.type = X === void 0 ? "button" : X, qe.disabled = c) : (!V.href && !V.to && (qe.role = "button"), c && (qe["aria-disabled"] = c));
  const se = Bt(r, ie), Ze = {
    ...n,
    centerRipple: a,
    component: l,
    disabled: c,
    disableRipple: u,
    disableTouchRipple: f,
    focusRipple: d,
    tabIndex: D,
    focusVisible: j
  }, rt = BB(Ze);
  return /* @__PURE__ */ ue(zB, {
    as: Ue,
    className: Ee(rt.root, s),
    ownerState: Ze,
    onBlur: _e,
    onClick: b,
    onContextMenu: N,
    onFocus: Me,
    onKeyDown: Ve,
    onKeyUp: mt,
    onMouseDown: O,
    onMouseLeave: ee,
    onMouseUp: ne,
    onDragLeave: W,
    onTouchEnd: ce,
    onTouchMove: ye,
    onTouchStart: pe,
    ref: se,
    tabIndex: c ? -1 : D,
    type: X,
    ...qe,
    ...V,
    children: [i, q ? /* @__PURE__ */ P(jB, {
      ref: H,
      center: a,
      ...z
    }) : null]
  });
});
function An(e, t, r, n = !1) {
  return Rn((o) => (r && r(o), n || e[t](o), !0));
}
function UB(e) {
  return Be("MuiIconButton", e);
}
const VB = De("MuiIconButton", ["root", "disabled", "colorInherit", "colorPrimary", "colorSecondary", "colorError", "colorInfo", "colorSuccess", "colorWarning", "edgeStart", "edgeEnd", "sizeSmall", "sizeMedium", "sizeLarge"]), qB = (e) => {
  const {
    classes: t,
    disabled: r,
    color: n,
    edge: o,
    size: a
  } = e, i = {
    root: ["root", r && "disabled", n !== "default" && `color${$e(n)}`, o && `edge${$e(o)}`, `size${$e(a)}`]
  };
  return ze(i, UB, t);
}, WB = de(hs, {
  name: "MuiIconButton",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.color !== "default" && t[`color${$e(r.color)}`], r.edge && t[`edge${$e(r.edge)}`], t[`size${$e(r.size)}`]];
  }
})(je(({
  theme: e
}) => ({
  textAlign: "center",
  flex: "0 0 auto",
  fontSize: e.typography.pxToRem(24),
  padding: 8,
  borderRadius: "50%",
  color: (e.vars || e).palette.action.active,
  transition: e.transitions.create("background-color", {
    duration: e.transitions.duration.shortest
  }),
  variants: [{
    props: (t) => !t.disableRipple,
    style: {
      "--IconButton-hoverBg": e.vars ? `rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette.action.active, e.palette.action.hoverOpacity),
      "&:hover": {
        backgroundColor: "var(--IconButton-hoverBg)",
        // Reset on touch devices, it doesn't add specificity
        "@media (hover: none)": {
          backgroundColor: "transparent"
        }
      }
    }
  }, {
    props: {
      edge: "start"
    },
    style: {
      marginLeft: -12
    }
  }, {
    props: {
      edge: "start",
      size: "small"
    },
    style: {
      marginLeft: -3
    }
  }, {
    props: {
      edge: "end"
    },
    style: {
      marginRight: -12
    }
  }, {
    props: {
      edge: "end",
      size: "small"
    },
    style: {
      marginRight: -3
    }
  }]
})), je(({
  theme: e
}) => ({
  variants: [{
    props: {
      color: "inherit"
    },
    style: {
      color: "inherit"
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      color: (e.vars || e).palette[t].main
    }
  })), ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      "--IconButton-hoverBg": e.vars ? `rgba(${(e.vars || e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt((e.vars || e).palette[t].main, e.palette.action.hoverOpacity)
    }
  })), {
    props: {
      size: "small"
    },
    style: {
      padding: 5,
      fontSize: e.typography.pxToRem(18)
    }
  }, {
    props: {
      size: "large"
    },
    style: {
      padding: 12,
      fontSize: e.typography.pxToRem(28)
    }
  }],
  [`&.${VB.disabled}`]: {
    backgroundColor: "transparent",
    color: (e.vars || e).palette.action.disabled
  }
}))), vv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiIconButton"
  }), {
    edge: o = !1,
    children: a,
    className: i,
    color: s = "default",
    disabled: l = !1,
    disableFocusRipple: c = !1,
    size: u = "medium",
    ...f
  } = n, d = {
    ...n,
    edge: o,
    color: s,
    disabled: l,
    disableFocusRipple: c,
    size: u
  }, p = qB(d);
  return /* @__PURE__ */ P(WB, {
    className: Ee(p.root, i),
    centerRipple: !0,
    focusRipple: !c,
    disabled: l,
    ref: r,
    ...f,
    ownerState: d,
    children: a
  });
});
function KB({ uiSchema: e, registry: t, ...r }) {
  const { translateString: n } = t;
  return P(vv, { title: n(ot.AddItemButton), ...r, color: "primary", children: P(bB, {}) });
}
const GB = De("MuiBox", ["root"]), HB = gv(), hr = JL({
  themeId: $c,
  defaultTheme: HB,
  defaultClassName: GB.root,
  generateClassName: jb.generate
}), eg = /* @__PURE__ */ M.createContext();
function JB(e) {
  return Be("MuiGrid", e);
}
const YB = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10], XB = ["column-reverse", "column", "row-reverse", "row"], ZB = ["nowrap", "wrap-reverse", "wrap"], ii = ["auto", !0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12], Ki = De("MuiGrid", [
  "root",
  "container",
  "item",
  "zeroMinWidth",
  // spacings
  ...YB.map((e) => `spacing-xs-${e}`),
  // direction values
  ...XB.map((e) => `direction-xs-${e}`),
  // wrap values
  ...ZB.map((e) => `wrap-xs-${e}`),
  // grid sizes for all breakpoints
  ...ii.map((e) => `grid-xs-${e}`),
  ...ii.map((e) => `grid-sm-${e}`),
  ...ii.map((e) => `grid-md-${e}`),
  ...ii.map((e) => `grid-lg-${e}`),
  ...ii.map((e) => `grid-xl-${e}`)
]);
function QB({
  theme: e,
  ownerState: t
}) {
  let r;
  return e.breakpoints.keys.reduce((n, o) => {
    let a = {};
    if (t[o] && (r = t[o]), !r)
      return n;
    if (r === !0)
      a = {
        flexBasis: 0,
        flexGrow: 1,
        maxWidth: "100%"
      };
    else if (r === "auto")
      a = {
        flexBasis: "auto",
        flexGrow: 0,
        flexShrink: 0,
        maxWidth: "none",
        width: "auto"
      };
    else {
      const i = ac({
        values: t.columns,
        breakpoints: e.breakpoints.values
      }), s = typeof i == "object" ? i[o] : i;
      if (s == null)
        return n;
      const l = `${Math.round(r / s * 1e8) / 1e6}%`;
      let c = {};
      if (t.container && t.item && t.columnSpacing !== 0) {
        const u = e.spacing(t.columnSpacing);
        if (u !== "0px") {
          const f = `calc(${l} + ${u})`;
          c = {
            flexBasis: f,
            maxWidth: f
          };
        }
      }
      a = {
        flexBasis: l,
        flexGrow: 0,
        maxWidth: l,
        ...c
      };
    }
    return e.breakpoints.values[o] === 0 ? Object.assign(n, a) : n[e.breakpoints.up(o)] = a, n;
  }, {});
}
function ez({
  theme: e,
  ownerState: t
}) {
  const r = ac({
    values: t.direction,
    breakpoints: e.breakpoints.values
  });
  return Wr({
    theme: e
  }, r, (n) => {
    const o = {
      flexDirection: n
    };
    return n.startsWith("column") && (o[`& > .${Ki.item}`] = {
      maxWidth: "none"
    }), o;
  });
}
function $v({
  breakpoints: e,
  values: t
}) {
  let r = "";
  Object.keys(t).forEach((o) => {
    r === "" && t[o] !== 0 && (r = o);
  });
  const n = Object.keys(e).sort((o, a) => e[o] - e[a]);
  return n.slice(0, n.indexOf(r));
}
function tz({
  theme: e,
  ownerState: t
}) {
  const {
    container: r,
    rowSpacing: n
  } = t;
  let o = {};
  if (r && n !== 0) {
    const a = ac({
      values: n,
      breakpoints: e.breakpoints.values
    });
    let i;
    typeof a == "object" && (i = $v({
      breakpoints: e.breakpoints.values,
      values: a
    })), o = Wr({
      theme: e
    }, a, (s, l) => {
      const c = e.spacing(s);
      return c !== "0px" ? {
        marginTop: `calc(-1 * ${c})`,
        [`& > .${Ki.item}`]: {
          paddingTop: c
        }
      } : i != null && i.includes(l) ? {} : {
        marginTop: 0,
        [`& > .${Ki.item}`]: {
          paddingTop: 0
        }
      };
    });
  }
  return o;
}
function rz({
  theme: e,
  ownerState: t
}) {
  const {
    container: r,
    columnSpacing: n
  } = t;
  let o = {};
  if (r && n !== 0) {
    const a = ac({
      values: n,
      breakpoints: e.breakpoints.values
    });
    let i;
    typeof a == "object" && (i = $v({
      breakpoints: e.breakpoints.values,
      values: a
    })), o = Wr({
      theme: e
    }, a, (s, l) => {
      const c = e.spacing(s);
      if (c !== "0px") {
        const u = `calc(-1 * ${c})`;
        return {
          width: `calc(100% + ${c})`,
          marginLeft: u,
          [`& > .${Ki.item}`]: {
            paddingLeft: c
          }
        };
      }
      return i != null && i.includes(l) ? {} : {
        width: "100%",
        marginLeft: 0,
        [`& > .${Ki.item}`]: {
          paddingLeft: 0
        }
      };
    });
  }
  return o;
}
function nz(e, t, r = {}) {
  if (!e || e <= 0)
    return [];
  if (typeof e == "string" && !Number.isNaN(Number(e)) || typeof e == "number")
    return [r[`spacing-xs-${String(e)}`]];
  const n = [];
  return t.forEach((o) => {
    const a = e[o];
    Number(a) > 0 && n.push(r[`spacing-${o}-${String(a)}`]);
  }), n;
}
const oz = de("div", {
  name: "MuiGrid",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e, {
      container: n,
      direction: o,
      item: a,
      spacing: i,
      wrap: s,
      zeroMinWidth: l,
      breakpoints: c
    } = r;
    let u = [];
    n && (u = nz(i, c, t));
    const f = [];
    return c.forEach((d) => {
      const p = r[d];
      p && f.push(t[`grid-${d}-${String(p)}`]);
    }), [t.root, n && t.container, a && t.item, l && t.zeroMinWidth, ...u, o !== "row" && t[`direction-xs-${String(o)}`], s !== "wrap" && t[`wrap-xs-${String(s)}`], ...f];
  }
})(
  // FIXME(romgrk): Can't use memoTheme here
  ({
    ownerState: e
  }) => ({
    boxSizing: "border-box",
    ...e.container && {
      display: "flex",
      flexWrap: "wrap",
      width: "100%"
    },
    ...e.item && {
      margin: 0
      // For instance, it's useful when used with a `figure` element.
    },
    ...e.zeroMinWidth && {
      minWidth: 0
    },
    ...e.wrap !== "wrap" && {
      flexWrap: e.wrap
    }
  }),
  ez,
  tz,
  rz,
  QB
);
function az(e, t) {
  if (!e || e <= 0)
    return [];
  if (typeof e == "string" && !Number.isNaN(Number(e)) || typeof e == "number")
    return [`spacing-xs-${String(e)}`];
  const r = [];
  return t.forEach((n) => {
    const o = e[n];
    if (Number(o) > 0) {
      const a = `spacing-${n}-${String(o)}`;
      r.push(a);
    }
  }), r;
}
const iz = (e) => {
  const {
    classes: t,
    container: r,
    direction: n,
    item: o,
    spacing: a,
    wrap: i,
    zeroMinWidth: s,
    breakpoints: l
  } = e;
  let c = [];
  r && (c = az(a, l));
  const u = [];
  l.forEach((d) => {
    const p = e[d];
    p && u.push(`grid-${d}-${String(p)}`);
  });
  const f = {
    root: ["root", r && "container", o && "item", s && "zeroMinWidth", ...c, n !== "row" && `direction-xs-${String(n)}`, i !== "wrap" && `wrap-xs-${String(i)}`, ...u]
  };
  return ze(f, JB, t);
}, Rr = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiGrid"
  }), {
    breakpoints: o
  } = Ka(), a = fc(n), {
    className: i,
    columns: s,
    columnSpacing: l,
    component: c = "div",
    container: u = !1,
    direction: f = "row",
    item: d = !1,
    rowSpacing: p,
    spacing: h = 0,
    wrap: $ = "wrap",
    zeroMinWidth: b = !1,
    ...g
  } = a, y = p || h, S = l || h, m = M.useContext(eg), w = u ? s || 12 : m, v = {}, E = {
    ...g
  };
  o.keys.forEach((C) => {
    g[C] != null && (v[C] = g[C], delete E[C]);
  });
  const I = {
    ...a,
    columns: w,
    container: u,
    direction: f,
    item: d,
    rowSpacing: y,
    columnSpacing: S,
    wrap: $,
    zeroMinWidth: b,
    spacing: h,
    ...v,
    breakpoints: o.keys
  }, R = iz(I);
  return /* @__PURE__ */ P(eg.Provider, {
    value: w,
    children: /* @__PURE__ */ P(oz, {
      ownerState: I,
      className: Ee(R.root, i),
      as: c,
      ref: r,
      ...E
    })
  });
});
function sz(e) {
  return Be("MuiPaper", e);
}
De("MuiPaper", ["root", "rounded", "outlined", "elevation", "elevation0", "elevation1", "elevation2", "elevation3", "elevation4", "elevation5", "elevation6", "elevation7", "elevation8", "elevation9", "elevation10", "elevation11", "elevation12", "elevation13", "elevation14", "elevation15", "elevation16", "elevation17", "elevation18", "elevation19", "elevation20", "elevation21", "elevation22", "elevation23", "elevation24"]);
const lz = (e) => {
  const {
    square: t,
    elevation: r,
    variant: n,
    classes: o
  } = e, a = {
    root: ["root", n, !t && "rounded", n === "elevation" && `elevation${r}`]
  };
  return ze(a, sz, o);
}, cz = de("div", {
  name: "MuiPaper",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[r.variant], !r.square && t.rounded, r.variant === "elevation" && t[`elevation${r.elevation}`]];
  }
})(je(({
  theme: e
}) => ({
  backgroundColor: (e.vars || e).palette.background.paper,
  color: (e.vars || e).palette.text.primary,
  transition: e.transitions.create("box-shadow"),
  variants: [{
    props: ({
      ownerState: t
    }) => !t.square,
    style: {
      borderRadius: e.shape.borderRadius
    }
  }, {
    props: {
      variant: "outlined"
    },
    style: {
      border: `1px solid ${(e.vars || e).palette.divider}`
    }
  }, {
    props: {
      variant: "elevation"
    },
    style: {
      boxShadow: "var(--Paper-shadow)",
      backgroundImage: "var(--Paper-overlay)"
    }
  }]
}))), Ga = /* @__PURE__ */ M.forwardRef(function(t, r) {
  var p;
  const n = Ke({
    props: t,
    name: "MuiPaper"
  }), o = Ka(), {
    className: a,
    component: i = "div",
    elevation: s = 1,
    square: l = !1,
    variant: c = "elevation",
    ...u
  } = n, f = {
    ...n,
    component: i,
    elevation: s,
    square: l,
    variant: c
  }, d = lz(f);
  return /* @__PURE__ */ P(cz, {
    as: i,
    ownerState: f,
    className: Ee(d.root, a),
    ref: r,
    ...u,
    style: {
      ...c === "elevation" && {
        "--Paper-shadow": (o.vars || o).shadows[s],
        ...o.vars && {
          "--Paper-overlay": (p = o.vars.overlays) == null ? void 0 : p[s]
        },
        ...!o.vars && o.palette.mode === "dark" && {
          "--Paper-overlay": `linear-gradient(${Lt("#fff", qu(s))}, ${Lt("#fff", qu(s))})`
        }
      },
      ...u.style
    }
  });
});
function uz(e) {
  const { children: t, disabled: r, hasToolbar: n, hasCopy: o, hasMoveDown: a, hasMoveUp: i, hasRemove: s, index: l, onCopyIndexClick: c, onDropIndexClick: u, onReorderClick: f, readonly: d, uiSchema: p, registry: h } = e, { CopyButton: $, MoveDownButton: b, MoveUpButton: g, RemoveButton: y } = h.templates.ButtonTemplates, S = {
    flex: 1,
    paddingLeft: 6,
    paddingRight: 6,
    fontWeight: "bold",
    minWidth: 0
  };
  return ue(Rr, { container: !0, alignItems: "center", children: [P(Rr, { item: !0, xs: !0, style: { overflow: "auto" }, children: P(hr, { mb: 2, children: P(Ga, { elevation: 2, children: P(hr, { p: 2, children: t }) }) }) }), n && ue(Rr, { item: !0, children: [(i || a) && P(g, { style: S, disabled: r || d || !i, onClick: f(l, l - 1), uiSchema: p, registry: h }), (i || a) && P(b, { style: S, disabled: r || d || !a, onClick: f(l, l + 1), uiSchema: p, registry: h }), o && P($, { style: S, disabled: r || d, onClick: c(l), uiSchema: p, registry: h }), s && P(y, { style: S, disabled: r || d, onClick: u(l), uiSchema: p, registry: h })] })] });
}
function dz(e) {
  const { canAdd: t, disabled: r, idSchema: n, uiSchema: o, items: a, onAddClick: i, readonly: s, registry: l, required: c, schema: u, title: f } = e, d = Qe(o), p = Ye("ArrayFieldDescriptionTemplate", l, d), h = Ye("ArrayFieldItemTemplate", l, d), $ = Ye("ArrayFieldTitleTemplate", l, d), { ButtonTemplates: { AddButton: b } } = l.templates;
  return P(Ga, { elevation: 2, children: ue(hr, { p: 2, children: [P($, { idSchema: n, title: d.title || f, schema: u, uiSchema: o, required: c, registry: l }), P(p, { idSchema: n, description: d.description || u.description, schema: u, uiSchema: o, registry: l }), a && a.map(({ key: g, ...y }) => P(h, { ...y }, g)), t && P(Rr, { container: !0, justifyContent: "flex-end", children: P(Rr, { item: !0, children: P(hr, { mt: 2, children: P(b, { className: "array-item-add", onClick: i, disabled: r || s, uiSchema: o, registry: l }) }) }) })] }) });
}
function Rs(e) {
  return parseInt(e, 10) || 0;
}
const fz = {
  shadow: {
    // Visibility needed to hide the extra text area on iPads
    visibility: "hidden",
    // Remove from the content flow
    position: "absolute",
    // Ignore the scrollbar width
    overflow: "hidden",
    height: 0,
    top: 0,
    left: 0,
    // Create a new layer, increase the isolation of the computed values
    transform: "translateZ(0)"
  }
};
function pz(e) {
  return e == null || Object.keys(e).length === 0 || e.outerHeightStyle === 0 && !e.overflowing;
}
const hz = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    onChange: n,
    maxRows: o,
    minRows: a = 1,
    style: i,
    value: s,
    ...l
  } = t, {
    current: c
  } = M.useRef(s != null), u = M.useRef(null), f = Bt(r, u), d = M.useRef(null), p = M.useRef(null), h = M.useCallback(() => {
    const g = u.current, S = Ln(g).getComputedStyle(g);
    if (S.width === "0px")
      return {
        outerHeightStyle: 0,
        overflowing: !1
      };
    const m = p.current;
    m.style.width = S.width, m.value = g.value || t.placeholder || "x", m.value.slice(-1) === `
` && (m.value += " ");
    const w = S.boxSizing, v = Rs(S.paddingBottom) + Rs(S.paddingTop), E = Rs(S.borderBottomWidth) + Rs(S.borderTopWidth), I = m.scrollHeight;
    m.value = "x";
    const R = m.scrollHeight;
    let C = I;
    a && (C = Math.max(Number(a) * R, C)), o && (C = Math.min(Number(o) * R, C)), C = Math.max(C, R);
    const T = C + (w === "border-box" ? v + E : 0), F = Math.abs(C - I) <= 1;
    return {
      outerHeightStyle: T,
      overflowing: F
    };
  }, [o, a, t.placeholder]), $ = M.useCallback(() => {
    const g = h();
    if (pz(g))
      return;
    const y = g.outerHeightStyle, S = u.current;
    d.current !== y && (d.current = y, S.style.height = `${y}px`), S.style.overflow = g.overflowing ? "hidden" : "";
  }, [h]);
  Bn(() => {
    const g = () => {
      $();
    };
    let y;
    const S = Mb(g), m = u.current, w = Ln(m);
    w.addEventListener("resize", S);
    let v;
    return typeof ResizeObserver < "u" && (v = new ResizeObserver(g), v.observe(m)), () => {
      S.clear(), cancelAnimationFrame(y), w.removeEventListener("resize", S), v && v.disconnect();
    };
  }, [h, $]), Bn(() => {
    $();
  });
  const b = (g) => {
    c || $(), n && n(g);
  };
  return /* @__PURE__ */ ue(M.Fragment, {
    children: [/* @__PURE__ */ P("textarea", {
      value: s,
      onChange: b,
      ref: f,
      rows: a,
      style: i,
      ...l
    }), /* @__PURE__ */ P("textarea", {
      "aria-hidden": !0,
      className: t.className,
      readOnly: !0,
      ref: p,
      tabIndex: -1,
      style: {
        ...fz.shadow,
        ...i,
        paddingTop: 0,
        paddingBottom: 0
      }
    })]
  });
});
function Tn(e) {
  return typeof e == "string";
}
function po({
  props: e,
  states: t,
  muiFormControl: r
}) {
  return t.reduce((n, o) => (n[o] = e[o], r && typeof e[o] > "u" && (n[o] = r[o]), n), {});
}
const If = /* @__PURE__ */ M.createContext(void 0);
function Sn() {
  return M.useContext(If);
}
function tg(e) {
  return e != null && !(Array.isArray(e) && e.length === 0);
}
function xl(e, t = !1) {
  return e && (tg(e.value) && e.value !== "" || t && tg(e.defaultValue) && e.defaultValue !== "");
}
function mz(e) {
  return e.startAdornment;
}
function gz(e) {
  return Be("MuiInputBase", e);
}
const Ca = De("MuiInputBase", ["root", "formControl", "focused", "disabled", "adornedStart", "adornedEnd", "error", "sizeSmall", "multiline", "colorSecondary", "fullWidth", "hiddenLabel", "readOnly", "input", "inputSizeSmall", "inputMultiline", "inputTypeSearch", "inputAdornedStart", "inputAdornedEnd", "inputHiddenLabel"]);
var rg;
const wc = (e, t) => {
  const {
    ownerState: r
  } = e;
  return [t.root, r.formControl && t.formControl, r.startAdornment && t.adornedStart, r.endAdornment && t.adornedEnd, r.error && t.error, r.size === "small" && t.sizeSmall, r.multiline && t.multiline, r.color && t[`color${$e(r.color)}`], r.fullWidth && t.fullWidth, r.hiddenLabel && t.hiddenLabel];
}, Cc = (e, t) => {
  const {
    ownerState: r
  } = e;
  return [t.input, r.size === "small" && t.inputSizeSmall, r.multiline && t.inputMultiline, r.type === "search" && t.inputTypeSearch, r.startAdornment && t.inputAdornedStart, r.endAdornment && t.inputAdornedEnd, r.hiddenLabel && t.inputHiddenLabel];
}, yz = (e) => {
  const {
    classes: t,
    color: r,
    disabled: n,
    error: o,
    endAdornment: a,
    focused: i,
    formControl: s,
    fullWidth: l,
    hiddenLabel: c,
    multiline: u,
    readOnly: f,
    size: d,
    startAdornment: p,
    type: h
  } = e, $ = {
    root: ["root", `color${$e(r)}`, n && "disabled", o && "error", l && "fullWidth", i && "focused", s && "formControl", d && d !== "medium" && `size${$e(d)}`, u && "multiline", p && "adornedStart", a && "adornedEnd", c && "hiddenLabel", f && "readOnly"],
    input: ["input", n && "disabled", h === "search" && "inputTypeSearch", u && "inputMultiline", d === "small" && "inputSizeSmall", c && "inputHiddenLabel", p && "inputAdornedStart", a && "inputAdornedEnd", f && "readOnly"]
  };
  return ze($, gz, t);
}, Ec = de("div", {
  name: "MuiInputBase",
  slot: "Root",
  overridesResolver: wc
})(je(({
  theme: e
}) => ({
  ...e.typography.body1,
  color: (e.vars || e).palette.text.primary,
  lineHeight: "1.4375em",
  // 23px
  boxSizing: "border-box",
  // Prevent padding issue with fullWidth.
  position: "relative",
  cursor: "text",
  display: "inline-flex",
  alignItems: "center",
  [`&.${Ca.disabled}`]: {
    color: (e.vars || e).palette.text.disabled,
    cursor: "default"
  },
  variants: [{
    props: ({
      ownerState: t
    }) => t.multiline,
    style: {
      padding: "4px 0 5px"
    }
  }, {
    props: ({
      ownerState: t,
      size: r
    }) => t.multiline && r === "small",
    style: {
      paddingTop: 1
    }
  }, {
    props: ({
      ownerState: t
    }) => t.fullWidth,
    style: {
      width: "100%"
    }
  }]
}))), _c = de("input", {
  name: "MuiInputBase",
  slot: "Input",
  overridesResolver: Cc
})(je(({
  theme: e
}) => {
  const t = e.palette.mode === "light", r = {
    color: "currentColor",
    ...e.vars ? {
      opacity: e.vars.opacity.inputPlaceholder
    } : {
      opacity: t ? 0.42 : 0.5
    },
    transition: e.transitions.create("opacity", {
      duration: e.transitions.duration.shorter
    })
  }, n = {
    opacity: "0 !important"
  }, o = e.vars ? {
    opacity: e.vars.opacity.inputPlaceholder
  } : {
    opacity: t ? 0.42 : 0.5
  };
  return {
    font: "inherit",
    letterSpacing: "inherit",
    color: "currentColor",
    padding: "4px 0 5px",
    border: 0,
    boxSizing: "content-box",
    background: "none",
    height: "1.4375em",
    // Reset 23pxthe native input line-height
    margin: 0,
    // Reset for Safari
    WebkitTapHighlightColor: "transparent",
    display: "block",
    // Make the flex item shrink with Firefox
    minWidth: 0,
    width: "100%",
    "&::-webkit-input-placeholder": r,
    "&::-moz-placeholder": r,
    // Firefox 19+
    "&::-ms-input-placeholder": r,
    // Edge
    "&:focus": {
      outline: 0
    },
    // Reset Firefox invalid required input style
    "&:invalid": {
      boxShadow: "none"
    },
    "&::-webkit-search-decoration": {
      // Remove the padding when type=search.
      WebkitAppearance: "none"
    },
    // Show and hide the placeholder logic
    [`label[data-shrink=false] + .${Ca.formControl} &`]: {
      "&::-webkit-input-placeholder": n,
      "&::-moz-placeholder": n,
      // Firefox 19+
      "&::-ms-input-placeholder": n,
      // Edge
      "&:focus::-webkit-input-placeholder": o,
      "&:focus::-moz-placeholder": o,
      // Firefox 19+
      "&:focus::-ms-input-placeholder": o
      // Edge
    },
    [`&.${Ca.disabled}`]: {
      opacity: 1,
      // Reset iOS opacity
      WebkitTextFillColor: (e.vars || e).palette.text.disabled
      // Fix opacity Safari bug
    },
    variants: [{
      props: ({
        ownerState: a
      }) => !a.disableInjectingGlobalStyles,
      style: {
        animationName: "mui-auto-fill-cancel",
        animationDuration: "10ms",
        "&:-webkit-autofill": {
          animationDuration: "5000s",
          animationName: "mui-auto-fill"
        }
      }
    }, {
      props: {
        size: "small"
      },
      style: {
        paddingTop: 1
      }
    }, {
      props: ({
        ownerState: a
      }) => a.multiline,
      style: {
        height: "auto",
        resize: "none",
        padding: 0,
        paddingTop: 0
      }
    }, {
      props: {
        type: "search"
      },
      style: {
        MozAppearance: "textfield"
        // Improve type search style.
      }
    }]
  };
})), ng = pB({
  "@keyframes mui-auto-fill": {
    from: {
      display: "block"
    }
  },
  "@keyframes mui-auto-fill-cancel": {
    from: {
      display: "block"
    }
  }
}), Rf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiInputBase"
  }), {
    "aria-describedby": o,
    autoComplete: a,
    autoFocus: i,
    className: s,
    color: l,
    components: c = {},
    componentsProps: u = {},
    defaultValue: f,
    disabled: d,
    disableInjectingGlobalStyles: p,
    endAdornment: h,
    error: $,
    fullWidth: b = !1,
    id: g,
    inputComponent: y = "input",
    inputProps: S = {},
    inputRef: m,
    margin: w,
    maxRows: v,
    minRows: E,
    multiline: I = !1,
    name: R,
    onBlur: C,
    onChange: T,
    onClick: F,
    onFocus: D,
    onKeyDown: z,
    onKeyUp: L,
    placeholder: X,
    readOnly: V,
    renderSuffix: ie,
    rows: Y,
    size: H,
    slotProps: j = {},
    slots: Q = {},
    startAdornment: q,
    type: O = "text",
    value: N,
    ...W
  } = n, ne = S.value != null ? S.value : N, {
    current: ee
  } = M.useRef(ne != null), pe = M.useRef(), ce = M.useCallback((ae) => {
  }, []), ye = Bt(pe, m, S.ref, ce), [_e, Me] = M.useState(!1), Re = Sn(), Ve = po({
    props: n,
    muiFormControl: Re,
    states: ["color", "disabled", "error", "hiddenLabel", "size", "required", "filled"]
  });
  Ve.focused = Re ? Re.focused : _e, M.useEffect(() => {
    !Re && d && _e && (Me(!1), C && C());
  }, [Re, d, _e, C]);
  const mt = Re && Re.onFilled, Ue = Re && Re.onEmpty, qe = M.useCallback((ae) => {
    xl(ae) ? mt && mt() : Ue && Ue();
  }, [mt, Ue]);
  Bn(() => {
    ee && qe({
      value: ne
    });
  }, [ne, qe, ee]);
  const se = (ae) => {
    D && D(ae), S.onFocus && S.onFocus(ae), Re && Re.onFocus ? Re.onFocus(ae) : Me(!0);
  }, Ze = (ae) => {
    C && C(ae), S.onBlur && S.onBlur(ae), Re && Re.onBlur ? Re.onBlur(ae) : Me(!1);
  }, rt = (ae, ...he) => {
    if (!ee) {
      const Oe = ae.target || pe.current;
      if (Oe == null)
        throw new Error(Dn(1));
      qe({
        value: Oe.value
      });
    }
    S.onChange && S.onChange(ae, ...he), T && T(ae, ...he);
  };
  M.useEffect(() => {
    qe(pe.current);
  }, []);
  const Ce = (ae) => {
    pe.current && ae.currentTarget === ae.target && pe.current.focus(), F && F(ae);
  };
  let Nt = y, re = S;
  I && Nt === "input" && (Y ? re = {
    type: void 0,
    minRows: Y,
    maxRows: Y,
    ...re
  } : re = {
    type: void 0,
    maxRows: v,
    minRows: E,
    ...re
  }, Nt = hz);
  const fe = (ae) => {
    qe(ae.animationName === "mui-auto-fill-cancel" ? pe.current : {
      value: "x"
    });
  };
  M.useEffect(() => {
    Re && Re.setAdornedStart(!!q);
  }, [Re, q]);
  const ve = {
    ...n,
    color: Ve.color || "primary",
    disabled: Ve.disabled,
    endAdornment: h,
    error: Ve.error,
    focused: Ve.focused,
    formControl: Re,
    fullWidth: b,
    hiddenLabel: Ve.hiddenLabel,
    multiline: I,
    size: Ve.size,
    startAdornment: q,
    type: O
  }, Ie = yz(ve), Le = Q.root || c.Root || Ec, K = j.root || u.root || {}, G = Q.input || c.Input || _c;
  return re = {
    ...re,
    ...j.input ?? u.input
  }, /* @__PURE__ */ ue(M.Fragment, {
    children: [!p && typeof ng == "function" && // For Emotion/Styled-components, InputGlobalStyles will be a function
    // For Pigment CSS, this has no effect because the InputGlobalStyles will be null.
    (rg || (rg = /* @__PURE__ */ P(ng, {}))), /* @__PURE__ */ ue(Le, {
      ...K,
      ref: r,
      onClick: Ce,
      ...W,
      ...!Tn(Le) && {
        ownerState: {
          ...ve,
          ...K.ownerState
        }
      },
      className: Ee(Ie.root, K.className, s, V && "MuiInputBase-readOnly"),
      children: [q, /* @__PURE__ */ P(If.Provider, {
        value: null,
        children: /* @__PURE__ */ P(G, {
          "aria-invalid": Ve.error,
          "aria-describedby": o,
          autoComplete: a,
          autoFocus: i,
          defaultValue: f,
          disabled: Ve.disabled,
          id: g,
          onAnimationStart: fe,
          name: R,
          placeholder: X,
          readOnly: V,
          required: Ve.required,
          rows: Y,
          value: ne,
          onKeyDown: z,
          onKeyUp: L,
          type: O,
          ...re,
          ...!Tn(G) && {
            as: Nt,
            ownerState: {
              ...ve,
              ...re.ownerState
            }
          },
          ref: ye,
          className: Ee(Ie.input, re.className, V && "MuiInputBase-readOnly"),
          onBlur: Ze,
          onChange: rt,
          onFocus: se
        })
      }), h, ie ? ie({
        ...Ve,
        startAdornment: q
      }) : null]
    })]
  });
});
function bz(e) {
  return Be("MuiInput", e);
}
const si = {
  ...Ca,
  ...De("MuiInput", ["root", "underline", "input"])
}, vz = (e) => {
  const {
    classes: t,
    disableUnderline: r
  } = e, o = ze({
    root: ["root", !r && "underline"],
    input: ["input"]
  }, bz, t);
  return {
    ...t,
    // forward classes to the InputBase
    ...o
  };
}, $z = de(Ec, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiInput",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [...wc(e, t), !r.disableUnderline && t.underline];
  }
})(je(({
  theme: e
}) => {
  let r = e.palette.mode === "light" ? "rgba(0, 0, 0, 0.42)" : "rgba(255, 255, 255, 0.7)";
  return e.vars && (r = `rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`), {
    position: "relative",
    variants: [{
      props: ({
        ownerState: n
      }) => n.formControl,
      style: {
        "label + &": {
          marginTop: 16
        }
      }
    }, {
      props: ({
        ownerState: n
      }) => !n.disableUnderline,
      style: {
        "&::after": {
          left: 0,
          bottom: 0,
          content: '""',
          position: "absolute",
          right: 0,
          transform: "scaleX(0)",
          transition: e.transitions.create("transform", {
            duration: e.transitions.duration.shorter,
            easing: e.transitions.easing.easeOut
          }),
          pointerEvents: "none"
          // Transparent to the hover style.
        },
        [`&.${si.focused}:after`]: {
          // translateX(0) is a workaround for Safari transform scale bug
          // See https://github.com/mui/material-ui/issues/31766
          transform: "scaleX(1) translateX(0)"
        },
        [`&.${si.error}`]: {
          "&::before, &::after": {
            borderBottomColor: (e.vars || e).palette.error.main
          }
        },
        "&::before": {
          borderBottom: `1px solid ${r}`,
          left: 0,
          bottom: 0,
          content: '"\\00a0"',
          position: "absolute",
          right: 0,
          transition: e.transitions.create("border-bottom-color", {
            duration: e.transitions.duration.shorter
          }),
          pointerEvents: "none"
          // Transparent to the hover style.
        },
        [`&:hover:not(.${si.disabled}, .${si.error}):before`]: {
          borderBottom: `2px solid ${(e.vars || e).palette.text.primary}`,
          // Reset on touch devices, it doesn't add specificity
          "@media (hover: none)": {
            borderBottom: `1px solid ${r}`
          }
        },
        [`&.${si.disabled}:before`]: {
          borderBottomStyle: "dotted"
        }
      }
    }, ...Object.entries(e.palette).filter(zt()).map(([n]) => ({
      props: {
        color: n,
        disableUnderline: !1
      },
      style: {
        "&::after": {
          borderBottom: `2px solid ${(e.vars || e).palette[n].main}`
        }
      }
    }))]
  };
})), Sz = de(_c, {
  name: "MuiInput",
  slot: "Input",
  overridesResolver: Cc
})({}), Tf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiInput"
  }), {
    disableUnderline: o = !1,
    components: a = {},
    componentsProps: i,
    fullWidth: s = !1,
    inputComponent: l = "input",
    multiline: c = !1,
    slotProps: u,
    slots: f = {},
    type: d = "text",
    ...p
  } = n, h = vz(n), b = {
    root: {
      ownerState: {
        disableUnderline: o
      }
    }
  }, g = u ?? i ? lr(u ?? i, b) : b, y = f.root ?? a.Root ?? $z, S = f.input ?? a.Input ?? Sz;
  return /* @__PURE__ */ P(Rf, {
    slots: {
      root: y,
      input: S
    },
    slotProps: g,
    fullWidth: s,
    inputComponent: l,
    multiline: c,
    ref: r,
    type: d,
    ...p,
    classes: h
  });
});
Tf.muiName = "Input";
function wz(e) {
  return Be("MuiFilledInput", e);
}
const mo = {
  ...Ca,
  ...De("MuiFilledInput", ["root", "underline", "input", "adornedStart", "adornedEnd", "sizeSmall", "multiline", "hiddenLabel"])
}, Cz = (e) => {
  const {
    classes: t,
    disableUnderline: r,
    startAdornment: n,
    endAdornment: o,
    size: a,
    hiddenLabel: i,
    multiline: s
  } = e, l = {
    root: ["root", !r && "underline", n && "adornedStart", o && "adornedEnd", a === "small" && `size${$e(a)}`, i && "hiddenLabel", s && "multiline"],
    input: ["input"]
  }, c = ze(l, wz, t);
  return {
    ...t,
    // forward classes to the InputBase
    ...c
  };
}, Ez = de(Ec, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiFilledInput",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [...wc(e, t), !r.disableUnderline && t.underline];
  }
})(je(({
  theme: e
}) => {
  const t = e.palette.mode === "light", r = t ? "rgba(0, 0, 0, 0.42)" : "rgba(255, 255, 255, 0.7)", n = t ? "rgba(0, 0, 0, 0.06)" : "rgba(255, 255, 255, 0.09)", o = t ? "rgba(0, 0, 0, 0.09)" : "rgba(255, 255, 255, 0.13)", a = t ? "rgba(0, 0, 0, 0.12)" : "rgba(255, 255, 255, 0.12)";
  return {
    position: "relative",
    backgroundColor: e.vars ? e.vars.palette.FilledInput.bg : n,
    borderTopLeftRadius: (e.vars || e).shape.borderRadius,
    borderTopRightRadius: (e.vars || e).shape.borderRadius,
    transition: e.transitions.create("background-color", {
      duration: e.transitions.duration.shorter,
      easing: e.transitions.easing.easeOut
    }),
    "&:hover": {
      backgroundColor: e.vars ? e.vars.palette.FilledInput.hoverBg : o,
      // Reset on touch devices, it doesn't add specificity
      "@media (hover: none)": {
        backgroundColor: e.vars ? e.vars.palette.FilledInput.bg : n
      }
    },
    [`&.${mo.focused}`]: {
      backgroundColor: e.vars ? e.vars.palette.FilledInput.bg : n
    },
    [`&.${mo.disabled}`]: {
      backgroundColor: e.vars ? e.vars.palette.FilledInput.disabledBg : a
    },
    variants: [{
      props: ({
        ownerState: i
      }) => !i.disableUnderline,
      style: {
        "&::after": {
          left: 0,
          bottom: 0,
          content: '""',
          position: "absolute",
          right: 0,
          transform: "scaleX(0)",
          transition: e.transitions.create("transform", {
            duration: e.transitions.duration.shorter,
            easing: e.transitions.easing.easeOut
          }),
          pointerEvents: "none"
          // Transparent to the hover style.
        },
        [`&.${mo.focused}:after`]: {
          // translateX(0) is a workaround for Safari transform scale bug
          // See https://github.com/mui/material-ui/issues/31766
          transform: "scaleX(1) translateX(0)"
        },
        [`&.${mo.error}`]: {
          "&::before, &::after": {
            borderBottomColor: (e.vars || e).palette.error.main
          }
        },
        "&::before": {
          borderBottom: `1px solid ${e.vars ? `rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})` : r}`,
          left: 0,
          bottom: 0,
          content: '"\\00a0"',
          position: "absolute",
          right: 0,
          transition: e.transitions.create("border-bottom-color", {
            duration: e.transitions.duration.shorter
          }),
          pointerEvents: "none"
          // Transparent to the hover style.
        },
        [`&:hover:not(.${mo.disabled}, .${mo.error}):before`]: {
          borderBottom: `1px solid ${(e.vars || e).palette.text.primary}`
        },
        [`&.${mo.disabled}:before`]: {
          borderBottomStyle: "dotted"
        }
      }
    }, ...Object.entries(e.palette).filter(zt()).map(([i]) => {
      var s;
      return {
        props: {
          disableUnderline: !1,
          color: i
        },
        style: {
          "&::after": {
            borderBottom: `2px solid ${(s = (e.vars || e).palette[i]) == null ? void 0 : s.main}`
          }
        }
      };
    }), {
      props: ({
        ownerState: i
      }) => i.startAdornment,
      style: {
        paddingLeft: 12
      }
    }, {
      props: ({
        ownerState: i
      }) => i.endAdornment,
      style: {
        paddingRight: 12
      }
    }, {
      props: ({
        ownerState: i
      }) => i.multiline,
      style: {
        padding: "25px 12px 8px"
      }
    }, {
      props: ({
        ownerState: i,
        size: s
      }) => i.multiline && s === "small",
      style: {
        paddingTop: 21,
        paddingBottom: 4
      }
    }, {
      props: ({
        ownerState: i
      }) => i.multiline && i.hiddenLabel,
      style: {
        paddingTop: 16,
        paddingBottom: 17
      }
    }, {
      props: ({
        ownerState: i
      }) => i.multiline && i.hiddenLabel && i.size === "small",
      style: {
        paddingTop: 8,
        paddingBottom: 9
      }
    }]
  };
})), _z = de(_c, {
  name: "MuiFilledInput",
  slot: "Input",
  overridesResolver: Cc
})(je(({
  theme: e
}) => ({
  paddingTop: 25,
  paddingRight: 12,
  paddingBottom: 8,
  paddingLeft: 12,
  ...!e.vars && {
    "&:-webkit-autofill": {
      WebkitBoxShadow: e.palette.mode === "light" ? null : "0 0 0 100px #266798 inset",
      WebkitTextFillColor: e.palette.mode === "light" ? null : "#fff",
      caretColor: e.palette.mode === "light" ? null : "#fff",
      borderTopLeftRadius: "inherit",
      borderTopRightRadius: "inherit"
    }
  },
  ...e.vars && {
    "&:-webkit-autofill": {
      borderTopLeftRadius: "inherit",
      borderTopRightRadius: "inherit"
    },
    [e.getColorSchemeSelector("dark")]: {
      "&:-webkit-autofill": {
        WebkitBoxShadow: "0 0 0 100px #266798 inset",
        WebkitTextFillColor: "#fff",
        caretColor: "#fff"
      }
    }
  },
  variants: [{
    props: {
      size: "small"
    },
    style: {
      paddingTop: 21,
      paddingBottom: 4
    }
  }, {
    props: ({
      ownerState: t
    }) => t.hiddenLabel,
    style: {
      paddingTop: 16,
      paddingBottom: 17
    }
  }, {
    props: ({
      ownerState: t
    }) => t.startAdornment,
    style: {
      paddingLeft: 0
    }
  }, {
    props: ({
      ownerState: t
    }) => t.endAdornment,
    style: {
      paddingRight: 0
    }
  }, {
    props: ({
      ownerState: t
    }) => t.hiddenLabel && t.size === "small",
    style: {
      paddingTop: 8,
      paddingBottom: 9
    }
  }, {
    props: ({
      ownerState: t
    }) => t.multiline,
    style: {
      paddingTop: 0,
      paddingBottom: 0,
      paddingLeft: 0,
      paddingRight: 0
    }
  }]
}))), Mf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFilledInput"
  }), {
    disableUnderline: o = !1,
    components: a = {},
    componentsProps: i,
    fullWidth: s = !1,
    hiddenLabel: l,
    // declare here to prevent spreading to DOM
    inputComponent: c = "input",
    multiline: u = !1,
    slotProps: f,
    slots: d = {},
    type: p = "text",
    ...h
  } = n, $ = {
    ...n,
    disableUnderline: o,
    fullWidth: s,
    inputComponent: c,
    multiline: u,
    type: p
  }, b = Cz(n), g = {
    root: {
      ownerState: $
    },
    input: {
      ownerState: $
    }
  }, y = f ?? i ? lr(g, f ?? i) : g, S = d.root ?? a.Root ?? Ez, m = d.input ?? a.Input ?? _z;
  return /* @__PURE__ */ P(Rf, {
    slots: {
      root: S,
      input: m
    },
    slotProps: y,
    fullWidth: s,
    inputComponent: c,
    multiline: u,
    ref: r,
    type: p,
    ...h,
    classes: b
  });
});
Mf.muiName = "Input";
var og;
const xz = de("fieldset", {
  shouldForwardProp: cr
})({
  textAlign: "left",
  position: "absolute",
  bottom: 0,
  right: 0,
  top: -5,
  left: 0,
  margin: 0,
  padding: "0 8px",
  pointerEvents: "none",
  borderRadius: "inherit",
  borderStyle: "solid",
  borderWidth: 1,
  overflow: "hidden",
  minWidth: "0%"
}), Pz = de("legend", {
  shouldForwardProp: cr
})(je(({
  theme: e
}) => ({
  float: "unset",
  // Fix conflict with bootstrap
  width: "auto",
  // Fix conflict with bootstrap
  overflow: "hidden",
  // Fix Horizontal scroll when label too long
  variants: [{
    props: ({
      ownerState: t
    }) => !t.withLabel,
    style: {
      padding: 0,
      lineHeight: "11px",
      // sync with `height` in `legend` styles
      transition: e.transitions.create("width", {
        duration: 150,
        easing: e.transitions.easing.easeOut
      })
    }
  }, {
    props: ({
      ownerState: t
    }) => t.withLabel,
    style: {
      display: "block",
      // Fix conflict with normalize.css and sanitize.css
      padding: 0,
      height: 11,
      // sync with `lineHeight` in `legend` styles
      fontSize: "0.75em",
      visibility: "hidden",
      maxWidth: 0.01,
      transition: e.transitions.create("max-width", {
        duration: 50,
        easing: e.transitions.easing.easeOut
      }),
      whiteSpace: "nowrap",
      "& > span": {
        paddingLeft: 5,
        paddingRight: 5,
        display: "inline-block",
        opacity: 0,
        visibility: "visible"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.withLabel && t.notched,
    style: {
      maxWidth: "100%",
      transition: e.transitions.create("max-width", {
        duration: 100,
        easing: e.transitions.easing.easeOut,
        delay: 50
      })
    }
  }]
})));
function kz(e) {
  const {
    children: t,
    classes: r,
    className: n,
    label: o,
    notched: a,
    ...i
  } = e, s = o != null && o !== "", l = {
    ...e,
    notched: a,
    withLabel: s
  };
  return /* @__PURE__ */ P(xz, {
    "aria-hidden": !0,
    className: n,
    ownerState: l,
    ...i,
    children: /* @__PURE__ */ P(Pz, {
      ownerState: l,
      children: s ? /* @__PURE__ */ P("span", {
        children: o
      }) : (
        // notranslate needed while Google Translate will not fix zero-width space issue
        og || (og = /* @__PURE__ */ P("span", {
          className: "notranslate",
          "aria-hidden": !0,
          children: "​"
        }))
      )
    })
  });
}
function Oz(e) {
  return Be("MuiOutlinedInput", e);
}
const an = {
  ...Ca,
  ...De("MuiOutlinedInput", ["root", "notchedOutline", "input"])
}, Az = (e) => {
  const {
    classes: t
  } = e, n = ze({
    root: ["root"],
    notchedOutline: ["notchedOutline"],
    input: ["input"]
  }, Oz, t);
  return {
    ...t,
    // forward classes to the InputBase
    ...n
  };
}, Iz = de(Ec, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiOutlinedInput",
  slot: "Root",
  overridesResolver: wc
})(je(({
  theme: e
}) => {
  const t = e.palette.mode === "light" ? "rgba(0, 0, 0, 0.23)" : "rgba(255, 255, 255, 0.23)";
  return {
    position: "relative",
    borderRadius: (e.vars || e).shape.borderRadius,
    [`&:hover .${an.notchedOutline}`]: {
      borderColor: (e.vars || e).palette.text.primary
    },
    // Reset on touch devices, it doesn't add specificity
    "@media (hover: none)": {
      [`&:hover .${an.notchedOutline}`]: {
        borderColor: e.vars ? `rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)` : t
      }
    },
    [`&.${an.focused} .${an.notchedOutline}`]: {
      borderWidth: 2
    },
    variants: [...Object.entries(e.palette).filter(zt()).map(([r]) => ({
      props: {
        color: r
      },
      style: {
        [`&.${an.focused} .${an.notchedOutline}`]: {
          borderColor: (e.vars || e).palette[r].main
        }
      }
    })), {
      props: {},
      // to overide the above style
      style: {
        [`&.${an.error} .${an.notchedOutline}`]: {
          borderColor: (e.vars || e).palette.error.main
        },
        [`&.${an.disabled} .${an.notchedOutline}`]: {
          borderColor: (e.vars || e).palette.action.disabled
        }
      }
    }, {
      props: ({
        ownerState: r
      }) => r.startAdornment,
      style: {
        paddingLeft: 14
      }
    }, {
      props: ({
        ownerState: r
      }) => r.endAdornment,
      style: {
        paddingRight: 14
      }
    }, {
      props: ({
        ownerState: r
      }) => r.multiline,
      style: {
        padding: "16.5px 14px"
      }
    }, {
      props: ({
        ownerState: r,
        size: n
      }) => r.multiline && n === "small",
      style: {
        padding: "8.5px 14px"
      }
    }]
  };
})), Rz = de(kz, {
  name: "MuiOutlinedInput",
  slot: "NotchedOutline",
  overridesResolver: (e, t) => t.notchedOutline
})(je(({
  theme: e
}) => {
  const t = e.palette.mode === "light" ? "rgba(0, 0, 0, 0.23)" : "rgba(255, 255, 255, 0.23)";
  return {
    borderColor: e.vars ? `rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)` : t
  };
})), Tz = de(_c, {
  name: "MuiOutlinedInput",
  slot: "Input",
  overridesResolver: Cc
})(je(({
  theme: e
}) => ({
  padding: "16.5px 14px",
  ...!e.vars && {
    "&:-webkit-autofill": {
      WebkitBoxShadow: e.palette.mode === "light" ? null : "0 0 0 100px #266798 inset",
      WebkitTextFillColor: e.palette.mode === "light" ? null : "#fff",
      caretColor: e.palette.mode === "light" ? null : "#fff",
      borderRadius: "inherit"
    }
  },
  ...e.vars && {
    "&:-webkit-autofill": {
      borderRadius: "inherit"
    },
    [e.getColorSchemeSelector("dark")]: {
      "&:-webkit-autofill": {
        WebkitBoxShadow: "0 0 0 100px #266798 inset",
        WebkitTextFillColor: "#fff",
        caretColor: "#fff"
      }
    }
  },
  variants: [{
    props: {
      size: "small"
    },
    style: {
      padding: "8.5px 14px"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.multiline,
    style: {
      padding: 0
    }
  }, {
    props: ({
      ownerState: t
    }) => t.startAdornment,
    style: {
      paddingLeft: 0
    }
  }, {
    props: ({
      ownerState: t
    }) => t.endAdornment,
    style: {
      paddingRight: 0
    }
  }]
}))), Nf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  var n;
  const o = Ke({
    props: t,
    name: "MuiOutlinedInput"
  }), {
    components: a = {},
    fullWidth: i = !1,
    inputComponent: s = "input",
    label: l,
    multiline: c = !1,
    notched: u,
    slots: f = {},
    type: d = "text",
    ...p
  } = o, h = Az(o), $ = Sn(), b = po({
    props: o,
    muiFormControl: $,
    states: ["color", "disabled", "error", "focused", "hiddenLabel", "size", "required"]
  }), g = {
    ...o,
    color: b.color || "primary",
    disabled: b.disabled,
    error: b.error,
    focused: b.focused,
    formControl: $,
    fullWidth: i,
    hiddenLabel: b.hiddenLabel,
    multiline: c,
    size: b.size,
    type: d
  }, y = f.root ?? a.Root ?? Iz, S = f.input ?? a.Input ?? Tz;
  return /* @__PURE__ */ P(Rf, {
    slots: {
      root: y,
      input: S
    },
    renderSuffix: (m) => /* @__PURE__ */ P(Rz, {
      ownerState: g,
      className: h.notchedOutline,
      label: l != null && l !== "" && b.required ? n || (n = /* @__PURE__ */ ue(M.Fragment, {
        children: [l, " ", "*"]
      })) : l,
      notched: typeof u < "u" ? u : !!(m.startAdornment || m.filled || m.focused)
    }),
    fullWidth: i,
    inputComponent: s,
    multiline: c,
    ref: r,
    type: d,
    ...p,
    classes: {
      ...h,
      notchedOutline: null
    }
  });
});
Nf.muiName = "Input";
function Mz(e) {
  return Be("MuiFormLabel", e);
}
const xi = De("MuiFormLabel", ["root", "colorSecondary", "focused", "disabled", "error", "filled", "required", "asterisk"]), Nz = (e) => {
  const {
    classes: t,
    color: r,
    focused: n,
    disabled: o,
    error: a,
    filled: i,
    required: s
  } = e, l = {
    root: ["root", `color${$e(r)}`, o && "disabled", a && "error", i && "filled", n && "focused", s && "required"],
    asterisk: ["asterisk", a && "error"]
  };
  return ze(l, Mz, t);
}, Fz = de("label", {
  name: "MuiFormLabel",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.color === "secondary" && t.colorSecondary, r.filled && t.filled];
  }
})(je(({
  theme: e
}) => ({
  color: (e.vars || e).palette.text.secondary,
  ...e.typography.body1,
  lineHeight: "1.4375em",
  padding: 0,
  position: "relative",
  variants: [...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      [`&.${xi.focused}`]: {
        color: (e.vars || e).palette[t].main
      }
    }
  })), {
    props: {},
    style: {
      [`&.${xi.disabled}`]: {
        color: (e.vars || e).palette.text.disabled
      },
      [`&.${xi.error}`]: {
        color: (e.vars || e).palette.error.main
      }
    }
  }]
}))), jz = de("span", {
  name: "MuiFormLabel",
  slot: "Asterisk",
  overridesResolver: (e, t) => t.asterisk
})(je(({
  theme: e
}) => ({
  [`&.${xi.error}`]: {
    color: (e.vars || e).palette.error.main
  }
}))), xc = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFormLabel"
  }), {
    children: o,
    className: a,
    color: i,
    component: s = "label",
    disabled: l,
    error: c,
    filled: u,
    focused: f,
    required: d,
    ...p
  } = n, h = Sn(), $ = po({
    props: n,
    muiFormControl: h,
    states: ["color", "required", "focused", "disabled", "error", "filled"]
  }), b = {
    ...n,
    color: $.color || "primary",
    component: s,
    disabled: $.disabled,
    error: $.error,
    filled: $.filled,
    focused: $.focused,
    required: $.required
  }, g = Nz(b);
  return /* @__PURE__ */ ue(Fz, {
    as: s,
    ownerState: b,
    className: Ee(g.root, a),
    ref: r,
    ...p,
    children: [o, $.required && /* @__PURE__ */ ue(jz, {
      ownerState: b,
      "aria-hidden": !0,
      className: g.asterisk,
      children: [" ", "*"]
    })]
  });
});
function Dz(e) {
  return Be("MuiInputLabel", e);
}
De("MuiInputLabel", ["root", "focused", "disabled", "error", "required", "asterisk", "formControl", "sizeSmall", "shrink", "animated", "standard", "filled", "outlined"]);
const Lz = (e) => {
  const {
    classes: t,
    formControl: r,
    size: n,
    shrink: o,
    disableAnimation: a,
    variant: i,
    required: s
  } = e, l = {
    root: ["root", r && "formControl", !a && "animated", o && "shrink", n && n !== "normal" && `size${$e(n)}`, i],
    asterisk: [s && "asterisk"]
  }, c = ze(l, Dz, t);
  return {
    ...t,
    // forward the focused, disabled, etc. classes to the FormLabel
    ...c
  };
}, Bz = de(xc, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiInputLabel",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [{
      [`& .${xi.asterisk}`]: t.asterisk
    }, t.root, r.formControl && t.formControl, r.size === "small" && t.sizeSmall, r.shrink && t.shrink, !r.disableAnimation && t.animated, r.focused && t.focused, t[r.variant]];
  }
})(je(({
  theme: e
}) => ({
  display: "block",
  transformOrigin: "top left",
  whiteSpace: "nowrap",
  overflow: "hidden",
  textOverflow: "ellipsis",
  maxWidth: "100%",
  variants: [{
    props: ({
      ownerState: t
    }) => t.formControl,
    style: {
      position: "absolute",
      left: 0,
      top: 0,
      // slight alteration to spec spacing to match visual spec result
      transform: "translate(0, 20px) scale(1)"
    }
  }, {
    props: {
      size: "small"
    },
    style: {
      // Compensation for the `Input.inputSizeSmall` style.
      transform: "translate(0, 17px) scale(1)"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.shrink,
    style: {
      transform: "translate(0, -1.5px) scale(0.75)",
      transformOrigin: "top left",
      maxWidth: "133%"
    }
  }, {
    props: ({
      ownerState: t
    }) => !t.disableAnimation,
    style: {
      transition: e.transitions.create(["color", "transform", "max-width"], {
        duration: e.transitions.duration.shorter,
        easing: e.transitions.easing.easeOut
      })
    }
  }, {
    props: {
      variant: "filled"
    },
    style: {
      // Chrome's autofill feature gives the input field a yellow background.
      // Since the input field is behind the label in the HTML tree,
      // the input field is drawn last and hides the label with an opaque background color.
      // zIndex: 1 will raise the label above opaque background-colors of input.
      zIndex: 1,
      pointerEvents: "none",
      transform: "translate(12px, 16px) scale(1)",
      maxWidth: "calc(100% - 24px)"
    }
  }, {
    props: {
      variant: "filled",
      size: "small"
    },
    style: {
      transform: "translate(12px, 13px) scale(1)"
    }
  }, {
    props: ({
      variant: t,
      ownerState: r
    }) => t === "filled" && r.shrink,
    style: {
      userSelect: "none",
      pointerEvents: "auto",
      transform: "translate(12px, 7px) scale(0.75)",
      maxWidth: "calc(133% - 24px)"
    }
  }, {
    props: ({
      variant: t,
      ownerState: r,
      size: n
    }) => t === "filled" && r.shrink && n === "small",
    style: {
      transform: "translate(12px, 4px) scale(0.75)"
    }
  }, {
    props: {
      variant: "outlined"
    },
    style: {
      // see comment above on filled.zIndex
      zIndex: 1,
      pointerEvents: "none",
      transform: "translate(14px, 16px) scale(1)",
      maxWidth: "calc(100% - 24px)"
    }
  }, {
    props: {
      variant: "outlined",
      size: "small"
    },
    style: {
      transform: "translate(14px, 9px) scale(1)"
    }
  }, {
    props: ({
      variant: t,
      ownerState: r
    }) => t === "outlined" && r.shrink,
    style: {
      userSelect: "none",
      pointerEvents: "auto",
      // Theoretically, we should have (8+5)*2/0.75 = 34px
      // but it feels a better when it bleeds a bit on the left, so 32px.
      maxWidth: "calc(133% - 32px)",
      transform: "translate(14px, -9px) scale(0.75)"
    }
  }]
}))), zz = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    name: "MuiInputLabel",
    props: t
  }), {
    disableAnimation: o = !1,
    margin: a,
    shrink: i,
    variant: s,
    className: l,
    ...c
  } = n, u = Sn();
  let f = i;
  typeof f > "u" && u && (f = u.filled || u.focused || u.adornedStart);
  const d = po({
    props: n,
    muiFormControl: u,
    states: ["size", "variant", "required", "focused"]
  }), p = {
    ...n,
    disableAnimation: o,
    formControl: u,
    shrink: f,
    size: d.size,
    variant: d.variant,
    required: d.required,
    focused: d.focused
  }, h = Lz(p);
  return /* @__PURE__ */ P(Bz, {
    "data-shrink": f,
    ref: r,
    className: Ee(h.root, l),
    ...c,
    ownerState: p,
    classes: h
  });
});
function Uz(e) {
  return Be("MuiFormControl", e);
}
De("MuiFormControl", ["root", "marginNone", "marginNormal", "marginDense", "fullWidth", "disabled"]);
const Vz = (e) => {
  const {
    classes: t,
    margin: r,
    fullWidth: n
  } = e, o = {
    root: ["root", r !== "none" && `margin${$e(r)}`, n && "fullWidth"]
  };
  return ze(o, Uz, t);
}, qz = de("div", {
  name: "MuiFormControl",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[`margin${$e(r.margin)}`], r.fullWidth && t.fullWidth];
  }
})({
  display: "inline-flex",
  flexDirection: "column",
  position: "relative",
  // Reset fieldset default style.
  minWidth: 0,
  padding: 0,
  margin: 0,
  border: 0,
  verticalAlign: "top",
  // Fix alignment issue on Safari.
  variants: [{
    props: {
      margin: "normal"
    },
    style: {
      marginTop: 16,
      marginBottom: 8
    }
  }, {
    props: {
      margin: "dense"
    },
    style: {
      marginTop: 8,
      marginBottom: 4
    }
  }, {
    props: {
      fullWidth: !0
    },
    style: {
      width: "100%"
    }
  }]
}), Sv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFormControl"
  }), {
    children: o,
    className: a,
    color: i = "primary",
    component: s = "div",
    disabled: l = !1,
    error: c = !1,
    focused: u,
    fullWidth: f = !1,
    hiddenLabel: d = !1,
    margin: p = "none",
    required: h = !1,
    size: $ = "medium",
    variant: b = "outlined",
    ...g
  } = n, y = {
    ...n,
    color: i,
    component: s,
    disabled: l,
    error: c,
    fullWidth: f,
    hiddenLabel: d,
    margin: p,
    required: h,
    size: $,
    variant: b
  }, S = Vz(y), [m, w] = M.useState(() => {
    let D = !1;
    return o && M.Children.forEach(o, (z) => {
      if (!Ci(z, ["Input", "Select"]))
        return;
      const L = Ci(z, ["Select"]) ? z.props.input : z;
      L && mz(L.props) && (D = !0);
    }), D;
  }), [v, E] = M.useState(() => {
    let D = !1;
    return o && M.Children.forEach(o, (z) => {
      Ci(z, ["Input", "Select"]) && (xl(z.props, !0) || xl(z.props.inputProps, !0)) && (D = !0);
    }), D;
  }), [I, R] = M.useState(!1);
  l && I && R(!1);
  const C = u !== void 0 && !l ? u : I;
  let T;
  M.useRef(!1);
  const F = M.useMemo(() => ({
    adornedStart: m,
    setAdornedStart: w,
    color: i,
    disabled: l,
    error: c,
    filled: v,
    focused: C,
    fullWidth: f,
    hiddenLabel: d,
    size: $,
    onBlur: () => {
      R(!1);
    },
    onEmpty: () => {
      E(!1);
    },
    onFilled: () => {
      E(!0);
    },
    onFocus: () => {
      R(!0);
    },
    registerEffect: T,
    required: h,
    variant: b
  }), [m, i, l, c, v, C, f, d, T, h, $, b]);
  return /* @__PURE__ */ P(If.Provider, {
    value: F,
    children: /* @__PURE__ */ P(qz, {
      as: s,
      ownerState: y,
      className: Ee(S.root, a),
      ref: r,
      ...g,
      children: o
    })
  });
});
function Wz(e) {
  return Be("MuiFormHelperText", e);
}
const ag = De("MuiFormHelperText", ["root", "error", "disabled", "sizeSmall", "sizeMedium", "contained", "focused", "filled", "required"]);
var ig;
const Kz = (e) => {
  const {
    classes: t,
    contained: r,
    size: n,
    disabled: o,
    error: a,
    filled: i,
    focused: s,
    required: l
  } = e, c = {
    root: ["root", o && "disabled", a && "error", n && `size${$e(n)}`, r && "contained", s && "focused", i && "filled", l && "required"]
  };
  return ze(c, Wz, t);
}, Gz = de("p", {
  name: "MuiFormHelperText",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.size && t[`size${$e(r.size)}`], r.contained && t.contained, r.filled && t.filled];
  }
})(je(({
  theme: e
}) => ({
  color: (e.vars || e).palette.text.secondary,
  ...e.typography.caption,
  textAlign: "left",
  marginTop: 3,
  marginRight: 0,
  marginBottom: 0,
  marginLeft: 0,
  [`&.${ag.disabled}`]: {
    color: (e.vars || e).palette.text.disabled
  },
  [`&.${ag.error}`]: {
    color: (e.vars || e).palette.error.main
  },
  variants: [{
    props: {
      size: "small"
    },
    style: {
      marginTop: 4
    }
  }, {
    props: ({
      ownerState: t
    }) => t.contained,
    style: {
      marginLeft: 14,
      marginRight: 14
    }
  }]
}))), Ff = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFormHelperText"
  }), {
    children: o,
    className: a,
    component: i = "p",
    disabled: s,
    error: l,
    filled: c,
    focused: u,
    margin: f,
    required: d,
    variant: p,
    ...h
  } = n, $ = Sn(), b = po({
    props: n,
    muiFormControl: $,
    states: ["variant", "size", "disabled", "error", "filled", "focused", "required"]
  }), g = {
    ...n,
    component: i,
    contained: b.variant === "filled" || b.variant === "outlined",
    variant: b.variant,
    size: b.size,
    disabled: b.disabled,
    error: b.error,
    filled: b.filled,
    focused: b.focused,
    required: b.required
  };
  delete g.ownerState;
  const y = Kz(g);
  return /* @__PURE__ */ P(Gz, {
    as: i,
    className: Ee(y.root, a),
    ref: r,
    ...h,
    ownerState: g,
    children: o === " " ? (
      // notranslate needed while Google Translate will not fix zero-width space issue
      ig || (ig = /* @__PURE__ */ P("span", {
        className: "notranslate",
        "aria-hidden": !0,
        children: "​"
      }))
    ) : o
  });
}), Mn = /* @__PURE__ */ M.createContext({});
function Hz(e) {
  return Be("MuiList", e);
}
De("MuiList", ["root", "padding", "dense", "subheader"]);
const Jz = (e) => {
  const {
    classes: t,
    disablePadding: r,
    dense: n,
    subheader: o
  } = e;
  return ze({
    root: ["root", !r && "padding", n && "dense", o && "subheader"]
  }, Hz, t);
}, Yz = de("ul", {
  name: "MuiList",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, !r.disablePadding && t.padding, r.dense && t.dense, r.subheader && t.subheader];
  }
})({
  listStyle: "none",
  margin: 0,
  padding: 0,
  position: "relative",
  variants: [{
    props: ({
      ownerState: e
    }) => !e.disablePadding,
    style: {
      paddingTop: 8,
      paddingBottom: 8
    }
  }, {
    props: ({
      ownerState: e
    }) => e.subheader,
    style: {
      paddingTop: 0
    }
  }]
}), jf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiList"
  }), {
    children: o,
    className: a,
    component: i = "ul",
    dense: s = !1,
    disablePadding: l = !1,
    subheader: c,
    ...u
  } = n, f = M.useMemo(() => ({
    dense: s
  }), [s]), d = {
    ...n,
    component: i,
    dense: s,
    disablePadding: l
  }, p = Jz(d);
  return /* @__PURE__ */ P(Mn.Provider, {
    value: f,
    children: /* @__PURE__ */ ue(Yz, {
      as: i,
      className: Ee(p.root, a),
      ref: r,
      ownerState: d,
      ...u,
      children: [c, o]
    })
  });
});
function uu(e, t, r) {
  return e === t ? e.firstChild : t && t.nextElementSibling ? t.nextElementSibling : r ? null : e.firstChild;
}
function sg(e, t, r) {
  return e === t ? r ? e.firstChild : e.lastChild : t && t.previousElementSibling ? t.previousElementSibling : r ? null : e.lastChild;
}
function wv(e, t) {
  if (t === void 0)
    return !0;
  let r = e.innerText;
  return r === void 0 && (r = e.textContent), r = r.trim().toLowerCase(), r.length === 0 ? !1 : t.repeating ? r[0] === t.keys[0] : r.startsWith(t.keys.join(""));
}
function li(e, t, r, n, o, a) {
  let i = !1, s = o(e, t, t ? r : !1);
  for (; s; ) {
    if (s === e.firstChild) {
      if (i)
        return !1;
      i = !0;
    }
    const l = n ? !1 : s.disabled || s.getAttribute("aria-disabled") === "true";
    if (!s.hasAttribute("tabindex") || !wv(s, a) || l)
      s = o(e, s, r);
    else
      return s.focus(), !0;
  }
  return !1;
}
const Xz = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    // private
    // eslint-disable-next-line react/prop-types
    actions: n,
    autoFocus: o = !1,
    autoFocusItem: a = !1,
    children: i,
    className: s,
    disabledItemsFocusable: l = !1,
    disableListWrap: c = !1,
    onKeyDown: u,
    variant: f = "selectedMenu",
    ...d
  } = t, p = M.useRef(null), h = M.useRef({
    keys: [],
    repeating: !0,
    previousKeyMatched: !0,
    lastTime: null
  });
  Bn(() => {
    o && p.current.focus();
  }, [o]), M.useImperativeHandle(n, () => ({
    adjustStyleForScrollbar: (S, {
      direction: m
    }) => {
      const w = !p.current.style.width;
      if (S.clientHeight < p.current.clientHeight && w) {
        const v = `${Fb(Ln(S))}px`;
        p.current.style[m === "rtl" ? "paddingLeft" : "paddingRight"] = v, p.current.style.width = `calc(100% + ${v})`;
      }
      return p.current;
    }
  }), []);
  const $ = (S) => {
    const m = p.current, w = S.key;
    if (S.ctrlKey || S.metaKey || S.altKey) {
      u && u(S);
      return;
    }
    const E = mr(m).activeElement;
    if (w === "ArrowDown")
      S.preventDefault(), li(m, E, c, l, uu);
    else if (w === "ArrowUp")
      S.preventDefault(), li(m, E, c, l, sg);
    else if (w === "Home")
      S.preventDefault(), li(m, null, c, l, uu);
    else if (w === "End")
      S.preventDefault(), li(m, null, c, l, sg);
    else if (w.length === 1) {
      const I = h.current, R = w.toLowerCase(), C = performance.now();
      I.keys.length > 0 && (C - I.lastTime > 500 ? (I.keys = [], I.repeating = !0, I.previousKeyMatched = !0) : I.repeating && R !== I.keys[0] && (I.repeating = !1)), I.lastTime = C, I.keys.push(R);
      const T = E && !I.repeating && wv(E, I);
      I.previousKeyMatched && (T || li(m, E, !1, l, uu, I)) ? S.preventDefault() : I.previousKeyMatched = !1;
    }
    u && u(S);
  }, b = Bt(p, r);
  let g = -1;
  M.Children.forEach(i, (S, m) => {
    if (!/* @__PURE__ */ M.isValidElement(S)) {
      g === m && (g += 1, g >= i.length && (g = -1));
      return;
    }
    S.props.disabled || (f === "selectedMenu" && S.props.selected || g === -1) && (g = m), g === m && (S.props.disabled || S.props.muiSkipListHighlight || S.type.muiSkipListHighlight) && (g += 1, g >= i.length && (g = -1));
  });
  const y = M.Children.map(i, (S, m) => {
    if (m === g) {
      const w = {};
      return a && (w.autoFocus = !0), S.props.tabIndex === void 0 && f === "selectedMenu" && (w.tabIndex = 0), /* @__PURE__ */ M.cloneElement(S, w);
    }
    return S;
  });
  return /* @__PURE__ */ P(jf, {
    role: "menu",
    ref: b,
    className: s,
    onKeyDown: $,
    tabIndex: o ? 0 : -1,
    ...d,
    children: y
  });
}), Cv = (e) => e.scrollTop;
function Ea(e, t) {
  const {
    timeout: r,
    easing: n,
    style: o = {}
  } = e;
  return {
    duration: o.transitionDuration ?? (typeof r == "number" ? r : r[t.mode] || 0),
    easing: o.transitionTimingFunction ?? (typeof n == "object" ? n[t.mode] : n),
    delay: o.transitionDelay
  };
}
function Ju(e) {
  return `scale(${e}, ${e ** 2})`;
}
const Zz = {
  entering: {
    opacity: 1,
    transform: Ju(1)
  },
  entered: {
    opacity: 1,
    transform: "none"
  }
}, du = typeof navigator < "u" && /^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent) && /(os |version\/)15(.|_)4/i.test(navigator.userAgent), Yu = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    addEndListener: n,
    appear: o = !0,
    children: a,
    easing: i,
    in: s,
    onEnter: l,
    onEntered: c,
    onEntering: u,
    onExit: f,
    onExited: d,
    onExiting: p,
    style: h,
    timeout: $ = "auto",
    // eslint-disable-next-line react/prop-types
    TransitionComponent: b = en,
    ...g
  } = t, y = pf(), S = M.useRef(), m = Ka(), w = M.useRef(null), v = Bt(w, ss(a), r), E = (L) => (X) => {
    if (L) {
      const V = w.current;
      X === void 0 ? L(V) : L(V, X);
    }
  }, I = E(u), R = E((L, X) => {
    Cv(L);
    const {
      duration: V,
      delay: ie,
      easing: Y
    } = Ea({
      style: h,
      timeout: $,
      easing: i
    }, {
      mode: "enter"
    });
    let H;
    $ === "auto" ? (H = m.transitions.getAutoHeightDuration(L.clientHeight), S.current = H) : H = V, L.style.transition = [m.transitions.create("opacity", {
      duration: H,
      delay: ie
    }), m.transitions.create("transform", {
      duration: du ? H : H * 0.666,
      delay: ie,
      easing: Y
    })].join(","), l && l(L, X);
  }), C = E(c), T = E(p), F = E((L) => {
    const {
      duration: X,
      delay: V,
      easing: ie
    } = Ea({
      style: h,
      timeout: $,
      easing: i
    }, {
      mode: "exit"
    });
    let Y;
    $ === "auto" ? (Y = m.transitions.getAutoHeightDuration(L.clientHeight), S.current = Y) : Y = X, L.style.transition = [m.transitions.create("opacity", {
      duration: Y,
      delay: V
    }), m.transitions.create("transform", {
      duration: du ? Y : Y * 0.666,
      delay: du ? V : V || Y * 0.333,
      easing: ie
    })].join(","), L.style.opacity = 0, L.style.transform = Ju(0.75), f && f(L);
  }), D = E(d);
  return /* @__PURE__ */ P(b, {
    appear: o,
    in: s,
    nodeRef: w,
    onEnter: R,
    onEntered: C,
    onEntering: I,
    onExit: F,
    onExited: D,
    onExiting: T,
    addEndListener: (L) => {
      $ === "auto" && y.start(S.current || 0, L), n && n(w.current, L);
    },
    timeout: $ === "auto" ? null : $,
    ...g,
    children: (L, {
      ownerState: X,
      ...V
    }) => /* @__PURE__ */ M.cloneElement(a, {
      style: {
        opacity: 0,
        transform: Ju(0.75),
        visibility: L === "exited" && !s ? "hidden" : void 0,
        ...Zz[L],
        ...h,
        ...a.props.style
      },
      ref: v,
      ...V
    })
  });
});
Yu && (Yu.muiSupportAuto = !0);
function Qz(e) {
  const t = mr(e);
  return t.body === e ? Ln(e).innerWidth > t.documentElement.clientWidth : e.scrollHeight > e.clientHeight;
}
function Pi(e, t) {
  t ? e.setAttribute("aria-hidden", "true") : e.removeAttribute("aria-hidden");
}
function lg(e) {
  return parseInt(Ln(e).getComputedStyle(e).paddingRight, 10) || 0;
}
function e7(e) {
  const r = ["TEMPLATE", "SCRIPT", "STYLE", "LINK", "MAP", "META", "NOSCRIPT", "PICTURE", "COL", "COLGROUP", "PARAM", "SLOT", "SOURCE", "TRACK"].includes(e.tagName), n = e.tagName === "INPUT" && e.getAttribute("type") === "hidden";
  return r || n;
}
function cg(e, t, r, n, o) {
  const a = [t, r, ...n];
  [].forEach.call(e.children, (i) => {
    const s = !a.includes(i), l = !e7(i);
    s && l && Pi(i, o);
  });
}
function fu(e, t) {
  let r = -1;
  return e.some((n, o) => t(n) ? (r = o, !0) : !1), r;
}
function t7(e, t) {
  const r = [], n = e.container;
  if (!t.disableScrollLock) {
    if (Qz(n)) {
      const i = Fb(Ln(n));
      r.push({
        value: n.style.paddingRight,
        property: "padding-right",
        el: n
      }), n.style.paddingRight = `${lg(n) + i}px`;
      const s = mr(n).querySelectorAll(".mui-fixed");
      [].forEach.call(s, (l) => {
        r.push({
          value: l.style.paddingRight,
          property: "padding-right",
          el: l
        }), l.style.paddingRight = `${lg(l) + i}px`;
      });
    }
    let a;
    if (n.parentNode instanceof DocumentFragment)
      a = mr(n).body;
    else {
      const i = n.parentElement, s = Ln(n);
      a = (i == null ? void 0 : i.nodeName) === "HTML" && s.getComputedStyle(i).overflowY === "scroll" ? i : n;
    }
    r.push({
      value: a.style.overflow,
      property: "overflow",
      el: a
    }, {
      value: a.style.overflowX,
      property: "overflow-x",
      el: a
    }, {
      value: a.style.overflowY,
      property: "overflow-y",
      el: a
    }), a.style.overflow = "hidden";
  }
  return () => {
    r.forEach(({
      value: a,
      el: i,
      property: s
    }) => {
      a ? i.style.setProperty(s, a) : i.style.removeProperty(s);
    });
  };
}
function r7(e) {
  const t = [];
  return [].forEach.call(e.children, (r) => {
    r.getAttribute("aria-hidden") === "true" && t.push(r);
  }), t;
}
class n7 {
  constructor() {
    this.modals = [], this.containers = [];
  }
  add(t, r) {
    let n = this.modals.indexOf(t);
    if (n !== -1)
      return n;
    n = this.modals.length, this.modals.push(t), t.modalRef && Pi(t.modalRef, !1);
    const o = r7(r);
    cg(r, t.mount, t.modalRef, o, !0);
    const a = fu(this.containers, (i) => i.container === r);
    return a !== -1 ? (this.containers[a].modals.push(t), n) : (this.containers.push({
      modals: [t],
      container: r,
      restore: null,
      hiddenSiblings: o
    }), n);
  }
  mount(t, r) {
    const n = fu(this.containers, (a) => a.modals.includes(t)), o = this.containers[n];
    o.restore || (o.restore = t7(o, r));
  }
  remove(t, r = !0) {
    const n = this.modals.indexOf(t);
    if (n === -1)
      return n;
    const o = fu(this.containers, (i) => i.modals.includes(t)), a = this.containers[o];
    if (a.modals.splice(a.modals.indexOf(t), 1), this.modals.splice(n, 1), a.modals.length === 0)
      a.restore && a.restore(), t.modalRef && Pi(t.modalRef, r), cg(a.container, t.mount, t.modalRef, a.hiddenSiblings, !1), this.containers.splice(o, 1);
    else {
      const i = a.modals[a.modals.length - 1];
      i.modalRef && Pi(i.modalRef, !1);
    }
    return n;
  }
  isTopModal(t) {
    return this.modals.length > 0 && this.modals[this.modals.length - 1] === t;
  }
}
const o7 = ["input", "select", "textarea", "a[href]", "button", "[tabindex]", "audio[controls]", "video[controls]", '[contenteditable]:not([contenteditable="false"])'].join(",");
function a7(e) {
  const t = parseInt(e.getAttribute("tabindex") || "", 10);
  return Number.isNaN(t) ? e.contentEditable === "true" || (e.nodeName === "AUDIO" || e.nodeName === "VIDEO" || e.nodeName === "DETAILS") && e.getAttribute("tabindex") === null ? 0 : e.tabIndex : t;
}
function i7(e) {
  if (e.tagName !== "INPUT" || e.type !== "radio" || !e.name)
    return !1;
  const t = (n) => e.ownerDocument.querySelector(`input[type="radio"]${n}`);
  let r = t(`[name="${e.name}"]:checked`);
  return r || (r = t(`[name="${e.name}"]`)), r !== e;
}
function s7(e) {
  return !(e.disabled || e.tagName === "INPUT" && e.type === "hidden" || i7(e));
}
function l7(e) {
  const t = [], r = [];
  return Array.from(e.querySelectorAll(o7)).forEach((n, o) => {
    const a = a7(n);
    a === -1 || !s7(n) || (a === 0 ? t.push(n) : r.push({
      documentOrder: o,
      tabIndex: a,
      node: n
    }));
  }), r.sort((n, o) => n.tabIndex === o.tabIndex ? n.documentOrder - o.documentOrder : n.tabIndex - o.tabIndex).map((n) => n.node).concat(t);
}
function c7() {
  return !0;
}
function u7(e) {
  const {
    children: t,
    disableAutoFocus: r = !1,
    disableEnforceFocus: n = !1,
    disableRestoreFocus: o = !1,
    getTabbable: a = l7,
    isEnabled: i = c7,
    open: s
  } = e, l = M.useRef(!1), c = M.useRef(null), u = M.useRef(null), f = M.useRef(null), d = M.useRef(null), p = M.useRef(!1), h = M.useRef(null), $ = Bt(ss(t), h), b = M.useRef(null);
  M.useEffect(() => {
    !s || !h.current || (p.current = !r);
  }, [r, s]), M.useEffect(() => {
    if (!s || !h.current)
      return;
    const S = mr(h.current);
    return h.current.contains(S.activeElement) || (h.current.hasAttribute("tabIndex") || h.current.setAttribute("tabIndex", "-1"), p.current && h.current.focus()), () => {
      o || (f.current && f.current.focus && (l.current = !0, f.current.focus()), f.current = null);
    };
  }, [s]), M.useEffect(() => {
    if (!s || !h.current)
      return;
    const S = mr(h.current), m = (E) => {
      b.current = E, !(n || !i() || E.key !== "Tab") && S.activeElement === h.current && E.shiftKey && (l.current = !0, u.current && u.current.focus());
    }, w = () => {
      var R, C;
      const E = h.current;
      if (E === null)
        return;
      if (!S.hasFocus() || !i() || l.current) {
        l.current = !1;
        return;
      }
      if (E.contains(S.activeElement) || n && S.activeElement !== c.current && S.activeElement !== u.current)
        return;
      if (S.activeElement !== d.current)
        d.current = null;
      else if (d.current !== null)
        return;
      if (!p.current)
        return;
      let I = [];
      if ((S.activeElement === c.current || S.activeElement === u.current) && (I = a(h.current)), I.length > 0) {
        const T = !!((R = b.current) != null && R.shiftKey && ((C = b.current) == null ? void 0 : C.key) === "Tab"), F = I[0], D = I[I.length - 1];
        typeof F != "string" && typeof D != "string" && (T ? D.focus() : F.focus());
      } else
        E.focus();
    };
    S.addEventListener("focusin", w), S.addEventListener("keydown", m, !0);
    const v = setInterval(() => {
      S.activeElement && S.activeElement.tagName === "BODY" && w();
    }, 50);
    return () => {
      clearInterval(v), S.removeEventListener("focusin", w), S.removeEventListener("keydown", m, !0);
    };
  }, [r, n, o, i, s, a]);
  const g = (S) => {
    f.current === null && (f.current = S.relatedTarget), p.current = !0, d.current = S.target;
    const m = t.props.onFocus;
    m && m(S);
  }, y = (S) => {
    f.current === null && (f.current = S.relatedTarget), p.current = !0;
  };
  return /* @__PURE__ */ ue(M.Fragment, {
    children: [/* @__PURE__ */ P("div", {
      tabIndex: s ? 0 : -1,
      onFocus: y,
      ref: c,
      "data-testid": "sentinelStart"
    }), /* @__PURE__ */ M.cloneElement(t, {
      ref: $,
      onFocus: g
    }), /* @__PURE__ */ P("div", {
      tabIndex: s ? 0 : -1,
      onFocus: y,
      ref: u,
      "data-testid": "sentinelEnd"
    })]
  });
}
function d7(e) {
  return typeof e == "function" ? e() : e;
}
const f7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    children: n,
    container: o,
    disablePortal: a = !1
  } = t, [i, s] = M.useState(null), l = Bt(/* @__PURE__ */ M.isValidElement(n) ? ss(n) : null, r);
  if (Bn(() => {
    a || s(d7(o) || document.body);
  }, [o, a]), Bn(() => {
    if (i && !a)
      return Em(r, i), () => {
        Em(r, null);
      };
  }, [r, i, a]), a) {
    if (/* @__PURE__ */ M.isValidElement(n)) {
      const c = {
        ref: l
      };
      return /* @__PURE__ */ M.cloneElement(n, c);
    }
    return n;
  }
  return i && /* @__PURE__ */ g$.createPortal(n, i);
});
function Sr(e, t) {
  const {
    className: r,
    elementType: n,
    ownerState: o,
    externalForwardedProps: a,
    internalForwardedProps: i,
    ...s
  } = t, {
    component: l,
    slots: c = {
      [e]: void 0
    },
    slotProps: u = {
      [e]: void 0
    },
    ...f
  } = a, d = c[e] || n, p = zb(u[e], o), {
    props: {
      component: h,
      ...$
    },
    internalRef: b
  } = Bb({
    className: r,
    ...s,
    externalForwardedProps: e === "root" ? f : void 0,
    externalSlotProps: p
  }), g = Bt(b, p == null ? void 0 : p.ref, t.ref), y = e === "root" ? h || l : h, S = Db(d, {
    ...e === "root" && !l && !c[e] && i,
    ...e !== "root" && !c[e] && i,
    ...$,
    ...y && {
      as: y
    },
    ref: g
  }, o);
  return [d, S];
}
const p7 = {
  entering: {
    opacity: 1
  },
  entered: {
    opacity: 1
  }
}, h7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ka(), o = {
    enter: n.transitions.duration.enteringScreen,
    exit: n.transitions.duration.leavingScreen
  }, {
    addEndListener: a,
    appear: i = !0,
    children: s,
    easing: l,
    in: c,
    onEnter: u,
    onEntered: f,
    onEntering: d,
    onExit: p,
    onExited: h,
    onExiting: $,
    style: b,
    timeout: g = o,
    // eslint-disable-next-line react/prop-types
    TransitionComponent: y = en,
    ...S
  } = t, m = M.useRef(null), w = Bt(m, ss(s), r), v = (z) => (L) => {
    if (z) {
      const X = m.current;
      L === void 0 ? z(X) : z(X, L);
    }
  }, E = v(d), I = v((z, L) => {
    Cv(z);
    const X = Ea({
      style: b,
      timeout: g,
      easing: l
    }, {
      mode: "enter"
    });
    z.style.webkitTransition = n.transitions.create("opacity", X), z.style.transition = n.transitions.create("opacity", X), u && u(z, L);
  }), R = v(f), C = v($), T = v((z) => {
    const L = Ea({
      style: b,
      timeout: g,
      easing: l
    }, {
      mode: "exit"
    });
    z.style.webkitTransition = n.transitions.create("opacity", L), z.style.transition = n.transitions.create("opacity", L), p && p(z);
  }), F = v(h);
  return /* @__PURE__ */ P(y, {
    appear: i,
    in: c,
    nodeRef: m,
    onEnter: I,
    onEntered: R,
    onEntering: E,
    onExit: T,
    onExited: F,
    onExiting: C,
    addEndListener: (z) => {
      a && a(m.current, z);
    },
    timeout: g,
    ...S,
    children: (z, {
      ownerState: L,
      ...X
    }) => /* @__PURE__ */ M.cloneElement(s, {
      style: {
        opacity: 0,
        visibility: z === "exited" && !c ? "hidden" : void 0,
        ...p7[z],
        ...b,
        ...s.props.style
      },
      ref: w,
      ...X
    })
  });
});
function m7(e) {
  return Be("MuiBackdrop", e);
}
De("MuiBackdrop", ["root", "invisible"]);
const g7 = (e) => {
  const {
    classes: t,
    invisible: r
  } = e;
  return ze({
    root: ["root", r && "invisible"]
  }, m7, t);
}, y7 = de("div", {
  name: "MuiBackdrop",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.invisible && t.invisible];
  }
})({
  position: "fixed",
  display: "flex",
  alignItems: "center",
  justifyContent: "center",
  right: 0,
  bottom: 0,
  top: 0,
  left: 0,
  backgroundColor: "rgba(0, 0, 0, 0.5)",
  WebkitTapHighlightColor: "transparent",
  variants: [{
    props: {
      invisible: !0
    },
    style: {
      backgroundColor: "transparent"
    }
  }]
}), b7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiBackdrop"
  }), {
    children: o,
    className: a,
    component: i = "div",
    invisible: s = !1,
    open: l,
    components: c = {},
    componentsProps: u = {},
    slotProps: f = {},
    slots: d = {},
    TransitionComponent: p,
    transitionDuration: h,
    ...$
  } = n, b = {
    ...n,
    component: i,
    invisible: s
  }, g = g7(b), y = {
    transition: p,
    root: c.Root,
    ...d
  }, S = {
    ...u,
    ...f
  }, m = {
    slots: y,
    slotProps: S
  }, [w, v] = Sr("root", {
    elementType: y7,
    externalForwardedProps: m,
    className: Ee(g.root, a),
    ownerState: b
  }), [E, I] = Sr("transition", {
    elementType: h7,
    externalForwardedProps: m,
    ownerState: b
  });
  return /* @__PURE__ */ P(E, {
    in: l,
    timeout: h,
    ...$,
    ...I,
    children: /* @__PURE__ */ P(w, {
      "aria-hidden": !0,
      ...v,
      classes: g,
      ref: r,
      children: o
    })
  });
});
function v7(e) {
  return typeof e == "function" ? e() : e;
}
function $7(e) {
  return e ? e.props.hasOwnProperty("in") : !1;
}
const ug = () => {
}, Ts = new n7();
function S7(e) {
  const {
    container: t,
    disableEscapeKeyDown: r = !1,
    disableScrollLock: n = !1,
    closeAfterTransition: o = !1,
    onTransitionEnter: a,
    onTransitionExited: i,
    children: s,
    onClose: l,
    open: c,
    rootRef: u
  } = e, f = M.useRef({}), d = M.useRef(null), p = M.useRef(null), h = Bt(p, u), [$, b] = M.useState(!c), g = $7(s);
  let y = !0;
  (e["aria-hidden"] === "false" || e["aria-hidden"] === !1) && (y = !1);
  const S = () => mr(d.current), m = () => (f.current.modalRef = p.current, f.current.mount = d.current, f.current), w = () => {
    Ts.mount(m(), {
      disableScrollLock: n
    }), p.current && (p.current.scrollTop = 0);
  }, v = Rn(() => {
    const L = v7(t) || S().body;
    Ts.add(m(), L), p.current && w();
  }), E = () => Ts.isTopModal(m()), I = Rn((L) => {
    d.current = L, L && (c && E() ? w() : p.current && Pi(p.current, y));
  }), R = M.useCallback(() => {
    Ts.remove(m(), y);
  }, [y]);
  M.useEffect(() => () => {
    R();
  }, [R]), M.useEffect(() => {
    c ? v() : (!g || !o) && R();
  }, [c, R, g, o, v]);
  const C = (L) => (X) => {
    var V;
    (V = L.onKeyDown) == null || V.call(L, X), !(X.key !== "Escape" || X.which === 229 || // Wait until IME is settled.
    !E()) && (r || (X.stopPropagation(), l && l(X, "escapeKeyDown")));
  }, T = (L) => (X) => {
    var V;
    (V = L.onClick) == null || V.call(L, X), X.target === X.currentTarget && l && l(X, "backdropClick");
  };
  return {
    getRootProps: (L = {}) => {
      const X = Ei(e);
      delete X.onTransitionEnter, delete X.onTransitionExited;
      const V = {
        ...X,
        ...L
      };
      return {
        /*
         * Marking an element with the role presentation indicates to assistive technology
         * that this element should be ignored; it exists to support the web application and
         * is not meant for humans to interact with directly.
         * https://github.com/evcohen/eslint-plugin-jsx-a11y/blob/master/docs/rules/no-static-element-interactions.md
         */
        role: "presentation",
        ...V,
        onKeyDown: C(V),
        ref: h
      };
    },
    getBackdropProps: (L = {}) => {
      const X = L;
      return {
        "aria-hidden": !0,
        ...X,
        onClick: T(X),
        open: c
      };
    },
    getTransitionProps: () => {
      const L = () => {
        b(!1), a && a();
      }, X = () => {
        b(!0), i && i(), o && R();
      };
      return {
        onEnter: ju(L, (s == null ? void 0 : s.props.onEnter) ?? ug),
        onExited: ju(X, (s == null ? void 0 : s.props.onExited) ?? ug)
      };
    },
    rootRef: h,
    portalRef: I,
    isTopModal: E,
    exited: $,
    hasTransition: g
  };
}
function w7(e) {
  return Be("MuiModal", e);
}
De("MuiModal", ["root", "hidden", "backdrop"]);
const C7 = (e) => {
  const {
    open: t,
    exited: r,
    classes: n
  } = e;
  return ze({
    root: ["root", !t && r && "hidden"],
    backdrop: ["backdrop"]
  }, w7, n);
}, E7 = de("div", {
  name: "MuiModal",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, !r.open && r.exited && t.hidden];
  }
})(je(({
  theme: e
}) => ({
  position: "fixed",
  zIndex: (e.vars || e).zIndex.modal,
  right: 0,
  bottom: 0,
  top: 0,
  left: 0,
  variants: [{
    props: ({
      ownerState: t
    }) => !t.open && t.exited,
    style: {
      visibility: "hidden"
    }
  }]
}))), _7 = de(b7, {
  name: "MuiModal",
  slot: "Backdrop",
  overridesResolver: (e, t) => t.backdrop
})({
  zIndex: -1
}), x7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    name: "MuiModal",
    props: t
  }), {
    BackdropComponent: o = _7,
    BackdropProps: a,
    classes: i,
    className: s,
    closeAfterTransition: l = !1,
    children: c,
    container: u,
    component: f,
    components: d = {},
    componentsProps: p = {},
    disableAutoFocus: h = !1,
    disableEnforceFocus: $ = !1,
    disableEscapeKeyDown: b = !1,
    disablePortal: g = !1,
    disableRestoreFocus: y = !1,
    disableScrollLock: S = !1,
    hideBackdrop: m = !1,
    keepMounted: w = !1,
    onBackdropClick: v,
    onClose: E,
    onTransitionEnter: I,
    onTransitionExited: R,
    open: C,
    slotProps: T = {},
    slots: F = {},
    // eslint-disable-next-line react/prop-types
    theme: D,
    ...z
  } = n, L = {
    ...n,
    closeAfterTransition: l,
    disableAutoFocus: h,
    disableEnforceFocus: $,
    disableEscapeKeyDown: b,
    disablePortal: g,
    disableRestoreFocus: y,
    disableScrollLock: S,
    hideBackdrop: m,
    keepMounted: w
  }, {
    getRootProps: X,
    getBackdropProps: V,
    getTransitionProps: ie,
    portalRef: Y,
    isTopModal: H,
    exited: j,
    hasTransition: Q
  } = S7({
    ...L,
    rootRef: r
  }), q = {
    ...L,
    exited: j
  }, O = C7(q), N = {};
  if (c.props.tabIndex === void 0 && (N.tabIndex = "-1"), Q) {
    const {
      onEnter: _e,
      onExited: Me
    } = ie();
    N.onEnter = _e, N.onExited = Me;
  }
  const W = {
    ...z,
    slots: {
      root: d.Root,
      backdrop: d.Backdrop,
      ...F
    },
    slotProps: {
      ...p,
      ...T
    }
  }, [ne, ee] = Sr("root", {
    elementType: E7,
    externalForwardedProps: W,
    getSlotProps: X,
    additionalProps: {
      ref: r,
      as: f
    },
    ownerState: q,
    className: Ee(s, O == null ? void 0 : O.root, !q.open && q.exited && (O == null ? void 0 : O.hidden))
  }), [pe, ce] = Sr("backdrop", {
    elementType: o,
    externalForwardedProps: W,
    additionalProps: a,
    getSlotProps: (_e) => V({
      ..._e,
      onClick: (Me) => {
        v && v(Me), _e != null && _e.onClick && _e.onClick(Me);
      }
    }),
    className: Ee(a == null ? void 0 : a.className, O == null ? void 0 : O.backdrop),
    ownerState: q
  }), ye = Bt(a == null ? void 0 : a.ref, ce.ref);
  return !w && !C && (!Q || j) ? null : /* @__PURE__ */ P(f7, {
    ref: Y,
    container: u,
    disablePortal: g,
    children: /* @__PURE__ */ ue(ne, {
      ...ee,
      children: [!m && o ? /* @__PURE__ */ P(pe, {
        ...ce,
        ref: ye
      }) : null, /* @__PURE__ */ P(u7, {
        disableEnforceFocus: $,
        disableAutoFocus: h,
        disableRestoreFocus: y,
        isEnabled: H,
        open: C,
        children: /* @__PURE__ */ M.cloneElement(c, N)
      })]
    })
  });
});
function P7(e) {
  return Be("MuiPopover", e);
}
De("MuiPopover", ["root", "paper"]);
function dg(e, t) {
  let r = 0;
  return typeof t == "number" ? r = t : t === "center" ? r = e.height / 2 : t === "bottom" && (r = e.height), r;
}
function fg(e, t) {
  let r = 0;
  return typeof t == "number" ? r = t : t === "center" ? r = e.width / 2 : t === "right" && (r = e.width), r;
}
function pg(e) {
  return [e.horizontal, e.vertical].map((t) => typeof t == "number" ? `${t}px` : t).join(" ");
}
function pu(e) {
  return typeof e == "function" ? e() : e;
}
const k7 = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"],
    paper: ["paper"]
  }, P7, t);
}, O7 = de(x7, {
  name: "MuiPopover",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({}), Ev = de(Ga, {
  name: "MuiPopover",
  slot: "Paper",
  overridesResolver: (e, t) => t.paper
})({
  position: "absolute",
  overflowY: "auto",
  overflowX: "hidden",
  // So we see the popover when it's empty.
  // It's most likely on issue on userland.
  minWidth: 16,
  minHeight: 16,
  maxWidth: "calc(100% - 32px)",
  maxHeight: "calc(100% - 32px)",
  // We disable the focus ring for mouse, touch and keyboard users.
  outline: 0
}), A7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiPopover"
  }), {
    action: o,
    anchorEl: a,
    anchorOrigin: i = {
      vertical: "top",
      horizontal: "left"
    },
    anchorPosition: s,
    anchorReference: l = "anchorEl",
    children: c,
    className: u,
    container: f,
    elevation: d = 8,
    marginThreshold: p = 16,
    open: h,
    PaperProps: $ = {},
    slots: b = {},
    slotProps: g = {},
    transformOrigin: y = {
      vertical: "top",
      horizontal: "left"
    },
    TransitionComponent: S = Yu,
    transitionDuration: m = "auto",
    TransitionProps: {
      onEntering: w,
      ...v
    } = {},
    disableScrollLock: E = !1,
    ...I
  } = n, R = (g == null ? void 0 : g.paper) ?? $, C = M.useRef(), T = {
    ...n,
    anchorOrigin: i,
    anchorReference: l,
    elevation: d,
    marginThreshold: p,
    externalPaperSlotProps: R,
    transformOrigin: y,
    TransitionComponent: S,
    transitionDuration: m,
    TransitionProps: v
  }, F = k7(T), D = M.useCallback(() => {
    if (l === "anchorPosition")
      return s;
    const ce = pu(a), _e = (ce && ce.nodeType === 1 ? ce : mr(C.current).body).getBoundingClientRect();
    return {
      top: _e.top + dg(_e, i.vertical),
      left: _e.left + fg(_e, i.horizontal)
    };
  }, [a, i.horizontal, i.vertical, s, l]), z = M.useCallback((ce) => ({
    vertical: dg(ce, y.vertical),
    horizontal: fg(ce, y.horizontal)
  }), [y.horizontal, y.vertical]), L = M.useCallback((ce) => {
    const ye = {
      width: ce.offsetWidth,
      height: ce.offsetHeight
    }, _e = z(ye);
    if (l === "none")
      return {
        top: null,
        left: null,
        transformOrigin: pg(_e)
      };
    const Me = D();
    let Re = Me.top - _e.vertical, Ve = Me.left - _e.horizontal;
    const mt = Re + ye.height, Ue = Ve + ye.width, qe = Ln(pu(a)), se = qe.innerHeight - p, Ze = qe.innerWidth - p;
    if (p !== null && Re < p) {
      const rt = Re - p;
      Re -= rt, _e.vertical += rt;
    } else if (p !== null && mt > se) {
      const rt = mt - se;
      Re -= rt, _e.vertical += rt;
    }
    if (p !== null && Ve < p) {
      const rt = Ve - p;
      Ve -= rt, _e.horizontal += rt;
    } else if (Ue > Ze) {
      const rt = Ue - Ze;
      Ve -= rt, _e.horizontal += rt;
    }
    return {
      top: `${Math.round(Re)}px`,
      left: `${Math.round(Ve)}px`,
      transformOrigin: pg(_e)
    };
  }, [a, l, D, z, p]), [X, V] = M.useState(h), ie = M.useCallback(() => {
    const ce = C.current;
    if (!ce)
      return;
    const ye = L(ce);
    ye.top !== null && ce.style.setProperty("top", ye.top), ye.left !== null && (ce.style.left = ye.left), ce.style.transformOrigin = ye.transformOrigin, V(!0);
  }, [L]);
  M.useEffect(() => (E && window.addEventListener("scroll", ie), () => window.removeEventListener("scroll", ie)), [a, E, ie]);
  const Y = (ce, ye) => {
    w && w(ce, ye), ie();
  }, H = () => {
    V(!1);
  };
  M.useEffect(() => {
    h && ie();
  }), M.useImperativeHandle(o, () => h ? {
    updatePosition: () => {
      ie();
    }
  } : null, [h, ie]), M.useEffect(() => {
    if (!h)
      return;
    const ce = Mb(() => {
      ie();
    }), ye = Ln(a);
    return ye.addEventListener("resize", ce), () => {
      ce.clear(), ye.removeEventListener("resize", ce);
    };
  }, [a, h, ie]);
  let j = m;
  m === "auto" && !S.muiSupportAuto && (j = void 0);
  const Q = f || (a ? mr(pu(a)).body : void 0), q = {
    slots: b,
    slotProps: {
      ...g,
      paper: R
    }
  }, [O, N] = Sr("paper", {
    elementType: Ev,
    externalForwardedProps: q,
    additionalProps: {
      elevation: d,
      className: Ee(F.paper, R == null ? void 0 : R.className),
      style: X ? R.style : {
        ...R.style,
        opacity: 0
      }
    },
    ownerState: T
  }), [W, {
    slotProps: ne,
    ...ee
  }] = Sr("root", {
    elementType: O7,
    externalForwardedProps: q,
    additionalProps: {
      slotProps: {
        backdrop: {
          invisible: !0
        }
      },
      container: Q,
      open: h
    },
    ownerState: T,
    className: Ee(F.root, u)
  }), pe = Bt(C, N.ref);
  return /* @__PURE__ */ P(W, {
    ...ee,
    ...!Tn(W) && {
      slotProps: ne,
      disableScrollLock: E
    },
    ...I,
    ref: r,
    children: /* @__PURE__ */ P(S, {
      appear: !0,
      in: h,
      onEntering: Y,
      onExited: H,
      timeout: j,
      ...v,
      children: /* @__PURE__ */ P(O, {
        ...N,
        ref: pe,
        children: c
      })
    })
  });
});
function I7(e) {
  return Be("MuiMenu", e);
}
De("MuiMenu", ["root", "paper", "list"]);
const R7 = {
  vertical: "top",
  horizontal: "right"
}, T7 = {
  vertical: "top",
  horizontal: "left"
}, M7 = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"],
    paper: ["paper"],
    list: ["list"]
  }, I7, t);
}, N7 = de(A7, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiMenu",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({}), F7 = de(Ev, {
  name: "MuiMenu",
  slot: "Paper",
  overridesResolver: (e, t) => t.paper
})({
  // specZ: The maximum height of a simple menu should be one or more rows less than the view
  // height. This ensures a tappable area outside of the simple menu with which to dismiss
  // the menu.
  maxHeight: "calc(100% - 96px)",
  // Add iOS momentum scrolling for iOS < 13.0
  WebkitOverflowScrolling: "touch"
}), j7 = de(Xz, {
  name: "MuiMenu",
  slot: "List",
  overridesResolver: (e, t) => t.list
})({
  // We disable the focus ring for mouse, touch and keyboard users.
  outline: 0
}), D7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiMenu"
  }), {
    autoFocus: o = !0,
    children: a,
    className: i,
    disableAutoFocusItem: s = !1,
    MenuListProps: l = {},
    onClose: c,
    open: u,
    PaperProps: f = {},
    PopoverClasses: d,
    transitionDuration: p = "auto",
    TransitionProps: {
      onEntering: h,
      ...$
    } = {},
    variant: b = "selectedMenu",
    slots: g = {},
    slotProps: y = {},
    ...S
  } = n, m = xf(), w = {
    ...n,
    autoFocus: o,
    disableAutoFocusItem: s,
    MenuListProps: l,
    onEntering: h,
    PaperProps: f,
    transitionDuration: p,
    TransitionProps: $,
    variant: b
  }, v = M7(w), E = o && !s && u, I = M.useRef(null), R = (X, V) => {
    I.current && I.current.adjustStyleForScrollbar(X, {
      direction: m ? "rtl" : "ltr"
    }), h && h(X, V);
  }, C = (X) => {
    X.key === "Tab" && (X.preventDefault(), c && c(X, "tabKeyDown"));
  };
  let T = -1;
  M.Children.map(a, (X, V) => {
    /* @__PURE__ */ M.isValidElement(X) && (X.props.disabled || (b === "selectedMenu" && X.props.selected || T === -1) && (T = V));
  });
  const F = g.paper ?? F7, D = y.paper ?? f, z = ln({
    elementType: g.root,
    externalSlotProps: y.root,
    ownerState: w,
    className: [v.root, i]
  }), L = ln({
    elementType: F,
    externalSlotProps: D,
    ownerState: w,
    className: v.paper
  });
  return /* @__PURE__ */ P(N7, {
    onClose: c,
    anchorOrigin: {
      vertical: "bottom",
      horizontal: m ? "right" : "left"
    },
    transformOrigin: m ? R7 : T7,
    slots: {
      paper: F,
      root: g.root
    },
    slotProps: {
      root: z,
      paper: L
    },
    open: u,
    ref: r,
    transitionDuration: p,
    TransitionProps: {
      onEntering: R,
      ...$
    },
    ownerState: w,
    ...S,
    classes: d,
    children: /* @__PURE__ */ P(j7, {
      onKeyDown: C,
      actions: I,
      autoFocus: o && (T === -1 || s),
      autoFocusItem: E,
      variant: b,
      ...l,
      className: Ee(v.list, l.className),
      children: a
    })
  });
});
function L7(e) {
  return Be("MuiNativeSelect", e);
}
const Df = De("MuiNativeSelect", ["root", "select", "multiple", "filled", "outlined", "standard", "disabled", "icon", "iconOpen", "iconFilled", "iconOutlined", "iconStandard", "nativeInput", "error"]), B7 = (e) => {
  const {
    classes: t,
    variant: r,
    disabled: n,
    multiple: o,
    open: a,
    error: i
  } = e, s = {
    select: ["select", r, n && "disabled", o && "multiple", i && "error"],
    icon: ["icon", `icon${$e(r)}`, a && "iconOpen", n && "disabled"]
  };
  return ze(s, L7, t);
}, _v = de("select")(({
  theme: e
}) => ({
  // Reset
  MozAppearance: "none",
  // Reset
  WebkitAppearance: "none",
  // When interacting quickly, the text can end up selected.
  // Native select can't be selected either.
  userSelect: "none",
  // Reset
  borderRadius: 0,
  cursor: "pointer",
  "&:focus": {
    // Reset Chrome style
    borderRadius: 0
  },
  [`&.${Df.disabled}`]: {
    cursor: "default"
  },
  "&[multiple]": {
    height: "auto"
  },
  "&:not([multiple]) option, &:not([multiple]) optgroup": {
    backgroundColor: (e.vars || e).palette.background.paper
  },
  variants: [{
    props: ({
      ownerState: t
    }) => t.variant !== "filled" && t.variant !== "outlined",
    style: {
      // Bump specificity to allow extending custom inputs
      "&&&": {
        paddingRight: 24,
        minWidth: 16
        // So it doesn't collapse.
      }
    }
  }, {
    props: {
      variant: "filled"
    },
    style: {
      "&&&": {
        paddingRight: 32
      }
    }
  }, {
    props: {
      variant: "outlined"
    },
    style: {
      borderRadius: (e.vars || e).shape.borderRadius,
      "&:focus": {
        borderRadius: (e.vars || e).shape.borderRadius
        // Reset the reset for Chrome style
      },
      "&&&": {
        paddingRight: 32
      }
    }
  }]
})), z7 = de(_v, {
  name: "MuiNativeSelect",
  slot: "Select",
  shouldForwardProp: cr,
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.select, t[r.variant], r.error && t.error, {
      [`&.${Df.multiple}`]: t.multiple
    }];
  }
})({}), xv = de("svg")(({
  theme: e
}) => ({
  // We use a position absolute over a flexbox in order to forward the pointer events
  // to the input and to support wrapping tags..
  position: "absolute",
  right: 0,
  // Center vertically, height is 1em
  top: "calc(50% - .5em)",
  // Don't block pointer events on the select under the icon.
  pointerEvents: "none",
  color: (e.vars || e).palette.action.active,
  [`&.${Df.disabled}`]: {
    color: (e.vars || e).palette.action.disabled
  },
  variants: [{
    props: ({
      ownerState: t
    }) => t.open,
    style: {
      transform: "rotate(180deg)"
    }
  }, {
    props: {
      variant: "filled"
    },
    style: {
      right: 7
    }
  }, {
    props: {
      variant: "outlined"
    },
    style: {
      right: 7
    }
  }]
})), U7 = de(xv, {
  name: "MuiNativeSelect",
  slot: "Icon",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.icon, r.variant && t[`icon${$e(r.variant)}`], r.open && t.iconOpen];
  }
})({}), V7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    className: n,
    disabled: o,
    error: a,
    IconComponent: i,
    inputRef: s,
    variant: l = "standard",
    ...c
  } = t, u = {
    ...t,
    disabled: o,
    variant: l,
    error: a
  }, f = B7(u);
  return /* @__PURE__ */ ue(M.Fragment, {
    children: [/* @__PURE__ */ P(z7, {
      ownerState: u,
      className: Ee(f.select, n),
      disabled: o,
      ref: s || r,
      ...c
    }), t.multiple ? null : /* @__PURE__ */ P(U7, {
      as: i,
      ownerState: u,
      className: f.icon
    })]
  });
});
function q7(e) {
  return Be("MuiSelect", e);
}
const ci = De("MuiSelect", ["root", "select", "multiple", "filled", "outlined", "standard", "disabled", "focused", "icon", "iconOpen", "iconFilled", "iconOutlined", "iconStandard", "nativeInput", "error"]);
var hg;
const W7 = de(_v, {
  name: "MuiSelect",
  slot: "Select",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [
      // Win specificity over the input base
      {
        [`&.${ci.select}`]: t.select
      },
      {
        [`&.${ci.select}`]: t[r.variant]
      },
      {
        [`&.${ci.error}`]: t.error
      },
      {
        [`&.${ci.multiple}`]: t.multiple
      }
    ];
  }
})({
  // Win specificity over the input base
  [`&.${ci.select}`]: {
    height: "auto",
    // Resets for multiple select with chips
    minHeight: "1.4375em",
    // Required for select\text-field height consistency
    textOverflow: "ellipsis",
    whiteSpace: "nowrap",
    overflow: "hidden"
  }
}), K7 = de(xv, {
  name: "MuiSelect",
  slot: "Icon",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.icon, r.variant && t[`icon${$e(r.variant)}`], r.open && t.iconOpen];
  }
})({}), G7 = de("input", {
  shouldForwardProp: (e) => Sc(e) && e !== "classes",
  name: "MuiSelect",
  slot: "NativeInput",
  overridesResolver: (e, t) => t.nativeInput
})({
  bottom: 0,
  left: 0,
  position: "absolute",
  opacity: 0,
  pointerEvents: "none",
  width: "100%",
  boxSizing: "border-box"
});
function mg(e, t) {
  return typeof t == "object" && t !== null ? e === t : String(e) === String(t);
}
function H7(e) {
  return e == null || typeof e == "string" && !e.trim();
}
const J7 = (e) => {
  const {
    classes: t,
    variant: r,
    disabled: n,
    multiple: o,
    open: a,
    error: i
  } = e, s = {
    select: ["select", r, n && "disabled", o && "multiple", i && "error"],
    icon: ["icon", `icon${$e(r)}`, a && "iconOpen", n && "disabled"],
    nativeInput: ["nativeInput"]
  };
  return ze(s, q7, t);
}, Y7 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  var ut;
  const {
    "aria-describedby": n,
    "aria-label": o,
    autoFocus: a,
    autoWidth: i,
    children: s,
    className: l,
    defaultOpen: c,
    defaultValue: u,
    disabled: f,
    displayEmpty: d,
    error: p = !1,
    IconComponent: h,
    inputRef: $,
    labelId: b,
    MenuProps: g = {},
    multiple: y,
    name: S,
    onBlur: m,
    onChange: w,
    onClose: v,
    onFocus: E,
    onOpen: I,
    open: R,
    readOnly: C,
    renderValue: T,
    required: F,
    SelectDisplayProps: D = {},
    tabIndex: z,
    // catching `type` from Input which makes no sense for SelectInput
    type: L,
    value: X,
    variant: V = "standard",
    ...ie
  } = t, [Y, H] = Bi({
    controlled: X,
    default: u,
    name: "Select"
  }), [j, Q] = Bi({
    controlled: R,
    default: c,
    name: "Select"
  }), q = M.useRef(null), O = M.useRef(null), [N, W] = M.useState(null), {
    current: ne
  } = M.useRef(R != null), [ee, pe] = M.useState(), ce = Bt(r, $), ye = M.useCallback((Se) => {
    O.current = Se, Se && W(Se);
  }, []), _e = N == null ? void 0 : N.parentNode;
  M.useImperativeHandle(ce, () => ({
    focus: () => {
      O.current.focus();
    },
    node: q.current,
    value: Y
  }), [Y]), M.useEffect(() => {
    c && j && N && !ne && (pe(i ? null : _e.clientWidth), O.current.focus());
  }, [N, i]), M.useEffect(() => {
    a && O.current.focus();
  }, [a]), M.useEffect(() => {
    if (!b)
      return;
    const Se = mr(O.current).getElementById(b);
    if (Se) {
      const Ne = () => {
        getSelection().isCollapsed && O.current.focus();
      };
      return Se.addEventListener("click", Ne), () => {
        Se.removeEventListener("click", Ne);
      };
    }
  }, [b]);
  const Me = (Se, Ne) => {
    Se ? I && I(Ne) : v && v(Ne), ne || (pe(i ? null : _e.clientWidth), Q(Se));
  }, Re = (Se) => {
    Se.button === 0 && (Se.preventDefault(), O.current.focus(), Me(!0, Se));
  }, Ve = (Se) => {
    Me(!1, Se);
  }, mt = M.Children.toArray(s), Ue = (Se) => {
    const Ne = mt.find((et) => et.props.value === Se.target.value);
    Ne !== void 0 && (H(Ne.props.value), w && w(Se, Ne));
  }, qe = (Se) => (Ne) => {
    let et;
    if (Ne.currentTarget.hasAttribute("tabindex")) {
      if (y) {
        et = Array.isArray(Y) ? Y.slice() : [];
        const It = Y.indexOf(Se.props.value);
        It === -1 ? et.push(Se.props.value) : et.splice(It, 1);
      } else
        et = Se.props.value;
      if (Se.props.onClick && Se.props.onClick(Ne), Y !== et && (H(et), w)) {
        const It = Ne.nativeEvent || Ne, Vt = new It.constructor(It.type, It);
        Object.defineProperty(Vt, "target", {
          writable: !0,
          value: {
            value: et,
            name: S
          }
        }), w(Vt, Se);
      }
      y || Me(!1, Ne);
    }
  }, se = (Se) => {
    C || [
      " ",
      "ArrowUp",
      "ArrowDown",
      // The native select doesn't respond to enter on macOS, but it's recommended by
      // https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/
      "Enter"
    ].includes(Se.key) && (Se.preventDefault(), Me(!0, Se));
  }, Ze = N !== null && j, rt = (Se) => {
    !Ze && m && (Object.defineProperty(Se, "target", {
      writable: !0,
      value: {
        value: Y,
        name: S
      }
    }), m(Se));
  };
  delete ie["aria-invalid"];
  let Ce, Nt;
  const re = [];
  let fe = !1;
  (xl({
    value: Y
  }) || d) && (T ? Ce = T(Y) : fe = !0);
  const ve = mt.map((Se) => {
    if (!/* @__PURE__ */ M.isValidElement(Se))
      return null;
    let Ne;
    if (y) {
      if (!Array.isArray(Y))
        throw new Error(Dn(2));
      Ne = Y.some((et) => mg(et, Se.props.value)), Ne && fe && re.push(Se.props.children);
    } else
      Ne = mg(Y, Se.props.value), Ne && fe && (Nt = Se.props.children);
    return /* @__PURE__ */ M.cloneElement(Se, {
      "aria-selected": Ne ? "true" : "false",
      onClick: qe(Se),
      onKeyUp: (et) => {
        et.key === " " && et.preventDefault(), Se.props.onKeyUp && Se.props.onKeyUp(et);
      },
      role: "option",
      selected: Ne,
      value: void 0,
      // The value is most likely not a valid HTML attribute.
      "data-value": Se.props.value
      // Instead, we provide it as a data attribute.
    });
  });
  fe && (y ? re.length === 0 ? Ce = null : Ce = re.reduce((Se, Ne, et) => (Se.push(Ne), et < re.length - 1 && Se.push(", "), Se), []) : Ce = Nt);
  let Ie = ee;
  !i && ne && N && (Ie = _e.clientWidth);
  let Le;
  typeof z < "u" ? Le = z : Le = f ? null : 0;
  const K = D.id || (S ? `mui-component-select-${S}` : void 0), G = {
    ...t,
    variant: V,
    value: Y,
    open: Ze,
    error: p
  }, ae = J7(G), he = {
    ...g.PaperProps,
    ...(ut = g.slotProps) == null ? void 0 : ut.paper
  }, Oe = df();
  return /* @__PURE__ */ ue(M.Fragment, {
    children: [/* @__PURE__ */ P(W7, {
      as: "div",
      ref: ye,
      tabIndex: Le,
      role: "combobox",
      "aria-controls": Oe,
      "aria-disabled": f ? "true" : void 0,
      "aria-expanded": Ze ? "true" : "false",
      "aria-haspopup": "listbox",
      "aria-label": o,
      "aria-labelledby": [b, K].filter(Boolean).join(" ") || void 0,
      "aria-describedby": n,
      "aria-required": F ? "true" : void 0,
      "aria-invalid": p ? "true" : void 0,
      onKeyDown: se,
      onMouseDown: f || C ? null : Re,
      onBlur: rt,
      onFocus: E,
      ...D,
      ownerState: G,
      className: Ee(D.className, ae.select, l),
      id: K,
      children: H7(Ce) ? (
        // notranslate needed while Google Translate will not fix zero-width space issue
        hg || (hg = /* @__PURE__ */ P("span", {
          className: "notranslate",
          "aria-hidden": !0,
          children: "​"
        }))
      ) : Ce
    }), /* @__PURE__ */ P(G7, {
      "aria-invalid": p,
      value: Array.isArray(Y) ? Y.join(",") : Y,
      name: S,
      ref: q,
      "aria-hidden": !0,
      onChange: Ue,
      tabIndex: -1,
      disabled: f,
      className: ae.nativeInput,
      autoFocus: a,
      required: F,
      ...ie,
      ownerState: G
    }), /* @__PURE__ */ P(K7, {
      as: h,
      className: ae.icon,
      ownerState: G
    }), /* @__PURE__ */ P(D7, {
      id: `menu-${S || ""}`,
      anchorEl: _e,
      open: Ze,
      onClose: Ve,
      anchorOrigin: {
        vertical: "bottom",
        horizontal: "center"
      },
      transformOrigin: {
        vertical: "top",
        horizontal: "center"
      },
      ...g,
      MenuListProps: {
        "aria-labelledby": b,
        role: "listbox",
        "aria-multiselectable": y ? "true" : void 0,
        disableListWrap: !0,
        id: Oe,
        ...g.MenuListProps
      },
      slotProps: {
        ...g.slotProps,
        paper: {
          ...he,
          style: {
            minWidth: Ie,
            ...he != null ? he.style : null
          }
        }
      },
      children: ve
    })]
  });
}), X7 = gr(/* @__PURE__ */ P("path", {
  d: "M7 10l5 5 5-5z"
}), "ArrowDropDown"), Z7 = (e) => {
  const {
    classes: t
  } = e;
  return t;
}, Lf = {
  name: "MuiSelect",
  overridesResolver: (e, t) => t.root,
  shouldForwardProp: (e) => cr(e) && e !== "variant",
  slot: "Root"
}, Q7 = de(Tf, Lf)(""), eU = de(Nf, Lf)(""), tU = de(Mf, Lf)(""), Pv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    name: "MuiSelect",
    props: t
  }), {
    autoWidth: o = !1,
    children: a,
    classes: i = {},
    className: s,
    defaultOpen: l = !1,
    displayEmpty: c = !1,
    IconComponent: u = X7,
    id: f,
    input: d,
    inputProps: p,
    label: h,
    labelId: $,
    MenuProps: b,
    multiple: g = !1,
    native: y = !1,
    onClose: S,
    onOpen: m,
    open: w,
    renderValue: v,
    SelectDisplayProps: E,
    variant: I = "outlined",
    ...R
  } = n, C = y ? V7 : Y7, T = Sn(), F = po({
    props: n,
    muiFormControl: T,
    states: ["variant", "error"]
  }), D = F.variant || I, z = {
    ...n,
    variant: D,
    classes: i
  }, L = Z7(z), {
    root: X,
    ...V
  } = L, ie = d || {
    standard: /* @__PURE__ */ P(Q7, {
      ownerState: z
    }),
    outlined: /* @__PURE__ */ P(eU, {
      label: h,
      ownerState: z
    }),
    filled: /* @__PURE__ */ P(tU, {
      ownerState: z
    })
  }[D], Y = Bt(r, ss(ie));
  return /* @__PURE__ */ P(M.Fragment, {
    children: /* @__PURE__ */ M.cloneElement(ie, {
      // Most of the logic is implemented in `SelectInput`.
      // The `Select` component is a simple API wrapper to expose something better to play with.
      inputComponent: C,
      inputProps: {
        children: a,
        error: F.error,
        IconComponent: u,
        variant: D,
        type: void 0,
        // We render a select. We can ignore the type provided by the `Input`.
        multiple: g,
        ...y ? {
          id: f
        } : {
          autoWidth: o,
          defaultOpen: l,
          displayEmpty: c,
          labelId: $,
          MenuProps: b,
          onClose: S,
          onOpen: m,
          open: w,
          renderValue: v,
          SelectDisplayProps: {
            id: f,
            ...E
          }
        },
        ...p,
        classes: p ? lr(V, p.classes) : V,
        ...d ? d.props.inputProps : {}
      },
      ...(g && y || c) && D === "outlined" ? {
        notched: !0
      } : {},
      ref: Y,
      className: Ee(ie.props.className, s, L.root),
      // If a custom input is provided via 'input' prop, do not allow 'variant' to be propagated to it's root element. See https://github.com/mui/material-ui/issues/33894.
      ...!d && {
        variant: D
      },
      ...R
    })
  });
});
Pv.muiName = "Select";
function rU(e) {
  return Be("MuiTextField", e);
}
De("MuiTextField", ["root"]);
const nU = {
  standard: Tf,
  filled: Mf,
  outlined: Nf
}, oU = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"]
  }, rU, t);
}, aU = de(Sv, {
  name: "MuiTextField",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({}), Bf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiTextField"
  }), {
    autoComplete: o,
    autoFocus: a = !1,
    children: i,
    className: s,
    color: l = "primary",
    defaultValue: c,
    disabled: u = !1,
    error: f = !1,
    FormHelperTextProps: d,
    fullWidth: p = !1,
    helperText: h,
    id: $,
    InputLabelProps: b,
    inputProps: g,
    InputProps: y,
    inputRef: S,
    label: m,
    maxRows: w,
    minRows: v,
    multiline: E = !1,
    name: I,
    onBlur: R,
    onChange: C,
    onFocus: T,
    placeholder: F,
    required: D = !1,
    rows: z,
    select: L = !1,
    SelectProps: X,
    slots: V = {},
    slotProps: ie = {},
    type: Y,
    value: H,
    variant: j = "outlined",
    ...Q
  } = n, q = {
    ...n,
    autoFocus: a,
    color: l,
    disabled: u,
    error: f,
    fullWidth: p,
    multiline: E,
    required: D,
    select: L,
    variant: j
  }, O = oU(q), N = df($), W = h && N ? `${N}-helper-text` : void 0, ne = m && N ? `${N}-label` : void 0, ee = nU[j], pe = {
    slots: V,
    slotProps: {
      input: y,
      inputLabel: b,
      htmlInput: g,
      formHelperText: d,
      select: X,
      ...ie
    }
  }, ce = {}, ye = pe.slotProps.inputLabel;
  j === "outlined" && (ye && typeof ye.shrink < "u" && (ce.notched = ye.shrink), ce.label = m), L && ((!X || !X.native) && (ce.id = void 0), ce["aria-describedby"] = void 0);
  const [_e, Me] = Sr("input", {
    elementType: ee,
    externalForwardedProps: pe,
    additionalProps: ce,
    ownerState: q
  }), [Re, Ve] = Sr("inputLabel", {
    elementType: zz,
    externalForwardedProps: pe,
    ownerState: q
  }), [mt, Ue] = Sr("htmlInput", {
    elementType: "input",
    externalForwardedProps: pe,
    ownerState: q
  }), [qe, se] = Sr("formHelperText", {
    elementType: Ff,
    externalForwardedProps: pe,
    ownerState: q
  }), [Ze, rt] = Sr("select", {
    elementType: Pv,
    externalForwardedProps: pe,
    ownerState: q
  }), Ce = /* @__PURE__ */ P(_e, {
    "aria-describedby": W,
    autoComplete: o,
    autoFocus: a,
    defaultValue: c,
    fullWidth: p,
    multiline: E,
    name: I,
    rows: z,
    maxRows: w,
    minRows: v,
    type: Y,
    value: H,
    id: N,
    inputRef: S,
    onBlur: R,
    onChange: C,
    onFocus: T,
    placeholder: F,
    inputProps: Ue,
    slots: {
      input: V.htmlInput ? mt : void 0
    },
    ...Me
  });
  return /* @__PURE__ */ ue(aU, {
    className: Ee(O.root, s),
    disabled: u,
    error: f,
    fullWidth: p,
    ref: r,
    required: D,
    color: l,
    variant: j,
    ownerState: q,
    ...Q,
    children: [m != null && m !== "" && /* @__PURE__ */ P(Re, {
      htmlFor: N,
      id: ne,
      ...Ve,
      children: m
    }), L ? /* @__PURE__ */ P(Ze, {
      "aria-describedby": W,
      id: N,
      labelId: ne,
      value: H,
      input: Ce,
      ...rt,
      children: i
    }) : Ce, h && /* @__PURE__ */ P(qe, {
      id: W,
      ...se,
      children: h
    })]
  });
}), iU = ["date", "datetime-local", "file", "time"];
function sU(e) {
  const {
    id: t,
    name: r,
    // remove this from textFieldProps
    placeholder: n,
    required: o,
    readonly: a,
    disabled: i,
    type: s,
    label: l,
    hideLabel: c,
    hideError: u,
    value: f,
    onChange: d,
    onChangeOverride: p,
    onBlur: h,
    onFocus: $,
    autofocus: b,
    options: g,
    schema: y,
    uiSchema: S,
    rawErrors: m = [],
    errorSchema: w,
    formContext: v,
    registry: E,
    InputLabelProps: I,
    ...R
  } = e, C = ib(y, s, g), { step: T, min: F, max: D, ...z } = C, L = {
    inputProps: {
      step: T,
      min: F,
      max: D,
      ...y.examples ? { list: ji(t) } : void 0
    },
    ...z
  }, X = ({ target: { value: H } }) => d(H === "" ? g.emptyValue : H), V = ({ target: H }) => h(t, H && H.value), ie = ({ target: H }) => $(t, H && H.value), Y = iU.includes(s) ? {
    ...I,
    shrink: !0
  } : I;
  return ue(Wt, { children: [P(Bf, { id: t, name: t, placeholder: n, label: Bo(l || void 0, c, void 0), autoFocus: b, required: o, disabled: i || a, ...L, value: f || f === 0 ? f : "", error: m.length > 0, onChange: p || X, onBlur: V, onFocus: ie, InputLabelProps: Y, ...R, "aria-describedby": Mr(t, !!y.examples) }), Array.isArray(y.examples) && P("datalist", { id: ji(t), children: y.examples.concat(y.default && !y.examples.includes(y.default) ? [y.default] : []).map((H) => P("option", { value: H }, H)) })] });
}
function lU(e) {
  return Be("MuiTypography", e);
}
const gg = De("MuiTypography", ["root", "h1", "h2", "h3", "h4", "h5", "h6", "subtitle1", "subtitle2", "body1", "body2", "inherit", "button", "caption", "overline", "alignLeft", "alignRight", "alignCenter", "alignJustify", "noWrap", "gutterBottom", "paragraph"]), cU = {
  primary: !0,
  secondary: !0,
  error: !0,
  info: !0,
  success: !0,
  warning: !0,
  textPrimary: !0,
  textSecondary: !0,
  textDisabled: !0
}, uU = hB(), dU = (e) => {
  const {
    align: t,
    gutterBottom: r,
    noWrap: n,
    paragraph: o,
    variant: a,
    classes: i
  } = e, s = {
    root: ["root", a, e.align !== "inherit" && `align${$e(t)}`, r && "gutterBottom", n && "noWrap", o && "paragraph"]
  };
  return ze(s, lU, i);
}, fU = de("span", {
  name: "MuiTypography",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.variant && t[r.variant], r.align !== "inherit" && t[`align${$e(r.align)}`], r.noWrap && t.noWrap, r.gutterBottom && t.gutterBottom, r.paragraph && t.paragraph];
  }
})(je(({
  theme: e
}) => {
  var t;
  return {
    margin: 0,
    variants: [{
      props: {
        variant: "inherit"
      },
      style: {
        // Some elements, like <button> on Chrome have default font that doesn't inherit, reset this.
        font: "inherit",
        lineHeight: "inherit",
        letterSpacing: "inherit"
      }
    }, ...Object.entries(e.typography).filter(([r, n]) => r !== "inherit" && n && typeof n == "object").map(([r, n]) => ({
      props: {
        variant: r
      },
      style: n
    })), ...Object.entries(e.palette).filter(zt()).map(([r]) => ({
      props: {
        color: r
      },
      style: {
        color: (e.vars || e).palette[r].main
      }
    })), ...Object.entries(((t = e.palette) == null ? void 0 : t.text) || {}).filter(([, r]) => typeof r == "string").map(([r]) => ({
      props: {
        color: `text${$e(r)}`
      },
      style: {
        color: (e.vars || e).palette.text[r]
      }
    })), {
      props: ({
        ownerState: r
      }) => r.align !== "inherit",
      style: {
        textAlign: "var(--Typography-textAlign)"
      }
    }, {
      props: ({
        ownerState: r
      }) => r.noWrap,
      style: {
        overflow: "hidden",
        textOverflow: "ellipsis",
        whiteSpace: "nowrap"
      }
    }, {
      props: ({
        ownerState: r
      }) => r.gutterBottom,
      style: {
        marginBottom: "0.35em"
      }
    }, {
      props: ({
        ownerState: r
      }) => r.paragraph,
      style: {
        marginBottom: 16
      }
    }]
  };
})), yg = {
  h1: "h1",
  h2: "h2",
  h3: "h3",
  h4: "h4",
  h5: "h5",
  h6: "h6",
  subtitle1: "h6",
  subtitle2: "h6",
  body1: "p",
  body2: "p",
  inherit: "p"
}, sr = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    color: n,
    ...o
  } = Ke({
    props: t,
    name: "MuiTypography"
  }), a = !cU[n], i = uU({
    ...o,
    ...a && {
      color: n
    }
  }), {
    align: s = "inherit",
    className: l,
    component: c,
    gutterBottom: u = !1,
    noWrap: f = !1,
    paragraph: d = !1,
    variant: p = "body1",
    variantMapping: h = yg,
    ...$
  } = i, b = {
    ...i,
    align: s,
    color: n,
    className: l,
    component: c,
    gutterBottom: u,
    noWrap: f,
    paragraph: d,
    variant: p,
    variantMapping: h
  }, g = c || (d ? "p" : h[p] || yg[p]) || "span", y = dU(b);
  return /* @__PURE__ */ P(fU, {
    as: g,
    ref: r,
    className: Ee(y.root, l),
    ...$,
    ownerState: b,
    style: {
      ...s !== "inherit" && {
        "--Typography-textAlign": s
      },
      ...$.style
    }
  });
});
function pU(e) {
  const { id: t, description: r } = e;
  return r ? P(sr, { id: t, variant: "subtitle2", style: { marginTop: "5px" }, children: r }) : null;
}
const hU = gr(/* @__PURE__ */ P("path", {
  d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-2h2zm0-4h-2V7h2z"
}), "Error");
function mU(e) {
  return Be("MuiListItem", e);
}
De("MuiListItem", ["root", "container", "dense", "alignItemsFlexStart", "divider", "gutters", "padding", "secondaryAction"]);
const gU = De("MuiListItemButton", ["root", "focusVisible", "dense", "alignItemsFlexStart", "disabled", "divider", "gutters", "selected"]);
function yU(e) {
  return Be("MuiListItemSecondaryAction", e);
}
De("MuiListItemSecondaryAction", ["root", "disableGutters"]);
const bU = (e) => {
  const {
    disableGutters: t,
    classes: r
  } = e;
  return ze({
    root: ["root", t && "disableGutters"]
  }, yU, r);
}, vU = de("div", {
  name: "MuiListItemSecondaryAction",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.disableGutters && t.disableGutters];
  }
})({
  position: "absolute",
  right: 16,
  top: "50%",
  transform: "translateY(-50%)",
  variants: [{
    props: ({
      ownerState: e
    }) => e.disableGutters,
    style: {
      right: 0
    }
  }]
}), kv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiListItemSecondaryAction"
  }), {
    className: o,
    ...a
  } = n, i = M.useContext(Mn), s = {
    ...n,
    disableGutters: i.disableGutters
  }, l = bU(s);
  return /* @__PURE__ */ P(vU, {
    className: Ee(l.root, o),
    ownerState: s,
    ref: r,
    ...a
  });
});
kv.muiName = "ListItemSecondaryAction";
const $U = (e, t) => {
  const {
    ownerState: r
  } = e;
  return [t.root, r.dense && t.dense, r.alignItems === "flex-start" && t.alignItemsFlexStart, r.divider && t.divider, !r.disableGutters && t.gutters, !r.disablePadding && t.padding, r.hasSecondaryAction && t.secondaryAction];
}, SU = (e) => {
  const {
    alignItems: t,
    classes: r,
    dense: n,
    disableGutters: o,
    disablePadding: a,
    divider: i,
    hasSecondaryAction: s
  } = e;
  return ze({
    root: ["root", n && "dense", !o && "gutters", !a && "padding", i && "divider", t === "flex-start" && "alignItemsFlexStart", s && "secondaryAction"],
    container: ["container"]
  }, mU, r);
}, wU = de("div", {
  name: "MuiListItem",
  slot: "Root",
  overridesResolver: $U
})(je(({
  theme: e
}) => ({
  display: "flex",
  justifyContent: "flex-start",
  alignItems: "center",
  position: "relative",
  textDecoration: "none",
  width: "100%",
  boxSizing: "border-box",
  textAlign: "left",
  variants: [{
    props: ({
      ownerState: t
    }) => !t.disablePadding,
    style: {
      paddingTop: 8,
      paddingBottom: 8
    }
  }, {
    props: ({
      ownerState: t
    }) => !t.disablePadding && t.dense,
    style: {
      paddingTop: 4,
      paddingBottom: 4
    }
  }, {
    props: ({
      ownerState: t
    }) => !t.disablePadding && !t.disableGutters,
    style: {
      paddingLeft: 16,
      paddingRight: 16
    }
  }, {
    props: ({
      ownerState: t
    }) => !t.disablePadding && !!t.secondaryAction,
    style: {
      // Add some space to avoid collision as `ListItemSecondaryAction`
      // is absolutely positioned.
      paddingRight: 48
    }
  }, {
    props: ({
      ownerState: t
    }) => !!t.secondaryAction,
    style: {
      [`& > .${gU.root}`]: {
        paddingRight: 48
      }
    }
  }, {
    props: {
      alignItems: "flex-start"
    },
    style: {
      alignItems: "flex-start"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.divider,
    style: {
      borderBottom: `1px solid ${(e.vars || e).palette.divider}`,
      backgroundClip: "padding-box"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.button,
    style: {
      transition: e.transitions.create("background-color", {
        duration: e.transitions.duration.shortest
      }),
      "&:hover": {
        textDecoration: "none",
        backgroundColor: (e.vars || e).palette.action.hover,
        // Reset on touch devices, it doesn't add specificity
        "@media (hover: none)": {
          backgroundColor: "transparent"
        }
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.hasSecondaryAction,
    style: {
      // Add some space to avoid collision as `ListItemSecondaryAction`
      // is absolutely positioned.
      paddingRight: 48
    }
  }]
}))), CU = de("li", {
  name: "MuiListItem",
  slot: "Container",
  overridesResolver: (e, t) => t.container
})({
  position: "relative"
}), Ov = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiListItem"
  }), {
    alignItems: o = "center",
    children: a,
    className: i,
    component: s,
    components: l = {},
    componentsProps: c = {},
    ContainerComponent: u = "li",
    ContainerProps: {
      className: f,
      ...d
    } = {},
    dense: p = !1,
    disableGutters: h = !1,
    disablePadding: $ = !1,
    divider: b = !1,
    secondaryAction: g,
    slotProps: y = {},
    slots: S = {},
    ...m
  } = n, w = M.useContext(Mn), v = M.useMemo(() => ({
    dense: p || w.dense || !1,
    alignItems: o,
    disableGutters: h
  }), [o, w.dense, p, h]), E = M.useRef(null), I = M.Children.toArray(a), R = I.length && Ci(I[I.length - 1], ["ListItemSecondaryAction"]), C = {
    ...n,
    alignItems: o,
    dense: v.dense,
    disableGutters: h,
    disablePadding: $,
    divider: b,
    hasSecondaryAction: R
  }, T = SU(C), F = Bt(E, r), D = S.root || l.Root || wU, z = y.root || c.root || {}, L = {
    className: Ee(T.root, z.className, i),
    ...m
  };
  let X = s || "li";
  return R ? (X = !L.component && !s ? "div" : X, u === "li" && (X === "li" ? X = "div" : L.component === "li" && (L.component = "div")), /* @__PURE__ */ P(Mn.Provider, {
    value: v,
    children: /* @__PURE__ */ ue(CU, {
      as: u,
      className: Ee(T.container, f),
      ref: F,
      ownerState: C,
      ...d,
      children: [/* @__PURE__ */ P(D, {
        ...z,
        ...!Tn(D) && {
          as: X,
          ownerState: {
            ...C,
            ...z.ownerState
          }
        },
        ...L,
        children: I
      }), I.pop()]
    })
  })) : /* @__PURE__ */ P(Mn.Provider, {
    value: v,
    children: /* @__PURE__ */ ue(D, {
      ...z,
      as: X,
      ref: F,
      ...!Tn(D) && {
        ownerState: {
          ...C,
          ...z.ownerState
        }
      },
      ...L,
      children: [I, g && /* @__PURE__ */ P(kv, {
        children: g
      })]
    })
  });
});
function EU(e) {
  return Be("MuiListItemIcon", e);
}
const bg = De("MuiListItemIcon", ["root", "alignItemsFlexStart"]), _U = (e) => {
  const {
    alignItems: t,
    classes: r
  } = e;
  return ze({
    root: ["root", t === "flex-start" && "alignItemsFlexStart"]
  }, EU, r);
}, xU = de("div", {
  name: "MuiListItemIcon",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.alignItems === "flex-start" && t.alignItemsFlexStart];
  }
})(je(({
  theme: e
}) => ({
  minWidth: 56,
  color: (e.vars || e).palette.action.active,
  flexShrink: 0,
  display: "inline-flex",
  variants: [{
    props: {
      alignItems: "flex-start"
    },
    style: {
      marginTop: 8
    }
  }]
}))), PU = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiListItemIcon"
  }), {
    className: o,
    ...a
  } = n, i = M.useContext(Mn), s = {
    ...n,
    alignItems: i.alignItems
  }, l = _U(s);
  return /* @__PURE__ */ P(xU, {
    className: Ee(l.root, o),
    ownerState: s,
    ref: r,
    ...a
  });
});
function kU(e) {
  return Be("MuiListItemText", e);
}
const ia = De("MuiListItemText", ["root", "multiline", "dense", "inset", "primary", "secondary"]), OU = (e) => {
  const {
    classes: t,
    inset: r,
    primary: n,
    secondary: o,
    dense: a
  } = e;
  return ze({
    root: ["root", r && "inset", a && "dense", n && o && "multiline"],
    primary: ["primary"],
    secondary: ["secondary"]
  }, kU, t);
}, AU = de("div", {
  name: "MuiListItemText",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [{
      [`& .${ia.primary}`]: t.primary
    }, {
      [`& .${ia.secondary}`]: t.secondary
    }, t.root, r.inset && t.inset, r.primary && r.secondary && t.multiline, r.dense && t.dense];
  }
})({
  flex: "1 1 auto",
  minWidth: 0,
  marginTop: 4,
  marginBottom: 4,
  [`.${gg.root}:where(& .${ia.primary})`]: {
    display: "block"
  },
  [`.${gg.root}:where(& .${ia.secondary})`]: {
    display: "block"
  },
  variants: [{
    props: ({
      ownerState: e
    }) => e.primary && e.secondary,
    style: {
      marginTop: 6,
      marginBottom: 6
    }
  }, {
    props: ({
      ownerState: e
    }) => e.inset,
    style: {
      paddingLeft: 56
    }
  }]
}), IU = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiListItemText"
  }), {
    children: o,
    className: a,
    disableTypography: i = !1,
    inset: s = !1,
    primary: l,
    primaryTypographyProps: c,
    secondary: u,
    secondaryTypographyProps: f,
    slots: d = {},
    slotProps: p = {},
    ...h
  } = n, {
    dense: $
  } = M.useContext(Mn);
  let b = l ?? o, g = u;
  const y = {
    ...n,
    disableTypography: i,
    inset: s,
    primary: !!b,
    secondary: !!g,
    dense: $
  }, S = OU(y), m = {
    slots: d,
    slotProps: {
      primary: c,
      secondary: f,
      ...p
    }
  }, [w, v] = Sr("primary", {
    className: S.primary,
    elementType: sr,
    externalForwardedProps: m,
    ownerState: y
  }), [E, I] = Sr("secondary", {
    className: S.secondary,
    elementType: sr,
    externalForwardedProps: m,
    ownerState: y
  });
  return b != null && b.type !== sr && !i && (b = /* @__PURE__ */ P(w, {
    variant: $ ? "body2" : "body1",
    component: v != null && v.variant ? void 0 : "span",
    ...v,
    children: b
  })), g != null && g.type !== sr && !i && (g = /* @__PURE__ */ P(E, {
    variant: "body2",
    color: "textSecondary",
    ...I,
    children: g
  })), /* @__PURE__ */ ue(AU, {
    className: Ee(S.root, a),
    ownerState: y,
    ref: r,
    ...h,
    children: [b, g]
  });
});
function RU({ errors: e, registry: t }) {
  const { translateString: r } = t;
  return P(Ga, { elevation: 2, children: ue(hr, { mb: 2, p: 2, children: [P(sr, { variant: "h6", children: r(ot.ErrorsLabel) }), P(jf, { dense: !0, children: e.map((n, o) => ue(Ov, { children: [P(PU, { children: P(hU, { color: "error" }) }), P(IU, { primary: n.stack })] }, o)) })] }) });
}
const TU = gr(/* @__PURE__ */ P("path", {
  d: "m20 12-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8z"
}), "ArrowDownward"), MU = gr(/* @__PURE__ */ P("path", {
  d: "m4 12 1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8z"
}), "ArrowUpward"), NU = gr(/* @__PURE__ */ P("path", {
  d: "M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2m0 16H8V7h11z"
}), "ContentCopy"), FU = gr(/* @__PURE__ */ P("path", {
  d: "M19 13H5v-2h14z"
}), "Remove");
function Pc(e) {
  const { icon: t, color: r, uiSchema: n, registry: o, ...a } = e;
  return P(vv, { ...a, size: "small", color: r, children: t });
}
function jU(e) {
  const { registry: { translateString: t } } = e;
  return P(Pc, { title: t(ot.CopyButton), ...e, icon: P(NU, { fontSize: "small" }) });
}
function DU(e) {
  const { registry: { translateString: t } } = e;
  return P(Pc, { title: t(ot.MoveDownButton), ...e, icon: P(TU, { fontSize: "small" }) });
}
function LU(e) {
  const { registry: { translateString: t } } = e;
  return P(Pc, { title: t(ot.MoveUpButton), ...e, icon: P(MU, { fontSize: "small" }) });
}
function BU(e) {
  const { iconType: t, ...r } = e, { registry: { translateString: n } } = r;
  return P(Pc, { title: n(ot.RemoveButton), ...r, color: "error", icon: P(FU, { fontSize: t === "default" ? void 0 : "small" }) });
}
function zU(e) {
  const { errors: t = [], idSchema: r } = e;
  if (t.length === 0)
    return null;
  const n = of(r);
  return P(jf, { id: n, dense: !0, disablePadding: !0, children: t.map((o, a) => P(Ov, { disableGutters: !0, children: P(Ff, { component: "div", id: `${n}-${a}`, children: o }) }, a)) });
}
function UU(e) {
  const { idSchema: t, help: r } = e;
  if (!r)
    return null;
  const n = af(t);
  return P(Ff, { component: "div", id: n, children: r });
}
function VU(e) {
  const { id: t, children: r, classNames: n, style: o, disabled: a, displayLabel: i, hidden: s, label: l, onDropPropertyClick: c, onKeyChange: u, readonly: f, required: d, rawErrors: p = [], errors: h, help: $, description: b, rawDescription: g, schema: y, uiSchema: S, registry: m } = e, w = Qe(S), v = Ye("WrapIfAdditionalTemplate", m, w);
  return s ? P("div", { style: { display: "none" }, children: r }) : P(v, { classNames: n, style: o, disabled: a, id: t, label: l, onDropPropertyClick: c, onKeyChange: u, readonly: f, required: d, schema: y, uiSchema: S, registry: m, children: ue(Sv, { fullWidth: !0, error: !!p.length, required: d, children: [r, i && g ? P(sr, { variant: "caption", color: "textSecondary", children: b }) : null, h, $] }) });
}
function qU(e) {
  const { description: t, title: r, properties: n, required: o, disabled: a, readonly: i, uiSchema: s, idSchema: l, schema: c, formData: u, onAddClick: f, registry: d } = e, p = Qe(s), h = Ye("TitleFieldTemplate", d, p), $ = Ye("DescriptionFieldTemplate", d, p), { ButtonTemplates: { AddButton: b } } = d.templates;
  return ue(Wt, { children: [r && P(h, { id: sf(l), title: r, required: o, schema: c, uiSchema: s, registry: d }), t && P($, { id: Lo(l), description: t, schema: c, uiSchema: s, registry: d }), ue(Rr, { container: !0, spacing: 2, style: { marginTop: "10px" }, children: [n.map((g, y) => (
    // Remove the <Grid> if the inner element is hidden as the <Grid>
    // itself would otherwise still take up space.
    g.hidden ? g.content : P(Rr, { item: !0, xs: 12, style: { marginBottom: "10px" }, children: g.content }, y)
  )), fy(c, s, u) && P(Rr, { container: !0, justifyContent: "flex-end", children: P(Rr, { item: !0, children: P(b, { className: "object-property-expand", onClick: f(c), disabled: a || i, uiSchema: s, registry: d }) }) })] })] });
}
function WU(e) {
  return Be("MuiButton", e);
}
const Yo = De("MuiButton", ["root", "text", "textInherit", "textPrimary", "textSecondary", "textSuccess", "textError", "textInfo", "textWarning", "outlined", "outlinedInherit", "outlinedPrimary", "outlinedSecondary", "outlinedSuccess", "outlinedError", "outlinedInfo", "outlinedWarning", "contained", "containedInherit", "containedPrimary", "containedSecondary", "containedSuccess", "containedError", "containedInfo", "containedWarning", "disableElevation", "focusVisible", "disabled", "colorInherit", "colorPrimary", "colorSecondary", "colorSuccess", "colorError", "colorInfo", "colorWarning", "textSizeSmall", "textSizeMedium", "textSizeLarge", "outlinedSizeSmall", "outlinedSizeMedium", "outlinedSizeLarge", "containedSizeSmall", "containedSizeMedium", "containedSizeLarge", "sizeMedium", "sizeSmall", "sizeLarge", "fullWidth", "startIcon", "endIcon", "icon", "iconSizeSmall", "iconSizeMedium", "iconSizeLarge"]), KU = /* @__PURE__ */ M.createContext({}), GU = /* @__PURE__ */ M.createContext(void 0), HU = (e) => {
  const {
    color: t,
    disableElevation: r,
    fullWidth: n,
    size: o,
    variant: a,
    classes: i
  } = e, s = {
    root: ["root", a, `${a}${$e(t)}`, `size${$e(o)}`, `${a}Size${$e(o)}`, `color${$e(t)}`, r && "disableElevation", n && "fullWidth"],
    label: ["label"],
    startIcon: ["icon", "startIcon", `iconSize${$e(o)}`],
    endIcon: ["icon", "endIcon", `iconSize${$e(o)}`]
  }, l = ze(s, WU, i);
  return {
    ...i,
    // forward the focused, disabled, etc. classes to the ButtonBase
    ...l
  };
}, Av = [{
  props: {
    size: "small"
  },
  style: {
    "& > *:nth-of-type(1)": {
      fontSize: 18
    }
  }
}, {
  props: {
    size: "medium"
  },
  style: {
    "& > *:nth-of-type(1)": {
      fontSize: 20
    }
  }
}, {
  props: {
    size: "large"
  },
  style: {
    "& > *:nth-of-type(1)": {
      fontSize: 22
    }
  }
}], JU = de(hs, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiButton",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[r.variant], t[`${r.variant}${$e(r.color)}`], t[`size${$e(r.size)}`], t[`${r.variant}Size${$e(r.size)}`], r.color === "inherit" && t.colorInherit, r.disableElevation && t.disableElevation, r.fullWidth && t.fullWidth];
  }
})(je(({
  theme: e
}) => {
  const t = e.palette.mode === "light" ? e.palette.grey[300] : e.palette.grey[800], r = e.palette.mode === "light" ? e.palette.grey.A100 : e.palette.grey[700];
  return {
    ...e.typography.button,
    minWidth: 64,
    padding: "6px 16px",
    border: 0,
    borderRadius: (e.vars || e).shape.borderRadius,
    transition: e.transitions.create(["background-color", "box-shadow", "border-color", "color"], {
      duration: e.transitions.duration.short
    }),
    "&:hover": {
      textDecoration: "none"
    },
    [`&.${Yo.disabled}`]: {
      color: (e.vars || e).palette.action.disabled
    },
    variants: [{
      props: {
        variant: "contained"
      },
      style: {
        color: "var(--variant-containedColor)",
        backgroundColor: "var(--variant-containedBg)",
        boxShadow: (e.vars || e).shadows[2],
        "&:hover": {
          boxShadow: (e.vars || e).shadows[4],
          // Reset on touch devices, it doesn't add specificity
          "@media (hover: none)": {
            boxShadow: (e.vars || e).shadows[2]
          }
        },
        "&:active": {
          boxShadow: (e.vars || e).shadows[8]
        },
        [`&.${Yo.focusVisible}`]: {
          boxShadow: (e.vars || e).shadows[6]
        },
        [`&.${Yo.disabled}`]: {
          color: (e.vars || e).palette.action.disabled,
          boxShadow: (e.vars || e).shadows[0],
          backgroundColor: (e.vars || e).palette.action.disabledBackground
        }
      }
    }, {
      props: {
        variant: "outlined"
      },
      style: {
        padding: "5px 15px",
        border: "1px solid currentColor",
        borderColor: "var(--variant-outlinedBorder, currentColor)",
        backgroundColor: "var(--variant-outlinedBg)",
        color: "var(--variant-outlinedColor)",
        [`&.${Yo.disabled}`]: {
          border: `1px solid ${(e.vars || e).palette.action.disabledBackground}`
        }
      }
    }, {
      props: {
        variant: "text"
      },
      style: {
        padding: "6px 8px",
        color: "var(--variant-textColor)",
        backgroundColor: "var(--variant-textBg)"
      }
    }, ...Object.entries(e.palette).filter(zt()).map(([n]) => ({
      props: {
        color: n
      },
      style: {
        "--variant-textColor": (e.vars || e).palette[n].main,
        "--variant-outlinedColor": (e.vars || e).palette[n].main,
        "--variant-outlinedBorder": e.vars ? `rgba(${e.vars.palette[n].mainChannel} / 0.5)` : Lt(e.palette[n].main, 0.5),
        "--variant-containedColor": (e.vars || e).palette[n].contrastText,
        "--variant-containedBg": (e.vars || e).palette[n].main,
        "@media (hover: hover)": {
          "&:hover": {
            "--variant-containedBg": (e.vars || e).palette[n].dark,
            "--variant-textBg": e.vars ? `rgba(${e.vars.palette[n].mainChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette[n].main, e.palette.action.hoverOpacity),
            "--variant-outlinedBorder": (e.vars || e).palette[n].main,
            "--variant-outlinedBg": e.vars ? `rgba(${e.vars.palette[n].mainChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette[n].main, e.palette.action.hoverOpacity)
          }
        }
      }
    })), {
      props: {
        color: "inherit"
      },
      style: {
        color: "inherit",
        borderColor: "currentColor",
        "--variant-containedBg": e.vars ? e.vars.palette.Button.inheritContainedBg : t,
        "@media (hover: hover)": {
          "&:hover": {
            "--variant-containedBg": e.vars ? e.vars.palette.Button.inheritContainedHoverBg : r,
            "--variant-textBg": e.vars ? `rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette.text.primary, e.palette.action.hoverOpacity),
            "--variant-outlinedBg": e.vars ? `rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette.text.primary, e.palette.action.hoverOpacity)
          }
        }
      }
    }, {
      props: {
        size: "small",
        variant: "text"
      },
      style: {
        padding: "4px 5px",
        fontSize: e.typography.pxToRem(13)
      }
    }, {
      props: {
        size: "large",
        variant: "text"
      },
      style: {
        padding: "8px 11px",
        fontSize: e.typography.pxToRem(15)
      }
    }, {
      props: {
        size: "small",
        variant: "outlined"
      },
      style: {
        padding: "3px 9px",
        fontSize: e.typography.pxToRem(13)
      }
    }, {
      props: {
        size: "large",
        variant: "outlined"
      },
      style: {
        padding: "7px 21px",
        fontSize: e.typography.pxToRem(15)
      }
    }, {
      props: {
        size: "small",
        variant: "contained"
      },
      style: {
        padding: "4px 10px",
        fontSize: e.typography.pxToRem(13)
      }
    }, {
      props: {
        size: "large",
        variant: "contained"
      },
      style: {
        padding: "8px 22px",
        fontSize: e.typography.pxToRem(15)
      }
    }, {
      props: {
        disableElevation: !0
      },
      style: {
        boxShadow: "none",
        "&:hover": {
          boxShadow: "none"
        },
        [`&.${Yo.focusVisible}`]: {
          boxShadow: "none"
        },
        "&:active": {
          boxShadow: "none"
        },
        [`&.${Yo.disabled}`]: {
          boxShadow: "none"
        }
      }
    }, {
      props: {
        fullWidth: !0
      },
      style: {
        width: "100%"
      }
    }]
  };
})), YU = de("span", {
  name: "MuiButton",
  slot: "StartIcon",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.startIcon, t[`iconSize${$e(r.size)}`]];
  }
})({
  display: "inherit",
  marginRight: 8,
  marginLeft: -4,
  variants: [{
    props: {
      size: "small"
    },
    style: {
      marginLeft: -2
    }
  }, ...Av]
}), XU = de("span", {
  name: "MuiButton",
  slot: "EndIcon",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.endIcon, t[`iconSize${$e(r.size)}`]];
  }
})({
  display: "inherit",
  marginRight: -4,
  marginLeft: 8,
  variants: [{
    props: {
      size: "small"
    },
    style: {
      marginRight: -2
    }
  }, ...Av]
}), Gi = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = M.useContext(KU), o = M.useContext(GU), a = zi(n, t), i = Ke({
    props: a,
    name: "MuiButton"
  }), {
    children: s,
    color: l = "primary",
    component: c = "button",
    className: u,
    disabled: f = !1,
    disableElevation: d = !1,
    disableFocusRipple: p = !1,
    endIcon: h,
    focusVisibleClassName: $,
    fullWidth: b = !1,
    size: g = "medium",
    startIcon: y,
    type: S,
    variant: m = "text",
    ...w
  } = i, v = {
    ...i,
    color: l,
    component: c,
    disabled: f,
    disableElevation: d,
    disableFocusRipple: p,
    fullWidth: b,
    size: g,
    type: S,
    variant: m
  }, E = HU(v), I = y && /* @__PURE__ */ P(YU, {
    className: E.startIcon,
    ownerState: v,
    children: y
  }), R = h && /* @__PURE__ */ P(XU, {
    className: E.endIcon,
    ownerState: v,
    children: h
  }), C = o || "";
  return /* @__PURE__ */ ue(JU, {
    ownerState: v,
    className: Ee(n.className, E.root, u, C),
    component: c,
    disabled: f,
    focusRipple: !p,
    focusVisibleClassName: Ee(E.focusVisible, $),
    ref: r,
    type: S,
    ...w,
    classes: E,
    children: [I, s, R]
  });
});
function ZU({ uiSchema: e }) {
  const { submitText: t, norender: r, props: n = {} } = sb(e);
  return r ? null : P(hr, { marginTop: 3, children: P(Gi, { type: "submit", variant: "contained", color: "primary", ...n, children: t }) });
}
function QU(e) {
  return Be("MuiDivider", e);
}
const vg = De("MuiDivider", ["root", "absolute", "fullWidth", "inset", "middle", "flexItem", "light", "vertical", "withChildren", "withChildrenVertical", "textAlignRight", "textAlignLeft", "wrapper", "wrapperVertical"]), eV = (e) => {
  const {
    absolute: t,
    children: r,
    classes: n,
    flexItem: o,
    light: a,
    orientation: i,
    textAlign: s,
    variant: l
  } = e;
  return ze({
    root: ["root", t && "absolute", l, a && "light", i === "vertical" && "vertical", o && "flexItem", r && "withChildren", r && i === "vertical" && "withChildrenVertical", s === "right" && i !== "vertical" && "textAlignRight", s === "left" && i !== "vertical" && "textAlignLeft"],
    wrapper: ["wrapper", i === "vertical" && "wrapperVertical"]
  }, QU, n);
}, tV = de("div", {
  name: "MuiDivider",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.absolute && t.absolute, t[r.variant], r.light && t.light, r.orientation === "vertical" && t.vertical, r.flexItem && t.flexItem, r.children && t.withChildren, r.children && r.orientation === "vertical" && t.withChildrenVertical, r.textAlign === "right" && r.orientation !== "vertical" && t.textAlignRight, r.textAlign === "left" && r.orientation !== "vertical" && t.textAlignLeft];
  }
})(je(({
  theme: e
}) => ({
  margin: 0,
  // Reset browser default style.
  flexShrink: 0,
  borderWidth: 0,
  borderStyle: "solid",
  borderColor: (e.vars || e).palette.divider,
  borderBottomWidth: "thin",
  variants: [{
    props: {
      absolute: !0
    },
    style: {
      position: "absolute",
      bottom: 0,
      left: 0,
      width: "100%"
    }
  }, {
    props: {
      light: !0
    },
    style: {
      borderColor: e.vars ? `rgba(${e.vars.palette.dividerChannel} / 0.08)` : Lt(e.palette.divider, 0.08)
    }
  }, {
    props: {
      variant: "inset"
    },
    style: {
      marginLeft: 72
    }
  }, {
    props: {
      variant: "middle",
      orientation: "horizontal"
    },
    style: {
      marginLeft: e.spacing(2),
      marginRight: e.spacing(2)
    }
  }, {
    props: {
      variant: "middle",
      orientation: "vertical"
    },
    style: {
      marginTop: e.spacing(1),
      marginBottom: e.spacing(1)
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      height: "100%",
      borderBottomWidth: 0,
      borderRightWidth: "thin"
    }
  }, {
    props: {
      flexItem: !0
    },
    style: {
      alignSelf: "stretch",
      height: "auto"
    }
  }, {
    props: ({
      ownerState: t
    }) => !!t.children,
    style: {
      display: "flex",
      textAlign: "center",
      border: 0,
      borderTopStyle: "solid",
      borderLeftStyle: "solid",
      "&::before, &::after": {
        content: '""',
        alignSelf: "center"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.children && t.orientation !== "vertical",
    style: {
      "&::before, &::after": {
        width: "100%",
        borderTop: `thin solid ${(e.vars || e).palette.divider}`,
        borderTopStyle: "inherit"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.orientation === "vertical" && t.children,
    style: {
      flexDirection: "column",
      "&::before, &::after": {
        height: "100%",
        borderLeft: `thin solid ${(e.vars || e).palette.divider}`,
        borderLeftStyle: "inherit"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.textAlign === "right" && t.orientation !== "vertical",
    style: {
      "&::before": {
        width: "90%"
      },
      "&::after": {
        width: "10%"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.textAlign === "left" && t.orientation !== "vertical",
    style: {
      "&::before": {
        width: "10%"
      },
      "&::after": {
        width: "90%"
      }
    }
  }]
}))), rV = de("span", {
  name: "MuiDivider",
  slot: "Wrapper",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.wrapper, r.orientation === "vertical" && t.wrapperVertical];
  }
})(je(({
  theme: e
}) => ({
  display: "inline-block",
  paddingLeft: `calc(${e.spacing(1)} * 1.2)`,
  paddingRight: `calc(${e.spacing(1)} * 1.2)`,
  whiteSpace: "nowrap",
  variants: [{
    props: {
      orientation: "vertical"
    },
    style: {
      paddingTop: `calc(${e.spacing(1)} * 1.2)`,
      paddingBottom: `calc(${e.spacing(1)} * 1.2)`
    }
  }]
}))), Xu = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiDivider"
  }), {
    absolute: o = !1,
    children: a,
    className: i,
    orientation: s = "horizontal",
    component: l = a || s === "vertical" ? "div" : "hr",
    flexItem: c = !1,
    light: u = !1,
    role: f = l !== "hr" ? "separator" : void 0,
    textAlign: d = "center",
    variant: p = "fullWidth",
    ...h
  } = n, $ = {
    ...n,
    absolute: o,
    component: l,
    flexItem: c,
    light: u,
    orientation: s,
    role: f,
    textAlign: d,
    variant: p
  }, b = eV($);
  return /* @__PURE__ */ P(tV, {
    as: l,
    className: Ee(b.root, i),
    role: f,
    ref: r,
    ownerState: $,
    "aria-orientation": f === "separator" && (l !== "hr" || s === "vertical") ? s : void 0,
    ...h,
    children: a ? /* @__PURE__ */ P(rV, {
      className: b.wrapper,
      ownerState: $,
      children: a
    }) : null
  });
});
Xu && (Xu.muiSkipListHighlight = !0);
function nV({ id: e, title: t }) {
  return ue(hr, { id: e, mb: 1, mt: 1, children: [P(sr, { variant: "h5", children: t }), P(Xu, {})] });
}
function oV(e) {
  const { children: t, classNames: r, style: n, disabled: o, id: a, label: i, onDropPropertyClick: s, onKeyChange: l, readonly: c, required: u, schema: f, uiSchema: d, registry: p } = e, { templates: h, translateString: $ } = p, { RemoveButton: b } = h.ButtonTemplates, g = $(ot.KeyLabel, [i]), y = ka in f, S = {
    flex: 1,
    paddingLeft: 6,
    paddingRight: 6,
    fontWeight: "bold"
  };
  if (!y)
    return P("div", { className: r, style: n, children: t });
  const m = ({ target: w }) => l(w && w.value);
  return ue(Rr, { container: !0, alignItems: "center", spacing: 2, className: r, style: n, children: [P(Rr, { item: !0, xs: !0, children: P(Bf, { fullWidth: !0, required: u, label: g, defaultValue: i, disabled: o || c, id: `${a}-key`, name: `${a}-key`, onBlur: c ? void 0 : m, type: "text" }) }), P(Rr, { item: !0, xs: !0, children: t }), P(Rr, { item: !0, children: P(b, { iconType: "default", style: S, disabled: o || c, onClick: s(i), uiSchema: d, registry: p }) })] }, `${a}-key`);
}
function aV() {
  return {
    ArrayFieldItemTemplate: uz,
    ArrayFieldTemplate: dz,
    BaseInputTemplate: sU,
    ButtonTemplates: {
      AddButton: KB,
      CopyButton: jU,
      MoveDownButton: DU,
      MoveUpButton: LU,
      RemoveButton: BU,
      SubmitButton: ZU
    },
    DescriptionFieldTemplate: pU,
    ErrorListTemplate: RU,
    FieldErrorTemplate: zU,
    FieldHelpTemplate: UU,
    FieldTemplate: VU,
    ObjectFieldTemplate: qU,
    TitleFieldTemplate: nV,
    WrapIfAdditionalTemplate: oV
  };
}
function iV(e) {
  return Be("PrivateSwitchBase", e);
}
De("PrivateSwitchBase", ["root", "checked", "disabled", "input", "edgeStart", "edgeEnd"]);
const sV = (e) => {
  const {
    classes: t,
    checked: r,
    disabled: n,
    edge: o
  } = e, a = {
    root: ["root", r && "checked", n && "disabled", o && `edge${$e(o)}`],
    input: ["input"]
  };
  return ze(a, iV, t);
}, lV = de(hs)({
  padding: 9,
  borderRadius: "50%",
  variants: [{
    props: {
      edge: "start",
      size: "small"
    },
    style: {
      marginLeft: -3
    }
  }, {
    props: ({
      edge: e,
      ownerState: t
    }) => e === "start" && t.size !== "small",
    style: {
      marginLeft: -12
    }
  }, {
    props: {
      edge: "end",
      size: "small"
    },
    style: {
      marginRight: -3
    }
  }, {
    props: ({
      edge: e,
      ownerState: t
    }) => e === "end" && t.size !== "small",
    style: {
      marginRight: -12
    }
  }]
}), cV = de("input", {
  shouldForwardProp: cr
})({
  cursor: "inherit",
  position: "absolute",
  opacity: 0,
  width: "100%",
  height: "100%",
  top: 0,
  left: 0,
  margin: 0,
  padding: 0,
  zIndex: 1
}), Iv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    autoFocus: n,
    checked: o,
    checkedIcon: a,
    className: i,
    defaultChecked: s,
    disabled: l,
    disableFocusRipple: c = !1,
    edge: u = !1,
    icon: f,
    id: d,
    inputProps: p,
    inputRef: h,
    name: $,
    onBlur: b,
    onChange: g,
    onFocus: y,
    readOnly: S,
    required: m = !1,
    tabIndex: w,
    type: v,
    value: E,
    ...I
  } = t, [R, C] = Bi({
    controlled: o,
    default: !!s,
    name: "SwitchBase",
    state: "checked"
  }), T = Sn(), F = (Y) => {
    y && y(Y), T && T.onFocus && T.onFocus(Y);
  }, D = (Y) => {
    b && b(Y), T && T.onBlur && T.onBlur(Y);
  }, z = (Y) => {
    if (Y.nativeEvent.defaultPrevented)
      return;
    const H = Y.target.checked;
    C(H), g && g(Y, H);
  };
  let L = l;
  T && typeof L > "u" && (L = T.disabled);
  const X = v === "checkbox" || v === "radio", V = {
    ...t,
    checked: R,
    disabled: L,
    disableFocusRipple: c,
    edge: u
  }, ie = sV(V);
  return /* @__PURE__ */ ue(lV, {
    component: "span",
    className: Ee(ie.root, i),
    centerRipple: !0,
    focusRipple: !c,
    disabled: L,
    tabIndex: null,
    role: void 0,
    onFocus: F,
    onBlur: D,
    ownerState: V,
    ref: r,
    ...I,
    children: [/* @__PURE__ */ P(cV, {
      autoFocus: n,
      checked: o,
      defaultChecked: s,
      className: ie.input,
      disabled: L,
      id: X ? d : void 0,
      name: $,
      onChange: z,
      readOnly: S,
      ref: h,
      required: m,
      ownerState: V,
      tabIndex: w,
      type: v,
      ...v === "checkbox" && E === void 0 ? {} : {
        value: E
      },
      ...p
    }), R ? a : f]
  });
}), uV = gr(/* @__PURE__ */ P("path", {
  d: "M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"
}), "CheckBoxOutlineBlank"), dV = gr(/* @__PURE__ */ P("path", {
  d: "M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"
}), "CheckBox"), fV = gr(/* @__PURE__ */ P("path", {
  d: "M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"
}), "IndeterminateCheckBox");
function pV(e) {
  return Be("MuiCheckbox", e);
}
const hu = De("MuiCheckbox", ["root", "checked", "disabled", "indeterminate", "colorPrimary", "colorSecondary", "sizeSmall", "sizeMedium"]), hV = (e) => {
  const {
    classes: t,
    indeterminate: r,
    color: n,
    size: o
  } = e, a = {
    root: ["root", r && "indeterminate", `color${$e(n)}`, `size${$e(o)}`]
  }, i = ze(a, pV, t);
  return {
    ...t,
    // forward the disabled and checked classes to the SwitchBase
    ...i
  };
}, mV = de(Iv, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiCheckbox",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.indeterminate && t.indeterminate, t[`size${$e(r.size)}`], r.color !== "default" && t[`color${$e(r.color)}`]];
  }
})(je(({
  theme: e
}) => ({
  color: (e.vars || e).palette.text.secondary,
  variants: [{
    props: {
      color: "default",
      disableRipple: !1
    },
    style: {
      "&:hover": {
        backgroundColor: e.vars ? `rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette.action.active, e.palette.action.hoverOpacity)
      }
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t,
      disableRipple: !1
    },
    style: {
      "&:hover": {
        backgroundColor: e.vars ? `rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette[t].main, e.palette.action.hoverOpacity)
      }
    }
  })), ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      [`&.${hu.checked}, &.${hu.indeterminate}`]: {
        color: (e.vars || e).palette[t].main
      },
      [`&.${hu.disabled}`]: {
        color: (e.vars || e).palette.action.disabled
      }
    }
  })), {
    // Should be last to override other colors
    props: {
      disableRipple: !1
    },
    style: {
      // Reset on touch devices, it doesn't add specificity
      "&:hover": {
        "@media (hover: none)": {
          backgroundColor: "transparent"
        }
      }
    }
  }]
}))), gV = /* @__PURE__ */ P(dV, {}), yV = /* @__PURE__ */ P(uV, {}), bV = /* @__PURE__ */ P(fV, {}), Rv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCheckbox"
  }), {
    checkedIcon: o = gV,
    color: a = "primary",
    icon: i = yV,
    indeterminate: s = !1,
    indeterminateIcon: l = bV,
    inputProps: c,
    size: u = "medium",
    disableRipple: f = !1,
    className: d,
    ...p
  } = n, h = s ? l : i, $ = s ? l : o, b = {
    ...n,
    disableRipple: f,
    color: a,
    indeterminate: s,
    size: u
  }, g = hV(b);
  return /* @__PURE__ */ P(mV, {
    type: "checkbox",
    inputProps: {
      "data-indeterminate": s,
      ...c
    },
    icon: /* @__PURE__ */ M.cloneElement(h, {
      fontSize: h.props.fontSize ?? u
    }),
    checkedIcon: /* @__PURE__ */ M.cloneElement($, {
      fontSize: $.props.fontSize ?? u
    }),
    ownerState: b,
    ref: r,
    className: Ee(g.root, d),
    disableRipple: f,
    ...p,
    classes: g
  });
});
function vV(e) {
  return Be("MuiFormControlLabel", e);
}
const bi = De("MuiFormControlLabel", ["root", "labelPlacementStart", "labelPlacementTop", "labelPlacementBottom", "disabled", "label", "error", "required", "asterisk"]), $V = (e) => {
  const {
    classes: t,
    disabled: r,
    labelPlacement: n,
    error: o,
    required: a
  } = e, i = {
    root: ["root", r && "disabled", `labelPlacement${$e(n)}`, o && "error", a && "required"],
    label: ["label", r && "disabled"],
    asterisk: ["asterisk", o && "error"]
  };
  return ze(i, vV, t);
}, SV = de("label", {
  name: "MuiFormControlLabel",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [{
      [`& .${bi.label}`]: t.label
    }, t.root, t[`labelPlacement${$e(r.labelPlacement)}`]];
  }
})(je(({
  theme: e
}) => ({
  display: "inline-flex",
  alignItems: "center",
  cursor: "pointer",
  // For correct alignment with the text.
  verticalAlign: "middle",
  WebkitTapHighlightColor: "transparent",
  marginLeft: -11,
  marginRight: 16,
  // used for row presentation of radio/checkbox
  [`&.${bi.disabled}`]: {
    cursor: "default"
  },
  [`& .${bi.label}`]: {
    [`&.${bi.disabled}`]: {
      color: (e.vars || e).palette.text.disabled
    }
  },
  variants: [{
    props: {
      labelPlacement: "start"
    },
    style: {
      flexDirection: "row-reverse",
      marginRight: -11
    }
  }, {
    props: {
      labelPlacement: "top"
    },
    style: {
      flexDirection: "column-reverse"
    }
  }, {
    props: {
      labelPlacement: "bottom"
    },
    style: {
      flexDirection: "column"
    }
  }, {
    props: ({
      labelPlacement: t
    }) => t === "start" || t === "top" || t === "bottom",
    style: {
      marginLeft: 16
      // used for row presentation of radio/checkbox
    }
  }]
}))), wV = de("span", {
  name: "MuiFormControlLabel",
  slot: "Asterisk",
  overridesResolver: (e, t) => t.asterisk
})(je(({
  theme: e
}) => ({
  [`&.${bi.error}`]: {
    color: (e.vars || e).palette.error.main
  }
}))), zf = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFormControlLabel"
  }), {
    checked: o,
    className: a,
    componentsProps: i = {},
    control: s,
    disabled: l,
    disableTypography: c,
    inputRef: u,
    label: f,
    labelPlacement: d = "end",
    name: p,
    onChange: h,
    required: $,
    slots: b = {},
    slotProps: g = {},
    value: y,
    ...S
  } = n, m = Sn(), w = l ?? s.props.disabled ?? (m == null ? void 0 : m.disabled), v = $ ?? s.props.required, E = {
    disabled: w,
    required: v
  };
  ["checked", "name", "onChange", "value", "inputRef"].forEach((L) => {
    typeof s.props[L] > "u" && typeof n[L] < "u" && (E[L] = n[L]);
  });
  const I = po({
    props: n,
    muiFormControl: m,
    states: ["error"]
  }), R = {
    ...n,
    disabled: w,
    labelPlacement: d,
    required: v,
    error: I.error
  }, C = $V(R), T = {
    slots: b,
    slotProps: {
      ...i,
      ...g
    }
  }, [F, D] = Sr("typography", {
    elementType: sr,
    externalForwardedProps: T,
    ownerState: R
  });
  let z = f;
  return z != null && z.type !== sr && !c && (z = /* @__PURE__ */ P(F, {
    component: "span",
    ...D,
    className: Ee(C.label, D == null ? void 0 : D.className),
    children: z
  })), /* @__PURE__ */ ue(SV, {
    className: Ee(C.root, a),
    ownerState: R,
    ref: r,
    ...S,
    children: [/* @__PURE__ */ M.cloneElement(s, E), v ? /* @__PURE__ */ ue("div", {
      children: [z, /* @__PURE__ */ ue(wV, {
        ownerState: R,
        "aria-hidden": !0,
        className: C.asterisk,
        children: [" ", "*"]
      })]
    }) : z]
  });
});
function CV(e) {
  var t;
  const { schema: r, id: n, value: o, disabled: a, readonly: i, label: s = "", hideLabel: l, autofocus: c, onChange: u, onBlur: f, onFocus: d, registry: p, options: h, uiSchema: $ } = e, b = Ye("DescriptionFieldTemplate", p, h), g = wi(r), y = (v, E) => u(E), S = ({ target: v }) => f(n, v && v.value), m = ({ target: v }) => d(n, v && v.value), w = (t = h.description) !== null && t !== void 0 ? t : r.description;
  return ue(Wt, { children: [!l && !!w && P(b, { id: Lo(n), description: w, schema: r, uiSchema: $, registry: p }), P(zf, { control: P(Rv, { id: n, name: n, checked: typeof o > "u" ? !1 : !!o, required: g, disabled: a || i, autoFocus: c, onChange: y, onBlur: S, onFocus: m, "aria-describedby": Mr(n) }), label: Bo(s, l, !1) })] });
}
function EV(e) {
  return Be("MuiFormGroup", e);
}
De("MuiFormGroup", ["root", "row", "error"]);
const _V = (e) => {
  const {
    classes: t,
    row: r,
    error: n
  } = e;
  return ze({
    root: ["root", r && "row", n && "error"]
  }, EV, t);
}, xV = de("div", {
  name: "MuiFormGroup",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.row && t.row];
  }
})({
  display: "flex",
  flexDirection: "column",
  flexWrap: "wrap",
  variants: [{
    props: {
      row: !0
    },
    style: {
      flexDirection: "row"
    }
  }]
}), Tv = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiFormGroup"
  }), {
    className: o,
    row: a = !1,
    ...i
  } = n, s = Sn(), l = po({
    props: n,
    muiFormControl: s,
    states: ["error"]
  }), c = {
    ...n,
    row: a,
    error: l.error
  }, u = _V(c);
  return /* @__PURE__ */ P(xV, {
    className: Ee(u.root, o),
    ownerState: c,
    ref: r,
    ...i
  });
});
function PV({ label: e, hideLabel: t, id: r, disabled: n, options: o, value: a, autofocus: i, readonly: s, required: l, onChange: c, onBlur: u, onFocus: f }) {
  const { enumOptions: d, enumDisabled: p, inline: h, emptyValue: $ } = o, b = Array.isArray(a) ? a : [a], g = (m) => ({ target: { checked: w } }) => {
    c(w ? ob(m, b, d) : rb(m, b, d));
  }, y = ({ target: m }) => u(r, Yt(m && m.value, d, $)), S = ({ target: m }) => f(r, Yt(m && m.value, d, $));
  return ue(Wt, { children: [Bo(P(xc, { required: l, htmlFor: r, children: e || void 0 }), t), P(Tv, { id: r, row: !!h, children: Array.isArray(d) && d.map((m, w) => {
    const v = ec(m.value, b), E = Array.isArray(p) && p.indexOf(m.value) !== -1, I = P(Rv, { id: tc(r, w), name: r, checked: v, disabled: n || E || s, autoFocus: i && w === 0, onChange: g(w), onBlur: y, onFocus: S, "aria-describedby": Mr(r) });
    return P(zf, { control: I, label: m.label }, w);
  }) })] });
}
const kV = gr(/* @__PURE__ */ P("path", {
  d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"
}), "RadioButtonUnchecked"), OV = gr(/* @__PURE__ */ P("path", {
  d: "M8.465 8.465C9.37 7.56 10.62 7 12 7C14.76 7 17 9.24 17 12C17 13.38 16.44 14.63 15.535 15.535C14.63 16.44 13.38 17 12 17C9.24 17 7 14.76 7 12C7 10.62 7.56 9.37 8.465 8.465Z"
}), "RadioButtonChecked"), AV = de("span", {
  shouldForwardProp: cr
})({
  position: "relative",
  display: "flex"
}), IV = de(kV)({
  // Scale applied to prevent dot misalignment in Safari
  transform: "scale(1)"
}), RV = de(OV)(je(({
  theme: e
}) => ({
  left: 0,
  position: "absolute",
  transform: "scale(0)",
  transition: e.transitions.create("transform", {
    easing: e.transitions.easing.easeIn,
    duration: e.transitions.duration.shortest
  }),
  variants: [{
    props: {
      checked: !0
    },
    style: {
      transform: "scale(1)",
      transition: e.transitions.create("transform", {
        easing: e.transitions.easing.easeOut,
        duration: e.transitions.duration.shortest
      })
    }
  }]
})));
function Mv(e) {
  const {
    checked: t = !1,
    classes: r = {},
    fontSize: n
  } = e, o = {
    ...e,
    checked: t
  };
  return /* @__PURE__ */ ue(AV, {
    className: r.root,
    ownerState: o,
    children: [/* @__PURE__ */ P(IV, {
      fontSize: n,
      className: r.background,
      ownerState: o
    }), /* @__PURE__ */ P(RV, {
      fontSize: n,
      className: r.dot,
      ownerState: o
    })]
  });
}
const Nv = /* @__PURE__ */ M.createContext(void 0);
function TV() {
  return M.useContext(Nv);
}
function MV(e) {
  return Be("MuiRadio", e);
}
const $g = De("MuiRadio", ["root", "checked", "disabled", "colorPrimary", "colorSecondary", "sizeSmall"]), NV = (e) => {
  const {
    classes: t,
    color: r,
    size: n
  } = e, o = {
    root: ["root", `color${$e(r)}`, n !== "medium" && `size${$e(n)}`]
  };
  return {
    ...t,
    ...ze(o, MV, t)
  };
}, FV = de(Iv, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiRadio",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, r.size !== "medium" && t[`size${$e(r.size)}`], t[`color${$e(r.color)}`]];
  }
})(je(({
  theme: e
}) => ({
  color: (e.vars || e).palette.text.secondary,
  [`&.${$g.disabled}`]: {
    color: (e.vars || e).palette.action.disabled
  },
  variants: [{
    props: {
      color: "default",
      disabled: !1,
      disableRipple: !1
    },
    style: {
      "&:hover": {
        backgroundColor: e.vars ? `rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette.action.active, e.palette.action.hoverOpacity)
      }
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t,
      disabled: !1,
      disableRipple: !1
    },
    style: {
      "&:hover": {
        backgroundColor: e.vars ? `rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})` : Lt(e.palette[t].main, e.palette.action.hoverOpacity)
      }
    }
  })), ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t,
      disabled: !1
    },
    style: {
      [`&.${$g.checked}`]: {
        color: (e.vars || e).palette[t].main
      }
    }
  })), {
    // Should be last to override other colors
    props: {
      disableRipple: !1
    },
    style: {
      // Reset on touch devices, it doesn't add specificity
      "&:hover": {
        "@media (hover: none)": {
          backgroundColor: "transparent"
        }
      }
    }
  }]
})));
function jV(e, t) {
  return typeof t == "object" && t !== null ? e === t : String(e) === String(t);
}
const Sg = /* @__PURE__ */ P(Mv, {
  checked: !0
}), wg = /* @__PURE__ */ P(Mv, {}), DV = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiRadio"
  }), {
    checked: o,
    checkedIcon: a = Sg,
    color: i = "primary",
    icon: s = wg,
    name: l,
    onChange: c,
    size: u = "medium",
    className: f,
    disabled: d,
    disableRipple: p = !1,
    ...h
  } = n, $ = Sn();
  let b = d;
  $ && typeof b > "u" && (b = $.disabled), b ?? (b = !1);
  const g = {
    ...n,
    disabled: b,
    disableRipple: p,
    color: i,
    size: u
  }, y = NV(g), S = TV();
  let m = o;
  const w = ju(c, S && S.onChange);
  let v = l;
  return S && (typeof m > "u" && (m = jV(S.value, n.value)), typeof v > "u" && (v = S.name)), /* @__PURE__ */ P(FV, {
    type: "radio",
    icon: /* @__PURE__ */ M.cloneElement(s, {
      fontSize: wg.props.fontSize ?? u
    }),
    checkedIcon: /* @__PURE__ */ M.cloneElement(a, {
      fontSize: Sg.props.fontSize ?? u
    }),
    disabled: b,
    ownerState: g,
    classes: y,
    name: v,
    checked: m,
    onChange: w,
    ref: r,
    className: Ee(y.root, f),
    ...h
  });
});
function LV(e) {
  return Be("MuiRadioGroup", e);
}
De("MuiRadioGroup", ["root", "row", "error"]);
const BV = (e) => {
  const {
    classes: t,
    row: r,
    error: n
  } = e;
  return ze({
    root: ["root", r && "row", n && "error"]
  }, LV, t);
}, zV = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const {
    // private
    // eslint-disable-next-line react/prop-types
    actions: n,
    children: o,
    className: a,
    defaultValue: i,
    name: s,
    onChange: l,
    value: c,
    ...u
  } = t, f = M.useRef(null), d = BV(t), [p, h] = Bi({
    controlled: c,
    default: i,
    name: "RadioGroup"
  });
  M.useImperativeHandle(n, () => ({
    focus: () => {
      let y = f.current.querySelector("input:not(:disabled):checked");
      y || (y = f.current.querySelector("input:not(:disabled)")), y && y.focus();
    }
  }), []);
  const $ = Bt(r, f), b = df(s), g = M.useMemo(() => ({
    name: b,
    onChange(y) {
      h(y.target.value), l && l(y, y.target.value);
    },
    value: p
  }), [b, l, h, p]);
  return /* @__PURE__ */ P(Nv.Provider, {
    value: g,
    children: /* @__PURE__ */ P(Tv, {
      role: "radiogroup",
      ref: $,
      className: Ee(d.root, a),
      ...u,
      children: o
    })
  });
});
function UV({ id: e, options: t, value: r, required: n, disabled: o, readonly: a, label: i, hideLabel: s, onChange: l, onBlur: c, onFocus: u }) {
  var f;
  const { enumOptions: d, enumDisabled: p, emptyValue: h } = t, $ = (m, w) => l(Yt(w, d, h)), b = ({ target: m }) => c(e, Yt(m && m.value, d, h)), g = ({ target: m }) => u(e, Yt(m && m.value, d, h)), y = t ? t.inline : !1, S = (f = nf(r, d)) !== null && f !== void 0 ? f : null;
  return ue(Wt, { children: [Bo(P(xc, { required: n, htmlFor: e, children: i || void 0 }), s), P(zV, { id: e, name: e, value: S, row: y, onChange: $, onBlur: b, onFocus: g, "aria-describedby": Mr(e), children: Array.isArray(d) && d.map((m, w) => {
    const v = Array.isArray(p) && p.indexOf(m.value) !== -1;
    return P(zf, { control: P(DV, { name: e, id: tc(e, w), color: "primary" }), label: m.label, value: String(w), disabled: o || v || a }, w);
  }) })] });
}
function VV(e, t, r = (n, o) => n === o) {
  return e.length === t.length && e.every((n, o) => r(n, t[o]));
}
const qV = 2;
function Xo(e, t, r, n, o) {
  return r === 1 ? Math.min(e + t, o) : Math.max(e - t, n);
}
function Fv(e, t) {
  return e - t;
}
function Cg(e, t) {
  const {
    index: r
  } = e.reduce((n, o, a) => {
    const i = Math.abs(t - o);
    return n === null || i < n.distance || i === n.distance ? {
      distance: i,
      index: a
    } : n;
  }, null) ?? {};
  return r;
}
function Ms(e, t) {
  if (t.current !== void 0 && e.changedTouches) {
    const r = e;
    for (let n = 0; n < r.changedTouches.length; n += 1) {
      const o = r.changedTouches[n];
      if (o.identifier === t.current)
        return {
          x: o.clientX,
          y: o.clientY
        };
    }
    return !1;
  }
  return {
    x: e.clientX,
    y: e.clientY
  };
}
function Pl(e, t, r) {
  return (e - t) * 100 / (r - t);
}
function WV(e, t, r) {
  return (r - t) * e + t;
}
function KV(e) {
  if (Math.abs(e) < 1) {
    const r = e.toExponential().split("e-"), n = r[0].split(".")[1];
    return (n ? n.length : 0) + parseInt(r[1], 10);
  }
  const t = e.toString().split(".")[1];
  return t ? t.length : 0;
}
function GV(e, t, r) {
  const n = Math.round((e - r) / t) * t + r;
  return Number(n.toFixed(KV(t)));
}
function Eg({
  values: e,
  newValue: t,
  index: r
}) {
  const n = e.slice();
  return n[r] = t, n.sort(Fv);
}
function Ns({
  sliderRef: e,
  activeIndex: t,
  setActive: r
}) {
  var o, a, i;
  const n = mr(e.current);
  (!((o = e.current) != null && o.contains(n.activeElement)) || Number((a = n == null ? void 0 : n.activeElement) == null ? void 0 : a.getAttribute("data-index")) !== t) && ((i = e.current) == null || i.querySelector(`[type="range"][data-index="${t}"]`).focus()), r && r(t);
}
function Fs(e, t) {
  return typeof e == "number" && typeof t == "number" ? e === t : typeof e == "object" && typeof t == "object" ? VV(e, t) : !1;
}
const HV = {
  horizontal: {
    offset: (e) => ({
      left: `${e}%`
    }),
    leap: (e) => ({
      width: `${e}%`
    })
  },
  "horizontal-reverse": {
    offset: (e) => ({
      right: `${e}%`
    }),
    leap: (e) => ({
      width: `${e}%`
    })
  },
  vertical: {
    offset: (e) => ({
      bottom: `${e}%`
    }),
    leap: (e) => ({
      height: `${e}%`
    })
  }
}, JV = (e) => e;
let js;
function _g() {
  return js === void 0 && (typeof CSS < "u" && typeof CSS.supports == "function" ? js = CSS.supports("touch-action", "none") : js = !0), js;
}
function YV(e) {
  const {
    "aria-labelledby": t,
    defaultValue: r,
    disabled: n = !1,
    disableSwap: o = !1,
    isRtl: a = !1,
    marks: i = !1,
    max: s = 100,
    min: l = 0,
    name: c,
    onChange: u,
    onChangeCommitted: f,
    orientation: d = "horizontal",
    rootRef: p,
    scale: h = JV,
    step: $ = 1,
    shiftStep: b = 10,
    tabIndex: g,
    value: y
  } = e, S = M.useRef(void 0), [m, w] = M.useState(-1), [v, E] = M.useState(-1), [I, R] = M.useState(!1), C = M.useRef(0), [T, F] = Bi({
    controlled: y,
    default: r ?? l,
    name: "Slider"
  }), D = u && ((re, fe, ve) => {
    const Ie = re.nativeEvent || re, Le = new Ie.constructor(Ie.type, Ie);
    Object.defineProperty(Le, "target", {
      writable: !0,
      value: {
        value: fe,
        name: c
      }
    }), u(Le, fe, ve);
  }), z = Array.isArray(T);
  let L = z ? T.slice().sort(Fv) : [T];
  L = L.map((re) => re == null ? l : ta(re, l, s));
  const X = i === !0 && $ !== null ? [...Array(Math.floor((s - l) / $) + 1)].map((re, fe) => ({
    value: l + $ * fe
  })) : i || [], V = X.map((re) => re.value), [ie, Y] = M.useState(-1), H = M.useRef(null), j = Bt(p, H), Q = (re) => (fe) => {
    var Ie;
    const ve = Number(fe.currentTarget.getAttribute("data-index"));
    vl(fe.target) && Y(ve), E(ve), (Ie = re == null ? void 0 : re.onFocus) == null || Ie.call(re, fe);
  }, q = (re) => (fe) => {
    var ve;
    vl(fe.target) || Y(-1), E(-1), (ve = re == null ? void 0 : re.onBlur) == null || ve.call(re, fe);
  }, O = (re, fe) => {
    const ve = Number(re.currentTarget.getAttribute("data-index")), Ie = L[ve], Le = V.indexOf(Ie);
    let K = fe;
    if (X && $ == null) {
      const G = V[V.length - 1];
      K > G ? K = G : K < V[0] ? K = V[0] : K = K < Ie ? V[Le - 1] : V[Le + 1];
    }
    if (K = ta(K, l, s), z) {
      o && (K = ta(K, L[ve - 1] || -1 / 0, L[ve + 1] || 1 / 0));
      const G = K;
      K = Eg({
        values: L,
        newValue: K,
        index: ve
      });
      let ae = ve;
      o || (ae = K.indexOf(G)), Ns({
        sliderRef: H,
        activeIndex: ae
      });
    }
    F(K), Y(ve), D && !Fs(K, T) && D(re, K, ve), f && f(re, K);
  }, N = (re) => (fe) => {
    var ve;
    if (["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight", "PageUp", "PageDown", "Home", "End"].includes(fe.key)) {
      fe.preventDefault();
      const Ie = Number(fe.currentTarget.getAttribute("data-index")), Le = L[Ie];
      let K = null;
      if ($ != null) {
        const G = fe.shiftKey ? b : $;
        switch (fe.key) {
          case "ArrowUp":
            K = Xo(Le, G, 1, l, s);
            break;
          case "ArrowRight":
            K = Xo(Le, G, a ? -1 : 1, l, s);
            break;
          case "ArrowDown":
            K = Xo(Le, G, -1, l, s);
            break;
          case "ArrowLeft":
            K = Xo(Le, G, a ? 1 : -1, l, s);
            break;
          case "PageUp":
            K = Xo(Le, b, 1, l, s);
            break;
          case "PageDown":
            K = Xo(Le, b, -1, l, s);
            break;
          case "Home":
            K = l;
            break;
          case "End":
            K = s;
            break;
        }
      } else if (X) {
        const G = V[V.length - 1], ae = V.indexOf(Le), he = [a ? "ArrowRight" : "ArrowLeft", "ArrowDown", "PageDown", "Home"], Oe = [a ? "ArrowLeft" : "ArrowRight", "ArrowUp", "PageUp", "End"];
        he.includes(fe.key) ? ae === 0 ? K = V[0] : K = V[ae - 1] : Oe.includes(fe.key) && (ae === V.length - 1 ? K = G : K = V[ae + 1]);
      }
      K != null && O(fe, K);
    }
    (ve = re == null ? void 0 : re.onKeyDown) == null || ve.call(re, fe);
  };
  Bn(() => {
    var re;
    n && H.current.contains(document.activeElement) && ((re = document.activeElement) == null || re.blur());
  }, [n]), n && m !== -1 && w(-1), n && ie !== -1 && Y(-1);
  const W = (re) => (fe) => {
    var ve;
    (ve = re.onChange) == null || ve.call(re, fe), O(fe, fe.target.valueAsNumber);
  }, ne = M.useRef(void 0);
  let ee = d;
  a && d === "horizontal" && (ee += "-reverse");
  const pe = ({
    finger: re,
    move: fe = !1
  }) => {
    const {
      current: ve
    } = H, {
      width: Ie,
      height: Le,
      bottom: K,
      left: G
    } = ve.getBoundingClientRect();
    let ae;
    ee.startsWith("vertical") ? ae = (K - re.y) / Le : ae = (re.x - G) / Ie, ee.includes("-reverse") && (ae = 1 - ae);
    let he;
    if (he = WV(ae, l, s), $)
      he = GV(he, $, l);
    else {
      const ut = Cg(V, he);
      he = V[ut];
    }
    he = ta(he, l, s);
    let Oe = 0;
    if (z) {
      fe ? Oe = ne.current : Oe = Cg(L, he), o && (he = ta(he, L[Oe - 1] || -1 / 0, L[Oe + 1] || 1 / 0));
      const ut = he;
      he = Eg({
        values: L,
        newValue: he,
        index: Oe
      }), o && fe || (Oe = he.indexOf(ut), ne.current = Oe);
    }
    return {
      newValue: he,
      activeIndex: Oe
    };
  }, ce = Rn((re) => {
    const fe = Ms(re, S);
    if (!fe)
      return;
    if (C.current += 1, re.type === "mousemove" && re.buttons === 0) {
      ye(re);
      return;
    }
    const {
      newValue: ve,
      activeIndex: Ie
    } = pe({
      finger: fe,
      move: !0
    });
    Ns({
      sliderRef: H,
      activeIndex: Ie,
      setActive: w
    }), F(ve), !I && C.current > qV && R(!0), D && !Fs(ve, T) && D(re, ve, Ie);
  }), ye = Rn((re) => {
    const fe = Ms(re, S);
    if (R(!1), !fe)
      return;
    const {
      newValue: ve
    } = pe({
      finger: fe,
      move: !0
    });
    w(-1), re.type === "touchend" && E(-1), f && f(re, ve), S.current = void 0, Me();
  }), _e = Rn((re) => {
    if (n)
      return;
    _g() || re.preventDefault();
    const fe = re.changedTouches[0];
    fe != null && (S.current = fe.identifier);
    const ve = Ms(re, S);
    if (ve !== !1) {
      const {
        newValue: Le,
        activeIndex: K
      } = pe({
        finger: ve
      });
      Ns({
        sliderRef: H,
        activeIndex: K,
        setActive: w
      }), F(Le), D && !Fs(Le, T) && D(re, Le, K);
    }
    C.current = 0;
    const Ie = mr(H.current);
    Ie.addEventListener("touchmove", ce, {
      passive: !0
    }), Ie.addEventListener("touchend", ye, {
      passive: !0
    });
  }), Me = M.useCallback(() => {
    const re = mr(H.current);
    re.removeEventListener("mousemove", ce), re.removeEventListener("mouseup", ye), re.removeEventListener("touchmove", ce), re.removeEventListener("touchend", ye);
  }, [ye, ce]);
  M.useEffect(() => {
    const {
      current: re
    } = H;
    return re.addEventListener("touchstart", _e, {
      passive: _g()
    }), () => {
      re.removeEventListener("touchstart", _e), Me();
    };
  }, [Me, _e]), M.useEffect(() => {
    n && Me();
  }, [n, Me]);
  const Re = (re) => (fe) => {
    var Le;
    if ((Le = re.onMouseDown) == null || Le.call(re, fe), n || fe.defaultPrevented || fe.button !== 0)
      return;
    fe.preventDefault();
    const ve = Ms(fe, S);
    if (ve !== !1) {
      const {
        newValue: K,
        activeIndex: G
      } = pe({
        finger: ve
      });
      Ns({
        sliderRef: H,
        activeIndex: G,
        setActive: w
      }), F(K), D && !Fs(K, T) && D(fe, K, G);
    }
    C.current = 0;
    const Ie = mr(H.current);
    Ie.addEventListener("mousemove", ce, {
      passive: !0
    }), Ie.addEventListener("mouseup", ye);
  }, Ve = Pl(z ? L[0] : l, l, s), mt = Pl(L[L.length - 1], l, s) - Ve, Ue = (re = {}) => {
    const fe = Ei(re), ve = {
      onMouseDown: Re(fe || {})
    }, Ie = {
      ...fe,
      ...ve
    };
    return {
      ...re,
      ref: j,
      ...Ie
    };
  }, qe = (re) => (fe) => {
    var Ie;
    (Ie = re.onMouseOver) == null || Ie.call(re, fe);
    const ve = Number(fe.currentTarget.getAttribute("data-index"));
    E(ve);
  }, se = (re) => (fe) => {
    var ve;
    (ve = re.onMouseLeave) == null || ve.call(re, fe), E(-1);
  }, Ze = (re = {}) => {
    const fe = Ei(re), ve = {
      onMouseOver: qe(fe || {}),
      onMouseLeave: se(fe || {})
    };
    return {
      ...re,
      ...fe,
      ...ve
    };
  }, rt = (re) => ({
    // So the non active thumb doesn't show its label on hover.
    pointerEvents: m !== -1 && m !== re ? "none" : void 0
  });
  let Ce;
  return d === "vertical" && (Ce = a ? "vertical-rl" : "vertical-lr"), {
    active: m,
    axis: ee,
    axisProps: HV,
    dragging: I,
    focusedThumbIndex: ie,
    getHiddenInputProps: (re = {}) => {
      const fe = Ei(re), ve = {
        onChange: W(fe || {}),
        onFocus: Q(fe || {}),
        onBlur: q(fe || {}),
        onKeyDown: N(fe || {})
      }, Ie = {
        ...fe,
        ...ve
      };
      return {
        tabIndex: g,
        "aria-labelledby": t,
        "aria-orientation": d,
        "aria-valuemax": h(s),
        "aria-valuemin": h(l),
        name: c,
        type: "range",
        min: e.min,
        max: e.max,
        step: e.step === null && e.marks ? "any" : e.step ?? void 0,
        disabled: n,
        ...re,
        ...Ie,
        style: {
          ...j9,
          direction: a ? "rtl" : "ltr",
          // So that VoiceOver's focus indicator matches the thumb's dimensions
          width: "100%",
          height: "100%",
          writingMode: Ce
        }
      };
    },
    getRootProps: Ue,
    getThumbProps: Ze,
    marks: X,
    open: v,
    range: z,
    rootRef: j,
    trackLeap: mt,
    trackOffset: Ve,
    values: L,
    getThumbStyle: rt
  };
}
const XV = (e) => !e || !Tn(e);
function ZV(e) {
  return Be("MuiSlider", e);
}
const qr = De("MuiSlider", ["root", "active", "colorPrimary", "colorSecondary", "colorError", "colorInfo", "colorSuccess", "colorWarning", "disabled", "dragging", "focusVisible", "mark", "markActive", "marked", "markLabel", "markLabelActive", "rail", "sizeSmall", "thumb", "thumbColorPrimary", "thumbColorSecondary", "thumbColorError", "thumbColorSuccess", "thumbColorInfo", "thumbColorWarning", "track", "trackInverted", "trackFalse", "thumbSizeSmall", "valueLabel", "valueLabelOpen", "valueLabelCircle", "valueLabelLabel", "vertical"]), QV = (e) => {
  const {
    open: t
  } = e;
  return {
    offset: Ee(t && qr.valueLabelOpen),
    circle: qr.valueLabelCircle,
    label: qr.valueLabelLabel
  };
};
function eq(e) {
  const {
    children: t,
    className: r,
    value: n
  } = e, o = QV(e);
  return t ? /* @__PURE__ */ M.cloneElement(t, {
    className: Ee(t.props.className)
  }, /* @__PURE__ */ ue(M.Fragment, {
    children: [t.props.children, /* @__PURE__ */ P("span", {
      className: Ee(o.offset, r),
      "aria-hidden": !0,
      children: /* @__PURE__ */ P("span", {
        className: o.circle,
        children: /* @__PURE__ */ P("span", {
          className: o.label,
          children: n
        })
      })
    })]
  })) : null;
}
function xg(e) {
  return e;
}
const tq = de("span", {
  name: "MuiSlider",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[`color${$e(r.color)}`], r.size !== "medium" && t[`size${$e(r.size)}`], r.marked && t.marked, r.orientation === "vertical" && t.vertical, r.track === "inverted" && t.trackInverted, r.track === !1 && t.trackFalse];
  }
})(je(({
  theme: e
}) => ({
  borderRadius: 12,
  boxSizing: "content-box",
  display: "inline-block",
  position: "relative",
  cursor: "pointer",
  touchAction: "none",
  WebkitTapHighlightColor: "transparent",
  "@media print": {
    colorAdjust: "exact"
  },
  [`&.${qr.disabled}`]: {
    pointerEvents: "none",
    cursor: "default",
    color: (e.vars || e).palette.grey[400]
  },
  [`&.${qr.dragging}`]: {
    [`& .${qr.thumb}, & .${qr.track}`]: {
      transition: "none"
    }
  },
  variants: [...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      color: (e.vars || e).palette[t].main
    }
  })), {
    props: {
      orientation: "horizontal"
    },
    style: {
      height: 4,
      width: "100%",
      padding: "13px 0",
      // The primary input mechanism of the device includes a pointing device of limited accuracy.
      "@media (pointer: coarse)": {
        // Reach 42px touch target, about ~8mm on screen.
        padding: "20px 0"
      }
    }
  }, {
    props: {
      orientation: "horizontal",
      size: "small"
    },
    style: {
      height: 2
    }
  }, {
    props: {
      orientation: "horizontal",
      marked: !0
    },
    style: {
      marginBottom: 20
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      height: "100%",
      width: 4,
      padding: "0 13px",
      // The primary input mechanism of the device includes a pointing device of limited accuracy.
      "@media (pointer: coarse)": {
        // Reach 42px touch target, about ~8mm on screen.
        padding: "0 20px"
      }
    }
  }, {
    props: {
      orientation: "vertical",
      size: "small"
    },
    style: {
      width: 2
    }
  }, {
    props: {
      orientation: "vertical",
      marked: !0
    },
    style: {
      marginRight: 44
    }
  }]
}))), rq = de("span", {
  name: "MuiSlider",
  slot: "Rail",
  overridesResolver: (e, t) => t.rail
})({
  display: "block",
  position: "absolute",
  borderRadius: "inherit",
  backgroundColor: "currentColor",
  opacity: 0.38,
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      width: "100%",
      height: "inherit",
      top: "50%",
      transform: "translateY(-50%)"
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      height: "100%",
      width: "inherit",
      left: "50%",
      transform: "translateX(-50%)"
    }
  }, {
    props: {
      track: "inverted"
    },
    style: {
      opacity: 1
    }
  }]
}), nq = de("span", {
  name: "MuiSlider",
  slot: "Track",
  overridesResolver: (e, t) => t.track
})(je(({
  theme: e
}) => ({
  display: "block",
  position: "absolute",
  borderRadius: "inherit",
  border: "1px solid currentColor",
  backgroundColor: "currentColor",
  transition: e.transitions.create(["left", "width", "bottom", "height"], {
    duration: e.transitions.duration.shortest
  }),
  variants: [{
    props: {
      size: "small"
    },
    style: {
      border: "none"
    }
  }, {
    props: {
      orientation: "horizontal"
    },
    style: {
      height: "inherit",
      top: "50%",
      transform: "translateY(-50%)"
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      width: "inherit",
      left: "50%",
      transform: "translateX(-50%)"
    }
  }, {
    props: {
      track: !1
    },
    style: {
      display: "none"
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t,
      track: "inverted"
    },
    style: {
      ...e.vars ? {
        backgroundColor: e.vars.palette.Slider[`${t}Track`],
        borderColor: e.vars.palette.Slider[`${t}Track`]
      } : {
        backgroundColor: wa(e.palette[t].main, 0.62),
        borderColor: wa(e.palette[t].main, 0.62),
        ...e.applyStyles("dark", {
          backgroundColor: Sa(e.palette[t].main, 0.5)
        }),
        ...e.applyStyles("dark", {
          borderColor: Sa(e.palette[t].main, 0.5)
        })
      }
    }
  }))]
}))), oq = de("span", {
  name: "MuiSlider",
  slot: "Thumb",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.thumb, t[`thumbColor${$e(r.color)}`], r.size !== "medium" && t[`thumbSize${$e(r.size)}`]];
  }
})(je(({
  theme: e
}) => ({
  position: "absolute",
  width: 20,
  height: 20,
  boxSizing: "border-box",
  borderRadius: "50%",
  outline: 0,
  backgroundColor: "currentColor",
  display: "flex",
  alignItems: "center",
  justifyContent: "center",
  transition: e.transitions.create(["box-shadow", "left", "bottom"], {
    duration: e.transitions.duration.shortest
  }),
  "&::before": {
    position: "absolute",
    content: '""',
    borderRadius: "inherit",
    width: "100%",
    height: "100%",
    boxShadow: (e.vars || e).shadows[2]
  },
  "&::after": {
    position: "absolute",
    content: '""',
    borderRadius: "50%",
    // 42px is the hit target
    width: 42,
    height: 42,
    top: "50%",
    left: "50%",
    transform: "translate(-50%, -50%)"
  },
  [`&.${qr.disabled}`]: {
    "&:hover": {
      boxShadow: "none"
    }
  },
  variants: [{
    props: {
      size: "small"
    },
    style: {
      width: 12,
      height: 12,
      "&::before": {
        boxShadow: "none"
      }
    }
  }, {
    props: {
      orientation: "horizontal"
    },
    style: {
      top: "50%",
      transform: "translate(-50%, -50%)"
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      left: "50%",
      transform: "translate(-50%, 50%)"
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      [`&:hover, &.${qr.focusVisible}`]: {
        ...e.vars ? {
          boxShadow: `0px 0px 0px 8px rgba(${e.vars.palette[t].mainChannel} / 0.16)`
        } : {
          boxShadow: `0px 0px 0px 8px ${Lt(e.palette[t].main, 0.16)}`
        },
        "@media (hover: none)": {
          boxShadow: "none"
        }
      },
      [`&.${qr.active}`]: {
        ...e.vars ? {
          boxShadow: `0px 0px 0px 14px rgba(${e.vars.palette[t].mainChannel} / 0.16)`
        } : {
          boxShadow: `0px 0px 0px 14px ${Lt(e.palette[t].main, 0.16)}`
        }
      }
    }
  }))]
}))), aq = de(eq, {
  name: "MuiSlider",
  slot: "ValueLabel",
  overridesResolver: (e, t) => t.valueLabel
})(je(({
  theme: e
}) => ({
  zIndex: 1,
  whiteSpace: "nowrap",
  ...e.typography.body2,
  fontWeight: 500,
  transition: e.transitions.create(["transform"], {
    duration: e.transitions.duration.shortest
  }),
  position: "absolute",
  backgroundColor: (e.vars || e).palette.grey[600],
  borderRadius: 2,
  color: (e.vars || e).palette.common.white,
  display: "flex",
  alignItems: "center",
  justifyContent: "center",
  padding: "0.25rem 0.75rem",
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      transform: "translateY(-100%) scale(0)",
      top: "-10px",
      transformOrigin: "bottom center",
      "&::before": {
        position: "absolute",
        content: '""',
        width: 8,
        height: 8,
        transform: "translate(-50%, 50%) rotate(45deg)",
        backgroundColor: "inherit",
        bottom: 0,
        left: "50%"
      },
      [`&.${qr.valueLabelOpen}`]: {
        transform: "translateY(-100%) scale(1)"
      }
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      transform: "translateY(-50%) scale(0)",
      right: "30px",
      top: "50%",
      transformOrigin: "right center",
      "&::before": {
        position: "absolute",
        content: '""',
        width: 8,
        height: 8,
        transform: "translate(-50%, -50%) rotate(45deg)",
        backgroundColor: "inherit",
        right: -8,
        top: "50%"
      },
      [`&.${qr.valueLabelOpen}`]: {
        transform: "translateY(-50%) scale(1)"
      }
    }
  }, {
    props: {
      size: "small"
    },
    style: {
      fontSize: e.typography.pxToRem(12),
      padding: "0.25rem 0.5rem"
    }
  }, {
    props: {
      orientation: "vertical",
      size: "small"
    },
    style: {
      right: "20px"
    }
  }]
}))), iq = de("span", {
  name: "MuiSlider",
  slot: "Mark",
  shouldForwardProp: (e) => Sc(e) && e !== "markActive",
  overridesResolver: (e, t) => {
    const {
      markActive: r
    } = e;
    return [t.mark, r && t.markActive];
  }
})(je(({
  theme: e
}) => ({
  position: "absolute",
  width: 2,
  height: 2,
  borderRadius: 1,
  backgroundColor: "currentColor",
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      top: "50%",
      transform: "translate(-1px, -50%)"
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      left: "50%",
      transform: "translate(-50%, 1px)"
    }
  }, {
    props: {
      markActive: !0
    },
    style: {
      backgroundColor: (e.vars || e).palette.background.paper,
      opacity: 0.8
    }
  }]
}))), sq = de("span", {
  name: "MuiSlider",
  slot: "MarkLabel",
  shouldForwardProp: (e) => Sc(e) && e !== "markLabelActive",
  overridesResolver: (e, t) => t.markLabel
})(je(({
  theme: e
}) => ({
  ...e.typography.body2,
  color: (e.vars || e).palette.text.secondary,
  position: "absolute",
  whiteSpace: "nowrap",
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      top: 30,
      transform: "translateX(-50%)",
      "@media (pointer: coarse)": {
        top: 40
      }
    }
  }, {
    props: {
      orientation: "vertical"
    },
    style: {
      left: 36,
      transform: "translateY(50%)",
      "@media (pointer: coarse)": {
        left: 44
      }
    }
  }, {
    props: {
      markLabelActive: !0
    },
    style: {
      color: (e.vars || e).palette.text.primary
    }
  }]
}))), lq = (e) => {
  const {
    disabled: t,
    dragging: r,
    marked: n,
    orientation: o,
    track: a,
    classes: i,
    color: s,
    size: l
  } = e, c = {
    root: ["root", t && "disabled", r && "dragging", n && "marked", o === "vertical" && "vertical", a === "inverted" && "trackInverted", a === !1 && "trackFalse", s && `color${$e(s)}`, l && `size${$e(l)}`],
    rail: ["rail"],
    track: ["track"],
    mark: ["mark"],
    markActive: ["markActive"],
    markLabel: ["markLabel"],
    markLabelActive: ["markLabelActive"],
    valueLabel: ["valueLabel"],
    thumb: ["thumb", t && "disabled", l && `thumbSize${$e(l)}`, s && `thumbColor${$e(s)}`],
    active: ["active"],
    disabled: ["disabled"],
    focusVisible: ["focusVisible"]
  };
  return ze(c, ZV, i);
}, cq = ({
  children: e
}) => e, uq = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiSlider"
  }), o = xf(), {
    "aria-label": a,
    "aria-valuetext": i,
    "aria-labelledby": s,
    // eslint-disable-next-line react/prop-types
    component: l = "span",
    components: c = {},
    componentsProps: u = {},
    color: f = "primary",
    classes: d,
    className: p,
    disableSwap: h = !1,
    disabled: $ = !1,
    getAriaLabel: b,
    getAriaValueText: g,
    marks: y = !1,
    max: S = 100,
    min: m = 0,
    name: w,
    onChange: v,
    onChangeCommitted: E,
    orientation: I = "horizontal",
    shiftStep: R = 10,
    size: C = "medium",
    step: T = 1,
    scale: F = xg,
    slotProps: D,
    slots: z,
    tabIndex: L,
    track: X = "normal",
    value: V,
    valueLabelDisplay: ie = "off",
    valueLabelFormat: Y = xg,
    ...H
  } = n, j = {
    ...n,
    isRtl: o,
    max: S,
    min: m,
    classes: d,
    disabled: $,
    disableSwap: h,
    orientation: I,
    marks: y,
    color: f,
    size: C,
    step: T,
    shiftStep: R,
    scale: F,
    track: X,
    valueLabelDisplay: ie,
    valueLabelFormat: Y
  }, {
    axisProps: Q,
    getRootProps: q,
    getHiddenInputProps: O,
    getThumbProps: N,
    open: W,
    active: ne,
    axis: ee,
    focusedThumbIndex: pe,
    range: ce,
    dragging: ye,
    marks: _e,
    values: Me,
    trackOffset: Re,
    trackLeap: Ve,
    getThumbStyle: mt
  } = YV({
    ...j,
    rootRef: r
  });
  j.marked = _e.length > 0 && _e.some((it) => it.label), j.dragging = ye, j.focusedThumbIndex = pe;
  const Ue = lq(j), qe = (z == null ? void 0 : z.root) ?? c.Root ?? tq, se = (z == null ? void 0 : z.rail) ?? c.Rail ?? rq, Ze = (z == null ? void 0 : z.track) ?? c.Track ?? nq, rt = (z == null ? void 0 : z.thumb) ?? c.Thumb ?? oq, Ce = (z == null ? void 0 : z.valueLabel) ?? c.ValueLabel ?? aq, Nt = (z == null ? void 0 : z.mark) ?? c.Mark ?? iq, re = (z == null ? void 0 : z.markLabel) ?? c.MarkLabel ?? sq, fe = (z == null ? void 0 : z.input) ?? c.Input ?? "input", ve = (D == null ? void 0 : D.root) ?? u.root, Ie = (D == null ? void 0 : D.rail) ?? u.rail, Le = (D == null ? void 0 : D.track) ?? u.track, K = (D == null ? void 0 : D.thumb) ?? u.thumb, G = (D == null ? void 0 : D.valueLabel) ?? u.valueLabel, ae = (D == null ? void 0 : D.mark) ?? u.mark, he = (D == null ? void 0 : D.markLabel) ?? u.markLabel, Oe = (D == null ? void 0 : D.input) ?? u.input, ut = ln({
    elementType: qe,
    getSlotProps: q,
    externalSlotProps: ve,
    externalForwardedProps: H,
    additionalProps: {
      ...XV(qe) && {
        as: l
      }
    },
    ownerState: {
      ...j,
      ...ve == null ? void 0 : ve.ownerState
    },
    className: [Ue.root, p]
  }), Se = ln({
    elementType: se,
    externalSlotProps: Ie,
    ownerState: j,
    className: Ue.rail
  }), Ne = ln({
    elementType: Ze,
    externalSlotProps: Le,
    additionalProps: {
      style: {
        ...Q[ee].offset(Re),
        ...Q[ee].leap(Ve)
      }
    },
    ownerState: {
      ...j,
      ...Le == null ? void 0 : Le.ownerState
    },
    className: Ue.track
  }), et = ln({
    elementType: rt,
    getSlotProps: N,
    externalSlotProps: K,
    ownerState: {
      ...j,
      ...K == null ? void 0 : K.ownerState
    },
    className: Ue.thumb
  }), It = ln({
    elementType: Ce,
    externalSlotProps: G,
    ownerState: {
      ...j,
      ...G == null ? void 0 : G.ownerState
    },
    className: Ue.valueLabel
  }), Vt = ln({
    elementType: Nt,
    externalSlotProps: ae,
    ownerState: j,
    className: Ue.mark
  }), ur = ln({
    elementType: re,
    externalSlotProps: he,
    ownerState: j,
    className: Ue.markLabel
  }), Ft = ln({
    elementType: fe,
    getSlotProps: O,
    externalSlotProps: Oe,
    ownerState: j
  });
  return /* @__PURE__ */ ue(qe, {
    ...ut,
    children: [/* @__PURE__ */ P(se, {
      ...Se
    }), /* @__PURE__ */ P(Ze, {
      ...Ne
    }), _e.filter((it) => it.value >= m && it.value <= S).map((it, at) => {
      const kt = Pl(it.value, m, S), Jt = Q[ee].offset(kt);
      let yt;
      return X === !1 ? yt = Me.includes(it.value) : yt = X === "normal" && (ce ? it.value >= Me[0] && it.value <= Me[Me.length - 1] : it.value <= Me[0]) || X === "inverted" && (ce ? it.value <= Me[0] || it.value >= Me[Me.length - 1] : it.value >= Me[0]), /* @__PURE__ */ ue(M.Fragment, {
        children: [/* @__PURE__ */ P(Nt, {
          "data-index": at,
          ...Vt,
          ...!Tn(Nt) && {
            markActive: yt
          },
          style: {
            ...Jt,
            ...Vt.style
          },
          className: Ee(Vt.className, yt && Ue.markActive)
        }), it.label != null ? /* @__PURE__ */ P(re, {
          "aria-hidden": !0,
          "data-index": at,
          ...ur,
          ...!Tn(re) && {
            markLabelActive: yt
          },
          style: {
            ...Jt,
            ...ur.style
          },
          className: Ee(Ue.markLabel, ur.className, yt && Ue.markLabelActive),
          children: it.label
        }) : null]
      }, at);
    }), Me.map((it, at) => {
      const kt = Pl(it, m, S), Jt = Q[ee].offset(kt), yt = ie === "off" ? cq : Ce;
      return (
        /* TODO v6: Change component structure. It will help in avoiding the complicated React.cloneElement API added in SliderValueLabel component. Should be: Thumb -> Input, ValueLabel. Follow Joy UI's Slider structure. */
        /* @__PURE__ */ P(yt, {
          ...!Tn(yt) && {
            valueLabelFormat: Y,
            valueLabelDisplay: ie,
            value: typeof Y == "function" ? Y(F(it), at) : Y,
            index: at,
            open: W === at || ne === at || ie === "on",
            disabled: $
          },
          ...It,
          children: /* @__PURE__ */ P(rt, {
            "data-index": at,
            ...et,
            className: Ee(Ue.thumb, et.className, ne === at && Ue.active, pe === at && Ue.focusVisible),
            style: {
              ...Jt,
              ...mt(at),
              ...et.style
            },
            children: /* @__PURE__ */ P(fe, {
              "data-index": at,
              "aria-label": b ? b(at) : a,
              "aria-valuenow": F(it),
              "aria-labelledby": s,
              "aria-valuetext": g ? g(F(it), at) : i,
              value: Me[at],
              ...Ft
            })
          })
        }, at)
      );
    })]
  });
});
function dq(e) {
  const { value: t, readonly: r, disabled: n, onBlur: o, onFocus: a, options: i, schema: s, onChange: l, required: c, label: u, hideLabel: f, id: d } = e, p = { value: t, label: u, id: d, name: d, ...ab(s) }, h = (g, y) => {
    l(y ?? i.emptyValue);
  }, $ = ({ target: g }) => o(d, g && g.value), b = ({ target: g }) => a(d, g && g.value);
  return ue(Wt, { children: [Bo(P(xc, { required: c, htmlFor: d, children: u || void 0 }), f), P(uq, { disabled: n || r, onChange: h, onBlur: $, onFocus: b, valueLabelDisplay: "auto", ...p, "aria-describedby": Mr(d) })] });
}
function fq(e) {
  return Be("MuiMenuItem", e);
}
const ui = De("MuiMenuItem", ["root", "focusVisible", "dense", "disabled", "divider", "gutters", "selected"]), pq = (e, t) => {
  const {
    ownerState: r
  } = e;
  return [t.root, r.dense && t.dense, r.divider && t.divider, !r.disableGutters && t.gutters];
}, hq = (e) => {
  const {
    disabled: t,
    dense: r,
    divider: n,
    disableGutters: o,
    selected: a,
    classes: i
  } = e, l = ze({
    root: ["root", r && "dense", t && "disabled", !o && "gutters", n && "divider", a && "selected"]
  }, fq, i);
  return {
    ...i,
    ...l
  };
}, mq = de(hs, {
  shouldForwardProp: (e) => cr(e) || e === "classes",
  name: "MuiMenuItem",
  slot: "Root",
  overridesResolver: pq
})(je(({
  theme: e
}) => ({
  ...e.typography.body1,
  display: "flex",
  justifyContent: "flex-start",
  alignItems: "center",
  position: "relative",
  textDecoration: "none",
  minHeight: 48,
  paddingTop: 6,
  paddingBottom: 6,
  boxSizing: "border-box",
  whiteSpace: "nowrap",
  "&:hover": {
    textDecoration: "none",
    backgroundColor: (e.vars || e).palette.action.hover,
    // Reset on touch devices, it doesn't add specificity
    "@media (hover: none)": {
      backgroundColor: "transparent"
    }
  },
  [`&.${ui.selected}`]: {
    backgroundColor: e.vars ? `rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})` : Lt(e.palette.primary.main, e.palette.action.selectedOpacity),
    [`&.${ui.focusVisible}`]: {
      backgroundColor: e.vars ? `rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))` : Lt(e.palette.primary.main, e.palette.action.selectedOpacity + e.palette.action.focusOpacity)
    }
  },
  [`&.${ui.selected}:hover`]: {
    backgroundColor: e.vars ? `rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))` : Lt(e.palette.primary.main, e.palette.action.selectedOpacity + e.palette.action.hoverOpacity),
    // Reset on touch devices, it doesn't add specificity
    "@media (hover: none)": {
      backgroundColor: e.vars ? `rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})` : Lt(e.palette.primary.main, e.palette.action.selectedOpacity)
    }
  },
  [`&.${ui.focusVisible}`]: {
    backgroundColor: (e.vars || e).palette.action.focus
  },
  [`&.${ui.disabled}`]: {
    opacity: (e.vars || e).palette.action.disabledOpacity
  },
  [`& + .${vg.root}`]: {
    marginTop: e.spacing(1),
    marginBottom: e.spacing(1)
  },
  [`& + .${vg.inset}`]: {
    marginLeft: 52
  },
  [`& .${ia.root}`]: {
    marginTop: 0,
    marginBottom: 0
  },
  [`& .${ia.inset}`]: {
    paddingLeft: 36
  },
  [`& .${bg.root}`]: {
    minWidth: 36
  },
  variants: [{
    props: ({
      ownerState: t
    }) => !t.disableGutters,
    style: {
      paddingLeft: 16,
      paddingRight: 16
    }
  }, {
    props: ({
      ownerState: t
    }) => t.divider,
    style: {
      borderBottom: `1px solid ${(e.vars || e).palette.divider}`,
      backgroundClip: "padding-box"
    }
  }, {
    props: ({
      ownerState: t
    }) => !t.dense,
    style: {
      [e.breakpoints.up("sm")]: {
        minHeight: "auto"
      }
    }
  }, {
    props: ({
      ownerState: t
    }) => t.dense,
    style: {
      minHeight: 32,
      // https://m2.material.io/components/menus#specs > Dense
      paddingTop: 4,
      paddingBottom: 4,
      ...e.typography.body2,
      [`& .${bg.root} svg`]: {
        fontSize: "1.25rem"
      }
    }
  }]
}))), Pg = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiMenuItem"
  }), {
    autoFocus: o = !1,
    component: a = "li",
    dense: i = !1,
    divider: s = !1,
    disableGutters: l = !1,
    focusVisibleClassName: c,
    role: u = "menuitem",
    tabIndex: f,
    className: d,
    ...p
  } = n, h = M.useContext(Mn), $ = M.useMemo(() => ({
    dense: i || h.dense || !1,
    disableGutters: l
  }), [h.dense, i, l]), b = M.useRef(null);
  Bn(() => {
    o && b.current && b.current.focus();
  }, [o]);
  const g = {
    ...n,
    dense: $.dense,
    divider: s,
    disableGutters: l
  }, y = hq(n), S = Bt(b, r);
  let m;
  return n.disabled || (m = f !== void 0 ? f : -1), /* @__PURE__ */ P(Mn.Provider, {
    value: $,
    children: /* @__PURE__ */ P(mq, {
      ref: S,
      role: u,
      tabIndex: m,
      component: a,
      focusVisibleClassName: Ee(y.focusVisible, c),
      className: Ee(y.root, d),
      ...p,
      ownerState: g,
      classes: y
    })
  });
});
function gq({
  schema: e,
  id: t,
  name: r,
  // remove this from textFieldProps
  options: n,
  label: o,
  hideLabel: a,
  required: i,
  disabled: s,
  placeholder: l,
  readonly: c,
  value: u,
  multiple: f,
  autofocus: d,
  onChange: p,
  onBlur: h,
  onFocus: $,
  errorSchema: b,
  rawErrors: g = [],
  registry: y,
  uiSchema: S,
  hideError: m,
  formContext: w,
  ...v
}) {
  const { enumOptions: E, enumDisabled: I, emptyValue: R } = n;
  f = typeof f > "u" ? !1 : !!f;
  const C = f ? [] : "", T = typeof u > "u" || f && u.length < 1 || !f && u === C, F = ({ target: { value: j } }) => p(Yt(j, E, R)), D = ({ target: j }) => h(t, Yt(j && j.value, E, R)), z = ({ target: j }) => $(t, Yt(j && j.value, E, R)), L = nf(u, E, f), { InputLabelProps: X, SelectProps: V, autocomplete: ie, ...Y } = v, H = !f && e.default === void 0;
  return ue(Bf, { id: t, name: t, label: Bo(o || void 0, a, void 0), value: !T && typeof L < "u" ? L : C, required: i, disabled: s || c, autoFocus: d, autoComplete: ie, placeholder: l, error: g.length > 0, onChange: F, onBlur: D, onFocus: z, ...Y, select: !0, InputLabelProps: {
    ...X,
    shrink: !T
  }, SelectProps: {
    ...V,
    multiple: f
  }, "aria-describedby": Mr(t), children: [H && P(Pg, { value: "", children: l }), Array.isArray(E) && E.map(({ value: j, label: Q }, q) => {
    const O = Array.isArray(I) && I.indexOf(j) !== -1;
    return P(Pg, { value: String(q), disabled: O, children: Q }, q);
  })] });
}
function yq(e) {
  const { options: t, registry: r } = e, n = Ye("BaseInputTemplate", r, t);
  let o = 5;
  return (typeof t.rows == "string" || typeof t.rows == "number") && (o = t.rows), P(n, { ...e, multiline: !0, rows: o });
}
function bq() {
  return {
    CheckboxWidget: CV,
    CheckboxesWidget: PV,
    RadioWidget: UV,
    RangeWidget: dq,
    SelectWidget: gq,
    TextareaWidget: yq
  };
}
function vq() {
  return {
    templates: aV(),
    widgets: bq()
  };
}
function $q() {
  return I9(vq());
}
const Sq = $q();
var Zu = { exports: {} }, jv = {}, Zr = {}, _a = {}, ms = {}, Ge = {}, Hi = {};
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.regexpCode = e.getEsmExportName = e.getProperty = e.safeStringify = e.stringify = e.strConcat = e.addCodeArg = e.str = e._ = e.nil = e._Code = e.Name = e.IDENTIFIER = e._CodeOrName = void 0;
  class t {
  }
  e._CodeOrName = t, e.IDENTIFIER = /^[a-z$_][a-z$_0-9]*$/i;
  class r extends t {
    constructor(y) {
      if (super(), !e.IDENTIFIER.test(y))
        throw new Error("CodeGen: name must be a valid identifier");
      this.str = y;
    }
    toString() {
      return this.str;
    }
    emptyStr() {
      return !1;
    }
    get names() {
      return { [this.str]: 1 };
    }
  }
  e.Name = r;
  class n extends t {
    constructor(y) {
      super(), this._items = typeof y == "string" ? [y] : y;
    }
    toString() {
      return this.str;
    }
    emptyStr() {
      if (this._items.length > 1)
        return !1;
      const y = this._items[0];
      return y === "" || y === '""';
    }
    get str() {
      var y;
      return (y = this._str) !== null && y !== void 0 ? y : this._str = this._items.reduce((S, m) => `${S}${m}`, "");
    }
    get names() {
      var y;
      return (y = this._names) !== null && y !== void 0 ? y : this._names = this._items.reduce((S, m) => (m instanceof r && (S[m.str] = (S[m.str] || 0) + 1), S), {});
    }
  }
  e._Code = n, e.nil = new n("");
  function o(g, ...y) {
    const S = [g[0]];
    let m = 0;
    for (; m < y.length; )
      s(S, y[m]), S.push(g[++m]);
    return new n(S);
  }
  e._ = o;
  const a = new n("+");
  function i(g, ...y) {
    const S = [p(g[0])];
    let m = 0;
    for (; m < y.length; )
      S.push(a), s(S, y[m]), S.push(a, p(g[++m]));
    return l(S), new n(S);
  }
  e.str = i;
  function s(g, y) {
    y instanceof n ? g.push(...y._items) : y instanceof r ? g.push(y) : g.push(f(y));
  }
  e.addCodeArg = s;
  function l(g) {
    let y = 1;
    for (; y < g.length - 1; ) {
      if (g[y] === a) {
        const S = c(g[y - 1], g[y + 1]);
        if (S !== void 0) {
          g.splice(y - 1, 3, S);
          continue;
        }
        g[y++] = "+";
      }
      y++;
    }
  }
  function c(g, y) {
    if (y === '""')
      return g;
    if (g === '""')
      return y;
    if (typeof g == "string")
      return y instanceof r || g[g.length - 1] !== '"' ? void 0 : typeof y != "string" ? `${g.slice(0, -1)}${y}"` : y[0] === '"' ? g.slice(0, -1) + y.slice(1) : void 0;
    if (typeof y == "string" && y[0] === '"' && !(g instanceof r))
      return `"${g}${y.slice(1)}`;
  }
  function u(g, y) {
    return y.emptyStr() ? g : g.emptyStr() ? y : i`${g}${y}`;
  }
  e.strConcat = u;
  function f(g) {
    return typeof g == "number" || typeof g == "boolean" || g === null ? g : p(Array.isArray(g) ? g.join(",") : g);
  }
  function d(g) {
    return new n(p(g));
  }
  e.stringify = d;
  function p(g) {
    return JSON.stringify(g).replace(/\u2028/g, "\\u2028").replace(/\u2029/g, "\\u2029");
  }
  e.safeStringify = p;
  function h(g) {
    return typeof g == "string" && e.IDENTIFIER.test(g) ? new n(`.${g}`) : o`[${g}]`;
  }
  e.getProperty = h;
  function $(g) {
    if (typeof g == "string" && e.IDENTIFIER.test(g))
      return new n(`${g}`);
    throw new Error(`CodeGen: invalid export name: ${g}, use explicit $id name mapping`);
  }
  e.getEsmExportName = $;
  function b(g) {
    return new n(g.toString());
  }
  e.regexpCode = b;
})(Hi);
var Qu = {};
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.ValueScope = e.ValueScopeName = e.Scope = e.varKinds = e.UsedValueState = void 0;
  const t = Hi;
  class r extends Error {
    constructor(c) {
      super(`CodeGen: "code" for ${c} not defined`), this.value = c.value;
    }
  }
  var n;
  (function(l) {
    l[l.Started = 0] = "Started", l[l.Completed = 1] = "Completed";
  })(n || (e.UsedValueState = n = {})), e.varKinds = {
    const: new t.Name("const"),
    let: new t.Name("let"),
    var: new t.Name("var")
  };
  class o {
    constructor({ prefixes: c, parent: u } = {}) {
      this._names = {}, this._prefixes = c, this._parent = u;
    }
    toName(c) {
      return c instanceof t.Name ? c : this.name(c);
    }
    name(c) {
      return new t.Name(this._newName(c));
    }
    _newName(c) {
      const u = this._names[c] || this._nameGroup(c);
      return `${c}${u.index++}`;
    }
    _nameGroup(c) {
      var u, f;
      if (!((f = (u = this._parent) === null || u === void 0 ? void 0 : u._prefixes) === null || f === void 0) && f.has(c) || this._prefixes && !this._prefixes.has(c))
        throw new Error(`CodeGen: prefix "${c}" is not allowed in this scope`);
      return this._names[c] = { prefix: c, index: 0 };
    }
  }
  e.Scope = o;
  class a extends t.Name {
    constructor(c, u) {
      super(u), this.prefix = c;
    }
    setValue(c, { property: u, itemIndex: f }) {
      this.value = c, this.scopePath = (0, t._)`.${new t.Name(u)}[${f}]`;
    }
  }
  e.ValueScopeName = a;
  const i = (0, t._)`\n`;
  class s extends o {
    constructor(c) {
      super(c), this._values = {}, this._scope = c.scope, this.opts = { ...c, _n: c.lines ? i : t.nil };
    }
    get() {
      return this._scope;
    }
    name(c) {
      return new a(c, this._newName(c));
    }
    value(c, u) {
      var f;
      if (u.ref === void 0)
        throw new Error("CodeGen: ref must be passed in value");
      const d = this.toName(c), { prefix: p } = d, h = (f = u.key) !== null && f !== void 0 ? f : u.ref;
      let $ = this._values[p];
      if ($) {
        const y = $.get(h);
        if (y)
          return y;
      } else
        $ = this._values[p] = /* @__PURE__ */ new Map();
      $.set(h, d);
      const b = this._scope[p] || (this._scope[p] = []), g = b.length;
      return b[g] = u.ref, d.setValue(u, { property: p, itemIndex: g }), d;
    }
    getValue(c, u) {
      const f = this._values[c];
      if (f)
        return f.get(u);
    }
    scopeRefs(c, u = this._values) {
      return this._reduceValues(u, (f) => {
        if (f.scopePath === void 0)
          throw new Error(`CodeGen: name "${f}" has no value`);
        return (0, t._)`${c}${f.scopePath}`;
      });
    }
    scopeCode(c = this._values, u, f) {
      return this._reduceValues(c, (d) => {
        if (d.value === void 0)
          throw new Error(`CodeGen: name "${d}" has no value`);
        return d.value.code;
      }, u, f);
    }
    _reduceValues(c, u, f = {}, d) {
      let p = t.nil;
      for (const h in c) {
        const $ = c[h];
        if (!$)
          continue;
        const b = f[h] = f[h] || /* @__PURE__ */ new Map();
        $.forEach((g) => {
          if (b.has(g))
            return;
          b.set(g, n.Started);
          let y = u(g);
          if (y) {
            const S = this.opts.es5 ? e.varKinds.var : e.varKinds.const;
            p = (0, t._)`${p}${S} ${g} = ${y};${this.opts._n}`;
          } else if (y = d == null ? void 0 : d(g))
            p = (0, t._)`${p}${y}${this.opts._n}`;
          else
            throw new r(g);
          b.set(g, n.Completed);
        });
      }
      return p;
    }
  }
  e.ValueScope = s;
})(Qu);
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.or = e.and = e.not = e.CodeGen = e.operators = e.varKinds = e.ValueScopeName = e.ValueScope = e.Scope = e.Name = e.regexpCode = e.stringify = e.getProperty = e.nil = e.strConcat = e.str = e._ = void 0;
  const t = Hi, r = Qu;
  var n = Hi;
  Object.defineProperty(e, "_", { enumerable: !0, get: function() {
    return n._;
  } }), Object.defineProperty(e, "str", { enumerable: !0, get: function() {
    return n.str;
  } }), Object.defineProperty(e, "strConcat", { enumerable: !0, get: function() {
    return n.strConcat;
  } }), Object.defineProperty(e, "nil", { enumerable: !0, get: function() {
    return n.nil;
  } }), Object.defineProperty(e, "getProperty", { enumerable: !0, get: function() {
    return n.getProperty;
  } }), Object.defineProperty(e, "stringify", { enumerable: !0, get: function() {
    return n.stringify;
  } }), Object.defineProperty(e, "regexpCode", { enumerable: !0, get: function() {
    return n.regexpCode;
  } }), Object.defineProperty(e, "Name", { enumerable: !0, get: function() {
    return n.Name;
  } });
  var o = Qu;
  Object.defineProperty(e, "Scope", { enumerable: !0, get: function() {
    return o.Scope;
  } }), Object.defineProperty(e, "ValueScope", { enumerable: !0, get: function() {
    return o.ValueScope;
  } }), Object.defineProperty(e, "ValueScopeName", { enumerable: !0, get: function() {
    return o.ValueScopeName;
  } }), Object.defineProperty(e, "varKinds", { enumerable: !0, get: function() {
    return o.varKinds;
  } }), e.operators = {
    GT: new t._Code(">"),
    GTE: new t._Code(">="),
    LT: new t._Code("<"),
    LTE: new t._Code("<="),
    EQ: new t._Code("==="),
    NEQ: new t._Code("!=="),
    NOT: new t._Code("!"),
    OR: new t._Code("||"),
    AND: new t._Code("&&"),
    ADD: new t._Code("+")
  };
  class a {
    optimizeNodes() {
      return this;
    }
    optimizeNames(O, N) {
      return this;
    }
  }
  class i extends a {
    constructor(O, N, W) {
      super(), this.varKind = O, this.name = N, this.rhs = W;
    }
    render({ es5: O, _n: N }) {
      const W = O ? r.varKinds.var : this.varKind, ne = this.rhs === void 0 ? "" : ` = ${this.rhs}`;
      return `${W} ${this.name}${ne};` + N;
    }
    optimizeNames(O, N) {
      if (O[this.name.str])
        return this.rhs && (this.rhs = z(this.rhs, O, N)), this;
    }
    get names() {
      return this.rhs instanceof t._CodeOrName ? this.rhs.names : {};
    }
  }
  class s extends a {
    constructor(O, N, W) {
      super(), this.lhs = O, this.rhs = N, this.sideEffects = W;
    }
    render({ _n: O }) {
      return `${this.lhs} = ${this.rhs};` + O;
    }
    optimizeNames(O, N) {
      if (!(this.lhs instanceof t.Name && !O[this.lhs.str] && !this.sideEffects))
        return this.rhs = z(this.rhs, O, N), this;
    }
    get names() {
      const O = this.lhs instanceof t.Name ? {} : { ...this.lhs.names };
      return D(O, this.rhs);
    }
  }
  class l extends s {
    constructor(O, N, W, ne) {
      super(O, W, ne), this.op = N;
    }
    render({ _n: O }) {
      return `${this.lhs} ${this.op}= ${this.rhs};` + O;
    }
  }
  class c extends a {
    constructor(O) {
      super(), this.label = O, this.names = {};
    }
    render({ _n: O }) {
      return `${this.label}:` + O;
    }
  }
  class u extends a {
    constructor(O) {
      super(), this.label = O, this.names = {};
    }
    render({ _n: O }) {
      return `break${this.label ? ` ${this.label}` : ""};` + O;
    }
  }
  class f extends a {
    constructor(O) {
      super(), this.error = O;
    }
    render({ _n: O }) {
      return `throw ${this.error};` + O;
    }
    get names() {
      return this.error.names;
    }
  }
  class d extends a {
    constructor(O) {
      super(), this.code = O;
    }
    render({ _n: O }) {
      return `${this.code};` + O;
    }
    optimizeNodes() {
      return `${this.code}` ? this : void 0;
    }
    optimizeNames(O, N) {
      return this.code = z(this.code, O, N), this;
    }
    get names() {
      return this.code instanceof t._CodeOrName ? this.code.names : {};
    }
  }
  class p extends a {
    constructor(O = []) {
      super(), this.nodes = O;
    }
    render(O) {
      return this.nodes.reduce((N, W) => N + W.render(O), "");
    }
    optimizeNodes() {
      const { nodes: O } = this;
      let N = O.length;
      for (; N--; ) {
        const W = O[N].optimizeNodes();
        Array.isArray(W) ? O.splice(N, 1, ...W) : W ? O[N] = W : O.splice(N, 1);
      }
      return O.length > 0 ? this : void 0;
    }
    optimizeNames(O, N) {
      const { nodes: W } = this;
      let ne = W.length;
      for (; ne--; ) {
        const ee = W[ne];
        ee.optimizeNames(O, N) || (L(O, ee.names), W.splice(ne, 1));
      }
      return W.length > 0 ? this : void 0;
    }
    get names() {
      return this.nodes.reduce((O, N) => F(O, N.names), {});
    }
  }
  class h extends p {
    render(O) {
      return "{" + O._n + super.render(O) + "}" + O._n;
    }
  }
  class $ extends p {
  }
  class b extends h {
  }
  b.kind = "else";
  class g extends h {
    constructor(O, N) {
      super(N), this.condition = O;
    }
    render(O) {
      let N = `if(${this.condition})` + super.render(O);
      return this.else && (N += "else " + this.else.render(O)), N;
    }
    optimizeNodes() {
      super.optimizeNodes();
      const O = this.condition;
      if (O === !0)
        return this.nodes;
      let N = this.else;
      if (N) {
        const W = N.optimizeNodes();
        N = this.else = Array.isArray(W) ? new b(W) : W;
      }
      if (N)
        return O === !1 ? N instanceof g ? N : N.nodes : this.nodes.length ? this : new g(X(O), N instanceof g ? [N] : N.nodes);
      if (!(O === !1 || !this.nodes.length))
        return this;
    }
    optimizeNames(O, N) {
      var W;
      if (this.else = (W = this.else) === null || W === void 0 ? void 0 : W.optimizeNames(O, N), !!(super.optimizeNames(O, N) || this.else))
        return this.condition = z(this.condition, O, N), this;
    }
    get names() {
      const O = super.names;
      return D(O, this.condition), this.else && F(O, this.else.names), O;
    }
  }
  g.kind = "if";
  class y extends h {
  }
  y.kind = "for";
  class S extends y {
    constructor(O) {
      super(), this.iteration = O;
    }
    render(O) {
      return `for(${this.iteration})` + super.render(O);
    }
    optimizeNames(O, N) {
      if (super.optimizeNames(O, N))
        return this.iteration = z(this.iteration, O, N), this;
    }
    get names() {
      return F(super.names, this.iteration.names);
    }
  }
  class m extends y {
    constructor(O, N, W, ne) {
      super(), this.varKind = O, this.name = N, this.from = W, this.to = ne;
    }
    render(O) {
      const N = O.es5 ? r.varKinds.var : this.varKind, { name: W, from: ne, to: ee } = this;
      return `for(${N} ${W}=${ne}; ${W}<${ee}; ${W}++)` + super.render(O);
    }
    get names() {
      const O = D(super.names, this.from);
      return D(O, this.to);
    }
  }
  class w extends y {
    constructor(O, N, W, ne) {
      super(), this.loop = O, this.varKind = N, this.name = W, this.iterable = ne;
    }
    render(O) {
      return `for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})` + super.render(O);
    }
    optimizeNames(O, N) {
      if (super.optimizeNames(O, N))
        return this.iterable = z(this.iterable, O, N), this;
    }
    get names() {
      return F(super.names, this.iterable.names);
    }
  }
  class v extends h {
    constructor(O, N, W) {
      super(), this.name = O, this.args = N, this.async = W;
    }
    render(O) {
      return `${this.async ? "async " : ""}function ${this.name}(${this.args})` + super.render(O);
    }
  }
  v.kind = "func";
  class E extends p {
    render(O) {
      return "return " + super.render(O);
    }
  }
  E.kind = "return";
  class I extends h {
    render(O) {
      let N = "try" + super.render(O);
      return this.catch && (N += this.catch.render(O)), this.finally && (N += this.finally.render(O)), N;
    }
    optimizeNodes() {
      var O, N;
      return super.optimizeNodes(), (O = this.catch) === null || O === void 0 || O.optimizeNodes(), (N = this.finally) === null || N === void 0 || N.optimizeNodes(), this;
    }
    optimizeNames(O, N) {
      var W, ne;
      return super.optimizeNames(O, N), (W = this.catch) === null || W === void 0 || W.optimizeNames(O, N), (ne = this.finally) === null || ne === void 0 || ne.optimizeNames(O, N), this;
    }
    get names() {
      const O = super.names;
      return this.catch && F(O, this.catch.names), this.finally && F(O, this.finally.names), O;
    }
  }
  class R extends h {
    constructor(O) {
      super(), this.error = O;
    }
    render(O) {
      return `catch(${this.error})` + super.render(O);
    }
  }
  R.kind = "catch";
  class C extends h {
    render(O) {
      return "finally" + super.render(O);
    }
  }
  C.kind = "finally";
  class T {
    constructor(O, N = {}) {
      this._values = {}, this._blockStarts = [], this._constants = {}, this.opts = { ...N, _n: N.lines ? `
` : "" }, this._extScope = O, this._scope = new r.Scope({ parent: O }), this._nodes = [new $()];
    }
    toString() {
      return this._root.render(this.opts);
    }
    // returns unique name in the internal scope
    name(O) {
      return this._scope.name(O);
    }
    // reserves unique name in the external scope
    scopeName(O) {
      return this._extScope.name(O);
    }
    // reserves unique name in the external scope and assigns value to it
    scopeValue(O, N) {
      const W = this._extScope.value(O, N);
      return (this._values[W.prefix] || (this._values[W.prefix] = /* @__PURE__ */ new Set())).add(W), W;
    }
    getScopeValue(O, N) {
      return this._extScope.getValue(O, N);
    }
    // return code that assigns values in the external scope to the names that are used internally
    // (same names that were returned by gen.scopeName or gen.scopeValue)
    scopeRefs(O) {
      return this._extScope.scopeRefs(O, this._values);
    }
    scopeCode() {
      return this._extScope.scopeCode(this._values);
    }
    _def(O, N, W, ne) {
      const ee = this._scope.toName(N);
      return W !== void 0 && ne && (this._constants[ee.str] = W), this._leafNode(new i(O, ee, W)), ee;
    }
    // `const` declaration (`var` in es5 mode)
    const(O, N, W) {
      return this._def(r.varKinds.const, O, N, W);
    }
    // `let` declaration with optional assignment (`var` in es5 mode)
    let(O, N, W) {
      return this._def(r.varKinds.let, O, N, W);
    }
    // `var` declaration with optional assignment
    var(O, N, W) {
      return this._def(r.varKinds.var, O, N, W);
    }
    // assignment code
    assign(O, N, W) {
      return this._leafNode(new s(O, N, W));
    }
    // `+=` code
    add(O, N) {
      return this._leafNode(new l(O, e.operators.ADD, N));
    }
    // appends passed SafeExpr to code or executes Block
    code(O) {
      return typeof O == "function" ? O() : O !== t.nil && this._leafNode(new d(O)), this;
    }
    // returns code for object literal for the passed argument list of key-value pairs
    object(...O) {
      const N = ["{"];
      for (const [W, ne] of O)
        N.length > 1 && N.push(","), N.push(W), (W !== ne || this.opts.es5) && (N.push(":"), (0, t.addCodeArg)(N, ne));
      return N.push("}"), new t._Code(N);
    }
    // `if` clause (or statement if `thenBody` and, optionally, `elseBody` are passed)
    if(O, N, W) {
      if (this._blockNode(new g(O)), N && W)
        this.code(N).else().code(W).endIf();
      else if (N)
        this.code(N).endIf();
      else if (W)
        throw new Error('CodeGen: "else" body without "then" body');
      return this;
    }
    // `else if` clause - invalid without `if` or after `else` clauses
    elseIf(O) {
      return this._elseNode(new g(O));
    }
    // `else` clause - only valid after `if` or `else if` clauses
    else() {
      return this._elseNode(new b());
    }
    // end `if` statement (needed if gen.if was used only with condition)
    endIf() {
      return this._endBlockNode(g, b);
    }
    _for(O, N) {
      return this._blockNode(O), N && this.code(N).endFor(), this;
    }
    // a generic `for` clause (or statement if `forBody` is passed)
    for(O, N) {
      return this._for(new S(O), N);
    }
    // `for` statement for a range of values
    forRange(O, N, W, ne, ee = this.opts.es5 ? r.varKinds.var : r.varKinds.let) {
      const pe = this._scope.toName(O);
      return this._for(new m(ee, pe, N, W), () => ne(pe));
    }
    // `for-of` statement (in es5 mode replace with a normal for loop)
    forOf(O, N, W, ne = r.varKinds.const) {
      const ee = this._scope.toName(O);
      if (this.opts.es5) {
        const pe = N instanceof t.Name ? N : this.var("_arr", N);
        return this.forRange("_i", 0, (0, t._)`${pe}.length`, (ce) => {
          this.var(ee, (0, t._)`${pe}[${ce}]`), W(ee);
        });
      }
      return this._for(new w("of", ne, ee, N), () => W(ee));
    }
    // `for-in` statement.
    // With option `ownProperties` replaced with a `for-of` loop for object keys
    forIn(O, N, W, ne = this.opts.es5 ? r.varKinds.var : r.varKinds.const) {
      if (this.opts.ownProperties)
        return this.forOf(O, (0, t._)`Object.keys(${N})`, W);
      const ee = this._scope.toName(O);
      return this._for(new w("in", ne, ee, N), () => W(ee));
    }
    // end `for` loop
    endFor() {
      return this._endBlockNode(y);
    }
    // `label` statement
    label(O) {
      return this._leafNode(new c(O));
    }
    // `break` statement
    break(O) {
      return this._leafNode(new u(O));
    }
    // `return` statement
    return(O) {
      const N = new E();
      if (this._blockNode(N), this.code(O), N.nodes.length !== 1)
        throw new Error('CodeGen: "return" should have one node');
      return this._endBlockNode(E);
    }
    // `try` statement
    try(O, N, W) {
      if (!N && !W)
        throw new Error('CodeGen: "try" without "catch" and "finally"');
      const ne = new I();
      if (this._blockNode(ne), this.code(O), N) {
        const ee = this.name("e");
        this._currNode = ne.catch = new R(ee), N(ee);
      }
      return W && (this._currNode = ne.finally = new C(), this.code(W)), this._endBlockNode(R, C);
    }
    // `throw` statement
    throw(O) {
      return this._leafNode(new f(O));
    }
    // start self-balancing block
    block(O, N) {
      return this._blockStarts.push(this._nodes.length), O && this.code(O).endBlock(N), this;
    }
    // end the current self-balancing block
    endBlock(O) {
      const N = this._blockStarts.pop();
      if (N === void 0)
        throw new Error("CodeGen: not in self-balancing block");
      const W = this._nodes.length - N;
      if (W < 0 || O !== void 0 && W !== O)
        throw new Error(`CodeGen: wrong number of nodes: ${W} vs ${O} expected`);
      return this._nodes.length = N, this;
    }
    // `function` heading (or definition if funcBody is passed)
    func(O, N = t.nil, W, ne) {
      return this._blockNode(new v(O, N, W)), ne && this.code(ne).endFunc(), this;
    }
    // end function definition
    endFunc() {
      return this._endBlockNode(v);
    }
    optimize(O = 1) {
      for (; O-- > 0; )
        this._root.optimizeNodes(), this._root.optimizeNames(this._root.names, this._constants);
    }
    _leafNode(O) {
      return this._currNode.nodes.push(O), this;
    }
    _blockNode(O) {
      this._currNode.nodes.push(O), this._nodes.push(O);
    }
    _endBlockNode(O, N) {
      const W = this._currNode;
      if (W instanceof O || N && W instanceof N)
        return this._nodes.pop(), this;
      throw new Error(`CodeGen: not in block "${N ? `${O.kind}/${N.kind}` : O.kind}"`);
    }
    _elseNode(O) {
      const N = this._currNode;
      if (!(N instanceof g))
        throw new Error('CodeGen: "else" without "if"');
      return this._currNode = N.else = O, this;
    }
    get _root() {
      return this._nodes[0];
    }
    get _currNode() {
      const O = this._nodes;
      return O[O.length - 1];
    }
    set _currNode(O) {
      const N = this._nodes;
      N[N.length - 1] = O;
    }
  }
  e.CodeGen = T;
  function F(q, O) {
    for (const N in O)
      q[N] = (q[N] || 0) + (O[N] || 0);
    return q;
  }
  function D(q, O) {
    return O instanceof t._CodeOrName ? F(q, O.names) : q;
  }
  function z(q, O, N) {
    if (q instanceof t.Name)
      return W(q);
    if (!ne(q))
      return q;
    return new t._Code(q._items.reduce((ee, pe) => (pe instanceof t.Name && (pe = W(pe)), pe instanceof t._Code ? ee.push(...pe._items) : ee.push(pe), ee), []));
    function W(ee) {
      const pe = N[ee.str];
      return pe === void 0 || O[ee.str] !== 1 ? ee : (delete O[ee.str], pe);
    }
    function ne(ee) {
      return ee instanceof t._Code && ee._items.some((pe) => pe instanceof t.Name && O[pe.str] === 1 && N[pe.str] !== void 0);
    }
  }
  function L(q, O) {
    for (const N in O)
      q[N] = (q[N] || 0) - (O[N] || 0);
  }
  function X(q) {
    return typeof q == "boolean" || typeof q == "number" || q === null ? !q : (0, t._)`!${Q(q)}`;
  }
  e.not = X;
  const V = j(e.operators.AND);
  function ie(...q) {
    return q.reduce(V);
  }
  e.and = ie;
  const Y = j(e.operators.OR);
  function H(...q) {
    return q.reduce(Y);
  }
  e.or = H;
  function j(q) {
    return (O, N) => O === t.nil ? N : N === t.nil ? O : (0, t._)`${Q(O)} ${q} ${Q(N)}`;
  }
  function Q(q) {
    return q instanceof t.Name ? q : (0, t._)`(${q})`;
  }
})(Ge);
var we = {};
Object.defineProperty(we, "__esModule", { value: !0 });
we.checkStrictMode = we.getErrorPath = we.Type = we.useFunc = we.setEvaluated = we.evaluatedPropsToName = we.mergeEvaluated = we.eachItem = we.unescapeJsonPointer = we.escapeJsonPointer = we.escapeFragment = we.unescapeFragment = we.schemaRefOrVal = we.schemaHasRulesButRef = we.schemaHasRules = we.checkUnknownRules = we.alwaysValidSchema = we.toHash = void 0;
const $t = Ge, wq = Hi;
function Cq(e) {
  const t = {};
  for (const r of e)
    t[r] = !0;
  return t;
}
we.toHash = Cq;
function Eq(e, t) {
  return typeof t == "boolean" ? t : Object.keys(t).length === 0 ? !0 : (Dv(e, t), !Lv(t, e.self.RULES.all));
}
we.alwaysValidSchema = Eq;
function Dv(e, t = e.schema) {
  const { opts: r, self: n } = e;
  if (!r.strictSchema || typeof t == "boolean")
    return;
  const o = n.RULES.keywords;
  for (const a in t)
    o[a] || Uv(e, `unknown keyword: "${a}"`);
}
we.checkUnknownRules = Dv;
function Lv(e, t) {
  if (typeof e == "boolean")
    return !e;
  for (const r in e)
    if (t[r])
      return !0;
  return !1;
}
we.schemaHasRules = Lv;
function _q(e, t) {
  if (typeof e == "boolean")
    return !e;
  for (const r in e)
    if (r !== "$ref" && t.all[r])
      return !0;
  return !1;
}
we.schemaHasRulesButRef = _q;
function xq({ topSchemaRef: e, schemaPath: t }, r, n, o) {
  if (!o) {
    if (typeof r == "number" || typeof r == "boolean")
      return r;
    if (typeof r == "string")
      return (0, $t._)`${r}`;
  }
  return (0, $t._)`${e}${t}${(0, $t.getProperty)(n)}`;
}
we.schemaRefOrVal = xq;
function Pq(e) {
  return Bv(decodeURIComponent(e));
}
we.unescapeFragment = Pq;
function kq(e) {
  return encodeURIComponent(Uf(e));
}
we.escapeFragment = kq;
function Uf(e) {
  return typeof e == "number" ? `${e}` : e.replace(/~/g, "~0").replace(/\//g, "~1");
}
we.escapeJsonPointer = Uf;
function Bv(e) {
  return e.replace(/~1/g, "/").replace(/~0/g, "~");
}
we.unescapeJsonPointer = Bv;
function Oq(e, t) {
  if (Array.isArray(e))
    for (const r of e)
      t(r);
  else
    t(e);
}
we.eachItem = Oq;
function kg({ mergeNames: e, mergeToName: t, mergeValues: r, resultToName: n }) {
  return (o, a, i, s) => {
    const l = i === void 0 ? a : i instanceof $t.Name ? (a instanceof $t.Name ? e(o, a, i) : t(o, a, i), i) : a instanceof $t.Name ? (t(o, i, a), a) : r(a, i);
    return s === $t.Name && !(l instanceof $t.Name) ? n(o, l) : l;
  };
}
we.mergeEvaluated = {
  props: kg({
    mergeNames: (e, t, r) => e.if((0, $t._)`${r} !== true && ${t} !== undefined`, () => {
      e.if((0, $t._)`${t} === true`, () => e.assign(r, !0), () => e.assign(r, (0, $t._)`${r} || {}`).code((0, $t._)`Object.assign(${r}, ${t})`));
    }),
    mergeToName: (e, t, r) => e.if((0, $t._)`${r} !== true`, () => {
      t === !0 ? e.assign(r, !0) : (e.assign(r, (0, $t._)`${r} || {}`), Vf(e, r, t));
    }),
    mergeValues: (e, t) => e === !0 ? !0 : { ...e, ...t },
    resultToName: zv
  }),
  items: kg({
    mergeNames: (e, t, r) => e.if((0, $t._)`${r} !== true && ${t} !== undefined`, () => e.assign(r, (0, $t._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),
    mergeToName: (e, t, r) => e.if((0, $t._)`${r} !== true`, () => e.assign(r, t === !0 ? !0 : (0, $t._)`${r} > ${t} ? ${r} : ${t}`)),
    mergeValues: (e, t) => e === !0 ? !0 : Math.max(e, t),
    resultToName: (e, t) => e.var("items", t)
  })
};
function zv(e, t) {
  if (t === !0)
    return e.var("props", !0);
  const r = e.var("props", (0, $t._)`{}`);
  return t !== void 0 && Vf(e, r, t), r;
}
we.evaluatedPropsToName = zv;
function Vf(e, t, r) {
  Object.keys(r).forEach((n) => e.assign((0, $t._)`${t}${(0, $t.getProperty)(n)}`, !0));
}
we.setEvaluated = Vf;
const Og = {};
function Aq(e, t) {
  return e.scopeValue("func", {
    ref: t,
    code: Og[t.code] || (Og[t.code] = new wq._Code(t.code))
  });
}
we.useFunc = Aq;
var ed;
(function(e) {
  e[e.Num = 0] = "Num", e[e.Str = 1] = "Str";
})(ed || (we.Type = ed = {}));
function Iq(e, t, r) {
  if (e instanceof $t.Name) {
    const n = t === ed.Num;
    return r ? n ? (0, $t._)`"[" + ${e} + "]"` : (0, $t._)`"['" + ${e} + "']"` : n ? (0, $t._)`"/" + ${e}` : (0, $t._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`;
  }
  return r ? (0, $t.getProperty)(e).toString() : "/" + Uf(e);
}
we.getErrorPath = Iq;
function Uv(e, t, r = e.opts.strictSchema) {
  if (r) {
    if (t = `strict mode: ${t}`, r === !0)
      throw new Error(t);
    e.self.logger.warn(t);
  }
}
we.checkStrictMode = Uv;
var wn = {};
Object.defineProperty(wn, "__esModule", { value: !0 });
const ar = Ge, Rq = {
  // validation function arguments
  data: new ar.Name("data"),
  // data passed to validation function
  // args passed from referencing schema
  valCxt: new ar.Name("valCxt"),
  // validation/data context - should not be used directly, it is destructured to the names below
  instancePath: new ar.Name("instancePath"),
  parentData: new ar.Name("parentData"),
  parentDataProperty: new ar.Name("parentDataProperty"),
  rootData: new ar.Name("rootData"),
  // root data - same as the data passed to the first/top validation function
  dynamicAnchors: new ar.Name("dynamicAnchors"),
  // used to support recursiveRef and dynamicRef
  // function scoped variables
  vErrors: new ar.Name("vErrors"),
  // null or array of validation errors
  errors: new ar.Name("errors"),
  // counter of validation errors
  this: new ar.Name("this"),
  // "globals"
  self: new ar.Name("self"),
  scope: new ar.Name("scope"),
  // JTD serialize/parse name for JSON string and position
  json: new ar.Name("json"),
  jsonPos: new ar.Name("jsonPos"),
  jsonLen: new ar.Name("jsonLen"),
  jsonPart: new ar.Name("jsonPart")
};
wn.default = Rq;
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.extendErrors = e.resetErrorsCount = e.reportExtraError = e.reportError = e.keyword$DataError = e.keywordError = void 0;
  const t = Ge, r = we, n = wn;
  e.keywordError = {
    message: ({ keyword: b }) => (0, t.str)`must pass "${b}" keyword validation`
  }, e.keyword$DataError = {
    message: ({ keyword: b, schemaType: g }) => g ? (0, t.str)`"${b}" keyword must be ${g} ($data)` : (0, t.str)`"${b}" keyword is invalid ($data)`
  };
  function o(b, g = e.keywordError, y, S) {
    const { it: m } = b, { gen: w, compositeRule: v, allErrors: E } = m, I = f(b, g, y);
    S ?? (v || E) ? l(w, I) : c(m, (0, t._)`[${I}]`);
  }
  e.reportError = o;
  function a(b, g = e.keywordError, y) {
    const { it: S } = b, { gen: m, compositeRule: w, allErrors: v } = S, E = f(b, g, y);
    l(m, E), w || v || c(S, n.default.vErrors);
  }
  e.reportExtraError = a;
  function i(b, g) {
    b.assign(n.default.errors, g), b.if((0, t._)`${n.default.vErrors} !== null`, () => b.if(g, () => b.assign((0, t._)`${n.default.vErrors}.length`, g), () => b.assign(n.default.vErrors, null)));
  }
  e.resetErrorsCount = i;
  function s({ gen: b, keyword: g, schemaValue: y, data: S, errsCount: m, it: w }) {
    if (m === void 0)
      throw new Error("ajv implementation error");
    const v = b.name("err");
    b.forRange("i", m, n.default.errors, (E) => {
      b.const(v, (0, t._)`${n.default.vErrors}[${E}]`), b.if((0, t._)`${v}.instancePath === undefined`, () => b.assign((0, t._)`${v}.instancePath`, (0, t.strConcat)(n.default.instancePath, w.errorPath))), b.assign((0, t._)`${v}.schemaPath`, (0, t.str)`${w.errSchemaPath}/${g}`), w.opts.verbose && (b.assign((0, t._)`${v}.schema`, y), b.assign((0, t._)`${v}.data`, S));
    });
  }
  e.extendErrors = s;
  function l(b, g) {
    const y = b.const("err", g);
    b.if((0, t._)`${n.default.vErrors} === null`, () => b.assign(n.default.vErrors, (0, t._)`[${y}]`), (0, t._)`${n.default.vErrors}.push(${y})`), b.code((0, t._)`${n.default.errors}++`);
  }
  function c(b, g) {
    const { gen: y, validateName: S, schemaEnv: m } = b;
    m.$async ? y.throw((0, t._)`new ${b.ValidationError}(${g})`) : (y.assign((0, t._)`${S}.errors`, g), y.return(!1));
  }
  const u = {
    keyword: new t.Name("keyword"),
    schemaPath: new t.Name("schemaPath"),
    // also used in JTD errors
    params: new t.Name("params"),
    propertyName: new t.Name("propertyName"),
    message: new t.Name("message"),
    schema: new t.Name("schema"),
    parentSchema: new t.Name("parentSchema")
  };
  function f(b, g, y) {
    const { createErrors: S } = b.it;
    return S === !1 ? (0, t._)`{}` : d(b, g, y);
  }
  function d(b, g, y = {}) {
    const { gen: S, it: m } = b, w = [
      p(m, y),
      h(b, y)
    ];
    return $(b, g, w), S.object(...w);
  }
  function p({ errorPath: b }, { instancePath: g }) {
    const y = g ? (0, t.str)`${b}${(0, r.getErrorPath)(g, r.Type.Str)}` : b;
    return [n.default.instancePath, (0, t.strConcat)(n.default.instancePath, y)];
  }
  function h({ keyword: b, it: { errSchemaPath: g } }, { schemaPath: y, parentSchema: S }) {
    let m = S ? g : (0, t.str)`${g}/${b}`;
    return y && (m = (0, t.str)`${m}${(0, r.getErrorPath)(y, r.Type.Str)}`), [u.schemaPath, m];
  }
  function $(b, { params: g, message: y }, S) {
    const { keyword: m, data: w, schemaValue: v, it: E } = b, { opts: I, propertyName: R, topSchemaRef: C, schemaPath: T } = E;
    S.push([u.keyword, m], [u.params, typeof g == "function" ? g(b) : g || (0, t._)`{}`]), I.messages && S.push([u.message, typeof y == "function" ? y(b) : y]), I.verbose && S.push([u.schema, v], [u.parentSchema, (0, t._)`${C}${T}`], [n.default.data, w]), R && S.push([u.propertyName, R]);
  }
})(ms);
Object.defineProperty(_a, "__esModule", { value: !0 });
_a.boolOrEmptySchema = _a.topBoolOrEmptySchema = void 0;
const Tq = ms, Mq = Ge, Nq = wn, Fq = {
  message: "boolean schema is false"
};
function jq(e) {
  const { gen: t, schema: r, validateName: n } = e;
  r === !1 ? Vv(e, !1) : typeof r == "object" && r.$async === !0 ? t.return(Nq.default.data) : (t.assign((0, Mq._)`${n}.errors`, null), t.return(!0));
}
_a.topBoolOrEmptySchema = jq;
function Dq(e, t) {
  const { gen: r, schema: n } = e;
  n === !1 ? (r.var(t, !1), Vv(e)) : r.var(t, !0);
}
_a.boolOrEmptySchema = Dq;
function Vv(e, t) {
  const { gen: r, data: n } = e, o = {
    gen: r,
    keyword: "false schema",
    data: n,
    schema: !1,
    schemaCode: !1,
    schemaValue: !1,
    params: {},
    it: e
  };
  (0, Tq.reportError)(o, Fq, void 0, t);
}
var Gt = {}, Oo = {};
Object.defineProperty(Oo, "__esModule", { value: !0 });
Oo.getRules = Oo.isJSONType = void 0;
const Lq = ["string", "number", "integer", "boolean", "null", "object", "array"], Bq = new Set(Lq);
function zq(e) {
  return typeof e == "string" && Bq.has(e);
}
Oo.isJSONType = zq;
function Uq() {
  const e = {
    number: { type: "number", rules: [] },
    string: { type: "string", rules: [] },
    array: { type: "array", rules: [] },
    object: { type: "object", rules: [] }
  };
  return {
    types: { ...e, integer: !0, boolean: !0, null: !0 },
    rules: [{ rules: [] }, e.number, e.string, e.array, e.object],
    post: { rules: [] },
    all: {},
    keywords: {}
  };
}
Oo.getRules = Uq;
var Nn = {};
Object.defineProperty(Nn, "__esModule", { value: !0 });
Nn.shouldUseRule = Nn.shouldUseGroup = Nn.schemaHasRulesForType = void 0;
function Vq({ schema: e, self: t }, r) {
  const n = t.RULES.types[r];
  return n && n !== !0 && qv(e, n);
}
Nn.schemaHasRulesForType = Vq;
function qv(e, t) {
  return t.rules.some((r) => Wv(e, r));
}
Nn.shouldUseGroup = qv;
function Wv(e, t) {
  var r;
  return e[t.keyword] !== void 0 || ((r = t.definition.implements) === null || r === void 0 ? void 0 : r.some((n) => e[n] !== void 0));
}
Nn.shouldUseRule = Wv;
Object.defineProperty(Gt, "__esModule", { value: !0 });
Gt.reportTypeError = Gt.checkDataTypes = Gt.checkDataType = Gt.coerceAndCheckDataType = Gt.getJSONTypes = Gt.getSchemaTypes = Gt.DataType = void 0;
const qq = Oo, Wq = Nn, Kq = ms, We = Ge, Kv = we;
var da;
(function(e) {
  e[e.Correct = 0] = "Correct", e[e.Wrong = 1] = "Wrong";
})(da || (Gt.DataType = da = {}));
function Gq(e) {
  const t = Gv(e.type);
  if (t.includes("null")) {
    if (e.nullable === !1)
      throw new Error("type: null contradicts nullable: false");
  } else {
    if (!t.length && e.nullable !== void 0)
      throw new Error('"nullable" cannot be used without "type"');
    e.nullable === !0 && t.push("null");
  }
  return t;
}
Gt.getSchemaTypes = Gq;
function Gv(e) {
  const t = Array.isArray(e) ? e : e ? [e] : [];
  if (t.every(qq.isJSONType))
    return t;
  throw new Error("type must be JSONType or JSONType[]: " + t.join(","));
}
Gt.getJSONTypes = Gv;
function Hq(e, t) {
  const { gen: r, data: n, opts: o } = e, a = Jq(t, o.coerceTypes), i = t.length > 0 && !(a.length === 0 && t.length === 1 && (0, Wq.schemaHasRulesForType)(e, t[0]));
  if (i) {
    const s = qf(t, n, o.strictNumbers, da.Wrong);
    r.if(s, () => {
      a.length ? Yq(e, t, a) : Wf(e);
    });
  }
  return i;
}
Gt.coerceAndCheckDataType = Hq;
const Hv = /* @__PURE__ */ new Set(["string", "number", "integer", "boolean", "null"]);
function Jq(e, t) {
  return t ? e.filter((r) => Hv.has(r) || t === "array" && r === "array") : [];
}
function Yq(e, t, r) {
  const { gen: n, data: o, opts: a } = e, i = n.let("dataType", (0, We._)`typeof ${o}`), s = n.let("coerced", (0, We._)`undefined`);
  a.coerceTypes === "array" && n.if((0, We._)`${i} == 'object' && Array.isArray(${o}) && ${o}.length == 1`, () => n.assign(o, (0, We._)`${o}[0]`).assign(i, (0, We._)`typeof ${o}`).if(qf(t, o, a.strictNumbers), () => n.assign(s, o))), n.if((0, We._)`${s} !== undefined`);
  for (const c of r)
    (Hv.has(c) || c === "array" && a.coerceTypes === "array") && l(c);
  n.else(), Wf(e), n.endIf(), n.if((0, We._)`${s} !== undefined`, () => {
    n.assign(o, s), Xq(e, s);
  });
  function l(c) {
    switch (c) {
      case "string":
        n.elseIf((0, We._)`${i} == "number" || ${i} == "boolean"`).assign(s, (0, We._)`"" + ${o}`).elseIf((0, We._)`${o} === null`).assign(s, (0, We._)`""`);
        return;
      case "number":
        n.elseIf((0, We._)`${i} == "boolean" || ${o} === null
              || (${i} == "string" && ${o} && ${o} == +${o})`).assign(s, (0, We._)`+${o}`);
        return;
      case "integer":
        n.elseIf((0, We._)`${i} === "boolean" || ${o} === null
              || (${i} === "string" && ${o} && ${o} == +${o} && !(${o} % 1))`).assign(s, (0, We._)`+${o}`);
        return;
      case "boolean":
        n.elseIf((0, We._)`${o} === "false" || ${o} === 0 || ${o} === null`).assign(s, !1).elseIf((0, We._)`${o} === "true" || ${o} === 1`).assign(s, !0);
        return;
      case "null":
        n.elseIf((0, We._)`${o} === "" || ${o} === 0 || ${o} === false`), n.assign(s, null);
        return;
      case "array":
        n.elseIf((0, We._)`${i} === "string" || ${i} === "number"
              || ${i} === "boolean" || ${o} === null`).assign(s, (0, We._)`[${o}]`);
    }
  }
}
function Xq({ gen: e, parentData: t, parentDataProperty: r }, n) {
  e.if((0, We._)`${t} !== undefined`, () => e.assign((0, We._)`${t}[${r}]`, n));
}
function td(e, t, r, n = da.Correct) {
  const o = n === da.Correct ? We.operators.EQ : We.operators.NEQ;
  let a;
  switch (e) {
    case "null":
      return (0, We._)`${t} ${o} null`;
    case "array":
      a = (0, We._)`Array.isArray(${t})`;
      break;
    case "object":
      a = (0, We._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;
      break;
    case "integer":
      a = i((0, We._)`!(${t} % 1) && !isNaN(${t})`);
      break;
    case "number":
      a = i();
      break;
    default:
      return (0, We._)`typeof ${t} ${o} ${e}`;
  }
  return n === da.Correct ? a : (0, We.not)(a);
  function i(s = We.nil) {
    return (0, We.and)((0, We._)`typeof ${t} == "number"`, s, r ? (0, We._)`isFinite(${t})` : We.nil);
  }
}
Gt.checkDataType = td;
function qf(e, t, r, n) {
  if (e.length === 1)
    return td(e[0], t, r, n);
  let o;
  const a = (0, Kv.toHash)(e);
  if (a.array && a.object) {
    const i = (0, We._)`typeof ${t} != "object"`;
    o = a.null ? i : (0, We._)`!${t} || ${i}`, delete a.null, delete a.array, delete a.object;
  } else
    o = We.nil;
  a.number && delete a.integer;
  for (const i in a)
    o = (0, We.and)(o, td(i, t, r, n));
  return o;
}
Gt.checkDataTypes = qf;
const Zq = {
  message: ({ schema: e }) => `must be ${e}`,
  params: ({ schema: e, schemaValue: t }) => typeof e == "string" ? (0, We._)`{type: ${e}}` : (0, We._)`{type: ${t}}`
};
function Wf(e) {
  const t = Qq(e);
  (0, Kq.reportError)(t, Zq);
}
Gt.reportTypeError = Wf;
function Qq(e) {
  const { gen: t, data: r, schema: n } = e, o = (0, Kv.schemaRefOrVal)(e, n, "type");
  return {
    gen: t,
    keyword: "type",
    data: r,
    schema: n.type,
    schemaCode: o,
    schemaValue: o,
    parentSchema: n,
    params: {},
    it: e
  };
}
var kc = {};
Object.defineProperty(kc, "__esModule", { value: !0 });
kc.assignDefaults = void 0;
const Zo = Ge, eW = we;
function tW(e, t) {
  const { properties: r, items: n } = e.schema;
  if (t === "object" && r)
    for (const o in r)
      Ag(e, o, r[o].default);
  else t === "array" && Array.isArray(n) && n.forEach((o, a) => Ag(e, a, o.default));
}
kc.assignDefaults = tW;
function Ag(e, t, r) {
  const { gen: n, compositeRule: o, data: a, opts: i } = e;
  if (r === void 0)
    return;
  const s = (0, Zo._)`${a}${(0, Zo.getProperty)(t)}`;
  if (o) {
    (0, eW.checkStrictMode)(e, `default is ignored for: ${s}`);
    return;
  }
  let l = (0, Zo._)`${s} === undefined`;
  i.useDefaults === "empty" && (l = (0, Zo._)`${l} || ${s} === null || ${s} === ""`), n.if(l, (0, Zo._)`${s} = ${(0, Zo.stringify)(r)}`);
}
var gn = {}, Je = {};
Object.defineProperty(Je, "__esModule", { value: !0 });
Je.validateUnion = Je.validateArray = Je.usePattern = Je.callValidateCode = Je.schemaProperties = Je.allSchemaProperties = Je.noPropertyInData = Je.propertyInData = Je.isOwnProperty = Je.hasPropFunc = Je.reportMissingProp = Je.checkMissingProp = Je.checkReportMissingProp = void 0;
const xt = Ge, Kf = we, Hn = wn, rW = we;
function nW(e, t) {
  const { gen: r, data: n, it: o } = e;
  r.if(Hf(r, n, t, o.opts.ownProperties), () => {
    e.setParams({ missingProperty: (0, xt._)`${t}` }, !0), e.error();
  });
}
Je.checkReportMissingProp = nW;
function oW({ gen: e, data: t, it: { opts: r } }, n, o) {
  return (0, xt.or)(...n.map((a) => (0, xt.and)(Hf(e, t, a, r.ownProperties), (0, xt._)`${o} = ${a}`)));
}
Je.checkMissingProp = oW;
function aW(e, t) {
  e.setParams({ missingProperty: t }, !0), e.error();
}
Je.reportMissingProp = aW;
function Jv(e) {
  return e.scopeValue("func", {
    // eslint-disable-next-line @typescript-eslint/unbound-method
    ref: Object.prototype.hasOwnProperty,
    code: (0, xt._)`Object.prototype.hasOwnProperty`
  });
}
Je.hasPropFunc = Jv;
function Gf(e, t, r) {
  return (0, xt._)`${Jv(e)}.call(${t}, ${r})`;
}
Je.isOwnProperty = Gf;
function iW(e, t, r, n) {
  const o = (0, xt._)`${t}${(0, xt.getProperty)(r)} !== undefined`;
  return n ? (0, xt._)`${o} && ${Gf(e, t, r)}` : o;
}
Je.propertyInData = iW;
function Hf(e, t, r, n) {
  const o = (0, xt._)`${t}${(0, xt.getProperty)(r)} === undefined`;
  return n ? (0, xt.or)(o, (0, xt.not)(Gf(e, t, r))) : o;
}
Je.noPropertyInData = Hf;
function Yv(e) {
  return e ? Object.keys(e).filter((t) => t !== "__proto__") : [];
}
Je.allSchemaProperties = Yv;
function sW(e, t) {
  return Yv(t).filter((r) => !(0, Kf.alwaysValidSchema)(e, t[r]));
}
Je.schemaProperties = sW;
function lW({ schemaCode: e, data: t, it: { gen: r, topSchemaRef: n, schemaPath: o, errorPath: a }, it: i }, s, l, c) {
  const u = c ? (0, xt._)`${e}, ${t}, ${n}${o}` : t, f = [
    [Hn.default.instancePath, (0, xt.strConcat)(Hn.default.instancePath, a)],
    [Hn.default.parentData, i.parentData],
    [Hn.default.parentDataProperty, i.parentDataProperty],
    [Hn.default.rootData, Hn.default.rootData]
  ];
  i.opts.dynamicRef && f.push([Hn.default.dynamicAnchors, Hn.default.dynamicAnchors]);
  const d = (0, xt._)`${u}, ${r.object(...f)}`;
  return l !== xt.nil ? (0, xt._)`${s}.call(${l}, ${d})` : (0, xt._)`${s}(${d})`;
}
Je.callValidateCode = lW;
const cW = (0, xt._)`new RegExp`;
function uW({ gen: e, it: { opts: t } }, r) {
  const n = t.unicodeRegExp ? "u" : "", { regExp: o } = t.code, a = o(r, n);
  return e.scopeValue("pattern", {
    key: a.toString(),
    ref: a,
    code: (0, xt._)`${o.code === "new RegExp" ? cW : (0, rW.useFunc)(e, o)}(${r}, ${n})`
  });
}
Je.usePattern = uW;
function dW(e) {
  const { gen: t, data: r, keyword: n, it: o } = e, a = t.name("valid");
  if (o.allErrors) {
    const s = t.let("valid", !0);
    return i(() => t.assign(s, !1)), s;
  }
  return t.var(a, !0), i(() => t.break()), a;
  function i(s) {
    const l = t.const("len", (0, xt._)`${r}.length`);
    t.forRange("i", 0, l, (c) => {
      e.subschema({
        keyword: n,
        dataProp: c,
        dataPropType: Kf.Type.Num
      }, a), t.if((0, xt.not)(a), s);
    });
  }
}
Je.validateArray = dW;
function fW(e) {
  const { gen: t, schema: r, keyword: n, it: o } = e;
  if (!Array.isArray(r))
    throw new Error("ajv implementation error");
  if (r.some((l) => (0, Kf.alwaysValidSchema)(o, l)) && !o.opts.unevaluated)
    return;
  const i = t.let("valid", !1), s = t.name("_valid");
  t.block(() => r.forEach((l, c) => {
    const u = e.subschema({
      keyword: n,
      schemaProp: c,
      compositeRule: !0
    }, s);
    t.assign(i, (0, xt._)`${i} || ${s}`), e.mergeValidEvaluated(u, s) || t.if((0, xt.not)(i));
  })), e.result(i, () => e.reset(), () => e.error(!0));
}
Je.validateUnion = fW;
Object.defineProperty(gn, "__esModule", { value: !0 });
gn.validateKeywordUsage = gn.validSchemaType = gn.funcKeywordCode = gn.macroKeywordCode = void 0;
const dr = Ge, wo = wn, pW = Je, hW = ms;
function mW(e, t) {
  const { gen: r, keyword: n, schema: o, parentSchema: a, it: i } = e, s = t.macro.call(i.self, o, a, i), l = Xv(r, n, s);
  i.opts.validateSchema !== !1 && i.self.validateSchema(s, !0);
  const c = r.name("valid");
  e.subschema({
    schema: s,
    schemaPath: dr.nil,
    errSchemaPath: `${i.errSchemaPath}/${n}`,
    topSchemaRef: l,
    compositeRule: !0
  }, c), e.pass(c, () => e.error(!0));
}
gn.macroKeywordCode = mW;
function gW(e, t) {
  var r;
  const { gen: n, keyword: o, schema: a, parentSchema: i, $data: s, it: l } = e;
  bW(l, t);
  const c = !s && t.compile ? t.compile.call(l.self, a, i, l) : t.validate, u = Xv(n, o, c), f = n.let("valid");
  e.block$data(f, d), e.ok((r = t.valid) !== null && r !== void 0 ? r : f);
  function d() {
    if (t.errors === !1)
      $(), t.modifying && Ig(e), b(() => e.error());
    else {
      const g = t.async ? p() : h();
      t.modifying && Ig(e), b(() => yW(e, g));
    }
  }
  function p() {
    const g = n.let("ruleErrs", null);
    return n.try(() => $((0, dr._)`await `), (y) => n.assign(f, !1).if((0, dr._)`${y} instanceof ${l.ValidationError}`, () => n.assign(g, (0, dr._)`${y}.errors`), () => n.throw(y))), g;
  }
  function h() {
    const g = (0, dr._)`${u}.errors`;
    return n.assign(g, null), $(dr.nil), g;
  }
  function $(g = t.async ? (0, dr._)`await ` : dr.nil) {
    const y = l.opts.passContext ? wo.default.this : wo.default.self, S = !("compile" in t && !s || t.schema === !1);
    n.assign(f, (0, dr._)`${g}${(0, pW.callValidateCode)(e, u, y, S)}`, t.modifying);
  }
  function b(g) {
    var y;
    n.if((0, dr.not)((y = t.valid) !== null && y !== void 0 ? y : f), g);
  }
}
gn.funcKeywordCode = gW;
function Ig(e) {
  const { gen: t, data: r, it: n } = e;
  t.if(n.parentData, () => t.assign(r, (0, dr._)`${n.parentData}[${n.parentDataProperty}]`));
}
function yW(e, t) {
  const { gen: r } = e;
  r.if((0, dr._)`Array.isArray(${t})`, () => {
    r.assign(wo.default.vErrors, (0, dr._)`${wo.default.vErrors} === null ? ${t} : ${wo.default.vErrors}.concat(${t})`).assign(wo.default.errors, (0, dr._)`${wo.default.vErrors}.length`), (0, hW.extendErrors)(e);
  }, () => e.error());
}
function bW({ schemaEnv: e }, t) {
  if (t.async && !e.$async)
    throw new Error("async keyword in sync schema");
}
function Xv(e, t, r) {
  if (r === void 0)
    throw new Error(`keyword "${t}" failed to compile`);
  return e.scopeValue("keyword", typeof r == "function" ? { ref: r } : { ref: r, code: (0, dr.stringify)(r) });
}
function vW(e, t, r = !1) {
  return !t.length || t.some((n) => n === "array" ? Array.isArray(e) : n === "object" ? e && typeof e == "object" && !Array.isArray(e) : typeof e == n || r && typeof e > "u");
}
gn.validSchemaType = vW;
function $W({ schema: e, opts: t, self: r, errSchemaPath: n }, o, a) {
  if (Array.isArray(o.keyword) ? !o.keyword.includes(a) : o.keyword !== a)
    throw new Error("ajv implementation error");
  const i = o.dependencies;
  if (i != null && i.some((s) => !Object.prototype.hasOwnProperty.call(e, s)))
    throw new Error(`parent schema must have dependencies of ${a}: ${i.join(",")}`);
  if (o.validateSchema && !o.validateSchema(e[a])) {
    const l = `keyword "${a}" value is invalid at path "${n}": ` + r.errorsText(o.validateSchema.errors);
    if (t.validateSchema === "log")
      r.logger.error(l);
    else
      throw new Error(l);
  }
}
gn.validateKeywordUsage = $W;
var no = {};
Object.defineProperty(no, "__esModule", { value: !0 });
no.extendSubschemaMode = no.extendSubschemaData = no.getSubschema = void 0;
const fn = Ge, Zv = we;
function SW(e, { keyword: t, schemaProp: r, schema: n, schemaPath: o, errSchemaPath: a, topSchemaRef: i }) {
  if (t !== void 0 && n !== void 0)
    throw new Error('both "keyword" and "schema" passed, only one allowed');
  if (t !== void 0) {
    const s = e.schema[t];
    return r === void 0 ? {
      schema: s,
      schemaPath: (0, fn._)`${e.schemaPath}${(0, fn.getProperty)(t)}`,
      errSchemaPath: `${e.errSchemaPath}/${t}`
    } : {
      schema: s[r],
      schemaPath: (0, fn._)`${e.schemaPath}${(0, fn.getProperty)(t)}${(0, fn.getProperty)(r)}`,
      errSchemaPath: `${e.errSchemaPath}/${t}/${(0, Zv.escapeFragment)(r)}`
    };
  }
  if (n !== void 0) {
    if (o === void 0 || a === void 0 || i === void 0)
      throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');
    return {
      schema: n,
      schemaPath: o,
      topSchemaRef: i,
      errSchemaPath: a
    };
  }
  throw new Error('either "keyword" or "schema" must be passed');
}
no.getSubschema = SW;
function wW(e, t, { dataProp: r, dataPropType: n, data: o, dataTypes: a, propertyName: i }) {
  if (o !== void 0 && r !== void 0)
    throw new Error('both "data" and "dataProp" passed, only one allowed');
  const { gen: s } = t;
  if (r !== void 0) {
    const { errorPath: c, dataPathArr: u, opts: f } = t, d = s.let("data", (0, fn._)`${t.data}${(0, fn.getProperty)(r)}`, !0);
    l(d), e.errorPath = (0, fn.str)`${c}${(0, Zv.getErrorPath)(r, n, f.jsPropertySyntax)}`, e.parentDataProperty = (0, fn._)`${r}`, e.dataPathArr = [...u, e.parentDataProperty];
  }
  if (o !== void 0) {
    const c = o instanceof fn.Name ? o : s.let("data", o, !0);
    l(c), i !== void 0 && (e.propertyName = i);
  }
  a && (e.dataTypes = a);
  function l(c) {
    e.data = c, e.dataLevel = t.dataLevel + 1, e.dataTypes = [], t.definedProperties = /* @__PURE__ */ new Set(), e.parentData = t.data, e.dataNames = [...t.dataNames, c];
  }
}
no.extendSubschemaData = wW;
function CW(e, { jtdDiscriminator: t, jtdMetadata: r, compositeRule: n, createErrors: o, allErrors: a }) {
  n !== void 0 && (e.compositeRule = n), o !== void 0 && (e.createErrors = o), a !== void 0 && (e.allErrors = a), e.jtdDiscriminator = t, e.jtdMetadata = r;
}
no.extendSubschemaMode = CW;
var rr = {}, Qv = function e(t, r) {
  if (t === r) return !0;
  if (t && r && typeof t == "object" && typeof r == "object") {
    if (t.constructor !== r.constructor) return !1;
    var n, o, a;
    if (Array.isArray(t)) {
      if (n = t.length, n != r.length) return !1;
      for (o = n; o-- !== 0; )
        if (!e(t[o], r[o])) return !1;
      return !0;
    }
    if (t.constructor === RegExp) return t.source === r.source && t.flags === r.flags;
    if (t.valueOf !== Object.prototype.valueOf) return t.valueOf() === r.valueOf();
    if (t.toString !== Object.prototype.toString) return t.toString() === r.toString();
    if (a = Object.keys(t), n = a.length, n !== Object.keys(r).length) return !1;
    for (o = n; o-- !== 0; )
      if (!Object.prototype.hasOwnProperty.call(r, a[o])) return !1;
    for (o = n; o-- !== 0; ) {
      var i = a[o];
      if (!e(t[i], r[i])) return !1;
    }
    return !0;
  }
  return t !== t && r !== r;
}, e1 = { exports: {} }, Qn = e1.exports = function(e, t, r) {
  typeof t == "function" && (r = t, t = {}), r = t.cb || r;
  var n = typeof r == "function" ? r : r.pre || function() {
  }, o = r.post || function() {
  };
  ol(t, n, o, e, "", e);
};
Qn.keywords = {
  additionalItems: !0,
  items: !0,
  contains: !0,
  additionalProperties: !0,
  propertyNames: !0,
  not: !0,
  if: !0,
  then: !0,
  else: !0
};
Qn.arrayKeywords = {
  items: !0,
  allOf: !0,
  anyOf: !0,
  oneOf: !0
};
Qn.propsKeywords = {
  $defs: !0,
  definitions: !0,
  properties: !0,
  patternProperties: !0,
  dependencies: !0
};
Qn.skipKeywords = {
  default: !0,
  enum: !0,
  const: !0,
  required: !0,
  maximum: !0,
  minimum: !0,
  exclusiveMaximum: !0,
  exclusiveMinimum: !0,
  multipleOf: !0,
  maxLength: !0,
  minLength: !0,
  pattern: !0,
  format: !0,
  maxItems: !0,
  minItems: !0,
  uniqueItems: !0,
  maxProperties: !0,
  minProperties: !0
};
function ol(e, t, r, n, o, a, i, s, l, c) {
  if (n && typeof n == "object" && !Array.isArray(n)) {
    t(n, o, a, i, s, l, c);
    for (var u in n) {
      var f = n[u];
      if (Array.isArray(f)) {
        if (u in Qn.arrayKeywords)
          for (var d = 0; d < f.length; d++)
            ol(e, t, r, f[d], o + "/" + u + "/" + d, a, o, u, n, d);
      } else if (u in Qn.propsKeywords) {
        if (f && typeof f == "object")
          for (var p in f)
            ol(e, t, r, f[p], o + "/" + u + "/" + EW(p), a, o, u, n, p);
      } else (u in Qn.keywords || e.allKeys && !(u in Qn.skipKeywords)) && ol(e, t, r, f, o + "/" + u, a, o, u, n);
    }
    r(n, o, a, i, s, l, c);
  }
}
function EW(e) {
  return e.replace(/~/g, "~0").replace(/\//g, "~1");
}
var _W = e1.exports;
Object.defineProperty(rr, "__esModule", { value: !0 });
rr.getSchemaRefs = rr.resolveUrl = rr.normalizeId = rr._getFullPath = rr.getFullPath = rr.inlineRef = void 0;
const xW = we, PW = Qv, kW = _W, OW = /* @__PURE__ */ new Set([
  "type",
  "format",
  "pattern",
  "maxLength",
  "minLength",
  "maxProperties",
  "minProperties",
  "maxItems",
  "minItems",
  "maximum",
  "minimum",
  "uniqueItems",
  "multipleOf",
  "required",
  "enum",
  "const"
]);
function AW(e, t = !0) {
  return typeof e == "boolean" ? !0 : t === !0 ? !rd(e) : t ? t1(e) <= t : !1;
}
rr.inlineRef = AW;
const IW = /* @__PURE__ */ new Set([
  "$ref",
  "$recursiveRef",
  "$recursiveAnchor",
  "$dynamicRef",
  "$dynamicAnchor"
]);
function rd(e) {
  for (const t in e) {
    if (IW.has(t))
      return !0;
    const r = e[t];
    if (Array.isArray(r) && r.some(rd) || typeof r == "object" && rd(r))
      return !0;
  }
  return !1;
}
function t1(e) {
  let t = 0;
  for (const r in e) {
    if (r === "$ref")
      return 1 / 0;
    if (t++, !OW.has(r) && (typeof e[r] == "object" && (0, xW.eachItem)(e[r], (n) => t += t1(n)), t === 1 / 0))
      return 1 / 0;
  }
  return t;
}
function r1(e, t = "", r) {
  r !== !1 && (t = fa(t));
  const n = e.parse(t);
  return n1(e, n);
}
rr.getFullPath = r1;
function n1(e, t) {
  return e.serialize(t).split("#")[0] + "#";
}
rr._getFullPath = n1;
const RW = /#\/?$/;
function fa(e) {
  return e ? e.replace(RW, "") : "";
}
rr.normalizeId = fa;
function TW(e, t, r) {
  return r = fa(r), e.resolve(t, r);
}
rr.resolveUrl = TW;
const MW = /^[a-z_][-a-z0-9._]*$/i;
function NW(e, t) {
  if (typeof e == "boolean")
    return {};
  const { schemaId: r, uriResolver: n } = this.opts, o = fa(e[r] || t), a = { "": o }, i = r1(n, o, !1), s = {}, l = /* @__PURE__ */ new Set();
  return kW(e, { allKeys: !0 }, (f, d, p, h) => {
    if (h === void 0)
      return;
    const $ = i + d;
    let b = a[h];
    typeof f[r] == "string" && (b = g.call(this, f[r])), y.call(this, f.$anchor), y.call(this, f.$dynamicAnchor), a[d] = b;
    function g(S) {
      const m = this.opts.uriResolver.resolve;
      if (S = fa(b ? m(b, S) : S), l.has(S))
        throw u(S);
      l.add(S);
      let w = this.refs[S];
      return typeof w == "string" && (w = this.refs[w]), typeof w == "object" ? c(f, w.schema, S) : S !== fa($) && (S[0] === "#" ? (c(f, s[S], S), s[S] = f) : this.refs[S] = $), S;
    }
    function y(S) {
      if (typeof S == "string") {
        if (!MW.test(S))
          throw new Error(`invalid anchor "${S}"`);
        g.call(this, `#${S}`);
      }
    }
  }), s;
  function c(f, d, p) {
    if (d !== void 0 && !PW(f, d))
      throw u(p);
  }
  function u(f) {
    return new Error(`reference "${f}" resolves to more than one schema`);
  }
}
rr.getSchemaRefs = NW;
Object.defineProperty(Zr, "__esModule", { value: !0 });
Zr.getData = Zr.KeywordCxt = Zr.validateFunctionCode = void 0;
const o1 = _a, Rg = Gt, Jf = Nn, kl = Gt, FW = kc, ki = gn, mu = no, Pe = Ge, Fe = wn, jW = rr, Fn = we, di = ms;
function DW(e) {
  if (s1(e) && (l1(e), i1(e))) {
    zW(e);
    return;
  }
  a1(e, () => (0, o1.topBoolOrEmptySchema)(e));
}
Zr.validateFunctionCode = DW;
function a1({ gen: e, validateName: t, schema: r, schemaEnv: n, opts: o }, a) {
  o.code.es5 ? e.func(t, (0, Pe._)`${Fe.default.data}, ${Fe.default.valCxt}`, n.$async, () => {
    e.code((0, Pe._)`"use strict"; ${Tg(r, o)}`), BW(e, o), e.code(a);
  }) : e.func(t, (0, Pe._)`${Fe.default.data}, ${LW(o)}`, n.$async, () => e.code(Tg(r, o)).code(a));
}
function LW(e) {
  return (0, Pe._)`{${Fe.default.instancePath}="", ${Fe.default.parentData}, ${Fe.default.parentDataProperty}, ${Fe.default.rootData}=${Fe.default.data}${e.dynamicRef ? (0, Pe._)`, ${Fe.default.dynamicAnchors}={}` : Pe.nil}}={}`;
}
function BW(e, t) {
  e.if(Fe.default.valCxt, () => {
    e.var(Fe.default.instancePath, (0, Pe._)`${Fe.default.valCxt}.${Fe.default.instancePath}`), e.var(Fe.default.parentData, (0, Pe._)`${Fe.default.valCxt}.${Fe.default.parentData}`), e.var(Fe.default.parentDataProperty, (0, Pe._)`${Fe.default.valCxt}.${Fe.default.parentDataProperty}`), e.var(Fe.default.rootData, (0, Pe._)`${Fe.default.valCxt}.${Fe.default.rootData}`), t.dynamicRef && e.var(Fe.default.dynamicAnchors, (0, Pe._)`${Fe.default.valCxt}.${Fe.default.dynamicAnchors}`);
  }, () => {
    e.var(Fe.default.instancePath, (0, Pe._)`""`), e.var(Fe.default.parentData, (0, Pe._)`undefined`), e.var(Fe.default.parentDataProperty, (0, Pe._)`undefined`), e.var(Fe.default.rootData, Fe.default.data), t.dynamicRef && e.var(Fe.default.dynamicAnchors, (0, Pe._)`{}`);
  });
}
function zW(e) {
  const { schema: t, opts: r, gen: n } = e;
  a1(e, () => {
    r.$comment && t.$comment && u1(e), KW(e), n.let(Fe.default.vErrors, null), n.let(Fe.default.errors, 0), r.unevaluated && UW(e), c1(e), JW(e);
  });
}
function UW(e) {
  const { gen: t, validateName: r } = e;
  e.evaluated = t.const("evaluated", (0, Pe._)`${r}.evaluated`), t.if((0, Pe._)`${e.evaluated}.dynamicProps`, () => t.assign((0, Pe._)`${e.evaluated}.props`, (0, Pe._)`undefined`)), t.if((0, Pe._)`${e.evaluated}.dynamicItems`, () => t.assign((0, Pe._)`${e.evaluated}.items`, (0, Pe._)`undefined`));
}
function Tg(e, t) {
  const r = typeof e == "object" && e[t.schemaId];
  return r && (t.code.source || t.code.process) ? (0, Pe._)`/*# sourceURL=${r} */` : Pe.nil;
}
function VW(e, t) {
  if (s1(e) && (l1(e), i1(e))) {
    qW(e, t);
    return;
  }
  (0, o1.boolOrEmptySchema)(e, t);
}
function i1({ schema: e, self: t }) {
  if (typeof e == "boolean")
    return !e;
  for (const r in e)
    if (t.RULES.all[r])
      return !0;
  return !1;
}
function s1(e) {
  return typeof e.schema != "boolean";
}
function qW(e, t) {
  const { schema: r, gen: n, opts: o } = e;
  o.$comment && r.$comment && u1(e), GW(e), HW(e);
  const a = n.const("_errs", Fe.default.errors);
  c1(e, a), n.var(t, (0, Pe._)`${a} === ${Fe.default.errors}`);
}
function l1(e) {
  (0, Fn.checkUnknownRules)(e), WW(e);
}
function c1(e, t) {
  if (e.opts.jtd)
    return Mg(e, [], !1, t);
  const r = (0, Rg.getSchemaTypes)(e.schema), n = (0, Rg.coerceAndCheckDataType)(e, r);
  Mg(e, r, !n, t);
}
function WW(e) {
  const { schema: t, errSchemaPath: r, opts: n, self: o } = e;
  t.$ref && n.ignoreKeywordsWithRef && (0, Fn.schemaHasRulesButRef)(t, o.RULES) && o.logger.warn(`$ref: keywords ignored in schema at path "${r}"`);
}
function KW(e) {
  const { schema: t, opts: r } = e;
  t.default !== void 0 && r.useDefaults && r.strictSchema && (0, Fn.checkStrictMode)(e, "default is ignored in the schema root");
}
function GW(e) {
  const t = e.schema[e.opts.schemaId];
  t && (e.baseId = (0, jW.resolveUrl)(e.opts.uriResolver, e.baseId, t));
}
function HW(e) {
  if (e.schema.$async && !e.schemaEnv.$async)
    throw new Error("async schema in sync schema");
}
function u1({ gen: e, schemaEnv: t, schema: r, errSchemaPath: n, opts: o }) {
  const a = r.$comment;
  if (o.$comment === !0)
    e.code((0, Pe._)`${Fe.default.self}.logger.log(${a})`);
  else if (typeof o.$comment == "function") {
    const i = (0, Pe.str)`${n}/$comment`, s = e.scopeValue("root", { ref: t.root });
    e.code((0, Pe._)`${Fe.default.self}.opts.$comment(${a}, ${i}, ${s}.schema)`);
  }
}
function JW(e) {
  const { gen: t, schemaEnv: r, validateName: n, ValidationError: o, opts: a } = e;
  r.$async ? t.if((0, Pe._)`${Fe.default.errors} === 0`, () => t.return(Fe.default.data), () => t.throw((0, Pe._)`new ${o}(${Fe.default.vErrors})`)) : (t.assign((0, Pe._)`${n}.errors`, Fe.default.vErrors), a.unevaluated && YW(e), t.return((0, Pe._)`${Fe.default.errors} === 0`));
}
function YW({ gen: e, evaluated: t, props: r, items: n }) {
  r instanceof Pe.Name && e.assign((0, Pe._)`${t}.props`, r), n instanceof Pe.Name && e.assign((0, Pe._)`${t}.items`, n);
}
function Mg(e, t, r, n) {
  const { gen: o, schema: a, data: i, allErrors: s, opts: l, self: c } = e, { RULES: u } = c;
  if (a.$ref && (l.ignoreKeywordsWithRef || !(0, Fn.schemaHasRulesButRef)(a, u))) {
    o.block(() => p1(e, "$ref", u.all.$ref.definition));
    return;
  }
  l.jtd || XW(e, t), o.block(() => {
    for (const d of u.rules)
      f(d);
    f(u.post);
  });
  function f(d) {
    (0, Jf.shouldUseGroup)(a, d) && (d.type ? (o.if((0, kl.checkDataType)(d.type, i, l.strictNumbers)), Ng(e, d), t.length === 1 && t[0] === d.type && r && (o.else(), (0, kl.reportTypeError)(e)), o.endIf()) : Ng(e, d), s || o.if((0, Pe._)`${Fe.default.errors} === ${n || 0}`));
  }
}
function Ng(e, t) {
  const { gen: r, schema: n, opts: { useDefaults: o } } = e;
  o && (0, FW.assignDefaults)(e, t.type), r.block(() => {
    for (const a of t.rules)
      (0, Jf.shouldUseRule)(n, a) && p1(e, a.keyword, a.definition, t.type);
  });
}
function XW(e, t) {
  e.schemaEnv.meta || !e.opts.strictTypes || (ZW(e, t), e.opts.allowUnionTypes || QW(e, t), eK(e, e.dataTypes));
}
function ZW(e, t) {
  if (t.length) {
    if (!e.dataTypes.length) {
      e.dataTypes = t;
      return;
    }
    t.forEach((r) => {
      d1(e.dataTypes, r) || Yf(e, `type "${r}" not allowed by context "${e.dataTypes.join(",")}"`);
    }), rK(e, t);
  }
}
function QW(e, t) {
  t.length > 1 && !(t.length === 2 && t.includes("null")) && Yf(e, "use allowUnionTypes to allow union type keyword");
}
function eK(e, t) {
  const r = e.self.RULES.all;
  for (const n in r) {
    const o = r[n];
    if (typeof o == "object" && (0, Jf.shouldUseRule)(e.schema, o)) {
      const { type: a } = o.definition;
      a.length && !a.some((i) => tK(t, i)) && Yf(e, `missing type "${a.join(",")}" for keyword "${n}"`);
    }
  }
}
function tK(e, t) {
  return e.includes(t) || t === "number" && e.includes("integer");
}
function d1(e, t) {
  return e.includes(t) || t === "integer" && e.includes("number");
}
function rK(e, t) {
  const r = [];
  for (const n of e.dataTypes)
    d1(t, n) ? r.push(n) : t.includes("integer") && n === "number" && r.push("integer");
  e.dataTypes = r;
}
function Yf(e, t) {
  const r = e.schemaEnv.baseId + e.errSchemaPath;
  t += ` at "${r}" (strictTypes)`, (0, Fn.checkStrictMode)(e, t, e.opts.strictTypes);
}
class f1 {
  constructor(t, r, n) {
    if ((0, ki.validateKeywordUsage)(t, r, n), this.gen = t.gen, this.allErrors = t.allErrors, this.keyword = n, this.data = t.data, this.schema = t.schema[n], this.$data = r.$data && t.opts.$data && this.schema && this.schema.$data, this.schemaValue = (0, Fn.schemaRefOrVal)(t, this.schema, n, this.$data), this.schemaType = r.schemaType, this.parentSchema = t.schema, this.params = {}, this.it = t, this.def = r, this.$data)
      this.schemaCode = t.gen.const("vSchema", h1(this.$data, t));
    else if (this.schemaCode = this.schemaValue, !(0, ki.validSchemaType)(this.schema, r.schemaType, r.allowUndefined))
      throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`);
    ("code" in r ? r.trackErrors : r.errors !== !1) && (this.errsCount = t.gen.const("_errs", Fe.default.errors));
  }
  result(t, r, n) {
    this.failResult((0, Pe.not)(t), r, n);
  }
  failResult(t, r, n) {
    this.gen.if(t), n ? n() : this.error(), r ? (this.gen.else(), r(), this.allErrors && this.gen.endIf()) : this.allErrors ? this.gen.endIf() : this.gen.else();
  }
  pass(t, r) {
    this.failResult((0, Pe.not)(t), void 0, r);
  }
  fail(t) {
    if (t === void 0) {
      this.error(), this.allErrors || this.gen.if(!1);
      return;
    }
    this.gen.if(t), this.error(), this.allErrors ? this.gen.endIf() : this.gen.else();
  }
  fail$data(t) {
    if (!this.$data)
      return this.fail(t);
    const { schemaCode: r } = this;
    this.fail((0, Pe._)`${r} !== undefined && (${(0, Pe.or)(this.invalid$data(), t)})`);
  }
  error(t, r, n) {
    if (r) {
      this.setParams(r), this._error(t, n), this.setParams({});
      return;
    }
    this._error(t, n);
  }
  _error(t, r) {
    (t ? di.reportExtraError : di.reportError)(this, this.def.error, r);
  }
  $dataError() {
    (0, di.reportError)(this, this.def.$dataError || di.keyword$DataError);
  }
  reset() {
    if (this.errsCount === void 0)
      throw new Error('add "trackErrors" to keyword definition');
    (0, di.resetErrorsCount)(this.gen, this.errsCount);
  }
  ok(t) {
    this.allErrors || this.gen.if(t);
  }
  setParams(t, r) {
    r ? Object.assign(this.params, t) : this.params = t;
  }
  block$data(t, r, n = Pe.nil) {
    this.gen.block(() => {
      this.check$data(t, n), r();
    });
  }
  check$data(t = Pe.nil, r = Pe.nil) {
    if (!this.$data)
      return;
    const { gen: n, schemaCode: o, schemaType: a, def: i } = this;
    n.if((0, Pe.or)((0, Pe._)`${o} === undefined`, r)), t !== Pe.nil && n.assign(t, !0), (a.length || i.validateSchema) && (n.elseIf(this.invalid$data()), this.$dataError(), t !== Pe.nil && n.assign(t, !1)), n.else();
  }
  invalid$data() {
    const { gen: t, schemaCode: r, schemaType: n, def: o, it: a } = this;
    return (0, Pe.or)(i(), s());
    function i() {
      if (n.length) {
        if (!(r instanceof Pe.Name))
          throw new Error("ajv implementation error");
        const l = Array.isArray(n) ? n : [n];
        return (0, Pe._)`${(0, kl.checkDataTypes)(l, r, a.opts.strictNumbers, kl.DataType.Wrong)}`;
      }
      return Pe.nil;
    }
    function s() {
      if (o.validateSchema) {
        const l = t.scopeValue("validate$data", { ref: o.validateSchema });
        return (0, Pe._)`!${l}(${r})`;
      }
      return Pe.nil;
    }
  }
  subschema(t, r) {
    const n = (0, mu.getSubschema)(this.it, t);
    (0, mu.extendSubschemaData)(n, this.it, t), (0, mu.extendSubschemaMode)(n, t);
    const o = { ...this.it, ...n, items: void 0, props: void 0 };
    return VW(o, r), o;
  }
  mergeEvaluated(t, r) {
    const { it: n, gen: o } = this;
    n.opts.unevaluated && (n.props !== !0 && t.props !== void 0 && (n.props = Fn.mergeEvaluated.props(o, t.props, n.props, r)), n.items !== !0 && t.items !== void 0 && (n.items = Fn.mergeEvaluated.items(o, t.items, n.items, r)));
  }
  mergeValidEvaluated(t, r) {
    const { it: n, gen: o } = this;
    if (n.opts.unevaluated && (n.props !== !0 || n.items !== !0))
      return o.if(r, () => this.mergeEvaluated(t, Pe.Name)), !0;
  }
}
Zr.KeywordCxt = f1;
function p1(e, t, r, n) {
  const o = new f1(e, r, t);
  "code" in r ? r.code(o, n) : o.$data && r.validate ? (0, ki.funcKeywordCode)(o, r) : "macro" in r ? (0, ki.macroKeywordCode)(o, r) : (r.compile || r.validate) && (0, ki.funcKeywordCode)(o, r);
}
const nK = /^\/(?:[^~]|~0|~1)*$/, oK = /^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;
function h1(e, { dataLevel: t, dataNames: r, dataPathArr: n }) {
  let o, a;
  if (e === "")
    return Fe.default.rootData;
  if (e[0] === "/") {
    if (!nK.test(e))
      throw new Error(`Invalid JSON-pointer: ${e}`);
    o = e, a = Fe.default.rootData;
  } else {
    const c = oK.exec(e);
    if (!c)
      throw new Error(`Invalid JSON-pointer: ${e}`);
    const u = +c[1];
    if (o = c[2], o === "#") {
      if (u >= t)
        throw new Error(l("property/index", u));
      return n[t - u];
    }
    if (u > t)
      throw new Error(l("data", u));
    if (a = r[t - u], !o)
      return a;
  }
  let i = a;
  const s = o.split("/");
  for (const c of s)
    c && (a = (0, Pe._)`${a}${(0, Pe.getProperty)((0, Fn.unescapeJsonPointer)(c))}`, i = (0, Pe._)`${i} && ${a}`);
  return i;
  function l(c, u) {
    return `Cannot access ${c} ${u} levels up, current level is ${t}`;
  }
}
Zr.getData = h1;
var gs = {};
Object.defineProperty(gs, "__esModule", { value: !0 });
class aK extends Error {
  constructor(t) {
    super("validation failed"), this.errors = t, this.ajv = this.validation = !0;
  }
}
gs.default = aK;
var Ha = {};
Object.defineProperty(Ha, "__esModule", { value: !0 });
const gu = rr;
class iK extends Error {
  constructor(t, r, n, o) {
    super(o || `can't resolve reference ${n} from id ${r}`), this.missingRef = (0, gu.resolveUrl)(t, r, n), this.missingSchema = (0, gu.normalizeId)((0, gu.getFullPath)(t, this.missingRef));
  }
}
Ha.default = iK;
var wr = {};
Object.defineProperty(wr, "__esModule", { value: !0 });
wr.resolveSchema = wr.getCompilingSchema = wr.resolveRef = wr.compileSchema = wr.SchemaEnv = void 0;
const Jr = Ge, sK = gs, go = wn, Xr = rr, Fg = we, lK = Zr;
class Oc {
  constructor(t) {
    var r;
    this.refs = {}, this.dynamicAnchors = {};
    let n;
    typeof t.schema == "object" && (n = t.schema), this.schema = t.schema, this.schemaId = t.schemaId, this.root = t.root || this, this.baseId = (r = t.baseId) !== null && r !== void 0 ? r : (0, Xr.normalizeId)(n == null ? void 0 : n[t.schemaId || "$id"]), this.schemaPath = t.schemaPath, this.localRefs = t.localRefs, this.meta = t.meta, this.$async = n == null ? void 0 : n.$async, this.refs = {};
  }
}
wr.SchemaEnv = Oc;
function Xf(e) {
  const t = m1.call(this, e);
  if (t)
    return t;
  const r = (0, Xr.getFullPath)(this.opts.uriResolver, e.root.baseId), { es5: n, lines: o } = this.opts.code, { ownProperties: a } = this.opts, i = new Jr.CodeGen(this.scope, { es5: n, lines: o, ownProperties: a });
  let s;
  e.$async && (s = i.scopeValue("Error", {
    ref: sK.default,
    code: (0, Jr._)`require("ajv/dist/runtime/validation_error").default`
  }));
  const l = i.scopeName("validate");
  e.validateName = l;
  const c = {
    gen: i,
    allErrors: this.opts.allErrors,
    data: go.default.data,
    parentData: go.default.parentData,
    parentDataProperty: go.default.parentDataProperty,
    dataNames: [go.default.data],
    dataPathArr: [Jr.nil],
    // TODO can its length be used as dataLevel if nil is removed?
    dataLevel: 0,
    dataTypes: [],
    definedProperties: /* @__PURE__ */ new Set(),
    topSchemaRef: i.scopeValue("schema", this.opts.code.source === !0 ? { ref: e.schema, code: (0, Jr.stringify)(e.schema) } : { ref: e.schema }),
    validateName: l,
    ValidationError: s,
    schema: e.schema,
    schemaEnv: e,
    rootId: r,
    baseId: e.baseId || r,
    schemaPath: Jr.nil,
    errSchemaPath: e.schemaPath || (this.opts.jtd ? "" : "#"),
    errorPath: (0, Jr._)`""`,
    opts: this.opts,
    self: this
  };
  let u;
  try {
    this._compilations.add(e), (0, lK.validateFunctionCode)(c), i.optimize(this.opts.code.optimize);
    const f = i.toString();
    u = `${i.scopeRefs(go.default.scope)}return ${f}`, this.opts.code.process && (u = this.opts.code.process(u, e));
    const p = new Function(`${go.default.self}`, `${go.default.scope}`, u)(this, this.scope.get());
    if (this.scope.value(l, { ref: p }), p.errors = null, p.schema = e.schema, p.schemaEnv = e, e.$async && (p.$async = !0), this.opts.code.source === !0 && (p.source = { validateName: l, validateCode: f, scopeValues: i._values }), this.opts.unevaluated) {
      const { props: h, items: $ } = c;
      p.evaluated = {
        props: h instanceof Jr.Name ? void 0 : h,
        items: $ instanceof Jr.Name ? void 0 : $,
        dynamicProps: h instanceof Jr.Name,
        dynamicItems: $ instanceof Jr.Name
      }, p.source && (p.source.evaluated = (0, Jr.stringify)(p.evaluated));
    }
    return e.validate = p, e;
  } catch (f) {
    throw delete e.validate, delete e.validateName, u && this.logger.error("Error compiling schema, function code:", u), f;
  } finally {
    this._compilations.delete(e);
  }
}
wr.compileSchema = Xf;
function cK(e, t, r) {
  var n;
  r = (0, Xr.resolveUrl)(this.opts.uriResolver, t, r);
  const o = e.refs[r];
  if (o)
    return o;
  let a = fK.call(this, e, r);
  if (a === void 0) {
    const i = (n = e.localRefs) === null || n === void 0 ? void 0 : n[r], { schemaId: s } = this.opts;
    i && (a = new Oc({ schema: i, schemaId: s, root: e, baseId: t }));
  }
  if (a !== void 0)
    return e.refs[r] = uK.call(this, a);
}
wr.resolveRef = cK;
function uK(e) {
  return (0, Xr.inlineRef)(e.schema, this.opts.inlineRefs) ? e.schema : e.validate ? e : Xf.call(this, e);
}
function m1(e) {
  for (const t of this._compilations)
    if (dK(t, e))
      return t;
}
wr.getCompilingSchema = m1;
function dK(e, t) {
  return e.schema === t.schema && e.root === t.root && e.baseId === t.baseId;
}
function fK(e, t) {
  let r;
  for (; typeof (r = this.refs[t]) == "string"; )
    t = r;
  return r || this.schemas[t] || Ac.call(this, e, t);
}
function Ac(e, t) {
  const r = this.opts.uriResolver.parse(t), n = (0, Xr._getFullPath)(this.opts.uriResolver, r);
  let o = (0, Xr.getFullPath)(this.opts.uriResolver, e.baseId, void 0);
  if (Object.keys(e.schema).length > 0 && n === o)
    return yu.call(this, r, e);
  const a = (0, Xr.normalizeId)(n), i = this.refs[a] || this.schemas[a];
  if (typeof i == "string") {
    const s = Ac.call(this, e, i);
    return typeof (s == null ? void 0 : s.schema) != "object" ? void 0 : yu.call(this, r, s);
  }
  if (typeof (i == null ? void 0 : i.schema) == "object") {
    if (i.validate || Xf.call(this, i), a === (0, Xr.normalizeId)(t)) {
      const { schema: s } = i, { schemaId: l } = this.opts, c = s[l];
      return c && (o = (0, Xr.resolveUrl)(this.opts.uriResolver, o, c)), new Oc({ schema: s, schemaId: l, root: e, baseId: o });
    }
    return yu.call(this, r, i);
  }
}
wr.resolveSchema = Ac;
const pK = /* @__PURE__ */ new Set([
  "properties",
  "patternProperties",
  "enum",
  "dependencies",
  "definitions"
]);
function yu(e, { baseId: t, schema: r, root: n }) {
  var o;
  if (((o = e.fragment) === null || o === void 0 ? void 0 : o[0]) !== "/")
    return;
  for (const s of e.fragment.slice(1).split("/")) {
    if (typeof r == "boolean")
      return;
    const l = r[(0, Fg.unescapeFragment)(s)];
    if (l === void 0)
      return;
    r = l;
    const c = typeof r == "object" && r[this.opts.schemaId];
    !pK.has(s) && c && (t = (0, Xr.resolveUrl)(this.opts.uriResolver, t, c));
  }
  let a;
  if (typeof r != "boolean" && r.$ref && !(0, Fg.schemaHasRulesButRef)(r, this.RULES)) {
    const s = (0, Xr.resolveUrl)(this.opts.uriResolver, t, r.$ref);
    a = Ac.call(this, n, s);
  }
  const { schemaId: i } = this.opts;
  if (a = a || new Oc({ schema: r, schemaId: i, root: n, baseId: t }), a.schema !== a.root.schema)
    return a;
}
const hK = "https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#", mK = "Meta-schema for $data reference (JSON AnySchema extension proposal)", gK = "object", yK = [
  "$data"
], bK = {
  $data: {
    type: "string",
    anyOf: [
      {
        format: "relative-json-pointer"
      },
      {
        format: "json-pointer"
      }
    ]
  }
}, vK = !1, $K = {
  $id: hK,
  description: mK,
  type: gK,
  required: yK,
  properties: bK,
  additionalProperties: vK
};
var Zf = {}, Ic = { exports: {} };
const SK = {
  0: 0,
  1: 1,
  2: 2,
  3: 3,
  4: 4,
  5: 5,
  6: 6,
  7: 7,
  8: 8,
  9: 9,
  a: 10,
  A: 10,
  b: 11,
  B: 11,
  c: 12,
  C: 12,
  d: 13,
  D: 13,
  e: 14,
  E: 14,
  f: 15,
  F: 15
};
var wK = {
  HEX: SK
};
const { HEX: CK } = wK, EK = /^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u;
function g1(e) {
  if (b1(e, ".") < 3)
    return { host: e, isIPV4: !1 };
  const t = e.match(EK) || [], [r] = t;
  return r ? { host: xK(r, "."), isIPV4: !0 } : { host: e, isIPV4: !1 };
}
function nd(e, t = !1) {
  let r = "", n = !0;
  for (const o of e) {
    if (CK[o] === void 0) return;
    o !== "0" && n === !0 && (n = !1), n || (r += o);
  }
  return t && r.length === 0 && (r = "0"), r;
}
function _K(e) {
  let t = 0;
  const r = { error: !1, address: "", zone: "" }, n = [], o = [];
  let a = !1, i = !1, s = !1;
  function l() {
    if (o.length) {
      if (a === !1) {
        const c = nd(o);
        if (c !== void 0)
          n.push(c);
        else
          return r.error = !0, !1;
      }
      o.length = 0;
    }
    return !0;
  }
  for (let c = 0; c < e.length; c++) {
    const u = e[c];
    if (!(u === "[" || u === "]"))
      if (u === ":") {
        if (i === !0 && (s = !0), !l())
          break;
        if (t++, n.push(":"), t > 7) {
          r.error = !0;
          break;
        }
        c - 1 >= 0 && e[c - 1] === ":" && (i = !0);
        continue;
      } else if (u === "%") {
        if (!l())
          break;
        a = !0;
      } else {
        o.push(u);
        continue;
      }
  }
  return o.length && (a ? r.zone = o.join("") : s ? n.push(o.join("")) : n.push(nd(o))), r.address = n.join(""), r;
}
function y1(e) {
  if (b1(e, ":") < 2)
    return { host: e, isIPV6: !1 };
  const t = _K(e);
  if (t.error)
    return { host: e, isIPV6: !1 };
  {
    let r = t.address, n = t.address;
    return t.zone && (r += "%" + t.zone, n += "%25" + t.zone), { host: r, escapedHost: n, isIPV6: !0 };
  }
}
function xK(e, t) {
  let r = "", n = !0;
  const o = e.length;
  for (let a = 0; a < o; a++) {
    const i = e[a];
    i === "0" && n ? (a + 1 <= o && e[a + 1] === t || a + 1 === o) && (r += i, n = !1) : (i === t ? n = !0 : n = !1, r += i);
  }
  return r;
}
function b1(e, t) {
  let r = 0;
  for (let n = 0; n < e.length; n++)
    e[n] === t && r++;
  return r;
}
const jg = /^\.\.?\//u, Dg = /^\/\.(?:\/|$)/u, Lg = /^\/\.\.(?:\/|$)/u, PK = /^\/?(?:.|\n)*?(?=\/|$)/u;
function kK(e) {
  const t = [];
  for (; e.length; )
    if (e.match(jg))
      e = e.replace(jg, "");
    else if (e.match(Dg))
      e = e.replace(Dg, "/");
    else if (e.match(Lg))
      e = e.replace(Lg, "/"), t.pop();
    else if (e === "." || e === "..")
      e = "";
    else {
      const r = e.match(PK);
      if (r) {
        const n = r[0];
        e = e.slice(n.length), t.push(n);
      } else
        throw new Error("Unexpected dot segment condition");
    }
  return t.join("");
}
function OK(e, t) {
  const r = t !== !0 ? escape : unescape;
  return e.scheme !== void 0 && (e.scheme = r(e.scheme)), e.userinfo !== void 0 && (e.userinfo = r(e.userinfo)), e.host !== void 0 && (e.host = r(e.host)), e.path !== void 0 && (e.path = r(e.path)), e.query !== void 0 && (e.query = r(e.query)), e.fragment !== void 0 && (e.fragment = r(e.fragment)), e;
}
function AK(e) {
  const t = [];
  if (e.userinfo !== void 0 && (t.push(e.userinfo), t.push("@")), e.host !== void 0) {
    let r = unescape(e.host);
    const n = g1(r);
    if (n.isIPV4)
      r = n.host;
    else {
      const o = y1(n.host);
      o.isIPV6 === !0 ? r = `[${o.escapedHost}]` : r = e.host;
    }
    t.push(r);
  }
  return (typeof e.port == "number" || typeof e.port == "string") && (t.push(":"), t.push(String(e.port))), t.length ? t.join("") : void 0;
}
var IK = {
  recomposeAuthority: AK,
  normalizeComponentEncoding: OK,
  removeDotSegments: kK,
  normalizeIPv4: g1,
  normalizeIPv6: y1,
  stringArrayToHexStripped: nd
};
const RK = /^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu, TK = /([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;
function v1(e) {
  return typeof e.secure == "boolean" ? e.secure : String(e.scheme).toLowerCase() === "wss";
}
function $1(e) {
  return e.host || (e.error = e.error || "HTTP URIs must have a host."), e;
}
function S1(e) {
  const t = String(e.scheme).toLowerCase() === "https";
  return (e.port === (t ? 443 : 80) || e.port === "") && (e.port = void 0), e.path || (e.path = "/"), e;
}
function MK(e) {
  return e.secure = v1(e), e.resourceName = (e.path || "/") + (e.query ? "?" + e.query : ""), e.path = void 0, e.query = void 0, e;
}
function NK(e) {
  if ((e.port === (v1(e) ? 443 : 80) || e.port === "") && (e.port = void 0), typeof e.secure == "boolean" && (e.scheme = e.secure ? "wss" : "ws", e.secure = void 0), e.resourceName) {
    const [t, r] = e.resourceName.split("?");
    e.path = t && t !== "/" ? t : void 0, e.query = r, e.resourceName = void 0;
  }
  return e.fragment = void 0, e;
}
function FK(e, t) {
  if (!e.path)
    return e.error = "URN can not be parsed", e;
  const r = e.path.match(TK);
  if (r) {
    const n = t.scheme || e.scheme || "urn";
    e.nid = r[1].toLowerCase(), e.nss = r[2];
    const o = `${n}:${t.nid || e.nid}`, a = Qf[o];
    e.path = void 0, a && (e = a.parse(e, t));
  } else
    e.error = e.error || "URN can not be parsed.";
  return e;
}
function jK(e, t) {
  const r = t.scheme || e.scheme || "urn", n = e.nid.toLowerCase(), o = `${r}:${t.nid || n}`, a = Qf[o];
  a && (e = a.serialize(e, t));
  const i = e, s = e.nss;
  return i.path = `${n || t.nid}:${s}`, t.skipEscape = !0, i;
}
function DK(e, t) {
  const r = e;
  return r.uuid = r.nss, r.nss = void 0, !t.tolerant && (!r.uuid || !RK.test(r.uuid)) && (r.error = r.error || "UUID is not valid."), r;
}
function LK(e) {
  const t = e;
  return t.nss = (e.uuid || "").toLowerCase(), t;
}
const w1 = {
  scheme: "http",
  domainHost: !0,
  parse: $1,
  serialize: S1
}, BK = {
  scheme: "https",
  domainHost: w1.domainHost,
  parse: $1,
  serialize: S1
}, al = {
  scheme: "ws",
  domainHost: !0,
  parse: MK,
  serialize: NK
}, zK = {
  scheme: "wss",
  domainHost: al.domainHost,
  parse: al.parse,
  serialize: al.serialize
}, UK = {
  scheme: "urn",
  parse: FK,
  serialize: jK,
  skipNormalize: !0
}, VK = {
  scheme: "urn:uuid",
  parse: DK,
  serialize: LK,
  skipNormalize: !0
}, Qf = {
  http: w1,
  https: BK,
  ws: al,
  wss: zK,
  urn: UK,
  "urn:uuid": VK
};
var qK = Qf;
const { normalizeIPv6: WK, normalizeIPv4: KK, removeDotSegments: vi, recomposeAuthority: GK, normalizeComponentEncoding: Ds } = IK, ep = qK;
function HK(e, t) {
  return typeof e == "string" ? e = yn(zn(e, t), t) : typeof e == "object" && (e = zn(yn(e, t), t)), e;
}
function JK(e, t, r) {
  const n = Object.assign({ scheme: "null" }, r), o = C1(zn(e, n), zn(t, n), n, !0);
  return yn(o, { ...n, skipEscape: !0 });
}
function C1(e, t, r, n) {
  const o = {};
  return n || (e = zn(yn(e, r), r), t = zn(yn(t, r), r)), r = r || {}, !r.tolerant && t.scheme ? (o.scheme = t.scheme, o.userinfo = t.userinfo, o.host = t.host, o.port = t.port, o.path = vi(t.path || ""), o.query = t.query) : (t.userinfo !== void 0 || t.host !== void 0 || t.port !== void 0 ? (o.userinfo = t.userinfo, o.host = t.host, o.port = t.port, o.path = vi(t.path || ""), o.query = t.query) : (t.path ? (t.path.charAt(0) === "/" ? o.path = vi(t.path) : ((e.userinfo !== void 0 || e.host !== void 0 || e.port !== void 0) && !e.path ? o.path = "/" + t.path : e.path ? o.path = e.path.slice(0, e.path.lastIndexOf("/") + 1) + t.path : o.path = t.path, o.path = vi(o.path)), o.query = t.query) : (o.path = e.path, t.query !== void 0 ? o.query = t.query : o.query = e.query), o.userinfo = e.userinfo, o.host = e.host, o.port = e.port), o.scheme = e.scheme), o.fragment = t.fragment, o;
}
function YK(e, t, r) {
  return typeof e == "string" ? (e = unescape(e), e = yn(Ds(zn(e, r), !0), { ...r, skipEscape: !0 })) : typeof e == "object" && (e = yn(Ds(e, !0), { ...r, skipEscape: !0 })), typeof t == "string" ? (t = unescape(t), t = yn(Ds(zn(t, r), !0), { ...r, skipEscape: !0 })) : typeof t == "object" && (t = yn(Ds(t, !0), { ...r, skipEscape: !0 })), e.toLowerCase() === t.toLowerCase();
}
function yn(e, t) {
  const r = {
    host: e.host,
    scheme: e.scheme,
    userinfo: e.userinfo,
    port: e.port,
    path: e.path,
    query: e.query,
    nid: e.nid,
    nss: e.nss,
    uuid: e.uuid,
    fragment: e.fragment,
    reference: e.reference,
    resourceName: e.resourceName,
    secure: e.secure,
    error: ""
  }, n = Object.assign({}, t), o = [], a = ep[(n.scheme || r.scheme || "").toLowerCase()];
  a && a.serialize && a.serialize(r, n), r.path !== void 0 && (n.skipEscape ? r.path = unescape(r.path) : (r.path = escape(r.path), r.scheme !== void 0 && (r.path = r.path.split("%3A").join(":")))), n.reference !== "suffix" && r.scheme && o.push(r.scheme, ":");
  const i = GK(r);
  if (i !== void 0 && (n.reference !== "suffix" && o.push("//"), o.push(i), r.path && r.path.charAt(0) !== "/" && o.push("/")), r.path !== void 0) {
    let s = r.path;
    !n.absolutePath && (!a || !a.absolutePath) && (s = vi(s)), i === void 0 && (s = s.replace(/^\/\//u, "/%2F")), o.push(s);
  }
  return r.query !== void 0 && o.push("?", r.query), r.fragment !== void 0 && o.push("#", r.fragment), o.join("");
}
const XK = Array.from({ length: 127 }, (e, t) => /[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(t)));
function ZK(e) {
  let t = 0;
  for (let r = 0, n = e.length; r < n; ++r)
    if (t = e.charCodeAt(r), t > 126 || XK[t])
      return !0;
  return !1;
}
const QK = /^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;
function zn(e, t) {
  const r = Object.assign({}, t), n = {
    scheme: void 0,
    userinfo: void 0,
    host: "",
    port: void 0,
    path: "",
    query: void 0,
    fragment: void 0
  }, o = e.indexOf("%") !== -1;
  let a = !1;
  r.reference === "suffix" && (e = (r.scheme ? r.scheme + ":" : "") + "//" + e);
  const i = e.match(QK);
  if (i) {
    if (n.scheme = i[1], n.userinfo = i[3], n.host = i[4], n.port = parseInt(i[5], 10), n.path = i[6] || "", n.query = i[7], n.fragment = i[8], isNaN(n.port) && (n.port = i[5]), n.host) {
      const l = KK(n.host);
      if (l.isIPV4 === !1) {
        const c = WK(l.host);
        n.host = c.host.toLowerCase(), a = c.isIPV6;
      } else
        n.host = l.host, a = !0;
    }
    n.scheme === void 0 && n.userinfo === void 0 && n.host === void 0 && n.port === void 0 && !n.path && n.query === void 0 ? n.reference = "same-document" : n.scheme === void 0 ? n.reference = "relative" : n.fragment === void 0 ? n.reference = "absolute" : n.reference = "uri", r.reference && r.reference !== "suffix" && r.reference !== n.reference && (n.error = n.error || "URI is not a " + r.reference + " reference.");
    const s = ep[(r.scheme || n.scheme || "").toLowerCase()];
    if (!r.unicodeSupport && (!s || !s.unicodeSupport) && n.host && (r.domainHost || s && s.domainHost) && a === !1 && ZK(n.host))
      try {
        n.host = URL.domainToASCII(n.host.toLowerCase());
      } catch (l) {
        n.error = n.error || "Host's domain name can not be converted to ASCII: " + l;
      }
    (!s || s && !s.skipNormalize) && (o && n.scheme !== void 0 && (n.scheme = unescape(n.scheme)), o && n.host !== void 0 && (n.host = unescape(n.host)), n.path && n.path.length && (n.path = escape(unescape(n.path))), n.fragment && n.fragment.length && (n.fragment = encodeURI(decodeURIComponent(n.fragment)))), s && s.parse && s.parse(n, r);
  } else
    n.error = n.error || "URI can not be parsed.";
  return n;
}
const tp = {
  SCHEMES: ep,
  normalize: HK,
  resolve: JK,
  resolveComponents: C1,
  equal: YK,
  serialize: yn,
  parse: zn
};
Ic.exports = tp;
Ic.exports.default = tp;
Ic.exports.fastUri = tp;
var eG = Ic.exports;
Object.defineProperty(Zf, "__esModule", { value: !0 });
const E1 = eG;
E1.code = 'require("ajv/dist/runtime/uri").default';
Zf.default = E1;
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.CodeGen = e.Name = e.nil = e.stringify = e.str = e._ = e.KeywordCxt = void 0;
  var t = Zr;
  Object.defineProperty(e, "KeywordCxt", { enumerable: !0, get: function() {
    return t.KeywordCxt;
  } });
  var r = Ge;
  Object.defineProperty(e, "_", { enumerable: !0, get: function() {
    return r._;
  } }), Object.defineProperty(e, "str", { enumerable: !0, get: function() {
    return r.str;
  } }), Object.defineProperty(e, "stringify", { enumerable: !0, get: function() {
    return r.stringify;
  } }), Object.defineProperty(e, "nil", { enumerable: !0, get: function() {
    return r.nil;
  } }), Object.defineProperty(e, "Name", { enumerable: !0, get: function() {
    return r.Name;
  } }), Object.defineProperty(e, "CodeGen", { enumerable: !0, get: function() {
    return r.CodeGen;
  } });
  const n = gs, o = Ha, a = Oo, i = wr, s = Ge, l = rr, c = Gt, u = we, f = $K, d = Zf, p = (H, j) => new RegExp(H, j);
  p.code = "new RegExp";
  const h = ["removeAdditional", "useDefaults", "coerceTypes"], $ = /* @__PURE__ */ new Set([
    "validate",
    "serialize",
    "parse",
    "wrapper",
    "root",
    "schema",
    "keyword",
    "pattern",
    "formats",
    "validate$data",
    "func",
    "obj",
    "Error"
  ]), b = {
    errorDataPath: "",
    format: "`validateFormats: false` can be used instead.",
    nullable: '"nullable" keyword is supported by default.',
    jsonPointers: "Deprecated jsPropertySyntax can be used instead.",
    extendRefs: "Deprecated ignoreKeywordsWithRef can be used instead.",
    missingRefs: "Pass empty schema with $id that should be ignored to ajv.addSchema.",
    processCode: "Use option `code: {process: (code, schemaEnv: object) => string}`",
    sourceCode: "Use option `code: {source: true}`",
    strictDefaults: "It is default now, see option `strict`.",
    strictKeywords: "It is default now, see option `strict`.",
    uniqueItems: '"uniqueItems" keyword is always validated.',
    unknownFormats: "Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",
    cache: "Map is used as cache, schema object as key.",
    serialize: "Map is used as cache, schema object as key.",
    ajvErrors: "It is default now."
  }, g = {
    ignoreKeywordsWithRef: "",
    jsPropertySyntax: "",
    unicode: '"minLength"/"maxLength" account for unicode characters by default.'
  }, y = 200;
  function S(H) {
    var j, Q, q, O, N, W, ne, ee, pe, ce, ye, _e, Me, Re, Ve, mt, Ue, qe, se, Ze, rt, Ce, Nt, re, fe;
    const ve = H.strict, Ie = (j = H.code) === null || j === void 0 ? void 0 : j.optimize, Le = Ie === !0 || Ie === void 0 ? 1 : Ie || 0, K = (q = (Q = H.code) === null || Q === void 0 ? void 0 : Q.regExp) !== null && q !== void 0 ? q : p, G = (O = H.uriResolver) !== null && O !== void 0 ? O : d.default;
    return {
      strictSchema: (W = (N = H.strictSchema) !== null && N !== void 0 ? N : ve) !== null && W !== void 0 ? W : !0,
      strictNumbers: (ee = (ne = H.strictNumbers) !== null && ne !== void 0 ? ne : ve) !== null && ee !== void 0 ? ee : !0,
      strictTypes: (ce = (pe = H.strictTypes) !== null && pe !== void 0 ? pe : ve) !== null && ce !== void 0 ? ce : "log",
      strictTuples: (_e = (ye = H.strictTuples) !== null && ye !== void 0 ? ye : ve) !== null && _e !== void 0 ? _e : "log",
      strictRequired: (Re = (Me = H.strictRequired) !== null && Me !== void 0 ? Me : ve) !== null && Re !== void 0 ? Re : !1,
      code: H.code ? { ...H.code, optimize: Le, regExp: K } : { optimize: Le, regExp: K },
      loopRequired: (Ve = H.loopRequired) !== null && Ve !== void 0 ? Ve : y,
      loopEnum: (mt = H.loopEnum) !== null && mt !== void 0 ? mt : y,
      meta: (Ue = H.meta) !== null && Ue !== void 0 ? Ue : !0,
      messages: (qe = H.messages) !== null && qe !== void 0 ? qe : !0,
      inlineRefs: (se = H.inlineRefs) !== null && se !== void 0 ? se : !0,
      schemaId: (Ze = H.schemaId) !== null && Ze !== void 0 ? Ze : "$id",
      addUsedSchema: (rt = H.addUsedSchema) !== null && rt !== void 0 ? rt : !0,
      validateSchema: (Ce = H.validateSchema) !== null && Ce !== void 0 ? Ce : !0,
      validateFormats: (Nt = H.validateFormats) !== null && Nt !== void 0 ? Nt : !0,
      unicodeRegExp: (re = H.unicodeRegExp) !== null && re !== void 0 ? re : !0,
      int32range: (fe = H.int32range) !== null && fe !== void 0 ? fe : !0,
      uriResolver: G
    };
  }
  class m {
    constructor(j = {}) {
      this.schemas = {}, this.refs = {}, this.formats = {}, this._compilations = /* @__PURE__ */ new Set(), this._loading = {}, this._cache = /* @__PURE__ */ new Map(), j = this.opts = { ...j, ...S(j) };
      const { es5: Q, lines: q } = this.opts.code;
      this.scope = new s.ValueScope({ scope: {}, prefixes: $, es5: Q, lines: q }), this.logger = F(j.logger);
      const O = j.validateFormats;
      j.validateFormats = !1, this.RULES = (0, a.getRules)(), w.call(this, b, j, "NOT SUPPORTED"), w.call(this, g, j, "DEPRECATED", "warn"), this._metaOpts = C.call(this), j.formats && I.call(this), this._addVocabularies(), this._addDefaultMetaSchema(), j.keywords && R.call(this, j.keywords), typeof j.meta == "object" && this.addMetaSchema(j.meta), E.call(this), j.validateFormats = O;
    }
    _addVocabularies() {
      this.addKeyword("$async");
    }
    _addDefaultMetaSchema() {
      const { $data: j, meta: Q, schemaId: q } = this.opts;
      let O = f;
      q === "id" && (O = { ...f }, O.id = O.$id, delete O.$id), Q && j && this.addMetaSchema(O, O[q], !1);
    }
    defaultMeta() {
      const { meta: j, schemaId: Q } = this.opts;
      return this.opts.defaultMeta = typeof j == "object" ? j[Q] || j : void 0;
    }
    validate(j, Q) {
      let q;
      if (typeof j == "string") {
        if (q = this.getSchema(j), !q)
          throw new Error(`no schema with key or ref "${j}"`);
      } else
        q = this.compile(j);
      const O = q(Q);
      return "$async" in q || (this.errors = q.errors), O;
    }
    compile(j, Q) {
      const q = this._addSchema(j, Q);
      return q.validate || this._compileSchemaEnv(q);
    }
    compileAsync(j, Q) {
      if (typeof this.opts.loadSchema != "function")
        throw new Error("options.loadSchema should be a function");
      const { loadSchema: q } = this.opts;
      return O.call(this, j, Q);
      async function O(ce, ye) {
        await N.call(this, ce.$schema);
        const _e = this._addSchema(ce, ye);
        return _e.validate || W.call(this, _e);
      }
      async function N(ce) {
        ce && !this.getSchema(ce) && await O.call(this, { $ref: ce }, !0);
      }
      async function W(ce) {
        try {
          return this._compileSchemaEnv(ce);
        } catch (ye) {
          if (!(ye instanceof o.default))
            throw ye;
          return ne.call(this, ye), await ee.call(this, ye.missingSchema), W.call(this, ce);
        }
      }
      function ne({ missingSchema: ce, missingRef: ye }) {
        if (this.refs[ce])
          throw new Error(`AnySchema ${ce} is loaded but ${ye} cannot be resolved`);
      }
      async function ee(ce) {
        const ye = await pe.call(this, ce);
        this.refs[ce] || await N.call(this, ye.$schema), this.refs[ce] || this.addSchema(ye, ce, Q);
      }
      async function pe(ce) {
        const ye = this._loading[ce];
        if (ye)
          return ye;
        try {
          return await (this._loading[ce] = q(ce));
        } finally {
          delete this._loading[ce];
        }
      }
    }
    // Adds schema to the instance
    addSchema(j, Q, q, O = this.opts.validateSchema) {
      if (Array.isArray(j)) {
        for (const W of j)
          this.addSchema(W, void 0, q, O);
        return this;
      }
      let N;
      if (typeof j == "object") {
        const { schemaId: W } = this.opts;
        if (N = j[W], N !== void 0 && typeof N != "string")
          throw new Error(`schema ${W} must be string`);
      }
      return Q = (0, l.normalizeId)(Q || N), this._checkUnique(Q), this.schemas[Q] = this._addSchema(j, q, Q, O, !0), this;
    }
    // Add schema that will be used to validate other schemas
    // options in META_IGNORE_OPTIONS are alway set to false
    addMetaSchema(j, Q, q = this.opts.validateSchema) {
      return this.addSchema(j, Q, !0, q), this;
    }
    //  Validate schema against its meta-schema
    validateSchema(j, Q) {
      if (typeof j == "boolean")
        return !0;
      let q;
      if (q = j.$schema, q !== void 0 && typeof q != "string")
        throw new Error("$schema must be a string");
      if (q = q || this.opts.defaultMeta || this.defaultMeta(), !q)
        return this.logger.warn("meta-schema not available"), this.errors = null, !0;
      const O = this.validate(q, j);
      if (!O && Q) {
        const N = "schema is invalid: " + this.errorsText();
        if (this.opts.validateSchema === "log")
          this.logger.error(N);
        else
          throw new Error(N);
      }
      return O;
    }
    // Get compiled schema by `key` or `ref`.
    // (`key` that was passed to `addSchema` or full schema reference - `schema.$id` or resolved id)
    getSchema(j) {
      let Q;
      for (; typeof (Q = v.call(this, j)) == "string"; )
        j = Q;
      if (Q === void 0) {
        const { schemaId: q } = this.opts, O = new i.SchemaEnv({ schema: {}, schemaId: q });
        if (Q = i.resolveSchema.call(this, O, j), !Q)
          return;
        this.refs[j] = Q;
      }
      return Q.validate || this._compileSchemaEnv(Q);
    }
    // Remove cached schema(s).
    // If no parameter is passed all schemas but meta-schemas are removed.
    // If RegExp is passed all schemas with key/id matching pattern but meta-schemas are removed.
    // Even if schema is referenced by other schemas it still can be removed as other schemas have local references.
    removeSchema(j) {
      if (j instanceof RegExp)
        return this._removeAllSchemas(this.schemas, j), this._removeAllSchemas(this.refs, j), this;
      switch (typeof j) {
        case "undefined":
          return this._removeAllSchemas(this.schemas), this._removeAllSchemas(this.refs), this._cache.clear(), this;
        case "string": {
          const Q = v.call(this, j);
          return typeof Q == "object" && this._cache.delete(Q.schema), delete this.schemas[j], delete this.refs[j], this;
        }
        case "object": {
          const Q = j;
          this._cache.delete(Q);
          let q = j[this.opts.schemaId];
          return q && (q = (0, l.normalizeId)(q), delete this.schemas[q], delete this.refs[q]), this;
        }
        default:
          throw new Error("ajv.removeSchema: invalid parameter");
      }
    }
    // add "vocabulary" - a collection of keywords
    addVocabulary(j) {
      for (const Q of j)
        this.addKeyword(Q);
      return this;
    }
    addKeyword(j, Q) {
      let q;
      if (typeof j == "string")
        q = j, typeof Q == "object" && (this.logger.warn("these parameters are deprecated, see docs for addKeyword"), Q.keyword = q);
      else if (typeof j == "object" && Q === void 0) {
        if (Q = j, q = Q.keyword, Array.isArray(q) && !q.length)
          throw new Error("addKeywords: keyword must be string or non-empty array");
      } else
        throw new Error("invalid addKeywords parameters");
      if (z.call(this, q, Q), !Q)
        return (0, u.eachItem)(q, (N) => L.call(this, N)), this;
      V.call(this, Q);
      const O = {
        ...Q,
        type: (0, c.getJSONTypes)(Q.type),
        schemaType: (0, c.getJSONTypes)(Q.schemaType)
      };
      return (0, u.eachItem)(q, O.type.length === 0 ? (N) => L.call(this, N, O) : (N) => O.type.forEach((W) => L.call(this, N, O, W))), this;
    }
    getKeyword(j) {
      const Q = this.RULES.all[j];
      return typeof Q == "object" ? Q.definition : !!Q;
    }
    // Remove keyword
    removeKeyword(j) {
      const { RULES: Q } = this;
      delete Q.keywords[j], delete Q.all[j];
      for (const q of Q.rules) {
        const O = q.rules.findIndex((N) => N.keyword === j);
        O >= 0 && q.rules.splice(O, 1);
      }
      return this;
    }
    // Add format
    addFormat(j, Q) {
      return typeof Q == "string" && (Q = new RegExp(Q)), this.formats[j] = Q, this;
    }
    errorsText(j = this.errors, { separator: Q = ", ", dataVar: q = "data" } = {}) {
      return !j || j.length === 0 ? "No errors" : j.map((O) => `${q}${O.instancePath} ${O.message}`).reduce((O, N) => O + Q + N);
    }
    $dataMetaSchema(j, Q) {
      const q = this.RULES.all;
      j = JSON.parse(JSON.stringify(j));
      for (const O of Q) {
        const N = O.split("/").slice(1);
        let W = j;
        for (const ne of N)
          W = W[ne];
        for (const ne in q) {
          const ee = q[ne];
          if (typeof ee != "object")
            continue;
          const { $data: pe } = ee.definition, ce = W[ne];
          pe && ce && (W[ne] = Y(ce));
        }
      }
      return j;
    }
    _removeAllSchemas(j, Q) {
      for (const q in j) {
        const O = j[q];
        (!Q || Q.test(q)) && (typeof O == "string" ? delete j[q] : O && !O.meta && (this._cache.delete(O.schema), delete j[q]));
      }
    }
    _addSchema(j, Q, q, O = this.opts.validateSchema, N = this.opts.addUsedSchema) {
      let W;
      const { schemaId: ne } = this.opts;
      if (typeof j == "object")
        W = j[ne];
      else {
        if (this.opts.jtd)
          throw new Error("schema must be object");
        if (typeof j != "boolean")
          throw new Error("schema must be object or boolean");
      }
      let ee = this._cache.get(j);
      if (ee !== void 0)
        return ee;
      q = (0, l.normalizeId)(W || q);
      const pe = l.getSchemaRefs.call(this, j, q);
      return ee = new i.SchemaEnv({ schema: j, schemaId: ne, meta: Q, baseId: q, localRefs: pe }), this._cache.set(ee.schema, ee), N && !q.startsWith("#") && (q && this._checkUnique(q), this.refs[q] = ee), O && this.validateSchema(j, !0), ee;
    }
    _checkUnique(j) {
      if (this.schemas[j] || this.refs[j])
        throw new Error(`schema with key or id "${j}" already exists`);
    }
    _compileSchemaEnv(j) {
      if (j.meta ? this._compileMetaSchema(j) : i.compileSchema.call(this, j), !j.validate)
        throw new Error("ajv implementation error");
      return j.validate;
    }
    _compileMetaSchema(j) {
      const Q = this.opts;
      this.opts = this._metaOpts;
      try {
        i.compileSchema.call(this, j);
      } finally {
        this.opts = Q;
      }
    }
  }
  m.ValidationError = n.default, m.MissingRefError = o.default, e.default = m;
  function w(H, j, Q, q = "error") {
    for (const O in H) {
      const N = O;
      N in j && this.logger[q](`${Q}: option ${O}. ${H[N]}`);
    }
  }
  function v(H) {
    return H = (0, l.normalizeId)(H), this.schemas[H] || this.refs[H];
  }
  function E() {
    const H = this.opts.schemas;
    if (H)
      if (Array.isArray(H))
        this.addSchema(H);
      else
        for (const j in H)
          this.addSchema(H[j], j);
  }
  function I() {
    for (const H in this.opts.formats) {
      const j = this.opts.formats[H];
      j && this.addFormat(H, j);
    }
  }
  function R(H) {
    if (Array.isArray(H)) {
      this.addVocabulary(H);
      return;
    }
    this.logger.warn("keywords option as map is deprecated, pass array");
    for (const j in H) {
      const Q = H[j];
      Q.keyword || (Q.keyword = j), this.addKeyword(Q);
    }
  }
  function C() {
    const H = { ...this.opts };
    for (const j of h)
      delete H[j];
    return H;
  }
  const T = { log() {
  }, warn() {
  }, error() {
  } };
  function F(H) {
    if (H === !1)
      return T;
    if (H === void 0)
      return console;
    if (H.log && H.warn && H.error)
      return H;
    throw new Error("logger must implement log, warn and error methods");
  }
  const D = /^[a-z_$][a-z0-9_$:-]*$/i;
  function z(H, j) {
    const { RULES: Q } = this;
    if ((0, u.eachItem)(H, (q) => {
      if (Q.keywords[q])
        throw new Error(`Keyword ${q} is already defined`);
      if (!D.test(q))
        throw new Error(`Keyword ${q} has invalid name`);
    }), !!j && j.$data && !("code" in j || "validate" in j))
      throw new Error('$data keyword must have "code" or "validate" function');
  }
  function L(H, j, Q) {
    var q;
    const O = j == null ? void 0 : j.post;
    if (Q && O)
      throw new Error('keyword with "post" flag cannot have "type"');
    const { RULES: N } = this;
    let W = O ? N.post : N.rules.find(({ type: ee }) => ee === Q);
    if (W || (W = { type: Q, rules: [] }, N.rules.push(W)), N.keywords[H] = !0, !j)
      return;
    const ne = {
      keyword: H,
      definition: {
        ...j,
        type: (0, c.getJSONTypes)(j.type),
        schemaType: (0, c.getJSONTypes)(j.schemaType)
      }
    };
    j.before ? X.call(this, W, ne, j.before) : W.rules.push(ne), N.all[H] = ne, (q = j.implements) === null || q === void 0 || q.forEach((ee) => this.addKeyword(ee));
  }
  function X(H, j, Q) {
    const q = H.rules.findIndex((O) => O.keyword === Q);
    q >= 0 ? H.rules.splice(q, 0, j) : (H.rules.push(j), this.logger.warn(`rule ${Q} is not defined`));
  }
  function V(H) {
    let { metaSchema: j } = H;
    j !== void 0 && (H.$data && this.opts.$data && (j = Y(j)), H.validateSchema = this.compile(j, !0));
  }
  const ie = {
    $ref: "https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"
  };
  function Y(H) {
    return { anyOf: [H, ie] };
  }
})(jv);
var rp = {}, np = {}, op = {};
Object.defineProperty(op, "__esModule", { value: !0 });
const tG = {
  keyword: "id",
  code() {
    throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID');
  }
};
op.default = tG;
var Ao = {};
Object.defineProperty(Ao, "__esModule", { value: !0 });
Ao.callRef = Ao.getValidate = void 0;
const rG = Ha, Bg = Je, vr = Ge, Qo = wn, zg = wr, Ls = we, nG = {
  keyword: "$ref",
  schemaType: "string",
  code(e) {
    const { gen: t, schema: r, it: n } = e, { baseId: o, schemaEnv: a, validateName: i, opts: s, self: l } = n, { root: c } = a;
    if ((r === "#" || r === "#/") && o === c.baseId)
      return f();
    const u = zg.resolveRef.call(l, c, o, r);
    if (u === void 0)
      throw new rG.default(n.opts.uriResolver, o, r);
    if (u instanceof zg.SchemaEnv)
      return d(u);
    return p(u);
    function f() {
      if (a === c)
        return il(e, i, a, a.$async);
      const h = t.scopeValue("root", { ref: c });
      return il(e, (0, vr._)`${h}.validate`, c, c.$async);
    }
    function d(h) {
      const $ = _1(e, h);
      il(e, $, h, h.$async);
    }
    function p(h) {
      const $ = t.scopeValue("schema", s.code.source === !0 ? { ref: h, code: (0, vr.stringify)(h) } : { ref: h }), b = t.name("valid"), g = e.subschema({
        schema: h,
        dataTypes: [],
        schemaPath: vr.nil,
        topSchemaRef: $,
        errSchemaPath: r
      }, b);
      e.mergeEvaluated(g), e.ok(b);
    }
  }
};
function _1(e, t) {
  const { gen: r } = e;
  return t.validate ? r.scopeValue("validate", { ref: t.validate }) : (0, vr._)`${r.scopeValue("wrapper", { ref: t })}.validate`;
}
Ao.getValidate = _1;
function il(e, t, r, n) {
  const { gen: o, it: a } = e, { allErrors: i, schemaEnv: s, opts: l } = a, c = l.passContext ? Qo.default.this : vr.nil;
  n ? u() : f();
  function u() {
    if (!s.$async)
      throw new Error("async schema referenced by sync schema");
    const h = o.let("valid");
    o.try(() => {
      o.code((0, vr._)`await ${(0, Bg.callValidateCode)(e, t, c)}`), p(t), i || o.assign(h, !0);
    }, ($) => {
      o.if((0, vr._)`!(${$} instanceof ${a.ValidationError})`, () => o.throw($)), d($), i || o.assign(h, !1);
    }), e.ok(h);
  }
  function f() {
    e.result((0, Bg.callValidateCode)(e, t, c), () => p(t), () => d(t));
  }
  function d(h) {
    const $ = (0, vr._)`${h}.errors`;
    o.assign(Qo.default.vErrors, (0, vr._)`${Qo.default.vErrors} === null ? ${$} : ${Qo.default.vErrors}.concat(${$})`), o.assign(Qo.default.errors, (0, vr._)`${Qo.default.vErrors}.length`);
  }
  function p(h) {
    var $;
    if (!a.opts.unevaluated)
      return;
    const b = ($ = r == null ? void 0 : r.validate) === null || $ === void 0 ? void 0 : $.evaluated;
    if (a.props !== !0)
      if (b && !b.dynamicProps)
        b.props !== void 0 && (a.props = Ls.mergeEvaluated.props(o, b.props, a.props));
      else {
        const g = o.var("props", (0, vr._)`${h}.evaluated.props`);
        a.props = Ls.mergeEvaluated.props(o, g, a.props, vr.Name);
      }
    if (a.items !== !0)
      if (b && !b.dynamicItems)
        b.items !== void 0 && (a.items = Ls.mergeEvaluated.items(o, b.items, a.items));
      else {
        const g = o.var("items", (0, vr._)`${h}.evaluated.items`);
        a.items = Ls.mergeEvaluated.items(o, g, a.items, vr.Name);
      }
  }
}
Ao.callRef = il;
Ao.default = nG;
Object.defineProperty(np, "__esModule", { value: !0 });
const oG = op, aG = Ao, iG = [
  "$schema",
  "$id",
  "$defs",
  "$vocabulary",
  { keyword: "$comment" },
  "definitions",
  oG.default,
  aG.default
];
np.default = iG;
var ap = {}, ip = {};
Object.defineProperty(ip, "__esModule", { value: !0 });
const Ol = Ge, Jn = Ol.operators, Al = {
  maximum: { okStr: "<=", ok: Jn.LTE, fail: Jn.GT },
  minimum: { okStr: ">=", ok: Jn.GTE, fail: Jn.LT },
  exclusiveMaximum: { okStr: "<", ok: Jn.LT, fail: Jn.GTE },
  exclusiveMinimum: { okStr: ">", ok: Jn.GT, fail: Jn.LTE }
}, sG = {
  message: ({ keyword: e, schemaCode: t }) => (0, Ol.str)`must be ${Al[e].okStr} ${t}`,
  params: ({ keyword: e, schemaCode: t }) => (0, Ol._)`{comparison: ${Al[e].okStr}, limit: ${t}}`
}, lG = {
  keyword: Object.keys(Al),
  type: "number",
  schemaType: "number",
  $data: !0,
  error: sG,
  code(e) {
    const { keyword: t, data: r, schemaCode: n } = e;
    e.fail$data((0, Ol._)`${r} ${Al[t].fail} ${n} || isNaN(${r})`);
  }
};
ip.default = lG;
var sp = {};
Object.defineProperty(sp, "__esModule", { value: !0 });
const Oi = Ge, cG = {
  message: ({ schemaCode: e }) => (0, Oi.str)`must be multiple of ${e}`,
  params: ({ schemaCode: e }) => (0, Oi._)`{multipleOf: ${e}}`
}, uG = {
  keyword: "multipleOf",
  type: "number",
  schemaType: "number",
  $data: !0,
  error: cG,
  code(e) {
    const { gen: t, data: r, schemaCode: n, it: o } = e, a = o.opts.multipleOfPrecision, i = t.let("res"), s = a ? (0, Oi._)`Math.abs(Math.round(${i}) - ${i}) > 1e-${a}` : (0, Oi._)`${i} !== parseInt(${i})`;
    e.fail$data((0, Oi._)`(${n} === 0 || (${i} = ${r}/${n}, ${s}))`);
  }
};
sp.default = uG;
var lp = {}, cp = {};
Object.defineProperty(cp, "__esModule", { value: !0 });
function x1(e) {
  const t = e.length;
  let r = 0, n = 0, o;
  for (; n < t; )
    r++, o = e.charCodeAt(n++), o >= 55296 && o <= 56319 && n < t && (o = e.charCodeAt(n), (o & 64512) === 56320 && n++);
  return r;
}
cp.default = x1;
x1.code = 'require("ajv/dist/runtime/ucs2length").default';
Object.defineProperty(lp, "__esModule", { value: !0 });
const Co = Ge, dG = we, fG = cp, pG = {
  message({ keyword: e, schemaCode: t }) {
    const r = e === "maxLength" ? "more" : "fewer";
    return (0, Co.str)`must NOT have ${r} than ${t} characters`;
  },
  params: ({ schemaCode: e }) => (0, Co._)`{limit: ${e}}`
}, hG = {
  keyword: ["maxLength", "minLength"],
  type: "string",
  schemaType: "number",
  $data: !0,
  error: pG,
  code(e) {
    const { keyword: t, data: r, schemaCode: n, it: o } = e, a = t === "maxLength" ? Co.operators.GT : Co.operators.LT, i = o.opts.unicode === !1 ? (0, Co._)`${r}.length` : (0, Co._)`${(0, dG.useFunc)(e.gen, fG.default)}(${r})`;
    e.fail$data((0, Co._)`${i} ${a} ${n}`);
  }
};
lp.default = hG;
var up = {};
Object.defineProperty(up, "__esModule", { value: !0 });
const mG = Je, Il = Ge, gG = {
  message: ({ schemaCode: e }) => (0, Il.str)`must match pattern "${e}"`,
  params: ({ schemaCode: e }) => (0, Il._)`{pattern: ${e}}`
}, yG = {
  keyword: "pattern",
  type: "string",
  schemaType: "string",
  $data: !0,
  error: gG,
  code(e) {
    const { data: t, $data: r, schema: n, schemaCode: o, it: a } = e, i = a.opts.unicodeRegExp ? "u" : "", s = r ? (0, Il._)`(new RegExp(${o}, ${i}))` : (0, mG.usePattern)(e, n);
    e.fail$data((0, Il._)`!${s}.test(${t})`);
  }
};
up.default = yG;
var dp = {};
Object.defineProperty(dp, "__esModule", { value: !0 });
const Ai = Ge, bG = {
  message({ keyword: e, schemaCode: t }) {
    const r = e === "maxProperties" ? "more" : "fewer";
    return (0, Ai.str)`must NOT have ${r} than ${t} properties`;
  },
  params: ({ schemaCode: e }) => (0, Ai._)`{limit: ${e}}`
}, vG = {
  keyword: ["maxProperties", "minProperties"],
  type: "object",
  schemaType: "number",
  $data: !0,
  error: bG,
  code(e) {
    const { keyword: t, data: r, schemaCode: n } = e, o = t === "maxProperties" ? Ai.operators.GT : Ai.operators.LT;
    e.fail$data((0, Ai._)`Object.keys(${r}).length ${o} ${n}`);
  }
};
dp.default = vG;
var fp = {};
Object.defineProperty(fp, "__esModule", { value: !0 });
const fi = Je, Ii = Ge, $G = we, SG = {
  message: ({ params: { missingProperty: e } }) => (0, Ii.str)`must have required property '${e}'`,
  params: ({ params: { missingProperty: e } }) => (0, Ii._)`{missingProperty: ${e}}`
}, wG = {
  keyword: "required",
  type: "object",
  schemaType: "array",
  $data: !0,
  error: SG,
  code(e) {
    const { gen: t, schema: r, schemaCode: n, data: o, $data: a, it: i } = e, { opts: s } = i;
    if (!a && r.length === 0)
      return;
    const l = r.length >= s.loopRequired;
    if (i.allErrors ? c() : u(), s.strictRequired) {
      const p = e.parentSchema.properties, { definedProperties: h } = e.it;
      for (const $ of r)
        if ((p == null ? void 0 : p[$]) === void 0 && !h.has($)) {
          const b = i.schemaEnv.baseId + i.errSchemaPath, g = `required property "${$}" is not defined at "${b}" (strictRequired)`;
          (0, $G.checkStrictMode)(i, g, i.opts.strictRequired);
        }
    }
    function c() {
      if (l || a)
        e.block$data(Ii.nil, f);
      else
        for (const p of r)
          (0, fi.checkReportMissingProp)(e, p);
    }
    function u() {
      const p = t.let("missing");
      if (l || a) {
        const h = t.let("valid", !0);
        e.block$data(h, () => d(p, h)), e.ok(h);
      } else
        t.if((0, fi.checkMissingProp)(e, r, p)), (0, fi.reportMissingProp)(e, p), t.else();
    }
    function f() {
      t.forOf("prop", n, (p) => {
        e.setParams({ missingProperty: p }), t.if((0, fi.noPropertyInData)(t, o, p, s.ownProperties), () => e.error());
      });
    }
    function d(p, h) {
      e.setParams({ missingProperty: p }), t.forOf(p, n, () => {
        t.assign(h, (0, fi.propertyInData)(t, o, p, s.ownProperties)), t.if((0, Ii.not)(h), () => {
          e.error(), t.break();
        });
      }, Ii.nil);
    }
  }
};
fp.default = wG;
var pp = {};
Object.defineProperty(pp, "__esModule", { value: !0 });
const Ri = Ge, CG = {
  message({ keyword: e, schemaCode: t }) {
    const r = e === "maxItems" ? "more" : "fewer";
    return (0, Ri.str)`must NOT have ${r} than ${t} items`;
  },
  params: ({ schemaCode: e }) => (0, Ri._)`{limit: ${e}}`
}, EG = {
  keyword: ["maxItems", "minItems"],
  type: "array",
  schemaType: "number",
  $data: !0,
  error: CG,
  code(e) {
    const { keyword: t, data: r, schemaCode: n } = e, o = t === "maxItems" ? Ri.operators.GT : Ri.operators.LT;
    e.fail$data((0, Ri._)`${r}.length ${o} ${n}`);
  }
};
pp.default = EG;
var hp = {}, ys = {};
Object.defineProperty(ys, "__esModule", { value: !0 });
const P1 = Qv;
P1.code = 'require("ajv/dist/runtime/equal").default';
ys.default = P1;
Object.defineProperty(hp, "__esModule", { value: !0 });
const bu = Gt, Qt = Ge, _G = we, xG = ys, PG = {
  message: ({ params: { i: e, j: t } }) => (0, Qt.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,
  params: ({ params: { i: e, j: t } }) => (0, Qt._)`{i: ${e}, j: ${t}}`
}, kG = {
  keyword: "uniqueItems",
  type: "array",
  schemaType: "boolean",
  $data: !0,
  error: PG,
  code(e) {
    const { gen: t, data: r, $data: n, schema: o, parentSchema: a, schemaCode: i, it: s } = e;
    if (!n && !o)
      return;
    const l = t.let("valid"), c = a.items ? (0, bu.getSchemaTypes)(a.items) : [];
    e.block$data(l, u, (0, Qt._)`${i} === false`), e.ok(l);
    function u() {
      const h = t.let("i", (0, Qt._)`${r}.length`), $ = t.let("j");
      e.setParams({ i: h, j: $ }), t.assign(l, !0), t.if((0, Qt._)`${h} > 1`, () => (f() ? d : p)(h, $));
    }
    function f() {
      return c.length > 0 && !c.some((h) => h === "object" || h === "array");
    }
    function d(h, $) {
      const b = t.name("item"), g = (0, bu.checkDataTypes)(c, b, s.opts.strictNumbers, bu.DataType.Wrong), y = t.const("indices", (0, Qt._)`{}`);
      t.for((0, Qt._)`;${h}--;`, () => {
        t.let(b, (0, Qt._)`${r}[${h}]`), t.if(g, (0, Qt._)`continue`), c.length > 1 && t.if((0, Qt._)`typeof ${b} == "string"`, (0, Qt._)`${b} += "_"`), t.if((0, Qt._)`typeof ${y}[${b}] == "number"`, () => {
          t.assign($, (0, Qt._)`${y}[${b}]`), e.error(), t.assign(l, !1).break();
        }).code((0, Qt._)`${y}[${b}] = ${h}`);
      });
    }
    function p(h, $) {
      const b = (0, _G.useFunc)(t, xG.default), g = t.name("outer");
      t.label(g).for((0, Qt._)`;${h}--;`, () => t.for((0, Qt._)`${$} = ${h}; ${$}--;`, () => t.if((0, Qt._)`${b}(${r}[${h}], ${r}[${$}])`, () => {
        e.error(), t.assign(l, !1).break(g);
      })));
    }
  }
};
hp.default = kG;
var mp = {};
Object.defineProperty(mp, "__esModule", { value: !0 });
const od = Ge, OG = we, AG = ys, IG = {
  message: "must be equal to constant",
  params: ({ schemaCode: e }) => (0, od._)`{allowedValue: ${e}}`
}, RG = {
  keyword: "const",
  $data: !0,
  error: IG,
  code(e) {
    const { gen: t, data: r, $data: n, schemaCode: o, schema: a } = e;
    n || a && typeof a == "object" ? e.fail$data((0, od._)`!${(0, OG.useFunc)(t, AG.default)}(${r}, ${o})`) : e.fail((0, od._)`${a} !== ${r}`);
  }
};
mp.default = RG;
var gp = {};
Object.defineProperty(gp, "__esModule", { value: !0 });
const $i = Ge, TG = we, MG = ys, NG = {
  message: "must be equal to one of the allowed values",
  params: ({ schemaCode: e }) => (0, $i._)`{allowedValues: ${e}}`
}, FG = {
  keyword: "enum",
  schemaType: "array",
  $data: !0,
  error: NG,
  code(e) {
    const { gen: t, data: r, $data: n, schema: o, schemaCode: a, it: i } = e;
    if (!n && o.length === 0)
      throw new Error("enum must have non-empty array");
    const s = o.length >= i.opts.loopEnum;
    let l;
    const c = () => l ?? (l = (0, TG.useFunc)(t, MG.default));
    let u;
    if (s || n)
      u = t.let("valid"), e.block$data(u, f);
    else {
      if (!Array.isArray(o))
        throw new Error("ajv implementation error");
      const p = t.const("vSchema", a);
      u = (0, $i.or)(...o.map((h, $) => d(p, $)));
    }
    e.pass(u);
    function f() {
      t.assign(u, !1), t.forOf("v", a, (p) => t.if((0, $i._)`${c()}(${r}, ${p})`, () => t.assign(u, !0).break()));
    }
    function d(p, h) {
      const $ = o[h];
      return typeof $ == "object" && $ !== null ? (0, $i._)`${c()}(${r}, ${p}[${h}])` : (0, $i._)`${r} === ${$}`;
    }
  }
};
gp.default = FG;
Object.defineProperty(ap, "__esModule", { value: !0 });
const jG = ip, DG = sp, LG = lp, BG = up, zG = dp, UG = fp, VG = pp, qG = hp, WG = mp, KG = gp, GG = [
  // number
  jG.default,
  DG.default,
  // string
  LG.default,
  BG.default,
  // object
  zG.default,
  UG.default,
  // array
  VG.default,
  qG.default,
  // any
  { keyword: "type", schemaType: ["string", "array"] },
  { keyword: "nullable", schemaType: "boolean" },
  WG.default,
  KG.default
];
ap.default = GG;
var yp = {}, Ja = {};
Object.defineProperty(Ja, "__esModule", { value: !0 });
Ja.validateAdditionalItems = void 0;
const Eo = Ge, ad = we, HG = {
  message: ({ params: { len: e } }) => (0, Eo.str)`must NOT have more than ${e} items`,
  params: ({ params: { len: e } }) => (0, Eo._)`{limit: ${e}}`
}, JG = {
  keyword: "additionalItems",
  type: "array",
  schemaType: ["boolean", "object"],
  before: "uniqueItems",
  error: HG,
  code(e) {
    const { parentSchema: t, it: r } = e, { items: n } = t;
    if (!Array.isArray(n)) {
      (0, ad.checkStrictMode)(r, '"additionalItems" is ignored when "items" is not an array of schemas');
      return;
    }
    k1(e, n);
  }
};
function k1(e, t) {
  const { gen: r, schema: n, data: o, keyword: a, it: i } = e;
  i.items = !0;
  const s = r.const("len", (0, Eo._)`${o}.length`);
  if (n === !1)
    e.setParams({ len: t.length }), e.pass((0, Eo._)`${s} <= ${t.length}`);
  else if (typeof n == "object" && !(0, ad.alwaysValidSchema)(i, n)) {
    const c = r.var("valid", (0, Eo._)`${s} <= ${t.length}`);
    r.if((0, Eo.not)(c), () => l(c)), e.ok(c);
  }
  function l(c) {
    r.forRange("i", t.length, s, (u) => {
      e.subschema({ keyword: a, dataProp: u, dataPropType: ad.Type.Num }, c), i.allErrors || r.if((0, Eo.not)(c), () => r.break());
    });
  }
}
Ja.validateAdditionalItems = k1;
Ja.default = JG;
var bp = {}, Ya = {};
Object.defineProperty(Ya, "__esModule", { value: !0 });
Ya.validateTuple = void 0;
const Ug = Ge, sl = we, YG = Je, XG = {
  keyword: "items",
  type: "array",
  schemaType: ["object", "array", "boolean"],
  before: "uniqueItems",
  code(e) {
    const { schema: t, it: r } = e;
    if (Array.isArray(t))
      return O1(e, "additionalItems", t);
    r.items = !0, !(0, sl.alwaysValidSchema)(r, t) && e.ok((0, YG.validateArray)(e));
  }
};
function O1(e, t, r = e.schema) {
  const { gen: n, parentSchema: o, data: a, keyword: i, it: s } = e;
  u(o), s.opts.unevaluated && r.length && s.items !== !0 && (s.items = sl.mergeEvaluated.items(n, r.length, s.items));
  const l = n.name("valid"), c = n.const("len", (0, Ug._)`${a}.length`);
  r.forEach((f, d) => {
    (0, sl.alwaysValidSchema)(s, f) || (n.if((0, Ug._)`${c} > ${d}`, () => e.subschema({
      keyword: i,
      schemaProp: d,
      dataProp: d
    }, l)), e.ok(l));
  });
  function u(f) {
    const { opts: d, errSchemaPath: p } = s, h = r.length, $ = h === f.minItems && (h === f.maxItems || f[t] === !1);
    if (d.strictTuples && !$) {
      const b = `"${i}" is ${h}-tuple, but minItems or maxItems/${t} are not specified or different at path "${p}"`;
      (0, sl.checkStrictMode)(s, b, d.strictTuples);
    }
  }
}
Ya.validateTuple = O1;
Ya.default = XG;
Object.defineProperty(bp, "__esModule", { value: !0 });
const ZG = Ya, QG = {
  keyword: "prefixItems",
  type: "array",
  schemaType: ["array"],
  before: "uniqueItems",
  code: (e) => (0, ZG.validateTuple)(e, "items")
};
bp.default = QG;
var vp = {};
Object.defineProperty(vp, "__esModule", { value: !0 });
const Vg = Ge, eH = we, tH = Je, rH = Ja, nH = {
  message: ({ params: { len: e } }) => (0, Vg.str)`must NOT have more than ${e} items`,
  params: ({ params: { len: e } }) => (0, Vg._)`{limit: ${e}}`
}, oH = {
  keyword: "items",
  type: "array",
  schemaType: ["object", "boolean"],
  before: "uniqueItems",
  error: nH,
  code(e) {
    const { schema: t, parentSchema: r, it: n } = e, { prefixItems: o } = r;
    n.items = !0, !(0, eH.alwaysValidSchema)(n, t) && (o ? (0, rH.validateAdditionalItems)(e, o) : e.ok((0, tH.validateArray)(e)));
  }
};
vp.default = oH;
var $p = {};
Object.defineProperty($p, "__esModule", { value: !0 });
const Dr = Ge, Bs = we, aH = {
  message: ({ params: { min: e, max: t } }) => t === void 0 ? (0, Dr.str)`must contain at least ${e} valid item(s)` : (0, Dr.str)`must contain at least ${e} and no more than ${t} valid item(s)`,
  params: ({ params: { min: e, max: t } }) => t === void 0 ? (0, Dr._)`{minContains: ${e}}` : (0, Dr._)`{minContains: ${e}, maxContains: ${t}}`
}, iH = {
  keyword: "contains",
  type: "array",
  schemaType: ["object", "boolean"],
  before: "uniqueItems",
  trackErrors: !0,
  error: aH,
  code(e) {
    const { gen: t, schema: r, parentSchema: n, data: o, it: a } = e;
    let i, s;
    const { minContains: l, maxContains: c } = n;
    a.opts.next ? (i = l === void 0 ? 1 : l, s = c) : i = 1;
    const u = t.const("len", (0, Dr._)`${o}.length`);
    if (e.setParams({ min: i, max: s }), s === void 0 && i === 0) {
      (0, Bs.checkStrictMode)(a, '"minContains" == 0 without "maxContains": "contains" keyword ignored');
      return;
    }
    if (s !== void 0 && i > s) {
      (0, Bs.checkStrictMode)(a, '"minContains" > "maxContains" is always invalid'), e.fail();
      return;
    }
    if ((0, Bs.alwaysValidSchema)(a, r)) {
      let $ = (0, Dr._)`${u} >= ${i}`;
      s !== void 0 && ($ = (0, Dr._)`${$} && ${u} <= ${s}`), e.pass($);
      return;
    }
    a.items = !0;
    const f = t.name("valid");
    s === void 0 && i === 1 ? p(f, () => t.if(f, () => t.break())) : i === 0 ? (t.let(f, !0), s !== void 0 && t.if((0, Dr._)`${o}.length > 0`, d)) : (t.let(f, !1), d()), e.result(f, () => e.reset());
    function d() {
      const $ = t.name("_valid"), b = t.let("count", 0);
      p($, () => t.if($, () => h(b)));
    }
    function p($, b) {
      t.forRange("i", 0, u, (g) => {
        e.subschema({
          keyword: "contains",
          dataProp: g,
          dataPropType: Bs.Type.Num,
          compositeRule: !0
        }, $), b();
      });
    }
    function h($) {
      t.code((0, Dr._)`${$}++`), s === void 0 ? t.if((0, Dr._)`${$} >= ${i}`, () => t.assign(f, !0).break()) : (t.if((0, Dr._)`${$} > ${s}`, () => t.assign(f, !1).break()), i === 1 ? t.assign(f, !0) : t.if((0, Dr._)`${$} >= ${i}`, () => t.assign(f, !0)));
    }
  }
};
$p.default = iH;
var A1 = {};
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.validateSchemaDeps = e.validatePropertyDeps = e.error = void 0;
  const t = Ge, r = we, n = Je;
  e.error = {
    message: ({ params: { property: l, depsCount: c, deps: u } }) => {
      const f = c === 1 ? "property" : "properties";
      return (0, t.str)`must have ${f} ${u} when property ${l} is present`;
    },
    params: ({ params: { property: l, depsCount: c, deps: u, missingProperty: f } }) => (0, t._)`{property: ${l},
    missingProperty: ${f},
    depsCount: ${c},
    deps: ${u}}`
    // TODO change to reference
  };
  const o = {
    keyword: "dependencies",
    type: "object",
    schemaType: "object",
    error: e.error,
    code(l) {
      const [c, u] = a(l);
      i(l, c), s(l, u);
    }
  };
  function a({ schema: l }) {
    const c = {}, u = {};
    for (const f in l) {
      if (f === "__proto__")
        continue;
      const d = Array.isArray(l[f]) ? c : u;
      d[f] = l[f];
    }
    return [c, u];
  }
  function i(l, c = l.schema) {
    const { gen: u, data: f, it: d } = l;
    if (Object.keys(c).length === 0)
      return;
    const p = u.let("missing");
    for (const h in c) {
      const $ = c[h];
      if ($.length === 0)
        continue;
      const b = (0, n.propertyInData)(u, f, h, d.opts.ownProperties);
      l.setParams({
        property: h,
        depsCount: $.length,
        deps: $.join(", ")
      }), d.allErrors ? u.if(b, () => {
        for (const g of $)
          (0, n.checkReportMissingProp)(l, g);
      }) : (u.if((0, t._)`${b} && (${(0, n.checkMissingProp)(l, $, p)})`), (0, n.reportMissingProp)(l, p), u.else());
    }
  }
  e.validatePropertyDeps = i;
  function s(l, c = l.schema) {
    const { gen: u, data: f, keyword: d, it: p } = l, h = u.name("valid");
    for (const $ in c)
      (0, r.alwaysValidSchema)(p, c[$]) || (u.if(
        (0, n.propertyInData)(u, f, $, p.opts.ownProperties),
        () => {
          const b = l.subschema({ keyword: d, schemaProp: $ }, h);
          l.mergeValidEvaluated(b, h);
        },
        () => u.var(h, !0)
        // TODO var
      ), l.ok(h));
  }
  e.validateSchemaDeps = s, e.default = o;
})(A1);
var Sp = {};
Object.defineProperty(Sp, "__esModule", { value: !0 });
const I1 = Ge, sH = we, lH = {
  message: "property name must be valid",
  params: ({ params: e }) => (0, I1._)`{propertyName: ${e.propertyName}}`
}, cH = {
  keyword: "propertyNames",
  type: "object",
  schemaType: ["object", "boolean"],
  error: lH,
  code(e) {
    const { gen: t, schema: r, data: n, it: o } = e;
    if ((0, sH.alwaysValidSchema)(o, r))
      return;
    const a = t.name("valid");
    t.forIn("key", n, (i) => {
      e.setParams({ propertyName: i }), e.subschema({
        keyword: "propertyNames",
        data: i,
        dataTypes: ["string"],
        propertyName: i,
        compositeRule: !0
      }, a), t.if((0, I1.not)(a), () => {
        e.error(!0), o.allErrors || t.break();
      });
    }), e.ok(a);
  }
};
Sp.default = cH;
var Rc = {};
Object.defineProperty(Rc, "__esModule", { value: !0 });
const zs = Je, Yr = Ge, uH = wn, Us = we, dH = {
  message: "must NOT have additional properties",
  params: ({ params: e }) => (0, Yr._)`{additionalProperty: ${e.additionalProperty}}`
}, fH = {
  keyword: "additionalProperties",
  type: ["object"],
  schemaType: ["boolean", "object"],
  allowUndefined: !0,
  trackErrors: !0,
  error: dH,
  code(e) {
    const { gen: t, schema: r, parentSchema: n, data: o, errsCount: a, it: i } = e;
    if (!a)
      throw new Error("ajv implementation error");
    const { allErrors: s, opts: l } = i;
    if (i.props = !0, l.removeAdditional !== "all" && (0, Us.alwaysValidSchema)(i, r))
      return;
    const c = (0, zs.allSchemaProperties)(n.properties), u = (0, zs.allSchemaProperties)(n.patternProperties);
    f(), e.ok((0, Yr._)`${a} === ${uH.default.errors}`);
    function f() {
      t.forIn("key", o, (b) => {
        !c.length && !u.length ? h(b) : t.if(d(b), () => h(b));
      });
    }
    function d(b) {
      let g;
      if (c.length > 8) {
        const y = (0, Us.schemaRefOrVal)(i, n.properties, "properties");
        g = (0, zs.isOwnProperty)(t, y, b);
      } else c.length ? g = (0, Yr.or)(...c.map((y) => (0, Yr._)`${b} === ${y}`)) : g = Yr.nil;
      return u.length && (g = (0, Yr.or)(g, ...u.map((y) => (0, Yr._)`${(0, zs.usePattern)(e, y)}.test(${b})`))), (0, Yr.not)(g);
    }
    function p(b) {
      t.code((0, Yr._)`delete ${o}[${b}]`);
    }
    function h(b) {
      if (l.removeAdditional === "all" || l.removeAdditional && r === !1) {
        p(b);
        return;
      }
      if (r === !1) {
        e.setParams({ additionalProperty: b }), e.error(), s || t.break();
        return;
      }
      if (typeof r == "object" && !(0, Us.alwaysValidSchema)(i, r)) {
        const g = t.name("valid");
        l.removeAdditional === "failing" ? ($(b, g, !1), t.if((0, Yr.not)(g), () => {
          e.reset(), p(b);
        })) : ($(b, g), s || t.if((0, Yr.not)(g), () => t.break()));
      }
    }
    function $(b, g, y) {
      const S = {
        keyword: "additionalProperties",
        dataProp: b,
        dataPropType: Us.Type.Str
      };
      y === !1 && Object.assign(S, {
        compositeRule: !0,
        createErrors: !1,
        allErrors: !1
      }), e.subschema(S, g);
    }
  }
};
Rc.default = fH;
var wp = {};
Object.defineProperty(wp, "__esModule", { value: !0 });
const pH = Zr, qg = Je, vu = we, Wg = Rc, hH = {
  keyword: "properties",
  type: "object",
  schemaType: "object",
  code(e) {
    const { gen: t, schema: r, parentSchema: n, data: o, it: a } = e;
    a.opts.removeAdditional === "all" && n.additionalProperties === void 0 && Wg.default.code(new pH.KeywordCxt(a, Wg.default, "additionalProperties"));
    const i = (0, qg.allSchemaProperties)(r);
    for (const f of i)
      a.definedProperties.add(f);
    a.opts.unevaluated && i.length && a.props !== !0 && (a.props = vu.mergeEvaluated.props(t, (0, vu.toHash)(i), a.props));
    const s = i.filter((f) => !(0, vu.alwaysValidSchema)(a, r[f]));
    if (s.length === 0)
      return;
    const l = t.name("valid");
    for (const f of s)
      c(f) ? u(f) : (t.if((0, qg.propertyInData)(t, o, f, a.opts.ownProperties)), u(f), a.allErrors || t.else().var(l, !0), t.endIf()), e.it.definedProperties.add(f), e.ok(l);
    function c(f) {
      return a.opts.useDefaults && !a.compositeRule && r[f].default !== void 0;
    }
    function u(f) {
      e.subschema({
        keyword: "properties",
        schemaProp: f,
        dataProp: f
      }, l);
    }
  }
};
wp.default = hH;
var Cp = {};
Object.defineProperty(Cp, "__esModule", { value: !0 });
const Kg = Je, Vs = Ge, Gg = we, Hg = we, mH = {
  keyword: "patternProperties",
  type: "object",
  schemaType: "object",
  code(e) {
    const { gen: t, schema: r, data: n, parentSchema: o, it: a } = e, { opts: i } = a, s = (0, Kg.allSchemaProperties)(r), l = s.filter(($) => (0, Gg.alwaysValidSchema)(a, r[$]));
    if (s.length === 0 || l.length === s.length && (!a.opts.unevaluated || a.props === !0))
      return;
    const c = i.strictSchema && !i.allowMatchingProperties && o.properties, u = t.name("valid");
    a.props !== !0 && !(a.props instanceof Vs.Name) && (a.props = (0, Hg.evaluatedPropsToName)(t, a.props));
    const { props: f } = a;
    d();
    function d() {
      for (const $ of s)
        c && p($), a.allErrors ? h($) : (t.var(u, !0), h($), t.if(u));
    }
    function p($) {
      for (const b in c)
        new RegExp($).test(b) && (0, Gg.checkStrictMode)(a, `property ${b} matches pattern ${$} (use allowMatchingProperties)`);
    }
    function h($) {
      t.forIn("key", n, (b) => {
        t.if((0, Vs._)`${(0, Kg.usePattern)(e, $)}.test(${b})`, () => {
          const g = l.includes($);
          g || e.subschema({
            keyword: "patternProperties",
            schemaProp: $,
            dataProp: b,
            dataPropType: Hg.Type.Str
          }, u), a.opts.unevaluated && f !== !0 ? t.assign((0, Vs._)`${f}[${b}]`, !0) : !g && !a.allErrors && t.if((0, Vs.not)(u), () => t.break());
        });
      });
    }
  }
};
Cp.default = mH;
var Ep = {};
Object.defineProperty(Ep, "__esModule", { value: !0 });
const gH = we, yH = {
  keyword: "not",
  schemaType: ["object", "boolean"],
  trackErrors: !0,
  code(e) {
    const { gen: t, schema: r, it: n } = e;
    if ((0, gH.alwaysValidSchema)(n, r)) {
      e.fail();
      return;
    }
    const o = t.name("valid");
    e.subschema({
      keyword: "not",
      compositeRule: !0,
      createErrors: !1,
      allErrors: !1
    }, o), e.failResult(o, () => e.reset(), () => e.error());
  },
  error: { message: "must NOT be valid" }
};
Ep.default = yH;
var _p = {};
Object.defineProperty(_p, "__esModule", { value: !0 });
const bH = Je, vH = {
  keyword: "anyOf",
  schemaType: "array",
  trackErrors: !0,
  code: bH.validateUnion,
  error: { message: "must match a schema in anyOf" }
};
_p.default = vH;
var xp = {};
Object.defineProperty(xp, "__esModule", { value: !0 });
const ll = Ge, $H = we, SH = {
  message: "must match exactly one schema in oneOf",
  params: ({ params: e }) => (0, ll._)`{passingSchemas: ${e.passing}}`
}, wH = {
  keyword: "oneOf",
  schemaType: "array",
  trackErrors: !0,
  error: SH,
  code(e) {
    const { gen: t, schema: r, parentSchema: n, it: o } = e;
    if (!Array.isArray(r))
      throw new Error("ajv implementation error");
    if (o.opts.discriminator && n.discriminator)
      return;
    const a = r, i = t.let("valid", !1), s = t.let("passing", null), l = t.name("_valid");
    e.setParams({ passing: s }), t.block(c), e.result(i, () => e.reset(), () => e.error(!0));
    function c() {
      a.forEach((u, f) => {
        let d;
        (0, $H.alwaysValidSchema)(o, u) ? t.var(l, !0) : d = e.subschema({
          keyword: "oneOf",
          schemaProp: f,
          compositeRule: !0
        }, l), f > 0 && t.if((0, ll._)`${l} && ${i}`).assign(i, !1).assign(s, (0, ll._)`[${s}, ${f}]`).else(), t.if(l, () => {
          t.assign(i, !0), t.assign(s, f), d && e.mergeEvaluated(d, ll.Name);
        });
      });
    }
  }
};
xp.default = wH;
var Pp = {};
Object.defineProperty(Pp, "__esModule", { value: !0 });
const CH = we, EH = {
  keyword: "allOf",
  schemaType: "array",
  code(e) {
    const { gen: t, schema: r, it: n } = e;
    if (!Array.isArray(r))
      throw new Error("ajv implementation error");
    const o = t.name("valid");
    r.forEach((a, i) => {
      if ((0, CH.alwaysValidSchema)(n, a))
        return;
      const s = e.subschema({ keyword: "allOf", schemaProp: i }, o);
      e.ok(o), e.mergeEvaluated(s);
    });
  }
};
Pp.default = EH;
var kp = {};
Object.defineProperty(kp, "__esModule", { value: !0 });
const Rl = Ge, R1 = we, _H = {
  message: ({ params: e }) => (0, Rl.str)`must match "${e.ifClause}" schema`,
  params: ({ params: e }) => (0, Rl._)`{failingKeyword: ${e.ifClause}}`
}, xH = {
  keyword: "if",
  schemaType: ["object", "boolean"],
  trackErrors: !0,
  error: _H,
  code(e) {
    const { gen: t, parentSchema: r, it: n } = e;
    r.then === void 0 && r.else === void 0 && (0, R1.checkStrictMode)(n, '"if" without "then" and "else" is ignored');
    const o = Jg(n, "then"), a = Jg(n, "else");
    if (!o && !a)
      return;
    const i = t.let("valid", !0), s = t.name("_valid");
    if (l(), e.reset(), o && a) {
      const u = t.let("ifClause");
      e.setParams({ ifClause: u }), t.if(s, c("then", u), c("else", u));
    } else o ? t.if(s, c("then")) : t.if((0, Rl.not)(s), c("else"));
    e.pass(i, () => e.error(!0));
    function l() {
      const u = e.subschema({
        keyword: "if",
        compositeRule: !0,
        createErrors: !1,
        allErrors: !1
      }, s);
      e.mergeEvaluated(u);
    }
    function c(u, f) {
      return () => {
        const d = e.subschema({ keyword: u }, s);
        t.assign(i, s), e.mergeValidEvaluated(d, i), f ? t.assign(f, (0, Rl._)`${u}`) : e.setParams({ ifClause: u });
      };
    }
  }
};
function Jg(e, t) {
  const r = e.schema[t];
  return r !== void 0 && !(0, R1.alwaysValidSchema)(e, r);
}
kp.default = xH;
var Op = {};
Object.defineProperty(Op, "__esModule", { value: !0 });
const PH = we, kH = {
  keyword: ["then", "else"],
  schemaType: ["object", "boolean"],
  code({ keyword: e, parentSchema: t, it: r }) {
    t.if === void 0 && (0, PH.checkStrictMode)(r, `"${e}" without "if" is ignored`);
  }
};
Op.default = kH;
Object.defineProperty(yp, "__esModule", { value: !0 });
const OH = Ja, AH = bp, IH = Ya, RH = vp, TH = $p, MH = A1, NH = Sp, FH = Rc, jH = wp, DH = Cp, LH = Ep, BH = _p, zH = xp, UH = Pp, VH = kp, qH = Op;
function WH(e = !1) {
  const t = [
    // any
    LH.default,
    BH.default,
    zH.default,
    UH.default,
    VH.default,
    qH.default,
    // object
    NH.default,
    FH.default,
    MH.default,
    jH.default,
    DH.default
  ];
  return e ? t.push(AH.default, RH.default) : t.push(OH.default, IH.default), t.push(TH.default), t;
}
yp.default = WH;
var Ap = {}, Ip = {};
Object.defineProperty(Ip, "__esModule", { value: !0 });
const Dt = Ge, KH = {
  message: ({ schemaCode: e }) => (0, Dt.str)`must match format "${e}"`,
  params: ({ schemaCode: e }) => (0, Dt._)`{format: ${e}}`
}, GH = {
  keyword: "format",
  type: ["number", "string"],
  schemaType: "string",
  $data: !0,
  error: KH,
  code(e, t) {
    const { gen: r, data: n, $data: o, schema: a, schemaCode: i, it: s } = e, { opts: l, errSchemaPath: c, schemaEnv: u, self: f } = s;
    if (!l.validateFormats)
      return;
    o ? d() : p();
    function d() {
      const h = r.scopeValue("formats", {
        ref: f.formats,
        code: l.code.formats
      }), $ = r.const("fDef", (0, Dt._)`${h}[${i}]`), b = r.let("fType"), g = r.let("format");
      r.if((0, Dt._)`typeof ${$} == "object" && !(${$} instanceof RegExp)`, () => r.assign(b, (0, Dt._)`${$}.type || "string"`).assign(g, (0, Dt._)`${$}.validate`), () => r.assign(b, (0, Dt._)`"string"`).assign(g, $)), e.fail$data((0, Dt.or)(y(), S()));
      function y() {
        return l.strictSchema === !1 ? Dt.nil : (0, Dt._)`${i} && !${g}`;
      }
      function S() {
        const m = u.$async ? (0, Dt._)`(${$}.async ? await ${g}(${n}) : ${g}(${n}))` : (0, Dt._)`${g}(${n})`, w = (0, Dt._)`(typeof ${g} == "function" ? ${m} : ${g}.test(${n}))`;
        return (0, Dt._)`${g} && ${g} !== true && ${b} === ${t} && !${w}`;
      }
    }
    function p() {
      const h = f.formats[a];
      if (!h) {
        y();
        return;
      }
      if (h === !0)
        return;
      const [$, b, g] = S(h);
      $ === t && e.pass(m());
      function y() {
        if (l.strictSchema === !1) {
          f.logger.warn(w());
          return;
        }
        throw new Error(w());
        function w() {
          return `unknown format "${a}" ignored in schema at path "${c}"`;
        }
      }
      function S(w) {
        const v = w instanceof RegExp ? (0, Dt.regexpCode)(w) : l.code.formats ? (0, Dt._)`${l.code.formats}${(0, Dt.getProperty)(a)}` : void 0, E = r.scopeValue("formats", { key: a, ref: w, code: v });
        return typeof w == "object" && !(w instanceof RegExp) ? [w.type || "string", w.validate, (0, Dt._)`${E}.validate`] : ["string", w, E];
      }
      function m() {
        if (typeof h == "object" && !(h instanceof RegExp) && h.async) {
          if (!u.$async)
            throw new Error("async format in sync schema");
          return (0, Dt._)`await ${g}(${n})`;
        }
        return typeof b == "function" ? (0, Dt._)`${g}(${n})` : (0, Dt._)`${g}.test(${n})`;
      }
    }
  }
};
Ip.default = GH;
Object.defineProperty(Ap, "__esModule", { value: !0 });
const HH = Ip, JH = [HH.default];
Ap.default = JH;
var xa = {};
Object.defineProperty(xa, "__esModule", { value: !0 });
xa.contentVocabulary = xa.metadataVocabulary = void 0;
xa.metadataVocabulary = [
  "title",
  "description",
  "default",
  "deprecated",
  "readOnly",
  "writeOnly",
  "examples"
];
xa.contentVocabulary = [
  "contentMediaType",
  "contentEncoding",
  "contentSchema"
];
Object.defineProperty(rp, "__esModule", { value: !0 });
const YH = np, XH = ap, ZH = yp, QH = Ap, Yg = xa, eJ = [
  YH.default,
  XH.default,
  (0, ZH.default)(),
  QH.default,
  Yg.metadataVocabulary,
  Yg.contentVocabulary
];
rp.default = eJ;
var Rp = {}, Tc = {};
Object.defineProperty(Tc, "__esModule", { value: !0 });
Tc.DiscrError = void 0;
var Xg;
(function(e) {
  e.Tag = "tag", e.Mapping = "mapping";
})(Xg || (Tc.DiscrError = Xg = {}));
Object.defineProperty(Rp, "__esModule", { value: !0 });
const na = Ge, id = Tc, Zg = wr, tJ = Ha, rJ = we, nJ = {
  message: ({ params: { discrError: e, tagName: t } }) => e === id.DiscrError.Tag ? `tag "${t}" must be string` : `value of tag "${t}" must be in oneOf`,
  params: ({ params: { discrError: e, tag: t, tagName: r } }) => (0, na._)`{error: ${e}, tag: ${r}, tagValue: ${t}}`
}, oJ = {
  keyword: "discriminator",
  type: "object",
  schemaType: "object",
  error: nJ,
  code(e) {
    const { gen: t, data: r, schema: n, parentSchema: o, it: a } = e, { oneOf: i } = o;
    if (!a.opts.discriminator)
      throw new Error("discriminator: requires discriminator option");
    const s = n.propertyName;
    if (typeof s != "string")
      throw new Error("discriminator: requires propertyName");
    if (n.mapping)
      throw new Error("discriminator: mapping is not supported");
    if (!i)
      throw new Error("discriminator: requires oneOf keyword");
    const l = t.let("valid", !1), c = t.const("tag", (0, na._)`${r}${(0, na.getProperty)(s)}`);
    t.if((0, na._)`typeof ${c} == "string"`, () => u(), () => e.error(!1, { discrError: id.DiscrError.Tag, tag: c, tagName: s })), e.ok(l);
    function u() {
      const p = d();
      t.if(!1);
      for (const h in p)
        t.elseIf((0, na._)`${c} === ${h}`), t.assign(l, f(p[h]));
      t.else(), e.error(!1, { discrError: id.DiscrError.Mapping, tag: c, tagName: s }), t.endIf();
    }
    function f(p) {
      const h = t.name("valid"), $ = e.subschema({ keyword: "oneOf", schemaProp: p }, h);
      return e.mergeEvaluated($, na.Name), h;
    }
    function d() {
      var p;
      const h = {}, $ = g(o);
      let b = !0;
      for (let m = 0; m < i.length; m++) {
        let w = i[m];
        if (w != null && w.$ref && !(0, rJ.schemaHasRulesButRef)(w, a.self.RULES)) {
          const E = w.$ref;
          if (w = Zg.resolveRef.call(a.self, a.schemaEnv.root, a.baseId, E), w instanceof Zg.SchemaEnv && (w = w.schema), w === void 0)
            throw new tJ.default(a.opts.uriResolver, a.baseId, E);
        }
        const v = (p = w == null ? void 0 : w.properties) === null || p === void 0 ? void 0 : p[s];
        if (typeof v != "object")
          throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${s}"`);
        b = b && ($ || g(w)), y(v, m);
      }
      if (!b)
        throw new Error(`discriminator: "${s}" must be required`);
      return h;
      function g({ required: m }) {
        return Array.isArray(m) && m.includes(s);
      }
      function y(m, w) {
        if (m.const)
          S(m.const, w);
        else if (m.enum)
          for (const v of m.enum)
            S(v, w);
        else
          throw new Error(`discriminator: "properties/${s}" must have "const" or "enum"`);
      }
      function S(m, w) {
        if (typeof m != "string" || m in h)
          throw new Error(`discriminator: "${s}" values must be unique strings`);
        h[m] = w;
      }
    }
  }
};
Rp.default = oJ;
const aJ = "http://json-schema.org/draft-07/schema#", iJ = "http://json-schema.org/draft-07/schema#", sJ = "Core schema meta-schema", lJ = {
  schemaArray: {
    type: "array",
    minItems: 1,
    items: {
      $ref: "#"
    }
  },
  nonNegativeInteger: {
    type: "integer",
    minimum: 0
  },
  nonNegativeIntegerDefault0: {
    allOf: [
      {
        $ref: "#/definitions/nonNegativeInteger"
      },
      {
        default: 0
      }
    ]
  },
  simpleTypes: {
    enum: [
      "array",
      "boolean",
      "integer",
      "null",
      "number",
      "object",
      "string"
    ]
  },
  stringArray: {
    type: "array",
    items: {
      type: "string"
    },
    uniqueItems: !0,
    default: []
  }
}, cJ = [
  "object",
  "boolean"
], uJ = {
  $id: {
    type: "string",
    format: "uri-reference"
  },
  $schema: {
    type: "string",
    format: "uri"
  },
  $ref: {
    type: "string",
    format: "uri-reference"
  },
  $comment: {
    type: "string"
  },
  title: {
    type: "string"
  },
  description: {
    type: "string"
  },
  default: !0,
  readOnly: {
    type: "boolean",
    default: !1
  },
  examples: {
    type: "array",
    items: !0
  },
  multipleOf: {
    type: "number",
    exclusiveMinimum: 0
  },
  maximum: {
    type: "number"
  },
  exclusiveMaximum: {
    type: "number"
  },
  minimum: {
    type: "number"
  },
  exclusiveMinimum: {
    type: "number"
  },
  maxLength: {
    $ref: "#/definitions/nonNegativeInteger"
  },
  minLength: {
    $ref: "#/definitions/nonNegativeIntegerDefault0"
  },
  pattern: {
    type: "string",
    format: "regex"
  },
  additionalItems: {
    $ref: "#"
  },
  items: {
    anyOf: [
      {
        $ref: "#"
      },
      {
        $ref: "#/definitions/schemaArray"
      }
    ],
    default: !0
  },
  maxItems: {
    $ref: "#/definitions/nonNegativeInteger"
  },
  minItems: {
    $ref: "#/definitions/nonNegativeIntegerDefault0"
  },
  uniqueItems: {
    type: "boolean",
    default: !1
  },
  contains: {
    $ref: "#"
  },
  maxProperties: {
    $ref: "#/definitions/nonNegativeInteger"
  },
  minProperties: {
    $ref: "#/definitions/nonNegativeIntegerDefault0"
  },
  required: {
    $ref: "#/definitions/stringArray"
  },
  additionalProperties: {
    $ref: "#"
  },
  definitions: {
    type: "object",
    additionalProperties: {
      $ref: "#"
    },
    default: {}
  },
  properties: {
    type: "object",
    additionalProperties: {
      $ref: "#"
    },
    default: {}
  },
  patternProperties: {
    type: "object",
    additionalProperties: {
      $ref: "#"
    },
    propertyNames: {
      format: "regex"
    },
    default: {}
  },
  dependencies: {
    type: "object",
    additionalProperties: {
      anyOf: [
        {
          $ref: "#"
        },
        {
          $ref: "#/definitions/stringArray"
        }
      ]
    }
  },
  propertyNames: {
    $ref: "#"
  },
  const: !0,
  enum: {
    type: "array",
    items: !0,
    minItems: 1,
    uniqueItems: !0
  },
  type: {
    anyOf: [
      {
        $ref: "#/definitions/simpleTypes"
      },
      {
        type: "array",
        items: {
          $ref: "#/definitions/simpleTypes"
        },
        minItems: 1,
        uniqueItems: !0
      }
    ]
  },
  format: {
    type: "string"
  },
  contentMediaType: {
    type: "string"
  },
  contentEncoding: {
    type: "string"
  },
  if: {
    $ref: "#"
  },
  then: {
    $ref: "#"
  },
  else: {
    $ref: "#"
  },
  allOf: {
    $ref: "#/definitions/schemaArray"
  },
  anyOf: {
    $ref: "#/definitions/schemaArray"
  },
  oneOf: {
    $ref: "#/definitions/schemaArray"
  },
  not: {
    $ref: "#"
  }
}, dJ = {
  $schema: aJ,
  $id: iJ,
  title: sJ,
  definitions: lJ,
  type: cJ,
  properties: uJ,
  default: !0
};
(function(e, t) {
  Object.defineProperty(t, "__esModule", { value: !0 }), t.MissingRefError = t.ValidationError = t.CodeGen = t.Name = t.nil = t.stringify = t.str = t._ = t.KeywordCxt = t.Ajv = void 0;
  const r = jv, n = rp, o = Rp, a = dJ, i = ["/properties"], s = "http://json-schema.org/draft-07/schema";
  class l extends r.default {
    _addVocabularies() {
      super._addVocabularies(), n.default.forEach((h) => this.addVocabulary(h)), this.opts.discriminator && this.addKeyword(o.default);
    }
    _addDefaultMetaSchema() {
      if (super._addDefaultMetaSchema(), !this.opts.meta)
        return;
      const h = this.opts.$data ? this.$dataMetaSchema(a, i) : a;
      this.addMetaSchema(h, s, !1), this.refs["http://json-schema.org/schema"] = s;
    }
    defaultMeta() {
      return this.opts.defaultMeta = super.defaultMeta() || (this.getSchema(s) ? s : void 0);
    }
  }
  t.Ajv = l, e.exports = t = l, e.exports.Ajv = l, Object.defineProperty(t, "__esModule", { value: !0 }), t.default = l;
  var c = Zr;
  Object.defineProperty(t, "KeywordCxt", { enumerable: !0, get: function() {
    return c.KeywordCxt;
  } });
  var u = Ge;
  Object.defineProperty(t, "_", { enumerable: !0, get: function() {
    return u._;
  } }), Object.defineProperty(t, "str", { enumerable: !0, get: function() {
    return u.str;
  } }), Object.defineProperty(t, "stringify", { enumerable: !0, get: function() {
    return u.stringify;
  } }), Object.defineProperty(t, "nil", { enumerable: !0, get: function() {
    return u.nil;
  } }), Object.defineProperty(t, "Name", { enumerable: !0, get: function() {
    return u.Name;
  } }), Object.defineProperty(t, "CodeGen", { enumerable: !0, get: function() {
    return u.CodeGen;
  } });
  var f = gs;
  Object.defineProperty(t, "ValidationError", { enumerable: !0, get: function() {
    return f.default;
  } });
  var d = Ha;
  Object.defineProperty(t, "MissingRefError", { enumerable: !0, get: function() {
    return d.default;
  } });
})(Zu, Zu.exports);
var T1 = Zu.exports;
const fJ = /* @__PURE__ */ pt(T1);
var sd = { exports: {} }, M1 = {};
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.formatNames = e.fastFormats = e.fullFormats = void 0;
  function t(R, C) {
    return { validate: R, compare: C };
  }
  e.fullFormats = {
    // date: http://tools.ietf.org/html/rfc3339#section-5.6
    date: t(a, i),
    // date-time: http://tools.ietf.org/html/rfc3339#section-5.6
    time: t(l, c),
    "date-time": t(f, d),
    // duration: https://tools.ietf.org/html/rfc3339#appendix-A
    duration: /^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,
    uri: $,
    "uri-reference": /^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,
    // uri-template: https://tools.ietf.org/html/rfc6570
    "uri-template": /^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,
    // For the source: https://gist.github.com/dperini/729294
    // For test cases: https://mathiasbynens.be/demo/url-regex
    url: /^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,
    email: /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,
    hostname: /^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,
    // optimized https://www.safaribooksonline.com/library/view/regular-expressions-cookbook/9780596802837/ch07s16.html
    ipv4: /^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,
    ipv6: /^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,
    regex: I,
    // uuid: http://tools.ietf.org/html/rfc4122
    uuid: /^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,
    // JSON-pointer: https://tools.ietf.org/html/rfc6901
    // uri fragment: https://tools.ietf.org/html/rfc3986#appendix-A
    "json-pointer": /^(?:\/(?:[^~/]|~0|~1)*)*$/,
    "json-pointer-uri-fragment": /^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,
    // relative JSON-pointer: http://tools.ietf.org/html/draft-luff-relative-json-pointer-00
    "relative-json-pointer": /^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,
    // the following formats are used by the openapi specification: https://spec.openapis.org/oas/v3.0.0#data-types
    // byte: https://github.com/miguelmota/is-base64
    byte: g,
    // signed 32 bit integer
    int32: { type: "number", validate: m },
    // signed 64 bit integer
    int64: { type: "number", validate: w },
    // C-type float
    float: { type: "number", validate: v },
    // C-type double
    double: { type: "number", validate: v },
    // hint to the UI to hide input strings
    password: !0,
    // unchecked string payload
    binary: !0
  }, e.fastFormats = {
    ...e.fullFormats,
    date: t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/, i),
    time: t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i, c),
    "date-time": t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i, d),
    // uri: https://github.com/mafintosh/is-my-json-valid/blob/master/formats.js
    uri: /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,
    "uri-reference": /^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,
    // email (sources from jsen validator):
    // http://stackoverflow.com/questions/201323/using-a-regular-expression-to-validate-an-email-address#answer-8829363
    // http://www.w3.org/TR/html5/forms.html#valid-e-mail-address (search for 'wilful violation')
    email: /^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i
  }, e.formatNames = Object.keys(e.fullFormats);
  function r(R) {
    return R % 4 === 0 && (R % 100 !== 0 || R % 400 === 0);
  }
  const n = /^(\d\d\d\d)-(\d\d)-(\d\d)$/, o = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
  function a(R) {
    const C = n.exec(R);
    if (!C)
      return !1;
    const T = +C[1], F = +C[2], D = +C[3];
    return F >= 1 && F <= 12 && D >= 1 && D <= (F === 2 && r(T) ? 29 : o[F]);
  }
  function i(R, C) {
    if (R && C)
      return R > C ? 1 : R < C ? -1 : 0;
  }
  const s = /^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;
  function l(R, C) {
    const T = s.exec(R);
    if (!T)
      return !1;
    const F = +T[1], D = +T[2], z = +T[3], L = T[5];
    return (F <= 23 && D <= 59 && z <= 59 || F === 23 && D === 59 && z === 60) && (!C || L !== "");
  }
  function c(R, C) {
    if (!(R && C))
      return;
    const T = s.exec(R), F = s.exec(C);
    if (T && F)
      return R = T[1] + T[2] + T[3] + (T[4] || ""), C = F[1] + F[2] + F[3] + (F[4] || ""), R > C ? 1 : R < C ? -1 : 0;
  }
  const u = /t|\s/i;
  function f(R) {
    const C = R.split(u);
    return C.length === 2 && a(C[0]) && l(C[1], !0);
  }
  function d(R, C) {
    if (!(R && C))
      return;
    const [T, F] = R.split(u), [D, z] = C.split(u), L = i(T, D);
    if (L !== void 0)
      return L || c(F, z);
  }
  const p = /\/|:/, h = /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;
  function $(R) {
    return p.test(R) && h.test(R);
  }
  const b = /^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;
  function g(R) {
    return b.lastIndex = 0, b.test(R);
  }
  const y = -2147483648, S = 2 ** 31 - 1;
  function m(R) {
    return Number.isInteger(R) && R <= S && R >= y;
  }
  function w(R) {
    return Number.isInteger(R);
  }
  function v() {
    return !0;
  }
  const E = /[^\\]\\Z/;
  function I(R) {
    if (E.test(R))
      return !1;
    try {
      return new RegExp(R), !0;
    } catch {
      return !1;
    }
  }
})(M1);
var N1 = {};
(function(e) {
  Object.defineProperty(e, "__esModule", { value: !0 }), e.formatLimitDefinition = void 0;
  const t = T1, r = Ge, n = r.operators, o = {
    formatMaximum: { okStr: "<=", ok: n.LTE, fail: n.GT },
    formatMinimum: { okStr: ">=", ok: n.GTE, fail: n.LT },
    formatExclusiveMaximum: { okStr: "<", ok: n.LT, fail: n.GTE },
    formatExclusiveMinimum: { okStr: ">", ok: n.GT, fail: n.LTE }
  }, a = {
    message: ({ keyword: s, schemaCode: l }) => r.str`should be ${o[s].okStr} ${l}`,
    params: ({ keyword: s, schemaCode: l }) => r._`{comparison: ${o[s].okStr}, limit: ${l}}`
  };
  e.formatLimitDefinition = {
    keyword: Object.keys(o),
    type: "string",
    schemaType: "string",
    $data: !0,
    error: a,
    code(s) {
      const { gen: l, data: c, schemaCode: u, keyword: f, it: d } = s, { opts: p, self: h } = d;
      if (!p.validateFormats)
        return;
      const $ = new t.KeywordCxt(d, h.RULES.all.format.definition, "format");
      $.$data ? b() : g();
      function b() {
        const S = l.scopeValue("formats", {
          ref: h.formats,
          code: p.code.formats
        }), m = l.const("fmt", r._`${S}[${$.schemaCode}]`);
        s.fail$data(r.or(r._`typeof ${m} != "object"`, r._`${m} instanceof RegExp`, r._`typeof ${m}.compare != "function"`, y(m)));
      }
      function g() {
        const S = $.schema, m = h.formats[S];
        if (!m || m === !0)
          return;
        if (typeof m != "object" || m instanceof RegExp || typeof m.compare != "function")
          throw new Error(`"${f}": format "${S}" does not define "compare" function`);
        const w = l.scopeValue("formats", {
          key: S,
          ref: m,
          code: p.code.formats ? r._`${p.code.formats}${r.getProperty(S)}` : void 0
        });
        s.fail$data(y(w));
      }
      function y(S) {
        return r._`${S}.compare(${c}, ${u}) ${o[f].fail} 0`;
      }
    },
    dependencies: ["format"]
  };
  const i = (s) => (s.addKeyword(e.formatLimitDefinition), s);
  e.default = i;
})(N1);
(function(e, t) {
  Object.defineProperty(t, "__esModule", { value: !0 });
  const r = M1, n = N1, o = Ge, a = new o.Name("fullFormats"), i = new o.Name("fastFormats"), s = (c, u = { keywords: !0 }) => {
    if (Array.isArray(u))
      return l(c, u, r.fullFormats, a), c;
    const [f, d] = u.mode === "fast" ? [r.fastFormats, i] : [r.fullFormats, a], p = u.formats || r.formatNames;
    return l(c, p, f, d), u.keywords && n.default(c), c;
  };
  s.get = (c, u = "full") => {
    const d = (u === "fast" ? r.fastFormats : r.fullFormats)[c];
    if (!d)
      throw new Error(`Unknown format "${c}"`);
    return d;
  };
  function l(c, u, f, d) {
    var p, h;
    (p = (h = c.opts.code).formats) !== null && p !== void 0 || (h.formats = o._`require("ajv-formats/dist/formats").${d}`);
    for (const $ of u)
      c.addFormat($, f[$]);
  }
  e.exports = t = s, Object.defineProperty(t, "__esModule", { value: !0 }), t.default = s;
})(sd, sd.exports);
var pJ = sd.exports;
const Qg = /* @__PURE__ */ pt(pJ), hJ = {
  allErrors: !0,
  multipleOfPrecision: 8,
  strict: !1,
  verbose: !0,
  discriminator: !1
  // TODO enable this in V6
}, mJ = /^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/, gJ = /^data:([a-z]+\/[a-z0-9-+.]+)?;(?:name=(.*);)?base64,(.*)$/;
function yJ(e, t, r = {}, n, o = fJ) {
  const a = new o({ ...hJ, ...r });
  return n ? Qg(a, n) : n !== !1 && Qg(a), a.addFormat("data-url", gJ), a.addFormat("color", mJ), a.addKeyword(ka), a.addKeyword(gd), Array.isArray(e) && a.addMetaSchema(e), Ur(t) && Object.keys(t).forEach((i) => {
    a.addFormat(i, t[i]);
  }), a;
}
function bJ(e = [], t) {
  return e.map((r) => {
    const { instancePath: n, keyword: o, params: a, schemaPath: i, parentSchema: s, ...l } = r;
    let { message: c = "" } = l, u = n.replace(/\//g, "."), f = `${u} ${c}`.trim();
    if ("missingProperty" in a) {
      u = u ? `${u}.${a.missingProperty}` : a.missingProperty;
      const d = a.missingProperty;
      let p = Qe(xe(t, `${u.replace(/^\./, "")}`)).title;
      if (p === void 0) {
        const h = i.replace(/\/properties\//g, "/").split("/").slice(1, -1).concat([d]);
        p = Qe(xe(t, h)).title;
      }
      if (p)
        c = c.replace(`'${d}'`, `'${p}'`);
      else {
        const h = xe(s, [Mt, d, "title"]);
        h && (c = c.replace(`'${d}'`, `'${h}'`));
      }
      f = c;
    } else {
      const d = Qe(xe(t, `${u.replace(/^\./, "")}`)).title;
      if (d)
        f = `'${d}' ${c}`.trim();
      else {
        const p = s == null ? void 0 : s.title;
        p && (f = `'${p}' ${c}`.trim());
      }
    }
    return {
      name: o,
      property: u,
      message: c,
      params: a,
      stack: f,
      schemaPath: i
    };
  });
}
function vJ(e, t, r, n, o, a, i) {
  const { validationError: s } = t;
  let l = bJ(t.errors, i);
  s && (l = [...l, { stack: s.message }]), typeof a == "function" && (l = a(l, i));
  let c = HF(l);
  if (s && (c = {
    ...c,
    $schema: {
      __errors: [s.message]
    }
  }), typeof o != "function")
    return { errors: l, errorSchema: c };
  const u = Z0(e, n, r, n, !0), f = o(u, wu(u), i), d = ub(f);
  return Zs({ errors: l, errorSchema: c }, d);
}
class $J {
  /** Constructs an `AJV8Validator` instance using the `options`
   *
   * @param options - The `CustomValidatorOptionsType` options that are used to create the AJV instance
   * @param [localizer] - If provided, is used to localize a list of Ajv `ErrorObject`s
   */
  constructor(t, r) {
    const { additionalMetaSchemas: n, customFormats: o, ajvOptionsOverrides: a, ajvFormatOptions: i, AjvClass: s } = t;
    this.ajv = yJ(n, o, a, i, s), this.localizer = r;
  }
  /** Resets the internal AJV validator to clear schemas from it. Can be helpful for resetting the validator for tests.
   */
  reset() {
    this.ajv.removeSchema();
  }
  /** Converts an `errorSchema` into a list of `RJSFValidationErrors`
   *
   * @param errorSchema - The `ErrorSchema` instance to convert
   * @param [fieldPath=[]] - The current field path, defaults to [] if not specified
   * @deprecated - Use the `toErrorList()` function provided by `@rjsf/utils` instead. This function will be removed in
   *        the next major release.
   */
  toErrorList(t, r = []) {
    return Di(t, r);
  }
  /** Runs the pure validation of the `schema` and `formData` without any of the RJSF functionality. Provided for use
   * by the playground. Returns the `errors` from the validation
   *
   * @param schema - The schema against which to validate the form data   * @param schema
   * @param formData - The form data to validate
   */
  rawValidation(t, r) {
    var n, o;
    let a, i;
    t[Zn] && (i = this.ajv.getSchema(t[Zn]));
    try {
      i === void 0 && (i = this.ajv.compile(t)), i(r);
    } catch (l) {
      a = l;
    }
    let s;
    return i && (typeof this.localizer == "function" && (((n = i.errors) !== null && n !== void 0 ? n : []).forEach((l) => {
      var c;
      !((c = l.params) === null || c === void 0) && c.missingProperty && (l.params.missingProperty = `'${l.params.missingProperty}'`);
    }), this.localizer(i.errors), ((o = i.errors) !== null && o !== void 0 ? o : []).forEach((l) => {
      var c;
      !((c = l.params) === null || c === void 0) && c.missingProperty && (l.params.missingProperty = l.params.missingProperty.slice(1, -1));
    })), s = i.errors || void 0, i.errors = null), {
      errors: s,
      validationError: a
    };
  }
  /** This function processes the `formData` with an optional user contributed `customValidate` function, which receives
   * the form data and a `errorHandler` function that will be used to add custom validation errors for each field. Also
   * supports a `transformErrors` function that will take the raw AJV validation errors, prior to custom validation and
   * transform them in what ever way it chooses.
   *
   * @param formData - The form data to validate
   * @param schema - The schema against which to validate the form data
   * @param [customValidate] - An optional function that is used to perform custom validation
   * @param [transformErrors] - An optional function that is used to transform errors after AJV validation
   * @param [uiSchema] - An optional uiSchema that is passed to `transformErrors` and `customValidate`
   */
  validateFormData(t, r, n, o, a) {
    const i = this.rawValidation(r, t);
    return vJ(this, i, t, r, n, o, a);
  }
  /**
   * This function checks if a schema needs to be added and if the root schemas don't match it removes the old root schema from the ajv instance and adds the new one.
   * @param rootSchema - The root schema used to provide $ref resolutions
   */
  handleSchemaUpdate(t) {
    var r, n;
    const o = (r = t[Zn]) !== null && r !== void 0 ? r : dy;
    this.ajv.getSchema(o) === void 0 ? this.ajv.addSchema(t, o) : pr(t, (n = this.ajv.getSchema(o)) === null || n === void 0 ? void 0 : n.schema) || (this.ajv.removeSchema(o), this.ajv.addSchema(t, o));
  }
  /** Validates data against a schema, returning true if the data is valid, or
   * false otherwise. If the schema is invalid, then this function will return
   * false.
   *
   * @param schema - The schema against which to validate the form data
   * @param formData - The form data to validate
   * @param rootSchema - The root schema used to provide $ref resolutions
   */
  isValid(t, r, n) {
    var o;
    try {
      this.handleSchemaUpdate(n);
      const a = lf(t), i = (o = a[Zn]) !== null && o !== void 0 ? o : TF(a);
      let s;
      return s = this.ajv.getSchema(i), s === void 0 && (s = this.ajv.addSchema(a, i).getSchema(i) || this.ajv.compile(a)), s(r);
    } catch (a) {
      return console.warn("Error encountered compiling schema:", a), !1;
    }
  }
}
function SJ(e = {}, t) {
  return new $J(e, t);
}
const wJ = SJ(), {
  fields: { SchemaField: ey }
} = Ab(), CJ = (e) => {
  if (e.schema.uiSchema) {
    const t = {
      ...e.uiSchema ? e.uiSchema : {},
      ...e.schema.uiSchema
    };
    return /* @__PURE__ */ P(ey, { ...e, uiSchema: t });
  }
  return /* @__PURE__ */ P(ey, { ...e });
}, ty = (e) => console.log.bind(console, e);
function F1({
  schema: e,
  uiSchema: t,
  fields: r,
  widgets: n,
  onSubmit: o,
  onError: a,
  onChange: i
}) {
  return typeof t > "u" && (t = {}), e.uiSchema && (t = { ...t, ...e.uiSchema }), t.func_name = { "ui:widget": "hidden" }, Object.entries(e.properties).forEach(([s, l]) => {
    l.is_reporter && (t[s] = { "ui:widget": "hidden" });
  }), /* @__PURE__ */ P(Wt, { children: /* @__PURE__ */ P(
    Sq,
    {
      schema: e,
      uiSchema: t,
      validator: wJ,
      onSubmit: typeof o < "u" ? o : ty("submitted"),
      onError: typeof a < "u" ? a : ty("errors"),
      fields: { SchemaField: CJ, ...r || {} },
      widgets: n,
      onChange: i
    }
  ) });
}
var j1 = { exports: {} };
(function(e, t) {
  (function(r, n) {
    e.exports = n(pn);
  })(hi, (r) => (() => {
    var n = { 9735: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "apathy", author: "jannik siebert (https://github.com/janniks)", base00: "#031A16", base01: "#0B342D", base02: "#184E45", base03: "#2B685E", base04: "#5F9C92", base05: "#81B5AC", base06: "#A7CEC8", base07: "#D2E7E4", base08: "#3E9688", base09: "#3E7996", base0A: "#3E4C96", base0B: "#883E96", base0C: "#963E4C", base0D: "#96883E", base0E: "#4C963E", base0F: "#3E965B" }, s.exports = l.default;
    }, 294: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "ashes", author: "jannik siebert (https://github.com/janniks)", base00: "#1C2023", base01: "#393F45", base02: "#565E65", base03: "#747C84", base04: "#ADB3BA", base05: "#C7CCD1", base06: "#DFE2E5", base07: "#F3F4F5", base08: "#C7AE95", base09: "#C7C795", base0A: "#AEC795", base0B: "#95C7AE", base0C: "#95AEC7", base0D: "#AE95C7", base0E: "#C795AE", base0F: "#C79595" }, s.exports = l.default;
    }, 1733: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "atelier dune", author: "bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune)", base00: "#20201d", base01: "#292824", base02: "#6e6b5e", base03: "#7d7a68", base04: "#999580", base05: "#a6a28c", base06: "#e8e4cf", base07: "#fefbec", base08: "#d73737", base09: "#b65611", base0A: "#cfb017", base0B: "#60ac39", base0C: "#1fad83", base0D: "#6684e1", base0E: "#b854d4", base0F: "#d43552" }, s.exports = l.default;
    }, 8974: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "atelier forest", author: "bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest)", base00: "#1b1918", base01: "#2c2421", base02: "#68615e", base03: "#766e6b", base04: "#9c9491", base05: "#a8a19f", base06: "#e6e2e0", base07: "#f1efee", base08: "#f22c40", base09: "#df5320", base0A: "#d5911a", base0B: "#5ab738", base0C: "#00ad9c", base0D: "#407ee7", base0E: "#6666ea", base0F: "#c33ff3" }, s.exports = l.default;
    }, 6933: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "atelier heath", author: "bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath)", base00: "#1b181b", base01: "#292329", base02: "#695d69", base03: "#776977", base04: "#9e8f9e", base05: "#ab9bab", base06: "#d8cad8", base07: "#f7f3f7", base08: "#ca402b", base09: "#a65926", base0A: "#bb8a35", base0B: "#379a37", base0C: "#159393", base0D: "#516aec", base0E: "#7b59c0", base0F: "#cc33cc" }, s.exports = l.default;
    }, 523: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "atelier lakeside", author: "bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside/)", base00: "#161b1d", base01: "#1f292e", base02: "#516d7b", base03: "#5a7b8c", base04: "#7195a8", base05: "#7ea2b4", base06: "#c1e4f6", base07: "#ebf8ff", base08: "#d22d72", base09: "#935c25", base0A: "#8a8a0f", base0B: "#568c3b", base0C: "#2d8f6f", base0D: "#257fad", base0E: "#5d5db1", base0F: "#b72dd2" }, s.exports = l.default;
    }, 1223: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "atelier seaside", author: "bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside/)", base00: "#131513", base01: "#242924", base02: "#5e6e5e", base03: "#687d68", base04: "#809980", base05: "#8ca68c", base06: "#cfe8cf", base07: "#f0fff0", base08: "#e6193c", base09: "#87711d", base0A: "#c3c322", base0B: "#29a329", base0C: "#1999b3", base0D: "#3d62f5", base0E: "#ad2bee", base0F: "#e619c3" }, s.exports = l.default;
    }, 1233: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "bespin", author: "jan t. sott", base00: "#28211c", base01: "#36312e", base02: "#5e5d5c", base03: "#666666", base04: "#797977", base05: "#8a8986", base06: "#9d9b97", base07: "#baae9e", base08: "#cf6a4c", base09: "#cf7d34", base0A: "#f9ee98", base0B: "#54be0d", base0C: "#afc4db", base0D: "#5ea6ea", base0E: "#9b859d", base0F: "#937121" }, s.exports = l.default;
    }, 2847: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "brewer", author: "timothée poisot (http://github.com/tpoisot)", base00: "#0c0d0e", base01: "#2e2f30", base02: "#515253", base03: "#737475", base04: "#959697", base05: "#b7b8b9", base06: "#dadbdc", base07: "#fcfdfe", base08: "#e31a1c", base09: "#e6550d", base0A: "#dca060", base0B: "#31a354", base0C: "#80b1d3", base0D: "#3182bd", base0E: "#756bb1", base0F: "#b15928" }, s.exports = l.default;
    }, 8120: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "bright", author: "chris kempson (http://chriskempson.com)", base00: "#000000", base01: "#303030", base02: "#505050", base03: "#b0b0b0", base04: "#d0d0d0", base05: "#e0e0e0", base06: "#f5f5f5", base07: "#ffffff", base08: "#fb0120", base09: "#fc6d24", base0A: "#fda331", base0B: "#a1c659", base0C: "#76c7b7", base0D: "#6fb3d2", base0E: "#d381c3", base0F: "#be643c" }, s.exports = l.default;
    }, 6305: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "chalk", author: "chris kempson (http://chriskempson.com)", base00: "#151515", base01: "#202020", base02: "#303030", base03: "#505050", base04: "#b0b0b0", base05: "#d0d0d0", base06: "#e0e0e0", base07: "#f5f5f5", base08: "#fb9fb1", base09: "#eda987", base0A: "#ddb26f", base0B: "#acc267", base0C: "#12cfc0", base0D: "#6fc2ef", base0E: "#e1a3ee", base0F: "#deaf8f" }, s.exports = l.default;
    }, 525: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "codeschool", author: "brettof86", base00: "#232c31", base01: "#1c3657", base02: "#2a343a", base03: "#3f4944", base04: "#84898c", base05: "#9ea7a6", base06: "#a7cfa3", base07: "#b5d8f6", base08: "#2a5491", base09: "#43820d", base0A: "#a03b1e", base0B: "#237986", base0C: "#b02f30", base0D: "#484d79", base0E: "#c59820", base0F: "#c98344" }, s.exports = l.default;
    }, 4124: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "colors", author: "mrmrs (http://clrs.cc)", base00: "#111111", base01: "#333333", base02: "#555555", base03: "#777777", base04: "#999999", base05: "#bbbbbb", base06: "#dddddd", base07: "#ffffff", base08: "#ff4136", base09: "#ff851b", base0A: "#ffdc00", base0B: "#2ecc40", base0C: "#7fdbff", base0D: "#0074d9", base0E: "#b10dc9", base0F: "#85144b" }, s.exports = l.default;
    }, 7167: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "default", author: "chris kempson (http://chriskempson.com)", base00: "#181818", base01: "#282828", base02: "#383838", base03: "#585858", base04: "#b8b8b8", base05: "#d8d8d8", base06: "#e8e8e8", base07: "#f8f8f8", base08: "#ab4642", base09: "#dc9656", base0A: "#f7ca88", base0B: "#a1b56c", base0C: "#86c1b9", base0D: "#7cafc2", base0E: "#ba8baf", base0F: "#a16946" }, s.exports = l.default;
    }, 4582: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "eighties", author: "chris kempson (http://chriskempson.com)", base00: "#2d2d2d", base01: "#393939", base02: "#515151", base03: "#747369", base04: "#a09f93", base05: "#d3d0c8", base06: "#e8e6df", base07: "#f2f0ec", base08: "#f2777a", base09: "#f99157", base0A: "#ffcc66", base0B: "#99cc99", base0C: "#66cccc", base0D: "#6699cc", base0E: "#cc99cc", base0F: "#d27b53" }, s.exports = l.default;
    }, 7096: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "embers", author: "jannik siebert (https://github.com/janniks)", base00: "#16130F", base01: "#2C2620", base02: "#433B32", base03: "#5A5047", base04: "#8A8075", base05: "#A39A90", base06: "#BEB6AE", base07: "#DBD6D1", base08: "#826D57", base09: "#828257", base0A: "#6D8257", base0B: "#57826D", base0C: "#576D82", base0D: "#6D5782", base0E: "#82576D", base0F: "#825757" }, s.exports = l.default;
    }, 9887: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "flat", author: "chris kempson (http://chriskempson.com)", base00: "#2C3E50", base01: "#34495E", base02: "#7F8C8D", base03: "#95A5A6", base04: "#BDC3C7", base05: "#e0e0e0", base06: "#f5f5f5", base07: "#ECF0F1", base08: "#E74C3C", base09: "#E67E22", base0A: "#F1C40F", base0B: "#2ECC71", base0C: "#1ABC9C", base0D: "#3498DB", base0E: "#9B59B6", base0F: "#be643c" }, s.exports = l.default;
    }, 7199: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "google", author: "seth wright (http://sethawright.com)", base00: "#1d1f21", base01: "#282a2e", base02: "#373b41", base03: "#969896", base04: "#b4b7b4", base05: "#c5c8c6", base06: "#e0e0e0", base07: "#ffffff", base08: "#CC342B", base09: "#F96A38", base0A: "#FBA922", base0B: "#198844", base0C: "#3971ED", base0D: "#3971ED", base0E: "#A36AC7", base0F: "#3971ED" }, s.exports = l.default;
    }, 1985: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "grayscale", author: "alexandre gavioli (https://github.com/alexx2/)", base00: "#101010", base01: "#252525", base02: "#464646", base03: "#525252", base04: "#ababab", base05: "#b9b9b9", base06: "#e3e3e3", base07: "#f7f7f7", base08: "#7c7c7c", base09: "#999999", base0A: "#a0a0a0", base0B: "#8e8e8e", base0C: "#868686", base0D: "#686868", base0E: "#747474", base0F: "#5e5e5e" }, s.exports = l.default;
    }, 8093: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "green screen", author: "chris kempson (http://chriskempson.com)", base00: "#001100", base01: "#003300", base02: "#005500", base03: "#007700", base04: "#009900", base05: "#00bb00", base06: "#00dd00", base07: "#00ff00", base08: "#007700", base09: "#009900", base0A: "#007700", base0B: "#00bb00", base0C: "#005500", base0D: "#009900", base0E: "#00bb00", base0F: "#005500" }, s.exports = l.default;
    }, 1615: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "harmonic16", author: "jannik siebert (https://github.com/janniks)", base00: "#0b1c2c", base01: "#223b54", base02: "#405c79", base03: "#627e99", base04: "#aabcce", base05: "#cbd6e2", base06: "#e5ebf1", base07: "#f7f9fb", base08: "#bf8b56", base09: "#bfbf56", base0A: "#8bbf56", base0B: "#56bf8b", base0C: "#568bbf", base0D: "#8b56bf", base0E: "#bf568b", base0F: "#bf5656" }, s.exports = l.default;
    }, 9063: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "hopscotch", author: "jan t. sott", base00: "#322931", base01: "#433b42", base02: "#5c545b", base03: "#797379", base04: "#989498", base05: "#b9b5b8", base06: "#d5d3d5", base07: "#ffffff", base08: "#dd464c", base09: "#fd8b19", base0A: "#fdcc59", base0B: "#8fc13e", base0C: "#149b93", base0D: "#1290bf", base0E: "#c85e7c", base0F: "#b33508" }, s.exports = l.default;
    }, 9446: (s, l, c) => {
      function u(_e) {
        return _e && _e.__esModule ? _e.default : _e;
      }
      l.__esModule = !0;
      var f = c(1308);
      l.threezerotwofour = u(f);
      var d = c(9735);
      l.apathy = u(d);
      var p = c(294);
      l.ashes = u(p);
      var h = c(1733);
      l.atelierDune = u(h);
      var $ = c(8974);
      l.atelierForest = u($);
      var b = c(6933);
      l.atelierHeath = u(b);
      var g = c(523);
      l.atelierLakeside = u(g);
      var y = c(1223);
      l.atelierSeaside = u(y);
      var S = c(1233);
      l.bespin = u(S);
      var m = c(2847);
      l.brewer = u(m);
      var w = c(8120);
      l.bright = u(w);
      var v = c(6305);
      l.chalk = u(v);
      var E = c(525);
      l.codeschool = u(E);
      var I = c(4124);
      l.colors = u(I);
      var R = c(7167);
      l.default = u(R);
      var C = c(4582);
      l.eighties = u(C);
      var T = c(7096);
      l.embers = u(T);
      var F = c(9887);
      l.flat = u(F);
      var D = c(7199);
      l.google = u(D);
      var z = c(1985);
      l.grayscale = u(z);
      var L = c(8093);
      l.greenscreen = u(L);
      var X = c(1615);
      l.harmonic = u(X);
      var V = c(9063);
      l.hopscotch = u(V);
      var ie = c(9033);
      l.isotope = u(ie);
      var Y = c(4112);
      l.marrakesh = u(Y);
      var H = c(9600);
      l.mocha = u(H);
      var j = c(1240);
      l.monokai = u(j);
      var Q = c(9768);
      l.ocean = u(Q);
      var q = c(8293);
      l.paraiso = u(q);
      var O = c(3093);
      l.pop = u(O);
      var N = c(1951);
      l.railscasts = u(N);
      var W = c(6368);
      l.shapeshifter = u(W);
      var ne = c(2317);
      l.solarized = u(ne);
      var ee = c(1091);
      l.summerfruit = u(ee);
      var pe = c(6943);
      l.tomorrow = u(pe);
      var ce = c(5670);
      l.tube = u(ce);
      var ye = c(2536);
      l.twilight = u(ye);
    }, 9033: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "isotope", author: "jan t. sott", base00: "#000000", base01: "#404040", base02: "#606060", base03: "#808080", base04: "#c0c0c0", base05: "#d0d0d0", base06: "#e0e0e0", base07: "#ffffff", base08: "#ff0000", base09: "#ff9900", base0A: "#ff0099", base0B: "#33ff00", base0C: "#00ffff", base0D: "#0066ff", base0E: "#cc00ff", base0F: "#3300ff" }, s.exports = l.default;
    }, 4112: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "marrakesh", author: "alexandre gavioli (http://github.com/alexx2/)", base00: "#201602", base01: "#302e00", base02: "#5f5b17", base03: "#6c6823", base04: "#86813b", base05: "#948e48", base06: "#ccc37a", base07: "#faf0a5", base08: "#c35359", base09: "#b36144", base0A: "#a88339", base0B: "#18974e", base0C: "#75a738", base0D: "#477ca1", base0E: "#8868b3", base0F: "#b3588e" }, s.exports = l.default;
    }, 9600: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "mocha", author: "chris kempson (http://chriskempson.com)", base00: "#3B3228", base01: "#534636", base02: "#645240", base03: "#7e705a", base04: "#b8afad", base05: "#d0c8c6", base06: "#e9e1dd", base07: "#f5eeeb", base08: "#cb6077", base09: "#d28b71", base0A: "#f4bc87", base0B: "#beb55b", base0C: "#7bbda4", base0D: "#8ab3b5", base0E: "#a89bb9", base0F: "#bb9584" }, s.exports = l.default;
    }, 1240: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "monokai", author: "wimer hazenberg (http://www.monokai.nl)", base00: "#272822", base01: "#383830", base02: "#49483e", base03: "#75715e", base04: "#a59f85", base05: "#f8f8f2", base06: "#f5f4f1", base07: "#f9f8f5", base08: "#f92672", base09: "#fd971f", base0A: "#f4bf75", base0B: "#a6e22e", base0C: "#a1efe4", base0D: "#66d9ef", base0E: "#ae81ff", base0F: "#cc6633" }, s.exports = l.default;
    }, 9768: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "ocean", author: "chris kempson (http://chriskempson.com)", base00: "#2b303b", base01: "#343d46", base02: "#4f5b66", base03: "#65737e", base04: "#a7adba", base05: "#c0c5ce", base06: "#dfe1e8", base07: "#eff1f5", base08: "#bf616a", base09: "#d08770", base0A: "#ebcb8b", base0B: "#a3be8c", base0C: "#96b5b4", base0D: "#8fa1b3", base0E: "#b48ead", base0F: "#ab7967" }, s.exports = l.default;
    }, 8293: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "paraiso", author: "jan t. sott", base00: "#2f1e2e", base01: "#41323f", base02: "#4f424c", base03: "#776e71", base04: "#8d8687", base05: "#a39e9b", base06: "#b9b6b0", base07: "#e7e9db", base08: "#ef6155", base09: "#f99b15", base0A: "#fec418", base0B: "#48b685", base0C: "#5bc4bf", base0D: "#06b6ef", base0E: "#815ba4", base0F: "#e96ba8" }, s.exports = l.default;
    }, 3093: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "pop", author: "chris kempson (http://chriskempson.com)", base00: "#000000", base01: "#202020", base02: "#303030", base03: "#505050", base04: "#b0b0b0", base05: "#d0d0d0", base06: "#e0e0e0", base07: "#ffffff", base08: "#eb008a", base09: "#f29333", base0A: "#f8ca12", base0B: "#37b349", base0C: "#00aabb", base0D: "#0e5a94", base0E: "#b31e8d", base0F: "#7a2d00" }, s.exports = l.default;
    }, 1951: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "railscasts", author: "ryan bates (http://railscasts.com)", base00: "#2b2b2b", base01: "#272935", base02: "#3a4055", base03: "#5a647e", base04: "#d4cfc9", base05: "#e6e1dc", base06: "#f4f1ed", base07: "#f9f7f3", base08: "#da4939", base09: "#cc7833", base0A: "#ffc66d", base0B: "#a5c261", base0C: "#519f50", base0D: "#6d9cbe", base0E: "#b6b3eb", base0F: "#bc9458" }, s.exports = l.default;
    }, 6368: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "shapeshifter", author: "tyler benziger (http://tybenz.com)", base00: "#000000", base01: "#040404", base02: "#102015", base03: "#343434", base04: "#555555", base05: "#ababab", base06: "#e0e0e0", base07: "#f9f9f9", base08: "#e92f2f", base09: "#e09448", base0A: "#dddd13", base0B: "#0ed839", base0C: "#23edda", base0D: "#3b48e3", base0E: "#f996e2", base0F: "#69542d" }, s.exports = l.default;
    }, 2317: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "solarized", author: "ethan schoonover (http://ethanschoonover.com/solarized)", base00: "#002b36", base01: "#073642", base02: "#586e75", base03: "#657b83", base04: "#839496", base05: "#93a1a1", base06: "#eee8d5", base07: "#fdf6e3", base08: "#dc322f", base09: "#cb4b16", base0A: "#b58900", base0B: "#859900", base0C: "#2aa198", base0D: "#268bd2", base0E: "#6c71c4", base0F: "#d33682" }, s.exports = l.default;
    }, 1091: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "summerfruit", author: "christopher corley (http://cscorley.github.io/)", base00: "#151515", base01: "#202020", base02: "#303030", base03: "#505050", base04: "#B0B0B0", base05: "#D0D0D0", base06: "#E0E0E0", base07: "#FFFFFF", base08: "#FF0086", base09: "#FD8900", base0A: "#ABA800", base0B: "#00C918", base0C: "#1faaaa", base0D: "#3777E6", base0E: "#AD00A1", base0F: "#cc6633" }, s.exports = l.default;
    }, 1308: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "threezerotwofour", author: "jan t. sott (http://github.com/idleberg)", base00: "#090300", base01: "#3a3432", base02: "#4a4543", base03: "#5c5855", base04: "#807d7c", base05: "#a5a2a2", base06: "#d6d5d4", base07: "#f7f7f7", base08: "#db2d20", base09: "#e8bbd0", base0A: "#fded02", base0B: "#01a252", base0C: "#b5e4f4", base0D: "#01a0e4", base0E: "#a16a94", base0F: "#cdab53" }, s.exports = l.default;
    }, 6943: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "tomorrow", author: "chris kempson (http://chriskempson.com)", base00: "#1d1f21", base01: "#282a2e", base02: "#373b41", base03: "#969896", base04: "#b4b7b4", base05: "#c5c8c6", base06: "#e0e0e0", base07: "#ffffff", base08: "#cc6666", base09: "#de935f", base0A: "#f0c674", base0B: "#b5bd68", base0C: "#8abeb7", base0D: "#81a2be", base0E: "#b294bb", base0F: "#a3685a" }, s.exports = l.default;
    }, 5670: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "london tube", author: "jan t. sott", base00: "#231f20", base01: "#1c3f95", base02: "#5a5758", base03: "#737171", base04: "#959ca1", base05: "#d9d8d8", base06: "#e7e7e8", base07: "#ffffff", base08: "#ee2e24", base09: "#f386a1", base0A: "#ffd204", base0B: "#00853e", base0C: "#85cebc", base0D: "#009ddc", base0E: "#98005d", base0F: "#b06110" }, s.exports = l.default;
    }, 2536: (s, l) => {
      l.__esModule = !0, l.default = { scheme: "twilight", author: "david hart (http://hart-dev.com)", base00: "#1e1e1e", base01: "#323537", base02: "#464b50", base03: "#5f5a60", base04: "#838184", base05: "#a7a7a7", base06: "#c3c3c3", base07: "#ffffff", base08: "#cf6a4c", base09: "#cda869", base0A: "#f9ee98", base0B: "#8f9d6a", base0C: "#afc4db", base0D: "#7587a6", base0E: "#9b859d", base0F: "#9b703f" }, s.exports = l.default;
    }, 6481: (s, l, c) => {
      var u = c(4176), f = {};
      for (var d in u) u.hasOwnProperty(d) && (f[u[d]] = d);
      var p = s.exports = { rgb: { channels: 3, labels: "rgb" }, hsl: { channels: 3, labels: "hsl" }, hsv: { channels: 3, labels: "hsv" }, hwb: { channels: 3, labels: "hwb" }, cmyk: { channels: 4, labels: "cmyk" }, xyz: { channels: 3, labels: "xyz" }, lab: { channels: 3, labels: "lab" }, lch: { channels: 3, labels: "lch" }, hex: { channels: 1, labels: ["hex"] }, keyword: { channels: 1, labels: ["keyword"] }, ansi16: { channels: 1, labels: ["ansi16"] }, ansi256: { channels: 1, labels: ["ansi256"] }, hcg: { channels: 3, labels: ["h", "c", "g"] }, apple: { channels: 3, labels: ["r16", "g16", "b16"] }, gray: { channels: 1, labels: ["gray"] } };
      for (var h in p) if (p.hasOwnProperty(h)) {
        if (!("channels" in p[h])) throw new Error("missing channels property: " + h);
        if (!("labels" in p[h])) throw new Error("missing channel labels property: " + h);
        if (p[h].labels.length !== p[h].channels) throw new Error("channel and label counts mismatch: " + h);
        var $ = p[h].channels, b = p[h].labels;
        delete p[h].channels, delete p[h].labels, Object.defineProperty(p[h], "channels", { value: $ }), Object.defineProperty(p[h], "labels", { value: b });
      }
      p.rgb.hsl = function(g) {
        var y, S, m = g[0] / 255, w = g[1] / 255, v = g[2] / 255, E = Math.min(m, w, v), I = Math.max(m, w, v), R = I - E;
        return I === E ? y = 0 : m === I ? y = (w - v) / R : w === I ? y = 2 + (v - m) / R : v === I && (y = 4 + (m - w) / R), (y = Math.min(60 * y, 360)) < 0 && (y += 360), S = (E + I) / 2, [y, 100 * (I === E ? 0 : S <= 0.5 ? R / (I + E) : R / (2 - I - E)), 100 * S];
      }, p.rgb.hsv = function(g) {
        var y, S, m, w, v, E = g[0] / 255, I = g[1] / 255, R = g[2] / 255, C = Math.max(E, I, R), T = C - Math.min(E, I, R), F = function(D) {
          return (C - D) / 6 / T + 0.5;
        };
        return T === 0 ? w = v = 0 : (v = T / C, y = F(E), S = F(I), m = F(R), E === C ? w = m - S : I === C ? w = 0.3333333333333333 + y - m : R === C && (w = 0.6666666666666666 + S - y), w < 0 ? w += 1 : w > 1 && (w -= 1)), [360 * w, 100 * v, 100 * C];
      }, p.rgb.hwb = function(g) {
        var y = g[0], S = g[1], m = g[2];
        return [p.rgb.hsl(g)[0], 100 * (0.00392156862745098 * Math.min(y, Math.min(S, m))), 100 * (m = 1 - 0.00392156862745098 * Math.max(y, Math.max(S, m)))];
      }, p.rgb.cmyk = function(g) {
        var y, S = g[0] / 255, m = g[1] / 255, w = g[2] / 255;
        return [100 * ((1 - S - (y = Math.min(1 - S, 1 - m, 1 - w))) / (1 - y) || 0), 100 * ((1 - m - y) / (1 - y) || 0), 100 * ((1 - w - y) / (1 - y) || 0), 100 * y];
      }, p.rgb.keyword = function(g) {
        var y = f[g];
        if (y) return y;
        var S, m, w, v = 1 / 0;
        for (var E in u) if (u.hasOwnProperty(E)) {
          var I = u[E], R = (m = g, w = I, Math.pow(m[0] - w[0], 2) + Math.pow(m[1] - w[1], 2) + Math.pow(m[2] - w[2], 2));
          R < v && (v = R, S = E);
        }
        return S;
      }, p.keyword.rgb = function(g) {
        return u[g];
      }, p.rgb.xyz = function(g) {
        var y = g[0] / 255, S = g[1] / 255, m = g[2] / 255;
        return [100 * (0.4124 * (y = y > 0.04045 ? Math.pow((y + 0.055) / 1.055, 2.4) : y / 12.92) + 0.3576 * (S = S > 0.04045 ? Math.pow((S + 0.055) / 1.055, 2.4) : S / 12.92) + 0.1805 * (m = m > 0.04045 ? Math.pow((m + 0.055) / 1.055, 2.4) : m / 12.92)), 100 * (0.2126 * y + 0.7152 * S + 0.0722 * m), 100 * (0.0193 * y + 0.1192 * S + 0.9505 * m)];
      }, p.rgb.lab = function(g) {
        var y = p.rgb.xyz(g), S = y[0], m = y[1], w = y[2];
        return m /= 100, w /= 108.883, S = (S /= 95.047) > 8856e-6 ? Math.pow(S, 0.3333333333333333) : 7.787 * S + 0.13793103448275862, [116 * (m = m > 8856e-6 ? Math.pow(m, 0.3333333333333333) : 7.787 * m + 0.13793103448275862) - 16, 500 * (S - m), 200 * (m - (w = w > 8856e-6 ? Math.pow(w, 0.3333333333333333) : 7.787 * w + 0.13793103448275862))];
      }, p.hsl.rgb = function(g) {
        var y, S, m, w, v, E = g[0] / 360, I = g[1] / 100, R = g[2] / 100;
        if (I === 0) return [v = 255 * R, v, v];
        y = 2 * R - (S = R < 0.5 ? R * (1 + I) : R + I - R * I), w = [0, 0, 0];
        for (var C = 0; C < 3; C++) (m = E + 0.3333333333333333 * -(C - 1)) < 0 && m++, m > 1 && m--, v = 6 * m < 1 ? y + 6 * (S - y) * m : 2 * m < 1 ? S : 3 * m < 2 ? y + (S - y) * (0.6666666666666666 - m) * 6 : y, w[C] = 255 * v;
        return w;
      }, p.hsl.hsv = function(g) {
        var y = g[0], S = g[1] / 100, m = g[2] / 100, w = S, v = Math.max(m, 0.01);
        return S *= (m *= 2) <= 1 ? m : 2 - m, w *= v <= 1 ? v : 2 - v, [y, 100 * (m === 0 ? 2 * w / (v + w) : 2 * S / (m + S)), 100 * ((m + S) / 2)];
      }, p.hsv.rgb = function(g) {
        var y = g[0] / 60, S = g[1] / 100, m = g[2] / 100, w = Math.floor(y) % 6, v = y - Math.floor(y), E = 255 * m * (1 - S), I = 255 * m * (1 - S * v), R = 255 * m * (1 - S * (1 - v));
        switch (m *= 255, w) {
          case 0:
            return [m, R, E];
          case 1:
            return [I, m, E];
          case 2:
            return [E, m, R];
          case 3:
            return [E, I, m];
          case 4:
            return [R, E, m];
          case 5:
            return [m, E, I];
        }
      }, p.hsv.hsl = function(g) {
        var y, S, m, w = g[0], v = g[1] / 100, E = g[2] / 100, I = Math.max(E, 0.01);
        return m = (2 - v) * E, S = v * I, [w, 100 * (S = (S /= (y = (2 - v) * I) <= 1 ? y : 2 - y) || 0), 100 * (m /= 2)];
      }, p.hwb.rgb = function(g) {
        var y, S, m, w, v, E, I, R = g[0] / 360, C = g[1] / 100, T = g[2] / 100, F = C + T;
        switch (F > 1 && (C /= F, T /= F), m = 6 * R - (y = Math.floor(6 * R)), 1 & y && (m = 1 - m), w = C + m * ((S = 1 - T) - C), y) {
          default:
          case 6:
          case 0:
            v = S, E = w, I = C;
            break;
          case 1:
            v = w, E = S, I = C;
            break;
          case 2:
            v = C, E = S, I = w;
            break;
          case 3:
            v = C, E = w, I = S;
            break;
          case 4:
            v = w, E = C, I = S;
            break;
          case 5:
            v = S, E = C, I = w;
        }
        return [255 * v, 255 * E, 255 * I];
      }, p.cmyk.rgb = function(g) {
        var y = g[0] / 100, S = g[1] / 100, m = g[2] / 100, w = g[3] / 100;
        return [255 * (1 - Math.min(1, y * (1 - w) + w)), 255 * (1 - Math.min(1, S * (1 - w) + w)), 255 * (1 - Math.min(1, m * (1 - w) + w))];
      }, p.xyz.rgb = function(g) {
        var y, S, m, w = g[0] / 100, v = g[1] / 100, E = g[2] / 100;
        return S = -0.9689 * w + 1.8758 * v + 0.0415 * E, m = 0.0557 * w + -0.204 * v + 1.057 * E, y = (y = 3.2406 * w + -1.5372 * v + -0.4986 * E) > 31308e-7 ? 1.055 * Math.pow(y, 0.4166666666666667) - 0.055 : 12.92 * y, S = S > 31308e-7 ? 1.055 * Math.pow(S, 0.4166666666666667) - 0.055 : 12.92 * S, m = m > 31308e-7 ? 1.055 * Math.pow(m, 0.4166666666666667) - 0.055 : 12.92 * m, [255 * (y = Math.min(Math.max(0, y), 1)), 255 * (S = Math.min(Math.max(0, S), 1)), 255 * (m = Math.min(Math.max(0, m), 1))];
      }, p.xyz.lab = function(g) {
        var y = g[0], S = g[1], m = g[2];
        return S /= 100, m /= 108.883, y = (y /= 95.047) > 8856e-6 ? Math.pow(y, 0.3333333333333333) : 7.787 * y + 0.13793103448275862, [116 * (S = S > 8856e-6 ? Math.pow(S, 0.3333333333333333) : 7.787 * S + 0.13793103448275862) - 16, 500 * (y - S), 200 * (S - (m = m > 8856e-6 ? Math.pow(m, 0.3333333333333333) : 7.787 * m + 0.13793103448275862))];
      }, p.lab.xyz = function(g) {
        var y, S, m, w = g[0];
        y = g[1] / 500 + (S = (w + 16) / 116), m = S - g[2] / 200;
        var v = Math.pow(S, 3), E = Math.pow(y, 3), I = Math.pow(m, 3);
        return S = v > 8856e-6 ? v : (S - 0.13793103448275862) / 7.787, y = E > 8856e-6 ? E : (y - 0.13793103448275862) / 7.787, m = I > 8856e-6 ? I : (m - 0.13793103448275862) / 7.787, [y *= 95.047, S *= 100, m *= 108.883];
      }, p.lab.lch = function(g) {
        var y, S = g[0], m = g[1], w = g[2];
        return (y = 360 * Math.atan2(w, m) / 2 / Math.PI) < 0 && (y += 360), [S, Math.sqrt(m * m + w * w), y];
      }, p.lch.lab = function(g) {
        var y, S = g[0], m = g[1];
        return y = g[2] / 360 * 2 * Math.PI, [S, m * Math.cos(y), m * Math.sin(y)];
      }, p.rgb.ansi16 = function(g) {
        var y = g[0], S = g[1], m = g[2], w = 1 in arguments ? arguments[1] : p.rgb.hsv(g)[2];
        if ((w = Math.round(w / 50)) === 0) return 30;
        var v = 30 + (Math.round(m / 255) << 2 | Math.round(S / 255) << 1 | Math.round(y / 255));
        return w === 2 && (v += 60), v;
      }, p.hsv.ansi16 = function(g) {
        return p.rgb.ansi16(p.hsv.rgb(g), g[2]);
      }, p.rgb.ansi256 = function(g) {
        var y = g[0], S = g[1], m = g[2];
        return y === S && S === m ? y < 8 ? 16 : y > 248 ? 231 : Math.round((y - 8) / 247 * 24) + 232 : 16 + 36 * Math.round(y / 255 * 5) + 6 * Math.round(S / 255 * 5) + Math.round(m / 255 * 5);
      }, p.ansi16.rgb = function(g) {
        var y = g % 10;
        if (y === 0 || y === 7) return g > 50 && (y += 3.5), [y = y / 10.5 * 255, y, y];
        var S = 0.5 * (1 + ~~(g > 50));
        return [(1 & y) * S * 255, (y >> 1 & 1) * S * 255, (y >> 2 & 1) * S * 255];
      }, p.ansi256.rgb = function(g) {
        if (g >= 232) {
          var y = 10 * (g - 232) + 8;
          return [y, y, y];
        }
        var S;
        return g -= 16, [Math.floor(g / 36) / 5 * 255, Math.floor((S = g % 36) / 6) / 5 * 255, S % 6 / 5 * 255];
      }, p.rgb.hex = function(g) {
        var y = (((255 & Math.round(g[0])) << 16) + ((255 & Math.round(g[1])) << 8) + (255 & Math.round(g[2]))).toString(16).toUpperCase();
        return "000000".substring(y.length) + y;
      }, p.hex.rgb = function(g) {
        var y = g.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);
        if (!y) return [0, 0, 0];
        var S = y[0];
        y[0].length === 3 && (S = S.split("").map(function(w) {
          return w + w;
        }).join(""));
        var m = parseInt(S, 16);
        return [m >> 16 & 255, m >> 8 & 255, 255 & m];
      }, p.rgb.hcg = function(g) {
        var y, S = g[0] / 255, m = g[1] / 255, w = g[2] / 255, v = Math.max(Math.max(S, m), w), E = Math.min(Math.min(S, m), w), I = v - E;
        return y = I <= 0 ? 0 : v === S ? (m - w) / I % 6 : v === m ? 2 + (w - S) / I : 4 + (S - m) / I + 4, y /= 6, [360 * (y %= 1), 100 * I, 100 * (I < 1 ? E / (1 - I) : 0)];
      }, p.hsl.hcg = function(g) {
        var y = g[1] / 100, S = g[2] / 100, m = 1, w = 0;
        return (m = S < 0.5 ? 2 * y * S : 2 * y * (1 - S)) < 1 && (w = (S - 0.5 * m) / (1 - m)), [g[0], 100 * m, 100 * w];
      }, p.hsv.hcg = function(g) {
        var y = g[1] / 100, S = g[2] / 100, m = y * S, w = 0;
        return m < 1 && (w = (S - m) / (1 - m)), [g[0], 100 * m, 100 * w];
      }, p.hcg.rgb = function(g) {
        var y = g[0] / 360, S = g[1] / 100, m = g[2] / 100;
        if (S === 0) return [255 * m, 255 * m, 255 * m];
        var w, v = [0, 0, 0], E = y % 1 * 6, I = E % 1, R = 1 - I;
        switch (Math.floor(E)) {
          case 0:
            v[0] = 1, v[1] = I, v[2] = 0;
            break;
          case 1:
            v[0] = R, v[1] = 1, v[2] = 0;
            break;
          case 2:
            v[0] = 0, v[1] = 1, v[2] = I;
            break;
          case 3:
            v[0] = 0, v[1] = R, v[2] = 1;
            break;
          case 4:
            v[0] = I, v[1] = 0, v[2] = 1;
            break;
          default:
            v[0] = 1, v[1] = 0, v[2] = R;
        }
        return w = (1 - S) * m, [255 * (S * v[0] + w), 255 * (S * v[1] + w), 255 * (S * v[2] + w)];
      }, p.hcg.hsv = function(g) {
        var y = g[1] / 100, S = y + g[2] / 100 * (1 - y), m = 0;
        return S > 0 && (m = y / S), [g[0], 100 * m, 100 * S];
      }, p.hcg.hsl = function(g) {
        var y = g[1] / 100, S = g[2] / 100 * (1 - y) + 0.5 * y, m = 0;
        return S > 0 && S < 0.5 ? m = y / (2 * S) : S >= 0.5 && S < 1 && (m = y / (2 * (1 - S))), [g[0], 100 * m, 100 * S];
      }, p.hcg.hwb = function(g) {
        var y = g[1] / 100, S = y + g[2] / 100 * (1 - y);
        return [g[0], 100 * (S - y), 100 * (1 - S)];
      }, p.hwb.hcg = function(g) {
        var y = g[1] / 100, S = 1 - g[2] / 100, m = S - y, w = 0;
        return m < 1 && (w = (S - m) / (1 - m)), [g[0], 100 * m, 100 * w];
      }, p.apple.rgb = function(g) {
        return [g[0] / 65535 * 255, g[1] / 65535 * 255, g[2] / 65535 * 255];
      }, p.rgb.apple = function(g) {
        return [g[0] / 255 * 65535, g[1] / 255 * 65535, g[2] / 255 * 65535];
      }, p.gray.rgb = function(g) {
        return [g[0] / 100 * 255, g[0] / 100 * 255, g[0] / 100 * 255];
      }, p.gray.hsl = p.gray.hsv = function(g) {
        return [0, 0, g[0]];
      }, p.gray.hwb = function(g) {
        return [0, 100, g[0]];
      }, p.gray.cmyk = function(g) {
        return [0, 0, 0, g[0]];
      }, p.gray.lab = function(g) {
        return [g[0], 0, 0];
      }, p.gray.hex = function(g) {
        var y = 255 & Math.round(g[0] / 100 * 255), S = ((y << 16) + (y << 8) + y).toString(16).toUpperCase();
        return "000000".substring(S.length) + S;
      }, p.rgb.gray = function(g) {
        return [(g[0] + g[1] + g[2]) / 3 / 255 * 100];
      };
    }, 4732: (s, l, c) => {
      var u = c(6481), f = c(1157), d = {};
      Object.keys(u).forEach(function(p) {
        d[p] = {}, Object.defineProperty(d[p], "channels", { value: u[p].channels }), Object.defineProperty(d[p], "labels", { value: u[p].labels });
        var h = f(p);
        Object.keys(h).forEach(function($) {
          var b = h[$];
          d[p][$] = function(g) {
            var y = function(S) {
              if (S == null) return S;
              arguments.length > 1 && (S = Array.prototype.slice.call(arguments));
              var m = g(S);
              if (typeof m == "object") for (var w = m.length, v = 0; v < w; v++) m[v] = Math.round(m[v]);
              return m;
            };
            return "conversion" in g && (y.conversion = g.conversion), y;
          }(b), d[p][$].raw = function(g) {
            var y = function(S) {
              return S == null ? S : (arguments.length > 1 && (S = Array.prototype.slice.call(arguments)), g(S));
            };
            return "conversion" in g && (y.conversion = g.conversion), y;
          }(b);
        });
      }), s.exports = d;
    }, 1157: (s, l, c) => {
      var u = c(6481);
      function f(h) {
        var $ = function() {
          for (var E = {}, I = Object.keys(u), R = I.length, C = 0; C < R; C++) E[I[C]] = { distance: -1, parent: null };
          return E;
        }(), b = [h];
        for ($[h].distance = 0; b.length; ) for (var g = b.pop(), y = Object.keys(u[g]), S = y.length, m = 0; m < S; m++) {
          var w = y[m], v = $[w];
          v.distance === -1 && (v.distance = $[g].distance + 1, v.parent = g, b.unshift(w));
        }
        return $;
      }
      function d(h, $) {
        return function(b) {
          return $(h(b));
        };
      }
      function p(h, $) {
        for (var b = [$[h].parent, h], g = u[$[h].parent][h], y = $[h].parent; $[y].parent; ) b.unshift($[y].parent), g = d(u[$[y].parent][y], g), y = $[y].parent;
        return g.conversion = b, g;
      }
      s.exports = function(h) {
        for (var $ = f(h), b = {}, g = Object.keys($), y = g.length, S = 0; S < y; S++) {
          var m = g[S];
          $[m].parent !== null && (b[m] = p(m, $));
        }
        return b;
      };
    }, 4176: (s) => {
      s.exports = { aliceblue: [240, 248, 255], antiquewhite: [250, 235, 215], aqua: [0, 255, 255], aquamarine: [127, 255, 212], azure: [240, 255, 255], beige: [245, 245, 220], bisque: [255, 228, 196], black: [0, 0, 0], blanchedalmond: [255, 235, 205], blue: [0, 0, 255], blueviolet: [138, 43, 226], brown: [165, 42, 42], burlywood: [222, 184, 135], cadetblue: [95, 158, 160], chartreuse: [127, 255, 0], chocolate: [210, 105, 30], coral: [255, 127, 80], cornflowerblue: [100, 149, 237], cornsilk: [255, 248, 220], crimson: [220, 20, 60], cyan: [0, 255, 255], darkblue: [0, 0, 139], darkcyan: [0, 139, 139], darkgoldenrod: [184, 134, 11], darkgray: [169, 169, 169], darkgreen: [0, 100, 0], darkgrey: [169, 169, 169], darkkhaki: [189, 183, 107], darkmagenta: [139, 0, 139], darkolivegreen: [85, 107, 47], darkorange: [255, 140, 0], darkorchid: [153, 50, 204], darkred: [139, 0, 0], darksalmon: [233, 150, 122], darkseagreen: [143, 188, 143], darkslateblue: [72, 61, 139], darkslategray: [47, 79, 79], darkslategrey: [47, 79, 79], darkturquoise: [0, 206, 209], darkviolet: [148, 0, 211], deeppink: [255, 20, 147], deepskyblue: [0, 191, 255], dimgray: [105, 105, 105], dimgrey: [105, 105, 105], dodgerblue: [30, 144, 255], firebrick: [178, 34, 34], floralwhite: [255, 250, 240], forestgreen: [34, 139, 34], fuchsia: [255, 0, 255], gainsboro: [220, 220, 220], ghostwhite: [248, 248, 255], gold: [255, 215, 0], goldenrod: [218, 165, 32], gray: [128, 128, 128], green: [0, 128, 0], greenyellow: [173, 255, 47], grey: [128, 128, 128], honeydew: [240, 255, 240], hotpink: [255, 105, 180], indianred: [205, 92, 92], indigo: [75, 0, 130], ivory: [255, 255, 240], khaki: [240, 230, 140], lavender: [230, 230, 250], lavenderblush: [255, 240, 245], lawngreen: [124, 252, 0], lemonchiffon: [255, 250, 205], lightblue: [173, 216, 230], lightcoral: [240, 128, 128], lightcyan: [224, 255, 255], lightgoldenrodyellow: [250, 250, 210], lightgray: [211, 211, 211], lightgreen: [144, 238, 144], lightgrey: [211, 211, 211], lightpink: [255, 182, 193], lightsalmon: [255, 160, 122], lightseagreen: [32, 178, 170], lightskyblue: [135, 206, 250], lightslategray: [119, 136, 153], lightslategrey: [119, 136, 153], lightsteelblue: [176, 196, 222], lightyellow: [255, 255, 224], lime: [0, 255, 0], limegreen: [50, 205, 50], linen: [250, 240, 230], magenta: [255, 0, 255], maroon: [128, 0, 0], mediumaquamarine: [102, 205, 170], mediumblue: [0, 0, 205], mediumorchid: [186, 85, 211], mediumpurple: [147, 112, 219], mediumseagreen: [60, 179, 113], mediumslateblue: [123, 104, 238], mediumspringgreen: [0, 250, 154], mediumturquoise: [72, 209, 204], mediumvioletred: [199, 21, 133], midnightblue: [25, 25, 112], mintcream: [245, 255, 250], mistyrose: [255, 228, 225], moccasin: [255, 228, 181], navajowhite: [255, 222, 173], navy: [0, 0, 128], oldlace: [253, 245, 230], olive: [128, 128, 0], olivedrab: [107, 142, 35], orange: [255, 165, 0], orangered: [255, 69, 0], orchid: [218, 112, 214], palegoldenrod: [238, 232, 170], palegreen: [152, 251, 152], paleturquoise: [175, 238, 238], palevioletred: [219, 112, 147], papayawhip: [255, 239, 213], peachpuff: [255, 218, 185], peru: [205, 133, 63], pink: [255, 192, 203], plum: [221, 160, 221], powderblue: [176, 224, 230], purple: [128, 0, 128], rebeccapurple: [102, 51, 153], red: [255, 0, 0], rosybrown: [188, 143, 143], royalblue: [65, 105, 225], saddlebrown: [139, 69, 19], salmon: [250, 128, 114], sandybrown: [244, 164, 96], seagreen: [46, 139, 87], seashell: [255, 245, 238], sienna: [160, 82, 45], silver: [192, 192, 192], skyblue: [135, 206, 235], slateblue: [106, 90, 205], slategray: [112, 128, 144], slategrey: [112, 128, 144], snow: [255, 250, 250], springgreen: [0, 255, 127], steelblue: [70, 130, 180], tan: [210, 180, 140], teal: [0, 128, 128], thistle: [216, 191, 216], tomato: [255, 99, 71], turquoise: [64, 224, 208], violet: [238, 130, 238], wheat: [245, 222, 179], white: [255, 255, 255], whitesmoke: [245, 245, 245], yellow: [255, 255, 0], yellowgreen: [154, 205, 50] };
    }, 4877: (s) => {
      s.exports = { aliceblue: [240, 248, 255], antiquewhite: [250, 235, 215], aqua: [0, 255, 255], aquamarine: [127, 255, 212], azure: [240, 255, 255], beige: [245, 245, 220], bisque: [255, 228, 196], black: [0, 0, 0], blanchedalmond: [255, 235, 205], blue: [0, 0, 255], blueviolet: [138, 43, 226], brown: [165, 42, 42], burlywood: [222, 184, 135], cadetblue: [95, 158, 160], chartreuse: [127, 255, 0], chocolate: [210, 105, 30], coral: [255, 127, 80], cornflowerblue: [100, 149, 237], cornsilk: [255, 248, 220], crimson: [220, 20, 60], cyan: [0, 255, 255], darkblue: [0, 0, 139], darkcyan: [0, 139, 139], darkgoldenrod: [184, 134, 11], darkgray: [169, 169, 169], darkgreen: [0, 100, 0], darkgrey: [169, 169, 169], darkkhaki: [189, 183, 107], darkmagenta: [139, 0, 139], darkolivegreen: [85, 107, 47], darkorange: [255, 140, 0], darkorchid: [153, 50, 204], darkred: [139, 0, 0], darksalmon: [233, 150, 122], darkseagreen: [143, 188, 143], darkslateblue: [72, 61, 139], darkslategray: [47, 79, 79], darkslategrey: [47, 79, 79], darkturquoise: [0, 206, 209], darkviolet: [148, 0, 211], deeppink: [255, 20, 147], deepskyblue: [0, 191, 255], dimgray: [105, 105, 105], dimgrey: [105, 105, 105], dodgerblue: [30, 144, 255], firebrick: [178, 34, 34], floralwhite: [255, 250, 240], forestgreen: [34, 139, 34], fuchsia: [255, 0, 255], gainsboro: [220, 220, 220], ghostwhite: [248, 248, 255], gold: [255, 215, 0], goldenrod: [218, 165, 32], gray: [128, 128, 128], green: [0, 128, 0], greenyellow: [173, 255, 47], grey: [128, 128, 128], honeydew: [240, 255, 240], hotpink: [255, 105, 180], indianred: [205, 92, 92], indigo: [75, 0, 130], ivory: [255, 255, 240], khaki: [240, 230, 140], lavender: [230, 230, 250], lavenderblush: [255, 240, 245], lawngreen: [124, 252, 0], lemonchiffon: [255, 250, 205], lightblue: [173, 216, 230], lightcoral: [240, 128, 128], lightcyan: [224, 255, 255], lightgoldenrodyellow: [250, 250, 210], lightgray: [211, 211, 211], lightgreen: [144, 238, 144], lightgrey: [211, 211, 211], lightpink: [255, 182, 193], lightsalmon: [255, 160, 122], lightseagreen: [32, 178, 170], lightskyblue: [135, 206, 250], lightslategray: [119, 136, 153], lightslategrey: [119, 136, 153], lightsteelblue: [176, 196, 222], lightyellow: [255, 255, 224], lime: [0, 255, 0], limegreen: [50, 205, 50], linen: [250, 240, 230], magenta: [255, 0, 255], maroon: [128, 0, 0], mediumaquamarine: [102, 205, 170], mediumblue: [0, 0, 205], mediumorchid: [186, 85, 211], mediumpurple: [147, 112, 219], mediumseagreen: [60, 179, 113], mediumslateblue: [123, 104, 238], mediumspringgreen: [0, 250, 154], mediumturquoise: [72, 209, 204], mediumvioletred: [199, 21, 133], midnightblue: [25, 25, 112], mintcream: [245, 255, 250], mistyrose: [255, 228, 225], moccasin: [255, 228, 181], navajowhite: [255, 222, 173], navy: [0, 0, 128], oldlace: [253, 245, 230], olive: [128, 128, 0], olivedrab: [107, 142, 35], orange: [255, 165, 0], orangered: [255, 69, 0], orchid: [218, 112, 214], palegoldenrod: [238, 232, 170], palegreen: [152, 251, 152], paleturquoise: [175, 238, 238], palevioletred: [219, 112, 147], papayawhip: [255, 239, 213], peachpuff: [255, 218, 185], peru: [205, 133, 63], pink: [255, 192, 203], plum: [221, 160, 221], powderblue: [176, 224, 230], purple: [128, 0, 128], rebeccapurple: [102, 51, 153], red: [255, 0, 0], rosybrown: [188, 143, 143], royalblue: [65, 105, 225], saddlebrown: [139, 69, 19], salmon: [250, 128, 114], sandybrown: [244, 164, 96], seagreen: [46, 139, 87], seashell: [255, 245, 238], sienna: [160, 82, 45], silver: [192, 192, 192], skyblue: [135, 206, 235], slateblue: [106, 90, 205], slategray: [112, 128, 144], slategrey: [112, 128, 144], snow: [255, 250, 250], springgreen: [0, 255, 127], steelblue: [70, 130, 180], tan: [210, 180, 140], teal: [0, 128, 128], thistle: [216, 191, 216], tomato: [255, 99, 71], turquoise: [64, 224, 208], violet: [238, 130, 238], wheat: [245, 222, 179], white: [255, 255, 255], whitesmoke: [245, 245, 245], yellow: [255, 255, 0], yellowgreen: [154, 205, 50] };
    }, 6138: (s, l, c) => {
      var u = c(4877), f = c(301), d = Object.hasOwnProperty, p = /* @__PURE__ */ Object.create(null);
      for (var h in u) d.call(u, h) && (p[u[h]] = h);
      var $ = s.exports = { to: {}, get: {} };
      function b(y, S, m) {
        return Math.min(Math.max(S, y), m);
      }
      function g(y) {
        var S = Math.round(y).toString(16).toUpperCase();
        return S.length < 2 ? "0" + S : S;
      }
      $.get = function(y) {
        var S, m;
        switch (y.substring(0, 3).toLowerCase()) {
          case "hsl":
            S = $.get.hsl(y), m = "hsl";
            break;
          case "hwb":
            S = $.get.hwb(y), m = "hwb";
            break;
          default:
            S = $.get.rgb(y), m = "rgb";
        }
        return S ? { model: m, value: S } : null;
      }, $.get.rgb = function(y) {
        if (!y) return null;
        var S, m, w, v = [0, 0, 0, 1];
        if (S = y.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)) {
          for (w = S[2], S = S[1], m = 0; m < 3; m++) {
            var E = 2 * m;
            v[m] = parseInt(S.slice(E, E + 2), 16);
          }
          w && (v[3] = parseInt(w, 16) / 255);
        } else if (S = y.match(/^#([a-f0-9]{3,4})$/i)) {
          for (w = (S = S[1])[3], m = 0; m < 3; m++) v[m] = parseInt(S[m] + S[m], 16);
          w && (v[3] = parseInt(w + w, 16) / 255);
        } else if (S = y.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)) {
          for (m = 0; m < 3; m++) v[m] = parseInt(S[m + 1], 0);
          S[4] && (S[5] ? v[3] = 0.01 * parseFloat(S[4]) : v[3] = parseFloat(S[4]));
        } else {
          if (!(S = y.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/))) return (S = y.match(/^(\w+)$/)) ? S[1] === "transparent" ? [0, 0, 0, 0] : d.call(u, S[1]) ? ((v = u[S[1]])[3] = 1, v) : null : null;
          for (m = 0; m < 3; m++) v[m] = Math.round(2.55 * parseFloat(S[m + 1]));
          S[4] && (S[5] ? v[3] = 0.01 * parseFloat(S[4]) : v[3] = parseFloat(S[4]));
        }
        for (m = 0; m < 3; m++) v[m] = b(v[m], 0, 255);
        return v[3] = b(v[3], 0, 1), v;
      }, $.get.hsl = function(y) {
        if (!y) return null;
        var S = y.match(/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);
        if (S) {
          var m = parseFloat(S[4]);
          return [(parseFloat(S[1]) % 360 + 360) % 360, b(parseFloat(S[2]), 0, 100), b(parseFloat(S[3]), 0, 100), b(isNaN(m) ? 1 : m, 0, 1)];
        }
        return null;
      }, $.get.hwb = function(y) {
        if (!y) return null;
        var S = y.match(/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);
        if (S) {
          var m = parseFloat(S[4]);
          return [(parseFloat(S[1]) % 360 + 360) % 360, b(parseFloat(S[2]), 0, 100), b(parseFloat(S[3]), 0, 100), b(isNaN(m) ? 1 : m, 0, 1)];
        }
        return null;
      }, $.to.hex = function() {
        var y = f(arguments);
        return "#" + g(y[0]) + g(y[1]) + g(y[2]) + (y[3] < 1 ? g(Math.round(255 * y[3])) : "");
      }, $.to.rgb = function() {
        var y = f(arguments);
        return y.length < 4 || y[3] === 1 ? "rgb(" + Math.round(y[0]) + ", " + Math.round(y[1]) + ", " + Math.round(y[2]) + ")" : "rgba(" + Math.round(y[0]) + ", " + Math.round(y[1]) + ", " + Math.round(y[2]) + ", " + y[3] + ")";
      }, $.to.rgb.percent = function() {
        var y = f(arguments), S = Math.round(y[0] / 255 * 100), m = Math.round(y[1] / 255 * 100), w = Math.round(y[2] / 255 * 100);
        return y.length < 4 || y[3] === 1 ? "rgb(" + S + "%, " + m + "%, " + w + "%)" : "rgba(" + S + "%, " + m + "%, " + w + "%, " + y[3] + ")";
      }, $.to.hsl = function() {
        var y = f(arguments);
        return y.length < 4 || y[3] === 1 ? "hsl(" + y[0] + ", " + y[1] + "%, " + y[2] + "%)" : "hsla(" + y[0] + ", " + y[1] + "%, " + y[2] + "%, " + y[3] + ")";
      }, $.to.hwb = function() {
        var y = f(arguments), S = "";
        return y.length >= 4 && y[3] !== 1 && (S = ", " + y[3]), "hwb(" + y[0] + ", " + y[1] + "%, " + y[2] + "%" + S + ")";
      }, $.to.keyword = function(y) {
        return p[y.slice(0, 3)];
      };
    }, 3639: (s, l, c) => {
      var u = c(6138), f = c(4732), d = [].slice, p = ["keyword", "gray", "hex"], h = {};
      Object.keys(f).forEach(function(m) {
        h[d.call(f[m].labels).sort().join("")] = m;
      });
      var $ = {};
      function b(m, w) {
        if (!(this instanceof b)) return new b(m, w);
        if (w && w in p && (w = null), w && !(w in f)) throw new Error("Unknown model: " + w);
        var v, E;
        if (m == null) this.model = "rgb", this.color = [0, 0, 0], this.valpha = 1;
        else if (m instanceof b) this.model = m.model, this.color = m.color.slice(), this.valpha = m.valpha;
        else if (typeof m == "string") {
          var I = u.get(m);
          if (I === null) throw new Error("Unable to parse color from string: " + m);
          this.model = I.model, E = f[this.model].channels, this.color = I.value.slice(0, E), this.valpha = typeof I.value[E] == "number" ? I.value[E] : 1;
        } else if (m.length) {
          this.model = w || "rgb", E = f[this.model].channels;
          var R = d.call(m, 0, E);
          this.color = S(R, E), this.valpha = typeof m[E] == "number" ? m[E] : 1;
        } else if (typeof m == "number") m &= 16777215, this.model = "rgb", this.color = [m >> 16 & 255, m >> 8 & 255, 255 & m], this.valpha = 1;
        else {
          this.valpha = 1;
          var C = Object.keys(m);
          "alpha" in m && (C.splice(C.indexOf("alpha"), 1), this.valpha = typeof m.alpha == "number" ? m.alpha : 0);
          var T = C.sort().join("");
          if (!(T in h)) throw new Error("Unable to parse color from object: " + JSON.stringify(m));
          this.model = h[T];
          var F = f[this.model].labels, D = [];
          for (v = 0; v < F.length; v++) D.push(m[F[v]]);
          this.color = S(D);
        }
        if ($[this.model]) for (E = f[this.model].channels, v = 0; v < E; v++) {
          var z = $[this.model][v];
          z && (this.color[v] = z(this.color[v]));
        }
        this.valpha = Math.max(0, Math.min(1, this.valpha)), Object.freeze && Object.freeze(this);
      }
      function g(m, w, v) {
        return (m = Array.isArray(m) ? m : [m]).forEach(function(E) {
          ($[E] || ($[E] = []))[w] = v;
        }), m = m[0], function(E) {
          var I;
          return arguments.length ? (v && (E = v(E)), (I = this[m]()).color[w] = E, I) : (I = this[m]().color[w], v && (I = v(I)), I);
        };
      }
      function y(m) {
        return function(w) {
          return Math.max(0, Math.min(m, w));
        };
      }
      function S(m, w) {
        for (var v = 0; v < w; v++) typeof m[v] != "number" && (m[v] = 0);
        return m;
      }
      b.prototype = { toString: function() {
        return this.string();
      }, toJSON: function() {
        return this[this.model]();
      }, string: function(m) {
        var w = this.model in u.to ? this : this.rgb(), v = (w = w.round(typeof m == "number" ? m : 1)).valpha === 1 ? w.color : w.color.concat(this.valpha);
        return u.to[w.model](v);
      }, percentString: function(m) {
        var w = this.rgb().round(typeof m == "number" ? m : 1), v = w.valpha === 1 ? w.color : w.color.concat(this.valpha);
        return u.to.rgb.percent(v);
      }, array: function() {
        return this.valpha === 1 ? this.color.slice() : this.color.concat(this.valpha);
      }, object: function() {
        for (var m = {}, w = f[this.model].channels, v = f[this.model].labels, E = 0; E < w; E++) m[v[E]] = this.color[E];
        return this.valpha !== 1 && (m.alpha = this.valpha), m;
      }, unitArray: function() {
        var m = this.rgb().color;
        return m[0] /= 255, m[1] /= 255, m[2] /= 255, this.valpha !== 1 && m.push(this.valpha), m;
      }, unitObject: function() {
        var m = this.rgb().object();
        return m.r /= 255, m.g /= 255, m.b /= 255, this.valpha !== 1 && (m.alpha = this.valpha), m;
      }, round: function(m) {
        return m = Math.max(m || 0, 0), new b(this.color.map(/* @__PURE__ */ function(w) {
          return function(v) {
            return function(E, I) {
              return Number(E.toFixed(I));
            }(v, w);
          };
        }(m)).concat(this.valpha), this.model);
      }, alpha: function(m) {
        return arguments.length ? new b(this.color.concat(Math.max(0, Math.min(1, m))), this.model) : this.valpha;
      }, red: g("rgb", 0, y(255)), green: g("rgb", 1, y(255)), blue: g("rgb", 2, y(255)), hue: g(["hsl", "hsv", "hsl", "hwb", "hcg"], 0, function(m) {
        return (m % 360 + 360) % 360;
      }), saturationl: g("hsl", 1, y(100)), lightness: g("hsl", 2, y(100)), saturationv: g("hsv", 1, y(100)), value: g("hsv", 2, y(100)), chroma: g("hcg", 1, y(100)), gray: g("hcg", 2, y(100)), white: g("hwb", 1, y(100)), wblack: g("hwb", 2, y(100)), cyan: g("cmyk", 0, y(100)), magenta: g("cmyk", 1, y(100)), yellow: g("cmyk", 2, y(100)), black: g("cmyk", 3, y(100)), x: g("xyz", 0, y(100)), y: g("xyz", 1, y(100)), z: g("xyz", 2, y(100)), l: g("lab", 0, y(100)), a: g("lab", 1), b: g("lab", 2), keyword: function(m) {
        return arguments.length ? new b(m) : f[this.model].keyword(this.color);
      }, hex: function(m) {
        return arguments.length ? new b(m) : u.to.hex(this.rgb().round().color);
      }, rgbNumber: function() {
        var m = this.rgb().color;
        return (255 & m[0]) << 16 | (255 & m[1]) << 8 | 255 & m[2];
      }, luminosity: function() {
        for (var m = this.rgb().color, w = [], v = 0; v < m.length; v++) {
          var E = m[v] / 255;
          w[v] = E <= 0.03928 ? E / 12.92 : Math.pow((E + 0.055) / 1.055, 2.4);
        }
        return 0.2126 * w[0] + 0.7152 * w[1] + 0.0722 * w[2];
      }, contrast: function(m) {
        var w = this.luminosity(), v = m.luminosity();
        return w > v ? (w + 0.05) / (v + 0.05) : (v + 0.05) / (w + 0.05);
      }, level: function(m) {
        var w = this.contrast(m);
        return w >= 7.1 ? "AAA" : w >= 4.5 ? "AA" : "";
      }, isDark: function() {
        var m = this.rgb().color;
        return (299 * m[0] + 587 * m[1] + 114 * m[2]) / 1e3 < 128;
      }, isLight: function() {
        return !this.isDark();
      }, negate: function() {
        for (var m = this.rgb(), w = 0; w < 3; w++) m.color[w] = 255 - m.color[w];
        return m;
      }, lighten: function(m) {
        var w = this.hsl();
        return w.color[2] += w.color[2] * m, w;
      }, darken: function(m) {
        var w = this.hsl();
        return w.color[2] -= w.color[2] * m, w;
      }, saturate: function(m) {
        var w = this.hsl();
        return w.color[1] += w.color[1] * m, w;
      }, desaturate: function(m) {
        var w = this.hsl();
        return w.color[1] -= w.color[1] * m, w;
      }, whiten: function(m) {
        var w = this.hwb();
        return w.color[1] += w.color[1] * m, w;
      }, blacken: function(m) {
        var w = this.hwb();
        return w.color[2] += w.color[2] * m, w;
      }, grayscale: function() {
        var m = this.rgb().color, w = 0.3 * m[0] + 0.59 * m[1] + 0.11 * m[2];
        return b.rgb(w, w, w);
      }, fade: function(m) {
        return this.alpha(this.valpha - this.valpha * m);
      }, opaquer: function(m) {
        return this.alpha(this.valpha + this.valpha * m);
      }, rotate: function(m) {
        var w = this.hsl(), v = w.color[0];
        return v = (v = (v + m) % 360) < 0 ? 360 + v : v, w.color[0] = v, w;
      }, mix: function(m, w) {
        if (!m || !m.rgb) throw new Error('Argument to "mix" was not a Color instance, but rather an instance of ' + typeof m);
        var v = m.rgb(), E = this.rgb(), I = w === void 0 ? 0.5 : w, R = 2 * I - 1, C = v.alpha() - E.alpha(), T = ((R * C == -1 ? R : (R + C) / (1 + R * C)) + 1) / 2, F = 1 - T;
        return b.rgb(T * v.red() + F * E.red(), T * v.green() + F * E.green(), T * v.blue() + F * E.blue(), v.alpha() * I + E.alpha() * (1 - I));
      } }, Object.keys(f).forEach(function(m) {
        if (p.indexOf(m) === -1) {
          var w = f[m].channels;
          b.prototype[m] = function() {
            if (this.model === m) return new b(this);
            if (arguments.length) return new b(arguments, m);
            var v, E = typeof arguments[w] == "number" ? w : this.valpha;
            return new b((v = f[this.model][m].raw(this.color), Array.isArray(v) ? v : [v]).concat(E), m);
          }, b[m] = function(v) {
            return typeof v == "number" && (v = S(d.call(arguments), w)), new b(v, m);
          };
        }
      }), s.exports = b;
    }, 9784: (s) => {
      var l, c = typeof Reflect == "object" ? Reflect : null, u = c && typeof c.apply == "function" ? c.apply : function(E, I, R) {
        return Function.prototype.apply.call(E, I, R);
      };
      l = c && typeof c.ownKeys == "function" ? c.ownKeys : Object.getOwnPropertySymbols ? function(E) {
        return Object.getOwnPropertyNames(E).concat(Object.getOwnPropertySymbols(E));
      } : function(E) {
        return Object.getOwnPropertyNames(E);
      };
      var f = Number.isNaN || function(E) {
        return E != E;
      };
      function d() {
        d.init.call(this);
      }
      s.exports = d, s.exports.once = function(E, I) {
        return new Promise(function(R, C) {
          function T(D) {
            E.removeListener(I, F), C(D);
          }
          function F() {
            typeof E.removeListener == "function" && E.removeListener("error", T), R([].slice.call(arguments));
          }
          v(E, I, F, { once: !0 }), I !== "error" && function(D, z, L) {
            typeof D.on == "function" && v(D, "error", z, L);
          }(E, T, { once: !0 });
        });
      }, d.EventEmitter = d, d.prototype._events = void 0, d.prototype._eventsCount = 0, d.prototype._maxListeners = void 0;
      var p = 10;
      function h(E) {
        if (typeof E != "function") throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof E);
      }
      function $(E) {
        return E._maxListeners === void 0 ? d.defaultMaxListeners : E._maxListeners;
      }
      function b(E, I, R, C) {
        var T, F, D, z;
        if (h(R), (F = E._events) === void 0 ? (F = E._events = /* @__PURE__ */ Object.create(null), E._eventsCount = 0) : (F.newListener !== void 0 && (E.emit("newListener", I, R.listener ? R.listener : R), F = E._events), D = F[I]), D === void 0) D = F[I] = R, ++E._eventsCount;
        else if (typeof D == "function" ? D = F[I] = C ? [R, D] : [D, R] : C ? D.unshift(R) : D.push(R), (T = $(E)) > 0 && D.length > T && !D.warned) {
          D.warned = !0;
          var L = new Error("Possible EventEmitter memory leak detected. " + D.length + " " + String(I) + " listeners added. Use emitter.setMaxListeners() to increase limit");
          L.name = "MaxListenersExceededWarning", L.emitter = E, L.type = I, L.count = D.length, z = L, console && console.warn && console.warn(z);
        }
        return E;
      }
      function g() {
        if (!this.fired) return this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments);
      }
      function y(E, I, R) {
        var C = { fired: !1, wrapFn: void 0, target: E, type: I, listener: R }, T = g.bind(C);
        return T.listener = R, C.wrapFn = T, T;
      }
      function S(E, I, R) {
        var C = E._events;
        if (C === void 0) return [];
        var T = C[I];
        return T === void 0 ? [] : typeof T == "function" ? R ? [T.listener || T] : [T] : R ? function(F) {
          for (var D = new Array(F.length), z = 0; z < D.length; ++z) D[z] = F[z].listener || F[z];
          return D;
        }(T) : w(T, T.length);
      }
      function m(E) {
        var I = this._events;
        if (I !== void 0) {
          var R = I[E];
          if (typeof R == "function") return 1;
          if (R !== void 0) return R.length;
        }
        return 0;
      }
      function w(E, I) {
        for (var R = new Array(I), C = 0; C < I; ++C) R[C] = E[C];
        return R;
      }
      function v(E, I, R, C) {
        if (typeof E.on == "function") C.once ? E.once(I, R) : E.on(I, R);
        else {
          if (typeof E.addEventListener != "function") throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof E);
          E.addEventListener(I, function T(F) {
            C.once && E.removeEventListener(I, T), R(F);
          });
        }
      }
      Object.defineProperty(d, "defaultMaxListeners", { enumerable: !0, get: function() {
        return p;
      }, set: function(E) {
        if (typeof E != "number" || E < 0 || f(E)) throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + E + ".");
        p = E;
      } }), d.init = function() {
        this._events !== void 0 && this._events !== Object.getPrototypeOf(this)._events || (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
      }, d.prototype.setMaxListeners = function(E) {
        if (typeof E != "number" || E < 0 || f(E)) throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + E + ".");
        return this._maxListeners = E, this;
      }, d.prototype.getMaxListeners = function() {
        return $(this);
      }, d.prototype.emit = function(E) {
        for (var I = [], R = 1; R < arguments.length; R++) I.push(arguments[R]);
        var C = E === "error", T = this._events;
        if (T !== void 0) C = C && T.error === void 0;
        else if (!C) return !1;
        if (C) {
          var F;
          if (I.length > 0 && (F = I[0]), F instanceof Error) throw F;
          var D = new Error("Unhandled error." + (F ? " (" + F.message + ")" : ""));
          throw D.context = F, D;
        }
        var z = T[E];
        if (z === void 0) return !1;
        if (typeof z == "function") u(z, this, I);
        else {
          var L = z.length, X = w(z, L);
          for (R = 0; R < L; ++R) u(X[R], this, I);
        }
        return !0;
      }, d.prototype.addListener = function(E, I) {
        return b(this, E, I, !1);
      }, d.prototype.on = d.prototype.addListener, d.prototype.prependListener = function(E, I) {
        return b(this, E, I, !0);
      }, d.prototype.once = function(E, I) {
        return h(I), this.on(E, y(this, E, I)), this;
      }, d.prototype.prependOnceListener = function(E, I) {
        return h(I), this.prependListener(E, y(this, E, I)), this;
      }, d.prototype.removeListener = function(E, I) {
        var R, C, T, F, D;
        if (h(I), (C = this._events) === void 0) return this;
        if ((R = C[E]) === void 0) return this;
        if (R === I || R.listener === I) --this._eventsCount == 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete C[E], C.removeListener && this.emit("removeListener", E, R.listener || I));
        else if (typeof R != "function") {
          for (T = -1, F = R.length - 1; F >= 0; F--) if (R[F] === I || R[F].listener === I) {
            D = R[F].listener, T = F;
            break;
          }
          if (T < 0) return this;
          T === 0 ? R.shift() : function(z, L) {
            for (; L + 1 < z.length; L++) z[L] = z[L + 1];
            z.pop();
          }(R, T), R.length === 1 && (C[E] = R[0]), C.removeListener !== void 0 && this.emit("removeListener", E, D || I);
        }
        return this;
      }, d.prototype.off = d.prototype.removeListener, d.prototype.removeAllListeners = function(E) {
        var I, R, C;
        if ((R = this._events) === void 0) return this;
        if (R.removeListener === void 0) return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : R[E] !== void 0 && (--this._eventsCount == 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete R[E]), this;
        if (arguments.length === 0) {
          var T, F = Object.keys(R);
          for (C = 0; C < F.length; ++C) (T = F[C]) !== "removeListener" && this.removeAllListeners(T);
          return this.removeAllListeners("removeListener"), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this;
        }
        if (typeof (I = R[E]) == "function") this.removeListener(E, I);
        else if (I !== void 0) for (C = I.length - 1; C >= 0; C--) this.removeListener(E, I[C]);
        return this;
      }, d.prototype.listeners = function(E) {
        return S(this, E, !0);
      }, d.prototype.rawListeners = function(E) {
        return S(this, E, !1);
      }, d.listenerCount = function(E, I) {
        return typeof E.listenerCount == "function" ? E.listenerCount(I) : m.call(E, I);
      }, d.prototype.listenerCount = m, d.prototype.eventNames = function() {
        return this._eventsCount > 0 ? l(this._events) : [];
      };
    }, 8336: (s) => {
      s.exports = function(l) {
        return !(!l || typeof l == "string") && (l instanceof Array || Array.isArray(l) || l.length >= 0 && (l.splice instanceof Function || Object.getOwnPropertyDescriptor(l, l.length - 1) && l.constructor.name !== "String"));
      };
    }, 3989: (s, l, c) => {
      var u = "__lodash_placeholder__", f = 32, d = 1 / 0, p = NaN, h = [["ary", 128], ["bind", 1], ["bindKey", 2], ["curry", 8], ["curryRight", 16], ["flip", 512], ["partial", f], ["partialRight", 64], ["rearg", 256]], $ = "[object Function]", b = "[object GeneratorFunction]", g = /^\s+|\s+$/g, y = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/, S = /\{\n\/\* \[wrapped with (.+)\] \*/, m = /,? & /, w = /^[-+]0x[0-9a-f]+$/i, v = /^0b[01]+$/i, E = /^\[object .+?Constructor\]$/, I = /^0o[0-7]+$/i, R = /^(?:0|[1-9]\d*)$/, C = parseInt, T = typeof c.g == "object" && c.g && c.g.Object === Object && c.g, F = typeof self == "object" && self && self.Object === Object && self, D = T || F || Function("return this")();
      function z(K, G, ae) {
        switch (ae.length) {
          case 0:
            return K.call(G);
          case 1:
            return K.call(G, ae[0]);
          case 2:
            return K.call(G, ae[0], ae[1]);
          case 3:
            return K.call(G, ae[0], ae[1], ae[2]);
        }
        return K.apply(G, ae);
      }
      function L(K, G) {
        return !!(K && K.length) && function(ae, he, Oe) {
          if (he != he) return function(Ne, et, It, Vt) {
            for (var ur = Ne.length, Ft = It + -1; ++Ft < ur; ) if (et(Ne[Ft], Ft, Ne)) return Ft;
            return -1;
          }(ae, X, Oe);
          for (var ut = Oe - 1, Se = ae.length; ++ut < Se; ) if (ae[ut] === he) return ut;
          return -1;
        }(K, G, 0) > -1;
      }
      function X(K) {
        return K != K;
      }
      function V(K, G) {
        for (var ae = -1, he = K.length, Oe = 0, ut = []; ++ae < he; ) {
          var Se = K[ae];
          Se !== G && Se !== u || (K[ae] = u, ut[Oe++] = ae);
        }
        return ut;
      }
      var ie, Y, H, j = Function.prototype, Q = Object.prototype, q = D["__core-js_shared__"], O = (ie = /[^.]+$/.exec(q && q.keys && q.keys.IE_PROTO || "")) ? "Symbol(src)_1." + ie : "", N = j.toString, W = Q.hasOwnProperty, ne = Q.toString, ee = RegExp("^" + N.call(W).replace(/[\\^$.*+?()[\]{}|]/g, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"), pe = Object.create, ce = Math.max, ye = Math.min, _e = (Y = se(Object, "defineProperty"), (H = se.name) && H.length > 2 ? Y : void 0);
      function Me(K) {
        if (!ve(K) || function(ae) {
          return !!O && O in ae;
        }(K)) return !1;
        var G = function(ae) {
          var he = ve(ae) ? ne.call(ae) : "";
          return he == $ || he == b;
        }(K) || function(ae) {
          var he = !1;
          if (ae != null && typeof ae.toString != "function") try {
            he = !!(ae + "");
          } catch {
          }
          return he;
        }(K) ? ee : E;
        return G.test(function(ae) {
          if (ae != null) {
            try {
              return N.call(ae);
            } catch {
            }
            try {
              return ae + "";
            } catch {
            }
          }
          return "";
        }(K));
      }
      function Re(K) {
        return function() {
          var G = arguments;
          switch (G.length) {
            case 0:
              return new K();
            case 1:
              return new K(G[0]);
            case 2:
              return new K(G[0], G[1]);
            case 3:
              return new K(G[0], G[1], G[2]);
            case 4:
              return new K(G[0], G[1], G[2], G[3]);
            case 5:
              return new K(G[0], G[1], G[2], G[3], G[4]);
            case 6:
              return new K(G[0], G[1], G[2], G[3], G[4], G[5]);
            case 7:
              return new K(G[0], G[1], G[2], G[3], G[4], G[5], G[6]);
          }
          var ae, he = ve(ae = K.prototype) ? pe(ae) : {}, Oe = K.apply(he, G);
          return ve(Oe) ? Oe : he;
        };
      }
      function Ve(K, G, ae, he, Oe, ut, Se, Ne, et, It) {
        var Vt = 128 & G, ur = 1 & G, Ft = 2 & G, it = 24 & G, at = 512 & G, kt = Ft ? void 0 : Re(K);
        return function Jt() {
          for (var yt = arguments.length, Ot = Array(yt), nr = yt; nr--; ) Ot[nr] = arguments[nr];
          if (it) var _r = qe(Jt), Cn = function(jt, yr) {
            for (var xr = jt.length, Nr = 0; xr--; ) jt[xr] === yr && Nr++;
            return Nr;
          }(Ot, _r);
          if (he && (Ot = function(jt, yr, xr, Nr) {
            for (var or = -1, tn = jt.length, rn = xr.length, br = -1, Fr = yr.length, nn = ce(tn - rn, 0), En = Array(Fr + nn), Wn = !Nr; ++br < Fr; ) En[br] = yr[br];
            for (; ++or < rn; ) (Wn || or < tn) && (En[xr[or]] = jt[or]);
            for (; nn--; ) En[br++] = jt[or++];
            return En;
          }(Ot, he, Oe, it)), ut && (Ot = function(jt, yr, xr, Nr) {
            for (var or = -1, tn = jt.length, rn = -1, br = xr.length, Fr = -1, nn = yr.length, En = ce(tn - br, 0), Wn = Array(En + nn), Mc = !Nr; ++or < En; ) Wn[or] = jt[or];
            for (var bs = or; ++Fr < nn; ) Wn[bs + Fr] = yr[Fr];
            for (; ++rn < br; ) (Mc || or < tn) && (Wn[bs + xr[rn]] = jt[or++]);
            return Wn;
          }(Ot, ut, Se, it)), yt -= Cn, it && yt < It) {
            var Hr = V(Ot, _r);
            return mt(K, G, Ve, Jt.placeholder, ae, Ot, Hr, Ne, et, It - yt);
          }
          var wt = ur ? ae : this, qn = Ft ? wt[K] : K;
          return yt = Ot.length, Ne ? Ot = function(jt, yr) {
            for (var xr = jt.length, Nr = ye(yr.length, xr), or = function(rn, br) {
              var Fr = -1, nn = rn.length;
              for (br || (br = Array(nn)); ++Fr < nn; ) br[Fr] = rn[Fr];
              return br;
            }(jt); Nr--; ) {
              var tn = yr[Nr];
              jt[Nr] = Ce(tn, xr) ? or[tn] : void 0;
            }
            return jt;
          }(Ot, Ne) : at && yt > 1 && Ot.reverse(), Vt && et < yt && (Ot.length = et), this && this !== D && this instanceof Jt && (qn = kt || Re(qn)), qn.apply(wt, Ot);
        };
      }
      function mt(K, G, ae, he, Oe, ut, Se, Ne, et, It) {
        var Vt = 8 & G;
        G |= Vt ? f : 64, 4 & (G &= ~(Vt ? 64 : f)) || (G &= -4);
        var ur = ae(K, G, Oe, Vt ? ut : void 0, Vt ? Se : void 0, Vt ? void 0 : ut, Vt ? void 0 : Se, Ne, et, It);
        return ur.placeholder = he, Nt(ur, K, G);
      }
      function Ue(K, G, ae, he, Oe, ut, Se, Ne) {
        var et = 2 & G;
        if (!et && typeof K != "function") throw new TypeError("Expected a function");
        var It = he ? he.length : 0;
        if (It || (G &= -97, he = Oe = void 0), Se = Se === void 0 ? Se : ce(Le(Se), 0), Ne = Ne === void 0 ? Ne : Le(Ne), It -= Oe ? Oe.length : 0, 64 & G) {
          var Vt = he, ur = Oe;
          he = Oe = void 0;
        }
        var Ft = [K, G, ae, he, Oe, Vt, ur, ut, Se, Ne];
        if (K = Ft[0], G = Ft[1], ae = Ft[2], he = Ft[3], Oe = Ft[4], !(Ne = Ft[9] = Ft[9] == null ? et ? 0 : K.length : ce(Ft[9] - It, 0)) && 24 & G && (G &= -25), G && G != 1) it = G == 8 || G == 16 ? function(at, kt, Jt) {
          var yt = Re(at);
          return function Ot() {
            for (var nr = arguments.length, _r = Array(nr), Cn = nr, Hr = qe(Ot); Cn--; ) _r[Cn] = arguments[Cn];
            var wt = nr < 3 && _r[0] !== Hr && _r[nr - 1] !== Hr ? [] : V(_r, Hr);
            return (nr -= wt.length) < Jt ? mt(at, kt, Ve, Ot.placeholder, void 0, _r, wt, void 0, void 0, Jt - nr) : z(this && this !== D && this instanceof Ot ? yt : at, this, _r);
          };
        }(K, G, Ne) : G != f && G != 33 || Oe.length ? Ve.apply(void 0, Ft) : function(at, kt, Jt, yt) {
          var Ot = 1 & kt, nr = Re(at);
          return function _r() {
            for (var Cn = -1, Hr = arguments.length, wt = -1, qn = yt.length, jt = Array(qn + Hr), yr = this && this !== D && this instanceof _r ? nr : at; ++wt < qn; ) jt[wt] = yt[wt];
            for (; Hr--; ) jt[wt++] = arguments[++Cn];
            return z(yr, Ot ? Jt : this, jt);
          };
        }(K, G, ae, he);
        else var it = function(at, kt, Jt) {
          var yt = 1 & kt, Ot = Re(at);
          return function nr() {
            return (this && this !== D && this instanceof nr ? Ot : at).apply(yt ? Jt : this, arguments);
          };
        }(K, G, ae);
        return Nt(it, K, G);
      }
      function qe(K) {
        return K.placeholder;
      }
      function se(K, G) {
        var ae = function(he, Oe) {
          return he == null ? void 0 : he[Oe];
        }(K, G);
        return Me(ae) ? ae : void 0;
      }
      function Ze(K) {
        var G = K.match(S);
        return G ? G[1].split(m) : [];
      }
      function rt(K, G) {
        var ae = G.length, he = ae - 1;
        return G[he] = (ae > 1 ? "& " : "") + G[he], G = G.join(ae > 2 ? ", " : " "), K.replace(y, `{
/* [wrapped with ` + G + `] */
`);
      }
      function Ce(K, G) {
        return !!(G = G ?? 9007199254740991) && (typeof K == "number" || R.test(K)) && K > -1 && K % 1 == 0 && K < G;
      }
      var Nt = _e ? function(K, G, ae) {
        var he, Oe = G + "";
        return _e(K, "toString", { configurable: !0, enumerable: !1, value: (he = rt(Oe, re(Ze(Oe), ae)), function() {
          return he;
        }) });
      } : function(K) {
        return K;
      };
      function re(K, G) {
        return function(ae, he) {
          for (var Oe = -1, ut = ae.length; ++Oe < ut && he(ae[Oe], Oe, ae) !== !1; ) ;
        }(h, function(ae) {
          var he = "_." + ae[0];
          G & ae[1] && !L(K, he) && K.push(he);
        }), K.sort();
      }
      function fe(K, G, ae) {
        var he = Ue(K, 8, void 0, void 0, void 0, void 0, void 0, G = ae ? void 0 : G);
        return he.placeholder = fe.placeholder, he;
      }
      function ve(K) {
        var G = typeof K;
        return !!K && (G == "object" || G == "function");
      }
      function Ie(K) {
        return K ? (K = function(G) {
          if (typeof G == "number") return G;
          if (function(Oe) {
            return typeof Oe == "symbol" || /* @__PURE__ */ function(ut) {
              return !!ut && typeof ut == "object";
            }(Oe) && ne.call(Oe) == "[object Symbol]";
          }(G)) return p;
          if (ve(G)) {
            var ae = typeof G.valueOf == "function" ? G.valueOf() : G;
            G = ve(ae) ? ae + "" : ae;
          }
          if (typeof G != "string") return G === 0 ? G : +G;
          G = G.replace(g, "");
          var he = v.test(G);
          return he || I.test(G) ? C(G.slice(2), he ? 2 : 8) : w.test(G) ? p : +G;
        }(K)) === d || K === -1 / 0 ? 17976931348623157e292 * (K < 0 ? -1 : 1) : K == K ? K : 0 : K === 0 ? K : 0;
      }
      function Le(K) {
        var G = Ie(K), ae = G % 1;
        return G == G ? ae ? G - ae : G : 0;
      }
      fe.placeholder = {}, s.exports = fe;
    }, 301: (s, l, c) => {
      var u = c(8336), f = Array.prototype.concat, d = Array.prototype.slice, p = s.exports = function(h) {
        for (var $ = [], b = 0, g = h.length; b < g; b++) {
          var y = h[b];
          u(y) ? $ = f.call($, d.call(y)) : $.push(y);
        }
        return $;
      };
      p.wrap = function(h) {
        return function() {
          return h(p(arguments));
        };
      };
    }, 4119: (s) => {
      s.exports = r;
    } }, o = {};
    function a(s) {
      var l = o[s];
      if (l !== void 0) return l.exports;
      var c = o[s] = { exports: {} };
      return n[s](c, c.exports, a), c.exports;
    }
    a.n = (s) => {
      var l = s && s.__esModule ? () => s.default : () => s;
      return a.d(l, { a: l }), l;
    }, a.d = (s, l) => {
      for (var c in l) a.o(l, c) && !a.o(s, c) && Object.defineProperty(s, c, { enumerable: !0, get: l[c] });
    }, a.g = function() {
      if (typeof globalThis == "object") return globalThis;
      try {
        return this || new Function("return this")();
      } catch {
        if (typeof window == "object") return window;
      }
    }(), a.o = (s, l) => Object.prototype.hasOwnProperty.call(s, l), a.r = (s) => {
      typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(s, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(s, "__esModule", { value: !0 });
    };
    var i = {};
    return (() => {
      function s(A) {
        return s = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(_) {
          return typeof _;
        } : function(_) {
          return _ && typeof Symbol == "function" && _.constructor === Symbol && _ !== Symbol.prototype ? "symbol" : typeof _;
        }, s(A);
      }
      function l(A) {
        var _ = function(x, k) {
          if (s(x) != "object" || !x) return x;
          var B = x[Symbol.toPrimitive];
          if (B !== void 0) {
            var Z = B.call(x, k || "default");
            if (s(Z) != "object") return Z;
            throw new TypeError("@@toPrimitive must return a primitive value.");
          }
          return (k === "string" ? String : Number)(x);
        }(A, "string");
        return s(_) == "symbol" ? _ : _ + "";
      }
      function c(A, _, x) {
        return (_ = l(_)) in A ? Object.defineProperty(A, _, { value: x, enumerable: !0, configurable: !0, writable: !0 }) : A[_] = x, A;
      }
      function u(A, _) {
        var x = Object.keys(A);
        if (Object.getOwnPropertySymbols) {
          var k = Object.getOwnPropertySymbols(A);
          _ && (k = k.filter(function(B) {
            return Object.getOwnPropertyDescriptor(A, B).enumerable;
          })), x.push.apply(x, k);
        }
        return x;
      }
      function f(A) {
        for (var _ = 1; _ < arguments.length; _++) {
          var x = arguments[_] != null ? arguments[_] : {};
          _ % 2 ? u(Object(x), !0).forEach(function(k) {
            c(A, k, x[k]);
          }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(A, Object.getOwnPropertyDescriptors(x)) : u(Object(x)).forEach(function(k) {
            Object.defineProperty(A, k, Object.getOwnPropertyDescriptor(x, k));
          });
        }
        return A;
      }
      function d(A, _) {
        if (!(A instanceof _)) throw new TypeError("Cannot call a class as a function");
      }
      function p(A, _) {
        for (var x = 0; x < _.length; x++) {
          var k = _[x];
          k.enumerable = k.enumerable || !1, k.configurable = !0, "value" in k && (k.writable = !0), Object.defineProperty(A, l(k.key), k);
        }
      }
      function h(A, _, x) {
        return _ && p(A.prototype, _), x && p(A, x), Object.defineProperty(A, "prototype", { writable: !1 }), A;
      }
      function $(A) {
        return $ = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(_) {
          return _.__proto__ || Object.getPrototypeOf(_);
        }, $(A);
      }
      function b() {
        try {
          var A = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
          }));
        } catch {
        }
        return (b = function() {
          return !!A;
        })();
      }
      function g(A, _) {
        if (_ && (s(_) == "object" || typeof _ == "function")) return _;
        if (_ !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
        return function(x) {
          if (x === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
          return x;
        }(A);
      }
      function y(A, _, x) {
        return _ = $(_), g(A, b() ? Reflect.construct(_, x || [], $(A).constructor) : _.apply(A, x));
      }
      function S(A, _) {
        return S = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(x, k) {
          return x.__proto__ = k, x;
        }, S(A, _);
      }
      function m(A, _) {
        if (typeof _ != "function" && _ !== null) throw new TypeError("Super expression must either be null or a function");
        A.prototype = Object.create(_ && _.prototype, { constructor: { value: A, writable: !0, configurable: !0 } }), Object.defineProperty(A, "prototype", { writable: !1 }), _ && S(A, _);
      }
      a.r(i), a.d(i, { default: () => s$ });
      var w = a(4119), v = a.n(w);
      function E() {
        var A = this.constructor.getDerivedStateFromProps(this.props, this.state);
        A != null && this.setState(A);
      }
      function I(A) {
        this.setState((function(_) {
          var x = this.constructor.getDerivedStateFromProps(A, _);
          return x ?? null;
        }).bind(this));
      }
      function R(A, _) {
        try {
          var x = this.props, k = this.state;
          this.props = A, this.state = _, this.__reactInternalSnapshotFlag = !0, this.__reactInternalSnapshot = this.getSnapshotBeforeUpdate(x, k);
        } finally {
          this.props = x, this.state = k;
        }
      }
      function C(A) {
        var _ = A.prototype;
        if (!_ || !_.isReactComponent) throw new Error("Can only polyfill class components");
        if (typeof A.getDerivedStateFromProps != "function" && typeof _.getSnapshotBeforeUpdate != "function") return A;
        var x = null, k = null, B = null;
        if (typeof _.componentWillMount == "function" ? x = "componentWillMount" : typeof _.UNSAFE_componentWillMount == "function" && (x = "UNSAFE_componentWillMount"), typeof _.componentWillReceiveProps == "function" ? k = "componentWillReceiveProps" : typeof _.UNSAFE_componentWillReceiveProps == "function" && (k = "UNSAFE_componentWillReceiveProps"), typeof _.componentWillUpdate == "function" ? B = "componentWillUpdate" : typeof _.UNSAFE_componentWillUpdate == "function" && (B = "UNSAFE_componentWillUpdate"), x !== null || k !== null || B !== null) {
          var Z = A.displayName || A.name, J = typeof A.getDerivedStateFromProps == "function" ? "getDerivedStateFromProps()" : "getSnapshotBeforeUpdate()";
          throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs.

` + Z + " uses " + J + " but also contains the following legacy lifecycles:" + (x !== null ? `
  ` + x : "") + (k !== null ? `
  ` + k : "") + (B !== null ? `
  ` + B : "") + `

The above lifecycles should be removed. Learn more about this warning here:
https://fb.me/react-async-component-lifecycle-hooks`);
        }
        if (typeof A.getDerivedStateFromProps == "function" && (_.componentWillMount = E, _.componentWillReceiveProps = I), typeof _.getSnapshotBeforeUpdate == "function") {
          if (typeof _.componentDidUpdate != "function") throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");
          _.componentWillUpdate = R;
          var U = _.componentDidUpdate;
          _.componentDidUpdate = function(oe, le, ge) {
            var be = this.__reactInternalSnapshotFlag ? this.__reactInternalSnapshot : ge;
            U.call(this, oe, le, be);
          };
        }
        return A;
      }
      function T(A, _) {
        if (A == null) return {};
        var x = {};
        for (var k in A) if ({}.hasOwnProperty.call(A, k)) {
          if (_.includes(k)) continue;
          x[k] = A[k];
        }
        return x;
      }
      function F(A, _) {
        if (A == null) return {};
        var x, k, B = T(A, _);
        if (Object.getOwnPropertySymbols) {
          var Z = Object.getOwnPropertySymbols(A);
          for (k = 0; k < Z.length; k++) x = Z[k], _.includes(x) || {}.propertyIsEnumerable.call(A, x) && (B[x] = A[x]);
        }
        return B;
      }
      function D(A, _) {
        var x;
        if (_ && (A == null || (x = A.constructor) === null || x === void 0 ? void 0 : x.name) === (_ == null ? void 0 : _.name)) return "bigNumber";
        var k = function(B) {
          return {}.toString.call(B).match(/\s([a-zA-Z]+)/)[1].toLowerCase();
        }(A);
        return k === "number" && (k = isNaN(A) ? "nan" : (0 | A) != A ? "float" : "integer"), k;
      }
      function z(A) {
        return A.replace(/\\/g, "\\\\").replace(/\n/g, "\\n").replace(/\t/g, "\\t").replace(/\r/g, "\\r").replace(/\f/g, "\\f");
      }
      E.__suppressDeprecationWarning = !0, I.__suppressDeprecationWarning = !0, R.__suppressDeprecationWarning = !0;
      var L = { scheme: "rjv-default", author: "mac gainor", base00: "rgba(0, 0, 0, 0)", base01: "rgb(245, 245, 245)", base02: "rgb(235, 235, 235)", base03: "#93a1a1", base04: "rgba(0, 0, 0, 0.3)", base05: "#586e75", base06: "#073642", base07: "#002b36", base08: "#d33682", base09: "#cb4b16", base0A: "#dc322f", base0B: "#859900", base0C: "#6c71c4", base0D: "#586e75", base0E: "#2aa198", base0F: "#268bd2" }, X = { scheme: "rjv-grey", author: "mac gainor", base00: "rgba(1, 1, 1, 0)", base01: "rgba(1, 1, 1, 0.1)", base02: "rgba(0, 0, 0, 0.2)", base03: "rgba(1, 1, 1, 0.3)", base04: "rgba(0, 0, 0, 0.4)", base05: "rgba(1, 1, 1, 0.5)", base06: "rgba(1, 1, 1, 0.6)", base07: "rgba(1, 1, 1, 0.7)", base08: "rgba(1, 1, 1, 0.8)", base09: "rgba(1, 1, 1, 0.8)", base0A: "rgba(1, 1, 1, 0.8)", base0B: "rgba(1, 1, 1, 0.8)", base0C: "rgba(1, 1, 1, 0.8)", base0D: "rgba(1, 1, 1, 0.8)", base0E: "rgba(1, 1, 1, 0.8)", base0F: "rgba(1, 1, 1, 0.8)" };
      const V = { white: "#fff", black: "#000", transparent: "rgba(1, 1, 1, 0)", globalFontFamily: "monospace", globalCursor: "default", indentBlockWidth: "5px", braceFontWeight: "bold", braceCursor: "pointer", ellipsisFontSize: "18px", ellipsisLineHeight: "10px", ellipsisCursor: "pointer", keyMargin: "0px 5px", keyLetterSpacing: "0.5px", keyFontStyle: "none", keyBorderRadius: "3px", keyColonWeight: "bold", keyVerticalAlign: "top", keyOpacity: "0.85", keyOpacityHover: "1", keyValPaddingTop: "3px", keyValPaddingBottom: "3px", keyValPaddingRight: "5px", keyValBorderLeft: "1px solid", keyValBorderHover: "2px solid", keyValPaddingHover: "3px 5px 3px 4px", pushedContentMarginLeft: "6px", variableValuePaddingRight: "6px", nullFontSize: "11px", nullFontWeight: "bold", nullPadding: "1px 2px", nullBorderRadius: "3px", nanFontSize: "11px", nanFontWeight: "bold", nanPadding: "1px 2px", nanBorderRadius: "3px", undefinedFontSize: "11px", undefinedFontWeight: "bold", undefinedPadding: "1px 2px", undefinedBorderRadius: "3px", dataTypeFontSize: "11px", dataTypeMarginRight: "4px", datatypeOpacity: "0.8", objectSizeBorderRadius: "3px", objectSizeFontStyle: "italic", objectSizeMargin: "0px 6px 0px 0px", clipboardCursor: "pointer", clipboardCheckMarginLeft: "-12px", metaDataPadding: "0px 0px 0px 10px", arrayGroupMetaPadding: "0px 0px 0px 4px", iconContainerWidth: "17px", tooltipPadding: "4px", editInputMinWidth: "130px", editInputBorderRadius: "2px", editInputPadding: "5px", editInputMarginRight: "4px", editInputFontFamily: "monospace", iconCursor: "pointer", iconFontSize: "15px", iconPaddingRight: "1px", dateValueMarginLeft: "2px", iconMarginRight: "3px", detectedRowPaddingTop: "3px", addKeyCoverBackground: "rgba(255, 255, 255, 0.3)", addKeyCoverPosition: "absolute", addKeyCoverPositionPx: "0px", addKeyModalWidth: "200px", addKeyModalMargin: "auto", addKeyModalPadding: "10px", addKeyModalRadius: "3px" };
      function ie(A, _) {
        (_ == null || _ > A.length) && (_ = A.length);
        for (var x = 0, k = Array(_); x < _; x++) k[x] = A[x];
        return k;
      }
      function Y(A, _) {
        if (A) {
          if (typeof A == "string") return ie(A, _);
          var x = {}.toString.call(A).slice(8, -1);
          return x === "Object" && A.constructor && (x = A.constructor.name), x === "Map" || x === "Set" ? Array.from(A) : x === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(x) ? ie(A, _) : void 0;
        }
      }
      function H(A, _) {
        return function(x) {
          if (Array.isArray(x)) return x;
        }(A) || function(x, k) {
          var B = x == null ? null : typeof Symbol < "u" && x[Symbol.iterator] || x["@@iterator"];
          if (B != null) {
            var Z, J, U, oe, le = [], ge = !0, be = !1;
            try {
              if (U = (B = B.call(x)).next, k === 0) {
                if (Object(B) !== B) return;
                ge = !1;
              } else for (; !(ge = (Z = U.call(B)).done) && (le.push(Z.value), le.length !== k); ge = !0) ;
            } catch (ke) {
              be = !0, J = ke;
            } finally {
              try {
                if (!ge && B.return != null && (oe = B.return(), Object(oe) !== oe)) return;
              } finally {
                if (be) throw J;
              }
            }
            return le;
          }
        }(A, _) || Y(A, _) || function() {
          throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
        }();
      }
      var j = a(9446), Q = a(3639), q = a.n(Q), O = a(3989), N = a.n(O);
      function W(A, _) {
        var x = Object.keys(A);
        if (Object.getOwnPropertySymbols) {
          var k = Object.getOwnPropertySymbols(A);
          _ && (k = k.filter(function(B) {
            return Object.getOwnPropertyDescriptor(A, B).enumerable;
          })), x.push.apply(x, k);
        }
        return x;
      }
      function ne(A) {
        for (var _ = 1; _ < arguments.length; _++) {
          var x = arguments[_] != null ? arguments[_] : {};
          _ % 2 ? W(Object(x), !0).forEach(function(k) {
            c(A, k, x[k]);
          }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(A, Object.getOwnPropertyDescriptors(x)) : W(Object(x)).forEach(function(k) {
            Object.defineProperty(A, k, Object.getOwnPropertyDescriptor(x, k));
          });
        }
        return A;
      }
      var ee = j.default, pe = Object.keys(ee), ce = function(A) {
        var _, x = function(oe) {
          var le = oe[0] / 255, ge = oe[1] / 255, be = oe[2] / 255;
          return [0.299 * le + 0.587 * ge + 0.114 * be, -0.14713 * le + -0.28886 * ge + 0.436 * be, 0.615 * le + -0.51499 * ge + -0.10001 * be];
        }(q()(A).array()), k = H(x, 3), B = k[0], Z = k[1], J = k[2], U = function(oe) {
          var le, ge, be, ke = oe[0], me = oe[1], He = oe[2];
          return le = 1 * ke + 0 * me + 1.13983 * He, ge = 1 * ke + -0.39465 * me + -0.5806 * He, be = 1 * ke + 2.02311 * me + 0 * He, [255 * (le = Math.min(Math.max(0, le), 1)), 255 * (ge = Math.min(Math.max(0, ge), 1)), 255 * (be = Math.min(Math.max(0, be), 1))];
        }([(_ = B, _ < 0.25 ? 1 : _ < 0.5 ? 0.9 - _ : 1.1 - _), Z, J]);
        return q().rgb(U).hex();
      }, ye = function(A) {
        return function(_) {
          return { className: [_.className, A.className].filter(Boolean).join(" "), style: ne(ne({}, _.style || {}), A.style || {}) };
        };
      }, _e = function(A, _) {
        var x = Object.keys(_);
        for (var k in A) x.indexOf(k) === -1 && x.push(k);
        return x.reduce(function(B, Z) {
          return B[Z] = function(J, U) {
            if (J === void 0) return U;
            if (U === void 0) return J;
            var oe = s(J), le = s(U);
            switch (oe) {
              case "string":
                switch (le) {
                  case "string":
                    return [U, J].filter(Boolean).join(" ");
                  case "object":
                    return ye({ className: J, style: U });
                  case "function":
                    return function(ge) {
                      for (var be = arguments.length, ke = new Array(be > 1 ? be - 1 : 0), me = 1; me < be; me++) ke[me - 1] = arguments[me];
                      return ye({ className: J })(U.apply(void 0, [ge].concat(ke)));
                    };
                }
                break;
              case "object":
                switch (le) {
                  case "string":
                    return ye({ className: U, style: J });
                  case "object":
                    return ne(ne({}, U), J);
                  case "function":
                    return function(ge) {
                      for (var be = arguments.length, ke = new Array(be > 1 ? be - 1 : 0), me = 1; me < be; me++) ke[me - 1] = arguments[me];
                      return ye({ style: J })(U.apply(void 0, [ge].concat(ke)));
                    };
                }
                break;
              case "function":
                switch (le) {
                  case "string":
                    return function(ge) {
                      for (var be = arguments.length, ke = new Array(be > 1 ? be - 1 : 0), me = 1; me < be; me++) ke[me - 1] = arguments[me];
                      return J.apply(void 0, [ye(ge)({ className: U })].concat(ke));
                    };
                  case "object":
                    return function(ge) {
                      for (var be = arguments.length, ke = new Array(be > 1 ? be - 1 : 0), me = 1; me < be; me++) ke[me - 1] = arguments[me];
                      return J.apply(void 0, [ye(ge)({ style: U })].concat(ke));
                    };
                  case "function":
                    return function(ge) {
                      for (var be = arguments.length, ke = new Array(be > 1 ? be - 1 : 0), me = 1; me < be; me++) ke[me - 1] = arguments[me];
                      return J.apply(void 0, [U.apply(void 0, [ge].concat(ke))].concat(ke));
                    };
                }
            }
          }(A[Z], _[Z]), B;
        }, {});
      }, Me = function(A, _) {
        for (var x = arguments.length, k = new Array(x > 2 ? x - 2 : 0), B = 2; B < x; B++) k[B - 2] = arguments[B];
        if (_ === null) return A;
        Array.isArray(_) || (_ = [_]);
        var Z = _.map(function(J) {
          return A[J];
        }).filter(Boolean).reduce(function(J, U) {
          return typeof U == "string" ? J.className = [J.className, U].filter(Boolean).join(" ") : s(U) === "object" ? J.style = ne(ne({}, J.style), U) : typeof U == "function" && (J = ne(ne({}, J), U.apply(void 0, [J].concat(k)))), J;
        }, { className: "", style: {} });
        return Z.className || delete Z.className, Object.keys(Z.style).length === 0 && delete Z.style, Z;
      }, Re = function(A) {
        return Object.keys(A).reduce(function(_, x) {
          return _[x] = /^base/.test(x) ? ce(A[x]) : x === "scheme" ? A[x] + ":inverted" : A[x], _;
        }, {});
      }, Ve = N()(function(A) {
        var _ = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, x = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, k = _.defaultBase16, B = k === void 0 ? ee : k, Z = _.base16Themes, J = Ue(x, Z === void 0 ? null : Z);
        J && (x = ne(ne({}, J), x));
        for (var U = pe.reduce(function(He, ht) {
          return He[ht] = x[ht] || B[ht], He;
        }, {}), oe = Object.keys(x).reduce(function(He, ht) {
          return pe.indexOf(ht) === -1 && (He[ht] = x[ht]), He;
        }, {}), le = A(U), ge = _e(oe, le), be = arguments.length, ke = new Array(be > 3 ? be - 3 : 0), me = 3; me < be; me++) ke[me - 3] = arguments[me];
        return N()(Me, 2).apply(void 0, [ge].concat(ke));
      }, 3), mt = function(A) {
        return !!A.extend;
      }, Ue = function(A, _) {
        if (A && mt(A) && A.extend && (A = A.extend), typeof A == "string") {
          var x = H(A.split(":"), 2), k = x[0], B = x[1];
          A = _ ? _[k] : j[k], B === "inverted" && (A = Re(A));
        }
        return A && Object.prototype.hasOwnProperty.call(A, "base00") ? A : void 0;
      }, qe = function(A) {
        var _ = function(x) {
          return { backgroundColor: x.base00, ellipsisColor: x.base09, braceColor: x.base07, expandedIcon: x.base0D, collapsedIcon: x.base0E, keyColor: x.base07, arrayKeyColor: x.base0C, objectSize: x.base04, copyToClipboard: x.base0F, copyToClipboardCheck: x.base0D, objectBorder: x.base02, dataTypes: { boolean: x.base0E, date: x.base0D, float: x.base0B, function: x.base0D, integer: x.base0F, string: x.base09, nan: x.base08, null: x.base0A, undefined: x.base05, regexp: x.base0A, background: x.base02, bigNumber: x.base09 }, editVariable: { editIcon: x.base0E, cancelIcon: x.base09, removeIcon: x.base09, addIcon: x.base0E, checkIcon: x.base0E, background: x.base01, color: x.base0A, border: x.base07 }, addKeyModal: { background: x.base05, border: x.base04, color: x.base0A, labelColor: x.base01 }, validationFailure: { background: x.base09, iconColor: x.base01, fontColor: x.base01 } };
        }(A);
        return { "app-container": { fontFamily: V.globalFontFamily, cursor: V.globalCursor, backgroundColor: _.backgroundColor, position: "relative" }, ellipsis: { display: "inline-block", color: _.ellipsisColor, fontSize: V.ellipsisFontSize, lineHeight: V.ellipsisLineHeight, cursor: V.ellipsisCursor }, "brace-row": { display: "inline-block", cursor: "pointer" }, brace: { display: "inline-block", cursor: V.braceCursor, fontWeight: V.braceFontWeight, color: _.braceColor }, "expanded-icon": { color: _.expandedIcon }, "collapsed-icon": { color: _.collapsedIcon }, colon: { display: "inline-block", margin: V.keyMargin, color: _.keyColor, verticalAlign: "top" }, objectKeyVal: function(x, k) {
          return { style: f({ paddingTop: V.keyValPaddingTop, paddingRight: V.keyValPaddingRight, paddingBottom: V.keyValPaddingBottom, borderLeft: V.keyValBorderLeft + " " + _.objectBorder, ":hover": { paddingLeft: k.paddingLeft - 1 + "px", borderLeft: V.keyValBorderHover + " " + _.objectBorder } }, k) };
        }, "object-key-val-no-border": { padding: V.keyValPadding }, "pushed-content": { marginLeft: V.pushedContentMarginLeft }, variableValue: function(x, k) {
          return { style: f({ display: "inline-block", paddingRight: V.variableValuePaddingRight, position: "relative" }, k) };
        }, "object-name": { display: "inline-block", color: _.keyColor, letterSpacing: V.keyLetterSpacing, fontStyle: V.keyFontStyle, verticalAlign: V.keyVerticalAlign, opacity: V.keyOpacity, ":hover": { opacity: V.keyOpacityHover } }, "array-key": { display: "inline-block", color: _.arrayKeyColor, letterSpacing: V.keyLetterSpacing, fontStyle: V.keyFontStyle, verticalAlign: V.keyVerticalAlign, opacity: V.keyOpacity, ":hover": { opacity: V.keyOpacityHover } }, "object-size": { color: _.objectSize, borderRadius: V.objectSizeBorderRadius, fontStyle: V.objectSizeFontStyle, margin: V.objectSizeMargin, cursor: "default" }, "data-type-label": { fontSize: V.dataTypeFontSize, marginRight: V.dataTypeMarginRight, opacity: V.datatypeOpacity }, boolean: { display: "inline-block", color: _.dataTypes.boolean }, date: { display: "inline-block", color: _.dataTypes.date }, "date-value": { marginLeft: V.dateValueMarginLeft }, float: { display: "inline-block", color: _.dataTypes.float }, function: { display: "inline-block", color: _.dataTypes.function, cursor: "pointer", whiteSpace: "pre-line" }, "function-value": { fontStyle: "italic" }, integer: { display: "inline-block", color: _.dataTypes.integer }, bigNumber: { display: "inline-block", color: _.dataTypes.bigNumber }, string: { display: "inline-block", color: _.dataTypes.string }, nan: { display: "inline-block", color: _.dataTypes.nan, fontSize: V.nanFontSize, fontWeight: V.nanFontWeight, backgroundColor: _.dataTypes.background, padding: V.nanPadding, borderRadius: V.nanBorderRadius }, null: { display: "inline-block", color: _.dataTypes.null, fontSize: V.nullFontSize, fontWeight: V.nullFontWeight, backgroundColor: _.dataTypes.background, padding: V.nullPadding, borderRadius: V.nullBorderRadius }, undefined: { display: "inline-block", color: _.dataTypes.undefined, fontSize: V.undefinedFontSize, padding: V.undefinedPadding, borderRadius: V.undefinedBorderRadius, backgroundColor: _.dataTypes.background }, regexp: { display: "inline-block", color: _.dataTypes.regexp }, "copy-to-clipboard": { cursor: V.clipboardCursor }, "copy-icon": { color: _.copyToClipboard, fontSize: V.iconFontSize, marginRight: V.iconMarginRight, verticalAlign: "top" }, "copy-icon-copied": { color: _.copyToClipboardCheck, marginLeft: V.clipboardCheckMarginLeft }, "array-group-meta-data": { display: "inline-block", padding: V.arrayGroupMetaPadding }, "object-meta-data": { display: "inline-block", padding: V.metaDataPadding }, "icon-container": { display: "inline-block", width: V.iconContainerWidth }, tooltip: { padding: V.tooltipPadding }, removeVarIcon: { verticalAlign: "top", display: "inline-block", color: _.editVariable.removeIcon, cursor: V.iconCursor, fontSize: V.iconFontSize, marginRight: V.iconMarginRight }, addVarIcon: { verticalAlign: "top", display: "inline-block", color: _.editVariable.addIcon, cursor: V.iconCursor, fontSize: V.iconFontSize, marginRight: V.iconMarginRight }, editVarIcon: { verticalAlign: "top", display: "inline-block", color: _.editVariable.editIcon, cursor: V.iconCursor, fontSize: V.iconFontSize, marginRight: V.iconMarginRight }, "edit-icon-container": { display: "inline-block", verticalAlign: "top" }, "check-icon": { display: "inline-block", cursor: V.iconCursor, color: _.editVariable.checkIcon, fontSize: V.iconFontSize, paddingRight: V.iconPaddingRight }, "cancel-icon": { display: "inline-block", cursor: V.iconCursor, color: _.editVariable.cancelIcon, fontSize: V.iconFontSize, paddingRight: V.iconPaddingRight }, "edit-input": { display: "inline-block", minWidth: V.editInputMinWidth, borderRadius: V.editInputBorderRadius, backgroundColor: _.editVariable.background, color: _.editVariable.color, padding: V.editInputPadding, marginRight: V.editInputMarginRight, fontFamily: V.editInputFontFamily }, "detected-row": { paddingTop: V.detectedRowPaddingTop }, "key-modal-request": { position: V.addKeyCoverPosition, top: V.addKeyCoverPositionPx, left: V.addKeyCoverPositionPx, right: V.addKeyCoverPositionPx, bottom: V.addKeyCoverPositionPx, backgroundColor: V.addKeyCoverBackground }, "key-modal": { width: V.addKeyModalWidth, backgroundColor: _.addKeyModal.background, marginLeft: V.addKeyModalMargin, marginRight: V.addKeyModalMargin, padding: V.addKeyModalPadding, borderRadius: V.addKeyModalRadius, marginTop: "15px", position: "relative" }, "key-modal-label": { color: _.addKeyModal.labelColor, marginLeft: "2px", marginBottom: "5px", fontSize: "11px" }, "key-modal-input-container": { overflow: "hidden" }, "key-modal-input": { width: "100%", padding: "3px 6px", fontFamily: "monospace", color: _.addKeyModal.color, border: "none", boxSizing: "border-box", borderRadius: "2px" }, "key-modal-cancel": { backgroundColor: _.editVariable.removeIcon, position: "absolute", top: "0px", right: "0px", borderRadius: "0px 3px 0px 3px", cursor: "pointer" }, "key-modal-cancel-icon": { color: _.addKeyModal.labelColor, fontSize: V.iconFontSize, transform: "rotate(45deg)" }, "key-modal-submit": { color: _.editVariable.addIcon, fontSize: V.iconFontSize, position: "absolute", right: "2px", top: "3px", cursor: "pointer" }, "function-ellipsis": { display: "inline-block", color: _.ellipsisColor, fontSize: V.ellipsisFontSize, lineHeight: V.ellipsisLineHeight, cursor: V.ellipsisCursor }, "validation-failure": { float: "right", padding: "3px 6px", borderRadius: "2px", cursor: "pointer", color: _.validationFailure.fontColor, backgroundColor: _.validationFailure.background }, "validation-failure-label": { marginRight: "6px" }, "validation-failure-clear": { position: "relative", verticalAlign: "top", cursor: "pointer", color: _.validationFailure.iconColor, fontSize: V.iconFontSize, transform: "rotate(45deg)" } };
      };
      function se(A, _, x) {
        return A || console.error("theme has not been set"), function(k) {
          var B = L;
          return k !== !1 && k !== "none" || (B = X), Ve(qe, { defaultBase16: B })(k);
        }(A)(_, x);
      }
      var Ze = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = (x.rjvId, x.type_name), B = x.displayDataTypes, Z = x.theme;
          return B ? v().createElement("span", Object.assign({ className: "data-type-label" }, se(Z, "data-type-label")), k) : null;
        } }]);
      }(v().PureComponent), rt = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "boolean"), v().createElement(Ze, Object.assign({ type_name: "bool" }, x)), x.value ? "true" : "false");
        } }]);
      }(v().PureComponent), Ce = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "date"), v().createElement(Ze, Object.assign({ type_name: "date" }, x)), v().createElement("span", Object.assign({ className: "date-value" }, se(x.theme, "date-value")), x.value.toLocaleTimeString("en-us", { weekday: "short", year: "numeric", month: "short", day: "numeric", hour: "2-digit", minute: "2-digit" })));
        } }]);
      }(v().PureComponent), Nt = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "float"), v().createElement(Ze, Object.assign({ type_name: "float" }, x)), this.props.value);
        } }]);
      }(v().PureComponent);
      function re(A) {
        return function(_) {
          if (Array.isArray(_)) return ie(_);
        }(A) || function(_) {
          if (typeof Symbol < "u" && _[Symbol.iterator] != null || _["@@iterator"] != null) return Array.from(_);
        }(A) || Y(A) || function() {
          throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
        }();
      }
      var fe = a(9784), ve = function() {
        return h(function A() {
          d(this, A), this.handler = function() {
          };
        }, [{ key: "register", value: function(A) {
          this.handler = A;
        } }, { key: "dispatch", value: function(A) {
          var _;
          (_ = this.handler) === null || _ === void 0 || _.call(this, A);
        } }]);
      }();
      globalThis.__globalDispatcherInstance || (globalThis.__globalDispatcherInstance = new ve());
      const Ie = globalThis.__globalDispatcherInstance;
      var Le = new (function(A) {
        function _() {
          var x;
          d(this, _);
          for (var k = arguments.length, B = new Array(k), Z = 0; Z < k; Z++) B[Z] = arguments[Z];
          return (x = y(this, _, [].concat(B))).objects = {}, x.set = function(J, U, oe, le) {
            x.objects[J] === void 0 && (x.objects[J] = {}), x.objects[J][U] === void 0 && (x.objects[J][U] = {}), x.objects[J][U][oe] = le;
          }, x.get = function(J, U, oe, le) {
            return x.objects[J] === void 0 || x.objects[J][U] === void 0 || x.objects[J][U][oe] == null ? le : x.objects[J][U][oe];
          }, x.handleAction = function(J) {
            var U = J.rjvId, oe = J.data;
            switch (J.name) {
              case "RESET":
                x.emit("reset-" + U);
                break;
              case "VARIABLE_UPDATED":
                J.data.updated_src = x.updateSrc(U, oe), x.set(U, "action", "variable-update", f(f({}, oe), {}, { type: "variable-edited" })), x.emit("variable-update-" + U);
                break;
              case "VARIABLE_REMOVED":
                J.data.updated_src = x.updateSrc(U, oe), x.set(U, "action", "variable-update", f(f({}, oe), {}, { type: "variable-removed" })), x.emit("variable-update-" + U);
                break;
              case "VARIABLE_ADDED":
                J.data.updated_src = x.updateSrc(U, oe), x.set(U, "action", "variable-update", f(f({}, oe), {}, { type: "variable-added" })), x.emit("variable-update-" + U);
                break;
              case "ADD_VARIABLE_KEY_REQUEST":
                x.set(U, "action", "new-key-request", oe), x.emit("add-key-request-" + U);
            }
          }, x.updateSrc = function(J, U) {
            var oe = U.name, le = U.namespace, ge = U.new_value, be = (U.existing_value, U.variable_removed);
            le.shift();
            var ke, me = x.get(J, "global", "src"), He = x.deepCopy(me, re(le)), ht = He, nt = function(Et, _n) {
              var Zt = typeof Symbol < "u" && Et[Symbol.iterator] || Et["@@iterator"];
              if (!Zt) {
                if (Array.isArray(Et) || (Zt = Y(Et)) || _n) {
                  Zt && (Et = Zt);
                  var Ss = 0, xn = function() {
                  };
                  return { s: xn, n: function() {
                    return Ss >= Et.length ? { done: !0 } : { done: !1, value: Et[Ss++] };
                  }, e: function(Pr) {
                    throw Pr;
                  }, f: xn };
                }
                throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
              }
              var ho, Pn = !0, Kt = !1;
              return { s: function() {
                Zt = Zt.call(Et);
              }, n: function() {
                var Pr = Zt.next();
                return Pn = Pr.done, Pr;
              }, e: function(Pr) {
                Kt = !0, ho = Pr;
              }, f: function() {
                try {
                  Pn || Zt.return == null || Zt.return();
                } finally {
                  if (Kt) throw ho;
                }
              } };
            }(le);
            try {
              for (nt.s(); !(ke = nt.n()).done; )
                ht = ht[ke.value];
            } catch (Et) {
              nt.e(Et);
            } finally {
              nt.f();
            }
            return be ? D(ht) == "array" ? ht.splice(oe, 1) : delete ht[oe] : oe !== null ? ht[oe] = ge : He = ge, x.set(J, "global", "src", He), He;
          }, x.deepCopy = function(J, U) {
            var oe, le = D(J), ge = U.shift();
            return le == "array" ? oe = re(J) : le == "object" && (oe = f({}, J)), ge !== void 0 && (oe[ge] = x.deepCopy(J[ge], U)), oe;
          }, x;
        }
        return m(_, A), h(_);
      }(fe.EventEmitter))();
      Ie.register(Le.handleAction.bind(Le));
      const K = Le;
      var G = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).toggleCollapsed = function() {
            k.setState({ collapsed: !k.state.collapsed }, function() {
              K.set(k.props.rjvId, k.props.namespace, "collapsed", k.state.collapsed);
            });
          }, k.getFunctionDisplay = function(B) {
            var Z = k.props;
            return B ? v().createElement("span", null, k.props.value.toString().slice(9, -1).replace(/\{[\s\S]+/, ""), v().createElement("span", { className: "function-collapsed", style: { fontWeight: "bold" } }, v().createElement("span", null, "{"), v().createElement("span", se(Z.theme, "ellipsis"), "..."), v().createElement("span", null, "}"))) : k.props.value.toString().slice(9, -1);
          }, k.state = { collapsed: K.get(x.rjvId, x.namespace, "collapsed", !0) }, k;
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = this.state.collapsed;
          return v().createElement("div", se(x.theme, "function"), v().createElement(Ze, Object.assign({ type_name: "function" }, x)), v().createElement("span", Object.assign({}, se(x.theme, "function-value"), { className: "rjv-function-container", onClick: this.toggleCollapsed }), this.getFunctionDisplay(k)));
        } }]);
      }(v().PureComponent), ae = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          return v().createElement("div", se(this.props.theme, "nan"), "NaN");
        } }]);
      }(v().PureComponent), he = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          return v().createElement("div", se(this.props.theme, "null"), "NULL");
        } }]);
      }(v().PureComponent), Oe = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "integer"), v().createElement(Ze, Object.assign({ type_name: "int" }, x)), this.props.value);
        } }]);
      }(v().PureComponent), ut = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "regexp"), v().createElement(Ze, Object.assign({ type_name: "regexp" }, x)), this.props.value.toString());
        } }]);
      }(v().PureComponent), Se = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).toggleCollapsed = function() {
            k.setState({ collapsed: !k.state.collapsed }, function() {
              K.set(k.props.rjvId, k.props.namespace, "collapsed", k.state.collapsed);
            });
          }, k.state = { collapsed: K.get(x.rjvId, x.namespace, "collapsed", !0) }, k;
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.state.collapsed, k = this.props, B = k.collapseStringsAfterLength, Z = k.theme, J = k.escapeStrings, U = k.value, oe = D(B) === "integer", le = { style: { cursor: "default" } };
          return J && (U = z(U)), oe && U.length > B && (le.style.cursor = "pointer", x && (U = v().createElement("span", null, U.substring(0, B), v().createElement("span", se(Z, "ellipsis"), " ...")))), v().createElement("div", se(Z, "string"), v().createElement(Ze, Object.assign({ type_name: "string" }, k)), v().createElement("span", Object.assign({ className: "string-value" }, le, { onClick: this.toggleCollapsed }), '"', U, '"'));
        } }]);
      }(v().PureComponent), Ne = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          return v().createElement("div", se(this.props.theme, "undefined"), "undefined");
        } }]);
      }(v().PureComponent), et = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props;
          return v().createElement("div", se(x.theme, "bigNumber"), v().createElement(Ze, Object.assign({ type_name: "bigNumber" }, x)), this.props.value.toString());
        } }]);
      }(v().PureComponent);
      function It() {
        return It = Object.assign ? Object.assign.bind() : function(A) {
          for (var _ = 1; _ < arguments.length; _++) {
            var x = arguments[_];
            for (var k in x) ({}).hasOwnProperty.call(x, k) && (A[k] = x[k]);
          }
          return A;
        }, It.apply(null, arguments);
      }
      const Vt = w.useLayoutEffect;
      var ur = function(A, _) {
        typeof A != "function" ? A.current = _ : A(_);
      };
      const Ft = function(A, _) {
        var x = (0, w.useRef)();
        return (0, w.useCallback)(function(k) {
          A.current = k, x.current && ur(x.current, null), x.current = _, _ && ur(_, k);
        }, [_]);
      };
      var it = { "min-height": "0", "max-height": "none", height: "0", visibility: "hidden", overflow: "hidden", position: "absolute", "z-index": "-1000", top: "0", right: "0" }, at = function(A) {
        Object.keys(it).forEach(function(_) {
          A.style.setProperty(_, it[_], "important");
        });
      }, kt = null, Jt = function() {
      }, yt = ["borderBottomWidth", "borderLeftWidth", "borderRightWidth", "borderTopWidth", "boxSizing", "fontFamily", "fontSize", "fontStyle", "fontWeight", "letterSpacing", "lineHeight", "paddingBottom", "paddingLeft", "paddingRight", "paddingTop", "tabSize", "textIndent", "textRendering", "textTransform", "width", "wordBreak"], Ot = !!document.documentElement.currentStyle, nr = function(A) {
        var _, x, k = (_ = A, x = w.useRef(_), Vt(function() {
          x.current = _;
        }), x);
        (0, w.useLayoutEffect)(function() {
          var B = function(Z) {
            k.current(Z);
          };
          return window.addEventListener("resize", B), function() {
            window.removeEventListener("resize", B);
          };
        }, []);
      }, _r = function(A, _) {
        var x = A.cacheMeasurements, k = A.maxRows, B = A.minRows, Z = A.onChange, J = Z === void 0 ? Jt : Z, U = A.onHeightChange, oe = U === void 0 ? Jt : U, le = T(A, ["cacheMeasurements", "maxRows", "minRows", "onChange", "onHeightChange"]), ge = le.value !== void 0, be = (0, w.useRef)(null), ke = Ft(be, _), me = (0, w.useRef)(0), He = (0, w.useRef)(), ht = function() {
          var nt = be.current, Et = x && He.current ? He.current : function(xn) {
            var ho = window.getComputedStyle(xn);
            if (ho === null) return null;
            var Pn, Kt = (Pn = ho, yt.reduce(function(Xa, zo) {
              return Xa[zo] = Pn[zo], Xa;
            }, {})), Pr = Kt.boxSizing;
            return Pr === "" ? null : (Ot && Pr === "border-box" && (Kt.width = parseFloat(Kt.width) + parseFloat(Kt.borderRightWidth) + parseFloat(Kt.borderLeftWidth) + parseFloat(Kt.paddingRight) + parseFloat(Kt.paddingLeft) + "px"), { sizingStyle: Kt, paddingSize: parseFloat(Kt.paddingBottom) + parseFloat(Kt.paddingTop), borderSize: parseFloat(Kt.borderBottomWidth) + parseFloat(Kt.borderTopWidth) });
          }(nt);
          if (Et) {
            He.current = Et;
            var _n = function(xn, ho, Pn, Kt) {
              Pn === void 0 && (Pn = 1), Kt === void 0 && (Kt = 1 / 0), kt || ((kt = document.createElement("textarea")).setAttribute("tabindex", "-1"), kt.setAttribute("aria-hidden", "true"), at(kt)), kt.parentNode === null && document.body.appendChild(kt);
              var Pr = xn.paddingSize, Xa = xn.borderSize, zo = xn.sizingStyle, qp = zo.boxSizing;
              Object.keys(zo).forEach(function(zc) {
                var Uo = zc;
                kt.style[Uo] = zo[Uo];
              }), at(kt), kt.value = ho;
              var ws = function(zc, Uo) {
                var Wp = zc.scrollHeight;
                return Uo.sizingStyle.boxSizing === "border-box" ? Wp + Uo.borderSize : Wp - Uo.paddingSize;
              }(kt, xn);
              kt.value = "x";
              var Dc = kt.scrollHeight - Pr, Lc = Dc * Pn;
              qp === "border-box" && (Lc = Lc + Pr + Xa), ws = Math.max(Lc, ws);
              var Bc = Dc * Kt;
              return qp === "border-box" && (Bc = Bc + Pr + Xa), [ws = Math.min(Bc, ws), Dc];
            }(Et, nt.value || nt.placeholder || "x", B, k), Zt = _n[0], Ss = _n[1];
            me.current !== Zt && (me.current = Zt, nt.style.setProperty("height", Zt + "px", "important"), oe(Zt, { rowHeight: Ss }));
          }
        };
        return (0, w.useLayoutEffect)(ht), nr(ht), (0, w.createElement)("textarea", It({}, le, { onChange: function(nt) {
          ge || ht(), J(nt);
        }, ref: ke }));
      };
      const Cn = (0, w.forwardRef)(_r);
      function Hr(A, _) {
        A = A.trim();
        try {
          if ((A = structuredClone(A))[0] === "[") return wt("array", JSON.parse(A));
          if (A[0] === "{") return wt("object", JSON.parse(A));
          if (A.match(/\-?\d+\.\d+/) && A.match(/\-?\d+\.\d+/)[0] === A) return _ && parseFloat(A).toString() !== A ? wt("bigNumber", A) : wt("float", parseFloat(A));
          if (A.match(/\-?\d+e-\d+/) && A.match(/\-?\d+e-\d+/)[0] === A) return wt("float", Number(A));
          if (A.match(/\-?\d+/) && A.match(/\-?\d+/)[0] === A) return _ && parseInt(A).toString() !== A ? wt("bigNumber", A) : wt("integer", parseInt(A));
          if (A.match(/\-?\d+e\+\d+/) && A.match(/\-?\d+e\+\d+/)[0] === A) return wt("integer", Number(A));
        } catch {
        }
        switch (A = A.toLowerCase()) {
          case "undefined":
            return wt("undefined", void 0);
          case "nan":
            return wt("nan", NaN);
          case "null":
            return wt("null", null);
          case "true":
            return wt("boolean", !0);
          case "false":
            return wt("boolean", !1);
          default:
            if (A = Date.parse(A)) return wt("date", new Date(A));
        }
        return wt(!1, null);
      }
      function wt(A, _) {
        return { type: A, value: _ };
      }
      var qn = ["style"], jt = ["style"], yr = ["style"], xr = ["style"], Nr = ["style"], or = ["style"], tn = ["style"], rn = ["style"], br = ["style"], Fr = ["style"], nn = ["style"], En = ["style"], Wn = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, qn);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 24 24", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("path", { d: "M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M7,13H17V11H7" })));
        } }]);
      }(v().PureComponent), Mc = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, jt);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 24 24", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("path", { d: "M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M13,7H11V11H7V13H11V17H13V13H17V11H13V7Z" })));
        } }]);
      }(v().PureComponent), bs = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, yr), Z = jr(k).style;
          return v().createElement("span", B, v().createElement("svg", { fill: Z.color, width: Z.height, height: Z.width, style: Z, viewBox: "0 0 1792 1792" }, v().createElement("path", { d: "M1344 800v64q0 14-9 23t-23 9h-832q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h832q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z" })));
        } }]);
      }(v().PureComponent), H1 = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, xr), Z = jr(k).style;
          return v().createElement("span", B, v().createElement("svg", { fill: Z.color, width: Z.height, height: Z.width, style: Z, viewBox: "0 0 1792 1792" }, v().createElement("path", { d: "M1344 800v64q0 14-9 23t-23 9h-352v352q0 14-9 23t-23 9h-64q-14 0-23-9t-9-23v-352h-352q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h352v-352q0-14 9-23t23-9h64q14 0 23 9t9 23v352h352q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z" })));
        } }]);
      }(v().PureComponent), J1 = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, Nr);
          return v().createElement("span", B, v().createElement("svg", { style: f(f({}, jr(k).style), {}, { paddingLeft: "2px", verticalAlign: "top" }), viewBox: "0 0 15 15", fill: "currentColor" }, v().createElement("path", { d: "M0 14l6-6-6-6z" })));
        } }]);
      }(v().PureComponent), Y1 = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, or);
          return v().createElement("span", B, v().createElement("svg", { style: f(f({}, jr(k).style), {}, { paddingLeft: "2px", verticalAlign: "top" }), viewBox: "0 0 15 15", fill: "currentColor" }, v().createElement("path", { d: "M0 5l6 6 6-6z" })));
        } }]);
      }(v().PureComponent), Fp = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, tn);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m30 35h-25v-22.5h25v7.5h2.5v-12.5c0-1.4-1.1-2.5-2.5-2.5h-7.5c0-2.8-2.2-5-5-5s-5 2.2-5 5h-7.5c-1.4 0-2.5 1.1-2.5 2.5v27.5c0 1.4 1.1 2.5 2.5 2.5h25c1.4 0 2.5-1.1 2.5-2.5v-5h-2.5v5z m-20-27.5h2.5s2.5-1.1 2.5-2.5 1.1-2.5 2.5-2.5 2.5 1.1 2.5 2.5 1.3 2.5 2.5 2.5h2.5s2.5 1.1 2.5 2.5h-20c0-1.5 1.1-2.5 2.5-2.5z m-2.5 20h5v-2.5h-5v2.5z m17.5-5v-5l-10 7.5 10 7.5v-5h12.5v-5h-12.5z m-17.5 10h7.5v-2.5h-7.5v2.5z m12.5-17.5h-12.5v2.5h12.5v-2.5z m-7.5 5h-5v2.5h5v-2.5z" }))));
        } }]);
      }(v().PureComponent), Nc = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, rn);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m28.6 25q0-0.5-0.4-1l-4-4 4-4q0.4-0.5 0.4-1 0-0.6-0.4-1.1l-2-2q-0.4-0.4-1-0.4-0.6 0-1 0.4l-4.1 4.1-4-4.1q-0.4-0.4-1-0.4-0.6 0-1 0.4l-2 2q-0.5 0.5-0.5 1.1 0 0.5 0.5 1l4 4-4 4q-0.5 0.5-0.5 1 0 0.7 0.5 1.1l2 2q0.4 0.4 1 0.4 0.6 0 1-0.4l4-4.1 4.1 4.1q0.4 0.4 1 0.4 0.6 0 1-0.4l2-2q0.4-0.4 0.4-1z m8.7-5q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z" }))));
        } }]);
      }(v().PureComponent), X1 = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, br);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m30.1 21.4v-2.8q0-0.6-0.4-1t-1-0.5h-5.7v-5.7q0-0.6-0.4-1t-1-0.4h-2.9q-0.6 0-1 0.4t-0.4 1v5.7h-5.7q-0.6 0-1 0.5t-0.5 1v2.8q0 0.6 0.5 1t1 0.5h5.7v5.7q0 0.5 0.4 1t1 0.4h2.9q0.6 0 1-0.4t0.4-1v-5.7h5.7q0.6 0 1-0.5t0.4-1z m7.2-1.4q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z" }))));
        } }]);
      }(v().PureComponent), jp = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, Fr);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m31.6 21.6h-10v10h-3.2v-10h-10v-3.2h10v-10h3.2v10h10v3.2z" }))));
        } }]);
      }(v().PureComponent), Z1 = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, nn);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m19.8 26.4l2.6-2.6-3.4-3.4-2.6 2.6v1.3h2.2v2.1h1.2z m9.8-16q-0.3-0.4-0.7 0l-7.8 7.8q-0.4 0.4 0 0.7t0.7 0l7.8-7.8q0.4-0.4 0-0.7z m1.8 13.2v4.3q0 2.6-1.9 4.5t-4.5 1.9h-18.6q-2.6 0-4.5-1.9t-1.9-4.5v-18.6q0-2.7 1.9-4.6t4.5-1.8h18.6q1.4 0 2.6 0.5 0.3 0.2 0.4 0.5 0.1 0.4-0.2 0.7l-1.1 1.1q-0.3 0.3-0.7 0.1-0.5-0.1-1-0.1h-18.6q-1.4 0-2.5 1.1t-1 2.5v18.6q0 1.4 1 2.5t2.5 1h18.6q1.5 0 2.5-1t1.1-2.5v-2.9q0-0.2 0.2-0.4l1.4-1.5q0.3-0.3 0.8-0.1t0.4 0.6z m-2.1-16.5l6.4 6.5-15 15h-6.4v-6.5z m9.9 3l-2.1 2-6.4-6.4 2.1-2q0.6-0.7 1.5-0.7t1.5 0.7l3.4 3.4q0.6 0.6 0.6 1.5t-0.6 1.5z" }))));
        } }]);
      }(v().PureComponent), Fc = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.style, B = F(x, En);
          return v().createElement("span", B, v().createElement("svg", Object.assign({}, jr(k), { viewBox: "0 0 40 40", fill: "currentColor", preserveAspectRatio: "xMidYMid meet" }), v().createElement("g", null, v().createElement("path", { d: "m31.7 16.4q0-0.6-0.4-1l-2.1-2.1q-0.4-0.4-1-0.4t-1 0.4l-9.1 9.1-5-5q-0.5-0.4-1-0.4t-1 0.4l-2.1 2q-0.4 0.4-0.4 1 0 0.6 0.4 1l8.1 8.1q0.4 0.4 1 0.4 0.6 0 1-0.4l12.2-12.1q0.4-0.4 0.4-1z m5.6 3.6q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z" }))));
        } }]);
      }(v().PureComponent);
      function jr(A) {
        return A || (A = {}), { style: f(f({ verticalAlign: "middle" }, A), {}, { color: A.color ? A.color : "#000000", height: "1em", width: "1em" }) };
      }
      var Dp = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).copiedTimer = null, k.copyToClipboardFallback = function(B) {
            var Z = document.createElement("textarea");
            Z.value = B, document.body.appendChild(Z), Z.select(), document.execCommand("copy"), document.body.removeChild(Z);
          }, k.handleCopy = function() {
            var B = k.props, Z = B.clickCallback, J = B.src, U = B.namespace, oe = JSON.stringify(k.clipboardValue(J), null, "  ");
            navigator.clipboard ? navigator.clipboard.writeText(oe).catch(function() {
              k.copyToClipboardFallback(oe);
            }) : k.copyToClipboardFallback(oe), k.copiedTimer = setTimeout(function() {
              k.setState({ copied: !1 });
            }, 5500), k.setState({ copied: !0 }, function() {
              typeof Z == "function" && Z({ src: J, namespace: U, name: U[U.length - 1] });
            });
          }, k.getClippyIcon = function() {
            var B = k.props.theme;
            return k.state.copied ? v().createElement("span", null, v().createElement(Fp, Object.assign({ className: "copy-icon" }, se(B, "copy-icon"))), v().createElement("span", se(B, "copy-icon-copied"), "✔")) : v().createElement(Fp, Object.assign({ className: "copy-icon" }, se(B, "copy-icon")));
          }, k.clipboardValue = function(B) {
            switch (D(B)) {
              case "function":
              case "regexp":
                return B.toString();
              default:
                return B;
            }
          }, k.state = { copied: !1 }, k;
        }
        return m(_, A), h(_, [{ key: "componentWillUnmount", value: function() {
          this.copiedTimer && (clearTimeout(this.copiedTimer), this.copiedTimer = null);
        } }, { key: "render", value: function() {
          var x = this.props, k = (x.src, x.theme), B = x.hidden, Z = x.rowHovered, J = se(k, "copy-to-clipboard").style, U = "inline";
          return B && (U = "none"), v().createElement("span", { className: "copy-to-clipboard-container", title: "Copy to clipboard", style: { verticalAlign: "top", display: Z ? "inline-block" : "none" } }, v().createElement("span", { style: f(f({}, J), {}, { display: U }), onClick: this.handleCopy }, this.getClippyIcon()));
        } }]);
      }(v().PureComponent);
      const Q1 = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).getEditIcon = function() {
            var B = k.props, Z = B.variable, J = B.theme;
            return v().createElement("div", { className: "click-to-edit", style: { verticalAlign: "top", display: k.state.hovered ? "inline-block" : "none" } }, v().createElement(Z1, Object.assign({ className: "click-to-edit-icon" }, se(J, "editVarIcon"), { onClick: function() {
              k.prepopInput(Z);
            } })));
          }, k.prepopInput = function(B) {
            if (k.props.onEdit !== !1) {
              var Z = function(U, oe) {
                var le;
                switch (D(U, oe)) {
                  case "undefined":
                    le = "undefined";
                    break;
                  case "nan":
                    le = "NaN";
                    break;
                  case "string":
                    le = U;
                    break;
                  case "bigNumber":
                  case "date":
                  case "function":
                  case "regexp":
                    le = U.toString();
                    break;
                  default:
                    try {
                      le = JSON.stringify(U, null, "  ");
                    } catch {
                      le = "";
                    }
                }
                return le;
              }(B.value, k.props.bigNumber), J = Hr(Z, k.props.bigNumber);
              k.setState({ editMode: !0, editValue: Z, parsedInput: { type: J.type, value: J.value } });
            }
          }, k.getRemoveIcon = function() {
            var B = k.props, Z = B.variable, J = B.namespace, U = B.theme, oe = B.rjvId;
            return v().createElement("div", { className: "click-to-remove", style: { verticalAlign: "top", display: k.state.hovered ? "inline-block" : "none" } }, v().createElement(Nc, Object.assign({ className: "click-to-remove-icon" }, se(U, "removeVarIcon"), { onClick: function() {
              Ie.dispatch({ name: "VARIABLE_REMOVED", rjvId: oe, data: { name: Z.name, namespace: J, existing_value: Z.value, variable_removed: !0 } });
            } })));
          }, k.getValue = function(B, Z) {
            var J = !Z && B.type, U = k.props;
            switch (J) {
              case !1:
                return k.getEditInput();
              case "string":
                return v().createElement(Se, Object.assign({ value: B.value }, U));
              case "integer":
                return v().createElement(Oe, Object.assign({ value: B.value }, U));
              case "float":
                return v().createElement(Nt, Object.assign({ value: B.value }, U));
              case "boolean":
                return v().createElement(rt, Object.assign({ value: B.value }, U));
              case "function":
                return v().createElement(G, Object.assign({ value: B.value }, U));
              case "null":
                return v().createElement(he, U);
              case "nan":
                return v().createElement(ae, U);
              case "undefined":
                return v().createElement(Ne, U);
              case "date":
                return v().createElement(Ce, Object.assign({ value: B.value }, U));
              case "regexp":
                return v().createElement(ut, Object.assign({ value: B.value }, U));
              case "bigNumber":
                return v().createElement(et, Object.assign({ value: B.value }, U));
              default:
                return v().createElement("div", { className: "object-value" }, JSON.stringify(B.value));
            }
          }, k.getEditInput = function() {
            var B = k.props, Z = B.keyModifier, J = B.selectOnFocus, U = B.theme, oe = k.state.editValue;
            return v().createElement("div", null, v().createElement(Cn, Object.assign({ type: "text", ref: function(le) {
              le && le[J ? "select" : "focus"]();
            }, value: oe, className: "variable-editor", onChange: function(le) {
              var ge = le.target.value, be = Hr(ge, k.props.bigNumber);
              k.setState({ editValue: ge, parsedInput: { type: be.type, value: be.value } });
            }, onKeyDown: function(le) {
              switch (le.key) {
                case "Escape":
                  k.setState({ editMode: !1, editValue: "" });
                  break;
                case "Enter":
                  Z(le, "submit") && k.submitEdit(!0);
              }
              le.stopPropagation();
            }, placeholder: "update this value", minRows: 2 }, se(U, "edit-input"))), v().createElement("div", se(U, "edit-icon-container"), v().createElement(Nc, Object.assign({ className: "edit-cancel" }, se(U, "cancel-icon"), { onClick: function(le) {
              le && le.stopPropagation(), k.setState({ editMode: !1, editValue: "" });
            } })), v().createElement(Fc, Object.assign({ className: "edit-check string-value" }, se(U, "check-icon"), { onClick: function(le) {
              le && le.stopPropagation(), k.submitEdit();
            } })), v().createElement("div", null, k.showDetected())));
          }, k.submitEdit = function(B) {
            var Z = k.props, J = Z.variable, U = Z.namespace, oe = Z.rjvId, le = Z.bigNumber, ge = k.state, be = ge.editValue, ke = ge.parsedInput, me = be;
            B && ke.type && (me = ke.value, le && ke.type === "bigNumber" && (me = new le(me))), k.setState({ editMode: !1 }), Ie.dispatch({ name: "VARIABLE_UPDATED", rjvId: oe, data: { name: J.name, namespace: U, existing_value: J.value, new_value: me, variable_removed: !1 } });
          }, k.showDetected = function() {
            var B = k.props, Z = B.theme, J = (B.variable, B.namespace, B.rjvId, k.state.parsedInput), U = (J.type, J.value, k.getDetectedInput());
            if (U) return v().createElement("div", null, v().createElement("div", se(Z, "detected-row"), U, v().createElement(Fc, { className: "edit-check detected", style: f({ verticalAlign: "top", paddingLeft: "3px" }, se(Z, "check-icon").style), onClick: function(oe) {
              oe && oe.stopPropagation(), k.submitEdit(!0);
            } })));
          }, k.getDetectedInput = function() {
            var B = k.state.parsedInput, Z = B.type, J = B.value, U = k.props, oe = U.theme;
            if (Z !== !1) switch (Z.toLowerCase()) {
              case "object":
                return v().createElement("span", null, v().createElement("span", { style: f(f({}, se(oe, "brace").style), {}, { cursor: "default" }) }, "{"), v().createElement("span", { style: f(f({}, se(oe, "ellipsis").style), {}, { cursor: "default" }) }, "..."), v().createElement("span", { style: f(f({}, se(oe, "brace").style), {}, { cursor: "default" }) }, "}"));
              case "array":
                return v().createElement("span", null, v().createElement("span", { style: f(f({}, se(oe, "brace").style), {}, { cursor: "default" }) }, "["), v().createElement("span", { style: f(f({}, se(oe, "ellipsis").style), {}, { cursor: "default" }) }, "..."), v().createElement("span", { style: f(f({}, se(oe, "brace").style), {}, { cursor: "default" }) }, "]"));
              case "string":
                return v().createElement(Se, Object.assign({ value: J }, U));
              case "integer":
                return v().createElement(Oe, Object.assign({ value: J }, U));
              case "float":
                return v().createElement(Nt, Object.assign({ value: J }, U));
              case "boolean":
                return v().createElement(rt, Object.assign({ value: J }, U));
              case "function":
                return v().createElement(G, Object.assign({ value: J }, U));
              case "null":
                return v().createElement(he, U);
              case "nan":
                return v().createElement(ae, U);
              case "undefined":
                return v().createElement(Ne, U);
              case "date":
                return v().createElement(Ce, Object.assign({ value: new Date(J) }, U));
              case "bignumber":
                return v().createElement(et, Object.assign({ value: J }, U));
            }
          }, k.state = { editMode: !1, editValue: "", hovered: !1, renameKey: !1, parsedInput: { type: !1, value: null } }, k;
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this, k = this.props, B = k.variable, Z = k.singleIndent, J = k.type, U = k.theme, oe = k.namespace, le = k.indentWidth, ge = k.enableClipboard, be = k.onEdit, ke = k.onDelete, me = k.onSelect, He = k.displayArrayKey, ht = k.quotesOnKeys, nt = k.keyModifier, Et = this.state.editMode;
          return v().createElement("div", Object.assign({}, se(U, "objectKeyVal", { paddingLeft: le * Z }), { onMouseEnter: function() {
            return x.setState(f(f({}, x.state), {}, { hovered: !0 }));
          }, onMouseLeave: function() {
            return x.setState(f(f({}, x.state), {}, { hovered: !1 }));
          }, className: "variable-row", key: B.name }), J == "array" ? He ? v().createElement("span", Object.assign({}, se(U, "array-key"), { key: B.name + "_" + oe }), B.name, v().createElement("div", se(U, "colon"), ":")) : null : v().createElement("span", null, v().createElement("span", Object.assign({}, se(U, "object-name"), { className: "object-key", key: B.name + "_" + oe }), !!ht && v().createElement("span", { style: { verticalAlign: "top" } }, '"'), v().createElement("span", { style: { display: "inline-block" } }, z(B.name)), !!ht && v().createElement("span", { style: { verticalAlign: "top" } }, '"')), v().createElement("span", se(U, "colon"), ":")), v().createElement("div", Object.assign({ className: "variable-value", onClick: me === !1 && be === !1 ? null : function(_n) {
            var Zt = re(oe);
            nt(_n, "edit") && be !== !1 ? x.prepopInput(B) : me !== !1 && (Zt.shift(), me(f(f({}, B), {}, { namespace: Zt })));
          } }, se(U, "variableValue", { cursor: me === !1 ? "default" : "pointer" })), this.getValue(B, Et)), ge ? v().createElement(Dp, { rowHovered: this.state.hovered, hidden: Et, src: B.value, clickCallback: ge, theme: U, namespace: [].concat(re(oe), [B.name]) }) : null, be !== !1 && Et == 0 ? this.getEditIcon() : null, ke !== !1 && Et == 0 ? this.getRemoveIcon() : null);
        } }]);
      }(v().PureComponent);
      var Lp = function(A) {
        function _() {
          var x;
          d(this, _);
          for (var k = arguments.length, B = new Array(k), Z = 0; Z < k; Z++) B[Z] = arguments[Z];
          return (x = y(this, _, [].concat(B))).getObjectSize = function() {
            var J = x.props, U = J.size, oe = J.theme;
            if (J.displayObjectSize) return v().createElement("span", Object.assign({ className: "object-size" }, se(oe, "object-size")), U, " item", U === 1 ? "" : "s");
          }, x.getAddAttribute = function(J) {
            var U = x.props, oe = U.theme, le = U.namespace, ge = U.name, be = U.src, ke = U.rjvId, me = U.depth;
            return v().createElement("span", { className: "click-to-add", style: { verticalAlign: "top", display: J ? "inline-block" : "none" } }, v().createElement(X1, Object.assign({ className: "click-to-add-icon" }, se(oe, "addVarIcon"), { onClick: function() {
              var He = { name: me > 0 ? ge : null, namespace: le.splice(0, le.length - 1), existing_value: be, variable_removed: !1, key_name: null };
              D(be) === "object" ? Ie.dispatch({ name: "ADD_VARIABLE_KEY_REQUEST", rjvId: ke, data: He }) : Ie.dispatch({ name: "VARIABLE_ADDED", rjvId: ke, data: f(f({}, He), {}, { new_value: [].concat(re(be), [null]) }) });
            } })));
          }, x.getRemoveObject = function(J) {
            var U = x.props, oe = U.theme, le = (U.hover, U.namespace), ge = U.name, be = U.src, ke = U.rjvId;
            if (le.length !== 1) return v().createElement("span", { className: "click-to-remove", style: { display: J ? "inline-block" : "none" } }, v().createElement(Nc, Object.assign({ className: "click-to-remove-icon" }, se(oe, "removeVarIcon"), { onClick: function() {
              Ie.dispatch({ name: "VARIABLE_REMOVED", rjvId: ke, data: { name: ge, namespace: le.splice(0, le.length - 1), existing_value: be, variable_removed: !0 } });
            } })));
          }, x.render = function() {
            var J = x.props, U = J.theme, oe = J.onDelete, le = J.onAdd, ge = J.enableClipboard, be = J.src, ke = J.namespace, me = J.rowHovered;
            return v().createElement("div", Object.assign({}, se(U, "object-meta-data"), { className: "object-meta-data", onClick: function(He) {
              He.stopPropagation();
            } }), x.getObjectSize(), ge ? v().createElement(Dp, { rowHovered: me, clickCallback: ge, src: be, theme: U, namespace: ke }) : null, le !== !1 ? x.getAddAttribute(me) : null, oe !== !1 ? x.getRemoveObject(me) : null);
          }, x;
        }
        return m(_, A), h(_);
      }(v().PureComponent);
      function Bp(A) {
        var _ = A.parent_type, x = A.namespace, k = A.quotesOnKeys, B = A.theme, Z = A.jsvRoot, J = A.name, U = A.displayArrayKey, oe = A.name ? A.name : "";
        return !Z || J !== !1 && J !== null ? _ == "array" ? U ? v().createElement("span", Object.assign({}, se(B, "array-key"), { key: x }), v().createElement("span", { className: "array-key" }, oe), v().createElement("span", se(B, "colon"), ":")) : v().createElement("span", null) : v().createElement("span", Object.assign({}, se(B, "object-name"), { key: x }), v().createElement("span", { className: "object-key" }, k && v().createElement("span", { style: { verticalAlign: "top" } }, '"'), v().createElement("span", null, oe), k && v().createElement("span", { style: { verticalAlign: "top" } }, '"')), v().createElement("span", se(B, "colon"), ":")) : v().createElement("span", null);
      }
      function zp(A) {
        var _ = A.theme;
        switch (A.iconStyle) {
          case "triangle":
            return v().createElement(Y1, Object.assign({}, se(_, "expanded-icon"), { className: "expanded-icon" }));
          case "square":
            return v().createElement(bs, Object.assign({}, se(_, "expanded-icon"), { className: "expanded-icon" }));
          default:
            return v().createElement(Wn, Object.assign({}, se(_, "expanded-icon"), { className: "expanded-icon" }));
        }
      }
      function Up(A) {
        var _ = A.theme;
        switch (A.iconStyle) {
          case "triangle":
            return v().createElement(J1, Object.assign({}, se(_, "collapsed-icon"), { className: "collapsed-icon" }));
          case "square":
            return v().createElement(H1, Object.assign({}, se(_, "collapsed-icon"), { className: "collapsed-icon" }));
          default:
            return v().createElement(Mc, Object.assign({}, se(_, "collapsed-icon"), { className: "collapsed-icon" }));
        }
      }
      var e$ = ["src", "groupArraysAfterLength", "depth", "name", "theme", "jsvRoot", "namespace", "parent_type"], Vp = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).toggleCollapsed = function(B) {
            var Z = [];
            for (var J in k.state.expanded) Z.push(k.state.expanded[J]);
            Z[B] = !Z[B], k.setState({ expanded: Z });
          }, k.state = { expanded: [] }, k;
        }
        return m(_, A), h(_, [{ key: "getExpandedIcon", value: function(x) {
          var k = this.props, B = k.theme, Z = k.iconStyle;
          return this.state.expanded[x] ? v().createElement(zp, { theme: B, iconStyle: Z }) : v().createElement(Up, { theme: B, iconStyle: Z });
        } }, { key: "render", value: function() {
          var x = this, k = this.props, B = k.src, Z = k.groupArraysAfterLength, J = (k.depth, k.name), U = k.theme, oe = k.jsvRoot, le = k.namespace, ge = (k.parent_type, F(k, e$)), be = 0, ke = 5 * this.props.indentWidth;
          oe || (be = 5 * this.props.indentWidth);
          var me = Z, He = Math.ceil(B.length / me);
          return v().createElement("div", Object.assign({ className: "object-key-val" }, se(U, oe ? "jsv-root" : "objectKeyVal", { paddingLeft: be })), v().createElement(Bp, this.props), v().createElement("span", null, v().createElement(Lp, Object.assign({ size: B.length }, this.props))), re(Array(He)).map(function(ht, nt) {
            return v().createElement("div", Object.assign({ key: nt, className: "object-key-val array-group" }, se(U, "objectKeyVal", { marginLeft: 6, paddingLeft: ke })), v().createElement("span", se(U, "brace-row"), v().createElement("div", Object.assign({ className: "icon-container" }, se(U, "icon-container"), { onClick: function(Et) {
              x.toggleCollapsed(nt);
            } }), x.getExpandedIcon(nt)), x.state.expanded[nt] ? v().createElement(vs, Object.assign({ key: J + nt, depth: 0, name: !1, collapsed: !1, groupArraysAfterLength: me, index_offset: nt * me, src: B.slice(nt * me, nt * me + me), namespace: le, type: "array", parent_type: "array_group", theme: U }, ge)) : v().createElement("span", Object.assign({}, se(U, "brace"), { onClick: function(Et) {
              x.toggleCollapsed(nt);
            }, className: "array-group-brace" }), "[", v().createElement("div", Object.assign({}, se(U, "array-group-meta-data"), { className: "array-group-meta-data" }), v().createElement("span", Object.assign({ className: "object-size" }, se(U, "object-size")), nt * me, " - ", nt * me + me > B.length ? B.length : nt * me + me)), "]")));
          }));
        } }]);
      }(v().PureComponent), t$ = ["depth", "src", "namespace", "name", "type", "parent_type", "theme", "jsvRoot", "iconStyle"], jc = function(A) {
        function _(x) {
          var k;
          d(this, _), (k = y(this, _, [x])).toggleCollapsed = function() {
            k.setState({ expanded: !k.state.expanded }, function() {
              K.set(k.props.rjvId, k.props.namespace, "expanded", k.state.expanded);
            });
          }, k.getObjectContent = function(Z, J, U) {
            return v().createElement("div", { className: "pushed-content object-container" }, v().createElement("div", Object.assign({ className: "object-content" }, se(k.props.theme, "pushed-content")), k.renderObjectContents(J, U)));
          }, k.getEllipsis = function() {
            return k.state.size === 0 ? null : v().createElement("div", Object.assign({}, se(k.props.theme, "ellipsis"), { className: "node-ellipsis", onClick: k.toggleCollapsed }), "...");
          }, k.getObjectMetaData = function(Z) {
            var J = k.props, U = (J.rjvId, J.theme, k.state), oe = U.size, le = U.hovered;
            return v().createElement(Lp, Object.assign({ rowHovered: le, size: oe }, k.props));
          }, k.renderObjectContents = function(Z, J) {
            var U, oe = k.props, le = oe.depth, ge = oe.parent_type, be = oe.index_offset, ke = oe.groupArraysAfterLength, me = oe.namespace, He = k.state.object_type, ht = [], nt = Object.keys(Z || {});
            return k.props.sortKeys && He !== "array" && (nt = nt.sort()), nt.forEach(function(Et) {
              if (U = new r$(Et, Z[Et], J.bigNumber), ge === "array_group" && be && (U.name = parseInt(U.name) + be), Object.prototype.hasOwnProperty.call(Z, Et)) if (U.type === "object") ht.push(v().createElement(vs, Object.assign({ key: U.name, depth: le + 1, name: U.name, src: U.value, namespace: me.concat(U.name), parent_type: He }, J)));
              else if (U.type === "array") {
                var _n = vs;
                ke && U.value.length > ke && (_n = Vp), ht.push(v().createElement(_n, Object.assign({ key: U.name, depth: le + 1, name: U.name, src: U.value, namespace: me.concat(U.name), type: "array", parent_type: He }, J)));
              } else ht.push(v().createElement(Q1, Object.assign({ key: U.name + "_" + me, variable: U, singleIndent: 5, namespace: me, type: k.props.type }, J)));
            }), ht;
          };
          var B = _.getState(x);
          return k.state = f(f({}, B), {}, { prevProps: {} }), k;
        }
        return m(_, A), h(_, [{ key: "getBraceStart", value: function(x, k) {
          var B = this, Z = this.props, J = Z.src, U = Z.theme, oe = Z.iconStyle;
          if (Z.parent_type === "array_group") return v().createElement("span", null, v().createElement("span", se(U, "brace"), x === "array" ? "[" : "{"), k ? this.getObjectMetaData(J) : null);
          var le = k ? zp : Up;
          return v().createElement("span", null, v().createElement("span", Object.assign({ onClick: function(ge) {
            B.toggleCollapsed();
          } }, se(U, "brace-row")), v().createElement("div", Object.assign({ className: "icon-container" }, se(U, "icon-container")), v().createElement(le, { theme: U, iconStyle: oe })), v().createElement(Bp, this.props), v().createElement("span", se(U, "brace"), x === "array" ? "[" : "{")), k ? this.getObjectMetaData(J) : null);
        } }, { key: "render", value: function() {
          var x = this, k = this.props, B = k.depth, Z = k.src, J = (k.namespace, k.name, k.type, k.parent_type), U = k.theme, oe = k.jsvRoot, le = k.iconStyle, ge = F(k, t$), be = this.state, ke = be.object_type, me = be.expanded, He = {};
          return oe || J === "array_group" ? J === "array_group" && (He.borderLeft = 0, He.display = "inline") : He.paddingLeft = 5 * this.props.indentWidth, v().createElement("div", Object.assign({ className: "object-key-val", onMouseEnter: function() {
            return x.setState(f(f({}, x.state), {}, { hovered: !0 }));
          }, onMouseLeave: function() {
            return x.setState(f(f({}, x.state), {}, { hovered: !1 }));
          } }, se(U, oe ? "jsv-root" : "objectKeyVal", He)), this.getBraceStart(ke, me), me ? this.getObjectContent(B, Z, f({ theme: U, iconStyle: le }, ge)) : this.getEllipsis(), v().createElement("span", { className: "brace-row" }, v().createElement("span", { style: f(f({}, se(U, "brace").style), {}, { paddingLeft: me ? "3px" : "0px" }) }, ke === "array" ? "]" : "}"), me ? null : this.getObjectMetaData(Z)));
        } }], [{ key: "getDerivedStateFromProps", value: function(x, k) {
          var B = k.prevProps;
          return x.src !== B.src || x.collapsed !== B.collapsed || x.name !== B.name || x.namespace !== B.namespace || x.rjvId !== B.rjvId ? f(f({}, _.getState(x)), {}, { prevProps: x }) : null;
        } }]);
      }(v().PureComponent);
      jc.getState = function(A) {
        var _ = Object.keys(A.src).length, x = (A.collapsed === !1 || A.collapsed !== !0 && A.collapsed > A.depth) && (!A.shouldCollapse || A.shouldCollapse({ name: A.name, src: A.src, type: D(A.src), namespace: A.namespace }) === !1) && _ !== 0;
        return { expanded: K.get(A.rjvId, A.namespace, "expanded", x), object_type: A.type === "array" ? "array" : "object", parent_type: A.type === "array" ? "array" : "object", size: _, hovered: !1 };
      };
      var r$ = h(function A(_, x, k) {
        d(this, A), this.name = _, this.value = x, this.type = D(x, k);
      });
      C(jc);
      const vs = jc;
      var n$ = function(A) {
        function _() {
          var x;
          d(this, _);
          for (var k = arguments.length, B = new Array(k), Z = 0; Z < k; Z++) B[Z] = arguments[Z];
          return (x = y(this, _, [].concat(B))).render = function() {
            var J, U, oe, le, ge = x.props, be = [ge.name], ke = vs;
            return typeof ge.name != "object" || Array.isArray(ge.name) || (be = [((J = ge.name) === null || J === void 0 ? void 0 : J.displayName) || ((U = ge.name) === null || U === void 0 ? void 0 : U.name) || ((oe = ge.name) === null || oe === void 0 || (le = oe.type) === null || le === void 0 ? void 0 : le.name) || "Anonymous"]), Array.isArray(ge.src) && ge.groupArraysAfterLength && ge.src.length > ge.groupArraysAfterLength && (ke = Vp), v().createElement("div", { className: "pretty-json-container object-container" }, v().createElement("div", { className: "object-content" }, v().createElement(ke, Object.assign({ namespace: be, depth: 0, jsvRoot: !0 }, ge))));
          }, x;
        }
        return m(_, A), h(_);
      }(v().PureComponent), o$ = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).closeModal = function() {
            Ie.dispatch({ rjvId: k.props.rjvId, name: "RESET" });
          }, k.submit = function() {
            k.props.submit(k.state.input);
          }, k.state = { input: x.input ? x.input : "" }, k;
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this, k = this.props, B = k.theme, Z = k.rjvId, J = k.isValid, U = this.state.input, oe = J(U);
          return v().createElement("div", Object.assign({ className: "key-modal-request" }, se(B, "key-modal-request"), { onClick: this.closeModal }), v().createElement("div", Object.assign({}, se(B, "key-modal"), { onClick: function(le) {
            le.stopPropagation();
          } }), v().createElement("div", se(B, "key-modal-label"), "Key Name:"), v().createElement("div", { style: { position: "relative" } }, v().createElement("input", Object.assign({}, se(B, "key-modal-input"), { className: "key-modal-input", ref: function(le) {
            return le && le.focus();
          }, spellCheck: !1, value: U, placeholder: "...", onChange: function(le) {
            x.setState({ input: le.target.value });
          }, onKeyPress: function(le) {
            oe && le.key === "Enter" ? x.submit() : le.key === "Escape" && x.closeModal();
          } })), oe ? v().createElement(Fc, Object.assign({}, se(B, "key-modal-submit"), { className: "key-modal-submit", onClick: function(le) {
            return x.submit();
          } })) : null), v().createElement("span", se(B, "key-modal-cancel"), v().createElement(jp, Object.assign({}, se(B, "key-modal-cancel-icon"), { className: "key-modal-cancel", onClick: function() {
            Ie.dispatch({ rjvId: Z, name: "RESET" });
          } })))));
        } }]);
      }(v().PureComponent), a$ = function(A) {
        function _() {
          var x;
          d(this, _);
          for (var k = arguments.length, B = new Array(k), Z = 0; Z < k; Z++) B[Z] = arguments[Z];
          return (x = y(this, _, [].concat(B))).isValid = function(J) {
            var U = x.props.rjvId, oe = K.get(U, "action", "new-key-request");
            return J != "" && Object.keys(oe.existing_value).indexOf(J) === -1;
          }, x.submit = function(J) {
            var U = x.props.rjvId, oe = K.get(U, "action", "new-key-request");
            oe.new_value = f({}, oe.existing_value), oe.new_value[J] = x.props.defaultValue, Ie.dispatch({ name: "VARIABLE_ADDED", rjvId: U, data: oe });
          }, x;
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.active, B = x.theme, Z = x.rjvId;
          return k ? v().createElement(o$, { rjvId: Z, theme: B, isValid: this.isValid, submit: this.submit }) : null;
        } }]);
      }(v().PureComponent), i$ = function(A) {
        function _() {
          return d(this, _), y(this, _, arguments);
        }
        return m(_, A), h(_, [{ key: "render", value: function() {
          var x = this.props, k = x.message, B = x.active, Z = x.theme, J = x.rjvId;
          return B ? v().createElement("div", Object.assign({ className: "validation-failure" }, se(Z, "validation-failure"), { onClick: function() {
            Ie.dispatch({ rjvId: J, name: "RESET" });
          } }), v().createElement("span", se(Z, "validation-failure-label"), k), v().createElement(jp, se(Z, "validation-failure-clear"))) : null;
        } }]);
      }(v().PureComponent), $s = function(A) {
        function _(x) {
          var k;
          return d(this, _), (k = y(this, _, [x])).rjvId = Date.now().toString() + Math.random().toString(36).slice(2), k.getListeners = function() {
            return { reset: k.resetState, "variable-update": k.updateSrc, "add-key-request": k.addKeyRequest };
          }, k.updateSrc = function() {
            var B, Z = K.get(k.rjvId, "action", "variable-update"), J = Z.name, U = Z.namespace, oe = Z.new_value, le = Z.existing_value, ge = Z.updated_src, be = Z.type, ke = k.props, me = ke.onEdit, He = ke.onDelete, ht = ke.onAdd, nt = { existing_src: k.state.src, new_value: oe, updated_src: ge, name: J, namespace: U, existing_value: le };
            switch (be) {
              case "variable-added":
                B = ht(nt);
                break;
              case "variable-edited":
                B = me(nt);
                break;
              case "variable-removed":
                B = He(nt);
            }
            B !== !1 ? (K.set(k.rjvId, "global", "src", ge), k.setState({ src: ge })) : k.setState({ validationFailure: !0 });
          }, k.addKeyRequest = function() {
            k.setState({ addKeyRequest: !0 });
          }, k.resetState = function() {
            k.setState({ validationFailure: !1, addKeyRequest: !1 });
          }, k.state = { addKeyRequest: !1, editKeyRequest: !1, validationFailure: !1, src: _.defaultProps.src, name: _.defaultProps.name, theme: _.defaultProps.theme, validationMessage: _.defaultProps.validationMessage, prevSrc: _.defaultProps.src, prevName: _.defaultProps.name, prevTheme: _.defaultProps.theme }, k;
        }
        return m(_, A), h(_, [{ key: "componentDidMount", value: function() {
          K.set(this.rjvId, "global", "src", this.state.src);
          var x = this.getListeners();
          for (var k in x) K.on(k + "-" + this.rjvId, x[k]);
          this.setState({ addKeyRequest: !1, editKeyRequest: !1 });
        } }, { key: "componentDidUpdate", value: function(x, k) {
          k.addKeyRequest !== !1 && this.setState({ addKeyRequest: !1 }), k.editKeyRequest !== !1 && this.setState({ editKeyRequest: !1 }), x.src !== this.state.src && K.set(this.rjvId, "global", "src", this.state.src);
        } }, { key: "componentWillUnmount", value: function() {
          var x = this.getListeners();
          for (var k in x) K.removeListener(k + "-" + this.rjvId, x[k]);
        } }, { key: "render", value: function() {
          var x = this.state, k = x.validationFailure, B = x.validationMessage, Z = x.addKeyRequest, J = x.theme, U = x.src, oe = x.name, le = this.props, ge = le.style, be = le.defaultValue;
          return v().createElement("div", { className: "react-json-view", style: f(f({}, se(J, "app-container").style), ge) }, v().createElement(i$, { message: B, active: k, theme: J, rjvId: this.rjvId }), v().createElement(n$, Object.assign({}, this.props, { src: U, name: oe, theme: J, type: D(U), rjvId: this.rjvId })), v().createElement(a$, { active: Z, theme: J, rjvId: this.rjvId, defaultValue: be }));
        } }], [{ key: "getDerivedStateFromProps", value: function(x, k) {
          if (x.src !== k.prevSrc || x.name !== k.prevName || x.theme !== k.prevTheme) {
            var B = { src: x.src, name: x.name, theme: x.theme, validationMessage: x.validationMessage, prevSrc: x.src, prevName: x.name, prevTheme: x.theme };
            return _.validateState(B);
          }
          return null;
        } }]);
      }(v().PureComponent);
      $s.defaultProps = { src: {}, name: "root", theme: "rjv-default", collapsed: !1, collapseStringsAfterLength: !1, shouldCollapse: !1, sortKeys: !1, quotesOnKeys: !0, groupArraysAfterLength: 100, indentWidth: 4, enableClipboard: !0, escapeStrings: !0, displayObjectSize: !0, displayDataTypes: !0, onEdit: !1, onDelete: !1, onAdd: !1, onSelect: !1, iconStyle: "triangle", style: {}, validationMessage: "Validation Error", defaultValue: null, displayArrayKey: !0, selectOnFocus: !1, keyModifier: function(A) {
        return A.metaKey || A.ctrlKey;
      }, bigNumber: null }, $s.validateState = function(A) {
        var _ = {};
        return D(A.theme) !== "object" || function(x) {
          var k = ["base00", "base01", "base02", "base03", "base04", "base05", "base06", "base07", "base08", "base09", "base0A", "base0B", "base0C", "base0D", "base0E", "base0F"];
          if (D(x) === "object") {
            for (var B = 0; B < k.length; B++) if (!(k[B] in x)) return !1;
            return !0;
          }
          return !1;
        }(A.theme) || (console.error("react-json-view error:", "theme prop must be a theme name or valid base-16 theme object.", 'defaulting to "rjv-default" theme'), _.theme = "rjv-default"), D(A.src) !== "object" && D(A.src) !== "array" && (console.error("react-json-view error:", "src property must be a valid json object"), _.name = "ERROR", _.src = { message: "src property must be a valid json object" }), f(f({}, A), _);
      }, C($s);
      const s$ = $s;
    })(), i;
  })());
})(j1);
var EJ = j1.exports;
const _J = /* @__PURE__ */ pt(EJ);
function xJ({
  content: e,
  description: t,
  renderStringAsHtml: r = !1
}) {
  const n = r ? ["string", "object"] : ["object"], o = (a) => !!(typeof a == "string" && (a.startsWith("http://") || a.startsWith("https://")) && URL.canParse(a) && !/\s/g.test(a));
  return /* @__PURE__ */ ue(Wt, { children: [
    typeof e == "string" && r && /* @__PURE__ */ P("div", { dangerouslySetInnerHTML: { __html: e } }),
    typeof e == "object" && e != null && /* @__PURE__ */ P(_J, { src: e }),
    e != null && !n.includes(typeof e) && /* @__PURE__ */ ue(Wt, { children: [
      /* @__PURE__ */ P("div", { children: t || "Output" }),
      o(e) && /* @__PURE__ */ P("a", { href: e, target: "_blank", children: e }) || /* @__PURE__ */ P("pre", { children: JSON.stringify(e, null, "    ") })
    ] })
  ] });
}
function PJ(e) {
  return Be("MuiLinearProgress", e);
}
De("MuiLinearProgress", ["root", "colorPrimary", "colorSecondary", "determinate", "indeterminate", "buffer", "query", "dashed", "dashedColorPrimary", "dashedColorSecondary", "bar", "barColorPrimary", "barColorSecondary", "bar1Indeterminate", "bar1Determinate", "bar1Buffer", "bar2Indeterminate", "bar2Buffer"]);
const ld = 4, cd = fo`
  0% {
    left: -35%;
    right: 100%;
  }

  60% {
    left: 100%;
    right: -90%;
  }

  100% {
    left: 100%;
    right: -90%;
  }
`, kJ = typeof cd != "string" ? qa`
        animation: ${cd} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
      ` : null, ud = fo`
  0% {
    left: -200%;
    right: 100%;
  }

  60% {
    left: 107%;
    right: -8%;
  }

  100% {
    left: 107%;
    right: -8%;
  }
`, OJ = typeof ud != "string" ? qa`
        animation: ${ud} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite;
      ` : null, dd = fo`
  0% {
    opacity: 1;
    background-position: 0 -23px;
  }

  60% {
    opacity: 0;
    background-position: 0 -23px;
  }

  100% {
    opacity: 1;
    background-position: -200px -23px;
  }
`, AJ = typeof dd != "string" ? qa`
        animation: ${dd} 3s infinite linear;
      ` : null, IJ = (e) => {
  const {
    classes: t,
    variant: r,
    color: n
  } = e, o = {
    root: ["root", `color${$e(n)}`, r],
    dashed: ["dashed", `dashedColor${$e(n)}`],
    bar1: ["bar", `barColor${$e(n)}`, (r === "indeterminate" || r === "query") && "bar1Indeterminate", r === "determinate" && "bar1Determinate", r === "buffer" && "bar1Buffer"],
    bar2: ["bar", r !== "buffer" && `barColor${$e(n)}`, r === "buffer" && `color${$e(n)}`, (r === "indeterminate" || r === "query") && "bar2Indeterminate", r === "buffer" && "bar2Buffer"]
  };
  return ze(o, PJ, t);
}, Tp = (e, t) => e.vars ? e.vars.palette.LinearProgress[`${t}Bg`] : e.palette.mode === "light" ? wa(e.palette[t].main, 0.62) : Sa(e.palette[t].main, 0.5), RJ = de("span", {
  name: "MuiLinearProgress",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[`color${$e(r.color)}`], t[r.variant]];
  }
})(je(({
  theme: e
}) => ({
  position: "relative",
  overflow: "hidden",
  display: "block",
  height: 4,
  // Fix Safari's bug during composition of different paint.
  zIndex: 0,
  "@media print": {
    colorAdjust: "exact"
  },
  variants: [...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      backgroundColor: Tp(e, t)
    }
  })), {
    props: ({
      ownerState: t
    }) => t.color === "inherit" && t.variant !== "buffer",
    style: {
      "&::before": {
        content: '""',
        position: "absolute",
        left: 0,
        top: 0,
        right: 0,
        bottom: 0,
        backgroundColor: "currentColor",
        opacity: 0.3
      }
    }
  }, {
    props: {
      variant: "buffer"
    },
    style: {
      backgroundColor: "transparent"
    }
  }, {
    props: {
      variant: "query"
    },
    style: {
      transform: "rotate(180deg)"
    }
  }]
}))), TJ = de("span", {
  name: "MuiLinearProgress",
  slot: "Dashed",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.dashed, t[`dashedColor${$e(r.color)}`]];
  }
})(je(({
  theme: e
}) => ({
  position: "absolute",
  marginTop: 0,
  height: "100%",
  width: "100%",
  backgroundSize: "10px 10px",
  backgroundPosition: "0 -23px",
  variants: [{
    props: {
      color: "inherit"
    },
    style: {
      opacity: 0.3,
      backgroundImage: "radial-gradient(currentColor 0%, currentColor 16%, transparent 42%)"
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => {
    const r = Tp(e, t);
    return {
      props: {
        color: t
      },
      style: {
        backgroundImage: `radial-gradient(${r} 0%, ${r} 16%, transparent 42%)`
      }
    };
  })]
})), AJ || {
  // At runtime for Pigment CSS, `bufferAnimation` will be null and the generated keyframe will be used.
  animation: `${dd} 3s infinite linear`
}), MJ = de("span", {
  name: "MuiLinearProgress",
  slot: "Bar1",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.bar, t[`barColor${$e(r.color)}`], (r.variant === "indeterminate" || r.variant === "query") && t.bar1Indeterminate, r.variant === "determinate" && t.bar1Determinate, r.variant === "buffer" && t.bar1Buffer];
  }
})(je(({
  theme: e
}) => ({
  width: "100%",
  position: "absolute",
  left: 0,
  bottom: 0,
  top: 0,
  transition: "transform 0.2s linear",
  transformOrigin: "left",
  variants: [{
    props: {
      color: "inherit"
    },
    style: {
      backgroundColor: "currentColor"
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      backgroundColor: (e.vars || e).palette[t].main
    }
  })), {
    props: {
      variant: "determinate"
    },
    style: {
      transition: `transform .${ld}s linear`
    }
  }, {
    props: {
      variant: "buffer"
    },
    style: {
      zIndex: 1,
      transition: `transform .${ld}s linear`
    }
  }, {
    props: ({
      ownerState: t
    }) => t.variant === "indeterminate" || t.variant === "query",
    style: {
      width: "auto"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.variant === "indeterminate" || t.variant === "query",
    style: kJ || {
      animation: `${cd} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite`
    }
  }]
}))), NJ = de("span", {
  name: "MuiLinearProgress",
  slot: "Bar2",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.bar, t[`barColor${$e(r.color)}`], (r.variant === "indeterminate" || r.variant === "query") && t.bar2Indeterminate, r.variant === "buffer" && t.bar2Buffer];
  }
})(je(({
  theme: e
}) => ({
  width: "100%",
  position: "absolute",
  left: 0,
  bottom: 0,
  top: 0,
  transition: "transform 0.2s linear",
  transformOrigin: "left",
  variants: [...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      "--LinearProgressBar2-barColor": (e.vars || e).palette[t].main
    }
  })), {
    props: ({
      ownerState: t
    }) => t.variant !== "buffer" && t.color !== "inherit",
    style: {
      backgroundColor: "var(--LinearProgressBar2-barColor, currentColor)"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.variant !== "buffer" && t.color === "inherit",
    style: {
      backgroundColor: "currentColor"
    }
  }, {
    props: {
      color: "inherit"
    },
    style: {
      opacity: 0.3
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t,
      variant: "buffer"
    },
    style: {
      backgroundColor: Tp(e, t),
      transition: `transform .${ld}s linear`
    }
  })), {
    props: ({
      ownerState: t
    }) => t.variant === "indeterminate" || t.variant === "query",
    style: {
      width: "auto"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.variant === "indeterminate" || t.variant === "query",
    style: OJ || {
      animation: `${ud} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite`
    }
  }]
}))), D1 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiLinearProgress"
  }), {
    className: o,
    color: a = "primary",
    value: i,
    valueBuffer: s,
    variant: l = "indeterminate",
    ...c
  } = n, u = {
    ...n,
    color: a,
    variant: l
  }, f = IJ(u), d = xf(), p = {}, h = {
    bar1: {},
    bar2: {}
  };
  if ((l === "determinate" || l === "buffer") && i !== void 0) {
    p["aria-valuenow"] = Math.round(i), p["aria-valuemin"] = 0, p["aria-valuemax"] = 100;
    let $ = i - 100;
    d && ($ = -$), h.bar1.transform = `translateX(${$}%)`;
  }
  if (l === "buffer" && s !== void 0) {
    let $ = (s || 0) - 100;
    d && ($ = -$), h.bar2.transform = `translateX(${$}%)`;
  }
  return /* @__PURE__ */ ue(RJ, {
    className: Ee(f.root, o),
    ownerState: u,
    role: "progressbar",
    ...p,
    ref: r,
    ...c,
    children: [l === "buffer" ? /* @__PURE__ */ P(TJ, {
      className: f.dashed,
      ownerState: u
    }) : null, /* @__PURE__ */ P(MJ, {
      className: f.bar1,
      ownerState: u,
      style: h.bar1
    }), l === "determinate" ? null : /* @__PURE__ */ P(NJ, {
      className: f.bar2,
      ownerState: u,
      style: h.bar2
    })]
  });
});
function FJ(e) {
  return Be("MuiCircularProgress", e);
}
De("MuiCircularProgress", ["root", "determinate", "indeterminate", "colorPrimary", "colorSecondary", "svg", "circle", "circleDeterminate", "circleIndeterminate", "circleDisableShrink"]);
const Yn = 44, fd = fo`
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
`, pd = fo`
  0% {
    stroke-dasharray: 1px, 200px;
    stroke-dashoffset: 0;
  }

  50% {
    stroke-dasharray: 100px, 200px;
    stroke-dashoffset: -15px;
  }

  100% {
    stroke-dasharray: 100px, 200px;
    stroke-dashoffset: -125px;
  }
`, jJ = typeof fd != "string" ? qa`
        animation: ${fd} 1.4s linear infinite;
      ` : null, DJ = typeof pd != "string" ? qa`
        animation: ${pd} 1.4s ease-in-out infinite;
      ` : null, LJ = (e) => {
  const {
    classes: t,
    variant: r,
    color: n,
    disableShrink: o
  } = e, a = {
    root: ["root", r, `color${$e(n)}`],
    svg: ["svg"],
    circle: ["circle", `circle${$e(r)}`, o && "circleDisableShrink"]
  };
  return ze(a, FJ, t);
}, BJ = de("span", {
  name: "MuiCircularProgress",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[r.variant], t[`color${$e(r.color)}`]];
  }
})(je(({
  theme: e
}) => ({
  display: "inline-block",
  variants: [{
    props: {
      variant: "determinate"
    },
    style: {
      transition: e.transitions.create("transform")
    }
  }, {
    props: {
      variant: "indeterminate"
    },
    style: jJ || {
      animation: `${fd} 1.4s linear infinite`
    }
  }, ...Object.entries(e.palette).filter(zt()).map(([t]) => ({
    props: {
      color: t
    },
    style: {
      color: (e.vars || e).palette[t].main
    }
  }))]
}))), zJ = de("svg", {
  name: "MuiCircularProgress",
  slot: "Svg",
  overridesResolver: (e, t) => t.svg
})({
  display: "block"
  // Keeps the progress centered
}), UJ = de("circle", {
  name: "MuiCircularProgress",
  slot: "Circle",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.circle, t[`circle${$e(r.variant)}`], r.disableShrink && t.circleDisableShrink];
  }
})(je(({
  theme: e
}) => ({
  stroke: "currentColor",
  variants: [{
    props: {
      variant: "determinate"
    },
    style: {
      transition: e.transitions.create("stroke-dashoffset")
    }
  }, {
    props: {
      variant: "indeterminate"
    },
    style: {
      // Some default value that looks fine waiting for the animation to kicks in.
      strokeDasharray: "80px, 200px",
      strokeDashoffset: 0
      // Add the unit to fix a Edge 16 and below bug.
    }
  }, {
    props: ({
      ownerState: t
    }) => t.variant === "indeterminate" && !t.disableShrink,
    style: DJ || {
      // At runtime for Pigment CSS, `bufferAnimation` will be null and the generated keyframe will be used.
      animation: `${pd} 1.4s ease-in-out infinite`
    }
  }]
}))), L1 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCircularProgress"
  }), {
    className: o,
    color: a = "primary",
    disableShrink: i = !1,
    size: s = 40,
    style: l,
    thickness: c = 3.6,
    value: u = 0,
    variant: f = "indeterminate",
    ...d
  } = n, p = {
    ...n,
    color: a,
    disableShrink: i,
    size: s,
    thickness: c,
    value: u,
    variant: f
  }, h = LJ(p), $ = {}, b = {}, g = {};
  if (f === "determinate") {
    const y = 2 * Math.PI * ((Yn - c) / 2);
    $.strokeDasharray = y.toFixed(3), g["aria-valuenow"] = Math.round(u), $.strokeDashoffset = `${((100 - u) / 100 * y).toFixed(3)}px`, b.transform = "rotate(-90deg)";
  }
  return /* @__PURE__ */ P(BJ, {
    className: Ee(h.root, o),
    style: {
      width: s,
      height: s,
      ...b,
      ...l
    },
    ownerState: p,
    ref: r,
    role: "progressbar",
    ...g,
    ...d,
    children: /* @__PURE__ */ P(zJ, {
      className: h.svg,
      ownerState: p,
      viewBox: `${Yn / 2} ${Yn / 2} ${Yn} ${Yn}`,
      children: /* @__PURE__ */ P(UJ, {
        className: h.circle,
        style: $,
        ownerState: p,
        cx: Yn,
        cy: Yn,
        r: (Yn - c) / 2,
        fill: "none",
        strokeWidth: c
      })
    })
  });
});
var VJ = Object.defineProperty, qJ = (e, t, r) => t in e ? VJ(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, Ae = (e, t, r) => qJ(e, typeof t != "symbol" ? t + "" : t, r), sn = {}, qs = {}, ry = {}, ny;
function B1() {
  return ny || (ny = 1, function(e) {
    Object.defineProperty(e, "__esModule", { value: !0 }), function(t) {
      t[t.DISABLE = 0] = "DISABLE", t[t.ENABLE = 1] = "ENABLE", t[t.LOGGING = 2] = "LOGGING";
    }(e.OperationMode || (e.OperationMode = {})), function(t) {
      t[t.CASE_STRICT = 1] = "CASE_STRICT", t[t.CASE_INSENSITIVE = 2] = "CASE_INSENSITIVE";
    }(e.PropertyMatchingRule || (e.PropertyMatchingRule = {})), function(t) {
      t[t.ALLOW_NULL = 1] = "ALLOW_NULL", t[t.ALLOW_OBJECT_NULL = 2] = "ALLOW_OBJECT_NULL", t[t.DISALLOW_NULL = 3] = "DISALLOW_NULL";
    }(e.ValueCheckingMode || (e.ValueCheckingMode = {}));
  }(ry)), ry;
}
var pi = {}, oy;
function z1() {
  if (oy) return pi;
  oy = 1, Object.defineProperty(pi, "__esModule", { value: !0 });
  var e = (
    /** @class */
    function() {
      function r() {
      }
      return r.MAPPING_PROPERTY = "__jsonconvert__mapping__", r.MAPPER_PROPERTY = "__jsonconvert__mapper__", r.CLASS_IDENTIFIER = "__jsonconvert__class_identifier__", r;
    }()
  );
  pi.Settings = e;
  var t = (
    /** @class */
    /* @__PURE__ */ function() {
      function r() {
        this.classPropertyName = "", this.jsonPropertyName = "", this.expectedJsonType = void 0, this.isOptional = !1, this.customConverter = null;
      }
      return r;
    }()
  );
  return pi.MappingOptions = t, pi;
}
var Ws = {}, ay;
function Mp() {
  if (ay) return Ws;
  ay = 1, Object.defineProperty(Ws, "__esModule", { value: !0 });
  var e = (
    /** @class */
    /* @__PURE__ */ function() {
      function t() {
      }
      return t;
    }()
  );
  return Ws.Any = e, Ws;
}
var iy;
function WJ() {
  if (iy) return qs;
  iy = 1, Object.defineProperty(qs, "__esModule", { value: !0 });
  var e = B1(), t = z1(), r = Mp(), n = (
    /** @class */
    function() {
      function o(a, i, s, l) {
        this._operationMode = e.OperationMode.ENABLE, this._valueCheckingMode = e.ValueCheckingMode.ALLOW_OBJECT_NULL, this._ignorePrimitiveChecks = !1, this._propertyMatchingRule = e.PropertyMatchingRule.CASE_STRICT, this._ignoreRequiredCheck = !1, a !== void 0 && a in e.OperationMode && (this.operationMode = a), i !== void 0 && i in e.ValueCheckingMode && (this.valueCheckingMode = i), s !== void 0 && (this.ignorePrimitiveChecks = s), l !== void 0 && (this.propertyMatchingRule = l);
      }
      return Object.defineProperty(o.prototype, "operationMode", {
        /**
         * Determines how the JsonConvert class instance should operate.
         *
         * You may assign three different values:
         * - OperationMode.DISABLE: json2typescript will be disabled, no type checking or mapping is done
         * - OperationMode.ENABLE: json2typescript is enabled, but only errors are logged
         * - OperationMode.LOGGING: json2typescript is enabled and detailed information is logged
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        get: function() {
          return this._operationMode;
        },
        /**
         * Determines how the JsonConvert class instance should operate.
         *
         * You may assign three different values:
         * - OperationMode.DISABLE: json2typescript will be disabled, no type checking or mapping is done
         * - OperationMode.ENABLE: json2typescript is enabled, but only errors are logged
         * - OperationMode.LOGGING: json2typescript is enabled and detailed information is logged
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        set: function(a) {
          a in e.OperationMode && (this._operationMode = a);
        },
        enumerable: !0,
        configurable: !0
      }), Object.defineProperty(o.prototype, "valueCheckingMode", {
        /**
         * Determines which types are allowed to be null.
         *
         * You may assign three different values:
         * - ValueCheckingMode.ALLOW_NULL: all given values in the JSON are allowed to be null
         * - ValueCheckingMode.ALLOW_OBJECT_NULL: objects in the JSON are allowed to be null, primitive types are not allowed to be null
         * - ValueCheckingMode.DISALLOW_NULL: no null values are tolerated in the JSON
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        get: function() {
          return this._valueCheckingMode;
        },
        /**
         * Determines which types are allowed to be null.
         *
         * You may assign three different values:
         * - ValueCheckingMode.ALLOW_NULL: all given values in the JSON are allowed to be null
         * - ValueCheckingMode.ALLOW_OBJECT_NULL: objects in the JSON are allowed to be null, primitive types are not allowed to be null
         * - ValueCheckingMode.DISALLOW_NULL: no null values are tolerated in the JSON
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        set: function(a) {
          a in e.ValueCheckingMode && (this._valueCheckingMode = a);
        },
        enumerable: !0,
        configurable: !0
      }), Object.defineProperty(o.prototype, "ignorePrimitiveChecks", {
        /**
         * Determines whether primitive types should be checked.
         * If true, it will be allowed to assign primitive to other primitive types.
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        get: function() {
          return this._ignorePrimitiveChecks;
        },
        /**
         * Determines whether primitive types should be checked.
         * If true, it will be allowed to assign primitive to other primitive types.
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        set: function(a) {
          this._ignorePrimitiveChecks = a;
        },
        enumerable: !0,
        configurable: !0
      }), Object.defineProperty(o.prototype, "propertyMatchingRule", {
        /**
         * Determines the rule of how JSON properties shall be matched with class properties during deserialization.
         *
         * You may assign the following values:
         * - PropertyMatchingRule.CASE_STRICT: JSON properties need to match exactly the names in the decorators
         * - PropertyMatchingRule.CASE_INSENSITIVE: JSON properties need to match names in the decorators, but names they are not case sensitive
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        get: function() {
          return this._propertyMatchingRule;
        },
        /**
         * Determines the rule of how JSON properties shall be matched with class properties during deserialization.
         *
         * You may assign the following values:
         * - PropertyMatchingRule.CASE_STRICT: JSON properties need to match exactly the names in the decorators
         * - PropertyMatchingRule.CASE_INSENSITIVE: JSON properties need to match names in the decorators, but names they are not case sensitive
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        set: function(a) {
          a in e.PropertyMatchingRule && (this._propertyMatchingRule = a);
        },
        enumerable: !0,
        configurable: !0
      }), Object.defineProperty(o.prototype, "ignoreRequiredCheck", {
        /**
         * Determines whether the check for "required" properties should be ignored, making all
         * mapped values optional, whether or not the isOptional property mapping parameter is set.
         * If true, any missing properties (undefined) when serializing or deserializing will be
         * ignored, as if they were marked optional.
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        get: function() {
          return this._ignoreRequiredCheck;
        },
        /**
         * Determines whether the check for "required" properties should be ignored, making all
         * mapped values optional, whether or not the isOptional property mapping parameter is set.
         * If true, any missing properties (undefined) when serializing or deserializing will be
         * ignored, as if they were marked optional.
         *
         * @see https://www.npmjs.com/package/json2typescript full documentation
         */
        set: function(a) {
          this._ignoreRequiredCheck = a;
        },
        enumerable: !0,
        configurable: !0
      }), o.prototype.serialize = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a instanceof Array)
          return this.serializeArray(a, i);
        if (typeof a == "object")
          return this.serializeObject(a, i);
        throw new Error(`Fatal error in JsonConvert. Passed parameter data in JsonConvert.serialize() is not in valid format (object or array).
`);
      }, o.prototype.serializeObject = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a === void 0)
          throw new Error(`Fatal error in JsonConvert. Passed parameter instance in JsonConvert.serializeObject() is undefined. This is not a valid JSON format.
`);
        if (a === null) {
          if (this.valueCheckingMode === e.ValueCheckingMode.DISALLOW_NULL)
            throw new Error(`Fatal error in JsonConvert. Passed parameter instance in JsonConvert.serializeObject() is undefined. You have specified to disallow null values.
`);
          return a;
        } else if (typeof a != "object" || a instanceof Array)
          throw new Error(`Fatal error in JsonConvert. Passed parameter instance in JsonConvert.serializeObject() is not of type object.
`);
        this.operationMode === e.OperationMode.LOGGING && (console.log("----------"), console.log("Receiving JavaScript instance:"), console.log(a));
        var s = {}, l;
        i ? l = new i() : l = a;
        for (var c = 0, u = Object.keys(l); c < u.length; c++) {
          var f = u[c];
          try {
            this.serializeObject_loopProperty(a, l, f, s);
          } catch (d) {
            throw this.operationMode === e.OperationMode.LOGGING && (console.log("Failed to serialize property:"), console.log(d), console.log("----------")), d;
          }
        }
        return this.operationMode === e.OperationMode.LOGGING && (console.log("Returning JSON object:"), console.log(s), console.log("----------")), s;
      }, o.prototype.serializeArray = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a === void 0)
          throw new Error(`Fatal error in JsonConvert. Passed parameter instanceArray in JsonConvert.serializeArray() is undefined. This is not a valid JSON format.
`);
        if (a === null) {
          if (this.valueCheckingMode === e.ValueCheckingMode.DISALLOW_NULL)
            throw new Error(`Fatal error in JsonConvert. Passed parameter instanceArray in JsonConvert.serializeArray() is undefined. You have specified to disallow null values.
`);
          return a;
        } else if (typeof a != "object" || !(a instanceof Array))
          throw new Error(`Fatal error in JsonConvert. Passed parameter instanceArray in JsonConvert.serializeArray() is not of type array.
`);
        this.operationMode === e.OperationMode.LOGGING && (console.log("----------"), console.log("Receiving JavaScript array:"), console.log(a));
        for (var s = [], l = 0, c = a; l < c.length; l++) {
          var u = c[l];
          s.push(this.serializeObject(u, i));
        }
        return this.operationMode === e.OperationMode.LOGGING && (console.log("Returning JSON array:"), console.log(s), console.log("----------")), s;
      }, o.prototype.deserialize = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a instanceof Array)
          return this.deserializeArray(a, i);
        if (typeof a == "object")
          return this.deserializeObject(a, i);
        throw new Error(`Fatal error in JsonConvert. Passed parameter json in JsonConvert.deserialize() is not in valid JSON format (object or array).
`);
      }, o.prototype.deserializeObject = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a === void 0)
          throw new Error(`Fatal error in JsonConvert. Passed parameter jsonObject in JsonConvert.deserializeObject() is undefined. This is not a valid JSON format.
`);
        if (a === null) {
          if (this.valueCheckingMode === e.ValueCheckingMode.DISALLOW_NULL)
            throw new Error(`Fatal error in JsonConvert. Passed parameter jsonObject in JsonConvert.deserializeObject() is undefined. You have specified to disallow null values.
`);
          return a;
        } else if (typeof a != "object" || a instanceof Array)
          throw new Error(`Fatal error in JsonConvert. Passed parameter jsonObject in JsonConvert.deserializeObject() is not of type object.
`);
        this.operationMode === e.OperationMode.LOGGING && (console.log("----------"), console.log("Receiving JSON object:"), console.log(a));
        for (var s = new i(), l = 0, c = Object.keys(s); l < c.length; l++) {
          var u = c[l];
          try {
            this.deserializeObject_loopProperty(s, u, a);
          } catch (f) {
            throw this.operationMode === e.OperationMode.LOGGING && (console.log("Failed to deserialize property:"), console.log(f), console.log("----------")), f;
          }
        }
        return this.operationMode === e.OperationMode.LOGGING && (console.log("Returning CLASS instance:"), console.log(s), console.log("----------")), s;
      }, o.prototype.deserializeArray = function(a, i) {
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        if (a === void 0)
          throw new Error(`Fatal error in JsonConvert. Passed parameter jsonArray in JsonConvert.deserializeObject() is undefined. This is not a valid JSON format.
`);
        if (a === null) {
          if (this.valueCheckingMode === e.ValueCheckingMode.DISALLOW_NULL)
            throw new Error(`Fatal error in JsonConvert. Passed parameter jsonArray in JsonConvert.deserializeObject() is undefined. You have specified to disallow null values.
`);
          return a;
        } else if (typeof a != "object" || !(a instanceof Array))
          throw new Error(`Fatal error in JsonConvert. Passed parameter jsonArray in JsonConvert.deserializeArray() is not of type array.
`);
        if (this.operationMode === e.OperationMode.DISABLE)
          return a;
        this.operationMode === e.OperationMode.LOGGING && (console.log("----------"), console.log("Receiving JSON array:"), console.log(a));
        for (var s = [], l = 0, c = a; l < c.length; l++) {
          var u = c[l];
          s.push(this.deserializeObject(u, i));
        }
        return this.operationMode === e.OperationMode.LOGGING && (console.log("Returning array of CLASS instances:"), console.log(s), console.log("----------")), s;
      }, o.prototype.serializeObject_loopProperty = function(a, i, s, l) {
        var c = this.getClassPropertyMappingOptions(i, s);
        if (c !== null) {
          var u = c.jsonPropertyName, f = c.expectedJsonType, d = c.isOptional, p = c.customConverter, h = a[s];
          if (typeof h > "u") {
            if (d || this._ignoreRequiredCheck)
              return;
            throw new Error('Fatal error in JsonConvert. Failed to map the JavaScript instance of class "' + i[t.Settings.CLASS_IDENTIFIER] + '" to JSON because the defined class property "' + s + `" does not exist or is not defined:

	Class property: 
		` + s + `

	JSON property: 
		` + u + `

`);
          }
          if (!(d && h === null))
            try {
              l[u] = p !== null ? p.serialize(h) : this.verifyProperty(f, h, !0);
            } catch ($) {
              throw new Error('Fatal error in JsonConvert. Failed to map the JavaScript instance of class "' + i[t.Settings.CLASS_IDENTIFIER] + `" to JSON because of a type error.

	Class property: 
		` + s + `

	Class property value: 
		` + h + `

	Expected type: 
		` + this.getExpectedType(f) + `

	Runtime type: 
		` + this.getTrueType(h) + `

	JSON property: 
		` + u + `

` + $.message + `
`);
            }
        }
      }, o.prototype.deserializeObject_loopProperty = function(a, i, s) {
        var l = this.getClassPropertyMappingOptions(a, i);
        if (l !== null) {
          var c = l.jsonPropertyName, u = l.expectedJsonType, f = l.isOptional, d = l.customConverter, p = void 0;
          try {
            p = this.getObjectValue(s, c);
          } catch {
          }
          if (typeof p > "u") {
            if (f || this._ignoreRequiredCheck)
              return;
            throw new Error('Fatal error in JsonConvert. Failed to map the JSON object to the class "' + a[t.Settings.CLASS_IDENTIFIER] + '" because the defined JSON property "' + c + `" does not exist:

	Class property: 
		` + i + `

	JSON property: 
		` + c + `

`);
          }
          if (!(f && p === null))
            try {
              a[i] = d !== null ? d.deserialize(p) : this.verifyProperty(u, p);
            } catch (h) {
              throw new Error('Fatal error in JsonConvert. Failed to map the JSON object to the class "' + a[t.Settings.CLASS_IDENTIFIER] + `" because of a type error.

	Class property: 
		` + i + `

	Expected type: 
		` + this.getExpectedType(u) + `

	JSON property: 
		` + c + `

	JSON type: 
		` + this.getJsonType(p) + `

	JSON value: 
		` + JSON.stringify(p) + `

` + h.message + `
`);
            }
        }
      }, o.prototype.getClassPropertyMappingOptions = function(a, i) {
        var s = a[t.Settings.MAPPING_PROPERTY];
        if (typeof s > "u")
          return null;
        for (var l = Object.getPrototypeOf(a); l != null; ) {
          var c = l[t.Settings.CLASS_IDENTIFIER];
          if (c) {
            var u = c + "." + i;
            if (typeof s[u] < "u")
              return s[u];
          }
          l = Object.getPrototypeOf(l);
        }
        return null;
      }, o.prototype.verifyProperty = function(a, i, s) {
        if (a === r.Any || a === null || a === Object)
          return i;
        if (!(a instanceof Array) && !(i instanceof Array))
          if (typeof a < "u" && a.prototype.hasOwnProperty(t.Settings.CLASS_IDENTIFIER)) {
            if (i === null) {
              if (this.valueCheckingMode !== e.ValueCheckingMode.DISALLOW_NULL)
                return null;
              throw new Error("	Reason: Given value is null.");
            }
            return s ? this.serializeObject(i, a) : this.deserializeObject(i, a);
          } else if (a === r.Any || a === null || a === Object) {
            if (i === null) {
              if (this.valueCheckingMode !== e.ValueCheckingMode.DISALLOW_NULL)
                return null;
              throw new Error("	Reason: Given value is null.");
            }
            return i;
          } else if (a === String || a === Number || a === Boolean) {
            if (i === null) {
              if (this.valueCheckingMode === e.ValueCheckingMode.ALLOW_NULL)
                return null;
              throw new Error("	Reason: Given value is null.");
            }
            if (
              // primitive types match
              a === String && typeof i == "string" || a === Number && typeof i == "number" || a === Boolean && typeof i == "boolean" || this.ignorePrimitiveChecks
            )
              return i;
            throw new Error("	Reason: Given object does not match the expected primitive type.");
          } else
            throw new Error(`	Reason: Expected type is unknown. There might be multiple reasons for this:
	- You are missing the decorator @JsonObject (for object mapping)
	- You are missing the decorator @JsonConverter (for custom mapping) before your class definition
	- Your given class is undefined in the decorator because of circular dependencies`);
        if (a instanceof Array && i instanceof Array) {
          var l = [];
          if (i.length === 0)
            return l;
          if (a.length === 0)
            return i;
          for (var c = a.length < i.length, u = 0; u < i.length; u++)
            c && u >= a.length && (a[u] = a[u - 1]), l[u] = this.verifyProperty(a[u], i[u], s);
          return l;
        }
        if (a instanceof Array && i instanceof Object) {
          var l = [];
          if (i.length === 0)
            return l;
          if (a.length === 0)
            return i;
          var c = a.length < Object.keys(i).length, u = 0;
          for (var f in i)
            c && u >= a.length && (a[u] = a[u - 1]), l[f] = this.verifyProperty(a[u], i[f]), u++;
          return l;
        }
        if (a instanceof Array) {
          if (i === null) {
            if (this.valueCheckingMode !== e.ValueCheckingMode.DISALLOW_NULL)
              return null;
            throw new Error("	Reason: Given value is null.");
          }
          throw new Error("	Reason: Expected type is array, but given value is non-array.");
        }
        throw i instanceof Array ? new Error("	Reason: Given value is array, but expected a non-array type.") : new Error("	Reason: Mapping failed because of an unknown error.");
      }, o.prototype.getObjectValue = function(a, i) {
        if (this.propertyMatchingRule === e.PropertyMatchingRule.CASE_INSENSITIVE) {
          var s = Object.keys(a).reduce(function(l, c) {
            return l[c.toLowerCase()] = c, l;
          }, {});
          i = s[i.toLowerCase()];
        }
        if (!(i in a))
          throw new Error();
        return a[i];
      }, o.prototype.getExpectedType = function(a) {
        var i = "";
        if (a instanceof Array) {
          i = "[";
          for (var s = 0; s < a.length; s++)
            s > 0 && (i += ","), i += this.getExpectedType(a[s]);
          return i += "]", i;
        } else
          return a === r.Any || a === null || a === Object ? "any" : a === String || a === Boolean || a === Number ? new a().constructor.name.toLowerCase() : typeof a == "function" ? new a().constructor.name : a === void 0 ? "undefined" : "?????";
      }, o.prototype.getJsonType = function(a) {
        if (a === null)
          return "null";
        var i = "";
        if (a instanceof Array) {
          i = "[";
          for (var s = 0; s < a.length; s++)
            s > 0 && (i += ","), i += this.getJsonType(a[s]);
          return i += "]", i;
        } else
          return typeof a;
      }, o.prototype.getTrueType = function(a) {
        return typeof a;
      }, o;
    }()
  );
  return qs.JsonConvert = n, qs;
}
var ea = {}, sy;
function KJ() {
  if (sy) return ea;
  sy = 1, Object.defineProperty(ea, "__esModule", { value: !0 });
  var e = z1(), t = Mp();
  function r(a) {
    a[e.Settings.MAPPER_PROPERTY] = "";
  }
  ea.JsonConverter = r;
  function n(a) {
    var i = "", s = function(c) {
      c.prototype[e.Settings.CLASS_IDENTIFIER] = i.length > 0 ? i : c.name;
      var u = c.prototype[e.Settings.MAPPING_PROPERTY];
      if (u)
        for (var f = Object.keys(u).filter(function($) {
          return $.indexOf(e.Settings.CLASS_IDENTIFIER + ".") === 0;
        }), d = 0, p = f; d < p.length; d++) {
          var h = p[d];
          u[h.replace(e.Settings.CLASS_IDENTIFIER, c.prototype[e.Settings.CLASS_IDENTIFIER])] = u[h], delete u[h];
        }
    }, l = typeof a;
    switch (l) {
      case "string":
        return i = a, s;
      case "function":
      case "undefined":
      default:
        throw new Error(`Fatal error in JsonConvert. It is mandatory to pass a string as parameter in the @JsonObject decorator.

Use @JsonObject(classId) where classId is a string.

`);
    }
  }
  ea.JsonObject = n;
  function o() {
    for (var a = [], i = 0; i < arguments.length; i++)
      a[i] = arguments[i];
    return function(s, l) {
      var c = l, u = t.Any, f = !1;
      switch (a.length) {
        case 1:
          if (a[0] === void 0)
            throw new Error(`Fatal error in JsonConvert. It is not allowed to explicitly pass "undefined" as first parameter in the @JsonProperty decorator.

	Class property: 
		` + l + `

Leave the decorator parameters empty if you do not wish to pass the first parameter.

`);
          c = a[0];
          break;
        case 2:
          if (a[0] === void 0)
            throw new Error(`Fatal error in JsonConvert. It is not allowed to explicitly pass "undefined" as first parameter in the @JsonProperty decorator.

	Class property: 
		` + l + `

Leave the decorator parameters empty if you do not wish to pass the first parameter.

`);
          if (a[1] === void 0)
            throw new Error(`Fatal error in JsonConvert. It is not allowed to explicitly pass "undefined" as second parameter in the @JsonProperty decorator.

	Class property: 
		` + l + `

Use "Any" to allow any type. You can import this class from "json2typescript".

`);
          c = a[0], u = a[1];
          break;
        case 3:
          if (a[0] === void 0)
            throw new Error(`Fatal error in JsonConvert. It is not allowed to explicitly pass "undefined" as first parameter in the @JsonProperty decorator.

	Class property: 
		` + l + `

Leave the decorator parameters empty if you do not wish to pass the first parameter.

`);
          if (a[1] === void 0)
            throw new Error(`Fatal error in JsonConvert. It is not allowed to explicitly pass "undefined" as second parameter in the @JsonProperty decorator.

	Class property: 
		` + l + `

Use "Any" to allow any type. You can import this class from "json2typescript".

`);
          c = a[0], u = a[1], f = a[2];
          break;
      }
      typeof s[e.Settings.MAPPING_PROPERTY] > "u" && (s[e.Settings.MAPPING_PROPERTY] = []);
      var d = new e.MappingOptions();
      if (d.classPropertyName = l, d.jsonPropertyName = c, d.isOptional = f || !1, typeof u < "u" && u !== null && typeof u[e.Settings.MAPPER_PROPERTY] < "u" ? d.customConverter = new u() : d.expectedJsonType = u, typeof s[e.Settings.MAPPING_PROPERTY][e.Settings.CLASS_IDENTIFIER + "." + l] > "u")
        s[e.Settings.MAPPING_PROPERTY][e.Settings.CLASS_IDENTIFIER + "." + l] = d;
      else
        throw new Error(`Fatal error in JsonConvert. It is not allowed to add multiple decorators for the same property.

	Class property: 
		` + l + `

`);
    };
  }
  return ea.JsonProperty = o, ea;
}
var ly;
function GJ() {
  if (ly) return sn;
  ly = 1, Object.defineProperty(sn, "__esModule", { value: !0 });
  var e = WJ();
  sn.JsonConvert = e.JsonConvert;
  var t = B1();
  sn.ValueCheckingMode = t.ValueCheckingMode, sn.OperationMode = t.OperationMode;
  var r = KJ();
  sn.JsonObject = r.JsonObject, sn.JsonProperty = r.JsonProperty, sn.JsonConverter = r.JsonConverter;
  var n = Mp();
  return sn.Any = n.Any, sn;
}
var Xe = GJ(), HJ = Object.defineProperty, JJ = Object.getOwnPropertyDescriptor, tt = (e, t, r, n) => {
  for (var o = n > 1 ? void 0 : n ? JJ(t, r) : t, a = e.length - 1, i; a >= 0; a--)
    (i = e[a]) && (o = (n ? i(t, r, o) : i(o)) || o);
  return n && o && HJ(t, r, o), o;
}, oa = /* @__PURE__ */ ((e) => (e.Ping = "ping", e.Pong = "pong", e.Info = "info", e.ApiInfo = "api_info", e.Request = "request", e.Response = "response", e.Log = "log", e.Progress = "progress", e))(oa || {}), hd = /* @__PURE__ */ ((e) => (e.ResponseTopic = "response_topic", e.RequestContext = "requestContext", e.RequestMessageId = "requestMessageId", e.MessageType = "messageType", e.SourceTopic = "source_topic", e.Fragment = "fragment", e.NumFragments = "num_fragments", e.Status = "status", e))(hd || {}), pa = /* @__PURE__ */ ((e) => (e.Success = "success", e.Error = "error", e.Running = "running", e))(pa || {});
let $r = class {
  constructor() {
    Ae(this, "payload", ""), Ae(this, "context", ""), Ae(this, "properties");
  }
  static createMessage(e) {
    const t = new $r();
    return t.properties = {}, t.properties.messageType = e, t;
  }
  /** Shortcut to create a request message
   *
   * This static method creates a :class:`DASFModuleRequest` with the
   * :ref:`MessageType` `MessageType.Request`
   *
   * @param data - Optional data as javascript object that will be
   * json-serialized and added as :attr:`payload` to the request.
   *
   * @returns The :class:`DASFModuleRequest` of type `MessageType.Request`
   */
  static createRequestMessage(e) {
    const t = $r.createMessage(
      "request"
      /* Request */
    );
    return typeof e < "u" && (t.payload = btoa(JSON.stringify(e))), t;
  }
  /** Shortcut to create a Ping message
   *
   * This static method creates a :class:`DASFModuleRequest` with the
   * :ref:`MessageType` `MessageType.Ping`
   *
   * @returns The :class:`DASFModuleRequest` of type `MessageType.Ping`
   */
  static createPingMessage() {
    return $r.createMessage(
      "ping"
      /* Ping */
    );
  }
  /** Shortcut to create a Pong message
   *
   * This static method creates a :class:`DASFModuleRequest` with the
   * :ref:`MessageType` `MessageType.Pong`
   *
   * @returns The :class:`DASFModuleRequest` of type `MessageType.Pong`
   */
  static createPongMessage() {
    return $r.createMessage(
      "pong"
      /* Pong */
    );
  }
  /** Shortcut to create an Info message
   *
   * This static method creates a :class:`DASFModuleRequest` with the
   * :ref:`MessageType` `MessageType.Info` to get the information on the
   * backend module, see also :meth:`DASFConnection.getModuleInfo`
   *
   * @returns The :class:`DASFModuleRequest` of type `MessageType.Info`
   */
  static createInfoMessage() {
    return $r.createMessage(
      "info"
      /* Info */
    );
  }
  /** Shortcut to create an Info message
   *
   * This static method creates a :class:`DASFModuleRequest` with the
   * :ref:`MessageType` `MessageType.Info` to get the information on the
   * backend module, see also :meth:`DASFConnection.getApiInfo`
   *
   * @returns The :class:`DASFModuleRequest` of type `MessageType.ApiInfo`
   */
  static createApiInfoMessage() {
    return $r.createMessage(
      "api_info"
      /* ApiInfo */
    );
  }
  /** Shortcut to the the messagetype of the properties */
  getMessageType() {
    if (this.properties)
      return this.properties.messageType;
    throw new Error("Missing or empty message type property");
  }
};
tt([
  Xe.JsonProperty("payload", String)
], $r.prototype, "payload", 2);
tt([
  Xe.JsonProperty("properties", Xe.Any)
], $r.prototype, "properties", 2);
$r = tt([
  Xe.JsonObject("DASFModuleRequest")
], $r);
let co = class {
  constructor() {
    Ae(this, "result", ""), Ae(this, "messageId", ""), Ae(this, "errorMsg", ""), Ae(this, "context", "");
  }
  isOk() {
    return this.result == "ok";
  }
};
tt([
  Xe.JsonProperty("result", String)
], co.prototype, "result", 2);
tt([
  Xe.JsonProperty("messageId", String, !0)
], co.prototype, "messageId", 2);
tt([
  Xe.JsonProperty("errorMsg", String, !0)
], co.prototype, "errorMsg", 2);
tt([
  Xe.JsonProperty("context", String, !0)
], co.prototype, "context", 2);
co = tt([
  Xe.JsonObject("DASFModuleRequestReceipt")
], co);
let Tl = class {
  constructor(e) {
    Ae(this, "messageId", ""), e && (this.messageId = e);
  }
};
tt([
  Xe.JsonProperty("messageId", String)
], Tl.prototype, "messageId", 2);
Tl = tt([
  Xe.JsonObject("DASFAcknowledgment")
], Tl);
let Io = class {
  constructor() {
    Ae(this, "messageId", ""), Ae(this, "payload", ""), Ae(this, "publishTime", ""), Ae(this, "properties");
  }
  /** Shortcut to the the messagetype of the properties */
  getMessageType() {
    if (this.properties) {
      const e = this.properties.messageType;
      if (e && e.trim().length > 0)
        return e;
    }
    throw new Error("Missing or empty message type property");
  }
  /** Shortcut to the the request context of the properties */
  getRequestContext() {
    if (this.properties) {
      const e = this.properties.requestContext;
      if (e)
        return e;
    }
    throw new Error("Missing or empty request context property");
  }
  /** Get the original id of the request */
  getRequestMessageId() {
    if (this.properties) {
      const e = this.properties.requestMessageId;
      if (e)
        return e;
    }
    throw new Error("Missing or empty request messageId property");
  }
  /** Check if the response is fragmented or not. */
  isFragmented() {
    return this.properties != null && Object.prototype.hasOwnProperty.call(
      this.properties,
      "num_fragments"
      /* NumFragments */
    ) && Object.prototype.hasOwnProperty.call(
      this.properties,
      "fragment"
      /* Fragment */
    );
  }
  /** Get the id of this fragment. */
  getFragmentId() {
    if (this.properties && this.isFragmented())
      return this.properties.fragment;
    throw new Error(
      "Unable to request fragment id from unfragmented response."
    );
  }
  /** Get the total number of fragments */
  getNumberOfFragments() {
    if (this.properties && this.isFragmented())
      return this.properties.num_fragments;
    throw new Error(
      "Unable to request number of fragments from unfragmented response."
    );
  }
};
tt([
  Xe.JsonProperty("messageId", String)
], Io.prototype, "messageId", 2);
tt([
  Xe.JsonProperty("payload", String)
], Io.prototype, "payload", 2);
tt([
  Xe.JsonProperty("publishTime", String)
], Io.prototype, "publishTime", 2);
tt([
  Xe.JsonProperty("properties")
], Io.prototype, "properties", 2);
Io = tt([
  Xe.JsonObject("DASFModuleResponse")
], Io);
let vn = class {
  constructor() {
    Ae(this, "report_type", ""), Ae(this, "report_id", ""), Ae(this, "step_message", ""), Ae(this, "steps", 0), Ae(this, "status", "running"), Ae(this, "children");
  }
  hasError() {
    return this.status == "error";
  }
  hasSuccess() {
    return this.status == "success";
  }
  isRunning() {
    return this.status == "running";
  }
  isComplete() {
    return !this.isRunning();
  }
};
tt([
  Xe.JsonProperty("report_type", String)
], vn.prototype, "report_type", 2);
tt([
  Xe.JsonProperty("report_id", String)
], vn.prototype, "report_id", 2);
tt([
  Xe.JsonProperty("step_message", String)
], vn.prototype, "step_message", 2);
tt([
  Xe.JsonProperty("steps", Number)
], vn.prototype, "steps", 2);
tt([
  Xe.JsonProperty("status", String)
], vn.prototype, "status", 2);
tt([
  Xe.JsonProperty("children", [vn])
], vn.prototype, "children", 2);
vn = tt([
  Xe.JsonObject("DASFProgressReport")
], vn);
let Pa = class {
  // dummy JsonSchemaConverter to make sure the json2typescript library does
  // not complain
  serialize(e) {
    return JSON.stringify(e);
  }
  deserialize(e) {
    return e;
  }
};
Pa = tt([
  Xe.JsonConverter
], Pa);
let Ro = class {
  constructor() {
    Ae(this, "name", ""), Ae(this, "rpcSchema", {}), Ae(this, "returnSchema", {});
  }
};
tt([
  Xe.JsonProperty("name", String)
], Ro.prototype, "name", 2);
tt([
  Xe.JsonProperty("rpc_schema", Pa)
], Ro.prototype, "rpcSchema", 2);
tt([
  Xe.JsonProperty("return_schema", Pa)
], Ro.prototype, "returnSchema", 2);
Ro = tt([
  Xe.JsonObject("FunctionApiInfo")
], Ro);
let To = class {
  constructor() {
    Ae(this, "name", ""), Ae(this, "rpcSchema", {}), Ae(this, "methods", []);
  }
};
tt([
  Xe.JsonProperty("name", String)
], To.prototype, "name", 2);
tt([
  Xe.JsonProperty("rpc_schema", Pa)
], To.prototype, "rpcSchema", 2);
tt([
  Xe.JsonProperty("methods", [Ro])
], To.prototype, "methods", 2);
To = tt([
  Xe.JsonObject("ClassApiInfo")
], To);
let Mo = class {
  constructor() {
    Ae(this, "classes", []), Ae(this, "functions", []), Ae(this, "rpcSchema", {});
  }
};
tt([
  Xe.JsonProperty("classes", [To])
], Mo.prototype, "classes", 2);
tt([
  Xe.JsonProperty("functions", [Ro])
], Mo.prototype, "functions", 2);
tt([
  Xe.JsonProperty("rpc_schema", Pa)
], Mo.prototype, "rpcSchema", 2);
Mo = tt([
  Xe.JsonObject("ModuleApiInfo")
], Mo);
class YJ {
  /**
   * @param urlBuilder - A builder for the consumer and producer websocket url
   * @param onConnectionError - A callback for the case when no connection could be established
   */
  constructor(t, r) {
    Ae(this, "outgoingChannel"), Ae(this, "incomingChannel"), Ae(this, "DASFProducerURL"), Ae(this, "DASFConsumerURL"), Ae(this, "consumeTopic"), Ae(this, "jsonCoder"), Ae(this, "contextCounter", 0), Ae(this, "responseResolvers", /* @__PURE__ */ new Map()), Ae(this, "progressCallbacks", /* @__PURE__ */ new Map()), Ae(this, "responseRejectHandler", /* @__PURE__ */ new Map()), Ae(this, "finishedContexts", /* @__PURE__ */ new Set()), Ae(this, "contextResponseFragments", /* @__PURE__ */ new Map()), Ae(this, "pendingRequests", []), Ae(this, "waitingForPong", !1), Ae(this, "connectionTimeout", 1e4), Ae(this, "connectionError", ""), Ae(this, "onConnectionError"), Ae(this, "startedReconnectOutgoing", !0), Ae(this, "startedReconnectIncoming", !0), this.onConnectionError = r, this.consumeTopic = t.consumeTopic, this.DASFProducerURL = t.DASFProducerURL, this.DASFConsumerURL = t.DASFConsumerURL, this.jsonCoder = new Xe.JsonConvert(), this.connect(), setInterval(() => this.checkConnection(), this.connectionTimeout);
  }
  connect() {
    this.startedReconnectIncoming = !0, this.startedReconnectOutgoing = !0, this.outgoingChannel = new WebSocket(this.DASFProducerURL), this.incomingChannel = new WebSocket(this.DASFConsumerURL), this.registerListener();
  }
  isConnected() {
    return this.outgoingChannel && this.incomingChannel && this.outgoingChannel.readyState == WebSocket.OPEN && this.incomingChannel.readyState == WebSocket.OPEN;
  }
  isConnecting() {
    return this.outgoingChannel && this.incomingChannel && this.outgoingChannel.readyState != WebSocket.OPEN && this.incomingChannel.readyState != WebSocket.OPEN;
  }
  /**
   * Do something as soon as the websocket connection has been established
   *
   * This property returns a promise that resolves with the established
   * connection. You can use this to do something right after the connection has
   * been created.
   *
   * ```
   * import { DASFConnection, WebsocketUrlBuilder } from '@dasf/dasf-messaging'
   * const connection = new DASFConnection(
   *     new WebsocketUrlBuilder(
   *         'ws://localhost:8080/ws',
   *         'some-topic'
   *     )
   * )
   *
   * // log to the console when the connection has been connected
   * connection.connected.then(
   *     (connection: DASFConnection) => console.log("Websocket connection has been established.")
   * ).catch(
   *     (error: Error) => console.log(error)
   * )
   * ```
   *
   *
   */
  get connected() {
    const t = (r, n) => {
      this.hasConnectionError() ? n(new Error(this.connectionError)) : this.assureConnected() ? r(this) : setTimeout(() => t(r, n), 100);
    };
    return new Promise(t);
  }
  assureConnected() {
    return this.isConnected() ? !0 : (this.startedReconnectIncoming || this.startedReconnectOutgoing || this.isConnecting() || this.connect(), !1);
  }
  hasPendingRequests() {
    return this.pendingRequests.length > 0;
  }
  sendPendingRequests() {
    if (this.hasPendingRequests()) {
      const t = this.pendingRequests.shift();
      this.outgoingChannel.send(JSON.stringify(t)), setTimeout(() => this.sendPendingRequests(), 200);
    }
  }
  registerListener() {
    const t = (r) => {
      this.startedReconnectOutgoing = !1, this.startedReconnectIncoming = !1, !this.hasConnectionError() && this.isConnecting() && (this.connectionError = "Connection to " + r.target.url + " failed.", this.onConnectionError && this.onConnectionError(this.connectionError));
    };
    this.outgoingChannel.addEventListener("error", t), this.incomingChannel.addEventListener("error", t), this.outgoingChannel.addEventListener("open", () => {
      this.startedReconnectOutgoing = !1, this.connectionError = "", this.outgoingChannel.addEventListener("message", (r) => {
        const n = this.jsonCoder.deserializeObject(
          JSON.parse(r.data),
          co
        );
        if (n.isOk())
          this.responseRejectHandler.delete(n.context);
        else {
          console.error(n), this.responseResolvers.delete(n.context);
          const o = this.responseRejectHandler.get(
            n.context
          );
          o ? (this.responseRejectHandler.delete(n.context), o(n)) : console.error(
            "received error receipt for an unknwon context: " + n.context
          );
        }
      });
    }), this.incomingChannel.addEventListener("open", () => {
      this.startedReconnectIncoming = !1, this.connectionError = "", this.incomingChannel.addEventListener("message", (r) => {
        try {
          const n = JSON.parse(r.data), o = this.jsonCoder.deserializeObject(
            n,
            Io
          );
          this.acknowledgeMessage(o);
          const a = o.getRequestContext();
          if (this.finishedContexts.has(a))
            return;
          if (o.getMessageType() == oa.Progress) {
            const i = this.jsonCoder.deserializeObject(
              JSON.parse(atob(n.payload)),
              vn
            ), s = this.progressCallbacks.get(a);
            s && s({
              message: i,
              props: o.properties
            });
          } else {
            if (o.isFragmented())
              if (this.contextResponseFragments.has(a)) {
                let s = this.contextResponseFragments.get(a);
                if (s)
                  if (s.push(o), s.length == o.getNumberOfFragments()) {
                    s = s.sort(
                      (c, u) => c.getFragmentId() - u.getFragmentId()
                    );
                    let l = "";
                    for (const c of s)
                      l += c.payload;
                    o.payload = l, this.contextResponseFragments.delete(a);
                  } else
                    return;
              } else {
                this.contextResponseFragments.set(a, [o]);
                return;
              }
            const i = this.responseResolvers.get(a);
            i ? (this.responseResolvers.delete(a), this.progressCallbacks.delete(a), this.responseRejectHandler.delete(a), this.finishedContexts.add(a), i(o)) : console.warn(
              "received a response for an unknown context: " + a,
              o
            );
          }
        } catch (n) {
          console.error(n);
        }
      });
    });
  }
  checkConnection() {
    if (this.waitingForPong && console.warn("Ping to backend module timed out."), this.startedReconnectOutgoing || this.startedReconnectIncoming)
      return;
    this.waitingForPong = !0;
    const t = $r.createPingMessage();
    this.sendMessage(t).then(() => {
      this.waitingForPong = !1, this.sendPendingRequests();
    }).catch((r) => {
      console.warn(r.errorMsg);
    });
  }
  /** Send a request to the backend module and retrieve the response
   *
   * This high-level implementation of :meth:`sendMessage` takes an object and
   * sends it as a :class:`DASFModuleRequest` of type
   * :attr:`MessageType.Request` to the backend module (as soon as
   * the websocket connection has been established). The result
   * is a promise that resolves to the response of the backend module.
   *
   * **Example**
   *
   * ```
   * import { DASFConnection, WebsocketUrlBuilder } from '@dasf/dasf-messaging'
   * const connection = new DASFConnection(
   *     new WebsocketUrlBuilder(
   *         'ws://localhost:8080/ws',
   *         'some-topic'
   *     )
   * )
   *
   * // send request via the connection and log the response
   * connection.sendRequest({func_name: 'version_info'}).then(
   *     (response) => console.log(response)
   * )
   * ```
   *
   * @param data - The object that is sent as payload of the request to the
   *   backend module
   * @param onProgress - A callback to use when we receive progress reports
   *   while processing the request in the backend module.
   *
   * @returns The promise resolving to the deserialized response of the backend
   *   module
   */
  async sendRequest(t, r) {
    const n = $r.createRequestMessage(t);
    return this.sendMessage(n, r).then(
      (o) => o.properties && o.properties.status == "error" ? "Error: " + atob(o.payload) : JSON.parse(atob(o.payload))
    );
  }
  /** Send a generic message to the backend module
   *
   * This low-level implementation takes a generic :class:`DASFModuleRequest`
   * and sends it to the backend module (as soon as the websocket connection
   * has been established). The result is a promise that resolves to the
   * response of the backend module.
   *
   * @param requestMessage - The message you want to send
   * @param onProgress - A callback to use when we receive progress reports
   *   while processing the request in the backend module.
   *
   * @returns The promise resolving to the response of the backend module
   */
  async sendMessage(t, r) {
    if (t.context = String(++this.contextCounter), !t.properties)
      throw new Error("missing request properties");
    t.properties[hd.ResponseTopic] = this.consumeTopic, t.properties[hd.RequestContext] = t.context;
    const {
      promise: n,
      resolve: o,
      reject: a
    } = Promise.withResolvers();
    if (!this.hasConnectionError())
      this.responseResolvers.set(t.context, o), this.responseRejectHandler.set(t.context, a), typeof r < "u" && this.progressCallbacks.set(t.context, r), this.connected.then((i) => {
        const s = JSON.stringify(t);
        i.outgoingChannel.send(s);
      });
    else {
      const i = new co();
      i.context = t.context, i.errorMsg = this.connectionError, a(i);
    }
    return n;
  }
  acknowledgeMessage(t) {
    const r = this.jsonCoder.serializeObject(
      new Tl(t.messageId)
    );
    this.incomingChannel.send(JSON.stringify(r));
  }
  /** Close all connections
   *
   * This method closes the connections to the outgoing and incoming websocket.
   *
   * **Example**
   *
   * ```
   * import { DASFConnection, WebsocketUrlBuilder } from '@dasf/dasf-messaging'
   * const connection = new DASFConnection(
   *     new WebsocketUrlBuilder(
   *         'ws://localhost:8080/ws',
   *         'some-topic'
   *     )
   * )
   *
   * // send request via the connection and log the response
   * connection.sendRequest({func_name: 'version_info'}).then(
   *     (response) => {
   *       console.log(response)
   *       // close the connection upon receival
   *       connection.close()
   *     }
   * )
   *
   * ```
   */
  close() {
    this.outgoingChannel.close(), this.incomingChannel.close();
  }
  /** Get information on requests for this module
   *
   * This method retrieves the JSONSchema representation for requests to this
   * module. It is one large schema object that can be used to validate a
   * request for the :func:`sendRequest` method.
   *
   * @returns A promise that resolves to the JSONSchema for a request to this topic
   */
  getModuleInfo() {
    return this.sendInfoRequest(
      $r.createInfoMessage(),
      oa.Info
    );
  }
  /** Get api information for this backend module
   *
   * This method retrieves the api info, namely the individual JSONSchema
   * representations for the functions and classes in the backend module.
   * Different from :func:`getModuleInfo`, this method does not only provide a
   * single JSONSchema, but rather one JSONSchema for each method/function in
   * the backend module.
   *
   * @returns an object representing the api of the backend module.
   */
  getApiInfo() {
    return this.sendInfoRequest(
      $r.createApiInfoMessage(),
      oa.ApiInfo
    );
  }
  sendInfoRequest(t, r = oa.Info) {
    const { promise: n, resolve: o, reject: a } = Promise.withResolvers();
    return this.sendMessage(t).then((i) => {
      if (i.properties)
        try {
          const s = JSON.parse(i.properties[r]);
          r == oa.ApiInfo ? o(this.jsonCoder.deserializeObject(s, Mo)) : o(s);
        } catch (s) {
          console.warn(
            `Unable to retrieve backend module ${r}, got: `,
            i.properties[r]
          ), a(s);
        }
    }), n;
  }
  hasConnectionError() {
    return this.connectionError.length > 0;
  }
}
class XJ {
  constructor(t, r, n = "", o = "") {
    Ae(this, "topic"), Ae(this, "consumeTopic"), Ae(this, "DASFConsumerURL"), Ae(this, "DASFProducerURL"), this.topic = r, this.consumeTopic = this.generateConsumeTopic(r), this.DASFConsumerURL = (o || this.buildUrl(t, this.consumeTopic)) + "/" + this.generateSubscriptionPrefix(), this.DASFProducerURL = n || this.buildUrl(t, this.topic);
  }
  buildUrl(t, r) {
    return t + "/" + r;
  }
  generateConsumeTopic(t) {
    return t + "_" + this.generateRequestToken();
  }
  generateSubscriptionPrefix() {
    return "web-frontend-" + (/* @__PURE__ */ new Date()).toISOString();
  }
  generateRequestToken() {
    return Math.random().toString(16).slice(2);
  }
}
const ZJ = class U1 {
  constructor(t, r, n, o, a = "ws") {
    Ae(this, "topic"), Ae(this, "consumeTopic"), Ae(this, "DASFConsumerURL"), Ae(this, "DASFProducerURL"), this.topic = o, this.consumeTopic = this.generateConsumeTopic(o), this.DASFConsumerURL = this.buildUrl(
      t,
      r,
      n,
      "consumer",
      this.consumeTopic,
      a
    ), this.DASFProducerURL = this.buildUrl(
      t,
      r,
      n,
      "producer",
      this.topic,
      a
    );
  }
  buildUrl(t, r, n, o, a, i) {
    let s = U1.BASE_DASF_URL.replace("%host%", t).replace("%port%", r).replace("%namespace%", n).replace("%type%", o).replace("%topic%", a).replace("%protocol%", i);
    return o == "consumer" && (s += this.generateSubscriptionPrefix() + "?subscriptionType=Exclusive"), s;
  }
  generateConsumeTopic(t) {
    return t + "_" + this.generateRequestToken();
  }
  generateSubscriptionPrefix() {
    return "web-frontend-" + (/* @__PURE__ */ new Date()).toISOString();
  }
  generateRequestToken() {
    return Math.random().toString(16).slice(2);
  }
};
Ae(ZJ, "BASE_DASF_URL", "%protocol%://%host%:%port%/ws/v2/%type%/non-persistent/public/%namespace%/%topic%/");
function QJ({ report: e }) {
  const t = typeof e.children > "u" ? 0 : e.children.filter(
    (r) => r.status == pa.Success
  ).length;
  return /* @__PURE__ */ ue(Wt, { children: [
    /* @__PURE__ */ ue(hr, { sx: { display: "flex", alignItems: "center" }, children: [
      /* @__PURE__ */ P(hr, { sx: { minWidth: 100 }, children: /* @__PURE__ */ ue(sr, { variant: "body2", sx: { color: "text.secondary" }, children: [
        "Step ",
        t,
        " of ",
        e.steps
      ] }) }),
      /* @__PURE__ */ P(hr, { sx: { width: "100%", ml: 1 }, children: /* @__PURE__ */ P(
        D1,
        {
          variant: "determinate",
          value: t / e.steps * 100
        }
      ) })
    ] }),
    typeof e.children < "u" && e.children.length > 0 && /* @__PURE__ */ P(hr, { sx: { width: "100%", ml: 1, m: 1 }, children: /* @__PURE__ */ ue(sr, { variant: "body2", sx: { color: "text.secondary" }, children: [
      e.children[e.children.length - 1].status == pa.Running && /* @__PURE__ */ P(L1, { size: "1rem", sx: { mr: 2 } }),
      e.children[e.children.length - 1].step_message
    ] }) })
  ] });
}
const eY = gr(/* @__PURE__ */ P("path", {
  d: "M9 16.2 4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4z"
}), "Done"), tY = {
  50: "#fce4ec",
  100: "#f8bbd0",
  200: "#f48fb1",
  300: "#f06292",
  400: "#ec407a",
  500: "#e91e63",
  600: "#d81b60",
  700: "#c2185b",
  800: "#ad1457",
  900: "#880e4f",
  A100: "#ff80ab",
  A200: "#ff4081",
  A400: "#f50057",
  A700: "#c51162"
}, rY = gr(/* @__PURE__ */ P("path", {
  d: "M1 21h22L12 2zm12-3h-2v-2h2zm0-4h-2v-4h2z"
}), "ReportProblem");
function nY({ status: e, message: t }) {
  return /* @__PURE__ */ ue("span", { children: [
    e == pa.Running && /* @__PURE__ */ P(L1, { size: "1rem", sx: { mr: 2 } }),
    e == pa.Success && /* @__PURE__ */ P(eY, { color: "success", sx: { mr: 1 } }),
    e == pa.Error && /* @__PURE__ */ P(rY, { sx: { color: tY[500], mr: 1 } }),
    t
  ] });
}
function V1({ reportItem: e }) {
  return /* @__PURE__ */ ue(hr, { sx: { ml: 2, my: 1 }, children: [
    /* @__PURE__ */ P(
      nY,
      {
        status: e.status,
        message: e.step_message
      }
    ),
    typeof e.children < "u" && e.children.map((t, r) => /* @__PURE__ */ P(V1, { reportItem: t }, r))
  ] });
}
function oY({ reportItem: e }) {
  return /* @__PURE__ */ P(hr, { sx: { my: 2 }, children: /* @__PURE__ */ P(Ga, { elevation: 3, children: /* @__PURE__ */ P(hr, { sx: { p: 2 }, children: /* @__PURE__ */ P(V1, { reportItem: e }) }) }) });
}
function aY({ children: e }) {
  return /* @__PURE__ */ P(Wt, { children: e.map((t, r) => /* @__PURE__ */ P(oY, { reportItem: t }, r)) });
}
function iY(e) {
  return Be("MuiCollapse", e);
}
De("MuiCollapse", ["root", "horizontal", "vertical", "entered", "hidden", "wrapper", "wrapperInner"]);
const sY = (e) => {
  const {
    orientation: t,
    classes: r
  } = e, n = {
    root: ["root", `${t}`],
    entered: ["entered"],
    hidden: ["hidden"],
    wrapper: ["wrapper", `${t}`],
    wrapperInner: ["wrapperInner", `${t}`]
  };
  return ze(n, iY, r);
}, lY = de("div", {
  name: "MuiCollapse",
  slot: "Root",
  overridesResolver: (e, t) => {
    const {
      ownerState: r
    } = e;
    return [t.root, t[r.orientation], r.state === "entered" && t.entered, r.state === "exited" && !r.in && r.collapsedSize === "0px" && t.hidden];
  }
})(je(({
  theme: e
}) => ({
  height: 0,
  overflow: "hidden",
  transition: e.transitions.create("height"),
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      height: "auto",
      width: 0,
      transition: e.transitions.create("width")
    }
  }, {
    props: {
      state: "entered"
    },
    style: {
      height: "auto",
      overflow: "visible"
    }
  }, {
    props: {
      state: "entered",
      orientation: "horizontal"
    },
    style: {
      width: "auto"
    }
  }, {
    props: ({
      ownerState: t
    }) => t.state === "exited" && !t.in && t.collapsedSize === "0px",
    style: {
      visibility: "hidden"
    }
  }]
}))), cY = de("div", {
  name: "MuiCollapse",
  slot: "Wrapper",
  overridesResolver: (e, t) => t.wrapper
})({
  // Hack to get children with a negative margin to not falsify the height computation.
  display: "flex",
  width: "100%",
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      width: "auto",
      height: "100%"
    }
  }]
}), uY = de("div", {
  name: "MuiCollapse",
  slot: "WrapperInner",
  overridesResolver: (e, t) => t.wrapperInner
})({
  width: "100%",
  variants: [{
    props: {
      orientation: "horizontal"
    },
    style: {
      width: "auto",
      height: "100%"
    }
  }]
}), oo = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCollapse"
  }), {
    addEndListener: o,
    children: a,
    className: i,
    collapsedSize: s = "0px",
    component: l,
    easing: c,
    in: u,
    onEnter: f,
    onEntered: d,
    onEntering: p,
    onExit: h,
    onExited: $,
    onExiting: b,
    orientation: g = "vertical",
    style: y,
    timeout: S = fv.standard,
    // eslint-disable-next-line react/prop-types
    TransitionComponent: m = en,
    ...w
  } = n, v = {
    ...n,
    orientation: g,
    collapsedSize: s
  }, E = sY(v), I = Ka(), R = pf(), C = M.useRef(null), T = M.useRef(), F = typeof s == "number" ? `${s}px` : s, D = g === "horizontal", z = D ? "width" : "height", L = M.useRef(null), X = Bt(r, L), V = (W) => (ne) => {
    if (W) {
      const ee = L.current;
      ne === void 0 ? W(ee) : W(ee, ne);
    }
  }, ie = () => C.current ? C.current[D ? "clientWidth" : "clientHeight"] : 0, Y = V((W, ne) => {
    C.current && D && (C.current.style.position = "absolute"), W.style[z] = F, f && f(W, ne);
  }), H = V((W, ne) => {
    const ee = ie();
    C.current && D && (C.current.style.position = "");
    const {
      duration: pe,
      easing: ce
    } = Ea({
      style: y,
      timeout: S,
      easing: c
    }, {
      mode: "enter"
    });
    if (S === "auto") {
      const ye = I.transitions.getAutoHeightDuration(ee);
      W.style.transitionDuration = `${ye}ms`, T.current = ye;
    } else
      W.style.transitionDuration = typeof pe == "string" ? pe : `${pe}ms`;
    W.style[z] = `${ee}px`, W.style.transitionTimingFunction = ce, p && p(W, ne);
  }), j = V((W, ne) => {
    W.style[z] = "auto", d && d(W, ne);
  }), Q = V((W) => {
    W.style[z] = `${ie()}px`, h && h(W);
  }), q = V($), O = V((W) => {
    const ne = ie(), {
      duration: ee,
      easing: pe
    } = Ea({
      style: y,
      timeout: S,
      easing: c
    }, {
      mode: "exit"
    });
    if (S === "auto") {
      const ce = I.transitions.getAutoHeightDuration(ne);
      W.style.transitionDuration = `${ce}ms`, T.current = ce;
    } else
      W.style.transitionDuration = typeof ee == "string" ? ee : `${ee}ms`;
    W.style[z] = F, W.style.transitionTimingFunction = pe, b && b(W);
  });
  return /* @__PURE__ */ P(m, {
    in: u,
    onEnter: Y,
    onEntered: j,
    onEntering: H,
    onExit: Q,
    onExited: q,
    onExiting: O,
    addEndListener: (W) => {
      S === "auto" && R.start(T.current || 0, W), o && o(L.current, W);
    },
    nodeRef: L,
    timeout: S === "auto" ? null : S,
    ...w,
    children: (W, {
      ownerState: ne,
      ...ee
    }) => /* @__PURE__ */ P(lY, {
      as: l,
      className: Ee(E.root, i, {
        entered: E.entered,
        exited: !u && F === "0px" && E.hidden
      }[W]),
      style: {
        [D ? "minWidth" : "minHeight"]: F,
        ...y
      },
      ref: X,
      ownerState: {
        ...v,
        state: W
      },
      ...ee,
      children: /* @__PURE__ */ P(cY, {
        ownerState: {
          ...v,
          state: W
        },
        className: E.wrapper,
        ref: C,
        children: /* @__PURE__ */ P(uY, {
          ownerState: {
            ...v,
            state: W
          },
          className: E.wrapperInner,
          children: a
        })
      })
    })
  });
});
oo && (oo.muiSupportAuto = !0);
function dY({ report: e }) {
  const [t, r] = Or(!1);
  return /* @__PURE__ */ ue(Wt, { children: [
    /* @__PURE__ */ P(QJ, { report: e }),
    typeof e.children < "u" && /* @__PURE__ */ ue(Wt, { children: [
      /* @__PURE__ */ P(Gi, { variant: "text", onClick: () => r(!t), children: "Show details" }),
      /* @__PURE__ */ P(oo, { in: t, timeout: "auto", unmountOnExit: !0, children: /* @__PURE__ */ P(aY, { children: e.children }) })
    ] })
  ] });
}
function Np({
  connection: e,
  websocketUrl: t,
  topic: r
}) {
  return typeof e > "u" ? new YJ(
    // @ts-expect-error:next-line
    new XJ(t, r)
  ) : typeof e == "function" ? e() : e;
}
const xo = N8({
  createStyledComponent: de("div", {
    name: "MuiGrid2",
    slot: "Root",
    overridesResolver: (e, t) => {
      const {
        ownerState: r
      } = e;
      return [t.root, r.container && t.container];
    }
  }),
  componentName: "MuiGrid2",
  useThemeProps: (e) => Ke({
    props: e,
    name: "MuiGrid2"
  }),
  useTheme: Ka
});
var ao = /* @__PURE__ */ ((e) => (e.Rows = "rows", e.Columns = "columns", e))(ao || {});
function q1({
  schemaElement: e,
  schema: t,
  uiSchema: r,
  outputDescription: n,
  connection: o,
  websocketUrl: a,
  topic: i,
  functionName: s,
  onResponse: l,
  skipDefaultResponseHandler: c = !1,
  skipDefaultResponseHandlerCheck: u,
  onError: f,
  skipDefaultErrorHandler: d = !1,
  skipDefaultErrorHandlerCheck: p,
  onProgress: h,
  skipDefaultProgressHandler: $ = !1,
  skipDefaultProgressHandlerCheck: b,
  fields: g,
  widgets: y,
  constructorData: S,
  renderStringAsHtml: m = !1,
  layout: w = ao.Columns
}) {
  var ne;
  typeof e < "u" && (t = JSON.parse(
    // @ts-expect-error:next-line
    (ne = document.getElementById(e)) == null ? void 0 : ne.textContent
  ));
  const [v, E] = Or(null), [I, R] = Or(null), [C, T] = Or(!1), [F, D] = Or(t), [z, L] = Or(n), X = uy(null);
  function V(ee) {
    return typeof u > "u" ? c : u(ee);
  }
  function ie(ee) {
    return typeof b > "u" ? $ : b(ee);
  }
  function Y(ee) {
    return typeof p > "u" ? d : p(ee);
  }
  const H = (ee) => {
    E(ee);
  }, j = (ee) => {
    R(ee.message);
  }, Q = (ee) => {
    typeof h > "u" ? j(ee) : (h(ee), ie(ee) || j(ee));
  }, q = (ee) => {
    T(!1), X.current.disabled = !1, X.current.classList.remove("Mui-disabled"), typeof l > "u" ? H(ee) : (l(ee), V(ee) || H(ee));
  }, O = (ee) => {
    L("Request failed!"), typeof f > "u" ? console.error(ee) : (f(ee), Y(ee) || console.error("miao!", ee));
  }, N = Np({
    connection: o,
    websocketUrl: a,
    topic: i
  }), W = ({ formData: ee }, pe) => {
    T(!0), E(null), L(n), X.current.disabled = !0, X.current.classList.add("Mui-disabled"), typeof S < "u" && (ee = { ...S, function: ee }), N.sendRequest(ee, Q).then(q).catch(O);
  };
  return typeof r > "u" && (r = {}), r["ui:submitButtonOptions"] = {
    props: { ref: X }
    // don't use the disabled property here because this would trigger a rerender on every submit
  }, typeof F > "u" && N.getApiInfo().then((ee) => {
    D(typeof s > "u" ? ee.functions[0].rpcSchema : ee.functions.filter((pe) => pe.name == s)[0].rpcSchema);
  }), /* @__PURE__ */ P(Wt, { children: /* @__PURE__ */ ue(xo, { container: !0, spacing: 2, children: [
    /* @__PURE__ */ ue(
      xo,
      {
        size: {
          xs: 12,
          md: w == ao.Rows ? 12 : I || v ? 6 : 12
        },
        children: [
          F && /* @__PURE__ */ P(
            F1,
            {
              schema: F,
              uiSchema: r,
              onSubmit: W,
              fields: g,
              widgets: y
            }
          ),
          C && /* @__PURE__ */ P(hr, { sx: { mt: 2 }, children: /* @__PURE__ */ P(D1, {}) })
        ]
      }
    ),
    (I || v != null) && /* @__PURE__ */ ue(xo, { size: { xs: 12, md: w == ao.Rows ? 12 : 6 }, children: [
      I && /* @__PURE__ */ P(dY, { report: I }),
      v != null && /* @__PURE__ */ P(
        xJ,
        {
          content: v,
          description: z,
          renderStringAsHtml: m
        }
      )
    ] })
  ] }) });
}
function fY(e) {
  return Be("MuiCard", e);
}
De("MuiCard", ["root"]);
const pY = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"]
  }, fY, t);
}, hY = de(Ga, {
  name: "MuiCard",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({
  overflow: "hidden"
}), W1 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCard"
  }), {
    className: o,
    raised: a = !1,
    ...i
  } = n, s = {
    ...n,
    raised: a
  }, l = pY(s);
  return /* @__PURE__ */ P(hY, {
    className: Ee(l.root, o),
    elevation: a ? 8 : void 0,
    ref: r,
    ownerState: s,
    ...i
  });
});
function mY(e) {
  return Be("MuiCardActionArea", e);
}
const $u = De("MuiCardActionArea", ["root", "focusVisible", "focusHighlight"]), gY = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"],
    focusHighlight: ["focusHighlight"]
  }, mY, t);
}, yY = de(hs, {
  name: "MuiCardActionArea",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})(je(({
  theme: e
}) => ({
  display: "block",
  textAlign: "inherit",
  borderRadius: "inherit",
  // for Safari to work https://github.com/mui/material-ui/issues/36285.
  width: "100%",
  [`&:hover .${$u.focusHighlight}`]: {
    opacity: (e.vars || e).palette.action.hoverOpacity,
    "@media (hover: none)": {
      opacity: 0
    }
  },
  [`&.${$u.focusVisible} .${$u.focusHighlight}`]: {
    opacity: (e.vars || e).palette.action.focusOpacity
  }
}))), bY = de("span", {
  name: "MuiCardActionArea",
  slot: "FocusHighlight",
  overridesResolver: (e, t) => t.focusHighlight
})(je(({
  theme: e
}) => ({
  overflow: "hidden",
  pointerEvents: "none",
  position: "absolute",
  top: 0,
  right: 0,
  bottom: 0,
  left: 0,
  borderRadius: "inherit",
  opacity: 0,
  backgroundColor: "currentcolor",
  transition: e.transitions.create("opacity", {
    duration: e.transitions.duration.short
  })
}))), K1 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCardActionArea"
  }), {
    children: o,
    className: a,
    focusVisibleClassName: i,
    ...s
  } = n, l = n, c = gY(l);
  return /* @__PURE__ */ ue(yY, {
    className: Ee(c.root, a),
    focusVisibleClassName: Ee(i, c.focusVisible),
    ref: r,
    ownerState: l,
    ...s,
    children: [o, /* @__PURE__ */ P(bY, {
      className: c.focusHighlight,
      ownerState: l
    })]
  });
});
function vY(e) {
  return Be("MuiCardContent", e);
}
De("MuiCardContent", ["root"]);
const $Y = (e) => {
  const {
    classes: t
  } = e;
  return ze({
    root: ["root"]
  }, vY, t);
}, SY = de("div", {
  name: "MuiCardContent",
  slot: "Root",
  overridesResolver: (e, t) => t.root
})({
  padding: 16,
  "&:last-child": {
    paddingBottom: 24
  }
}), G1 = /* @__PURE__ */ M.forwardRef(function(t, r) {
  const n = Ke({
    props: t,
    name: "MuiCardContent"
  }), {
    className: o,
    component: a = "div",
    ...i
  } = n, s = {
    ...n,
    component: a
  }, l = $Y(s);
  return /* @__PURE__ */ P(SY, {
    as: a,
    className: Ee(l.root, o),
    ownerState: s,
    ref: r,
    ...i
  });
}), md = gr([/* @__PURE__ */ P("path", {
  d: "M17.59 18 19 16.59 14.42 12 19 7.41 17.59 6l-6 6z"
}, "0"), /* @__PURE__ */ P("path", {
  d: "m11 18 1.41-1.41L7.83 12l4.58-4.59L11 6l-6 6z"
}, "1")], "KeyboardDoubleArrowLeft");
function wY({
  apiInfoElement: e,
  apiInfo: t,
  uiSchema: r,
  connection: n,
  websocketUrl: o,
  topic: a,
  className: i,
  fields: s,
  widgets: l,
  layout: c = ao.Columns,
  ...u
}) {
  var m;
  const [f, d] = Or(-1), [p, h] = Or({}), $ = Np({
    connection: n,
    websocketUrl: o,
    topic: a
  });
  typeof e < "u" && (t = $.jsonCoder.deserializeObject(
    JSON.parse(
      // @ts-expect-error:next-line
      (m = document.getElementById(e)) == null ? void 0 : m.textContent
    ),
    To
  ));
  const [b, g] = Or(
    t
  );
  typeof r > "u" && (r = {});
  const y = {
    ...r,
    "ui:submitButtonOptions": { norender: !0 },
    class_name: { "ui:widget": "hidden" }
  };
  typeof b > "u" && $.getApiInfo().then((w) => {
    g(typeof i > "u" ? w.classes[0] : w.classes.filter((v) => v.name == i)[0]);
  });
  const S = ({ formData: w }) => {
    h(w);
  };
  return /* @__PURE__ */ P(Wt, { children: b && /* @__PURE__ */ ue(Wt, { children: [
    /* @__PURE__ */ P(
      F1,
      {
        schema: b.rpcSchema,
        uiSchema: y,
        onChange: S,
        fields: s,
        widgets: l
      }
    ),
    /* @__PURE__ */ P(oo, { in: f == -1, timeout: "auto", unmountOnExit: !0, children: /* @__PURE__ */ P(xo, { container: !0, spacing: { xs: 2, md: 3 }, children: b.methods.map(
      (w, v) => /* @__PURE__ */ P(
        xo,
        {
          size: { xs: 12, md: c == ao.Rows ? 12 : 6 },
          children: /* @__PURE__ */ P(W1, { variant: "outlined", children: /* @__PURE__ */ P(
            K1,
            {
              onClick: () => d(v),
              "data-active": void 0,
              sx: {
                height: "100%",
                "&[data-active]": {
                  backgroundColor: "action.selected",
                  "&:hover": {
                    backgroundColor: "action.selectedHover"
                  }
                }
              },
              children: /* @__PURE__ */ ue(G1, { children: [
                /* @__PURE__ */ P(
                  sr,
                  {
                    variant: "h5",
                    component: "div",
                    sx: { mb: 2 },
                    children: w.name
                  }
                ),
                w.rpcSchema.description && /* @__PURE__ */ P(
                  sr,
                  {
                    variant: "body2",
                    sx: { color: "text.secondary" },
                    children: w.rpcSchema.description
                  }
                )
              ] })
            }
          ) })
        },
        w.name
      )
    ) }) }),
    b.methods.map(
      (w, v) => /* @__PURE__ */ ue(
        oo,
        {
          in: v == f,
          timeout: "auto",
          unmountOnExit: !0,
          children: [
            /* @__PURE__ */ P(
              Gi,
              {
                variant: "text",
                onClick: () => d(-1),
                startIcon: /* @__PURE__ */ P(md, {}),
                children: "All functions"
              }
            ),
            /* @__PURE__ */ P(
              q1,
              {
                schema: w.rpcSchema,
                uiSchema: r,
                outputDescription: w.returnSchema.description,
                connection: $,
                constructorData: p,
                fields: s,
                widgets: l,
                layout: c,
                ...u
              },
              w.name
            )
          ]
        },
        w.name
      )
    )
  ] }) });
}
function CY(e) {
  const t = uy();
  return Ml(() => {
    t.current = e;
  }, [e]), t.current;
}
function OY({
  apiInfoElement: e,
  apiInfo: t,
  uiSchema: r,
  member: n,
  connection: o,
  websocketUrl: a,
  topic: i,
  layout: s = ao.Columns,
  updateUrl: l = !1,
  ...c
}) {
  var b;
  const [u, f] = Or(
    typeof n > "u" ? "" : n
  ), d = CY(u), p = Np({
    connection: o,
    websocketUrl: a,
    topic: i
  });
  typeof e < "u" && (t = p.jsonCoder.deserializeObject(
    JSON.parse(
      // @ts-expect-error:next-line
      (b = document.getElementById(e)) == null ? void 0 : b.textContent
    ),
    Mo
  ));
  const [h, $] = Or(
    t
  );
  return typeof h > "u" && p.getApiInfo().then((g) => {
    $(g);
  }), Ml(() => {
    if (l && d != u && typeof d < "u") {
      const g = new URL(
        (d ? "../" : "") + u + (u ? "/" : ""),
        window.location.href
      );
      history.replaceState(null, "", g);
    }
  }, [u, d, l]), /* @__PURE__ */ ue(Wt, { children: [
    h && /* @__PURE__ */ P(oo, { in: !u, timeout: "auto", unmountOnExit: !0, children: /* @__PURE__ */ P(xo, { container: !0, spacing: { xs: 2, md: 3 }, children: h.functions.concat(h.classes).map((g) => /* @__PURE__ */ P(
      xo,
      {
        size: { xs: 12, md: s == ao.Rows ? 12 : 6 },
        children: /* @__PURE__ */ P(W1, { variant: "outlined", children: /* @__PURE__ */ P(
          K1,
          {
            onClick: () => f(g.name),
            "data-active": void 0,
            sx: {
              height: "100%",
              "&[data-active]": {
                backgroundColor: "action.selected",
                "&:hover": {
                  backgroundColor: "action.selectedHover"
                }
              }
            },
            children: /* @__PURE__ */ ue(G1, { children: [
              /* @__PURE__ */ P(sr, { variant: "h5", component: "div", sx: { mb: 2 }, children: g.name }),
              g.rpcSchema.description && /* @__PURE__ */ P(
                sr,
                {
                  variant: "body2",
                  sx: { color: "text.secondary" },
                  children: g.rpcSchema.description
                }
              )
            ] })
          }
        ) })
      },
      g.name
    )) }) }),
    h && h.functions.map((g) => /* @__PURE__ */ ue(
      oo,
      {
        in: u == g.name,
        timeout: "auto",
        unmountOnExit: !0,
        children: [
          /* @__PURE__ */ P(
            Gi,
            {
              variant: "text",
              onClick: () => f(""),
              startIcon: /* @__PURE__ */ P(md, {}),
              children: "All functions"
            }
          ),
          /* @__PURE__ */ P(
            q1,
            {
              schema: g.rpcSchema,
              uiSchema: r,
              outputDescription: g.returnSchema.description,
              connection: p,
              layout: s,
              ...c
            },
            g.name
          )
        ]
      },
      g.name
    )),
    h && h.classes.map((g) => /* @__PURE__ */ ue(
      oo,
      {
        in: g.name == u,
        timeout: "auto",
        unmountOnExit: !0,
        children: [
          /* @__PURE__ */ P(
            Gi,
            {
              variant: "text",
              onClick: () => f(""),
              startIcon: /* @__PURE__ */ P(md, {}),
              children: "All functions"
            }
          ),
          /* @__PURE__ */ P(
            wY,
            {
              apiInfo: g,
              uiSchema: r,
              connection: p,
              layout: s,
              ...c
            },
            g.name
          )
        ]
      },
      g.name
    ))
  ] });
}
export {
  wY as ClassContainer,
  q1 as FunctionContainer,
  OY as ModuleContainer,
  Np as getConnection
};
