widget-staging.rather.chat
Open in
urlscan Pro
3.160.150.52
Public Scan
URL:
https://widget-staging.rather.chat/
Submission: On May 16 via api from US — Scanned from AT
Submission: On May 16 via api from US — Scanned from AT
Form analysis
0 forms found in the DOMText Content
/** * @vue/shared v3.4.21 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT **/ function ur(e, t) { const n = new Set(e.split(",")); return t ? (r) => n.has(r.toLowerCase()) : (r) => n.has(r); } const q = {}, lt = [], pe = () => { }, Qi = () => !1, an = (e) => e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && // uppercase letter (e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97), fr = (e) => e.startsWith("onUpdate:"), ne = Object.assign, dr = (e, t) => { const n = e.indexOf(t); n > -1 && e.splice(n, 1); }, Xi = Object.prototype.hasOwnProperty, j = (e, t) => Xi.call(e, t), T = Array.isArray, ct = (e) => un(e) === "[object Map]", Ps = (e) => un(e) === "[object Set]", N = (e) => typeof e == "function", ee = (e) => typeof e == "string", ht = (e) => typeof e == "symbol", J = (e) => e !== null && typeof e == "object", Ts = (e) => (J(e) || N(e)) && N(e.then) && N(e.catch), Ns = Object.prototype.toString, un = (e) => Ns.call(e), Zi = (e) => un(e).slice(8, -1), Bs = (e) => un(e) === "[object Object]", hr = (e) => ee(e) && e !== "NaN" && e[0] !== "-" && "" + parseInt(e, 10) === e, Et = /* @__PURE__ */ ur( // the leading comma is intentional so empty string "" is also included ",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted" ), fn = (e) => { const t = /* @__PURE__ */ Object.create(null); return (n) => t[n] || (t[n] = e(n)); }, Yi = /-(\w)/g, Fe = fn((e) => e.replace(Yi, (t, n) => n ? n.toUpperCase() : "")), eo = /\B([A-Z])/g, pt = fn( (e) => e.replace(eo, "-$1").toLowerCase() ), dn = fn((e) => e.charAt(0).toUpperCase() + e.slice(1)), Pn = fn((e) => e ? `on${dn(e)}` : ""), et = (e, t) => !Object.is(e, t), Tn = (e, t) => { for (let n = 0; n < e.length; n++) e[n](t); }, nn = (e, t, n) => { Object.defineProperty(e, t, { configurable: !0, enumerable: !1, value: n }); }, to = (e) => { const t = parseFloat(e); return isNaN(t) ? e : t; }; let Dr; const Ls = () => Dr || (Dr = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {}); function At(e) { if (T(e)) { const t = {}; for (let n = 0; n < e.length; n++) { const r = e[n], s = ee(r) ? io(r) : At(r); if (s) for (const i in s) t[i] = s[i]; } return t; } else if (ee(e) || J(e)) return e; } const no = /;(?![^(]*\))/g, ro = /:([^]+)/, so = /\/\*[^]*?\*\//g; function io(e) { const t = {}; return e.replace(so, "").split(no).forEach((n) => { if (n) { const r = n.split(ro); r.length > 1 && (t[r[0].trim()] = r[1].trim()); } }), t; } function mt(e) { let t = ""; if (ee(e)) t = e; else if (T(e)) for (let n = 0; n < e.length; n++) { const r = mt(e[n]); r && (t += r + " "); } else if (J(e)) for (const n in e) e[n] && (t += n + " "); return t.trim(); } const oo = "itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly", lo = /* @__PURE__ */ ur(oo); function Is(e) { return !!e || e === ""; } const Nn = (e) => ee(e) ? e : e == null ? "" : T(e) || J(e) && (e.toString === Ns || !N(e.toString)) ? JSON.stringify(e, ks, 2) : String(e), ks = (e, t) => t && t.__v_isRef ? ks(e, t.value) : ct(t) ? { [`Map(${t.size})`]: [...t.entries()].reduce( (n, [r, s], i) => (n[Bn(r, i) + " =>"] = s, n), {} ) } : Ps(t) ? { [`Set(${t.size})`]: [...t.values()].map((n) => Bn(n)) } : ht(t) ? Bn(t) : J(t) && !T(t) && !Bs(t) ? String(t) : t, Bn = (e, t = "") => { var n; return ht(e) ? `Symbol(${(n = e.description) != null ? n : t})` : e; }; /** * @vue/reactivity v3.4.21 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT **/ let be; class co { constructor(t = !1) { this.detached = t, this._active = !0, this.effects = [], this.cleanups = [], this.parent = be, !t && be && (this.index = (be.scopes || (be.scopes = [])).push( this ) - 1); } get active() { return this._active; } run(t) { if (this._active) { const n = be; try { return be = this, t(); } finally { be = n; } } } /** * This should only be called on non-detached scopes * @internal */ on() { be = this; } /** * This should only be called on non-detached scopes * @internal */ off() { be = this.parent; } stop(t) { if (this._active) { let n, r; for (n = 0, r = this.effects.length; n < r; n++) this.effects[n].stop(); for (n = 0, r = this.cleanups.length; n < r; n++) this.cleanups[n](); if (this.scopes) for (n = 0, r = this.scopes.length; n < r; n++) this.scopes[n].stop(!0); if (!this.detached && this.parent && !t) { const s = this.parent.scopes.pop(); s && s !== this && (this.parent.scopes[this.index] = s, s.index = this.index); } this.parent = void 0, this._active = !1; } } } function ao(e, t = be) { t && t.active && t.effects.push(e); } function uo() { return be; } let Ze; class pr { constructor(t, n, r, s) { this.fn = t, this.trigger = n, this.scheduler = r, this.active = !0, this.deps = [], this._dirtyLevel = 4, this._trackId = 0, this._runnings = 0, this._shouldSchedule = !1, this._depsLength = 0, ao(this, s); } get dirty() { if (this._dirtyLevel === 2 || this._dirtyLevel === 3) { this._dirtyLevel = 1, nt(); for (let t = 0; t < this._depsLength; t++) { const n = this.deps[t]; if (n.computed && (fo(n.computed), this._dirtyLevel >= 4)) break; } this._dirtyLevel === 1 && (this._dirtyLevel = 0), rt(); } return this._dirtyLevel >= 4; } set dirty(t) { this._dirtyLevel = t ? 4 : 0; } run() { if (this._dirtyLevel = 0, !this.active) return this.fn(); let t = We, n = Ze; try { return We = !0, Ze = this, this._runnings++, Vr(this), this.fn(); } finally { Hr(this), this._runnings--, Ze = n, We = t; } } stop() { var t; this.active && (Vr(this), Hr(this), (t = this.onStop) == null || t.call(this), this.active = !1); } } function fo(e) { return e.value; } function Vr(e) { e._trackId++, e._depsLength = 0; } function Hr(e) { if (e.deps.length > e._depsLength) { for (let t = e._depsLength; t < e.deps.length; t++) $s(e.deps[t], e); e.deps.length = e._depsLength; } } function $s(e, t) { const n = e.get(t); n !== void 0 && t._trackId !== n && (e.delete(t), e.size === 0 && e.cleanup()); } let We = !0, Kn = 0; const js = []; function nt() { js.push(We), We = !1; } function rt() { const e = js.pop(); We = e === void 0 ? !0 : e; } function mr() { Kn++; } function gr() { for (Kn--; !Kn && Jn.length; ) Jn.shift()(); } function Us(e, t, n) { if (t.get(e) !== e._trackId) { t.set(e, e._trackId); const r = e.deps[e._depsLength]; r !== t ? (r && $s(r, e), e.deps[e._depsLength++] = t) : e._depsLength++; } } const Jn = []; function Ds(e, t, n) { mr(); for (const r of e.keys()) { let s; r._dirtyLevel < t && (s ?? (s = e.get(r) === r._trackId)) && (r._shouldSchedule || (r._shouldSchedule = r._dirtyLevel === 0), r._dirtyLevel = t), r._shouldSchedule && (s ?? (s = e.get(r) === r._trackId)) && (r.trigger(), (!r._runnings || r.allowRecurse) && r._dirtyLevel !== 2 && (r._shouldSchedule = !1, r.scheduler && Jn.push(r.scheduler))); } gr(); } const Vs = (e, t) => { const n = /* @__PURE__ */ new Map(); return n.cleanup = e, n.computed = t, n; }, Gn = /* @__PURE__ */ new WeakMap(), Ye = Symbol(""), Qn = Symbol(""); function ae(e, t, n) { if (We && Ze) { let r = Gn.get(e); r || Gn.set(e, r = /* @__PURE__ */ new Map()); let s = r.get(n); s || r.set(n, s = Vs(() => r.delete(n))), Us( Ze, s ); } } function Le(e, t, n, r, s, i) { const o = Gn.get(e); if (!o) return; let l = []; if (t === "clear") l = [...o.values()]; else if (n === "length" && T(e)) { const c = Number(r); o.forEach((f, d) => { (d === "length" || !ht(d) && d >= c) && l.push(f); }); } else switch (n !== void 0 && l.push(o.get(n)), t) { case "add": T(e) ? hr(n) && l.push(o.get("length")) : (l.push(o.get(Ye)), ct(e) && l.push(o.get(Qn))); break; case "delete": T(e) || (l.push(o.get(Ye)), ct(e) && l.push(o.get(Qn))); break; case "set": ct(e) && l.push(o.get(Ye)); break; } mr(); for (const c of l) c && Ds( c, 4 ); gr(); } const ho = /* @__PURE__ */ ur("__proto__,__v_isRef,__isVue"), Hs = new Set( /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((e) => e !== "arguments" && e !== "caller").map((e) => Symbol[e]).filter(ht) ), Wr = /* @__PURE__ */ po(); function po() { const e = {}; return ["includes", "indexOf", "lastIndexOf"].forEach((t) => { e[t] = function(...n) { const r = D(this); for (let i = 0, o = this.length; i < o; i++) ae(r, "get", i + ""); const s = r[t](...n); return s === -1 || s === !1 ? r[t](...n.map(D)) : s; }; }), ["push", "pop", "shift", "unshift", "splice"].forEach((t) => { e[t] = function(...n) { nt(), mr(); const r = D(this)[t].apply(this, n); return gr(), rt(), r; }; }), e; } function mo(e) { const t = D(this); return ae(t, "has", e), t.hasOwnProperty(e); } class Ws { constructor(t = !1, n = !1) { this._isReadonly = t, this._isShallow = n; } get(t, n, r) { const s = this._isReadonly, i = this._isShallow; if (n === "__v_isReactive") return !s; if (n === "__v_isReadonly") return s; if (n === "__v_isShallow") return i; if (n === "__v_raw") return r === (s ? i ? Ro : Js : i ? Ks : qs).get(t) || // receiver is not the reactive proxy, but has the same prototype // this means the reciever is a user proxy of the reactive proxy Object.getPrototypeOf(t) === Object.getPrototypeOf(r) ? t : void 0; const o = T(t); if (!s) { if (o && j(Wr, n)) return Reflect.get(Wr, n, r); if (n === "hasOwnProperty") return mo; } const l = Reflect.get(t, n, r); return (ht(n) ? Hs.has(n) : ho(n)) || (s || ae(t, "get", n), i) ? l : de(l) ? o && hr(n) ? l : l.value : J(l) ? s ? Gs(l) : yr(l) : l; } } class zs extends Ws { constructor(t = !1) { super(!1, t); } set(t, n, r, s) { let i = t[n]; if (!this._isShallow) { const c = Ct(i); if (!Xn(r) && !Ct(r) && (i = D(i), r = D(r)), !T(t) && de(i) && !de(r)) return c ? !1 : (i.value = r, !0); } const o = T(t) && hr(n) ? Number(n) < t.length : j(t, n), l = Reflect.set(t, n, r, s); return t === D(s) && (o ? et(r, i) && Le(t, "set", n, r) : Le(t, "add", n, r)), l; } deleteProperty(t, n) { const r = j(t, n); t[n]; const s = Reflect.deleteProperty(t, n); return s && r && Le(t, "delete", n, void 0), s; } has(t, n) { const r = Reflect.has(t, n); return (!ht(n) || !Hs.has(n)) && ae(t, "has", n), r; } ownKeys(t) { return ae( t, "iterate", T(t) ? "length" : Ye ), Reflect.ownKeys(t); } } class go extends Ws { constructor(t = !1) { super(!0, t); } set(t, n) { return !0; } deleteProperty(t, n) { return !0; } } const bo = /* @__PURE__ */ new zs(), wo = /* @__PURE__ */ new go(), yo = /* @__PURE__ */ new zs( !0 ), br = (e) => e, hn = (e) => Reflect.getPrototypeOf(e); function Vt(e, t, n = !1, r = !1) { e = e.__v_raw; const s = D(e), i = D(t); n || (et(t, i) && ae(s, "get", t), ae(s, "get", i)); const { has: o } = hn(s), l = r ? br : n ? Er : Sr; if (o.call(s, t)) return l(e.get(t)); if (o.call(s, i)) return l(e.get(i)); e !== s && e.get(t); } function Ht(e, t = !1) { const n = this.__v_raw, r = D(n), s = D(e); return t || (et(e, s) && ae(r, "has", e), ae(r, "has", s)), e === s ? n.has(e) : n.has(e) || n.has(s); } function Wt(e, t = !1) { return e = e.__v_raw, !t && ae(D(e), "iterate", Ye), Reflect.get(e, "size", e); } function zr(e) { e = D(e); const t = D(this); return hn(t).has.call(t, e) || (t.add(e), Le(t, "add", e, e)), this; } function qr(e, t) { t = D(t); const n = D(this), { has: r, get: s } = hn(n); let i = r.call(n, e); i || (e = D(e), i = r.call(n, e)); const o = s.call(n, e); return n.set(e, t), i ? et(t, o) && Le(n, "set", e, t) : Le(n, "add", e, t), this; } function Kr(e) { const t = D(this), { has: n, get: r } = hn(t); let s = n.call(t, e); s || (e = D(e), s = n.call(t, e)), r && r.call(t, e); const i = t.delete(e); return s && Le(t, "delete", e, void 0), i; } function Jr() { const e = D(this), t = e.size !== 0, n = e.clear(); return t && Le(e, "clear", void 0, void 0), n; } function zt(e, t) { return function(r, s) { const i = this, o = i.__v_raw, l = D(o), c = t ? br : e ? Er : Sr; return !e && ae(l, "iterate", Ye), o.forEach((f, d) => r.call(s, c(f), c(d), i)); }; } function qt(e, t, n) { return function(...r) { const s = this.__v_raw, i = D(s), o = ct(i), l = e === "entries" || e === Symbol.iterator && o, c = e === "keys" && o, f = s[e](...r), d = n ? br : t ? Er : Sr; return !t && ae( i, "iterate", c ? Qn : Ye ), { // iterator protocol next() { const { value: h, done: E } = f.next(); return E ? { value: h, done: E } : { value: l ? [d(h[0]), d(h[1])] : d(h), done: E }; }, // iterable protocol [Symbol.iterator]() { return this; } }; }; } function $e(e) { return function(...t) { return e === "delete" ? !1 : e === "clear" ? void 0 : this; }; } function _o() { const e = { get(i) { return Vt(this, i); }, get size() { return Wt(this); }, has: Ht, add: zr, set: qr, delete: Kr, clear: Jr, forEach: zt(!1, !1) }, t = { get(i) { return Vt(this, i, !1, !0); }, get size() { return Wt(this); }, has: Ht, add: zr, set: qr, delete: Kr, clear: Jr, forEach: zt(!1, !0) }, n = { get(i) { return Vt(this, i, !0); }, get size() { return Wt(this, !0); }, has(i) { return Ht.call(this, i, !0); }, add: $e("add"), set: $e("set"), delete: $e("delete"), clear: $e("clear"), forEach: zt(!0, !1) }, r = { get(i) { return Vt(this, i, !0, !0); }, get size() { return Wt(this, !0); }, has(i) { return Ht.call(this, i, !0); }, add: $e("add"), set: $e("set"), delete: $e("delete"), clear: $e("clear"), forEach: zt(!0, !0) }; return ["keys", "values", "entries", Symbol.iterator].forEach((i) => { e[i] = qt( i, !1, !1 ), n[i] = qt( i, !0, !1 ), t[i] = qt( i, !1, !0 ), r[i] = qt( i, !0, !0 ); }), [ e, n, t, r ]; } const [ So, Eo, vo, Oo ] = /* @__PURE__ */ _o(); function wr(e, t) { const n = t ? e ? Oo : vo : e ? Eo : So; return (r, s, i) => s === "__v_isReactive" ? !e : s === "__v_isReadonly" ? e : s === "__v_raw" ? r : Reflect.get( j(n, s) && s in r ? n : r, s, i ); } const xo = { get: /* @__PURE__ */ wr(!1, !1) }, Ao = { get: /* @__PURE__ */ wr(!1, !0) }, Co = { get: /* @__PURE__ */ wr(!0, !1) }, qs = /* @__PURE__ */ new WeakMap(), Ks = /* @__PURE__ */ new WeakMap(), Js = /* @__PURE__ */ new WeakMap(), Ro = /* @__PURE__ */ new WeakMap(); function Mo(e) { switch (e) { case "Object": case "Array": return 1; case "Map": case "Set": case "WeakMap": case "WeakSet": return 2; default: return 0; } } function Fo(e) { return e.__v_skip || !Object.isExtensible(e) ? 0 : Mo(Zi(e)); } function yr(e) { return Ct(e) ? e : _r( e, !1, bo, xo, qs ); } function Po(e) { return _r( e, !1, yo, Ao, Ks ); } function Gs(e) { return _r( e, !0, wo, Co, Js ); } function _r(e, t, n, r, s) { if (!J(e) || e.__v_raw && !(t && e.__v_isReactive)) return e; const i = s.get(e); if (i) return i; const o = Fo(e); if (o === 0) return e; const l = new Proxy( e, o === 2 ? r : n ); return s.set(e, l), l; } function at(e) { return Ct(e) ? at(e.__v_raw) : !!(e && e.__v_isReactive); } function Ct(e) { return !!(e && e.__v_isReadonly); } function Xn(e) { return !!(e && e.__v_isShallow); } function Qs(e) { return at(e) || Ct(e); } function D(e) { const t = e && e.__v_raw; return t ? D(t) : e; } function Xs(e) { return Object.isExtensible(e) && nn(e, "__v_skip", !0), e; } const Sr = (e) => J(e) ? yr(e) : e, Er = (e) => J(e) ? Gs(e) : e; class Zs { constructor(t, n, r, s) { this.getter = t, this._setter = n, this.dep = void 0, this.__v_isRef = !0, this.__v_isReadonly = !1, this.effect = new pr( () => t(this._value), () => Ln( this, this.effect._dirtyLevel === 2 ? 2 : 3 ) ), this.effect.computed = this, this.effect.active = this._cacheable = !s, this.__v_isReadonly = r; } get value() { const t = D(this); return (!t._cacheable || t.effect.dirty) && et(t._value, t._value = t.effect.run()) && Ln(t, 4), No(t), t.effect._dirtyLevel >= 2 && Ln(t, 2), t._value; } set value(t) { this._setter(t); } // #region polyfill _dirty for backward compatibility third party code for Vue <= 3.3.x get _dirty() { return this.effect.dirty; } set _dirty(t) { this.effect.dirty = t; } // #endregion } function To(e, t, n = !1) { let r, s; const i = N(e); return i ? (r = e, s = pe) : (r = e.get, s = e.set), new Zs(r, s, i || !s, n); } function No(e) { var t; We && Ze && (e = D(e), Us( Ze, (t = e.dep) != null ? t : e.dep = Vs( () => e.dep = void 0, e instanceof Zs ? e : void 0 ) )); } function Ln(e, t = 4, n) { e = D(e); const r = e.dep; r && Ds( r, t ); } function de(e) { return !!(e && e.__v_isRef === !0); } function Bo(e) { return de(e) ? e.value : e; } const Lo = { get: (e, t, n) => Bo(Reflect.get(e, t, n)), set: (e, t, n, r) => { const s = e[t]; return de(s) && !de(n) ? (s.value = n, !0) : Reflect.set(e, t, n, r); } }; function Ys(e) { return at(e) ? e : new Proxy(e, Lo); } /** * @vue/runtime-core v3.4.21 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT **/ function ze(e, t, n, r) { try { return r ? e(...r) : e(); } catch (s) { pn(s, t, n); } } function _e(e, t, n, r) { if (N(e)) { const i = ze(e, t, n, r); return i && Ts(i) && i.catch((o) => { pn(o, t, n); }), i; } const s = []; for (let i = 0; i < e.length; i++) s.push(_e(e[i], t, n, r)); return s; } function pn(e, t, n, r = !0) { const s = t ? t.vnode : null; if (t) { let i = t.parent; const o = t.proxy, l = `https://vuejs.org/error-reference/#runtime-${n}`; for (; i; ) { const f = i.ec; if (f) { for (let d = 0; d < f.length; d++) if (f[d](e, o, l) === !1) return; } i = i.parent; } const c = t.appContext.config.errorHandler; if (c) { ze( c, null, 10, [e, o, l] ); return; } } Io(e, n, s, r); } function Io(e, t, n, r = !0) { console.error(e); } let Rt = !1, Zn = !1; const re = []; let Ce = 0; const ut = []; let De = null, Xe = 0; const ei = /* @__PURE__ */ Promise.resolve(); let vr = null; function ko(e) { const t = vr || ei; return e ? t.then(this ? e.bind(this) : e) : t; } function $o(e) { let t = Ce + 1, n = re.length; for (; t < n; ) { const r = t + n >>> 1, s = re[r], i = Mt(s); i < e || i === e && s.pre ? t = r + 1 : n = r; } return t; } function Or(e) { (!re.length || !re.includes( e, Rt && e.allowRecurse ? Ce + 1 : Ce )) && (e.id == null ? re.push(e) : re.splice($o(e.id), 0, e), ti()); } function ti() { !Rt && !Zn && (Zn = !0, vr = ei.then(ri)); } function jo(e) { const t = re.indexOf(e); t > Ce && re.splice(t, 1); } function Uo(e) { T(e) ? ut.push(...e) : (!De || !De.includes( e, e.allowRecurse ? Xe + 1 : Xe )) && ut.push(e), ti(); } function Gr(e, t, n = Rt ? Ce + 1 : 0) { for (; n < re.length; n++) { const r = re[n]; if (r && r.pre) { if (e && r.id !== e.uid) continue; re.splice(n, 1), n--, r(); } } } function ni(e) { if (ut.length) { const t = [...new Set(ut)].sort( (n, r) => Mt(n) - Mt(r) ); if (ut.length = 0, De) { De.push(...t); return; } for (De = t, Xe = 0; Xe < De.length; Xe++) De[Xe](); De = null, Xe = 0; } } const Mt = (e) => e.id == null ? 1 / 0 : e.id, Do = (e, t) => { const n = Mt(e) - Mt(t); if (n === 0) { if (e.pre && !t.pre) return -1; if (t.pre && !e.pre) return 1; } return n; }; function ri(e) { Zn = !1, Rt = !0, re.sort(Do); try { for (Ce = 0; Ce < re.length; Ce++) { const t = re[Ce]; t && t.active !== !1 && ze(t, null, 14); } } finally { Ce = 0, re.length = 0, ni(), Rt = !1, vr = null, (re.length || ut.length) && ri(); } } function Vo(e, t, ...n) { if (e.isUnmounted) return; const r = e.vnode.props || q; let s = n; const i = t.startsWith("update:"), o = i && t.slice(7); if (o && o in r) { const d = `${o === "modelValue" ? "model" : o}Modifiers`, { number: h, trim: E } = r[d] || q; E && (s = n.map((R) => ee(R) ? R.trim() : R)), h && (s = n.map(to)); } let l, c = r[l = Pn(t)] || // also try camelCase event handler (#2249) r[l = Pn(Fe(t))]; !c && i && (c = r[l = Pn(pt(t))]), c && _e( c, e, 6, s ); const f = r[l + "Once"]; if (f) { if (!e.emitted) e.emitted = {}; else if (e.emitted[l]) return; e.emitted[l] = !0, _e( f, e, 6, s ); } } function si(e, t, n = !1) { const r = t.emitsCache, s = r.get(e); if (s !== void 0) return s; const i = e.emits; let o = {}, l = !1; if (!N(e)) { const c = (f) => { const d = si(f, t, !0); d && (l = !0, ne(o, d)); }; !n && t.mixins.length && t.mixins.forEach(c), e.extends && c(e.extends), e.mixins && e.mixins.forEach(c); } return !i && !l ? (J(e) && r.set(e, null), null) : (T(i) ? i.forEach((c) => o[c] = null) : ne(o, i), J(e) && r.set(e, o), o); } function mn(e, t) { return !e || !an(t) ? !1 : (t = t.slice(2).replace(/Once$/, ""), j(e, t[0].toLowerCase() + t.slice(1)) || j(e, pt(t)) || j(e, t)); } let we = null, gn = null; function rn(e) { const t = we; return we = e, gn = e && e.type.__scopeId || null, t; } function ii(e) { gn = e; } function oi() { gn = null; } function Ho(e, t = we, n) { if (!t || e._n) return e; const r = (...s) => { r._d && os(-1); const i = rn(t); let o; try { o = e(...s); } finally { rn(i), r._d && os(1); } return o; }; return r._n = !0, r._c = !0, r._d = !0, r; } function In(e) { const { type: t, vnode: n, proxy: r, withProxy: s, props: i, propsOptions: [o], slots: l, attrs: c, emit: f, render: d, renderCache: h, data: E, setupState: R, ctx: A, inheritAttrs: O } = e; let B, I; const Z = rn(e); try { if (n.shapeFlag & 4) { const Q = s || r, he = Q; B = Ae( d.call( he, Q, h, i, R, E, A ) ), I = c; } else { const Q = t; B = Ae( Q.length > 1 ? Q( i, { attrs: c, slots: l, emit: f } ) : Q( i, null /* we know it doesn't need it */ ) ), I = t.props ? c : Wo(c); } } catch (Q) { xt.length = 0, pn(Q, e, 1), B = fe(tt); } let k = B; if (I && O !== !1) { const Q = Object.keys(I), { shapeFlag: he } = k; Q.length && he & 7 && (o && Q.some(fr) && (I = zo( I, o )), k = ft(k, I)); } return n.dirs && (k = ft(k), k.dirs = k.dirs ? k.dirs.concat(n.dirs) : n.dirs), n.transition && (k.transition = n.transition), B = k, rn(Z), B; } const Wo = (e) => { let t; for (const n in e) (n === "class" || n === "style" || an(n)) && ((t || (t = {}))[n] = e[n]); return t; }, zo = (e, t) => { const n = {}; for (const r in e) (!fr(r) || !(r.slice(9) in t)) && (n[r] = e[r]); return n; }; function qo(e, t, n) { const { props: r, children: s, component: i } = e, { props: o, children: l, patchFlag: c } = t, f = i.emitsOptions; if (t.dirs || t.transition) return !0; if (n && c >= 0) { if (c & 1024) return !0; if (c & 16) return r ? Qr(r, o, f) : !!o; if (c & 8) { const d = t.dynamicProps; for (let h = 0; h < d.length; h++) { const E = d[h]; if (o[E] !== r[E] && !mn(f, E)) return !0; } } } else return (s || l) && (!l || !l.$stable) ? !0 : r === o ? !1 : r ? o ? Qr(r, o, f) : !0 : !!o; return !1; } function Qr(e, t, n) { const r = Object.keys(t); if (r.length !== Object.keys(e).length) return !0; for (let s = 0; s < r.length; s++) { const i = r[s]; if (t[i] !== e[i] && !mn(n, i)) return !0; } return !1; } function Ko({ vnode: e, parent: t }, n) { for (; t; ) { const r = t.subTree; if (r.suspense && r.suspense.activeBranch === e && (r.el = e.el), r === e) (e = t.vnode).el = n, t = t.parent; else break; } } const li = "components"; function Jt(e, t) { return Go(li, e, !0, t) || e; } const Jo = Symbol.for("v-ndc"); function Go(e, t, n = !0, r = !1) { const s = we || se; if (s) { const i = s.type; if (e === li) { const l = Kl( i, !1 ); if (l && (l === t || l === Fe(t) || l === dn(Fe(t)))) return i; } const o = ( // local registration // check instance[type] first which is resolved for options API Xr(s[e] || i[e], t) || // global registration Xr(s.appContext[e], t) ); return !o && r ? i : o; } } function Xr(e, t) { return e && (e[t] || e[Fe(t)] || e[dn(Fe(t))]); } const Qo = (e) => e.__isSuspense; function Xo(e, t) { t && t.pendingBranch ? T(e) ? t.effects.push(...e) : t.effects.push(e) : Uo(e); } const Zo = Symbol.for("v-scx"), Yo = () => Qt(Zo), Kt = {}; function kn(e, t, n) { return ci(e, t, n); } function ci(e, t, { immediate: n, deep: r, flush: s, once: i, onTrack: o, onTrigger: l } = q) { if (t && i) { const U = t; t = (...Te) => { U(...Te), he(); }; } const c = se, f = (U) => r === !0 ? U : ( // for deep: false, only traverse root-level properties ot(U, r === !1 ? 1 : void 0) ); let d, h = !1, E = !1; if (de(e) ? (d = () => e.value, h = Xn(e)) : at(e) ? (d = () => f(e), h = !0) : T(e) ? (E = !0, h = e.some((U) => at(U) || Xn(U)), d = () => e.map((U) => { if (de(U)) return U.value; if (at(U)) return f(U); if (N(U)) return ze(U, c, 2); })) : N(e) ? t ? d = () => ze(e, c, 2) : d = () => (R && R(), _e( e, c, 3, [A] )) : d = pe, t && r) { const U = d; d = () => ot(U()); } let R, A = (U) => { R = k.onStop = () => { ze(U, c, 4), R = k.onStop = void 0; }; }, O; if (_n) if (A = pe, t ? n && _e(t, c, 3, [ d(), E ? [] : void 0, A ]) : d(), s === "sync") { const U = Yo(); O = U.__watcherHandles || (U.__watcherHandles = []); } else return pe; let B = E ? new Array(e.length).fill(Kt) : Kt; const I = () => { if (!(!k.active || !k.dirty)) if (t) { const U = k.run(); (r || h || (E ? U.some((Te, Se) => et(Te, B[Se])) : et(U, B))) && (R && R(), _e(t, c, 3, [ U, // pass undefined as the old value when it's changed for the first time B === Kt ? void 0 : E && B[0] === Kt ? [] : B, A ]), B = U); } else k.run(); }; I.allowRecurse = !!t; let Z; s === "sync" ? Z = I : s === "post" ? Z = () => ce(I, c && c.suspense) : (I.pre = !0, c && (I.id = c.uid), Z = () => Or(I)); const k = new pr(d, pe, Z), Q = uo(), he = () => { k.stop(), Q && dr(Q.effects, k); }; return t ? n ? I() : B = k.run() : s === "post" ? ce( k.run.bind(k), c && c.suspense ) : k.run(), O && O.push(he), he; } function el(e, t, n) { const r = this.proxy, s = ee(e) ? e.includes(".") ? ai(r, e) : () => r[e] : e.bind(r, r); let i; N(t) ? i = t : (i = t.handler, n = t); const o = Nt(this), l = ci(s, i.bind(r), n); return o(), l; } function ai(e, t) { const n = t.split("."); return () => { let r = e; for (let s = 0; s < n.length && r; s++) r = r[n[s]]; return r; }; } function ot(e, t, n = 0, r) { if (!J(e) || e.__v_skip) return e; if (t && t > 0) { if (n >= t) return e; n++; } if (r = r || /* @__PURE__ */ new Set(), r.has(e)) return e; if (r.add(e), de(e)) ot(e.value, t, n, r); else if (T(e)) for (let s = 0; s < e.length; s++) ot(e[s], t, n, r); else if (Ps(e) || ct(e)) e.forEach((s) => { ot(s, t, n, r); }); else if (Bs(e)) for (const s in e) ot(e[s], t, n, r); return e; } function Ge(e, t, n, r) { const s = e.dirs, i = t && t.dirs; for (let o = 0; o < s.length; o++) { const l = s[o]; i && (l.oldValue = i[o].value); let c = l.dir[r]; c && (nt(), _e(c, n, 8, [ e.el, l, e, t ]), rt()); } } /*! #__NO_SIDE_EFFECTS__ */ // @__NO_SIDE_EFFECTS__ function Tt(e, t) { return N(e) ? ( // #8326: extend call and options.name access are considered side-effects // by Rollup, so we have to wrap it in a pure-annotated IIFE. ne({ name: e.name }, t, { setup: e }) ) : e; } const Gt = (e) => !!e.type.__asyncLoader, ui = (e) => e.type.__isKeepAlive; function tl(e, t) { fi(e, "a", t); } function nl(e, t) { fi(e, "da", t); } function fi(e, t, n = se) { const r = e.__wdc || (e.__wdc = () => { let s = n; for (; s; ) { if (s.isDeactivated) return; s = s.parent; } return e(); }); if (bn(t, r, n), n) { let s = n.parent; for (; s && s.parent; ) ui(s.parent.vnode) && rl(r, t, n, s), s = s.parent; } } function rl(e, t, n, r) { const s = bn( t, e, r, !0 /* prepend */ ); di(() => { dr(r[t], s); }, n); } function bn(e, t, n = se, r = !1) { if (n) { const s = n[e] || (n[e] = []), i = t.__weh || (t.__weh = (...o) => { if (n.isUnmounted) return; nt(); const l = Nt(n), c = _e(t, n, e, o); return l(), rt(), c; }); return r ? s.unshift(i) : s.push(i), i; } } const ke = (e) => (t, n = se) => ( // post-create lifecycle registrations are noops during SSR (except for serverPrefetch) (!_n || e === "sp") && bn(e, (...r) => t(...r), n) ), sl = ke("bm"), il = ke("m"), ol = ke("bu"), ll = ke("u"), cl = ke("bum"), di = ke("um"), al = ke("sp"), ul = ke( "rtg" ), fl = ke( "rtc" ); function dl(e, t = se) { bn("ec", e, t); } function hl(e, t, n, r) { let s; const i = n && n[r]; if (T(e) || ee(e)) { s = new Array(e.length); for (let o = 0, l = e.length; o < l; o++) s[o] = t(e[o], o, void 0, i && i[o]); } else if (typeof e == "number") { s = new Array(e); for (let o = 0; o < e; o++) s[o] = t(o + 1, o, void 0, i && i[o]); } else if (J(e)) if (e[Symbol.iterator]) s = Array.from( e, (o, l) => t(o, l, void 0, i && i[l]) ); else { const o = Object.keys(e); s = new Array(o.length); for (let l = 0, c = o.length; l < c; l++) { const f = o[l]; s[l] = t(e[f], f, l, i && i[l]); } } else s = []; return n && (n[r] = s), s; } const Yn = (e) => e ? Oi(e) ? Rr(e) || e.proxy : Yn(e.parent) : null, vt = ( // Move PURE marker to new line to workaround compiler discarding it // due to type annotation /* @__PURE__ */ ne(/* @__PURE__ */ Object.create(null), { $: (e) => e, $el: (e) => e.vnode.el, $data: (e) => e.data, $props: (e) => e.props, $attrs: (e) => e.attrs, $slots: (e) => e.slots, $refs: (e) => e.refs, $parent: (e) => Yn(e.parent), $root: (e) => Yn(e.root), $emit: (e) => e.emit, $options: (e) => xr(e), $forceUpdate: (e) => e.f || (e.f = () => { e.effect.dirty = !0, Or(e.update); }), $nextTick: (e) => e.n || (e.n = ko.bind(e.proxy)), $watch: (e) => el.bind(e) }) ), $n = (e, t) => e !== q && !e.__isScriptSetup && j(e, t), pl = { get({ _: e }, t) { const { ctx: n, setupState: r, data: s, props: i, accessCache: o, type: l, appContext: c } = e; let f; if (t[0] !== "$") { const R = o[t]; if (R !== void 0) switch (R) { case 1: return r[t]; case 2: return s[t]; case 4: return n[t]; case 3: return i[t]; } else { if ($n(r, t)) return o[t] = 1, r[t]; if (s !== q && j(s, t)) return o[t] = 2, s[t]; if ( // only cache other properties when instance has declared (thus stable) // props (f = e.propsOptions[0]) && j(f, t) ) return o[t] = 3, i[t]; if (n !== q && j(n, t)) return o[t] = 4, n[t]; er && (o[t] = 0); } } const d = vt[t]; let h, E; if (d) return t === "$attrs" && ae(e, "get", t), d(e); if ( // css module (injected by vue-loader) (h = l.__cssModules) && (h = h[t]) ) return h; if (n !== q && j(n, t)) return o[t] = 4, n[t]; if ( // global properties E = c.config.globalProperties, j(E, t) ) return E[t]; }, set({ _: e }, t, n) { const { data: r, setupState: s, ctx: i } = e; return $n(s, t) ? (s[t] = n, !0) : r !== q && j(r, t) ? (r[t] = n, !0) : j(e.props, t) || t[0] === "$" && t.slice(1) in e ? !1 : (i[t] = n, !0); }, has({ _: { data: e, setupState: t, accessCache: n, ctx: r, appContext: s, propsOptions: i } }, o) { let l; return !!n[o] || e !== q && j(e, o) || $n(t, o) || (l = i[0]) && j(l, o) || j(r, o) || j(vt, o) || j(s.config.globalProperties, o); }, defineProperty(e, t, n) { return n.get != null ? e._.accessCache[t] = 0 : j(n, "value") && this.set(e, t, n.value, null), Reflect.defineProperty(e, t, n); } }; function Zr(e) { return T(e) ? e.reduce( (t, n) => (t[n] = null, t), {} ) : e; } let er = !0; function ml(e) { const t = xr(e), n = e.proxy, r = e.ctx; er = !1, t.beforeCreate && Yr(t.beforeCreate, e, "bc"); const { // state data: s, computed: i, methods: o, watch: l, provide: c, inject: f, // lifecycle created: d, beforeMount: h, mounted: E, beforeUpdate: R, updated: A, activated: O, deactivated: B, beforeDestroy: I, beforeUnmount: Z, destroyed: k, unmounted: Q, render: he, renderTracked: U, renderTriggered: Te, errorCaptured: Se, serverPrefetch: An, // public API expose: qe, inheritAttrs: bt, // assets components: $t, directives: jt, filters: Cn } = t; if (f && gl(f, r, null), o) for (const K in o) { const W = o[K]; N(W) && (r[K] = W.bind(n)); } if (s) { const K = s.call(n, n); J(K) && (e.data = yr(K)); } if (er = !0, i) for (const K in i) { const W = i[K], Ke = N(W) ? W.bind(n, n) : N(W.get) ? W.get.bind(n, n) : pe, Ut = !N(W) && N(W.set) ? W.set.bind(n) : pe, Je = Gl({ get: Ke, set: Ut }); Object.defineProperty(r, K, { enumerable: !0, configurable: !0, get: () => Je.value, set: (Ee) => Je.value = Ee }); } if (l) for (const K in l) hi(l[K], r, n, K); if (c) { const K = N(c) ? c.call(n) : c; Reflect.ownKeys(K).forEach((W) => { El(W, K[W]); }); } d && Yr(d, e, "c"); function ie(K, W) { T(W) ? W.forEach((Ke) => K(Ke.bind(n))) : W && K(W.bind(n)); } if (ie(sl, h), ie(il, E), ie(ol, R), ie(ll, A), ie(tl, O), ie(nl, B), ie(dl, Se), ie(fl, U), ie(ul, Te), ie(cl, Z), ie(di, Q), ie(al, An), T(qe)) if (qe.length) { const K = e.exposed || (e.exposed = {}); qe.forEach((W) => { Object.defineProperty(K, W, { get: () => n[W], set: (Ke) => n[W] = Ke }); }); } else e.exposed || (e.exposed = {}); he && e.render === pe && (e.render = he), bt != null && (e.inheritAttrs = bt), $t && (e.components = $t), jt && (e.directives = jt); } function gl(e, t, n = pe) { T(e) && (e = tr(e)); for (const r in e) { const s = e[r]; let i; J(s) ? "default" in s ? i = Qt( s.from || r, s.default, !0 ) : i = Qt(s.from || r) : i = Qt(s), de(i) ? Object.defineProperty(t, r, { enumerable: !0, configurable: !0, get: () => i.value, set: (o) => i.value = o }) : t[r] = i; } } function Yr(e, t, n) { _e( T(e) ? e.map((r) => r.bind(t.proxy)) : e.bind(t.proxy), t, n ); } function hi(e, t, n, r) { const s = r.includes(".") ? ai(n, r) : () => n[r]; if (ee(e)) { const i = t[e]; N(i) && kn(s, i); } else if (N(e)) kn(s, e.bind(n)); else if (J(e)) if (T(e)) e.forEach((i) => hi(i, t, n, r)); else { const i = N(e.handler) ? e.handler.bind(n) : t[e.handler]; N(i) && kn(s, i, e); } } function xr(e) { const t = e.type, { mixins: n, extends: r } = t, { mixins: s, optionsCache: i, config: { optionMergeStrategies: o } } = e.appContext, l = i.get(t); let c; return l ? c = l : !s.length && !n && !r ? c = t : (c = {}, s.length && s.forEach( (f) => sn(c, f, o, !0) ), sn(c, t, o)), J(t) && i.set(t, c), c; } function sn(e, t, n, r = !1) { const { mixins: s, extends: i } = t; i && sn(e, i, n, !0), s && s.forEach( (o) => sn(e, o, n, !0) ); for (const o in t) if (!(r && o === "expose")) { const l = bl[o] || n && n[o]; e[o] = l ? l(e[o], t[o]) : t[o]; } return e; } const bl = { data: es, props: ts, emits: ts, // objects methods: St, computed: St, // lifecycle beforeCreate: oe, created: oe, beforeMount: oe, mounted: oe, beforeUpdate: oe, updated: oe, beforeDestroy: oe, beforeUnmount: oe, destroyed: oe, unmounted: oe, activated: oe, deactivated: oe, errorCaptured: oe, serverPrefetch: oe, // assets components: St, directives: St, // watch watch: yl, // provide / inject provide: es, inject: wl }; function es(e, t) { return t ? e ? function() { return ne( N(e) ? e.call(this, this) : e, N(t) ? t.call(this, this) : t ); } : t : e; } function wl(e, t) { return St(tr(e), tr(t)); } function tr(e) { if (T(e)) { const t = {}; for (let n = 0; n < e.length; n++) t[e[n]] = e[n]; return t; } return e; } function oe(e, t) { return e ? [...new Set([].concat(e, t))] : t; } function St(e, t) { return e ? ne(/* @__PURE__ */ Object.create(null), e, t) : t; } function ts(e, t) { return e ? T(e) && T(t) ? [.../* @__PURE__ */ new Set([...e, ...t])] : ne( /* @__PURE__ */ Object.create(null), Zr(e), Zr(t ?? {}) ) : t; } function yl(e, t) { if (!e) return t; if (!t) return e; const n = ne(/* @__PURE__ */ Object.create(null), e); for (const r in t) n[r] = oe(e[r], t[r]); return n; } function pi() { return { app: null, config: { isNativeTag: Qi, performance: !1, globalProperties: {}, optionMergeStrategies: {}, errorHandler: void 0, warnHandler: void 0, compilerOptions: {} }, mixins: [], components: {}, directives: {}, provides: /* @__PURE__ */ Object.create(null), optionsCache: /* @__PURE__ */ new WeakMap(), propsCache: /* @__PURE__ */ new WeakMap(), emitsCache: /* @__PURE__ */ new WeakMap() }; } let _l = 0; function Sl(e, t) { return function(r, s = null) { N(r) || (r = ne({}, r)), s != null && !J(s) && (s = null); const i = pi(), o = /* @__PURE__ */ new WeakSet(); let l = !1; const c = i.app = { _uid: _l++, _component: r, _props: s, _container: null, _context: i, _instance: null, version: Ql, get config() { return i.config; }, set config(f) { }, use(f, ...d) { return o.has(f) || (f && N(f.install) ? (o.add(f), f.install(c, ...d)) : N(f) && (o.add(f), f(c, ...d))), c; }, mixin(f) { return i.mixins.includes(f) || i.mixins.push(f), c; }, component(f, d) { return d ? (i.components[f] = d, c) : i.components[f]; }, directive(f, d) { return d ? (i.directives[f] = d, c) : i.directives[f]; }, mount(f, d, h) { if (!l) { const E = fe(r, s); return E.appContext = i, h === !0 ? h = "svg" : h === !1 && (h = void 0), d && t ? t(E, f) : e(E, f, h), l = !0, c._container = f, f.__vue_app__ = c, Rr(E.component) || E.component.proxy; } }, unmount() { l && (e(null, c._container), delete c._container.__vue_app__); }, provide(f, d) { return i.provides[f] = d, c; }, runWithContext(f) { const d = Ot; Ot = c; try { return f(); } finally { Ot = d; } } }; return c; }; } let Ot = null; function El(e, t) { if (se) { let n = se.provides; const r = se.parent && se.parent.provides; r === n && (n = se.provides = Object.create(r)), n[e] = t; } } function Qt(e, t, n = !1) { const r = se || we; if (r || Ot) { const s = r ? r.parent == null ? r.vnode.appContext && r.vnode.appContext.provides : r.parent.provides : Ot._context.provides; if (s && e in s) return s[e]; if (arguments.length > 1) return n && N(t) ? t.call(r && r.proxy) : t; } } function vl(e, t, n, r = !1) { const s = {}, i = {}; nn(i, yn, 1), e.propsDefaults = /* @__PURE__ */ Object.create(null), mi(e, t, s, i); for (const o in e.propsOptions[0]) o in s || (s[o] = void 0); n ? e.props = r ? s : Po(s) : e.type.props ? e.props = s : e.props = i, e.attrs = i; } function Ol(e, t, n, r) { const { props: s, attrs: i, vnode: { patchFlag: o } } = e, l = D(s), [c] = e.propsOptions; let f = !1; if ( // always force full diff in dev // - #1942 if hmr is enabled with sfc component // - vite#872 non-sfc component used by sfc component (r || o > 0) && !(o & 16) ) { if (o & 8) { const d = e.vnode.dynamicProps; for (let h = 0; h < d.length; h++) { let E = d[h]; if (mn(e.emitsOptions, E)) continue; const R = t[E]; if (c) if (j(i, E)) R !== i[E] && (i[E] = R, f = !0); else { const A = Fe(E); s[A] = nr( c, l, A, R, e, !1 ); } else R !== i[E] && (i[E] = R, f = !0); } } } else { mi(e, t, s, i) && (f = !0); let d; for (const h in l) (!t || // for camelCase !j(t, h) && // it's possible the original props was passed in as kebab-case // and converted to camelCase (#955) ((d = pt(h)) === h || !j(t, d))) && (c ? n && // for camelCase (n[h] !== void 0 || // for kebab-case n[d] !== void 0) && (s[h] = nr( c, l, h, void 0, e, !0 )) : delete s[h]); if (i !== l) for (const h in i) (!t || !j(t, h)) && (delete i[h], f = !0); } f && Le(e, "set", "$attrs"); } function mi(e, t, n, r) { const [s, i] = e.propsOptions; let o = !1, l; if (t) for (let c in t) { if (Et(c)) continue; const f = t[c]; let d; s && j(s, d = Fe(c)) ? !i || !i.includes(d) ? n[d] = f : (l || (l = {}))[d] = f : mn(e.emitsOptions, c) || (!(c in r) || f !== r[c]) && (r[c] = f, o = !0); } if (i) { const c = D(n), f = l || q; for (let d = 0; d < i.length; d++) { const h = i[d]; n[h] = nr( s, c, h, f[h], e, !j(f, h) ); } } return o; } function nr(e, t, n, r, s, i) { const o = e[n]; if (o != null) { const l = j(o, "default"); if (l && r === void 0) { const c = o.default; if (o.type !== Function && !o.skipFactory && N(c)) { const { propsDefaults: f } = s; if (n in f) r = f[n]; else { const d = Nt(s); r = f[n] = c.call( null, t ), d(); } } else r = c; } o[ 0 /* shouldCast */ ] && (i && !l ? r = !1 : o[ 1 /* shouldCastTrue */ ] && (r === "" || r === pt(n)) && (r = !0)); } return r; } function gi(e, t, n = !1) { const r = t.propsCache, s = r.get(e); if (s) return s; const i = e.props, o = {}, l = []; let c = !1; if (!N(e)) { const d = (h) => { c = !0; const [E, R] = gi(h, t, !0); ne(o, E), R && l.push(...R); }; !n && t.mixins.length && t.mixins.forEach(d), e.extends && d(e.extends), e.mixins && e.mixins.forEach(d); } if (!i && !c) return J(e) && r.set(e, lt), lt; if (T(i)) for (let d = 0; d < i.length; d++) { const h = Fe(i[d]); ns(h) && (o[h] = q); } else if (i) for (const d in i) { const h = Fe(d); if (ns(h)) { const E = i[d], R = o[h] = T(E) || N(E) ? { type: E } : ne({}, E); if (R) { const A = is(Boolean, R.type), O = is(String, R.type); R[ 0 /* shouldCast */ ] = A > -1, R[ 1 /* shouldCastTrue */ ] = O < 0 || A < O, (A > -1 || j(R, "default")) && l.push(h); } } } const f = [o, l]; return J(e) && r.set(e, f), f; } function ns(e) { return e[0] !== "$" && !Et(e); } function rs(e) { return e === null ? "null" : typeof e == "function" ? e.name || "" : typeof e == "object" && e.constructor && e.constructor.name || ""; } function ss(e, t) { return rs(e) === rs(t); } function is(e, t) { return T(t) ? t.findIndex((n) => ss(n, e)) : N(t) && ss(t, e) ? 0 : -1; } const bi = (e) => e[0] === "_" || e === "$stable", Ar = (e) => T(e) ? e.map(Ae) : [Ae(e)], xl = (e, t, n) => { if (t._n) return t; const r = Ho((...s) => Ar(t(...s)), n); return r._c = !1, r; }, wi = (e, t, n) => { const r = e._ctx; for (const s in e) { if (bi(s)) continue; const i = e[s]; if (N(i)) t[s] = xl(s, i, r); else if (i != null) { const o = Ar(i); t[s] = () => o; } } }, yi = (e, t) => { const n = Ar(t); e.slots.default = () => n; }, Al = (e, t) => { if (e.vnode.shapeFlag & 32) { const n = t._; n ? (e.slots = D(t), nn(t, "_", n)) : wi( t, e.slots = {} ); } else e.slots = {}, t && yi(e, t); nn(e.slots, yn, 1); }, Cl = (e, t, n) => { const { vnode: r, slots: s } = e; let i = !0, o = q; if (r.shapeFlag & 32) { const l = t._; l ? n && l === 1 ? i = !1 : (ne(s, t), !n && l === 1 && delete s._) : (i = !t.$stable, wi(t, s)), o = t; } else t && (yi(e, t), o = { default: 1 }); if (i) for (const l in s) !bi(l) && o[l] == null && delete s[l]; }; function rr(e, t, n, r, s = !1) { if (T(e)) { e.forEach( (E, R) => rr( E, t && (T(t) ? t[R] : t), n, r, s ) ); return; } if (Gt(r) && !s) return; const i = r.shapeFlag & 4 ? Rr(r.component) || r.component.proxy : r.el, o = s ? null : i, { i: l, r: c } = e, f = t && t.r, d = l.refs === q ? l.refs = {} : l.refs, h = l.setupState; if (f != null && f !== c && (ee(f) ? (d[f] = null, j(h, f) && (h[f] = null)) : de(f) && (f.value = null)), N(c)) ze(c, l, 12, [o, d]); else { const E = ee(c), R = de(c); if (E || R) { const A = () => { if (e.f) { const O = E ? j(h, c) ? h[c] : d[c] : c.value; s ? T(O) && dr(O, i) : T(O) ? O.includes(i) || O.push(i) : E ? (d[c] = [i], j(h, c) && (h[c] = d[c])) : (c.value = [i], e.k && (d[e.k] = c.value)); } else E ? (d[c] = o, j(h, c) && (h[c] = o)) : R && (c.value = o, e.k && (d[e.k] = o)); }; o ? (A.id = -1, ce(A, n)) : A(); } } } const ce = Xo; function Rl(e) { return Ml(e); } function Ml(e, t) { const n = Ls(); n.__VUE__ = !0; const { insert: r, remove: s, patchProp: i, createElement: o, createText: l, createComment: c, setText: f, setElementText: d, parentNode: h, nextSibling: E, setScopeId: R = pe, insertStaticContent: A } = e, O = (a, u, p, b = null, w = null, S = null, x = void 0, _ = null, v = !!u.dynamicChildren) => { if (a === u) return; a && !yt(a, u) && (b = Dt(a), Ee(a, w, S, !0), a = null), u.patchFlag === -2 && (v = !1, u.dynamicChildren = null); const { type: y, ref: C, shapeFlag: F } = u; switch (y) { case wn: B(a, u, p, b); break; case tt: I(a, u, p, b); break; case Un: a == null && Z(u, p, b, x); break; case xe: $t( a, u, p, b, w, S, x, _, v ); break; default: F & 1 ? he( a, u, p, b, w, S, x, _, v ) : F & 6 ? jt( a, u, p, b, w, S, x, _, v ) : (F & 64 || F & 128) && y.process( a, u, p, b, w, S, x, _, v, st ); } C != null && w && rr(C, a && a.ref, S, u || a, !u); }, B = (a, u, p, b) => { if (a == null) r( u.el = l(u.children), p, b ); else { const w = u.el = a.el; u.children !== a.children && f(w, u.children); } }, I = (a, u, p, b) => { a == null ? r( u.el = c(u.children || ""), p, b ) : u.el = a.el; }, Z = (a, u, p, b) => { [a.el, a.anchor] = A( a.children, u, p, b, a.el, a.anchor ); }, k = ({ el: a, anchor: u }, p, b) => { let w; for (; a && a !== u; ) w = E(a), r(a, p, b), a = w; r(u, p, b); }, Q = ({ el: a, anchor: u }) => { let p; for (; a && a !== u; ) p = E(a), s(a), a = p; s(u); }, he = (a, u, p, b, w, S, x, _, v) => { u.type === "svg" ? x = "svg" : u.type === "math" && (x = "mathml"), a == null ? U( u, p, b, w, S, x, _, v ) : An( a, u, w, S, x, _, v ); }, U = (a, u, p, b, w, S, x, _) => { let v, y; const { props: C, shapeFlag: F, transition: M, dirs: P } = a; if (v = a.el = o( a.type, S, C && C.is, C ), F & 8 ? d(v, a.children) : F & 16 && Se( a.children, v, null, b, w, jn(a, S), x, _ ), P && Ge(a, null, b, "created"), Te(v, a, a.scopeId, x, b), C) { for (const V in C) V !== "value" && !Et(V) && i( v, V, null, C[V], S, a.children, b, w, Ne ); "value" in C && i(v, "value", null, C.value, S), (y = C.onVnodeBeforeMount) && Oe(y, b, a); } P && Ge(a, null, b, "beforeMount"); const L = Fl(w, M); L && M.beforeEnter(v), r(v, u, p), ((y = C && C.onVnodeMounted) || L || P) && ce(() => { y && Oe(y, b, a), L && M.enter(v), P && Ge(a, null, b, "mounted"); }, w); }, Te = (a, u, p, b, w) => { if (p && R(a, p), b) for (let S = 0; S < b.length; S++) R(a, b[S]); if (w) { let S = w.subTree; if (u === S) { const x = w.vnode; Te( a, x, x.scopeId, x.slotScopeIds, w.parent ); } } }, Se = (a, u, p, b, w, S, x, _, v = 0) => { for (let y = v; y < a.length; y++) { const C = a[y] = _ ? Ve(a[y]) : Ae(a[y]); O( null, C, u, p, b, w, S, x, _ ); } }, An = (a, u, p, b, w, S, x) => { const _ = u.el = a.el; let { patchFlag: v, dynamicChildren: y, dirs: C } = u; v |= a.patchFlag & 16; const F = a.props || q, M = u.props || q; let P; if (p && Qe(p, !1), (P = M.onVnodeBeforeUpdate) && Oe(P, p, u, a), C && Ge(u, a, p, "beforeUpdate"), p && Qe(p, !0), y ? qe( a.dynamicChildren, y, _, p, b, jn(u, w), S ) : x || W( a, u, _, null, p, b, jn(u, w), S, !1 ), v > 0) { if (v & 16) bt( _, u, F, M, p, b, w ); else if (v & 2 && F.class !== M.class && i(_, "class", null, M.class, w), v & 4 && i(_, "style", F.style, M.style, w), v & 8) { const L = u.dynamicProps; for (let V = 0; V < L.length; V++) { const z = L[V], te = F[z], ge = M[z]; (ge !== te || z === "value") && i( _, z, te, ge, w, a.children, p, b, Ne ); } } v & 1 && a.children !== u.children && d(_, u.children); } else !x && y == null && bt( _, u, F, M, p, b, w ); ((P = M.onVnodeUpdated) || C) && ce(() => { P && Oe(P, p, u, a), C && Ge(u, a, p, "updated"); }, b); }, qe = (a, u, p, b, w, S, x) => { for (let _ = 0; _ < u.length; _++) { const v = a[_], y = u[_], C = ( // oldVNode may be an errored async setup() component inside Suspense // which will not have a mounted element v.el && // - In the case of a Fragment, we need to provide the actual parent // of the Fragment itself so it can move its children. (v.type === xe || // - In the case of different nodes, there is going to be a replacement // which also requires the correct parent container !yt(v, y) || // - In the case of a component, it could contain anything. v.shapeFlag & 70) ? h(v.el) : ( // In other cases, the parent container is not actually used so we // just pass the block element here to avoid a DOM parentNode call. p ) ); O( v, y, C, null, b, w, S, x, !0 ); } }, bt = (a, u, p, b, w, S, x) => { if (p !== b) { if (p !== q) for (const _ in p) !Et(_) && !(_ in b) && i( a, _, p[_], null, x, u.children, w, S, Ne ); for (const _ in b) { if (Et(_)) continue; const v = b[_], y = p[_]; v !== y && _ !== "value" && i( a, _, y, v, x, u.children, w, S, Ne ); } "value" in b && i(a, "value", p.value, b.value, x); } }, $t = (a, u, p, b, w, S, x, _, v) => { const y = u.el = a ? a.el : l(""), C = u.anchor = a ? a.anchor : l(""); let { patchFlag: F, dynamicChildren: M, slotScopeIds: P } = u; P && (_ = _ ? _.concat(P) : P), a == null ? (r(y, p, b), r(C, p, b), Se( // #10007 // such fragment like `<></>` will be compiled into // a fragment which doesn't have a children. // In this case fallback to an empty array u.children || [], p, C, w, S, x, _, v )) : F > 0 && F & 64 && M && // #2715 the previous fragment could've been a BAILed one as a result // of renderSlot() with no valid children a.dynamicChildren ? (qe( a.dynamicChildren, M, p, w, S, x, _ ), // #2080 if the stable fragment has a key, it's a <template v-for> that may // get moved around. Make sure all root level vnodes inherit el. // #2134 or if it's a component root, it may also get moved around // as the component is being moved. (u.key != null || w && u === w.subTree) && _i( a, u, !0 /* shallow */ )) : W( a, u, p, C, w, S, x, _, v ); }, jt = (a, u, p, b, w, S, x, _, v) => { u.slotScopeIds = _, a == null ? u.shapeFlag & 512 ? w.ctx.activate( u, p, b, x, v ) : Cn( u, p, b, w, S, x, v ) : Lr(a, u, v); }, Cn = (a, u, p, b, w, S, x) => { const _ = a.component = Vl( a, b, w ); if (ui(a) && (_.ctx.renderer = st), Hl(_), _.asyncDep) { if (w && w.registerDep(_, ie), !a.el) { const v = _.subTree = fe(tt); I(null, v, u, p); } } else ie( _, a, u, p, w, S, x ); }, Lr = (a, u, p) => { const b = u.component = a.component; if (qo(a, u, p)) if (b.asyncDep && !b.asyncResolved) { K(b, u, p); return; } else b.next = u, jo(b.update), b.effect.dirty = !0, b.update(); else u.el = a.el, b.vnode = u; }, ie = (a, u, p, b, w, S, x) => { const _ = () => { if (a.isMounted) { let { next: C, bu: F, u: M, parent: P, vnode: L } = a; { const it = Si(a); if (it) { C && (C.el = L.el, K(a, C, x)), it.asyncDep.then(() => { a.isUnmounted || _(); }); return; } } let V = C, z; Qe(a, !1), C ? (C.el = L.el, K(a, C, x)) : C = L, F && Tn(F), (z = C.props && C.props.onVnodeBeforeUpdate) && Oe(z, P, C, L), Qe(a, !0); const te = In(a), ge = a.subTree; a.subTree = te, O( ge, te, // parent may have changed if it's in a teleport h(ge.el), // anchor may have changed if it's in a fragment Dt(ge), a, w, S ), C.el = te.el, V === null && Ko(a, te.el), M && ce(M, w), (z = C.props && C.props.onVnodeUpdated) && ce( () => Oe(z, P, C, L), w ); } else { let C; const { el: F, props: M } = u, { bm: P, m: L, parent: V } = a, z = Gt(u); if (Qe(a, !1), P && Tn(P), !z && (C = M && M.onVnodeBeforeMount) && Oe(C, V, u), Qe(a, !0), F && Fn) { const te = () => { a.subTree = In(a), Fn( F, a.subTree, a, w, null ); }; z ? u.type.__asyncLoader().then( // note: we are moving the render call into an async callback, // which means it won't track dependencies - but it's ok because // a server-rendered async wrapper is already in resolved state // and it will never need to change. () => !a.isUnmounted && te() ) : te(); } else { const te = a.subTree = In(a); O( null, te, p, b, a, w, S ), u.el = te.el; } if (L && ce(L, w), !z && (C = M && M.onVnodeMounted)) { const te = u; ce( () => Oe(C, V, te), w ); } (u.shapeFlag & 256 || V && Gt(V.vnode) && V.vnode.shapeFlag & 256) && a.a && ce(a.a, w), a.isMounted = !0, u = p = b = null; } }, v = a.effect = new pr( _, pe, () => Or(y), a.scope // track it in component's effect scope ), y = a.update = () => { v.dirty && v.run(); }; y.id = a.uid, Qe(a, !0), y(); }, K = (a, u, p) => { u.component = a; const b = a.vnode.props; a.vnode = u, a.next = null, Ol(a, u.props, b, p), Cl(a, u.children, p), nt(), Gr(a), rt(); }, W = (a, u, p, b, w, S, x, _, v = !1) => { const y = a && a.children, C = a ? a.shapeFlag : 0, F = u.children, { patchFlag: M, shapeFlag: P } = u; if (M > 0) { if (M & 128) { Ut( y, F, p, b, w, S, x, _, v ); return; } else if (M & 256) { Ke( y, F, p, b, w, S, x, _, v ); return; } } P & 8 ? (C & 16 && Ne(y, w, S), F !== y && d(p, F)) : C & 16 ? P & 16 ? Ut( y, F, p, b, w, S, x, _, v ) : Ne(y, w, S, !0) : (C & 8 && d(p, ""), P & 16 && Se( F, p, b, w, S, x, _, v )); }, Ke = (a, u, p, b, w, S, x, _, v) => { a = a || lt, u = u || lt; const y = a.length, C = u.length, F = Math.min(y, C); let M; for (M = 0; M < F; M++) { const P = u[M] = v ? Ve(u[M]) : Ae(u[M]); O( a[M], P, p, null, w, S, x, _, v ); } y > C ? Ne( a, w, S, !0, !1, F ) : Se( u, p, b, w, S, x, _, v, F ); }, Ut = (a, u, p, b, w, S, x, _, v) => { let y = 0; const C = u.length; let F = a.length - 1, M = C - 1; for (; y <= F && y <= M; ) { const P = a[y], L = u[y] = v ? Ve(u[y]) : Ae(u[y]); if (yt(P, L)) O( P, L, p, null, w, S, x, _, v ); else break; y++; } for (; y <= F && y <= M; ) { const P = a[F], L = u[M] = v ? Ve(u[M]) : Ae(u[M]); if (yt(P, L)) O( P, L, p, null, w, S, x, _, v ); else break; F--, M--; } if (y > F) { if (y <= M) { const P = M + 1, L = P < C ? u[P].el : b; for (; y <= M; ) O( null, u[y] = v ? Ve(u[y]) : Ae(u[y]), p, L, w, S, x, _, v ), y++; } } else if (y > M) for (; y <= F; ) Ee(a[y], w, S, !0), y++; else { const P = y, L = y, V = /* @__PURE__ */ new Map(); for (y = L; y <= M; y++) { const ue = u[y] = v ? Ve(u[y]) : Ae(u[y]); ue.key != null && V.set(ue.key, y); } let z, te = 0; const ge = M - L + 1; let it = !1, $r = 0; const wt = new Array(ge); for (y = 0; y < ge; y++) wt[y] = 0; for (y = P; y <= F; y++) { const ue = a[y]; if (te >= ge) { Ee(ue, w, S, !0); continue; } let ve; if (ue.key != null) ve = V.get(ue.key); else for (z = L; z <= M; z++) if (wt[z - L] === 0 && yt(ue, u[z])) { ve = z; break; } ve === void 0 ? Ee(ue, w, S, !0) : (wt[ve - L] = y + 1, ve >= $r ? $r = ve : it = !0, O( ue, u[ve], p, null, w, S, x, _, v ), te++); } const jr = it ? Pl(wt) : lt; for (z = jr.length - 1, y = ge - 1; y >= 0; y--) { const ue = L + y, ve = u[ue], Ur = ue + 1 < C ? u[ue + 1].el : b; wt[y] === 0 ? O( null, ve, p, Ur, w, S, x, _, v ) : it && (z < 0 || y !== jr[z] ? Je(ve, p, Ur, 2) : z--); } } }, Je = (a, u, p, b, w = null) => { const { el: S, type: x, transition: _, children: v, shapeFlag: y } = a; if (y & 6) { Je(a.component.subTree, u, p, b); return; } if (y & 128) { a.suspense.move(u, p, b); return; } if (y & 64) { x.move(a, u, p, st); return; } if (x === xe) { r(S, u, p); for (let F = 0; F < v.length; F++) Je(v[F], u, p, b); r(a.anchor, u, p); return; } if (x === Un) { k(a, u, p); return; } if (b !== 2 && y & 1 && _) if (b === 0) _.beforeEnter(S), r(S, u, p), ce(() => _.enter(S), w); else { const { leave: F, delayLeave: M, afterLeave: P } = _, L = () => r(S, u, p), V = () => { F(S, () => { L(), P && P(); }); }; M ? M(S, L, V) : V(); } else r(S, u, p); }, Ee = (a, u, p, b = !1, w = !1) => { const { type: S, props: x, ref: _, children: v, dynamicChildren: y, shapeFlag: C, patchFlag: F, dirs: M } = a; if (_ != null && rr(_, null, p, a, !0), C & 256) { u.ctx.deactivate(a); return; } const P = C & 1 && M, L = !Gt(a); let V; if (L && (V = x && x.onVnodeBeforeUnmount) && Oe(V, u, a), C & 6) Gi(a.component, p, b); else { if (C & 128) { a.suspense.unmount(p, b); return; } P && Ge(a, null, u, "beforeUnmount"), C & 64 ? a.type.remove( a, u, p, w, st, b ) : y && // #1153: fast path should not be taken for non-stable (v-for) fragments (S !== xe || F > 0 && F & 64) ? Ne( y, u, p, !1, !0 ) : (S === xe && F & 384 || !w && C & 16) && Ne(v, u, p), b && Ir(a); } (L && (V = x && x.onVnodeUnmounted) || P) && ce(() => { V && Oe(V, u, a), P && Ge(a, null, u, "unmounted"); }, p); }, Ir = (a) => { const { type: u, el: p, anchor: b, transition: w } = a; if (u === xe) { Ji(p, b); return; } if (u === Un) { Q(a); return; } const S = () => { s(p), w && !w.persisted && w.afterLeave && w.afterLeave(); }; if (a.shapeFlag & 1 && w && !w.persisted) { const { leave: x, delayLeave: _ } = w, v = () => x(p, S); _ ? _(a.el, S, v) : v(); } else S(); }, Ji = (a, u) => { let p; for (; a !== u; ) p = E(a), s(a), a = p; s(u); }, Gi = (a, u, p) => { const { bum: b, scope: w, update: S, subTree: x, um: _ } = a; b && Tn(b), w.stop(), S && (S.active = !1, Ee(x, a, u, p)), _ && ce(_, u), ce(() => { a.isUnmounted = !0; }, u), u && u.pendingBranch && !u.isUnmounted && a.asyncDep && !a.asyncResolved && a.suspenseId === u.pendingId && (u.deps--, u.deps === 0 && u.resolve()); }, Ne = (a, u, p, b = !1, w = !1, S = 0) => { for (let x = S; x < a.length; x++) Ee(a[x], u, p, b, w); }, Dt = (a) => a.shapeFlag & 6 ? Dt(a.component.subTree) : a.shapeFlag & 128 ? a.suspense.next() : E(a.anchor || a.el); let Rn = !1; const kr = (a, u, p) => { a == null ? u._vnode && Ee(u._vnode, null, null, !0) : O( u._vnode || null, a, u, null, null, null, p ), Rn || (Rn = !0, Gr(), ni(), Rn = !1), u._vnode = a; }, st = { p: O, um: Ee, m: Je, r: Ir, mt: Cn, mc: Se, pc: W, pbc: qe, n: Dt, o: e }; let Mn, Fn; return t && ([Mn, Fn] = t( st )), { render: kr, hydrate: Mn, createApp: Sl(kr, Mn) }; } function jn({ type: e, props: t }, n) { return n === "svg" && e === "foreignObject" || n === "mathml" && e === "annotation-xml" && t && t.encoding && t.encoding.includes("html") ? void 0 : n; } function Qe({ effect: e, update: t }, n) { e.allowRecurse = t.allowRecurse = n; } function Fl(e, t) { return (!e || e && !e.pendingBranch) && t && !t.persisted; } function _i(e, t, n = !1) { const r = e.children, s = t.children; if (T(r) && T(s)) for (let i = 0; i < r.length; i++) { const o = r[i]; let l = s[i]; l.shapeFlag & 1 && !l.dynamicChildren && ((l.patchFlag <= 0 || l.patchFlag === 32) && (l = s[i] = Ve(s[i]), l.el = o.el), n || _i(o, l)), l.type === wn && (l.el = o.el); } } function Pl(e) { const t = e.slice(), n = [0]; let r, s, i, o, l; const c = e.length; for (r = 0; r < c; r++) { const f = e[r]; if (f !== 0) { if (s = n[n.length - 1], e[s] < f) { t[r] = s, n.push(r); continue; } for (i = 0, o = n.length - 1; i < o; ) l = i + o >> 1, e[n[l]] < f ? i = l + 1 : o = l; f < e[n[i]] && (i > 0 && (t[r] = n[i - 1]), n[i] = r); } } for (i = n.length, o = n[i - 1]; i-- > 0; ) n[i] = o, o = t[o]; return n; } function Si(e) { const t = e.subTree.component; if (t) return t.asyncDep && !t.asyncResolved ? t : Si(t); } const Tl = (e) => e.__isTeleport, xe = Symbol.for("v-fgt"), wn = Symbol.for("v-txt"), tt = Symbol.for("v-cmt"), Un = Symbol.for("v-stc"), xt = []; let ye = null; function Re(e = !1) { xt.push(ye = e ? null : []); } function Nl() { xt.pop(), ye = xt[xt.length - 1] || null; } let Ft = 1; function os(e) { Ft += e; } function Ei(e) { return e.dynamicChildren = Ft > 0 ? ye || lt : null, Nl(), Ft > 0 && ye && ye.push(e), e; } function Be(e, t, n, r, s, i) { return Ei( Y( e, t, n, r, s, i, !0 ) ); } function Bl(e, t, n, r, s) { return Ei( fe( e, t, n, r, s, !0 ) ); } function Ll(e) { return e ? e.__v_isVNode === !0 : !1; } function yt(e, t) { return e.type === t.type && e.key === t.key; } const yn = "__vInternal", vi = ({ key: e }) => e ?? null, Xt = ({ ref: e, ref_key: t, ref_for: n }) => (typeof e == "number" && (e = "" + e), e != null ? ee(e) || de(e) || N(e) ? { i: we, r: e, k: t, f: !!n } : e : null); function Y(e, t = null, n = null, r = 0, s = null, i = e === xe ? 0 : 1, o = !1, l = !1) { const c = { __v_isVNode: !0, __v_skip: !0, type: e, props: t, key: t && vi(t), ref: t && Xt(t), scopeId: gn, slotScopeIds: null, children: n, component: null, suspense: null, ssContent: null, ssFallback: null, dirs: null, transition: null, el: null, anchor: null, target: null, targetAnchor: null, staticCount: 0, shapeFlag: i, patchFlag: r, dynamicProps: s, dynamicChildren: null, appContext: null, ctx: we }; return l ? (Cr(c, n), i & 128 && e.normalize(c)) : n && (c.shapeFlag |= ee(n) ? 8 : 16), Ft > 0 && // avoid a block node from tracking itself !o && // has current parent block ye && // presence of a patch flag indicates this node needs patching on updates. // component nodes also should always be patched, because even if the // component doesn't need to update, it needs to persist the instance on to // the next vnode so that it can be properly unmounted later. (c.patchFlag > 0 || i & 6) && // the EVENTS flag is only for hydration and if it is the only flag, the // vnode should not be considered dynamic due to handler caching. c.patchFlag !== 32 && ye.push(c), c; } const fe = Il; function Il(e, t = null, n = null, r = 0, s = null, i = !1) { if ((!e || e === Jo) && (e = tt), Ll(e)) { const l = ft( e, t, !0 /* mergeRef: true */ ); return n && Cr(l, n), Ft > 0 && !i && ye && (l.shapeFlag & 6 ? ye[ye.indexOf(e)] = l : ye.push(l)), l.patchFlag |= -2, l; } if (Jl(e) && (e = e.__vccOpts), t) { t = kl(t); let { class: l, style: c } = t; l && !ee(l) && (t.class = mt(l)), J(c) && (Qs(c) && !T(c) && (c = ne({}, c)), t.style = At(c)); } const o = ee(e) ? 1 : Qo(e) ? 128 : Tl(e) ? 64 : J(e) ? 4 : N(e) ? 2 : 0; return Y( e, t, n, r, s, o, i, !0 ); } function kl(e) { return e ? Qs(e) || yn in e ? ne({}, e) : e : null; } function ft(e, t, n = !1) { const { props: r, ref: s, patchFlag: i, children: o } = e, l = t ? jl(r || {}, t) : r; return { __v_isVNode: !0, __v_skip: !0, type: e.type, props: l, key: l && vi(l), ref: t && t.ref ? ( // #2078 in the case of <component :is="vnode" ref="extra"/> // if the vnode itself already has a ref, cloneVNode will need to merge // the refs so the single vnode can be set on multiple refs n && s ? T(s) ? s.concat(Xt(t)) : [s, Xt(t)] : Xt(t) ) : s, scopeId: e.scopeId, slotScopeIds: e.slotScopeIds, children: o, target: e.target, targetAnchor: e.targetAnchor, staticCount: e.staticCount, shapeFlag: e.shapeFlag, // if the vnode is cloned with extra props, we can no longer assume its // existing patch flag to be reliable and need to add the FULL_PROPS flag. // note: preserve flag for fragments since they use the flag for children // fast paths only. patchFlag: t && e.type !== xe ? i === -1 ? 16 : i | 16 : i, dynamicProps: e.dynamicProps, dynamicChildren: e.dynamicChildren, appContext: e.appContext, dirs: e.dirs, transition: e.transition, // These should technically only be non-null on mounted VNodes. However, // they *should* be copied for kept-alive vnodes. So we just always copy // them since them being non-null during a mount doesn't affect the logic as // they will simply be overwritten. component: e.component, suspense: e.suspense, ssContent: e.ssContent && ft(e.ssContent), ssFallback: e.ssFallback && ft(e.ssFallback), el: e.el, anchor: e.anchor, ctx: e.ctx, ce: e.ce }; } function on(e = " ", t = 0) { return fe(wn, null, e, t); } function $l(e = "", t = !1) { return t ? (Re(), Bl(tt, null, e)) : fe(tt, null, e); } function Ae(e) { return e == null || typeof e == "boolean" ? fe(tt) : T(e) ? fe( xe, null, // #3666, avoid reference pollution when reusing vnode e.slice() ) : typeof e == "object" ? Ve(e) : fe(wn, null, String(e)); } function Ve(e) { return e.el === null && e.patchFlag !== -1 || e.memo ? e : ft(e); } function Cr(e, t) { let n = 0; const { shapeFlag: r } = e; if (t == null) t = null; else if (T(t)) n = 16; else if (typeof t == "object") if (r & 65) { const s = t.default; s && (s._c && (s._d = !1), Cr(e, s()), s._c && (s._d = !0)); return; } else { n = 32; const s = t._; !s && !(yn in t) ? t._ctx = we : s === 3 && we && (we.slots._ === 1 ? t._ = 1 : (t._ = 2, e.patchFlag |= 1024)); } else N(t) ? (t = { default: t, _ctx: we }, n = 32) : (t = String(t), r & 64 ? (n = 16, t = [on(t)]) : n = 8); e.children = t, e.shapeFlag |= n; } function jl(...e) { const t = {}; for (let n = 0; n < e.length; n++) { const r = e[n]; for (const s in r) if (s === "class") t.class !== r.class && (t.class = mt([t.class, r.class])); else if (s === "style") t.style = At([t.style, r.style]); else if (an(s)) { const i = t[s], o = r[s]; o && i !== o && !(T(i) && i.includes(o)) && (t[s] = i ? [].concat(i, o) : o); } else s !== "" && (t[s] = r[s]); } return t; } function Oe(e, t, n, r = null) { _e(e, t, 7, [ n, r ]); } const Ul = pi(); let Dl = 0; function Vl(e, t, n) { const r = e.type, s = (t ? t.appContext : e.appContext) || Ul, i = { uid: Dl++, vnode: e, type: r, parent: t, appContext: s, root: null, // to be immediately set next: null, subTree: null, // will be set synchronously right after creation effect: null, update: null, // will be set synchronously right after creation scope: new co( !0 /* detached */ ), render: null, proxy: null, exposed: null, exposeProxy: null, withProxy: null, provides: t ? t.provides : Object.create(s.provides), accessCache: null, renderCache: [], // local resolved assets components: null, directives: null, // resolved props and emits options propsOptions: gi(r, s), emitsOptions: si(r, s), // emit emit: null, // to be set immediately emitted: null, // props default value propsDefaults: q, // inheritAttrs inheritAttrs: r.inheritAttrs, // state ctx: q, data: q, props: q, attrs: q, slots: q, refs: q, setupState: q, setupContext: null, attrsProxy: null, slotsProxy: null, // suspense related suspense: n, suspenseId: n ? n.pendingId : 0, asyncDep: null, asyncResolved: !1, // lifecycle hooks // not using enums here because it results in computed properties isMounted: !1, isUnmounted: !1, isDeactivated: !1, bc: null, c: null, bm: null, m: null, bu: null, u: null, um: null, bum: null, da: null, a: null, rtg: null, rtc: null, ec: null, sp: null }; return i.ctx = { _: i }, i.root = t ? t.root : i, i.emit = Vo.bind(null, i), e.ce && e.ce(i), i; } let se = null, ln, sr; { const e = Ls(), t = (n, r) => { let s; return (s = e[n]) || (s = e[n] = []), s.push(r), (i) => { s.length > 1 ? s.forEach((o) => o(i)) : s[0](i); }; }; ln = t( "__VUE_INSTANCE_SETTERS__", (n) => se = n ), sr = t( "__VUE_SSR_SETTERS__", (n) => _n = n ); } const Nt = (e) => { const t = se; return ln(e), e.scope.on(), () => { e.scope.off(), ln(t); }; }, ls = () => { se && se.scope.off(), ln(null); }; function Oi(e) { return e.vnode.shapeFlag & 4; } let _n = !1; function Hl(e, t = !1) { t && sr(t); const { props: n, children: r } = e.vnode, s = Oi(e); vl(e, n, s, t), Al(e, r); const i = s ? Wl(e, t) : void 0; return t && sr(!1), i; } function Wl(e, t) { const n = e.type; e.accessCache = /* @__PURE__ */ Object.create(null), e.proxy = Xs(new Proxy(e.ctx, pl)); const { setup: r } = n; if (r) { const s = e.setupContext = r.length > 1 ? ql(e) : null, i = Nt(e); nt(); const o = ze( r, e, 0, [ e.props, s ] ); if (rt(), i(), Ts(o)) { if (o.then(ls, ls), t) return o.then((l) => { cs(e, l, t); }).catch((l) => { pn(l, e, 0); }); e.asyncDep = o; } else cs(e, o, t); } else xi(e, t); } function cs(e, t, n) { N(t) ? e.type.__ssrInlineRender ? e.ssrRender = t : e.render = t : J(t) && (e.setupState = Ys(t)), xi(e, n); } let as; function xi(e, t, n) { const r = e.type; if (!e.render) { if (!t && as && !r.render) { const s = r.template || xr(e).template; if (s) { const { isCustomElement: i, compilerOptions: o } = e.appContext.config, { delimiters: l, compilerOptions: c } = r, f = ne( ne( { isCustomElement: i, delimiters: l }, o ), c ); r.render = as(s, f); } } e.render = r.render || pe; } { const s = Nt(e); nt(); try { ml(e); } finally { rt(), s(); } } } function zl(e) { return e.attrsProxy || (e.attrsProxy = new Proxy( e.attrs, { get(t, n) { return ae(e, "get", "$attrs"), t[n]; } } )); } function ql(e) { const t = (n) => { e.exposed = n || {}; }; return { get attrs() { return zl(e); }, slots: e.slots, emit: e.emit, expose: t }; } function Rr(e) { if (e.exposed) return e.exposeProxy || (e.exposeProxy = new Proxy(Ys(Xs(e.exposed)), { get(t, n) { if (n in t) return t[n]; if (n in vt) return vt[n](e); }, has(t, n) { return n in t || n in vt; } })); } function Kl(e, t = !0) { return N(e) ? e.displayName || e.name : e.name || t && e.__name; } function Jl(e) { return N(e) && "__vccOpts" in e; } const Gl = (e, t) => To(e, t, _n), Ql = "3.4.21"; /** * @vue/runtime-dom v3.4.21 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT **/ const Xl = "http://www.w3.org/2000/svg", Zl = "http://www.w3.org/1998/Math/MathML", He = typeof document < "u" ? document : null, us = He && /* @__PURE__ */ He.createElement("template"), Yl = { insert: (e, t, n) => { t.insertBefore(e, n || null); }, remove: (e) => { const t = e.parentNode; t && t.removeChild(e); }, createElement: (e, t, n, r) => { const s = t === "svg" ? He.createElementNS(Xl, e) : t === "mathml" ? He.createElementNS(Zl, e) : He.createElement(e, n ? { is: n } : void 0); return e === "select" && r && r.multiple != null && s.setAttribute("multiple", r.multiple), s; }, createText: (e) => He.createTextNode(e), createComment: (e) => He.createComment(e), setText: (e, t) => { e.nodeValue = t; }, setElementText: (e, t) => { e.textContent = t; }, parentNode: (e) => e.parentNode, nextSibling: (e) => e.nextSibling, querySelector: (e) => He.querySelector(e), setScopeId(e, t) { e.setAttribute(t, ""); }, // __UNSAFE__ // Reason: innerHTML. // Static content here can only come from compiled templates. // As long as the user only uses trusted templates, this is safe. insertStaticContent(e, t, n, r, s, i) { const o = n ? n.previousSibling : t.lastChild; if (s && (s === i || s.nextSibling)) for (; t.insertBefore(s.cloneNode(!0), n), !(s === i || !(s = s.nextSibling)); ) ; else { us.innerHTML = r === "svg" ? `<svg>${e}</svg>` : r === "mathml" ? `<math>${e}</math>` : e; const l = us.content; if (r === "svg" || r === "mathml") { const c = l.firstChild; for (; c.firstChild; ) l.appendChild(c.firstChild); l.removeChild(c); } t.insertBefore(l, n); } return [ // first o ? o.nextSibling : t.firstChild, // last n ? n.previousSibling : t.lastChild ]; } }, ec = Symbol("_vtc"); function tc(e, t, n) { const r = e[ec]; r && (t = (t ? [t, ...r] : [...r]).join(" ")), t == null ? e.removeAttribute("class") : n ? e.setAttribute("class", t) : e.className = t; } const fs = Symbol("_vod"), nc = Symbol("_vsh"), rc = Symbol(""), sc = /(^|;)\s*display\s*:/; function ic(e, t, n) { const r = e.style, s = ee(n); let i = !1; if (n && !s) { if (t) if (ee(t)) for (const o of t.split(";")) { const l = o.slice(0, o.indexOf(":")).trim(); n[l] == null && Zt(r, l, ""); } else for (const o in t) n[o] == null && Zt(r, o, ""); for (const o in n) o === "display" && (i = !0), Zt(r, o, n[o]); } else if (s) { if (t !== n) { const o = r[rc]; o && (n += ";" + o), r.cssText = n, i = sc.test(n); } } else t && e.removeAttribute("style"); fs in e && (e[fs] = i ? r.display : "", e[nc] && (r.display = "none")); } const ds = /\s*!important$/; function Zt(e, t, n) { if (T(n)) n.forEach((r) => Zt(e, t, r)); else if (n == null && (n = ""), t.startsWith("--")) e.setProperty(t, n); else { const r = oc(e, t); ds.test(n) ? e.setProperty( pt(r), n.replace(ds, ""), "important" ) : e[r] = n; } } const hs = ["Webkit", "Moz", "ms"], Dn = {}; function oc(e, t) { const n = Dn[t]; if (n) return n; let r = Fe(t); if (r !== "filter" && r in e) return Dn[t] = r; r = dn(r); for (let s = 0; s < hs.length; s++) { const i = hs[s] + r; if (i in e) return Dn[t] = i; } return t; } const ps = "http://www.w3.org/1999/xlink"; function lc(e, t, n, r, s) { if (r && t.startsWith("xlink:")) n == null ? e.removeAttributeNS(ps, t.slice(6, t.length)) : e.setAttributeNS(ps, t, n); else { const i = lo(t); n == null || i && !Is(n) ? e.removeAttribute(t) : e.setAttribute(t, i ? "" : n); } } function cc(e, t, n, r, s, i, o) { if (t === "innerHTML" || t === "textContent") { r && o(r, s, i), e[t] = n ?? ""; return; } const l = e.tagName; if (t === "value" && l !== "PROGRESS" && // custom elements may use _value internally !l.includes("-")) { const f = l === "OPTION" ? e.getAttribute("value") || "" : e.value, d = n ?? ""; (f !== d || !("_value" in e)) && (e.value = d), n == null && e.removeAttribute(t), e._value = n; return; } let c = !1; if (n === "" || n == null) { const f = typeof e[t]; f === "boolean" ? n = Is(n) : n == null && f === "string" ? (n = "", c = !0) : f === "number" && (n = 0, c = !0); } try { e[t] = n; } catch { } c && e.removeAttribute(t); } function ac(e, t, n, r) { e.addEventListener(t, n, r); } function uc(e, t, n, r) { e.removeEventListener(t, n, r); } const ms = Symbol("_vei"); function fc(e, t, n, r, s = null) { const i = e[ms] || (e[ms] = {}), o = i[t]; if (r && o) o.value = r; else { const [l, c] = dc(t); if (r) { const f = i[t] = mc(r, s); ac(e, l, f, c); } else o && (uc(e, l, o, c), i[t] = void 0); } } const gs = /(?:Once|Passive|Capture)$/; function dc(e) { let t; if (gs.test(e)) { t = {}; let r; for (; r = e.match(gs); ) e = e.slice(0, e.length - r[0].length), t[r[0].toLowerCase()] = !0; } return [e[2] === ":" ? e.slice(3) : pt(e.slice(2)), t]; } let Vn = 0; const hc = /* @__PURE__ */ Promise.resolve(), pc = () => Vn || (hc.then(() => Vn = 0), Vn = Date.now()); function mc(e, t) { const n = (r) => { if (!r._vts) r._vts = Date.now(); else if (r._vts <= n.attached) return; _e( gc(r, n.value), t, 5, [r] ); }; return n.value = e, n.attached = pc(), n; } function gc(e, t) { if (T(t)) { const n = e.stopImmediatePropagation; return e.stopImmediatePropagation = () => { n.call(e), e._stopped = !0; }, t.map((r) => (s) => !s._stopped && r && r(s)); } else return t; } const bs = (e) => e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && // lowercase letter e.charCodeAt(2) > 96 && e.charCodeAt(2) < 123, bc = (e, t, n, r, s, i, o, l, c) => { const f = s === "svg"; t === "class" ? tc(e, r, f) : t === "style" ? ic(e, n, r) : an(t) ? fr(t) || fc(e, t, n, r, o) : (t[0] === "." ? (t = t.slice(1), !0) : t[0] === "^" ? (t = t.slice(1), !1) : wc(e, t, r, f)) ? cc( e, t, r, i, o, l, c ) : (t === "true-value" ? e._trueValue = r : t === "false-value" && (e._falseValue = r), lc(e, t, r, f)); }; function wc(e, t, n, r) { if (r) return !!(t === "innerHTML" || t === "textContent" || t in e && bs(t) && N(n)); if (t === "spellcheck" || t === "draggable" || t === "translate" || t === "form" || t === "list" && e.tagName === "INPUT" || t === "type" && e.tagName === "TEXTAREA") return !1; if (t === "width" || t === "height") { const s = e.tagName; if (s === "IMG" || s === "VIDEO" || s === "CANVAS" || s === "SOURCE") return !1; } return bs(t) && ee(n) ? !1 : t in e; } const yc = /* @__PURE__ */ ne({ patchProp: bc }, Yl); let ws; function _c() { return ws || (ws = Rl(yc)); } const Sc = (...e) => { const t = _c().createApp(...e), { mount: n } = t; return t.mount = (r) => { const s = vc(r); if (!s) return; const i = t._component; !N(i) && !i.render && !i.template && (i.template = s.innerHTML), s.innerHTML = ""; const o = n(s, !1, Ec(s)); return s instanceof Element && (s.removeAttribute("v-cloak"), s.setAttribute("data-v-app", "")), o; }, t; }; function Ec(e) { if (e instanceof SVGElement) return "svg"; if (typeof MathMLElement == "function" && e instanceof MathMLElement) return "mathml"; } function vc(e) { return ee(e) ? document.querySelector(e) : e; } const Oc = /* @__PURE__ */ Tt({ name: "WidgetButton", props: { bounce: Boolean } }), Bt = (e, t) => { const n = e.__vccOpts || e; for (const [r, s] of t) n[r] = s; return n; }; function xc(e, t, n, r, s, i) { return Re(), Be("button", { class: mt(["widget-button", [e.bounce ? "rc-bounce" : ""]]) }, null, 2); } const Ac = /* @__PURE__ */ Bt(Oc, [["render", xc], ["__scopeId", "data-v-9158d063"]]), Cc = [ { code: "ZA", name: "South Africa", dialCode: "+27", flag: 249 }, { code: "US", name: "United States", dialCode: "+1", flag: 63 }, { code: "GB", name: "United Kingdom", dialCode: "+44", flag: 132 }, { code: "CA", name: "Canada", dialCode: "+1", flag: 6 } ], Rc = { code: "", name: "", dialCode: "", flag: 0 }, Mc = /* @__PURE__ */ Tt({ name: "PhoneInput", data: () => ({ isOpen: !1, countries: Cc, selectedCountryCode: "ZA" // Default to ZA }), methods: { selectCountry(e) { this.selectedCountryCode = e.code; }, getCountryFlagPosition(e) { let t = Math.floor(e.flag / 16); return { "background-position": `-${e.flag % 16 * 42}px -${t * 42 + 6}px` }; } }, computed: { selectedCountry() { return this.countries.find((e) => e.code === this.selectedCountryCode) || Rc; } } }), Fc = (e) => (ii("data-v-c8422abe"), e = e(), oi(), e), Pc = { class: "phone-input-field" }, Tc = { key: 0, class: "dropdown-menu" }, Nc = ["onClick"], Bc = { class: "phone-input" }, Lc = { class: "dial-code" }, Ic = /* @__PURE__ */ Fc(() => /* @__PURE__ */ Y("input", { type: "text" }, null, -1)); function kc(e, t, n, r, s, i) { return Re(), Be("div", Pc, [ Y("div", { onClick: t[0] || (t[0] = (o) => e.isOpen = !e.isOpen), class: "dropdown" }, [ Y("div", null, [ Y("i", { class: "flag-sprites", style: At(e.getCountryFlagPosition(e.selectedCountry)) }, null, 4), on(" " + Nn(e.selectedCountry.code), 1) ]), e.isOpen ? (Re(), Be("ul", Tc, [ (Re(!0), Be(xe, null, hl(e.countries, (o) => (Re(), Be("li", { key: o.code, onClick: (l) => e.selectCountry(o) }, [ Y("i", { class: "flag-sprites", style: At(e.getCountryFlagPosition(o)) }, null, 4), on(" " + Nn(o.name), 1) ], 8, Nc))), 128)) ])) : $l("", !0) ]), Y("div", Bc, [ Y("span", Lc, Nn(e.selectedCountry.dialCode), 1), Ic ]) ]); } const $c = /* @__PURE__ */ Bt(Mc, [["render", kc], ["__scopeId", "data-v-c8422abe"]]), jc = /* @__PURE__ */ Tt({ name: "ConversationWindow", components: { PhoneInput: $c }, props: { modelValue: Boolean }, methods: { startChat() { console.log("[RC] Start Chat"), this.$emit("success"), this.isActive = !1; } }, computed: { isActive: { get() { return this.modelValue; }, set(e) { this.$emit("update:modelValue", e); } } } }), Lt = (e) => (ii("data-v-cfa88b68"), e = e(), oi(), e), Uc = { class: "header" }, Dc = /* @__PURE__ */ Lt(() => /* @__PURE__ */ Y("h3", { class: "heading" }, "WhatsApp Chat", -1)), Vc = /* @__PURE__ */ Lt(() => /* @__PURE__ */ Y("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }, null, -1)), Hc = /* @__PURE__ */ Lt(() => /* @__PURE__ */ Y("path", { d: "M0 0h24v24H0z", fill: "none" }, null, -1)), Wc = [ Vc, Hc ], zc = { class: "body" }, qc = /* @__PURE__ */ Lt(() => /* @__PURE__ */ Y("div", { class: "rc-form-field" }, [ /* @__PURE__ */ Y("input", { type: "text", placeholder: "Your Name" }) ], -1)), Kc = /* @__PURE__ */ Lt(() => /* @__PURE__ */ Y("div", { class: "footer" }, [ /* @__PURE__ */ on("Powered by"), /* @__PURE__ */ Y("a", { href: "https://rather.chat", target: "_blank" }, "rather.chat") ], -1)); function Jc(e, t, n, r, s, i) { const o = Jt("phone-input"); return Re(), Be("div", { class: mt([[e.isActive ? "is-active" : ""], "conversation-window"]) }, [ Y("div", Uc, [ Dc, (Re(), Be("svg", { xmlns: "http://www.w3.org/2000/svg", width: "24", height: "24", viewBox: "0 0 24 24", class: "icon-button", onClick: t[0] || (t[0] = (l) => e.$emit("update:modelValue", !1)) }, Wc)) ]), Y("div", zc, [ qc, fe(o), Y("button", { class: "rc-chat-button", onClick: t[1] || (t[1] = (...l) => e.startChat && e.startChat(...l)) }, " Start WhatsApp Chat ") ]), Kc ], 2); } const Gc = /* @__PURE__ */ Bt(jc, [["render", Jc], ["__scopeId", "data-v-cfa88b68"]]), Qc = /* @__PURE__ */ Tt({ name: "AlertWindow", props: { modelValue: Boolean }, methods: { handleAnimationEnd() { this.isActive && (this.isActive = !1); } }, computed: { isActive: { get() { return this.modelValue; }, set(e) { this.$emit("update:modelValue", e); } } } }); function Xc(e, t, n, r, s, i) { return Re(), Be("div", { class: mt([[e.isActive ? "is-active" : ""], "container"]), onAnimationend: t[0] || (t[0] = (...o) => e.handleAnimationEnd && e.handleAnimationEnd(...o)) }, " Message Sent. Check your inbox. ", 34); } const Zc = /* @__PURE__ */ Bt(Qc, [["render", Xc], ["__scopeId", "data-v-7807ddb4"]]); function Ai(e, t) { return function() { return e.apply(t, arguments); }; } const { toString: Yc } = Object.prototype, { getPrototypeOf: Mr } = Object, Sn = /* @__PURE__ */ ((e) => (t) => { const n = Yc.call(t); return e[n] || (e[n] = n.slice(8, -1).toLowerCase()); })(/* @__PURE__ */ Object.create(null)), Pe = (e) => (e = e.toLowerCase(), (t) => Sn(t) === e), En = (e) => (t) => typeof t === e, { isArray: gt } = Array, Pt = En("undefined"); function ea(e) { return e !== null && !Pt(e) && e.constructor !== null && !Pt(e.constructor) && me(e.constructor.isBuffer) && e.constructor.isBuffer(e); } const Ci = Pe("ArrayBuffer"); function ta(e) { let t; return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Ci(e.buffer), t; } const na = En("string"), me = En("function"), Ri = En("number"), vn = (e) => e !== null && typeof e == "object", ra = (e) => e === !0 || e === !1, Yt = (e) => { if (Sn(e) !== "object") return !1; const t = Mr(e); return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e); }, sa = Pe("Date"), ia = Pe("File"), oa = Pe("Blob"), la = Pe("FileList"), ca = (e) => vn(e) && me(e.pipe), aa = (e) => { let t; return e && (typeof FormData == "function" && e instanceof FormData || me(e.append) && ((t = Sn(e)) === "formdata" || // detect form-data instance t === "object" && me(e.toString) && e.toString() === "[object FormData]")); }, ua = Pe("URLSearchParams"), fa = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, ""); function It(e, t, { allOwnKeys: n = !1 } = {}) { if (e === null || typeof e > "u") return; let r, s; if (typeof e != "object" && (e = [e]), gt(e)) for (r = 0, s = e.length; r < s; r++) t.call(null, e[r], r, e); else { const i = n ? Object.getOwnPropertyNames(e) : Object.keys(e), o = i.length; let l; for (r = 0; r < o; r++) l = i[r], t.call(null, e[l], l, e); } } function Mi(e, t) { t = t.toLowerCase(); const n = Object.keys(e); let r = n.length, s; for (; r-- > 0; ) if (s = n[r], t === s.toLowerCase()) return s; return null; } const Fi = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Pi = (e) => !Pt(e) && e !== Fi; function ir() { const { caseless: e } = Pi(this) && this || {}, t = {}, n = (r, s) => { const i = e && Mi(t, s) || s; Yt(t[i]) && Yt(r) ? t[i] = ir(t[i], r) : Yt(r) ? t[i] = ir({}, r) : gt(r) ? t[i] = r.slice() : t[i] = r; }; for (let r = 0, s = arguments.length; r < s; r++) arguments[r] && It(arguments[r], n); return t; } const da = (e, t, n, { allOwnKeys: r } = {}) => (It(t, (s, i) => { n && me(s) ? e[i] = Ai(s, n) : e[i] = s; }, { allOwnKeys: r }), e), ha = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), pa = (e, t, n, r) => { e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", { value: t.prototype }), n && Object.assign(e.prototype, n); }, ma = (e, t, n, r) => { let s, i, o; const l = {}; if (t = t || {}, e == null) return t; do { for (s = Object.getOwnPropertyNames(e), i = s.length; i-- > 0; ) o = s[i], (!r || r(o, e, t)) && !l[o] && (t[o] = e[o], l[o] = !0); e = n !== !1 && Mr(e); } while (e && (!n || n(e, t)) && e !== Object.prototype); return t; }, ga = (e, t, n) => { e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length; const r = e.indexOf(t, n); return r !== -1 && r === n; }, ba = (e) => { if (!e) return null; if (gt(e)) return e; let t = e.length; if (!Ri(t)) return null; const n = new Array(t); for (; t-- > 0; ) n[t] = e[t]; return n; }, wa = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && Mr(Uint8Array)), ya = (e, t) => { const r = (e && e[Symbol.iterator]).call(e); let s; for (; (s = r.next()) && !s.done; ) { const i = s.value; t.call(e, i[0], i[1]); } }, _a = (e, t) => { let n; const r = []; for (; (n = e.exec(t)) !== null; ) r.push(n); return r; }, Sa = Pe("HTMLFormElement"), Ea = (e) => e.toLowerCase().replace( /[-_\s]([a-z\d])(\w*)/g, function(n, r, s) { return r.toUpperCase() + s; } ), ys = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), va = Pe("RegExp"), Ti = (e, t) => { const n = Object.getOwnPropertyDescriptors(e), r = {}; It(n, (s, i) => { let o; (o = t(s, i, e)) !== !1 && (r[i] = o || s); }), Object.defineProperties(e, r); }, Oa = (e) => { Ti(e, (t, n) => { if (me(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1) return !1; const r = e[n]; if (me(r)) { if (t.enumerable = !1, "writable" in t) { t.writable = !1; return; } t.set || (t.set = () => { throw Error("Can not rewrite read-only method '" + n + "'"); }); } }); }, xa = (e, t) => { const n = {}, r = (s) => { s.forEach((i) => { n[i] = !0; }); }; return gt(e) ? r(e) : r(String(e).split(t)), n; }, Aa = () => { }, Ca = (e, t) => (e = +e, Number.isFinite(e) ? e : t), Hn = "abcdefghijklmnopqrstuvwxyz", _s = "0123456789", Ni = { DIGIT: _s, ALPHA: Hn, ALPHA_DIGIT: Hn + Hn.toUpperCase() + _s }, Ra = (e = 16, t = Ni.ALPHA_DIGIT) => { let n = ""; const { length: r } = t; for (; e--; ) n += t[Math.random() * r | 0]; return n; }; function Ma(e) { return !!(e && me(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]); } const Fa = (e) => { const t = new Array(10), n = (r, s) => { if (vn(r)) { if (t.indexOf(r) >= 0) return; if (!("toJSON" in r)) { t[s] = r; const i = gt(r) ? [] : {}; return It(r, (o, l) => { const c = n(o, s + 1); !Pt(c) && (i[l] = c); }), t[s] = void 0, i; } } return r; }; return n(e, 0); }, Pa = Pe("AsyncFunction"), Ta = (e) => e && (vn(e) || me(e)) && me(e.then) && me(e.catch), m = { isArray: gt, isArrayBuffer: Ci, isBuffer: ea, isFormData: aa, isArrayBufferView: ta, isString: na, isNumber: Ri, isBoolean: ra, isObject: vn, isPlainObject: Yt, isUndefined: Pt, isDate: sa, isFile: ia, isBlob: oa, isRegExp: va, isFunction: me, isStream: ca, isURLSearchParams: ua, isTypedArray: wa, isFileList: la, forEach: It, merge: ir, extend: da, trim: fa, stripBOM: ha, inherits: pa, toFlatObject: ma, kindOf: Sn, kindOfTest: Pe, endsWith: ga, toArray: ba, forEachEntry: ya, matchAll: _a, isHTMLForm: Sa, hasOwnProperty: ys, hasOwnProp: ys, // an alias to avoid ESLint no-prototype-builtins detection reduceDescriptors: Ti, freezeMethods: Oa, toObjectSet: xa, toCamelCase: Ea, noop: Aa, toFiniteNumber: Ca, findKey: Mi, global: Fi, isContextDefined: Pi, ALPHABET: Ni, generateString: Ra, isSpecCompliantForm: Ma, toJSONObject: Fa, isAsyncFn: Pa, isThenable: Ta }; function $(e, t, n, r, s) { Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), s && (this.response = s); } m.inherits($, Error, { toJSON: function() { return { // Standard message: this.message, name: this.name, // Microsoft description: this.description, number: this.number, // Mozilla fileName: this.fileName, lineNumber: this.lineNumber, columnNumber: this.columnNumber, stack: this.stack, // Axios config: m.toJSONObject(this.config), code: this.code, status: this.response && this.response.status ? this.response.status : null }; } }); const Bi = $.prototype, Li = {}; [ "ERR_BAD_OPTION_VALUE", "ERR_BAD_OPTION", "ECONNABORTED", "ETIMEDOUT", "ERR_NETWORK", "ERR_FR_TOO_MANY_REDIRECTS", "ERR_DEPRECATED", "ERR_BAD_RESPONSE", "ERR_BAD_REQUEST", "ERR_CANCELED", "ERR_NOT_SUPPORT", "ERR_INVALID_URL" // eslint-disable-next-line func-names ].forEach((e) => { Li[e] = { value: e }; }); Object.defineProperties($, Li); Object.defineProperty(Bi, "isAxiosError", { value: !0 }); $.from = (e, t, n, r, s, i) => { const o = Object.create(Bi); return m.toFlatObject(e, o, function(c) { return c !== Error.prototype; }, (l) => l !== "isAxiosError"), $.call(o, e.message, t, n, r, s), o.cause = e, o.name = e.name, i && Object.assign(o, i), o; }; const Na = null; function or(e) { return m.isPlainObject(e) || m.isArray(e); } function Ii(e) { return m.endsWith(e, "[]") ? e.slice(0, -2) : e; } function Ss(e, t, n) { return e ? e.concat(t).map(function(s, i) { return s = Ii(s), !n && i ? "[" + s + "]" : s; }).join(n ? "." : "") : t; } function Ba(e) { return m.isArray(e) && !e.some(or); } const La = m.toFlatObject(m, {}, null, function(t) { return /^is[A-Z]/.test(t); }); function On(e, t, n) { if (!m.isObject(e)) throw new TypeError("target must be an object"); t = t || new FormData(), n = m.toFlatObject(n, { metaTokens: !0, dots: !1, indexes: !1 }, !1, function(O, B) { return !m.isUndefined(B[O]); }); const r = n.metaTokens, s = n.visitor || d, i = n.dots, o = n.indexes, c = (n.Blob || typeof Blob < "u" && Blob) && m.isSpecCompliantForm(t); if (!m.isFunction(s)) throw new TypeError("visitor must be a function"); function f(A) { if (A === null) return ""; if (m.isDate(A)) return A.toISOString(); if (!c && m.isBlob(A)) throw new $("Blob is not supported. Use a Buffer instead."); return m.isArrayBuffer(A) || m.isTypedArray(A) ? c && typeof Blob == "function" ? new Blob([A]) : Buffer.from(A) : A; } function d(A, O, B) { let I = A; if (A && !B && typeof A == "object") { if (m.endsWith(O, "{}")) O = r ? O : O.slice(0, -2), A = JSON.stringify(A); else if (m.isArray(A) && Ba(A) || (m.isFileList(A) || m.endsWith(O, "[]")) && (I = m.toArray(A))) return O = Ii(O), I.forEach(function(k, Q) { !(m.isUndefined(k) || k === null) && t.append( // eslint-disable-next-line no-nested-ternary o === !0 ? Ss([O], Q, i) : o === null ? O : O + "[]", f(k) ); }), !1; } return or(A) ? !0 : (t.append(Ss(B, O, i), f(A)), !1); } const h = [], E = Object.assign(La, { defaultVisitor: d, convertValue: f, isVisitable: or }); function R(A, O) { if (!m.isUndefined(A)) { if (h.indexOf(A) !== -1) throw Error("Circular reference detected in " + O.join(".")); h.push(A), m.forEach(A, function(I, Z) { (!(m.isUndefined(I) || I === null) && s.call( t, I, m.isString(Z) ? Z.trim() : Z, O, E )) === !0 && R(I, O ? O.concat(Z) : [Z]); }), h.pop(); } } if (!m.isObject(e)) throw new TypeError("data must be an object"); return R(e), t; } function Es(e) { const t = { "!": "%21", "'": "%27", "(": "%28", ")": "%29", "~": "%7E", "%20": "+", "%00": "\0" }; return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(r) { return t[r]; }); } function Fr(e, t) { this._pairs = [], e && On(e, this, t); } const ki = Fr.prototype; ki.append = function(t, n) { this._pairs.push([t, n]); }; ki.toString = function(t) { const n = t ? function(r) { return t.call(this, r, Es); } : Es; return this._pairs.map(function(s) { return n(s[0]) + "=" + n(s[1]); }, "").join("&"); }; function Ia(e) { return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]"); } function $i(e, t, n) { if (!t) return e; const r = n && n.encode || Ia, s = n && n.serialize; let i; if (s ? i = s(t, n) : i = m.isURLSearchParams(t) ? t.toString() : new Fr(t, n).toString(r), i) { const o = e.indexOf("#"); o !== -1 && (e = e.slice(0, o)), e += (e.indexOf("?") === -1 ? "?" : "&") + i; } return e; } class vs { constructor() { this.handlers = []; } /** * Add a new interceptor to the stack * * @param {Function} fulfilled The function to handle `then` for a `Promise` * @param {Function} rejected The function to handle `reject` for a `Promise` * * @return {Number} An ID used to remove interceptor later */ use(t, n, r) { return this.handlers.push({ fulfilled: t, rejected: n, synchronous: r ? r.synchronous : !1, runWhen: r ? r.runWhen : null }), this.handlers.length - 1; } /** * Remove an interceptor from the stack * * @param {Number} id The ID that was returned by `use` * * @returns {Boolean} `true` if the interceptor was removed, `false` otherwise */ eject(t) { this.handlers[t] && (this.handlers[t] = null); } /** * Clear all interceptors from the stack * * @returns {void} */ clear() { this.handlers && (this.handlers = []); } /** * Iterate over all the registered interceptors * * This method is particularly useful for skipping over any * interceptors that may have become `null` calling `eject`. * * @param {Function} fn The function to call for each interceptor * * @returns {void} */ forEach(t) { m.forEach(this.handlers, function(r) { r !== null && t(r); }); } } const ji = { silentJSONParsing: !0, forcedJSONParsing: !0, clarifyTimeoutError: !1 }, ka = typeof URLSearchParams < "u" ? URLSearchParams : Fr, $a = typeof FormData < "u" ? FormData : null, ja = typeof Blob < "u" ? Blob : null, Ua = { isBrowser: !0, classes: { URLSearchParams: ka, FormData: $a, Blob: ja }, protocols: ["http", "https", "file", "blob", "url", "data"] }, Ui = typeof window < "u" && typeof document < "u", Da = ((e) => Ui && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator < "u" && navigator.product), Va = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Ha = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, hasBrowserEnv: Ui, hasStandardBrowserEnv: Da, hasStandardBrowserWebWorkerEnv: Va }, Symbol.toStringTag, { value: "Module" })), Me = { ...Ha, ...Ua }; function Wa(e, t) { return On(e, new Me.classes.URLSearchParams(), Object.assign({ visitor: function(n, r, s, i) { return Me.isNode && m.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : i.defaultVisitor.apply(this, arguments); } }, t)); } function za(e) { return m.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]); } function qa(e) { const t = {}, n = Object.keys(e); let r; const s = n.length; let i; for (r = 0; r < s; r++) i = n[r], t[i] = e[i]; return t; } function Di(e) { function t(n, r, s, i) { let o = n[i++]; if (o === "__proto__") return !0; const l = Number.isFinite(+o), c = i >= n.length; return o = !o && m.isArray(s) ? s.length : o, c ? (m.hasOwnProp(s, o) ? s[o] = [s[o], r] : s[o] = r, !l) : ((!s[o] || !m.isObject(s[o])) && (s[o] = []), t(n, r, s[o], i) && m.isArray(s[o]) && (s[o] = qa(s[o])), !l); } if (m.isFormData(e) && m.isFunction(e.entries)) { const n = {}; return m.forEachEntry(e, (r, s) => { t(za(r), s, n, 0); }), n; } return null; } function Ka(e, t, n) { if (m.isString(e)) try { return (t || JSON.parse)(e), m.trim(e); } catch (r) { if (r.name !== "SyntaxError") throw r; } return (n || JSON.stringify)(e); } const Pr = { transitional: ji, adapter: ["xhr", "http"], transformRequest: [function(t, n) { const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, i = m.isObject(t); if (i && m.isHTMLForm(t) && (t = new FormData(t)), m.isFormData(t)) return s ? JSON.stringify(Di(t)) : t; if (m.isArrayBuffer(t) || m.isBuffer(t) || m.isStream(t) || m.isFile(t) || m.isBlob(t)) return t; if (m.isArrayBufferView(t)) return t.buffer; if (m.isURLSearchParams(t)) return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString(); let l; if (i) { if (r.indexOf("application/x-www-form-urlencoded") > -1) return Wa(t, this.formSerializer).toString(); if ((l = m.isFileList(t)) || r.indexOf("multipart/form-data") > -1) { const c = this.env && this.env.FormData; return On( l ? { "files[]": t } : t, c && new c(), this.formSerializer ); } } return i || s ? (n.setContentType("application/json", !1), Ka(t)) : t; }], transformResponse: [function(t) { const n = this.transitional || Pr.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json"; if (t && m.isString(t) && (r && !this.responseType || s)) { const o = !(n && n.silentJSONParsing) && s; try { return JSON.parse(t); } catch (l) { if (o) throw l.name === "SyntaxError" ? $.from(l, $.ERR_BAD_RESPONSE, this, null, this.response) : l; } } return t; }], /** * A timeout in milliseconds to abort a request. If set to 0 (default) a * timeout is not created. */ timeout: 0, xsrfCookieName: "XSRF-TOKEN", xsrfHeaderName: "X-XSRF-TOKEN", maxContentLength: -1, maxBodyLength: -1, env: { FormData: Me.classes.FormData, Blob: Me.classes.Blob }, validateStatus: function(t) { return t >= 200 && t < 300; }, headers: { common: { Accept: "application/json, text/plain, */*", "Content-Type": void 0 } } }; m.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => { Pr.headers[e] = {}; }); const Tr = Pr, Ja = m.toObjectSet([ "age", "authorization", "content-length", "content-type", "etag", "expires", "from", "host", "if-modified-since", "if-unmodified-since", "last-modified", "location", "max-forwards", "proxy-authorization", "referer", "retry-after", "user-agent" ]), Ga = (e) => { const t = {}; let n, r, s; return e && e.split(` `).forEach(function(o) { s = o.indexOf(":"), n = o.substring(0, s).trim().toLowerCase(), r = o.substring(s + 1).trim(), !(!n || t[n] && Ja[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r); }), t; }, Os = Symbol("internals"); function _t(e) { return e && String(e).trim().toLowerCase(); } function en(e) { return e === !1 || e == null ? e : m.isArray(e) ? e.map(en) : String(e); } function Qa(e) { const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g; let r; for (; r = n.exec(e); ) t[r[1]] = r[2]; return t; } const Xa = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()); function Wn(e, t, n, r, s) { if (m.isFunction(r)) return r.call(this, t, n); if (s && (t = n), !!m.isString(t)) { if (m.isString(r)) return t.indexOf(r) !== -1; if (m.isRegExp(r)) return r.test(t); } } function Za(e) { return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r); } function Ya(e, t) { const n = m.toCamelCase(" " + t); ["get", "set", "has"].forEach((r) => { Object.defineProperty(e, r + n, { value: function(s, i, o) { return this[r].call(this, t, s, i, o); }, configurable: !0 }); }); } class xn { constructor(t) { t && this.set(t); } set(t, n, r) { const s = this; function i(l, c, f) { const d = _t(c); if (!d) throw new Error("header name must be a non-empty string"); const h = m.findKey(s, d); (!h || s[h] === void 0 || f === !0 || f === void 0 && s[h] !== !1) && (s[h || c] = en(l)); } const o = (l, c) => m.forEach(l, (f, d) => i(f, d, c)); return m.isPlainObject(t) || t instanceof this.constructor ? o(t, n) : m.isString(t) && (t = t.trim()) && !Xa(t) ? o(Ga(t), n) : t != null && i(n, t, r), this; } get(t, n) { if (t = _t(t), t) { const r = m.findKey(this, t); if (r) { const s = this[r]; if (!n) return s; if (n === !0) return Qa(s); if (m.isFunction(n)) return n.call(this, s, r); if (m.isRegExp(n)) return n.exec(s); throw new TypeError("parser must be boolean|regexp|function"); } } } has(t, n) { if (t = _t(t), t) { const r = m.findKey(this, t); return !!(r && this[r] !== void 0 && (!n || Wn(this, this[r], r, n))); } return !1; } delete(t, n) { const r = this; let s = !1; function i(o) { if (o = _t(o), o) { const l = m.findKey(r, o); l && (!n || Wn(r, r[l], l, n)) && (delete r[l], s = !0); } } return m.isArray(t) ? t.forEach(i) : i(t), s; } clear(t) { const n = Object.keys(this); let r = n.length, s = !1; for (; r--; ) { const i = n[r]; (!t || Wn(this, this[i], i, t, !0)) && (delete this[i], s = !0); } return s; } normalize(t) { const n = this, r = {}; return m.forEach(this, (s, i) => { const o = m.findKey(r, i); if (o) { n[o] = en(s), delete n[i]; return; } const l = t ? Za(i) : String(i).trim(); l !== i && delete n[i], n[l] = en(s), r[l] = !0; }), this; } concat(...t) { return this.constructor.concat(this, ...t); } toJSON(t) { const n = /* @__PURE__ */ Object.create(null); return m.forEach(this, (r, s) => { r != null && r !== !1 && (n[s] = t && m.isArray(r) ? r.join(", ") : r); }), n; } [Symbol.iterator]() { return Object.entries(this.toJSON())[Symbol.iterator](); } toString() { return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(` `); } get [Symbol.toStringTag]() { return "AxiosHeaders"; } static from(t) { return t instanceof this ? t : new this(t); } static concat(t, ...n) { const r = new this(t); return n.forEach((s) => r.set(s)), r; } static accessor(t) { const r = (this[Os] = this[Os] = { accessors: {} }).accessors, s = this.prototype; function i(o) { const l = _t(o); r[l] || (Ya(s, o), r[l] = !0); } return m.isArray(t) ? t.forEach(i) : i(t), this; } } xn.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]); m.reduceDescriptors(xn.prototype, ({ value: e }, t) => { let n = t[0].toUpperCase() + t.slice(1); return { get: () => e, set(r) { this[n] = r; } }; }); m.freezeMethods(xn); const Ie = xn; function zn(e, t) { const n = this || Tr, r = t || n, s = Ie.from(r.headers); let i = r.data; return m.forEach(e, function(l) { i = l.call(n, i, s.normalize(), t ? t.status : void 0); }), s.normalize(), i; } function Vi(e) { return !!(e && e.__CANCEL__); } function kt(e, t, n) { $.call(this, e ?? "canceled", $.ERR_CANCELED, t, n), this.name = "CanceledError"; } m.inherits(kt, $, { __CANCEL__: !0 }); function eu(e, t, n) { const r = n.config.validateStatus; !n.status || !r || r(n.status) ? e(n) : t(new $( "Request failed with status code " + n.status, [$.ERR_BAD_REQUEST, $.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4], n.config, n.request, n )); } const tu = Me.hasStandardBrowserEnv ? ( // Standard browser envs support document.cookie { write(e, t, n, r, s, i) { const o = [e + "=" + encodeURIComponent(t)]; m.isNumber(n) && o.push("expires=" + new Date(n).toGMTString()), m.isString(r) && o.push("path=" + r), m.isString(s) && o.push("domain=" + s), i === !0 && o.push("secure"), document.cookie = o.join("; "); }, read(e) { const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)")); return t ? decodeURIComponent(t[3]) : null; }, remove(e) { this.write(e, "", Date.now() - 864e5); } } ) : ( // Non-standard browser env (web workers, react-native) lack needed support. { write() { }, read() { return null; }, remove() { } } ); function nu(e) { return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e); } function ru(e, t) { return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e; } function Hi(e, t) { return e && !nu(t) ? ru(e, t) : t; } const su = Me.hasStandardBrowserEnv ? ( // Standard browser envs have full support of the APIs needed to test // whether the request URL is of the same origin as current location. function() { const t = /(msie|trident)/i.test(navigator.userAgent), n = document.createElement("a"); let r; function s(i) { let o = i; return t && (n.setAttribute("href", o), o = n.href), n.setAttribute("href", o), { href: n.href, protocol: n.protocol ? n.protocol.replace(/:$/, "") : "", host: n.host, search: n.search ? n.search.replace(/^\?/, "") : "", hash: n.hash ? n.hash.replace(/^#/, "") : "", hostname: n.hostname, port: n.port, pathname: n.pathname.charAt(0) === "/" ? n.pathname : "/" + n.pathname }; } return r = s(window.location.href), function(o) { const l = m.isString(o) ? s(o) : o; return l.protocol === r.protocol && l.host === r.host; }; }() ) : ( // Non standard browser envs (web workers, react-native) lack needed support. /* @__PURE__ */ function() { return function() { return !0; }; }() ); function iu(e) { const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e); return t && t[1] || ""; } function ou(e, t) { e = e || 10; const n = new Array(e), r = new Array(e); let s = 0, i = 0, o; return t = t !== void 0 ? t : 1e3, function(c) { const f = Date.now(), d = r[i]; o || (o = f), n[s] = c, r[s] = f; let h = i, E = 0; for (; h !== s; ) E += n[h++], h = h % e; if (s = (s + 1) % e, s === i && (i = (i + 1) % e), f - o < t) return; const R = d && f - d; return R ? Math.round(E * 1e3 / R) : void 0; }; } function xs(e, t) { let n = 0; const r = ou(50, 250); return (s) => { const i = s.loaded, o = s.lengthComputable ? s.total : void 0, l = i - n, c = r(l), f = i <= o; n = i; const d = { loaded: i, total: o, progress: o ? i / o : void 0, bytes: l, rate: c || void 0, estimated: c && o && f ? (o - i) / c : void 0, event: s }; d[t ? "download" : "upload"] = !0, e(d); }; } const lu = typeof XMLHttpRequest < "u", cu = lu && function(e) { return new Promise(function(n, r) { let s = e.data; const i = Ie.from(e.headers).normalize(); let { responseType: o, withXSRFToken: l } = e, c; function f() { e.cancelToken && e.cancelToken.unsubscribe(c), e.signal && e.signal.removeEventListener("abort", c); } let d; if (m.isFormData(s)) { if (Me.hasStandardBrowserEnv || Me.hasStandardBrowserWebWorkerEnv) i.setContentType(!1); else if ((d = i.getContentType()) !== !1) { const [O, ...B] = d ? d.split(";").map((I) => I.trim()).filter(Boolean) : []; i.setContentType([O || "multipart/form-data", ...B].join("; ")); } } let h = new XMLHttpRequest(); if (e.auth) { const O = e.auth.username || "", B = e.auth.password ? unescape(encodeURIComponent(e.auth.password)) : ""; i.set("Authorization", "Basic " + btoa(O + ":" + B)); } const E = Hi(e.baseURL, e.url); h.open(e.method.toUpperCase(), $i(E, e.params, e.paramsSerializer), !0), h.timeout = e.timeout; function R() { if (!h) return; const O = Ie.from( "getAllResponseHeaders" in h && h.getAllResponseHeaders() ), I = { data: !o || o === "text" || o === "json" ? h.responseText : h.response, status: h.status, statusText: h.statusText, headers: O, config: e, request: h }; eu(function(k) { n(k), f(); }, function(k) { r(k), f(); }, I), h = null; } if ("onloadend" in h ? h.onloadend = R : h.onreadystatechange = function() { !h || h.readyState !== 4 || h.status === 0 && !(h.responseURL && h.responseURL.indexOf("file:") === 0) || setTimeout(R); }, h.onabort = function() { h && (r(new $("Request aborted", $.ECONNABORTED, e, h)), h = null); }, h.onerror = function() { r(new $("Network Error", $.ERR_NETWORK, e, h)), h = null; }, h.ontimeout = function() { let B = e.timeout ? "timeout of " + e.timeout + "ms exceeded" : "timeout exceeded"; const I = e.transitional || ji; e.timeoutErrorMessage && (B = e.timeoutErrorMessage), r(new $( B, I.clarifyTimeoutError ? $.ETIMEDOUT : $.ECONNABORTED, e, h )), h = null; }, Me.hasStandardBrowserEnv && (l && m.isFunction(l) && (l = l(e)), l || l !== !1 && su(E))) { const O = e.xsrfHeaderName && e.xsrfCookieName && tu.read(e.xsrfCookieName); O && i.set(e.xsrfHeaderName, O); } s === void 0 && i.setContentType(null), "setRequestHeader" in h && m.forEach(i.toJSON(), function(B, I) { h.setRequestHeader(I, B); }), m.isUndefined(e.withCredentials) || (h.withCredentials = !!e.withCredentials), o && o !== "json" && (h.responseType = e.responseType), typeof e.onDownloadProgress == "function" && h.addEventListener("progress", xs(e.onDownloadProgress, !0)), typeof e.onUploadProgress == "function" && h.upload && h.upload.addEventListener("progress", xs(e.onUploadProgress)), (e.cancelToken || e.signal) && (c = (O) => { h && (r(!O || O.type ? new kt(null, e, h) : O), h.abort(), h = null); }, e.cancelToken && e.cancelToken.subscribe(c), e.signal && (e.signal.aborted ? c() : e.signal.addEventListener("abort", c))); const A = iu(E); if (A && Me.protocols.indexOf(A) === -1) { r(new $("Unsupported protocol " + A + ":", $.ERR_BAD_REQUEST, e)); return; } h.send(s || null); }); }, lr = { http: Na, xhr: cu }; m.forEach(lr, (e, t) => { if (e) { try { Object.defineProperty(e, "name", { value: t }); } catch { } Object.defineProperty(e, "adapterName", { value: t }); } }); const As = (e) => `- ${e}`, au = (e) => m.isFunction(e) || e === null || e === !1, Wi = { getAdapter: (e) => { e = m.isArray(e) ? e : [e]; const { length: t } = e; let n, r; const s = {}; for (let i = 0; i < t; i++) { n = e[i]; let o; if (r = n, !au(n) && (r = lr[(o = String(n)).toLowerCase()], r === void 0)) throw new $(`Unknown adapter '${o}'`); if (r) break; s[o || "#" + i] = r; } if (!r) { const i = Object.entries(s).map( ([l, c]) => `adapter ${l} ` + (c === !1 ? "is not supported by the environment" : "is not available in the build") ); let o = t ? i.length > 1 ? `since : ` + i.map(As).join(` `) : " " + As(i[0]) : "as no adapter specified"; throw new $( "There is no suitable adapter to dispatch the request " + o, "ERR_NOT_SUPPORT" ); } return r; }, adapters: lr }; function qn(e) { if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted) throw new kt(null, e); } function Cs(e) { return qn(e), e.headers = Ie.from(e.headers), e.data = zn.call( e, e.transformRequest ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Wi.getAdapter(e.adapter || Tr.adapter)(e).then(function(r) { return qn(e), r.data = zn.call( e, e.transformResponse, r ), r.headers = Ie.from(r.headers), r; }, function(r) { return Vi(r) || (qn(e), r && r.response && (r.response.data = zn.call( e, e.transformResponse, r.response ), r.response.headers = Ie.from(r.response.headers))), Promise.reject(r); }); } const Rs = (e) => e instanceof Ie ? { ...e } : e; function dt(e, t) { t = t || {}; const n = {}; function r(f, d, h) { return m.isPlainObject(f) && m.isPlainObject(d) ? m.merge.call({ caseless: h }, f, d) : m.isPlainObject(d) ? m.merge({}, d) : m.isArray(d) ? d.slice() : d; } function s(f, d, h) { if (m.isUndefined(d)) { if (!m.isUndefined(f)) return r(void 0, f, h); } else return r(f, d, h); } function i(f, d) { if (!m.isUndefined(d)) return r(void 0, d); } function o(f, d) { if (m.isUndefined(d)) { if (!m.isUndefined(f)) return r(void 0, f); } else return r(void 0, d); } function l(f, d, h) { if (h in t) return r(f, d); if (h in e) return r(void 0, f); } const c = { url: i, method: i, data: i, baseURL: o, transformRequest: o, transformResponse: o, paramsSerializer: o, timeout: o, timeoutMessage: o, withCredentials: o, withXSRFToken: o, adapter: o, responseType: o, xsrfCookieName: o, xsrfHeaderName: o, onUploadProgress: o, onDownloadProgress: o, decompress: o, maxContentLength: o, maxBodyLength: o, beforeRedirect: o, transport: o, httpAgent: o, httpsAgent: o, cancelToken: o, socketPath: o, responseEncoding: o, validateStatus: l, headers: (f, d) => s(Rs(f), Rs(d), !0) }; return m.forEach(Object.keys(Object.assign({}, e, t)), function(d) { const h = c[d] || s, E = h(e[d], t[d], d); m.isUndefined(E) && h !== l || (n[d] = E); }), n; } const zi = "1.6.8", Nr = {}; ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => { Nr[e] = function(r) { return typeof r === e || "a" + (t < 1 ? "n " : " ") + e; }; }); const Ms = {}; Nr.transitional = function(t, n, r) { function s(i, o) { return "[Axios v" + zi + "] Transitional option '" + i + "'" + o + (r ? ". " + r : ""); } return (i, o, l) => { if (t === !1) throw new $( s(o, " has been removed" + (n ? " in " + n : "")), $.ERR_DEPRECATED ); return n && !Ms[o] && (Ms[o] = !0, console.warn( s( o, " has been deprecated since v" + n + " and will be removed in the near future" ) )), t ? t(i, o, l) : !0; }; }; function uu(e, t, n) { if (typeof e != "object") throw new $("options must be an object", $.ERR_BAD_OPTION_VALUE); const r = Object.keys(e); let s = r.length; for (; s-- > 0; ) { const i = r[s], o = t[i]; if (o) { const l = e[i], c = l === void 0 || o(l, i, e); if (c !== !0) throw new $("option " + i + " must be " + c, $.ERR_BAD_OPTION_VALUE); continue; } if (n !== !0) throw new $("Unknown option " + i, $.ERR_BAD_OPTION); } } const cr = { assertOptions: uu, validators: Nr }, je = cr.validators; class cn { constructor(t) { this.defaults = t, this.interceptors = { request: new vs(), response: new vs() }; } /** * Dispatch a request * * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults) * @param {?Object} config * * @returns {Promise} The Promise to be fulfilled */ async request(t, n) { try { return await this._request(t, n); } catch (r) { if (r instanceof Error) { let s; Error.captureStackTrace ? Error.captureStackTrace(s = {}) : s = new Error(); const i = s.stack ? s.stack.replace(/^.+\n/, "") : ""; r.stack ? i && !String(r.stack).endsWith(i.replace(/^.+\n.+\n/, "")) && (r.stack += ` ` + i) : r.stack = i; } throw r; } } _request(t, n) { typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = dt(this.defaults, n); const { transitional: r, paramsSerializer: s, headers: i } = n; r !== void 0 && cr.assertOptions(r, { silentJSONParsing: je.transitional(je.boolean), forcedJSONParsing: je.transitional(je.boolean), clarifyTimeoutError: je.transitional(je.boolean) }, !1), s != null && (m.isFunction(s) ? n.paramsSerializer = { serialize: s } : cr.assertOptions(s, { encode: je.function, serialize: je.function }, !0)), n.method = (n.method || this.defaults.method || "get").toLowerCase(); let o = i && m.merge( i.common, i[n.method] ); i && m.forEach( ["delete", "get", "head", "post", "put", "patch", "common"], (A) => { delete i[A]; } ), n.headers = Ie.concat(o, i); const l = []; let c = !0; this.interceptors.request.forEach(function(O) { typeof O.runWhen == "function" && O.runWhen(n) === !1 || (c = c && O.synchronous, l.unshift(O.fulfilled, O.rejected)); }); const f = []; this.interceptors.response.forEach(function(O) { f.push(O.fulfilled, O.rejected); }); let d, h = 0, E; if (!c) { const A = [Cs.bind(this), void 0]; for (A.unshift.apply(A, l), A.push.apply(A, f), E = A.length, d = Promise.resolve(n); h < E; ) d = d.then(A[h++], A[h++]); return d; } E = l.length; let R = n; for (h = 0; h < E; ) { const A = l[h++], O = l[h++]; try { R = A(R); } catch (B) { O.call(this, B); break; } } try { d = Cs.call(this, R); } catch (A) { return Promise.reject(A); } for (h = 0, E = f.length; h < E; ) d = d.then(f[h++], f[h++]); return d; } getUri(t) { t = dt(this.defaults, t); const n = Hi(t.baseURL, t.url); return $i(n, t.params, t.paramsSerializer); } } m.forEach(["delete", "get", "head", "options"], function(t) { cn.prototype[t] = function(n, r) { return this.request(dt(r || {}, { method: t, url: n, data: (r || {}).data })); }; }); m.forEach(["post", "put", "patch"], function(t) { function n(r) { return function(i, o, l) { return this.request(dt(l || {}, { method: t, headers: r ? { "Content-Type": "multipart/form-data" } : {}, url: i, data: o })); }; } cn.prototype[t] = n(), cn.prototype[t + "Form"] = n(!0); }); const tn = cn; class Br { constructor(t) { if (typeof t != "function") throw new TypeError("executor must be a function."); let n; this.promise = new Promise(function(i) { n = i; }); const r = this; this.promise.then((s) => { if (!r._listeners) return; let i = r._listeners.length; for (; i-- > 0; ) r._listeners[i](s); r._listeners = null; }), this.promise.then = (s) => { let i; const o = new Promise((l) => { r.subscribe(l), i = l; }).then(s); return o.cancel = function() { r.unsubscribe(i); }, o; }, t(function(i, o, l) { r.reason || (r.reason = new kt(i, o, l), n(r.reason)); }); } /** * Throws a `CanceledError` if cancellation has been requested. */ throwIfRequested() { if (this.reason) throw this.reason; } /** * Subscribe to the cancel signal */ subscribe(t) { if (this.reason) { t(this.reason); return; } this._listeners ? this._listeners.push(t) : this._listeners = [t]; } /** * Unsubscribe from the cancel signal */ unsubscribe(t) { if (!this._listeners) return; const n = this._listeners.indexOf(t); n !== -1 && this._listeners.splice(n, 1); } /** * Returns an object that contains a new `CancelToken` and a function that, when called, * cancels the `CancelToken`. */ static source() { let t; return { token: new Br(function(s) { t = s; }), cancel: t }; } } const fu = Br; function du(e) { return function(n) { return e.apply(null, n); }; } function hu(e) { return m.isObject(e) && e.isAxiosError === !0; } const ar = { Continue: 100, SwitchingProtocols: 101, Processing: 102, EarlyHints: 103, Ok: 200, Created: 201, Accepted: 202, NonAuthoritativeInformation: 203, NoContent: 204, ResetContent: 205, PartialContent: 206, MultiStatus: 207, AlreadyReported: 208, ImUsed: 226, MultipleChoices: 300, MovedPermanently: 301, Found: 302, SeeOther: 303, NotModified: 304, UseProxy: 305, Unused: 306, TemporaryRedirect: 307, PermanentRedirect: 308, BadRequest: 400, Unauthorized: 401, PaymentRequired: 402, Forbidden: 403, NotFound: 404, MethodNotAllowed: 405, NotAcceptable: 406, ProxyAuthenticationRequired: 407, RequestTimeout: 408, Conflict: 409, Gone: 410, LengthRequired: 411, PreconditionFailed: 412, PayloadTooLarge: 413, UriTooLong: 414, UnsupportedMediaType: 415, RangeNotSatisfiable: 416, ExpectationFailed: 417, ImATeapot: 418, MisdirectedRequest: 421, UnprocessableEntity: 422, Locked: 423, FailedDependency: 424, TooEarly: 425, UpgradeRequired: 426, PreconditionRequired: 428, TooManyRequests: 429, RequestHeaderFieldsTooLarge: 431, UnavailableForLegalReasons: 451, InternalServerError: 500, NotImplemented: 501, BadGateway: 502, ServiceUnavailable: 503, GatewayTimeout: 504, HttpVersionNotSupported: 505, VariantAlsoNegotiates: 506, InsufficientStorage: 507, LoopDetected: 508, NotExtended: 510, NetworkAuthenticationRequired: 511 }; Object.entries(ar).forEach(([e, t]) => { ar[t] = e; }); const pu = ar; function qi(e) { const t = new tn(e), n = Ai(tn.prototype.request, t); return m.extend(n, tn.prototype, t, { allOwnKeys: !0 }), m.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) { return qi(dt(e, s)); }, n; } const X = qi(Tr); X.Axios = tn; X.CanceledError = kt; X.CancelToken = fu; X.isCancel = Vi; X.VERSION = zi; X.toFormData = On; X.AxiosError = $; X.Cancel = X.CanceledError; X.all = function(t) { return Promise.all(t); }; X.spread = du; X.isAxiosError = hu; X.mergeConfig = dt; X.AxiosHeaders = Ie; X.formToJSON = (e) => Di(m.isHTMLForm(e) ? new FormData(e) : e); X.getAdapter = Wi.getAdapter; X.HttpStatusCode = pu; X.default = X; const mu = { "Amazon Silk": "amazon_silk", "Android Browser": "android", Bada: "bada", BlackBerry: "blackberry", Chrome: "chrome", Chromium: "chromium", Electron: "electron", Epiphany: "epiphany", Firefox: "firefox", Focus: "focus", Generic: "generic", "Google Search": "google_search", Googlebot: "googlebot", "Internet Explorer": "ie", "K-Meleon": "k_meleon", Maxthon: "maxthon", "Microsoft Edge": "edge", "MZ Browser": "mz", "NAVER Whale Browser": "naver", Opera: "opera", "Opera Coast": "opera_coast", PhantomJS: "phantomjs", Puffin: "puffin", QupZilla: "qupzilla", QQ: "qq", QQLite: "qqlite", Safari: "safari", Sailfish: "sailfish", "Samsung Internet for Android": "samsung_internet", SeaMonkey: "seamonkey", Sleipnir: "sleipnir", Swing: "swing", Tizen: "tizen", "UC Browser": "uc", Vivaldi: "vivaldi", "WebOS Browser": "webos", WeChat: "wechat", "Yandex Browser": "yandex", Roku: "roku" }, Ki = { amazon_silk: "Amazon Silk", android: "Android Browser", bada: "Bada", blackberry: "BlackBerry", chrome: "Chrome", chromium: "Chromium", electron: "Electron", epiphany: "Epiphany", firefox: "Firefox", focus: "Focus", generic: "Generic", googlebot: "Googlebot", google_search: "Google Search", ie: "Internet Explorer", k_meleon: "K-Meleon", maxthon: "Maxthon", edge: "Microsoft Edge", mz: "MZ Browser", naver: "NAVER Whale Browser", opera: "Opera", opera_coast: "Opera Coast", phantomjs: "PhantomJS", puffin: "Puffin", qupzilla: "QupZilla", qq: "QQ Browser", qqlite: "QQ Browser Lite", safari: "Safari", sailfish: "Sailfish", samsung_internet: "Samsung Internet for Android", seamonkey: "SeaMonkey", sleipnir: "Sleipnir", swing: "Swing", tizen: "Tizen", uc: "UC Browser", vivaldi: "Vivaldi", webos: "WebOS Browser", wechat: "WeChat", yandex: "Yandex Browser" }, G = { tablet: "tablet", mobile: "mobile", desktop: "desktop", tv: "tv" }, le = { WindowsPhone: "Windows Phone", Windows: "Windows", MacOS: "macOS", iOS: "iOS", Android: "Android", WebOS: "WebOS", BlackBerry: "BlackBerry", Bada: "Bada", Tizen: "Tizen", Linux: "Linux", ChromeOS: "Chrome OS", PlayStation4: "PlayStation 4", Roku: "Roku" }, Ue = { EdgeHTML: "EdgeHTML", Blink: "Blink", Trident: "Trident", Presto: "Presto", Gecko: "Gecko", WebKit: "WebKit" }; class g { /** * Get first matched item for a string * @param {RegExp} regexp * @param {String} ua * @return {Array|{index: number, input: string}|*|boolean|string} */ static getFirstMatch(t, n) { const r = n.match(t); return r && r.length > 0 && r[1] || ""; } /** * Get second matched item for a string * @param regexp * @param {String} ua * @return {Array|{index: number, input: string}|*|boolean|string} */ static getSecondMatch(t, n) { const r = n.match(t); return r && r.length > 1 && r[2] || ""; } /** * Match a regexp and return a constant or undefined * @param {RegExp} regexp * @param {String} ua * @param {*} _const Any const that will be returned if regexp matches the string * @return {*} */ static matchAndReturnConst(t, n, r) { if (t.test(n)) return r; } static getWindowsVersionName(t) { switch (t) { case "NT": return "NT"; case "XP": return "XP"; case "NT 5.0": return "2000"; case "NT 5.1": return "XP"; case "NT 5.2": return "2003"; case "NT 6.0": return "Vista"; case "NT 6.1": return "7"; case "NT 6.2": return "8"; case "NT 6.3": return "8.1"; case "NT 10.0": return "10"; default: return; } } /** * Get macOS version name * 10.5 - Leopard * 10.6 - Snow Leopard * 10.7 - Lion * 10.8 - Mountain Lion * 10.9 - Mavericks * 10.10 - Yosemite * 10.11 - El Capitan * 10.12 - Sierra * 10.13 - High Sierra * 10.14 - Mojave * 10.15 - Catalina * * @example * getMacOSVersionName("10.14") // 'Mojave' * * @param {string} version * @return {string} versionName */ static getMacOSVersionName(t) { const n = t.split(".").splice(0, 2).map((r) => parseInt(r, 10) || 0); if (n.push(0), n[0] === 10) switch (n[1]) { case 5: return "Leopard"; case 6: return "Snow Leopard"; case 7: return "Lion"; case 8: return "Mountain Lion"; case 9: return "Mavericks"; case 10: return "Yosemite"; case 11: return "El Capitan"; case 12: return "Sierra"; case 13: return "High Sierra"; case 14: return "Mojave"; case 15: return "Catalina"; default: return; } } /** * Get Android version name * 1.5 - Cupcake * 1.6 - Donut * 2.0 - Eclair * 2.1 - Eclair * 2.2 - Froyo * 2.x - Gingerbread * 3.x - Honeycomb * 4.0 - Ice Cream Sandwich * 4.1 - Jelly Bean * 4.4 - KitKat * 5.x - Lollipop * 6.x - Marshmallow * 7.x - Nougat * 8.x - Oreo * 9.x - Pie * * @example * getAndroidVersionName("7.0") // 'Nougat' * * @param {string} version * @return {string} versionName */ static getAndroidVersionName(t) { const n = t.split(".").splice(0, 2).map((r) => parseInt(r, 10) || 0); if (n.push(0), !(n[0] === 1 && n[1] < 5)) { if (n[0] === 1 && n[1] < 6) return "Cupcake"; if (n[0] === 1 && n[1] >= 6) return "Donut"; if (n[0] === 2 && n[1] < 2) return "Eclair"; if (n[0] === 2 && n[1] === 2) return "Froyo"; if (n[0] === 2 && n[1] > 2) return "Gingerbread"; if (n[0] === 3) return "Honeycomb"; if (n[0] === 4 && n[1] < 1) return "Ice Cream Sandwich"; if (n[0] === 4 && n[1] < 4) return "Jelly Bean"; if (n[0] === 4 && n[1] >= 4) return "KitKat"; if (n[0] === 5) return "Lollipop"; if (n[0] === 6) return "Marshmallow"; if (n[0] === 7) return "Nougat"; if (n[0] === 8) return "Oreo"; if (n[0] === 9) return "Pie"; } } /** * Get version precisions count * * @example * getVersionPrecision("1.10.3") // 3 * * @param {string} version * @return {number} */ static getVersionPrecision(t) { return t.split(".").length; } /** * Calculate browser version weight * * @example * compareVersions('1.10.2.1', '1.8.2.1.90') // 1 * compareVersions('1.010.2.1', '1.09.2.1.90'); // 1 * compareVersions('1.10.2.1', '1.10.2.1'); // 0 * compareVersions('1.10.2.1', '1.0800.2'); // -1 * compareVersions('1.10.2.1', '1.10', true); // 0 * * @param {String} versionA versions versions to compare * @param {String} versionB versions versions to compare * @param {boolean} [isLoose] enable loose comparison * @return {Number} comparison result: -1 when versionA is lower, * 1 when versionA is bigger, 0 when both equal */ /* eslint consistent-return: 1 */ static compareVersions(t, n, r = !1) { const s = g.getVersionPrecision(t), i = g.getVersionPrecision(n); let o = Math.max(s, i), l = 0; const c = g.map([t, n], (f) => { const d = o - g.getVersionPrecision(f), h = f + new Array(d + 1).join(".0"); return g.map(h.split("."), (E) => new Array(20 - E.length).join("0") + E).reverse(); }); for (r && (l = o - Math.min(s, i)), o -= 1; o >= l; ) { if (c[0][o] > c[1][o]) return 1; if (c[0][o] === c[1][o]) { if (o === l) return 0; o -= 1; } else if (c[0][o] < c[1][o]) return -1; } } /** * Array::map polyfill * * @param {Array} arr * @param {Function} iterator * @return {Array} */ static map(t, n) { const r = []; let s; if (Array.prototype.map) return Array.prototype.map.call(t, n); for (s = 0; s < t.length; s += 1) r.push(n(t[s])); return r; } /** * Array::find polyfill * * @param {Array} arr * @param {Function} predicate * @return {Array} */ static find(t, n) { let r, s; if (Array.prototype.find) return Array.prototype.find.call(t, n); for (r = 0, s = t.length; r < s; r += 1) { const i = t[r]; if (n(i, r)) return i; } } /** * Object::assign polyfill * * @param {Object} obj * @param {Object} ...objs * @return {Object} */ static assign(t, ...n) { const r = t; let s, i; if (Object.assign) return Object.assign(t, ...n); for (s = 0, i = n.length; s < i; s += 1) { const o = n[s]; typeof o == "object" && o !== null && Object.keys(o).forEach((c) => { r[c] = o[c]; }); } return t; } /** * Get short version/alias for a browser name * * @example * getBrowserAlias('Microsoft Edge') // edge * * @param {string} browserName * @return {string} */ static getBrowserAlias(t) { return mu[t]; } /** * Get short version/alias for a browser name * * @example * getBrowserAlias('edge') // Microsoft Edge * * @param {string} browserAlias * @return {string} */ static getBrowserTypeByAlias(t) { return Ki[t] || ""; } } const H = /version\/(\d+(\.?_?\d+)+)/i, gu = [ /* Googlebot */ { test: [/googlebot/i], describe(e) { const t = { name: "Googlebot" }, n = g.getFirstMatch(/googlebot\/(\d+(\.\d+))/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, /* Opera < 13.0 */ { test: [/opera/i], describe(e) { const t = { name: "Opera" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, /* Opera > 13.0 */ { test: [/opr\/|opios/i], describe(e) { const t = { name: "Opera" }, n = g.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/SamsungBrowser/i], describe(e) { const t = { name: "Samsung Internet for Android" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/Whale/i], describe(e) { const t = { name: "NAVER Whale Browser" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/MZBrowser/i], describe(e) { const t = { name: "MZ Browser" }, n = g.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/focus/i], describe(e) { const t = { name: "Focus" }, n = g.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/swing/i], describe(e) { const t = { name: "Swing" }, n = g.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/coast/i], describe(e) { const t = { name: "Opera Coast" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/opt\/\d+(?:.?_?\d+)+/i], describe(e) { const t = { name: "Opera Touch" }, n = g.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/yabrowser/i], describe(e) { const t = { name: "Yandex Browser" }, n = g.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/ucbrowser/i], describe(e) { const t = { name: "UC Browser" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/Maxthon|mxios/i], describe(e) { const t = { name: "Maxthon" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/epiphany/i], describe(e) { const t = { name: "Epiphany" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/puffin/i], describe(e) { const t = { name: "Puffin" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/sleipnir/i], describe(e) { const t = { name: "Sleipnir" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/k-meleon/i], describe(e) { const t = { name: "K-Meleon" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/micromessenger/i], describe(e) { const t = { name: "WeChat" }, n = g.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/qqbrowser/i], describe(e) { const t = { name: /qqbrowserlite/i.test(e) ? "QQ Browser Lite" : "QQ Browser" }, n = g.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/msie|trident/i], describe(e) { const t = { name: "Internet Explorer" }, n = g.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/\sedg\//i], describe(e) { const t = { name: "Microsoft Edge" }, n = g.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/edg([ea]|ios)/i], describe(e) { const t = { name: "Microsoft Edge" }, n = g.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/vivaldi/i], describe(e) { const t = { name: "Vivaldi" }, n = g.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/seamonkey/i], describe(e) { const t = { name: "SeaMonkey" }, n = g.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/sailfish/i], describe(e) { const t = { name: "Sailfish" }, n = g.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i, e); return n && (t.version = n), t; } }, { test: [/silk/i], describe(e) { const t = { name: "Amazon Silk" }, n = g.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/phantom/i], describe(e) { const t = { name: "PhantomJS" }, n = g.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/slimerjs/i], describe(e) { const t = { name: "SlimerJS" }, n = g.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/blackberry|\bbb\d+/i, /rim\stablet/i], describe(e) { const t = { name: "BlackBerry" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/(web|hpw)[o0]s/i], describe(e) { const t = { name: "WebOS Browser" }, n = g.getFirstMatch(H, e) || g.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/bada/i], describe(e) { const t = { name: "Bada" }, n = g.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/tizen/i], describe(e) { const t = { name: "Tizen" }, n = g.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/qupzilla/i], describe(e) { const t = { name: "QupZilla" }, n = g.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/firefox|iceweasel|fxios/i], describe(e) { const t = { name: "Firefox" }, n = g.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/electron/i], describe(e) { const t = { name: "Electron" }, n = g.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/MiuiBrowser/i], describe(e) { const t = { name: "Miui" }, n = g.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/chromium/i], describe(e) { const t = { name: "Chromium" }, n = g.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i, e) || g.getFirstMatch(H, e); return n && (t.version = n), t; } }, { test: [/chrome|crios|crmo/i], describe(e) { const t = { name: "Chrome" }, n = g.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, { test: [/GSA/i], describe(e) { const t = { name: "Google Search" }, n = g.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, /* Android Browser */ { test(e) { const t = !e.test(/like android/i), n = e.test(/android/i); return t && n; }, describe(e) { const t = { name: "Android Browser" }, n = g.getFirstMatch(H, e); return n && (t.version = n), t; } }, /* PlayStation 4 */ { test: [/playstation 4/i], describe(e) { const t = { name: "PlayStation 4" }, n = g.getFirstMatch(H, e); return n && (t.version = n), t; } }, /* Safari */ { test: [/safari|applewebkit/i], describe(e) { const t = { name: "Safari" }, n = g.getFirstMatch(H, e); return n && (t.version = n), t; } }, /* Something else */ { test: [/.*/i], describe(e) { const t = /^(.*)\/(.*) /, n = /^(.*)\/(.*)[ \t]\((.*)/, s = e.search("\\(") !== -1 ? n : t; return { name: g.getFirstMatch(s, e), version: g.getSecondMatch(s, e) }; } } ], bu = [ /* Roku */ { test: [/Roku\/DVP/], describe(e) { const t = g.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i, e); return { name: le.Roku, version: t }; } }, /* Windows Phone */ { test: [/windows phone/i], describe(e) { const t = g.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i, e); return { name: le.WindowsPhone, version: t }; } }, /* Windows */ { test: [/windows /i], describe(e) { const t = g.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i, e), n = g.getWindowsVersionName(t); return { name: le.Windows, version: t, versionName: n }; } }, /* Firefox on iPad */ { test: [/Macintosh(.*?) FxiOS(.*?)\//], describe(e) { const t = { name: le.iOS }, n = g.getSecondMatch(/(Version\/)(\d[\d.]+)/, e); return n && (t.version = n), t; } }, /* macOS */ { test: [/macintosh/i], describe(e) { const t = g.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i, e).replace(/[_\s]/g, "."), n = g.getMacOSVersionName(t), r = { name: le.MacOS, version: t }; return n && (r.versionName = n), r; } }, /* iOS */ { test: [/(ipod|iphone|ipad)/i], describe(e) { const t = g.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i, e).replace(/[_\s]/g, "."); return { name: le.iOS, version: t }; } }, /* Android */ { test(e) { const t = !e.test(/like android/i), n = e.test(/android/i); return t && n; }, describe(e) { const t = g.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i, e), n = g.getAndroidVersionName(t), r = { name: le.Android, version: t }; return n && (r.versionName = n), r; } }, /* WebOS */ { test: [/(web|hpw)[o0]s/i], describe(e) { const t = g.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i, e), n = { name: le.WebOS }; return t && t.length && (n.version = t), n; } }, /* BlackBerry */ { test: [/blackberry|\bbb\d+/i, /rim\stablet/i], describe(e) { const t = g.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i, e) || g.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i, e) || g.getFirstMatch(/\bbb(\d+)/i, e); return { name: le.BlackBerry, version: t }; } }, /* Bada */ { test: [/bada/i], describe(e) { const t = g.getFirstMatch(/bada\/(\d+(\.\d+)*)/i, e); return { name: le.Bada, version: t }; } }, /* Tizen */ { test: [/tizen/i], describe(e) { const t = g.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i, e); return { name: le.Tizen, version: t }; } }, /* Linux */ { test: [/linux/i], describe() { return { name: le.Linux }; } }, /* Chrome OS */ { test: [/CrOS/], describe() { return { name: le.ChromeOS }; } }, /* Playstation 4 */ { test: [/PlayStation 4/], describe(e) { const t = g.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i, e); return { name: le.PlayStation4, version: t }; } } ], wu = [ /* Googlebot */ { test: [/googlebot/i], describe() { return { type: "bot", vendor: "Google" }; } }, /* Huawei */ { test: [/huawei/i], describe(e) { const t = g.getFirstMatch(/(can-l01)/i, e) && "Nova", n = { type: G.mobile, vendor: "Huawei" }; return t && (n.model = t), n; } }, /* Nexus Tablet */ { test: [/nexus\s*(?:7|8|9|10).*/i], describe() { return { type: G.tablet, vendor: "Nexus" }; } }, /* iPad */ { test: [/ipad/i], describe() { return { type: G.tablet, vendor: "Apple", model: "iPad" }; } }, /* Firefox on iPad */ { test: [/Macintosh(.*?) FxiOS(.*?)\//], describe() { return { type: G.tablet, vendor: "Apple", model: "iPad" }; } }, /* Amazon Kindle Fire */ { test: [/kftt build/i], describe() { return { type: G.tablet, vendor: "Amazon", model: "Kindle Fire HD 7" }; } }, /* Another Amazon Tablet with Silk */ { test: [/silk/i], describe() { return { type: G.tablet, vendor: "Amazon" }; } }, /* Tablet */ { test: [/tablet(?! pc)/i], describe() { return { type: G.tablet }; } }, /* iPod/iPhone */ { test(e) { const t = e.test(/ipod|iphone/i), n = e.test(/like (ipod|iphone)/i); return t && !n; }, describe(e) { const t = g.getFirstMatch(/(ipod|iphone)/i, e); return { type: G.mobile, vendor: "Apple", model: t }; } }, /* Nexus Mobile */ { test: [/nexus\s*[0-6].*/i, /galaxy nexus/i], describe() { return { type: G.mobile, vendor: "Nexus" }; } }, /* Mobile */ { test: [/[^-]mobi/i], describe() { return { type: G.mobile }; } }, /* BlackBerry */ { test(e) { return e.getBrowserName(!0) === "blackberry"; }, describe() { return { type: G.mobile, vendor: "BlackBerry" }; } }, /* Bada */ { test(e) { return e.getBrowserName(!0) === "bada"; }, describe() { return { type: G.mobile }; } }, /* Windows Phone */ { test(e) { return e.getBrowserName() === "windows phone"; }, describe() { return { type: G.mobile, vendor: "Microsoft" }; } }, /* Android Tablet */ { test(e) { const t = Number(String(e.getOSVersion()).split(".")[0]); return e.getOSName(!0) === "android" && t >= 3; }, describe() { return { type: G.tablet }; } }, /* Android Mobile */ { test(e) { return e.getOSName(!0) === "android"; }, describe() { return { type: G.mobile }; } }, /* desktop */ { test(e) { return e.getOSName(!0) === "macos"; }, describe() { return { type: G.desktop, vendor: "Apple" }; } }, /* Windows */ { test(e) { return e.getOSName(!0) === "windows"; }, describe() { return { type: G.desktop }; } }, /* Linux */ { test(e) { return e.getOSName(!0) === "linux"; }, describe() { return { type: G.desktop }; } }, /* PlayStation 4 */ { test(e) { return e.getOSName(!0) === "playstation 4"; }, describe() { return { type: G.tv }; } }, /* Roku */ { test(e) { return e.getOSName(!0) === "roku"; }, describe() { return { type: G.tv }; } } ], yu = [ /* EdgeHTML */ { test(e) { return e.getBrowserName(!0) === "microsoft edge"; }, describe(e) { if (/\sedg\//i.test(e)) return { name: Ue.Blink }; const n = g.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i, e); return { name: Ue.EdgeHTML, version: n }; } }, /* Trident */ { test: [/trident/i], describe(e) { const t = { name: Ue.Trident }, n = g.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, /* Presto */ { test(e) { return e.test(/presto/i); }, describe(e) { const t = { name: Ue.Presto }, n = g.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, /* Gecko */ { test(e) { const t = e.test(/gecko/i), n = e.test(/like gecko/i); return t && !n; }, describe(e) { const t = { name: Ue.Gecko }, n = g.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } }, /* Blink */ { test: [/(apple)?webkit\/537\.36/i], describe() { return { name: Ue.Blink }; } }, /* WebKit */ { test: [/(apple)?webkit/i], describe(e) { const t = { name: Ue.WebKit }, n = g.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i, e); return n && (t.version = n), t; } } ]; class Fs { /** * Create instance of Parser * * @param {String} UA User-Agent string * @param {Boolean} [skipParsing=false] parser can skip parsing in purpose of performance * improvements if you need to make a more particular parsing * like {@link Parser#parseBrowser} or {@link Parser#parsePlatform} * * @throw {Error} in case of empty UA String * * @constructor */ constructor(t, n = !1) { if (t == null || t === "") throw new Error("UserAgent parameter can't be empty"); this._ua = t, this.parsedResult = {}, n !== !0 && this.parse(); } /** * Get UserAgent string of current Parser instance * @return {String} User-Agent String of the current <Parser> object * * @public */ getUA() { return this._ua; } /** * Test a UA string for a regexp * @param {RegExp} regex * @return {Boolean} */ test(t) { return t.test(this._ua); } /** * Get parsed browser object * @return {Object} */ parseBrowser() { this.parsedResult.browser = {}; const t = g.find(gu, (n) => { if (typeof n.test == "function") return n.test(this); if (n.test instanceof Array) return n.test.some((r) => this.test(r)); throw new Error("Browser's test function is not valid"); }); return t && (this.parsedResult.browser = t.describe(this.getUA())), this.parsedResult.browser; } /** * Get parsed browser object * @return {Object} * * @public */ getBrowser() { return this.parsedResult.browser ? this.parsedResult.browser : this.parseBrowser(); } /** * Get browser's name * @return {String} Browser's name or an empty string * * @public */ getBrowserName(t) { return t ? String(this.getBrowser().name).toLowerCase() || "" : this.getBrowser().name || ""; } /** * Get browser's version * @return {String} version of browser * * @public */ getBrowserVersion() { return this.getBrowser().version; } /** * Get OS * @return {Object} * * @example * this.getOS(); * { * name: 'macOS', * version: '10.11.12' * } */ getOS() { return this.parsedResult.os ? this.parsedResult.os : this.parseOS(); } /** * Parse OS and save it to this.parsedResult.os * @return {*|{}} */ parseOS() { this.parsedResult.os = {}; const t = g.find(bu, (n) => { if (typeof n.test == "function") return n.test(this); if (n.test instanceof Array) return n.test.some((r) => this.test(r)); throw new Error("Browser's test function is not valid"); }); return t && (this.parsedResult.os = t.describe(this.getUA())), this.parsedResult.os; } /** * Get OS name * @param {Boolean} [toLowerCase] return lower-cased value * @return {String} name of the OS — macOS, Windows, Linux, etc. */ getOSName(t) { const { name: n } = this.getOS(); return t ? String(n).toLowerCase() || "" : n || ""; } /** * Get OS version * @return {String} full version with dots ('10.11.12', '5.6', etc) */ getOSVersion() { return this.getOS().version; } /** * Get parsed platform * @return {{}} */ getPlatform() { return this.parsedResult.platform ? this.parsedResult.platform : this.parsePlatform(); } /** * Get platform name * @param {Boolean} [toLowerCase=false] * @return {*} */ getPlatformType(t = !1) { const { type: n } = this.getPlatform(); return t ? String(n).toLowerCase() || "" : n || ""; } /** * Get parsed platform * @return {{}} */ parsePlatform() { this.parsedResult.platform = {}; const t = g.find(wu, (n) => { if (typeof n.test == "function") return n.test(this); if (n.test instanceof Array) return n.test.some((r) => this.test(r)); throw new Error("Browser's test function is not valid"); }); return t && (this.parsedResult.platform = t.describe(this.getUA())), this.parsedResult.platform; } /** * Get parsed engine * @return {{}} */ getEngine() { return this.parsedResult.engine ? this.parsedResult.engine : this.parseEngine(); } /** * Get engines's name * @return {String} Engines's name or an empty string * * @public */ getEngineName(t) { return t ? String(this.getEngine().name).toLowerCase() || "" : this.getEngine().name || ""; } /** * Get parsed platform * @return {{}} */ parseEngine() { this.parsedResult.engine = {}; const t = g.find(yu, (n) => { if (typeof n.test == "function") return n.test(this); if (n.test instanceof Array) return n.test.some((r) => this.test(r)); throw new Error("Browser's test function is not valid"); }); return t && (this.parsedResult.engine = t.describe(this.getUA())), this.parsedResult.engine; } /** * Parse full information about the browser * @returns {Parser} */ parse() { return this.parseBrowser(), this.parseOS(), this.parsePlatform(), this.parseEngine(), this; } /** * Get parsed result * @return {ParsedResult} */ getResult() { return g.assign({}, this.parsedResult); } /** * Check if parsed browser matches certain conditions * * @param {Object} checkTree It's one or two layered object, * which can include a platform or an OS on the first layer * and should have browsers specs on the bottom-laying layer * * @returns {Boolean|undefined} Whether the browser satisfies the set conditions or not. * Returns `undefined` when the browser is no described in the checkTree object. * * @example * const browser = Bowser.getParser(window.navigator.userAgent); * if (browser.satisfies({chrome: '>118.01.1322' })) * // or with os * if (browser.satisfies({windows: { chrome: '>118.01.1322' } })) * // or with platforms * if (browser.satisfies({desktop: { chrome: '>118.01.1322' } })) */ satisfies(t) { const n = {}; let r = 0; const s = {}; let i = 0; if (Object.keys(t).forEach((l) => { const c = t[l]; typeof c == "string" ? (s[l] = c, i += 1) : typeof c == "object" && (n[l] = c, r += 1); }), r > 0) { const l = Object.keys(n), c = g.find(l, (d) => this.isOS(d)); if (c) { const d = this.satisfies(n[c]); if (d !== void 0) return d; } const f = g.find( l, (d) => this.isPlatform(d) ); if (f) { const d = this.satisfies(n[f]); if (d !== void 0) return d; } } if (i > 0) { const l = Object.keys(s), c = g.find(l, (f) => this.isBrowser(f, !0)); if (c !== void 0) return this.compareVersion(s[c]); } } /** * Check if the browser name equals the passed string * @param browserName The string to compare with the browser name * @param [includingAlias=false] The flag showing whether alias will be included into comparison * @returns {boolean} */ isBrowser(t, n = !1) { const r = this.getBrowserName().toLowerCase(); let s = t.toLowerCase(); const i = g.getBrowserTypeByAlias(s); return n && i && (s = i.toLowerCase()), s === r; } compareVersion(t) { let n = [0], r = t, s = !1; const i = this.getBrowserVersion(); if (typeof i == "string") return t[0] === ">" || t[0] === "<" ? (r = t.substr(1), t[1] === "=" ? (s = !0, r = t.substr(2)) : n = [], t[0] === ">" ? n.push(1) : n.push(-1)) : t[0] === "=" ? r = t.substr(1) : t[0] === "~" && (s = !0, r = t.substr(1)), n.indexOf( g.compareVersions(i, r, s) ) > -1; } isOS(t) { return this.getOSName(!0) === String(t).toLowerCase(); } isPlatform(t) { return this.getPlatformType(!0) === String(t).toLowerCase(); } isEngine(t) { return this.getEngineName(!0) === String(t).toLowerCase(); } /** * Is anything? Check if the browser is called "anything", * the OS called "anything" or the platform called "anything" * @param {String} anything * @param [includingAlias=false] The flag showing whether alias will be included into comparison * @returns {Boolean} */ is(t, n = !1) { return this.isBrowser(t, n) || this.isOS(t) || this.isPlatform(t); } /** * Check if any of the given values satisfies this.is(anything) * @param {String[]} anythings * @returns {Boolean} */ some(t = []) { return t.some((n) => this.is(n)); } } /*! * Bowser - a browser detector * https://github.com/lancedikson/bowser * MIT License | (c) Dustin Diaz 2012-2015 * MIT License | (c) Denis Demchenko 2015-2019 */ class _u { /** * Creates a {@link Parser} instance * * @param {String} UA UserAgent string * @param {Boolean} [skipParsing=false] Will make the Parser postpone parsing until you ask it * explicitly. Same as `skipParsing` for {@link Parser}. * @returns {Parser} * @throws {Error} when UA is not a String * * @example * const parser = Bowser.getParser(window.navigator.userAgent); * const result = parser.getResult(); */ static getParser(t, n = !1) { if (typeof t != "string") throw new Error("UserAgent should be a string"); return new Fs(t, n); } /** * Creates a {@link Parser} instance and runs {@link Parser.getResult} immediately * * @param UA * @return {ParsedResult} * * @example * const result = Bowser.parse(window.navigator.userAgent); */ static parse(t) { return new Fs(t).getResult(); } static get BROWSER_MAP() { return Ki; } static get ENGINE_MAP() { return Ue; } static get OS_MAP() { return le; } static get PLATFORMS_MAP() { return G; } } const Su = "https://business.comparisure.co.za"; function Eu() { console.log("[RC] Notifying server that script has loaded"); const e = _u.getParser(window.navigator.userAgent); X.post(`${Su}/api/plugin-metrics/`, { company: "companyId", // TODO: Replace with your company ID browser: e.getBrowser(), os: e.getOS(), platform: e.getPlatform(), domain: { hostName: window.location.hostname, href: window.location.href } }).then((t) => { console.log("[RC] Server notified that script has loaded"); }).catch((t) => { console.error("[RC] Error notifying server that script has loaded", t); }); } const vu = /* @__PURE__ */ Tt({ name: "App", components: { AlertWindow: Zc, WidgetButton: Ac, ConversationWindow: Gc }, mounted() { console.debug("[RC] Widget Mounted"), Eu(); }, data: () => ({ showWindow: !1, showAlert: !1 }) }), Ou = { class: "chat-container" }; function xu(e, t, n, r, s, i) { const o = Jt("conversation-window"), l = Jt("alert-window"), c = Jt("widget-button"); return Re(), Be("div", Ou, [ fe(o, { modelValue: e.showWindow, "onUpdate:modelValue": t[0] || (t[0] = (f) => e.showWindow = f), onSuccess: t[1] || (t[1] = (f) => e.showAlert = !0) }, null, 8, ["modelValue"]), fe(l, { modelValue: e.showAlert, "onUpdate:modelValue": t[2] || (t[2] = (f) => e.showAlert = f) }, null, 8, ["modelValue"]), fe(c, { onClick: t[3] || (t[3] = (f) => e.showWindow = !e.showWindow), bounce: !e.showWindow }, null, 8, ["bounce"]) ]); } const Au = /* @__PURE__ */ Bt(vu, [["render", xu], ["__scopeId", "data-v-2c6bcaa7"]]), Cu = function() { const e = document.getElementsByTagName("script"); let t = ""; for (let n = 0; n < e.length; n++) if (e[n].src.includes("chat-widget.js")) { t = e[n].src.replace(/chat-widget\.js$/, ""); break; } return t; }, Ru = function() { const e = document.createElement("script"); return e.src = "https://unpkg.com/vue@3/dist/vue.global.js", document.head.appendChild(e), e; }, Mu = function() { console.log("[RC] Create link tag with RC styling"); const e = document.createElement("link"); e.rel = "stylesheet", e.type = "text/css", e.href = `${Cu()}style.css`, document.head.appendChild(e); }, Fu = () => { const e = document.createElement("div"); document.body.appendChild(e), Sc(Au).mount(e); }; (function() { { const e = Ru(); Mu(), e.onload = () => { Fu(); }; } })();