@metabohub/forum-library
Version:
[](https://forgemia.inra.fr/metabohub/web-components/mth-forum-lib/-/commits/dev) [ => t in e ? Tf(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
var xe = (e, t, n) => Vf(e, typeof t != "symbol" ? t + "" : t, n);
import { defineComponent as Rr, ref as R, reactive as Zn, watchEffect as Ot, toRef as I, isVNode as Af, Comment as Ef, Fragment as pe, capitalize as na, shallowRef as ne, unref as _t, getCurrentInstance as Df, computed as _, provide as We, inject as De, warn as Fr, h as aa, camelize as Ko, toRefs as Jo, toValue as rn, createVNode as g, mergeProps as j, createElementVNode as p, normalizeClass as Q, Text as Mf, normalizeStyle as J, isRef as $s, TransitionGroup as _l, Transition as Mn, watch as re, onBeforeMount as Lr, nextTick as Ge, onBeforeUnmount as At, withDirectives as ht, vShow as Bn, onScopeDispose as mt, effectScope as kl, toRaw as He, useId as on, markRaw as Rf, onMounted as Ba, onUpdated as Ff, readonly as Cl, resolveDynamicComponent as Lf, toDisplayString as Te, Teleport as Nf, onDeactivated as Bf, cloneVNode as $f, createTextVNode as Fe, createElementBlock as nt, openBlock as qe, withCtx as fe, createBlock as Zo, createCommentVNode as ct, withKeys as Uf, onBeforeUpdate as zf, withModifiers as tr, resolveComponent as Hf } from "vue";
function Pl() {
const e = /* @__PURE__ */ new Map(), t = document.location.hash;
if (t.split("#").length === 3) {
const n = t.split("#")[2];
for (const a of n.split("&").values()) {
const r = a.split("=");
r.length === 2 && e.set(r[0], r[1]);
}
}
return e;
}
function On(e, t) {
const n = document.location.hash, a = Pl();
t === void 0 || t === "" || t === null ? a.delete(e) : a.set(e, t);
let r = "";
a.forEach((s, l) => {
r += "&" + l + "=" + s;
}), document.location.hash = "#" + n.split("#")[1] + "#" + r;
}
var ze = /* @__PURE__ */ ((e) => (e.comp_to_mesh = "comp_to_mesh", e.mesh_to_comp = "mesh_to_comp", e))(ze || {}), me = /* @__PURE__ */ ((e) => (e.mesh_id = "mesh_id", e.chebi_id = "chebi_id", e.chemont_id = "chemont_id", e.pubchem_id = "pubchem_id", e.pubchem_fuzzy_id = "pubchem_fuzzy_id", e))(me || {});
class Xo {
// String passed via the search bar
constructor() {
xe(this, "searchEntityType");
xe(this, "searchSelectorType");
xe(this, "searchEntityQuery");
this.searchEntityType = "comp_to_mesh", this.searchSelectorType = "pubchem_id", this.searchEntityQuery = "";
}
/**
* Function to verify if the query is empty
*/
isEmpty() {
return !this.searchEntityQuery || this.searchEntityQuery.length === 0 || !this.searchEntityQuery.trim();
}
}
function eu(e, t) {
return function() {
return e.apply(t, arguments);
};
}
const { toString: Yf } = Object.prototype, { getPrototypeOf: xl } = Object, { iterator: Nr, toStringTag: tu } = Symbol, Br = /* @__PURE__ */ ((e) => (t) => {
const n = Yf.call(t);
return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
})(/* @__PURE__ */ Object.create(null)), Et = (e) => (e = e.toLowerCase(), (t) => Br(t) === e), $r = (e) => (t) => typeof t === e, { isArray: ra } = Array, Pa = $r("undefined");
function jf(e) {
return e !== null && !Pa(e) && e.constructor !== null && !Pa(e.constructor) && dt(e.constructor.isBuffer) && e.constructor.isBuffer(e);
}
const nu = Et("ArrayBuffer");
function Wf(e) {
let t;
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && nu(e.buffer), t;
}
const Gf = $r("string"), dt = $r("function"), au = $r("number"), Ur = (e) => e !== null && typeof e == "object", Qf = (e) => e === !0 || e === !1, cr = (e) => {
if (Br(e) !== "object")
return !1;
const t = xl(e);
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(tu in e) && !(Nr in e);
}, qf = Et("Date"), Kf = Et("File"), Jf = Et("Blob"), Zf = Et("FileList"), Xf = (e) => Ur(e) && dt(e.pipe), eh = (e) => {
let t;
return e && (typeof FormData == "function" && e instanceof FormData || dt(e.append) && ((t = Br(e)) === "formdata" || // detect form-data instance
t === "object" && dt(e.toString) && e.toString() === "[object FormData]"));
}, th = Et("URLSearchParams"), [nh, ah, rh, sh] = ["ReadableStream", "Request", "Response", "Headers"].map(Et), lh = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
function $a(e, t, { allOwnKeys: n = !1 } = {}) {
if (e === null || typeof e > "u")
return;
let a, r;
if (typeof e != "object" && (e = [e]), ra(e))
for (a = 0, r = e.length; a < r; a++)
t.call(null, e[a], a, e);
else {
const s = n ? Object.getOwnPropertyNames(e) : Object.keys(e), l = s.length;
let i;
for (a = 0; a < l; a++)
i = s[a], t.call(null, e[i], i, e);
}
}
function ru(e, t) {
t = t.toLowerCase();
const n = Object.keys(e);
let a = n.length, r;
for (; a-- > 0; )
if (r = n[a], t === r.toLowerCase())
return r;
return null;
}
const Tn = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, su = (e) => !Pa(e) && e !== Tn;
function Us() {
const { caseless: e } = su(this) && this || {}, t = {}, n = (a, r) => {
const s = e && ru(t, r) || r;
cr(t[s]) && cr(a) ? t[s] = Us(t[s], a) : cr(a) ? t[s] = Us({}, a) : ra(a) ? t[s] = a.slice() : t[s] = a;
};
for (let a = 0, r = arguments.length; a < r; a++)
arguments[a] && $a(arguments[a], n);
return t;
}
const ih = (e, t, n, { allOwnKeys: a } = {}) => ($a(t, (r, s) => {
n && dt(r) ? e[s] = eu(r, n) : e[s] = r;
}, { allOwnKeys: a }), e), oh = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), uh = (e, t, n, a) => {
e.prototype = Object.create(t.prototype, a), e.prototype.constructor = e, Object.defineProperty(e, "super", {
value: t.prototype
}), n && Object.assign(e.prototype, n);
}, ch = (e, t, n, a) => {
let r, s, l;
const i = {};
if (t = t || {}, e == null) return t;
do {
for (r = Object.getOwnPropertyNames(e), s = r.length; s-- > 0; )
l = r[s], (!a || a(l, e, t)) && !i[l] && (t[l] = e[l], i[l] = !0);
e = n !== !1 && xl(e);
} while (e && (!n || n(e, t)) && e !== Object.prototype);
return t;
}, dh = (e, t, n) => {
e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
const a = e.indexOf(t, n);
return a !== -1 && a === n;
}, fh = (e) => {
if (!e) return null;
if (ra(e)) return e;
let t = e.length;
if (!au(t)) return null;
const n = new Array(t);
for (; t-- > 0; )
n[t] = e[t];
return n;
}, hh = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && xl(Uint8Array)), mh = (e, t) => {
const a = (e && e[Nr]).call(e);
let r;
for (; (r = a.next()) && !r.done; ) {
const s = r.value;
t.call(e, s[0], s[1]);
}
}, vh = (e, t) => {
let n;
const a = [];
for (; (n = e.exec(t)) !== null; )
a.push(n);
return a;
}, yh = Et("HTMLFormElement"), gh = (e) => e.toLowerCase().replace(
/[-_\s]([a-z\d])(\w*)/g,
function(n, a, r) {
return a.toUpperCase() + r;
}
), Ti = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), bh = Et("RegExp"), lu = (e, t) => {
const n = Object.getOwnPropertyDescriptors(e), a = {};
$a(n, (r, s) => {
let l;
(l = t(r, s, e)) !== !1 && (a[s] = l || r);
}), Object.defineProperties(e, a);
}, ph = (e) => {
lu(e, (t, n) => {
if (dt(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
return !1;
const a = e[n];
if (dt(a)) {
if (t.enumerable = !1, "writable" in t) {
t.writable = !1;
return;
}
t.set || (t.set = () => {
throw Error("Can not rewrite read-only method '" + n + "'");
});
}
});
}, Sh = (e, t) => {
const n = {}, a = (r) => {
r.forEach((s) => {
n[s] = !0;
});
};
return ra(e) ? a(e) : a(String(e).split(t)), n;
}, wh = () => {
}, _h = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
function kh(e) {
return !!(e && dt(e.append) && e[tu] === "FormData" && e[Nr]);
}
const Ch = (e) => {
const t = new Array(10), n = (a, r) => {
if (Ur(a)) {
if (t.indexOf(a) >= 0)
return;
if (!("toJSON" in a)) {
t[r] = a;
const s = ra(a) ? [] : {};
return $a(a, (l, i) => {
const o = n(l, r + 1);
!Pa(o) && (s[i] = o);
}), t[r] = void 0, s;
}
}
return a;
};
return n(e, 0);
}, Ph = Et("AsyncFunction"), xh = (e) => e && (Ur(e) || dt(e)) && dt(e.then) && dt(e.catch), iu = ((e, t) => e ? setImmediate : t ? ((n, a) => (Tn.addEventListener("message", ({ source: r, data: s }) => {
r === Tn && s === n && a.length && a.shift()();
}, !1), (r) => {
a.push(r), Tn.postMessage(n, "*");
}))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
typeof setImmediate == "function",
dt(Tn.postMessage)
), Ih = typeof queueMicrotask < "u" ? queueMicrotask.bind(Tn) : typeof process < "u" && process.nextTick || iu, Oh = (e) => e != null && dt(e[Nr]), C = {
isArray: ra,
isArrayBuffer: nu,
isBuffer: jf,
isFormData: eh,
isArrayBufferView: Wf,
isString: Gf,
isNumber: au,
isBoolean: Qf,
isObject: Ur,
isPlainObject: cr,
isReadableStream: nh,
isRequest: ah,
isResponse: rh,
isHeaders: sh,
isUndefined: Pa,
isDate: qf,
isFile: Kf,
isBlob: Jf,
isRegExp: bh,
isFunction: dt,
isStream: Xf,
isURLSearchParams: th,
isTypedArray: hh,
isFileList: Zf,
forEach: $a,
merge: Us,
extend: ih,
trim: lh,
stripBOM: oh,
inherits: uh,
toFlatObject: ch,
kindOf: Br,
kindOfTest: Et,
endsWith: dh,
toArray: fh,
forEachEntry: mh,
matchAll: vh,
isHTMLForm: yh,
hasOwnProperty: Ti,
hasOwnProp: Ti,
// an alias to avoid ESLint no-prototype-builtins detection
reduceDescriptors: lu,
freezeMethods: ph,
toObjectSet: Sh,
toCamelCase: gh,
noop: wh,
toFiniteNumber: _h,
findKey: ru,
global: Tn,
isContextDefined: su,
isSpecCompliantForm: kh,
toJSONObject: Ch,
isAsyncFn: Ph,
isThenable: xh,
setImmediate: iu,
asap: Ih,
isIterable: Oh
};
function ue(e, t, n, a, r) {
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), a && (this.request = a), r && (this.response = r, this.status = r.status ? r.status : null);
}
C.inherits(ue, 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: C.toJSONObject(this.config),
code: this.code,
status: this.status
};
}
});
const ou = ue.prototype, uu = {};
[
"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) => {
uu[e] = { value: e };
});
Object.defineProperties(ue, uu);
Object.defineProperty(ou, "isAxiosError", { value: !0 });
ue.from = (e, t, n, a, r, s) => {
const l = Object.create(ou);
return C.toFlatObject(e, l, function(o) {
return o !== Error.prototype;
}, (i) => i !== "isAxiosError"), ue.call(l, e.message, t, n, a, r), l.cause = e, l.name = e.name, s && Object.assign(l, s), l;
};
const Th = null;
function zs(e) {
return C.isPlainObject(e) || C.isArray(e);
}
function cu(e) {
return C.endsWith(e, "[]") ? e.slice(0, -2) : e;
}
function Vi(e, t, n) {
return e ? e.concat(t).map(function(r, s) {
return r = cu(r), !n && s ? "[" + r + "]" : r;
}).join(n ? "." : "") : t;
}
function Vh(e) {
return C.isArray(e) && !e.some(zs);
}
const Ah = C.toFlatObject(C, {}, null, function(t) {
return /^is[A-Z]/.test(t);
});
function zr(e, t, n) {
if (!C.isObject(e))
throw new TypeError("target must be an object");
t = t || new FormData(), n = C.toFlatObject(n, {
metaTokens: !0,
dots: !1,
indexes: !1
}, !1, function(y, h) {
return !C.isUndefined(h[y]);
});
const a = n.metaTokens, r = n.visitor || c, s = n.dots, l = n.indexes, o = (n.Blob || typeof Blob < "u" && Blob) && C.isSpecCompliantForm(t);
if (!C.isFunction(r))
throw new TypeError("visitor must be a function");
function u(m) {
if (m === null) return "";
if (C.isDate(m))
return m.toISOString();
if (!o && C.isBlob(m))
throw new ue("Blob is not supported. Use a Buffer instead.");
return C.isArrayBuffer(m) || C.isTypedArray(m) ? o && typeof Blob == "function" ? new Blob([m]) : Buffer.from(m) : m;
}
function c(m, y, h) {
let b = m;
if (m && !h && typeof m == "object") {
if (C.endsWith(y, "{}"))
y = a ? y : y.slice(0, -2), m = JSON.stringify(m);
else if (C.isArray(m) && Vh(m) || (C.isFileList(m) || C.endsWith(y, "[]")) && (b = C.toArray(m)))
return y = cu(y), b.forEach(function(P, O) {
!(C.isUndefined(P) || P === null) && t.append(
// eslint-disable-next-line no-nested-ternary
l === !0 ? Vi([y], O, s) : l === null ? y : y + "[]",
u(P)
);
}), !1;
}
return zs(m) ? !0 : (t.append(Vi(h, y, s), u(m)), !1);
}
const d = [], f = Object.assign(Ah, {
defaultVisitor: c,
convertValue: u,
isVisitable: zs
});
function v(m, y) {
if (!C.isUndefined(m)) {
if (d.indexOf(m) !== -1)
throw Error("Circular reference detected in " + y.join("."));
d.push(m), C.forEach(m, function(b, S) {
(!(C.isUndefined(b) || b === null) && r.call(
t,
b,
C.isString(S) ? S.trim() : S,
y,
f
)) === !0 && v(b, y ? y.concat(S) : [S]);
}), d.pop();
}
}
if (!C.isObject(e))
throw new TypeError("data must be an object");
return v(e), t;
}
function Ai(e) {
const t = {
"!": "%21",
"'": "%27",
"(": "%28",
")": "%29",
"~": "%7E",
"%20": "+",
"%00": "\0"
};
return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(a) {
return t[a];
});
}
function Il(e, t) {
this._pairs = [], e && zr(e, this, t);
}
const du = Il.prototype;
du.append = function(t, n) {
this._pairs.push([t, n]);
};
du.toString = function(t) {
const n = t ? function(a) {
return t.call(this, a, Ai);
} : Ai;
return this._pairs.map(function(r) {
return n(r[0]) + "=" + n(r[1]);
}, "").join("&");
};
function Eh(e) {
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
}
function fu(e, t, n) {
if (!t)
return e;
const a = n && n.encode || Eh;
C.isFunction(n) && (n = {
serialize: n
});
const r = n && n.serialize;
let s;
if (r ? s = r(t, n) : s = C.isURLSearchParams(t) ? t.toString() : new Il(t, n).toString(a), s) {
const l = e.indexOf("#");
l !== -1 && (e = e.slice(0, l)), e += (e.indexOf("?") === -1 ? "?" : "&") + s;
}
return e;
}
class Ei {
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, a) {
return this.handlers.push({
fulfilled: t,
rejected: n,
synchronous: a ? a.synchronous : !1,
runWhen: a ? a.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) {
C.forEach(this.handlers, function(a) {
a !== null && t(a);
});
}
}
const hu = {
silentJSONParsing: !0,
forcedJSONParsing: !0,
clarifyTimeoutError: !1
}, Dh = typeof URLSearchParams < "u" ? URLSearchParams : Il, Mh = typeof FormData < "u" ? FormData : null, Rh = typeof Blob < "u" ? Blob : null, Fh = {
isBrowser: !0,
classes: {
URLSearchParams: Dh,
FormData: Mh,
Blob: Rh
},
protocols: ["http", "https", "file", "blob", "url", "data"]
}, Ol = typeof window < "u" && typeof document < "u", Hs = typeof navigator == "object" && navigator || void 0, Lh = Ol && (!Hs || ["ReactNative", "NativeScript", "NS"].indexOf(Hs.product) < 0), Nh = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Bh = Ol && window.location.href || "http://localhost", $h = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
hasBrowserEnv: Ol,
hasStandardBrowserEnv: Lh,
hasStandardBrowserWebWorkerEnv: Nh,
navigator: Hs,
origin: Bh
}, Symbol.toStringTag, { value: "Module" })), Xe = {
...$h,
...Fh
};
function Uh(e, t) {
return zr(e, new Xe.classes.URLSearchParams(), Object.assign({
visitor: function(n, a, r, s) {
return Xe.isNode && C.isBuffer(n) ? (this.append(a, n.toString("base64")), !1) : s.defaultVisitor.apply(this, arguments);
}
}, t));
}
function zh(e) {
return C.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
}
function Hh(e) {
const t = {}, n = Object.keys(e);
let a;
const r = n.length;
let s;
for (a = 0; a < r; a++)
s = n[a], t[s] = e[s];
return t;
}
function mu(e) {
function t(n, a, r, s) {
let l = n[s++];
if (l === "__proto__") return !0;
const i = Number.isFinite(+l), o = s >= n.length;
return l = !l && C.isArray(r) ? r.length : l, o ? (C.hasOwnProp(r, l) ? r[l] = [r[l], a] : r[l] = a, !i) : ((!r[l] || !C.isObject(r[l])) && (r[l] = []), t(n, a, r[l], s) && C.isArray(r[l]) && (r[l] = Hh(r[l])), !i);
}
if (C.isFormData(e) && C.isFunction(e.entries)) {
const n = {};
return C.forEachEntry(e, (a, r) => {
t(zh(a), r, n, 0);
}), n;
}
return null;
}
function Yh(e, t, n) {
if (C.isString(e))
try {
return (t || JSON.parse)(e), C.trim(e);
} catch (a) {
if (a.name !== "SyntaxError")
throw a;
}
return (n || JSON.stringify)(e);
}
const Ua = {
transitional: hu,
adapter: ["xhr", "http", "fetch"],
transformRequest: [function(t, n) {
const a = n.getContentType() || "", r = a.indexOf("application/json") > -1, s = C.isObject(t);
if (s && C.isHTMLForm(t) && (t = new FormData(t)), C.isFormData(t))
return r ? JSON.stringify(mu(t)) : t;
if (C.isArrayBuffer(t) || C.isBuffer(t) || C.isStream(t) || C.isFile(t) || C.isBlob(t) || C.isReadableStream(t))
return t;
if (C.isArrayBufferView(t))
return t.buffer;
if (C.isURLSearchParams(t))
return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
let i;
if (s) {
if (a.indexOf("application/x-www-form-urlencoded") > -1)
return Uh(t, this.formSerializer).toString();
if ((i = C.isFileList(t)) || a.indexOf("multipart/form-data") > -1) {
const o = this.env && this.env.FormData;
return zr(
i ? { "files[]": t } : t,
o && new o(),
this.formSerializer
);
}
}
return s || r ? (n.setContentType("application/json", !1), Yh(t)) : t;
}],
transformResponse: [function(t) {
const n = this.transitional || Ua.transitional, a = n && n.forcedJSONParsing, r = this.responseType === "json";
if (C.isResponse(t) || C.isReadableStream(t))
return t;
if (t && C.isString(t) && (a && !this.responseType || r)) {
const l = !(n && n.silentJSONParsing) && r;
try {
return JSON.parse(t);
} catch (i) {
if (l)
throw i.name === "SyntaxError" ? ue.from(i, ue.ERR_BAD_RESPONSE, this, null, this.response) : i;
}
}
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: Xe.classes.FormData,
Blob: Xe.classes.Blob
},
validateStatus: function(t) {
return t >= 200 && t < 300;
},
headers: {
common: {
Accept: "application/json, text/plain, */*",
"Content-Type": void 0
}
}
};
C.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
Ua.headers[e] = {};
});
const jh = C.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"
]), Wh = (e) => {
const t = {};
let n, a, r;
return e && e.split(`
`).forEach(function(l) {
r = l.indexOf(":"), n = l.substring(0, r).trim().toLowerCase(), a = l.substring(r + 1).trim(), !(!n || t[n] && jh[n]) && (n === "set-cookie" ? t[n] ? t[n].push(a) : t[n] = [a] : t[n] = t[n] ? t[n] + ", " + a : a);
}), t;
}, Di = Symbol("internals");
function ma(e) {
return e && String(e).trim().toLowerCase();
}
function dr(e) {
return e === !1 || e == null ? e : C.isArray(e) ? e.map(dr) : String(e);
}
function Gh(e) {
const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
let a;
for (; a = n.exec(e); )
t[a[1]] = a[2];
return t;
}
const Qh = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
function ys(e, t, n, a, r) {
if (C.isFunction(a))
return a.call(this, t, n);
if (r && (t = n), !!C.isString(t)) {
if (C.isString(a))
return t.indexOf(a) !== -1;
if (C.isRegExp(a))
return a.test(t);
}
}
function qh(e) {
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, a) => n.toUpperCase() + a);
}
function Kh(e, t) {
const n = C.toCamelCase(" " + t);
["get", "set", "has"].forEach((a) => {
Object.defineProperty(e, a + n, {
value: function(r, s, l) {
return this[a].call(this, t, r, s, l);
},
configurable: !0
});
});
}
let ft = class {
constructor(t) {
t && this.set(t);
}
set(t, n, a) {
const r = this;
function s(i, o, u) {
const c = ma(o);
if (!c)
throw new Error("header name must be a non-empty string");
const d = C.findKey(r, c);
(!d || r[d] === void 0 || u === !0 || u === void 0 && r[d] !== !1) && (r[d || o] = dr(i));
}
const l = (i, o) => C.forEach(i, (u, c) => s(u, c, o));
if (C.isPlainObject(t) || t instanceof this.constructor)
l(t, n);
else if (C.isString(t) && (t = t.trim()) && !Qh(t))
l(Wh(t), n);
else if (C.isObject(t) && C.isIterable(t)) {
let i = {}, o, u;
for (const c of t) {
if (!C.isArray(c))
throw TypeError("Object iterator must return a key-value pair");
i[u = c[0]] = (o = i[u]) ? C.isArray(o) ? [...o, c[1]] : [o, c[1]] : c[1];
}
l(i, n);
} else
t != null && s(n, t, a);
return this;
}
get(t, n) {
if (t = ma(t), t) {
const a = C.findKey(this, t);
if (a) {
const r = this[a];
if (!n)
return r;
if (n === !0)
return Gh(r);
if (C.isFunction(n))
return n.call(this, r, a);
if (C.isRegExp(n))
return n.exec(r);
throw new TypeError("parser must be boolean|regexp|function");
}
}
}
has(t, n) {
if (t = ma(t), t) {
const a = C.findKey(this, t);
return !!(a && this[a] !== void 0 && (!n || ys(this, this[a], a, n)));
}
return !1;
}
delete(t, n) {
const a = this;
let r = !1;
function s(l) {
if (l = ma(l), l) {
const i = C.findKey(a, l);
i && (!n || ys(a, a[i], i, n)) && (delete a[i], r = !0);
}
}
return C.isArray(t) ? t.forEach(s) : s(t), r;
}
clear(t) {
const n = Object.keys(this);
let a = n.length, r = !1;
for (; a--; ) {
const s = n[a];
(!t || ys(this, this[s], s, t, !0)) && (delete this[s], r = !0);
}
return r;
}
normalize(t) {
const n = this, a = {};
return C.forEach(this, (r, s) => {
const l = C.findKey(a, s);
if (l) {
n[l] = dr(r), delete n[s];
return;
}
const i = t ? qh(s) : String(s).trim();
i !== s && delete n[s], n[i] = dr(r), a[i] = !0;
}), this;
}
concat(...t) {
return this.constructor.concat(this, ...t);
}
toJSON(t) {
const n = /* @__PURE__ */ Object.create(null);
return C.forEach(this, (a, r) => {
a != null && a !== !1 && (n[r] = t && C.isArray(a) ? a.join(", ") : a);
}), n;
}
[Symbol.iterator]() {
return Object.entries(this.toJSON())[Symbol.iterator]();
}
toString() {
return Object.entries(this.toJSON()).map(([t, n]) => t + ": " + n).join(`
`);
}
getSetCookie() {
return this.get("set-cookie") || [];
}
get [Symbol.toStringTag]() {
return "AxiosHeaders";
}
static from(t) {
return t instanceof this ? t : new this(t);
}
static concat(t, ...n) {
const a = new this(t);
return n.forEach((r) => a.set(r)), a;
}
static accessor(t) {
const a = (this[Di] = this[Di] = {
accessors: {}
}).accessors, r = this.prototype;
function s(l) {
const i = ma(l);
a[i] || (Kh(r, l), a[i] = !0);
}
return C.isArray(t) ? t.forEach(s) : s(t), this;
}
};
ft.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
C.reduceDescriptors(ft.prototype, ({ value: e }, t) => {
let n = t[0].toUpperCase() + t.slice(1);
return {
get: () => e,
set(a) {
this[n] = a;
}
};
});
C.freezeMethods(ft);
function gs(e, t) {
const n = this || Ua, a = t || n, r = ft.from(a.headers);
let s = a.data;
return C.forEach(e, function(i) {
s = i.call(n, s, r.normalize(), t ? t.status : void 0);
}), r.normalize(), s;
}
function vu(e) {
return !!(e && e.__CANCEL__);
}
function sa(e, t, n) {
ue.call(this, e ?? "canceled", ue.ERR_CANCELED, t, n), this.name = "CanceledError";
}
C.inherits(sa, ue, {
__CANCEL__: !0
});
function yu(e, t, n) {
const a = n.config.validateStatus;
!n.status || !a || a(n.status) ? e(n) : t(new ue(
"Request failed with status code " + n.status,
[ue.ERR_BAD_REQUEST, ue.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
n.config,
n.request,
n
));
}
function Jh(e) {
const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
return t && t[1] || "";
}
function Zh(e, t) {
e = e || 10;
const n = new Array(e), a = new Array(e);
let r = 0, s = 0, l;
return t = t !== void 0 ? t : 1e3, function(o) {
const u = Date.now(), c = a[s];
l || (l = u), n[r] = o, a[r] = u;
let d = s, f = 0;
for (; d !== r; )
f += n[d++], d = d % e;
if (r = (r + 1) % e, r === s && (s = (s + 1) % e), u - l < t)
return;
const v = c && u - c;
return v ? Math.round(f * 1e3 / v) : void 0;
};
}
function Xh(e, t) {
let n = 0, a = 1e3 / t, r, s;
const l = (u, c = Date.now()) => {
n = c, r = null, s && (clearTimeout(s), s = null), e.apply(null, u);
};
return [(...u) => {
const c = Date.now(), d = c - n;
d >= a ? l(u, c) : (r = u, s || (s = setTimeout(() => {
s = null, l(r);
}, a - d)));
}, () => r && l(r)];
}
const br = (e, t, n = 3) => {
let a = 0;
const r = Zh(50, 250);
return Xh((s) => {
const l = s.loaded, i = s.lengthComputable ? s.total : void 0, o = l - a, u = r(o), c = l <= i;
a = l;
const d = {
loaded: l,
total: i,
progress: i ? l / i : void 0,
bytes: o,
rate: u || void 0,
estimated: u && i && c ? (i - l) / u : void 0,
event: s,
lengthComputable: i != null,
[t ? "download" : "upload"]: !0
};
e(d);
}, n);
}, Mi = (e, t) => {
const n = e != null;
return [(a) => t[0]({
lengthComputable: n,
total: e,
loaded: a
}), t[1]];
}, Ri = (e) => (...t) => C.asap(() => e(...t)), em = Xe.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (n) => (n = new URL(n, Xe.origin), e.protocol === n.protocol && e.host === n.host && (t || e.port === n.port)))(
new URL(Xe.origin),
Xe.navigator && /(msie|trident)/i.test(Xe.navigator.userAgent)
) : () => !0, tm = Xe.hasStandardBrowserEnv ? (
// Standard browser envs support document.cookie
{
write(e, t, n, a, r, s) {
const l = [e + "=" + encodeURIComponent(t)];
C.isNumber(n) && l.push("expires=" + new Date(n).toGMTString()), C.isString(a) && l.push("path=" + a), C.isString(r) && l.push("domain=" + r), s === !0 && l.push("secure"), document.cookie = l.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 nm(e) {
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
}
function am(e, t) {
return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
}
function gu(e, t, n) {
let a = !nm(t);
return e && (a || n == !1) ? am(e, t) : t;
}
const Fi = (e) => e instanceof ft ? { ...e } : e;
function Rn(e, t) {
t = t || {};
const n = {};
function a(u, c, d, f) {
return C.isPlainObject(u) && C.isPlainObject(c) ? C.merge.call({ caseless: f }, u, c) : C.isPlainObject(c) ? C.merge({}, c) : C.isArray(c) ? c.slice() : c;
}
function r(u, c, d, f) {
if (C.isUndefined(c)) {
if (!C.isUndefined(u))
return a(void 0, u, d, f);
} else return a(u, c, d, f);
}
function s(u, c) {
if (!C.isUndefined(c))
return a(void 0, c);
}
function l(u, c) {
if (C.isUndefined(c)) {
if (!C.isUndefined(u))
return a(void 0, u);
} else return a(void 0, c);
}
function i(u, c, d) {
if (d in t)
return a(u, c);
if (d in e)
return a(void 0, u);
}
const o = {
url: s,
method: s,
data: s,
baseURL: l,
transformRequest: l,
transformResponse: l,
paramsSerializer: l,
timeout: l,
timeoutMessage: l,
withCredentials: l,
withXSRFToken: l,
adapter: l,
responseType: l,
xsrfCookieName: l,
xsrfHeaderName: l,
onUploadProgress: l,
onDownloadProgress: l,
decompress: l,
maxContentLength: l,
maxBodyLength: l,
beforeRedirect: l,
transport: l,
httpAgent: l,
httpsAgent: l,
cancelToken: l,
socketPath: l,
responseEncoding: l,
validateStatus: i,
headers: (u, c, d) => r(Fi(u), Fi(c), d, !0)
};
return C.forEach(Object.keys(Object.assign({}, e, t)), function(c) {
const d = o[c] || r, f = d(e[c], t[c], c);
C.isUndefined(f) && d !== i || (n[c] = f);
}), n;
}
const bu = (e) => {
const t = Rn({}, e);
let { data: n, withXSRFToken: a, xsrfHeaderName: r, xsrfCookieName: s, headers: l, auth: i } = t;
t.headers = l = ft.from(l), t.url = fu(gu(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), i && l.set(
"Authorization",
"Basic " + btoa((i.username || "") + ":" + (i.password ? unescape(encodeURIComponent(i.password)) : ""))
);
let o;
if (C.isFormData(n)) {
if (Xe.hasStandardBrowserEnv || Xe.hasStandardBrowserWebWorkerEnv)
l.setContentType(void 0);
else if ((o = l.getContentType()) !== !1) {
const [u, ...c] = o ? o.split(";").map((d) => d.trim()).filter(Boolean) : [];
l.setContentType([u || "multipart/form-data", ...c].join("; "));
}
}
if (Xe.hasStandardBrowserEnv && (a && C.isFunction(a) && (a = a(t)), a || a !== !1 && em(t.url))) {
const u = r && s && tm.read(s);
u && l.set(r, u);
}
return t;
}, rm = typeof XMLHttpRequest < "u", sm = rm && function(e) {
return new Promise(function(n, a) {
const r = bu(e);
let s = r.data;
const l = ft.from(r.headers).normalize();
let { responseType: i, onUploadProgress: o, onDownloadProgress: u } = r, c, d, f, v, m;
function y() {
v && v(), m && m(), r.cancelToken && r.cancelToken.unsubscribe(c), r.signal && r.signal.removeEventListener("abort", c);
}
let h = new XMLHttpRequest();
h.open(r.method.toUpperCase(), r.url, !0), h.timeout = r.timeout;
function b() {
if (!h)
return;
const P = ft.from(
"getAllResponseHeaders" in h && h.getAllResponseHeaders()
), k = {
data: !i || i === "text" || i === "json" ? h.responseText : h.response,
status: h.status,
statusText: h.statusText,
headers: P,
config: e,
request: h
};
yu(function(V) {
n(V), y();
}, function(V) {
a(V), y();
}, k), h = null;
}
"onloadend" in h ? h.onloadend = b : h.onreadystatechange = function() {
!h || h.readyState !== 4 || h.status === 0 && !(h.responseURL && h.responseURL.indexOf("file:") === 0) || setTimeout(b);
}, h.onabort = function() {
h && (a(new ue("Request aborted", ue.ECONNABORTED, e, h)), h = null);
}, h.onerror = function() {
a(new ue("Network Error", ue.ERR_NETWORK, e, h)), h = null;
}, h.ontimeout = function() {
let O = r.timeout ? "timeout of " + r.timeout + "ms exceeded" : "timeout exceeded";
const k = r.transitional || hu;
r.timeoutErrorMessage && (O = r.timeoutErrorMessage), a(new ue(
O,
k.clarifyTimeoutError ? ue.ETIMEDOUT : ue.ECONNABORTED,
e,
h
)), h = null;
}, s === void 0 && l.setContentType(null), "setRequestHeader" in h && C.forEach(l.toJSON(), function(O, k) {
h.setRequestHeader(k, O);
}), C.isUndefined(r.withCredentials) || (h.withCredentials = !!r.withCredentials), i && i !== "json" && (h.responseType = r.responseType), u && ([f, m] = br(u, !0), h.addEventListener("progress", f)), o && h.upload && ([d, v] = br(o), h.upload.addEventListener("progress", d), h.upload.addEventListener("loadend", v)), (r.cancelToken || r.signal) && (c = (P) => {
h && (a(!P || P.type ? new sa(null, e, h) : P), h.abort(), h = null);
}, r.cancelToken && r.cancelToken.subscribe(c), r.signal && (r.signal.aborted ? c() : r.signal.addEventListener("abort", c)));
const S = Jh(r.url);
if (S && Xe.protocols.indexOf(S) === -1) {
a(new ue("Unsupported protocol " + S + ":", ue.ERR_BAD_REQUEST, e));
return;
}
h.send(s || null);
});
}, lm = (e, t) => {
const { length: n } = e = e ? e.filter(Boolean) : [];
if (t || n) {
let a = new AbortController(), r;
const s = function(u) {
if (!r) {
r = !0, i();
const c = u instanceof Error ? u : this.reason;
a.abort(c instanceof ue ? c : new sa(c instanceof Error ? c.message : c));
}
};
let l = t && setTimeout(() => {
l = null, s(new ue(`timeout ${t} of ms exceeded`, ue.ETIMEDOUT));
}, t);
const i = () => {
e && (l && clearTimeout(l), l = null, e.forEach((u) => {
u.unsubscribe ? u.unsubscribe(s) : u.removeEventListener("abort", s);
}), e = null);
};
e.forEach((u) => u.addEventListener("abort", s));
const { signal: o } = a;
return o.unsubscribe = () => C.asap(i), o;
}
}, im = function* (e, t) {
let n = e.byteLength;
if (n < t) {
yield e;
return;
}
let a = 0, r;
for (; a < n; )
r = a + t, yield e.slice(a, r), a = r;
}, om = async function* (e, t) {
for await (const n of um(e))
yield* im(n, t);
}, um = async function* (e) {
if (e[Symbol.asyncIterator]) {
yield* e;
return;
}
const t = e.getReader();
try {
for (; ; ) {
const { done: n, value: a } = await t.read();
if (n)
break;
yield a;
}
} finally {
await t.cancel();
}
}, Li = (e, t, n, a) => {
const r = om(e, t);
let s = 0, l, i = (o) => {
l || (l = !0, a && a(o));
};
return new ReadableStream({
async pull(o) {
try {
const { done: u, value: c } = await r.next();
if (u) {
i(), o.close();
return;
}
let d = c.byteLength;
if (n) {
let f = s += d;
n(f);
}
o.enqueue(new Uint8Array(c));
} catch (u) {
throw i(u), u;
}
},
cancel(o) {
return i(o), r.return();
}
}, {
highWaterMark: 2
});
}, Hr = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", pu = Hr && typeof ReadableStream == "function", cm = Hr && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), Su = (e, ...t) => {
try {
return !!e(...t);
} catch {
return !1;
}
}, dm = pu && Su(() => {
let e = !1;
const t = new Request(Xe.origin, {
body: new ReadableStream(),
method: "POST",
get duplex() {
return e = !0, "half";
}
}).headers.has("Content-Type");
return e && !t;
}), Ni = 64 * 1024, Ys = pu && Su(() => C.isReadableStream(new Response("").body)), pr = {
stream: Ys && ((e) => e.body)
};
Hr && ((e) => {
["text", "arrayBuffer", "blob", "formData", "stream"].forEach((t) => {
!pr[t] && (pr[t] = C.isFunction(e[t]) ? (n) => n[t]() : (n, a) => {
throw new ue(`Response type '${t}' is not supported`, ue.ERR_NOT_SUPPORT, a);
});
});
})(new Response());
const fm = async (e) => {
if (e == null)
return 0;
if (C.isBlob(e))
return e.size;
if (C.isSpecCompliantForm(e))
return (await new Request(Xe.origin, {
method: "POST",
body: e
}).arrayBuffer()).byteLength;
if (C.isArrayBufferView(e) || C.isArrayBuffer(e))
return e.byteLength;
if (C.isURLSearchParams(e) && (e = e + ""), C.isString(e))
return (await cm(e)).byteLength;
}, hm = async (e, t) => {
const n = C.toFiniteNumber(e.getContentLength());
return n ?? fm(t);
}, mm = Hr && (async (e) => {
let {
url: t,
method: n,
data: a,
signal: r,
cancelToken: s,
timeout: l,
onDownloadProgress: i,
onUploadProgress: o,
responseType: u,
headers: c,
withCredentials: d = "same-origin",
fetchOptions: f
} = bu(e);
u = u ? (u + "").toLowerCase() : "text";
let v = lm([r, s && s.toAbortSignal()], l), m;
const y = v && v.unsubscribe && (() => {
v.unsubscribe();
});
let h;
try {
if (o && dm && n !== "get" && n !== "head" && (h = await hm(c, a)) !== 0) {
let k = new Request(t, {
method: "POST",
body: a,
duplex: "half"
}), E;
if (C.isFormData(a) && (E = k.headers.get("content-type")) && c.setContentType(E), k.body) {
const [V, w] = Mi(
h,
br(Ri(o))
);
a = Li(k.body, Ni, V, w);
}
}
C.isString(d) || (d = d ? "include" : "omit");
const b = "credentials" in Request.prototype;
m = new Request(t, {
...f,
signal: v,
method: n.toUpperCase(),
headers: c.normalize().toJSON(),
body: a,
duplex: "half",
credentials: b ? d : void 0
});
let S = await fetch(m);
const P = Ys && (u === "stream" || u === "response");
if (Ys && (i || P && y)) {
const k = {};
["status", "statusText", "headers"].forEach((T) => {
k[T] = S[T];
});
const E = C.toFiniteNumber(S.headers.get("content-length")), [V, w] = i && Mi(
E,
br(Ri(i), !0)
) || [];
S = new Response(
Li(S.body, Ni, V, () => {
w && w(), y && y();
}),
k
);
}
u = u || "text";
let O = await pr[C.findKey(pr, u) || "text"](S, e);
return !P && y && y(), await new Promise((k, E) => {
yu(k, E, {
data: O,
headers: ft.from(S.headers),
status: S.status,
statusText: S.statusText,
config: e,
request: m
});
});
} catch (b) {
throw y && y(), b && b.name === "TypeError" && /Load failed|fetch/i.test(b.message) ? Object.assign(
new ue("Network Error", ue.ERR_NETWORK, e, m),
{
cause: b.cause || b
}
) : ue.from(b, b && b.code, e, m);
}
}), js = {
http: Th,
xhr: sm,
fetch: mm
};
C.forEach(js, (e, t) => {
if (e) {
try {
Object.defineProperty(e, "name", { value: t });
} catch {
}
Object.defineProperty(e, "adapterName", { value: t });
}
});
const Bi = (e) => `- ${e}`, vm = (e) => C.isFunction(e) || e === null || e === !1, wu = {
getAdapter: (e) => {
e = C.isArray(e) ? e : [e];
const { length: t } = e;
let n, a;
const r = {};
for (let s = 0; s < t; s++) {
n = e[s];
let l;
if (a = n, !vm(n) && (a = js[(l = String(n)).toLowerCase()], a === void 0))
throw new ue(`Unknown adapter '${l}'`);
if (a)
break;
r[l || "#" + s] = a;
}
if (!a) {
const s = Object.entries(r).map(
([i, o]) => `adapter ${i} ` + (o === !1 ? "is not supported by the environment" : "is not available in the build")
);
let l = t ? s.length > 1 ? `since :
` + s.map(Bi).join(`
`) : " " + Bi(s[0]) : "as no adapter specified";
throw new ue(
"There is no suitable adapter to dispatch the request " + l,
"ERR_NOT_SUPPORT"
);
}
return a;
},
adapters: js
};
function bs(e) {
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
throw new sa(null, e);
}
function $i(e) {
return bs(e), e.headers = ft.from(e.headers), e.data = gs.call(
e,
e.transformRequest
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), wu.getAdapter(e.adapter || Ua.adapter)(e).then(function(a) {
return bs(e), a.data = gs.call(
e,
e.transformResponse,
a
), a.headers = ft.from(a.headers), a;
}, function(a) {
return vu(a) || (bs(e), a && a.response && (a.response.data = gs.call(
e,
e.transformResponse,
a.response
), a.response.headers = ft.from(a.response.headers))), Promise.reject(a);
});
}
const _u = "1.9.0", Yr = {};
["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
Yr[e] = function(a) {
return typeof a === e || "a" + (t < 1 ? "n " : " ") + e;
};
});
const Ui = {};
Yr.transitional = function(t, n, a) {
function r(s, l) {
return "[Axios v" + _u + "] Transitional option '" + s + "'" + l + (a ? ". " + a : "");
}
return (s, l, i) => {
if (t === !1)
throw new ue(
r(l, " has been removed" + (n ? " in " + n : "")),
ue.ERR_DEPRECATED
);
return n && !Ui[l] && (Ui[l] = !0, console.warn(
r(
l,
" has been deprecated since v" + n + " and will be removed in the near future"
)
)), t ? t(s, l, i) : !0;
};
};
Yr.spelling = function(t) {
return (n, a) => (console.warn(`${a} is likely a misspelling of ${t}`), !0);
};
function ym(e, t, n) {
if (typeof e != "object")
throw new ue("options must be an object", ue.ERR_BAD_OPTION_VALUE);
const a = Object.keys(e);
let r = a.length;
for (; r-- > 0; ) {
const s = a[r], l = t[s];
if (l) {
const i = e[s], o = i === void 0 || l(i, s, e);
if (o !== !0)
throw new ue("option " + s + " must be " + o, ue.ERR_BAD_OPTION_VALUE);
continue;
}
if (n !== !0)
throw new ue("Unknown option " + s, ue.ERR_BAD_OPTION);
}
}
const fr = {
assertOptions: ym,
validators: Yr
}, Lt = fr.validators;
let An = class {
constructor(t) {
this.defaults = t || {}, this.interceptors = {
request: new Ei(),
response: new Ei()
};
}
/**
* 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 (a) {
if (a instanceof Error) {
let r = {};
Error.captureStackTrace ? Error.captureStackTrace(r) : r = new Error();
const s = r.stack ? r.stack.replace(/^.+\n/, "") : "";
try {
a.stack ? s && !String(a.stack).endsWith(s.replace(/^.+\n.+\n/, "")) && (a.stack += `
` + s) : a.stack = s;
} catch {
}
}
throw a;
}
}
_request(t, n) {
typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = Rn(this.defaults, n);
const { transitional: a, paramsSerializer: r, headers: s } = n;
a !== void 0 && fr.assertOptions(a, {
silentJSONParsing: Lt.transitional(Lt.boolean),
forcedJSONParsing: Lt.transitional(Lt.boolean),
clarifyTimeoutError: Lt.transitional(Lt.boolean)
}, !1), r != null && (C.isFunction(r) ? n.paramsSerializer = {
serialize: r
} : fr.assertOptions(r, {
encode: Lt.function,
serialize: Lt.function
}, !0)), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), fr.assertOptions(n, {
baseUrl: Lt.spelling("baseURL"),
withXsrfToken: Lt.spelling("withXSRFToken")
}, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
let l = s && C.merge(
s.common,
s[n.method]
);
s && C.forEach(
["delete", "get", "head", "post", "put", "patch", "common"],
(m) => {
delete s[m];
}
), n.headers = ft.concat(l, s);
const i = [];
let o = !0;
this.interceptors.request.forEach(function(y) {
typeof y.runWhen == "function" && y.runWhen(n) === !1 || (o = o && y.synchronous, i.unshift(y.fulfilled, y.rejected));
});
const u = [];
this.interceptors.response.forEach(function(y) {
u.push(y.fulfilled, y.rejected);
});
let c, d = 0, f;
if (!o) {
const m = [$i.bind(this), void 0];
for (m.unshift.apply(m, i), m.push.apply(m, u), f = m.length, c = Promise.resolve(n); d < f; )
c = c.then(m[d++], m[d++]);
return c;
}
f = i.length;
let v = n;
for (d = 0; d < f; ) {
const m = i[d++], y = i[d++];
try {
v = m(v);
} catch (h) {
y.call(this, h);
break;
}
}
try {
c = $i.call(this, v);
} catch (m) {
return Promise.reject(m);
}
for (d = 0, f = u.length; d < f; )
c = c.then(u[d++], u[d++]);
return c;
}
getUri(t) {
t = Rn(this.defaults, t);
const n = gu(t.baseURL, t.url, t.allowAbsoluteUrls);
return fu(n, t.params, t.paramsSerializer);
}
};
C.forEach(["delete", "get", "head", "options"], function(t) {
An.prototype[t] = function(n, a) {
return this.request(Rn(a || {}, {
method: t,
url: n,
data: (a || {}).data
}));
};
});
C.forEach(["post", "put", "patch"], function(t) {
function n(a) {
return function(s, l, i) {
return this.request(Rn(i || {}, {
method: t,
headers: a ? {
"Content-Type": "multipart/form-data"
} : {},
url: s,
data: l
}));
};
}
An.prototype[t] = n(), An.prototype[t + "Form"] = n(!0);
});
let gm = class ku {
constructor(t) {
if (typeof t != "function")
throw new TypeError("executor must be a function.");
let n;
this.promise = new Promise(function(s) {
n = s;
});
const a = this;
this.promise.then((r) => {
if (!a._listeners) return;
let s = a._listeners.length;
for (; s-- > 0; )
a._listeners[s](r);
a._listeners = null;
}), this.promise.then = (r) => {
let s;
const l = new Promise((i) => {
a.subscribe(i), s = i;
}).then(r);
return l.cancel = function() {
a.unsubscribe(s);
}, l;
}, t(function(s, l, i) {
a.reason || (a.reason = new sa(s, l, i), n(a.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);
}
toAbortSignal() {
const t = new AbortController(), n = (a) => {
t.abort(a);
};
return this.subscribe(n), t.signal.unsubscribe = () => this.unsubscribe(n), t.signal;
}
/**
* Returns an object that contains a new `CancelToken` and a function that, when called,
* cancels the `CancelToken`.
*/
static source() {
let t;
return {
token: new ku(function(r) {
t = r;
}),
cancel: t
};
}
};
function bm(e) {
return function(n) {
return e.apply(null, n);
};
}
function pm(e) {
return C.isObject(e) && e.isAxiosError === !0;
}
const Ws = {
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(Ws).forEach(([e, t]) => {
Ws[t] = e;
});
function Cu(e) {
const t = new An(e), n = eu(An.prototype.request, t);
return C.extend(n, An.prototype, t, { allOwnKeys: !0 }), C.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(r) {
return Cu(Rn(e, r));
}, n;
}
const ve = Cu(Ua);
ve.Axios = An;
ve.CanceledError = sa;
ve.CancelToken = gm;
ve.isCancel = vu;
ve.VERSION = _u;
ve.toFormData = zr;
ve.AxiosError = ue;
ve.Cancel = ve.CanceledError;
ve.all = function(t) {
return Promise.all(t);
};
ve.spread = bm;
ve.isAxiosError = pm;
ve.mergeConfig = Rn;
ve.AxiosHeaders = ft;
ve.formToJSON = (e) => mu(C.isHTMLForm(e) ? new FormData(e) : e);
ve.getAdapter = wu.getAdapter;
ve.HttpStatusCode = Ws;
ve.default = ve;
const {
Axios: G0,
AxiosError: Q0,
CanceledError: q0,
isCancel: K0,
CancelToken: J0,
VERSION: Z0,
all: X0,
Cancel: ek,
isAxiosError: tk,
spread: nk,
toFormData: ak,
AxiosHeaders: rk,
HttpStatusCode: sk,
formToJSON: lk,
getAdapter: ik,
mergeConfig: ok
} = ve, et = "https://unh-pfem-services.ara.inrae.fr/forum-api".replace(/\/+$/, "");
class za {
constructor(t, n = et, a = ve) {
xe(this, "configuration");
this.basePath = n, this.axios = a, t && (this.configuration = t, this.basePath = t.basePath || this.basePath);
}
}
class Sm extends Error {
constructor(n, a) {
super(a);
xe(this, "name", "RequiredError");
this.field = n;
}
}
const at = "https://example.com", rt = function(e, t, n) {
if (n == null)
throw new Sm(t, `Required parameter ${t} was null or undefined when calling ${e}.`);
};
function Gs(e, t, n = "") {
typeof t == "object" ? Array.isArray(t) ? t.forEach((a) => Gs(e, a, n)) : Object.keys(t).forEach(
(a) => Gs(e, t[a], `${n}${n !== "" ? "." : ""}${a}`)
) : e.has(n) ? e.append(n, t) : e.set(n, t);
}
const st = function(e, ...t) {
const n = new URLSearchParams(e.search);
Gs(n, t), e.search = n.toString();
}, lt = function(e) {
return e.pathname + e.search + e.hash;
}, it = function(e, t, n, a) {
return (r = t, s = n) => {
const l = { ...e.options, url: (a?.basePath || s) + e.url };
return r.request(l);
};
}, wm = function(e) {
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chebiFuzzyQueryGet: async (t, n = {}) => {
rt("chebiFuzzyQueryGet", "query", t);
const a = "/chebi_fuzzy/{query}/".replace("{query}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chebiMeshIdChebiGet: async (t, n = {}) => {
rt("chebiMeshIdChebiGet", "idChebi", t);
const a = "/chebi_mesh/{idChebi}/".replace("{idChebi}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshChebiIdMeshGet: async (t, n = {}) => {
rt("meshChebiIdMeshGet", "idMesh", t);
const a = "/mesh_chebi/{idMesh}/".replace("{idMesh}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
}
};
}, ps = function(e) {
const t = wm(e);
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chebiFuzzyQueryGet(n, a) {
const r = await t.chebiFuzzyQueryGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chebiMeshIdChebiGet(n, a) {
const r = await t.chebiMeshIdChebiGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshChebiIdMeshGet(n, a) {
const r = await t.meshChebiIdMeshGet(n, a);
return it(r, ve, et, e);
}
};
};
class Pu extends za {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChebiApi
*/
chebiFuzzyQueryGet(t, n) {
return ps(this.configuration).chebiFuzzyQueryGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChebiApi
*/
chebiMeshIdChebiGet(t, n) {
return ps(this.configuration).chebiMeshIdChebiGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChebiApi
*/
meshChebiIdMeshGet(t, n) {
return ps(this.configuration).meshChebiIdMeshGet(t, n).then((a) => a(this.axios, this.basePath));
}
}
const _m = function(e) {
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chemontFuzzyQueryGet: async (t, n = {}) => {
rt("chemontFuzzyQueryGet", "query", t);
const a = "/chemont_fuzzy/{query}/".replace("{query}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chemontMeshIdChemontGet: async (t, n = {}) => {
rt("chemontMeshIdChemontGet", "idChemont", t);
const a = "/chemont_mesh/{idChemont}/".replace("{idChemont}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshChemontIdMeshGet: async (t, n = {}) => {
rt("meshChemontIdMeshGet", "idMesh", t);
const a = "/mesh_chemont/{idMesh}/".replace("{idMesh}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
}
};
}, Ss = function(e) {
const t = _m(e);
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chemontFuzzyQueryGet(n, a) {
const r = await t.chemontFuzzyQueryGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chemontMeshIdChemontGet(n, a) {
const r = await t.chemontMeshIdChemontGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshChemontIdMeshGet(n, a) {
const r = await t.meshChemontIdMeshGet(n, a);
return it(r, ve, et, e);
}
};
};
class xu extends za {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChemontApi
*/
chemontFuzzyQueryGet(t, n) {
return Ss(this.configuration).chemontFuzzyQueryGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChemontApi
*/
chemontMeshIdChemontGet(t, n) {
return Ss(this.configuration).chemontMeshIdChemontGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ChemontApi
*/
meshChemontIdMeshGet(t, n) {
return Ss(this.configuration).meshChemontIdMeshGet(t, n).then((a) => a(this.axios, this.basePath));
}
}
const km = function(e) {
return {
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chebiLabelIdChebiGet: async (t, n = {}) => {
rt("chebiLabelIdChebiGet", "idChebi", t);
const a = "/chebi_label/{idChebi}/".replace("{idChebi}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
chemontLabelIdChemontGet: async (t, n = {}) => {
rt("chemontLabelIdChemontGet", "idChemont", t);
const a = "/chemont_label/{idChemont}/".replace("{idChemont}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshLabelIdMeshGet: async (t, n = {}) => {
rt("meshLabelIdMeshGet", "idMesh", t);
const a = "/mesh_label/{idMesh}/".replace("{idMesh}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshTreeIdMeshGet: async (t, n = {}) => {
rt("meshTreeIdMeshGet", "idMesh", t);
const a = "/mesh_tree/{idMesh}/".replace("{idMesh}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
pubchemLabelIdPubchemGet: async (t, n = {}) => {
rt("pubchemLabelIdPubchemGet", "idPubchem", t);
const a = "/pubchem_label/{idPubchem}/".replace("{idPubchem}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
}
};
}, va = function(e) {
const t = km(e);
return {
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chebiLabelIdChebiGet(n, a) {
const r = await t.chebiLabelIdChebiGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async chemontLabelIdChemontGet(n, a) {
const r = await t.chemontLabelIdChemontGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshLabelIdMeshGet(n, a) {
const r = await t.meshLabelIdMeshGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshTreeIdMeshGet(n, a) {
const r = await t.meshTreeIdMeshGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async pubchemLabelIdPubchemGet(n, a) {
const r = await t.pubchemLabelIdPubchemGet(n, a);
return it(r, ve, et, e);
}
};
};
class Cm extends za {
/**
*
* @param {string} idChebi idChebi
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LabelsApi
*/
chebiLabelIdChebiGet(t, n) {
return va(this.configuration).chebiLabelIdChebiGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idChemont idChemont
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LabelsApi
*/
chemontLabelIdChemontGet(t, n) {
return va(this.configuration).chemontLabelIdChemontGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LabelsApi
*/
meshLabelIdMeshGet(t, n) {
return va(this.configuration).meshLabelIdMeshGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LabelsApi
*/
meshTreeIdMeshGet(t, n) {
return va(this.configuration).meshTreeIdMeshGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LabelsApi
*/
pubchemLabelIdPubchemGet(t, n) {
return va(this.configuration).pubchemLabelIdPubchemGet(t, n).then((a) => a(this.axios, this.basePath));
}
}
const Pm = function(e) {
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshFuzzyQueryGet: async (t, n = {}) => {
rt("meshFuzzyQueryGet", "query", t);
const a = "/mesh_fuzzy/{query}/".replace("{query}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
}
};
}, xm = function(e) {
const t = Pm(e);
return {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshFuzzyQueryGet(n, a) {
const r = await t.meshFuzzyQueryGet(n, a);
return it(r, ve, et, e);
}
};
};
class Im extends za {
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof MeshApi
*/
meshFuzzyQueryGet(t, n) {
return xm(this.configuration).meshFuzzyQueryGet(t, n).then((a) => a(this.axios, this.basePath));
}
}
const Om = function(e) {
return {
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
meshPubchemIdMeshGet: async (t, n = {}) => {
rt("meshPubchemIdMeshGet", "idMesh", t);
const a = "/mesh_pubchem/{idMesh}/".replace("{idMesh}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
pubchemFuzzyQueryGet: async (t, n = {}) => {
rt("pubchemFuzzyQueryGet", "query", t);
const a = "/pubchem_fuzzy/{query}/".replace("{query}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
},
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
pubchemMeshIdPubchemGet: async (t, n = {}) => {
rt("pubchemMeshIdPubchemGet", "idPubchem", t);
const a = "/pubchem_mesh/{idPubchem}/".replace("{idPubchem}", encodeURIComponent(String(t))), r = new URL(a, at);
let s;
e && (s = e.baseOptions);
const l = { method: "GET", ...s, ...n }, i = {};
st(r, {});
let u = s && s.headers ? s.headers : {};
return l.headers = { ...i, ...u, ...n.headers }, {
url: lt(r),
options: l
};
}
};
}, ws = function(e) {
const t = Om(e);
return {
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async meshPubchemIdMeshGet(n, a) {
const r = await t.meshPubchemIdMeshGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async pubchemFuzzyQueryGet(n, a) {
const r = await t.pubchemFuzzyQueryGet(n, a);
return it(r, ve, et, e);
},
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async pubchemMeshIdPubchemGet(n, a) {
const r = await t.pubchemMeshIdPubchemGet(n, a);
return it(r, ve, et, e);
}
};
};
class Qs extends za {
/**
*
* @param {string} idMesh idMesh
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof PubchemApi
*/
meshPubchemIdMeshGet(t, n) {
return ws(this.configuration).meshPubchemIdMeshGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {string} query the user\'s query
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof PubchemApi
*/
pubchemFuzzyQueryGet(t, n) {
return ws(this.configuration).pubchemFuzzyQueryGet(t, n).then((a) => a(this.axios, this.basePath));
}
/**
*
* @param {number} idPubchem idPubchem
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof PubchemApi
*/
pubchemMeshIdPubchemGet(t, n) {
return ws(this.configuration).pubchemMeshIdPubchemGet(t, n).then((a) => a(this.axios, this.basePath));
}
}
class Tm {
constructor(t, n, a) {
xe(this, "id");
xe(this, "name");
xe(this, "score");
this._id = t, this._name = n, this._score = a, this.id = t, this.name = n, this.score = a;
}
}
const Vm = Rr({
name: "MthForumFormFinder",
emits: ["search-query"],
setup() {
return {
// from XXX to YYY
queryType: R(ze.comp_to_mesh),
// show / hide advanced options
switchShowAdvancedSetting: R(!1),
// advanced options value
searchType: R(me.pubchem_id),
// search query value
searchQueryItem: R(null),
// new FuzzyItem("", "", 0)
// -- init dynamic data
labelTarget: R(
"MeSH biomedicals concepts"
/* CPD_TO_MESH */
),
labelSource: R(
"PubChem CID"
/* PUBCHEM_CID_TO_MESH */
),
// -- init autocomplet
searchQueryItems: R([]),
searchQueryLoading: R(!1),
searchQueryNoData: R(
"enter at least 5 letters..."
/* DEFAULT */
),
// -- init fuzzy matching APIs config
fuzzyMatchingKeywordMinLength: R(5),
searchQueryItemText: R(""),
searchQueryItemTextCache: R(""),
searchQueryItemsVisible: R(!1),
// -- init fuzzy matching APIs
pubchemAPI: R(new Qs()),
chebiApi: R(new Pu()),
chemontApi: R(new xu()),
meshApi: R(new Im()),
abortController: R(new AbortController())
};
},
mounted() {
this.loadParamFromHash(), this.launchQuery();
},
methods: {
/**
* Method use to reload parameters from the URL hash
* (allow users to share results using a copy/pasted URL)
*/
loadParamFromHash() {
const e = Pl();
if (e.get("searchQueryName") && this.searchQueryItem != null) {
const n = e.get("searchQueryName");
this.searchQueryItem = t(this.searchQueryItem), this.searchQueryItem.name = n.replaceAll("%20", " ");
}
if (e.get("searchQueryId") && this.searchQueryItem != null) {
const n = e.get("searchQueryId");
this.searchQueryItem = t(this.searchQueryItem), this.searchQueryItem.id = n;
}
e.get("queryType") && (this.queryType = ze[e.get("queryType")]), e.get("searchType") && (this.searchType = me[e.get("searchType")], this.switchShowAdvancedSetting = !0), console.log(" this.searchQueryItem", this.searchQueryItem);
function t(n) {
return n === null && (n = {}), n;
}
},
/**
* Launch a query (submit button)
* - save the query in URL (as hash parameters)
* - build the EndpointSearchQuery object
* - emit this object to the parent component
*/
launchQuery() {
if (this.searchQueryItem?.id === null || //
this.searchQueryItem?.id?.trim() === "")
return;
On("queryType", this.queryType), On("searchType", this.searchType), On("searchQueryName", this.searchQueryItem?.name ?? ""), On("searchQueryId", this.searchQueryItem?.id ?? "");
const e = new Xo();
e.searchEntityType = ze[this.queryType], e.searchSelectorType = me[this.searchType], e.searchEntityQuery = this.searchQueryItem?.id ?? "", e.searchEntityQuery !== "" && this.$emit("search-query", e);
},
/**
* Launch an example with pres-defined parameters
* @param queryType the query type (cpd to mesh / mesh to cpd)
* @param searchType the search type (pubchem cid / chebi id / ...)
* @param searchQueryName the queried item NAME
* @param searchQueryId the queried item Identifier
*/
launchExample(e, t, n, a) {
this.searchQueryItemText = "", this.switchShowAdvancedSetting = !0, this.queryType = ze[e], this.searchType = me[t], this.searchQueryItem = {}, this.searchQueryItem.name = n, this.searchQueryItem.id = a, this.triggerFormChange(), this.launchQuery();
},
/**
* Method called if a change occured in the form
*/
triggerFormChange() {
if (this.queryType === ze.comp_to_mesh)
switch (this.labelTarget = "MeSH biomedicals concepts", this.searchType) {
case me.pubchem_id:
default:
this.labelSource = "PubChem CID";
break;
case me.chebi_id:
this.labelSource = "ChEBI ID";
break;
case me.chemont_id:
this.labelSource = "ChemOnt ID";
break;
}
else if (this.queryType === ze.mesh_to_comp)
switch (this.labelSource = "MeSH biomedical concept", this.searchType) {
case me.pubchem_id:
default:
this.labelTarget = "PubChem CIDs";
break;
case me.chebi_id:
this.labelTarget = "ChEBI IDs";
break;
case me.chemont_id:
this.labelTarget = "ChemOnt CIDs";
break;
}
},
triggerSearchQueryUpdate(e) {
this.searchQueryLoading && this.abortController.abort(), this.abortController = new AbortController();
const t = { signal: this.abortController.signal };
if (this.searchQueryItemText = e, this.searchQueryLoading = !1, this.searchQueryItems = [], this.searchQueryNoData = "enter at least 5 letters...", e && //
e.length >= this.fuzzyMatchingKeywordMinLength) {
this.searchQueryLoading = !0, this.searchQueryNoData = "loading...";
const r = e.toLowerCase().replace(/\s/g, "");
this.queryType === ze.comp_to_mesh && this.searchType === me.pubchem_id ? this.pubchemAPI.pubchemFuzzyQueryGet(r, t).then((s) => {
this.searchQueryLoading = !1, this.searchQueryNoData = "sorry, no matched results.", this.searchQueryItems = n(s.data, "CID");
}).catch((s) => {
console.error("pubchemFuzzyQueryGet::error ⇒", s);
}) : this.queryType === ze.comp_to_mesh && this.searchType === me.chebi_id ? this.chebiApi.chebiFuzzyQueryGet(r, t).then((s) => {
this.searchQueryLoading = !1, this.searchQueryNoData = "sorry, no matched results.", this.searchQueryItems = n(s.data, "CHEBI");
}).catch((s) => {
console.error("chebiFuzzyQueryGet::error ⇒", s);
}) : this.queryType === ze.comp_to_mesh && this.searchType === me.chemont_id ? this.chemontApi.chemontFuzzyQueryGet(r, t).then((s) => {
this.searchQueryLoading = !1, this.searchQueryNoData = "sorry, no matched results.", this.searchQueryItems = n(s.data, "CHEMONT");
}).catch((s) => {
console.error("chemontFuzzyQueryGet::error ⇒", s);
}) : this.queryType === ze.mesh_to_comp ? this.meshApi.meshFuzzyQueryGet(r, t).then((s) => {
this.searchQueryLoading = !1, this.searchQueryNoData = "sorry, no matched results.", this.searchQueryItems = n(s.data, "MESH");
}).catch((s) => {
console.error("meshFuzzyQueryGet::error ⇒", s);
}) : console.error("INCONSISTENT FORM FINDER");
}
function n(r, s) {
return r.sort(a).map(
//
(u) => new Tm(`${u.item[s]}`, `${u.item.name}`, u.score)
//
).filter((u) => u.name.toLowerCase().includes(e.toLocaleLowerCase()));
}
function a(r, s) {
return r.score < s.score ? -1 : r.score > s.score ? 1 : 0;
}
},
triggerSearchMenu(e) {
this.searchQueryItemsVisible = !1, e ? (this.searchQueryItemsVisible = !0, this.searchQueryItemText = this.searchQueryItemTextCache) : (this.searchQueryLoading = !1, this.searchQueryItemTextCache = this.searchQueryItemText, this.searchQueryItemText = "", this.launchQuery());
}
}
}), Tl = (e, t) => {
const n = e.__vccOpts || e;
for (const [a, r] of t)
n[a] = r;
return n;
}, Be = typeof window < "u", Vl = Be && "IntersectionObserver" in window;
function zi(e, t, n) {
Am(e, t), t.set(e, n);
}
function Am(e, t) {
if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object");
}
function Hi(e, t, n) {
return e.set(Iu(e, t), n), n;
}
function qt(e, t) {
return e.get(Iu(e, t));
}
function Iu(e, t, n) {
if (typeof e == "function" ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
throw new TypeError("Private element is not present on this object");
}
function Ou(e, t, n) {
const a = t.length - 1;
if (a < 0) return e === void 0 ? n : e;
for (let r = 0; r < a; r++) {
if (e == null)
return n;
e = e[t[r]];
}
return e == null || e[t[a]] === void 0 ? n : e[t[a]];
}
function gt(e, t) {
if (e === t) return !0;
if (e instanceof Date && t instanceof Date && e.getTime() !== t.getTime() || e !== Object(e) || t !== Object(t))
return !1;
const n = Object.keys(e);
return n.length !== Object.keys(t).length ? !1 : n.every((a) => gt(e[a], t[a]));
}
function xa(e, t, n) {
return e == null || !t || typeof t != "string" ? n : e[t] !== void 0 ? e[t] : (t = t.replace(/\[(\w+)\]/g, ".$1"), t = t.replace(/^\./, ""), Ou(e, t.split("."), n));
}
function ot(e, t, n) {
if (t === !0) return e === void 0 ? n : e;
if (t == null || typeof t == "boolean") return n;
if (e !== Object(e)) {
if (typeof t != "function") return n;
const r = t(e, n);
return typeof r > "u" ? n : r;
}
if (typeof t == "string") return xa(e, t, n);
if (Array.isArray(t)) return Ou(e, t, n);
if (typeof t != "function") return n;
const a = t(e, n);
return typeof a > "u" ? n : a;
}
function nr(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
return Array.from({
length: e
}, (n, a) => t + a);
}
function te(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "px";
if (e == null || e === "")
return;
const n = Number(e);
return isNaN(n) ? String(e) : isFinite(n) ? `${n}${t}` : void 0;
}
function qs(e) {
return e !== null && typeof e == "object" && !Array.isArray(e);
}
function Yi(e) {
let t;
return e !== null && typeof e == "object" && ((t = Object.getPrototypeOf(e)) === Object.prototype || t === null);
}
function Tu(e) {
if (e && "$el" in e) {
const t = e.$el;
return t?.nodeType === Node.TEXT_NODE ? t.nextElementSibling : t;
}
return e;
}
const ji = Object.freeze({
enter: 13,
tab: 9,
delete: 46,
esc: 27,
space: 32,
up: 38,
down: 40,
left: 37,
right: 39,
end: 35,
home: 36,
del: 46,
backspace: 8,
insert: 45,
pageup: 33,
pagedown: 34,
shift: 16
}), Wi = Object.freeze({
enter: "Enter",
tab: "Tab",
delete: "Delete",
esc: "Escape",
space: "Space",
up: "ArrowUp",
down: "ArrowDown",
left: "ArrowLeft",
right: "ArrowRight",
end: "End",
home: "Home",
del: "Delete",
backspace: "Backspace",
insert: "Insert",
pageup: "PageUp",
pagedown: "PageDown",
shift: "Shift"
});
function _s(e, t) {
return t.every((n) => e.hasOwnProperty(n));
}
function jr(e, t) {
const n = {};
for (const a of t)
Object.prototype.hasOwnProperty.call(e, a) && (n[a] = e[a]);
return n;
}
function Gi(e, t, n) {
const a = /* @__PURE__ */ Object.create(null), r = /* @__PURE__ */ Object.create(null);
for (const s in e)
t.some((l) => l instanceof RegExp ? l.test(s) : l === s) ? a[s] = e[s] : r[s] = e[s];
return [a, r];
}
function kn(e, t) {
const n = {
...e
};
return t.forEach((a) => delete n[a]), n;
}
const Vu = /^on[^a-z]/, Al = (e) => Vu.test(e), Em = ["onAfterscriptexecute", "onAnimationcancel", "onAnimationend", "onAnimationiteration", "onAnimationstart", "onAuxclick", "onBeforeinput", "onBeforescriptexecute", "onChange", "onClick", "onCompositionend", "onCompositionstart", "onCompositionupdate", "onContextmenu", "onCopy", "onCut", "onDblclick", "onFocusin", "onFocusout", "onFullscreenchange", "onFullscreenerror", "onGesturechange", "onGestureend", "onGesturestart", "onGotpointercapture", "onInput", "onKeydown", "onKeypress", "onKeyup", "onLostpointercapture", "onMousedown", "onMousemove", "onMouseout", "onMouseover", "onMouseup", "onMousewheel", "onPaste", "onPointercancel", "onPointerdown", "onPointerenter", "onPointerleave", "onPointermove", "onPointerout", "onPointerover", "onPointerup", "onReset", "onSelect", "onSubmit", "onTouchcancel", "onTouchend", "onTouchmove", "onTouchstart", "onTransitioncancel", "onTransitionend", "onTransitionrun", "onTransitionstart", "onWheel"];
function Wr(e) {
const [t, n] = Gi(e, [Vu]), a = kn(t, Em), [r, s] = Gi(n, ["class", "style", "id", /^data-/]);
return Object.assign(r, t), Object.assign(s, a), [r, s];
}
function Ke(e) {
return e == null ? [] : Array.isArray(e) ? e : [e];
}
function Dm(e, t) {
let n = 0;
const a = function() {
for (var r = arguments.length, s = new Array(r), l = 0; l < r; l++)
s[l] = arguments[l];
clearTimeout(n), n = setTimeout(() => e(...s), _t(t));
};
return a.clear = () => {
clearTimeout(n);
}, a.immediate = e, a;
}
function bt(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0, n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : 1;
return Math.max(t, Math.min(n, e));
}
function Qi(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : "0";
return e + n.repeat(Math.max(0, t - e.length));
}
function Mm(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 1;
const n = [];
let a = 0;
for (; a < e.length; )
n.push(e.substr(a, t)), a += t;
return n;
}
function Xt() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, n = arguments.length > 2 ? arguments[2] : void 0;
const a = {};
for (const r in e)
a[r] = e[r];
for (const r in t) {
const s = e[r], l = t[r];
if (Yi(s) && Yi(l)) {
a[r] = Xt(s, l, n);
continue;
}
if (n && Array.isArray(s) && Array.isArray(l)) {
a[r] = n(s, l);
continue;
}
a[r] = l;
}
return a;
}
function Au(e) {
return e.map((t) => t.type === pe ? Au(t.children) : t).flat();
}
function En() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "";
if (En.cache.has(e)) return En.cache.get(e);
const t = e.replace(/[^a-z]/gi, "-").replace(/\B([A-Z])/g, "-$1").toLowerCase();
return En.cache.set(e, t), t;
}
En.cache = /* @__PURE__ */ new Map();
function Sa(e, t) {
if (!t || typeof t != "object") return [];
if (Array.isArray(t))
return t.map((n) => Sa(e, n)).flat(1);
if (t.suspense)
return Sa(e, t.ssContent);
if (Array.isArray(t.children))
return t.children.map((n) => Sa(e, n)).flat(1);
if (t.component) {
if (Object.getOwnPropertySymbols(t.component.provides).includes(e))
return [t.component];
if (t.component.subTree)
return Sa(e, t.component.subTree).flat(1);
}
return [];
}
var Hn = /* @__PURE__ */ new WeakMap(), xn = /* @__PURE__ */ new WeakMap();
class Rm {
constructor(t) {
zi(this, Hn, []), zi(this, xn, 0), this.size = t;
}
get isFull() {
return qt(Hn, this).length === this.size;
}
push(t) {
qt(Hn, this)[qt(xn, this)] = t, Hi(xn, this, (qt(xn, this) + 1) % this.size);
}
values() {
return qt(Hn, this).slice(qt(xn, this)).concat(qt(Hn, this).slice(0, qt(xn, this)));
}
clear() {
qt(Hn, this).length = 0, Hi(xn, this, 0);
}
}
function El(e) {
const t = Zn({});
Ot(() => {
const a = e();
for (const r in a)
t[r] = a[r];
}, {
flush: "sync"
});
const n = {};
for (const a in t)
n[a] = I(() => t[a]);
return n;
}
function Sr(e, t) {
return e.includes(t);
}
function Eu(e) {
return e[2].toLowerCase() + e.slice(3);
}
const Je = () => [Function, Array];
function qi(e, t) {
return t = "on" + na(t), !!(e[t] || e[`${t}Once`] || e[`${t}Capture`] || e[`${t}OnceCapture`] || e[`${t}CaptureOnce`]);
}
function Du(e) {
for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), a = 1; a < t; a++)
n[a - 1] = arguments[a];
if (Array.isArray(e))
for (const r of e)
r(...n);
else typeof e == "function" && e(...n);
}
function Ia(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
const n = ["button", "[href]", 'input:not([type="hidden"])', "select", "textarea", "[tabindex]"].map((a) => `${a}${t ? ':not([tabindex="-1"])' : ""}:not([disabled])`).join(", ");
return [...e.querySelectorAll(n)];
}
function Mu(e, t, n) {
let a, r = e.indexOf(document.activeElement);
const s = t === "next" ? 1 : -1;
do
r += s, a = e[r];
while ((!a || a.offsetParent == null || !(n?.(a) ?? !0)) && r < e.length && r >= 0);
return a;
}
function ka(e, t) {
const n = Ia(e);
if (t == null)
(e === document.activeElement || !e.contains(document.activeElement)) && n[0]?.focus();
else if (t === "first")
n[0]?.focus();
else if (t === "last")
n.at(-1)?.focus();
else if (typeof t == "number")
n[t]?.focus();
else {
const a = Mu(n, t);
a ? a.focus() : ka(e, t === "next" ? "first" : "last");
}
}
function ar(e) {
return e == null || typeof e == "string" && e.trim() === "";
}
function Fm() {
}
function Xn(e, t) {
if (!(Be && typeof CSS < "u" && typeof CSS.supports < "u" && CSS.supports(`selector(${t})`))) return null;
try {
return !!e && e.matches(t);
} catch {
return null;
}
}
function Dl(e) {
return e.some((t) => Af(t) ? t.type === Ef ? !1 : t.type !== pe || Dl(t.children) : !0) ? e : null;
}
function Lm(e, t) {
if (!Be || e === 0)
return t(), () => {
};
const n = window.setTimeout(t, e);
return () => window.clearTimeout(n);
}
function Nm(e, t) {
const n = e.clientX, a = e.clientY, r = t.getBoundingClientRect(), s = r.left, l = r.top, i = r.right, o = r.bottom;
return n >= s && n <= i && a >= l && a <= o;
}
function Ks() {
const e = ne(), t = (n) => {
e.value = n;
};
return Object.defineProperty(t, "value", {
enumerable: !0,
get: () => e.value,
set: (n) => e.value = n
}), Object.defineProperty(t, "el", {
enumerable: !0,
get: () => Tu(e.value)
}), t;
}
function wr(e) {
const t = e.key.length === 1, n = !e.ctrlKey && !e.metaKey && !e.altKey;
return t && n;
}
function Ru(e) {
return typeof e == "string" || typeof e == "number" || typeof e == "boolean" || typeof e == "bigint";
}
function Ue(e, t) {
const n = Df();
if (!n)
throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);
return n;
}
function jt() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "composables";
const t = Ue(e).type;
return En(t?.aliasName || t?.name);
}
function Bm(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : Ue("injectSelf");
const {
provides: n
} = t;
if (n && e in n)
return n[e];
}
const _r = Symbol.for("vuetify:defaults");
function Ml() {
const e = De(_r);
if (!e) throw new Error("[Vuetify] Could not find defaults instance");
return e;
}
function zt(e, t) {
const n = Ml(), a = R(e), r = _(() => {
if (_t(t?.disabled)) return n.value;
const l = _t(t?.scoped), i = _t(t?.reset), o = _t(t?.root);
if (a.value == null && !(l || i || o)) return n.value;
let u = Xt(a.value, {
prev: n.value
});
if (l) return u;
if (i || o) {
const c = Number(i || 1 / 0);
for (let d = 0; d <= c && !(!u || !("prev" in u)); d++)
u = u.prev;
return u && typeof o == "string" && o in u && (u = Xt(Xt(u, {
prev: u
}), u[o])), u;
}
return u.prev ? Xt(u.prev, u) : u;
});
return We(_r, r), r;
}
function $m(e, t) {
return e.props && (typeof e.props[t] < "u" || typeof e.props[En(t)] < "u");
}
function Um() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, t = arguments.length > 1 ? arguments[1] : void 0, n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Ml();
const a = Ue("useDefaults");
if (t = t ?? a.type.name ?? a.type.__name, !t)
throw new Error("[Vuetify] Could not determine component name");
const r = _(() => n.value?.[e._as ?? t]), s = new Proxy(e, {
get(o, u) {
const c = Reflect.get(o, u);
if (u === "class" || u === "style")
return [r.value?.[u], c].filter((v) => v != null);
if ($m(a.vnode, u)) return c;
const d = r.value?.[u];
if (d !== void 0) return d;
const f = n.value?.global?.[u];
return f !== void 0 ? f : c;
}
}), l = ne();
Ot(() => {
if (r.value) {
const o = Object.entries(r.value).filter((u) => {
let [c] = u;
return c.startsWith(c[0].toUpperCase());
});
l.value = o.length ? Object.fromEntries(o) : void 0;
} else
l.value = void 0;
});
function i() {
const o = Bm(_r, a);
We(_r, _(() => l.value ? Xt(o?.value ?? {}, l.value) : o?.value));
}
return {
props: s,
provideSubDefaults: i
};
}
const Fu = ["top", "bottom"], zm = ["start", "end", "left", "right"];
function Js(e, t) {
let [n, a] = e.split(" ");
return a || (a = Sr(Fu, n) ? "start" : Sr(zm, n) ? "top" : "center"), {
side: Ki(n, t),
align: Ki(a, t)
};
}
function Ki(e, t) {
return e === "start" ? t ? "right" : "left" : e === "end" ? t ? "left" : "right" : e;
}
function ks(e) {
return {
side: {
center: "center",
top: "bottom",
bottom: "top",
left: "right",
right: "left"
}[e.side],
align: e.align
};
}
function Cs(e) {
return {
side: e.side,
align: {
center: "center",
top: "bottom",
bottom: "top",
left: "right",
right: "left"
}[e.align]
};
}
function Ji(e) {
return {
side: e.align,
align: e.side
};
}
function Zi(e) {
return Sr(Fu, e.side) ? "y" : "x";
}
class Bt {
constructor(t) {
let {
x: n,
y: a,
width: r,
height: s
} = t;
this.x = n, this.y = a, this.width = r, this.height = s;
}
get top() {
return this.y;
}
get bottom() {
return this.y + this.height;
}
get left() {
return this.x;
}
get right() {
return this.x + this.width;
}
}
function Xi(e, t) {
return {
x: {
before: Math.max(0, t.left - e.left),
after: Math.max(0, e.right - t.right)
},
y: {
before: Math.max(0, t.top - e.top),
after: Math.max(0, e.bottom - t.bottom)
}
};
}
function Lu(e) {
return Array.isArray(e) ? new Bt({
x: e[0],
y: e[1],
width: 0,
height: 0
}) : e.getBoundingClientRect();
}
function Hm(e) {
if (e === document.documentElement)
return visualViewport ? new Bt({
x: visualViewport.scale > 1 ? 0 : visualViewport.offsetLeft,
y: visualViewport.scale > 1 ? 0 : visualViewport.offsetTop,
width: visualViewport.width * visualViewport.scale,
height: visualViewport.height * visualViewport.scale
}) : new Bt({
x: 0,
y: 0,
width: document.documentElement.clientWidth,
height: document.documentElement.clientHeight
});
{
const t = e.getBoundingClientRect();
return new Bt({
x: t.x,
y: t.y,
width: e.clientWidth,
height: e.clientHeight
});
}
}
function Rl(e) {
const t = e.getBoundingClientRect(), n = getComputedStyle(e), a = n.transform;
if (a) {
let r, s, l, i, o;
if (a.startsWith("matrix3d("))
r = a.slice(9, -1).split(/, /), s = Number(r[0]), l = Number(r[5]), i = Number(r[12]), o = Number(r[13]);
else if (a.startsWith("matrix("))
r = a.slice(7, -1).split(/, /), s = Number(r[0]), l = Number(r[3]), i = Number(r[4]), o = Number(r[5]);
else
return new Bt(t);
const u = n.transformOrigin, c = t.x - i - (1 - s) * parseFloat(u), d = t.y - o - (1 - l) * parseFloat(u.slice(u.indexOf(" ") + 1)), f = s ? t.width / s : e.offsetWidth + 1, v = l ? t.height / l : e.offsetHeight + 1;
return new Bt({
x: c,
y: d,
width: f,
height: v
});
} else
return new Bt(t);
}
function Gn(e, t, n) {
if (typeof e.animate > "u") return {
finished: Promise.resolve()
};
let a;
try {
a = e.animate(t, n);
} catch {
return {
finished: Promise.resolve()
};
}
return typeof a.finished > "u" && (a.finished = new Promise((r) => {
a.onfinish = () => {
r(a);
};
})), a;
}
const hr = /* @__PURE__ */ new WeakMap();
function Ym(e, t) {
Object.keys(t).forEach((n) => {
if (Al(n)) {
const a = Eu(n), r = hr.get(e);
if (t[n] == null)
r?.forEach((s) => {
const [l, i] = s;
l === a && (e.removeEventListener(a, i), r.delete(s));
});
else if (!r || ![...r].some((s) => s[0] === a && s[1] === t[n])) {
e.addEventListener(a, t[n]);
const s = r || /* @__PURE__ */ new Set();
s.add([a, t[n]]), hr.has(e) || hr.set(e, s);
}
} else
t[n] == null ? e.removeAttribute(n) : e.setAttribute(n, t[n]);
});
}
function jm(e, t) {
Object.keys(t).forEach((n) => {
if (Al(n)) {
const a = Eu(n), r = hr.get(e);
r?.forEach((s) => {
const [l, i] = s;
l === a && (e.removeEventListener(a, i), r.delete(s));
});
} else
e.removeAttribute(n);
});
}
const Yn = 2.4, eo = 0.2126729, to = 0.7151522, no = 0.072175, Wm = 0.55, Gm = 0.58, Qm = 0.57, qm = 0.62, rr = 0.03, ao = 1.45, Km = 5e-4, Jm = 1.25, Zm = 1.25, Xm = 0.078, ro = 12.82051282051282, sr = 0.06, ev = 1e-3;
function so(e, t) {
const n = (e.r / 255) ** Yn, a = (e.g / 255) ** Yn, r = (e.b / 255) ** Yn, s = (t.r / 255) ** Yn, l = (t.g / 255) ** Yn, i = (t.b / 255) ** Yn;
let o = n * eo + a * to + r * no, u = s * eo + l * to + i * no;
if (o <= rr && (o += (rr - o) ** ao), u <= rr && (u += (rr - u) ** ao), Math.abs(u - o) < Km) return 0;
let c;
if (u > o) {
const d = (u ** Wm - o ** Gm) * Jm;
c = d < ev ? 0 : d < Xm ? d - d * ro * sr : d - sr;
} else {
const d = (u ** qm - o ** Qm) * Zm;
c = d > -1e-3 ? 0 : d > -0.078 ? d - d * ro * sr : d + sr;
}
return c * 100;
}
function Sn(e) {
Fr(`Vuetify: ${e}`);
}
function Fl(e) {
Fr(`Vuetify error: ${e}`);
}
function tv(e, t) {
t = Array.isArray(t) ? t.slice(0, -1).map((n) => `'${n}'`).join(", ") + ` or '${t.at(-1)}'` : `'${t}'`, Fr(`[Vuetify UPGRADE] '${e}' is deprecated, use ${t} instead.`);
}
function Zs(e) {
return !!e && /^(#|var\(--|(rgb|hsl)a?\()/.test(e);
}
function nv(e) {
return Zs(e) && !/^((rgb|hsl)a?\()?var\(--/.test(e);
}
const lo = /^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/, av = {
rgb: (e, t, n, a) => ({
r: e,
g: t,
b: n,
a
}),
rgba: (e, t, n, a) => ({
r: e,
g: t,
b: n,
a
}),
hsl: (e, t, n, a) => io({
h: e,
s: t,
l: n,
a
}),
hsla: (e, t, n, a) => io({
h: e,
s: t,
l: n,
a
}),
hsv: (e, t, n, a) => Oa({
h: e,
s: t,
v: n,
a
}),
hsva: (e, t, n, a) => Oa({
h: e,
s: t,
v: n,
a
})
};
function wa(e) {
if (typeof e == "number")
return (isNaN(e) || e < 0 || e > 16777215) && Sn(`'${e}' is not a valid hex color`), {
r: (e & 16711680) >> 16,
g: (e & 65280) >> 8,
b: e & 255
};
if (typeof e == "string" && lo.test(e)) {
const {
groups: t
} = e.match(lo), {
fn: n,
values: a
} = t, r = a.split(/,\s*|\s*\/\s*|\s+/).map((s, l) => s.endsWith("%") || // unitless slv are %
l > 0 && l < 3 && ["hsl", "hsla", "hsv", "hsva"].includes(n) ? parseFloat(s) / 100 : parseFloat(s));
return av[n](...r);
} else if (typeof e == "string") {
let t = e.startsWith("#") ? e.slice(1) : e;
[3, 4].includes(t.length) ? t = t.split("").map((a) => a + a).join("") : [6, 8].includes(t.length) || Sn(`'${e}' is not a valid hex(a) color`);
const n = parseInt(t, 16);
return (isNaN(n) || n < 0 || n > 4294967295) && Sn(`'${e}' is not a valid hex(a) color`), rv(t);
} else if (typeof e == "object") {
if (_s(e, ["r", "g", "b"]))
return e;
if (_s(e, ["h", "s", "l"]))
return Oa(Nu(e));
if (_s(e, ["h", "s", "v"]))
return Oa(e);
}
throw new TypeError(`Invalid color: ${e == null ? e : String(e) || e.constructor.name}
Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`);
}
function Oa(e) {
const {
h: t,
s: n,
v: a,
a: r
} = e, s = (i) => {
const o = (i + t / 60) % 6;
return a - a * n * Math.max(Math.min(o, 4 - o, 1), 0);
}, l = [s(5), s(3), s(1)].map((i) => Math.round(i * 255));
return {
r: l[0],
g: l[1],
b: l[2],
a: r
};
}
function io(e) {
return Oa(Nu(e));
}
function Nu(e) {
const {
h: t,
s: n,
l: a,
a: r
} = e, s = a + n * Math.min(a, 1 - a), l = s === 0 ? 0 : 2 - 2 * a / s;
return {
h: t,
s: l,
v: s,
a: r
};
}
function rv(e) {
e = sv(e);
let [t, n, a, r] = Mm(e, 2).map((s) => parseInt(s, 16));
return r = r === void 0 ? r : r / 255, {
r: t,
g: n,
b: a,
a: r
};
}
function sv(e) {
return e.startsWith("#") && (e = e.slice(1)), e = e.replace(/([^0-9a-f])/gi, "F"), (e.length === 3 || e.length === 4) && (e = e.split("").map((t) => t + t).join("")), e.length !== 6 && (e = Qi(Qi(e, 6), 8, "F")), e;
}
function lv(e) {
const t = Math.abs(so(wa(0), wa(e)));
return Math.abs(so(wa(16777215), wa(e))) > Math.min(t, 50) ? "#fff" : "#000";
}
function M(e, t) {
return (n) => Object.keys(e).reduce((a, r) => {
const l = typeof e[r] == "object" && e[r] != null && !Array.isArray(e[r]) ? e[r] : {
type: e[r]
};
return n && r in n ? a[r] = {
...l,
default: n[r]
} : a[r] = l, t && !a[r].source && (a[r].source = t), a;
}, {});
}
const ce = M({
class: [String, Array, Object],
style: {
type: [String, Array, Object],
default: null
}
}, "component");
function Ha(e) {
if (e._setup = e._setup ?? e.setup, !e.name)
return Sn("The component is missing an explicit name, unable to generate default prop value"), e;
if (e._setup) {
e.props = M(e.props ?? {}, e.name)();
const t = Object.keys(e.props).filter((n) => n !== "class" && n !== "style");
e.filterProps = function(a) {
return jr(a, t);
}, e.props._as = String, e.setup = function(a, r) {
const s = Ml();
if (!s.value) return e._setup(a, r);
const {
props: l,
provideSubDefaults: i
} = Um(a, a._as ?? e.name, s), o = e._setup(l, r);
return i(), o;
};
}
return e;
}
function G() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !0;
return (t) => (e ? Ha : Rr)(t);
}
function iv(e, t) {
return t.props = e, t;
}
function Bu(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "div", n = arguments.length > 2 ? arguments[2] : void 0;
return G()({
name: n ?? na(Ko(e.replace(/__/g, "-"))),
props: {
tag: {
type: String,
default: t
},
...ce()
},
setup(a, r) {
let {
slots: s
} = r;
return () => aa(a.tag, {
class: [e, a.class],
style: a.style
}, s.default?.());
}
});
}
function $u(e) {
if (typeof e.getRootNode != "function") {
for (; e.parentNode; ) e = e.parentNode;
return e !== document ? null : document;
}
const t = e.getRootNode();
return t !== document && t.getRootNode({
composed: !0
}) !== document ? null : t;
}
const kr = "cubic-bezier(0.4, 0, 0.2, 1)", ov = "cubic-bezier(0.0, 0, 0.2, 1)", uv = "cubic-bezier(0.4, 0, 1, 1)";
function oo(e, t, n) {
return Object.keys(e).filter((a) => Al(a) && a.endsWith(t)).reduce((a, r) => (a[r.slice(0, -t.length)] = (s) => e[r](s, n(s)), a), {});
}
function Uu(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
for (; e; ) {
if (t ? cv(e) : Ll(e)) return e;
e = e.parentElement;
}
return document.scrollingElement;
}
function Cr(e, t) {
const n = [];
if (t && e && !t.contains(e)) return n;
for (; e && (Ll(e) && n.push(e), e !== t); )
e = e.parentElement;
return n;
}
function Ll(e) {
if (!e || e.nodeType !== Node.ELEMENT_NODE) return !1;
const t = window.getComputedStyle(e);
return t.overflowY === "scroll" || t.overflowY === "auto" && e.scrollHeight > e.clientHeight;
}
function cv(e) {
if (!e || e.nodeType !== Node.ELEMENT_NODE) return !1;
const t = window.getComputedStyle(e);
return ["scroll", "auto"].includes(t.overflowY);
}
function dv(e) {
for (; e; ) {
if (window.getComputedStyle(e).position === "fixed")
return !0;
e = e.offsetParent;
}
return !1;
}
function ee(e) {
const t = Ue("useRender");
t.render = e;
}
const fv = M({
defaults: Object,
disabled: Boolean,
reset: [Number, String],
root: [Boolean, String],
scoped: Boolean
}, "VDefaultsProvider"), Ne = G(!1)({
name: "VDefaultsProvider",
props: fv(),
setup(e, t) {
let {
slots: n
} = t;
const {
defaults: a,
disabled: r,
reset: s,
root: l,
scoped: i
} = Jo(e);
return zt(a, {
reset: s,
root: l,
scoped: i,
disabled: r
}), () => n.default?.();
}
});
function Nl(e) {
return El(() => {
const t = rn(e), n = [], a = {};
if (t.background)
if (Zs(t.background)) {
if (a.backgroundColor = t.background, !t.text && nv(t.background)) {
const r = wa(t.background);
if (r.a == null || r.a === 1) {
const s = lv(r);
a.color = s, a.caretColor = s;
}
}
} else
n.push(`bg-${t.background}`);
return t.text && (Zs(t.text) ? (a.color = t.text, a.caretColor = t.text) : n.push(`text-${t.text}`)), {
colorClasses: n,
colorStyles: a
};
});
}
function Ht(e) {
const {
colorClasses: t,
colorStyles: n
} = Nl(() => ({
text: rn(e)
}));
return {
textColorClasses: t,
textColorStyles: n
};
}
function $t(e) {
const {
colorClasses: t,
colorStyles: n
} = Nl(() => ({
background: rn(e)
}));
return {
backgroundColorClasses: t,
backgroundColorStyles: n
};
}
const le = [String, Function, Object, Array], hv = Symbol.for("vuetify:icons"), Gr = M({
icon: {
type: le
},
// Could not remove this and use makeTagProps, types complained because it is not required
tag: {
type: [String, Object, Function],
required: !0
}
}, "icon"), uo = G()({
name: "VComponentIcon",
props: Gr(),
setup(e, t) {
let {
slots: n
} = t;
return () => {
const a = e.icon;
return g(e.tag, null, {
default: () => [e.icon ? g(a, null, null) : n.default?.()]
});
};
}
}), mv = Ha({
name: "VSvgIcon",
inheritAttrs: !1,
props: Gr(),
setup(e, t) {
let {
attrs: n
} = t;
return () => g(e.tag, j(n, {
style: null
}), {
default: () => [p("svg", {
class: "v-icon__svg",
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 24 24",
role: "img",
"aria-hidden": "true"
}, [Array.isArray(e.icon) ? e.icon.map((a) => Array.isArray(a) ? p("path", {
d: a[0],
"fill-opacity": a[1]
}, null) : p("path", {
d: a
}, null)) : p("path", {
d: e.icon
}, null)])]
});
}
});
Ha({
name: "VLigatureIcon",
props: Gr(),
setup(e) {
return () => g(e.tag, null, {
default: () => [e.icon]
});
}
});
Ha({
name: "VClassIcon",
props: Gr(),
setup(e) {
return () => g(e.tag, {
class: Q(e.icon)
}, null);
}
});
const vv = (e) => {
const t = De(hv);
if (!t) throw new Error("Missing Vuetify Icons provide!");
return {
iconData: _(() => {
const a = rn(e);
if (!a) return {
component: uo
};
let r = a;
if (typeof r == "string" && (r = r.trim(), r.startsWith("$") && (r = t.aliases?.[r.slice(1)])), r || Sn(`Could not find aliased icon "${a}"`), Array.isArray(r))
return {
component: mv,
icon: r
};
if (typeof r != "string")
return {
component: uo,
icon: r
};
const s = Object.keys(t.sets).find((o) => typeof r == "string" && r.startsWith(`${o}:`)), l = s ? r.slice(s.length + 1) : r;
return {
component: t.sets[s ?? t.defaultSet].component,
icon: l
};
})
};
}, yv = ["x-small", "small", "default", "large", "x-large"], la = M({
size: {
type: [String, Number],
default: "default"
}
}, "size");
function Ya(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return El(() => {
const n = e.size;
let a, r;
return Sr(yv, n) ? a = `${t}--size-${n}` : n && (r = {
width: te(n),
height: te(n)
}), {
sizeClasses: a,
sizeStyles: r
};
});
}
const Le = M({
tag: {
type: [String, Object, Function],
default: "div"
}
}, "tag"), Xs = Symbol.for("vuetify:theme"), Ye = M({
theme: String
}, "theme");
function Ze(e) {
Ue("provideTheme");
const t = De(Xs, null);
if (!t) throw new Error("Could not find Vuetify theme injection");
const n = I(() => e.theme ?? t.name.value), a = I(() => t.themes.value[n.value]), r = I(() => t.isDisabled ? void 0 : `v-theme--${n.value}`), s = {
...t,
name: n,
current: a,
themeClasses: r
};
return We(Xs, s), s;
}
function gv() {
Ue("useTheme");
const e = De(Xs, null);
if (!e) throw new Error("Could not find Vuetify theme injection");
return e;
}
const bv = M({
color: String,
disabled: Boolean,
start: Boolean,
end: Boolean,
icon: le,
opacity: [String, Number],
...ce(),
...la(),
...Le({
tag: "i"
}),
...Ye()
}, "VIcon"), Ve = G()({
name: "VIcon",
props: bv(),
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const r = ne(), {
themeClasses: s
} = gv(), {
iconData: l
} = vv(() => r.value || e.icon), {
sizeClasses: i
} = Ya(e), {
textColorClasses: o,
textColorStyles: u
} = Ht(() => e.color);
return ee(() => {
const c = a.default?.();
c && (r.value = Au(c).filter((f) => f.type === Mf && f.children && typeof f.children == "string")[0]?.children);
const d = !!(n.onClick || n.onClickOnce);
return g(l.value.component, {
tag: e.tag,
icon: l.value.icon,
class: Q(["v-icon", "notranslate", s.value, i.value, o.value, {
"v-icon--clickable": d,
"v-icon--disabled": e.disabled,
"v-icon--start": e.start,
"v-icon--end": e.end
}, e.class]),
style: J([{
"--v-icon-opacity": e.opacity
}, i.value ? void 0 : {
fontSize: te(e.size),
height: te(e.size),
width: te(e.size)
}, u.value, e.style]),
role: d ? "button" : void 0,
"aria-hidden": !d,
tabindex: d ? e.disabled ? -1 : 0 : void 0
}, {
default: () => [c]
});
}), {};
}
}), un = M({
height: [Number, String],
maxHeight: [Number, String],
maxWidth: [Number, String],
minHeight: [Number, String],
minWidth: [Number, String],
width: [Number, String]
}, "dimension");
function cn(e) {
return {
dimensionStyles: _(() => {
const n = {}, a = te(e.height), r = te(e.maxHeight), s = te(e.maxWidth), l = te(e.minHeight), i = te(e.minWidth), o = te(e.width);
return a != null && (n.height = a), r != null && (n.maxHeight = r), s != null && (n.maxWidth = s), l != null && (n.minHeight = l), i != null && (n.minWidth = i), o != null && (n.width = o), n;
})
};
}
function pv(e) {
return {
aspectStyles: _(() => {
const t = Number(e.aspectRatio);
return t ? {
paddingBottom: String(1 / t * 100) + "%"
} : void 0;
})
};
}
const zu = M({
aspectRatio: [String, Number],
contentClass: null,
inline: Boolean,
...ce(),
...un()
}, "VResponsive"), co = G()({
name: "VResponsive",
props: zu(),
setup(e, t) {
let {
slots: n
} = t;
const {
aspectStyles: a
} = pv(e), {
dimensionStyles: r
} = cn(e);
return ee(() => p("div", {
class: Q(["v-responsive", {
"v-responsive--inline": e.inline
}, e.class]),
style: J([r.value, e.style])
}, [p("div", {
class: "v-responsive__sizer",
style: J(a.value)
}, null), n.additional?.(), n.default && p("div", {
class: Q(["v-responsive__content", e.contentClass])
}, [n.default()])])), {};
}
}), kt = M({
rounded: {
type: [Boolean, Number, String],
default: void 0
},
tile: Boolean
}, "rounded");
function Dt(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return {
roundedClasses: _(() => {
const a = $s(e) ? e.value : e.rounded, r = $s(e) ? e.value : e.tile, s = [];
if (a === !0 || a === "")
s.push(`${t}--rounded`);
else if (typeof a == "string" || a === 0)
for (const l of String(a).split(" "))
s.push(`rounded-${l}`);
else (r || a === !1) && s.push("rounded-0");
return s;
})
};
}
const ia = M({
transition: {
type: null,
default: "fade-transition",
validator: (e) => e !== !0
}
}, "transition"), gn = (e, t) => {
let {
slots: n
} = t;
const {
transition: a,
disabled: r,
group: s,
...l
} = e, {
component: i = s ? _l : Mn,
...o
} = qs(a) ? a : {};
let u;
return qs(a) ? u = j(o, JSON.parse(JSON.stringify({
disabled: r,
group: s
})), l) : u = j({
name: r || !a ? "" : a
}, l), aa(i, u, n);
};
function Sv(e, t) {
if (!Vl) return;
const n = t.modifiers || {}, a = t.value, {
handler: r,
options: s
} = typeof a == "object" ? a : {
handler: a,
options: {}
}, l = new IntersectionObserver(function() {
let i = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], o = arguments.length > 1 ? arguments[1] : void 0;
const u = e._observe?.[t.instance.$.uid];
if (!u) return;
const c = i.some((d) => d.isIntersecting);
r && (!n.quiet || u.init) && (!n.once || c || u.init) && r(c, i, o), c && n.once ? Hu(e, t) : u.init = !0;
}, s);
e._observe = Object(e._observe), e._observe[t.instance.$.uid] = {
init: !1,
observer: l
}, l.observe(e);
}
function Hu(e, t) {
const n = e._observe?.[t.instance.$.uid];
n && (n.observer.unobserve(e), delete e._observe[t.instance.$.uid]);
}
const Pr = {
mounted: Sv,
unmounted: Hu
}, wv = M({
absolute: Boolean,
alt: String,
cover: Boolean,
color: String,
draggable: {
type: [Boolean, String],
default: void 0
},
eager: Boolean,
gradient: String,
lazySrc: String,
options: {
type: Object,
// For more information on types, navigate to:
// https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API
default: () => ({
root: void 0,
rootMargin: void 0,
threshold: void 0
})
},
sizes: String,
src: {
type: [String, Object],
default: ""
},
crossorigin: String,
referrerpolicy: String,
srcset: String,
position: String,
...zu(),
...ce(),
...kt(),
...ia()
}, "VImg"), Bl = G()({
name: "VImg",
directives: {
vIntersect: Pr
},
props: wv(),
emits: {
loadstart: (e) => !0,
load: (e) => !0,
error: (e) => !0
},
setup(e, t) {
let {
emit: n,
slots: a
} = t;
const {
backgroundColorClasses: r,
backgroundColorStyles: s
} = $t(() => e.color), {
roundedClasses: l
} = Dt(e), i = Ue("VImg"), o = ne(""), u = R(), c = ne(e.eager ? "loading" : "idle"), d = ne(), f = ne(), v = _(() => e.src && typeof e.src == "object" ? {
src: e.src.src,
srcset: e.srcset || e.src.srcset,
lazySrc: e.lazySrc || e.src.lazySrc,
aspect: Number(e.aspectRatio || e.src.aspect || 0)
} : {
src: e.src,
srcset: e.srcset,
lazySrc: e.lazySrc,
aspect: Number(e.aspectRatio || 0)
}), m = _(() => v.value.aspect || d.value / f.value || 0);
re(() => e.src, () => {
y(c.value !== "idle");
}), re(m, (B, D) => {
!B && D && u.value && O(u.value);
}), Lr(() => y());
function y(B) {
if (!(e.eager && B) && !(Vl && !B && !e.eager)) {
if (c.value = "loading", v.value.lazySrc) {
const D = new Image();
D.src = v.value.lazySrc, O(D, null);
}
v.value.src && Ge(() => {
n("loadstart", u.value?.currentSrc || v.value.src), setTimeout(() => {
if (!i.isUnmounted)
if (u.value?.complete) {
if (u.value.naturalWidth || b(), c.value === "error") return;
m.value || O(u.value, null), c.value === "loading" && h();
} else
m.value || O(u.value), S();
});
});
}
}
function h() {
i.isUnmounted || (S(), O(u.value), c.value = "loaded", n("load", u.value?.currentSrc || v.value.src));
}
function b() {
i.isUnmounted || (c.value = "error", n("error", u.value?.currentSrc || v.value.src));
}
function S() {
const B = u.value;
B && (o.value = B.currentSrc || B.src);
}
let P = -1;
At(() => {
clearTimeout(P);
});
function O(B) {
let D = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 100;
const H = () => {
if (clearTimeout(P), i.isUnmounted) return;
const {
naturalHeight: Y,
naturalWidth: X
} = B;
Y || X ? (d.value = X, f.value = Y) : !B.complete && c.value === "loading" && D != null ? P = window.setTimeout(H, D) : (B.currentSrc.endsWith(".svg") || B.currentSrc.startsWith("data:image/svg+xml")) && (d.value = 1, f.value = 1);
};
H();
}
const k = I(() => ({
"v-img__img--cover": e.cover,
"v-img__img--contain": !e.cover
})), E = () => {
if (!v.value.src || c.value === "idle") return null;
const B = p("img", {
class: Q(["v-img__img", k.value]),
style: J({
objectPosition: e.position
}),
crossorigin: e.crossorigin,
src: v.value.src,
srcset: v.value.srcset,
alt: e.alt,
referrerpolicy: e.referrerpolicy,
draggable: e.draggable,
sizes: e.sizes,
ref: u,
onLoad: h,
onError: b
}, null), D = a.sources?.();
return g(gn, {
transition: e.transition,
appear: !0
}, {
default: () => [ht(D ? p("picture", {
class: "v-img__picture"
}, [D, B]) : B, [[Bn, c.value === "loaded"]])]
});
}, V = () => g(gn, {
transition: e.transition
}, {
default: () => [v.value.lazySrc && c.value !== "loaded" && p("img", {
class: Q(["v-img__img", "v-img__img--preload", k.value]),
style: J({
objectPosition: e.position
}),
crossorigin: e.crossorigin,
src: v.value.lazySrc,
alt: e.alt,
referrerpolicy: e.referrerpolicy,
draggable: e.draggable
}, null)]
}), w = () => a.placeholder ? g(gn, {
transition: e.transition,
appear: !0
}, {
default: () => [(c.value === "loading" || c.value === "error" && !a.error) && p("div", {
class: "v-img__placeholder"
}, [a.placeholder()])]
}) : null, T = () => a.error ? g(gn, {
transition: e.transition,
appear: !0
}, {
default: () => [c.value === "error" && p("div", {
class: "v-img__error"
}, [a.error()])]
}) : null, L = () => e.gradient ? p("div", {
class: "v-img__gradient",
style: J({
backgroundImage: `linear-gradient(${e.gradient})`
})
}, null) : null, $ = ne(!1);
{
const B = re(m, (D) => {
D && (requestAnimationFrame(() => {
requestAnimationFrame(() => {
$.value = !0;
});
}), B());
});
}
return ee(() => {
const B = co.filterProps(e);
return ht(g(co, j({
class: ["v-img", {
"v-img--absolute": e.absolute,
"v-img--booting": !$.value
}, r.value, l.value, e.class],
style: [{
width: te(e.width === "auto" ? d.value : e.width)
}, s.value, e.style]
}, B, {
aspectRatio: m.value,
"aria-label": e.alt,
role: e.alt ? "img" : void 0
}), {
additional: () => p(pe, null, [g(E, null, null), g(V, null, null), g(L, null, null), g(w, null, null), g(T, null, null)]),
default: a.default
}), [[Pr, {
handler: y,
options: e.options
}, null, {
once: !0
}]]);
}), {
currentSrc: o,
image: u,
state: c,
naturalWidth: d,
naturalHeight: f
};
}
}), dn = M({
border: [Boolean, Number, String]
}, "border");
function Cn(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return {
borderClasses: _(() => {
const a = e.border;
return a === !0 || a === "" ? `${t}--border` : typeof a == "string" || a === 0 ? String(a).split(" ").map((r) => `border-${r}`) : [];
})
};
}
const _v = [null, "default", "comfortable", "compact"], Ct = M({
density: {
type: String,
default: "default",
validator: (e) => _v.includes(e)
}
}, "density");
function Wt(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return {
densityClasses: I(() => `${t}--density-${e.density}`)
};
}
const kv = ["elevated", "flat", "tonal", "outlined", "text", "plain"];
function ja(e, t) {
return p(pe, null, [e && p("span", {
key: "overlay",
class: Q(`${t}__overlay`)
}, null), p("span", {
key: "underlay",
class: Q(`${t}__underlay`)
}, null)]);
}
const fn = M({
color: String,
variant: {
type: String,
default: "elevated",
validator: (e) => kv.includes(e)
}
}, "variant");
function Wa(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
const n = I(() => {
const {
variant: s
} = rn(e);
return `${t}--variant-${s}`;
}), {
colorClasses: a,
colorStyles: r
} = Nl(() => {
const {
variant: s,
color: l
} = rn(e);
return {
[["elevated", "flat"].includes(s) ? "background" : "text"]: l
};
});
return {
colorClasses: a,
colorStyles: r,
variantClasses: n
};
}
const Cv = M({
start: Boolean,
end: Boolean,
icon: le,
image: String,
text: String,
...dn(),
...ce(),
...Ct(),
...kt(),
...la(),
...Le(),
...Ye(),
...fn({
variant: "flat"
})
}, "VAvatar"), _n = G()({
name: "VAvatar",
props: Cv(),
setup(e, t) {
let {
slots: n
} = t;
const {
themeClasses: a
} = Ze(e), {
borderClasses: r
} = Cn(e), {
colorClasses: s,
colorStyles: l,
variantClasses: i
} = Wa(e), {
densityClasses: o
} = Wt(e), {
roundedClasses: u
} = Dt(e), {
sizeClasses: c,
sizeStyles: d
} = Ya(e);
return ee(() => g(e.tag, {
class: Q(["v-avatar", {
"v-avatar--start": e.start,
"v-avatar--end": e.end
}, a.value, r.value, s.value, o.value, u.value, c.value, i.value, e.class]),
style: J([l.value, d.value, e.style])
}, {
default: () => [n.default ? g(Ne, {
key: "content-defaults",
defaults: {
VImg: {
cover: !0,
src: e.image
},
VIcon: {
icon: e.icon
}
}
}, {
default: () => [n.default()]
}) : e.image ? g(Bl, {
key: "image",
src: e.image,
alt: "",
cover: !0
}, null) : e.icon ? g(Ve, {
key: "icon",
icon: e.icon
}, null) : e.text, ja(!1, "v-avatar")]
})), {};
}
}), Pv = M({
text: String,
onClick: Je(),
...ce(),
...Ye()
}, "VLabel"), $l = G()({
name: "VLabel",
props: Pv(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => p("label", {
class: Q(["v-label", {
"v-label--clickable": !!e.onClick
}, e.class]),
style: J(e.style),
onClick: e.onClick
}, [e.text, n.default?.()])), {};
}
});
function Fn(e, t) {
let n;
function a() {
n = kl(), n.run(() => t.length ? t(() => {
n?.stop(), a();
}) : t());
}
re(e, (r) => {
r && !n ? a() : r || (n?.stop(), n = void 0);
}, {
immediate: !0
}), mt(() => {
n?.stop();
});
}
function _e(e, t, n) {
let a = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : (d) => d, r = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : (d) => d;
const s = Ue("useProxiedModel"), l = R(e[t] !== void 0 ? e[t] : n), i = En(t), u = i !== t ? _(() => (e[t], !!((s.vnode.props?.hasOwnProperty(t) || s.vnode.props?.hasOwnProperty(i)) && (s.vnode.props?.hasOwnProperty(`onUpdate:${t}`) || s.vnode.props?.hasOwnProperty(`onUpdate:${i}`))))) : _(() => (e[t], !!(s.vnode.props?.hasOwnProperty(t) && s.vnode.props?.hasOwnProperty(`onUpdate:${t}`))));
Fn(() => !u.value, () => {
re(() => e[t], (d) => {
l.value = d;
});
});
const c = _({
get() {
const d = e[t];
return a(u.value ? d : l.value);
},
set(d) {
const f = r(d), v = He(u.value ? e[t] : l.value);
v === f || a(v) === d || (l.value = f, s?.emit(`update:${t}`, f));
}
});
return Object.defineProperty(c, "externalValue", {
get: () => u.value ? e[t] : l.value
}), c;
}
const Yu = Symbol.for("vuetify:selection-control-group"), Ul = M({
color: String,
disabled: {
type: Boolean,
default: null
},
defaultsTarget: String,
error: Boolean,
id: String,
inline: Boolean,
falseIcon: le,
trueIcon: le,
ripple: {
type: [Boolean, Object],
default: !0
},
multiple: {
type: Boolean,
default: null
},
name: String,
readonly: {
type: Boolean,
default: null
},
modelValue: null,
type: String,
valueComparator: {
type: Function,
default: gt
},
...ce(),
...Ct(),
...Ye()
}, "SelectionControlGroup"), xv = M({
...Ul({
defaultsTarget: "VSelectionControl"
})
}, "VSelectionControlGroup"), Iv = G()({
name: "VSelectionControlGroup",
props: xv(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const a = _e(e, "modelValue"), r = on(), s = I(() => e.id || `v-selection-control-group-${r}`), l = I(() => e.name || s.value), i = /* @__PURE__ */ new Set();
return We(Yu, {
modelValue: a,
forceUpdate: () => {
i.forEach((o) => o());
},
onForceUpdate: (o) => {
i.add(o), mt(() => {
i.delete(o);
});
}
}), zt({
[e.defaultsTarget]: {
color: I(() => e.color),
disabled: I(() => e.disabled),
density: I(() => e.density),
error: I(() => e.error),
inline: I(() => e.inline),
modelValue: a,
multiple: I(() => !!e.multiple || e.multiple == null && Array.isArray(a.value)),
name: l,
falseIcon: I(() => e.falseIcon),
trueIcon: I(() => e.trueIcon),
readonly: I(() => e.readonly),
ripple: I(() => e.ripple),
type: I(() => e.type),
valueComparator: I(() => e.valueComparator)
}
}), ee(() => p("div", {
class: Q(["v-selection-control-group", {
"v-selection-control-group--inline": e.inline
}, e.class]),
style: J(e.style),
role: e.type === "radio" ? "radiogroup" : void 0
}, [n.default?.()])), {};
}
}), el = Symbol("rippleStop"), Ov = 80;
function fo(e, t) {
e.style.transform = t, e.style.webkitTransform = t;
}
function tl(e) {
return e.constructor.name === "TouchEvent";
}
function ju(e) {
return e.constructor.name === "KeyboardEvent";
}
const Tv = function(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, a = 0, r = 0;
if (!ju(e)) {
const d = t.getBoundingClientRect(), f = tl(e) ? e.touches[e.touches.length - 1] : e;
a = f.clientX - d.left, r = f.clientY - d.top;
}
let s = 0, l = 0.3;
t._ripple?.circle ? (l = 0.15, s = t.clientWidth / 2, s = n.center ? s : s + Math.sqrt((a - s) ** 2 + (r - s) ** 2) / 4) : s = Math.sqrt(t.clientWidth ** 2 + t.clientHeight ** 2) / 2;
const i = `${(t.clientWidth - s * 2) / 2}px`, o = `${(t.clientHeight - s * 2) / 2}px`, u = n.center ? i : `${a - s}px`, c = n.center ? o : `${r - s}px`;
return {
radius: s,
scale: l,
x: u,
y: c,
centerX: i,
centerY: o
};
}, xr = {
/* eslint-disable max-statements */
show(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
if (!t?._ripple?.enabled)
return;
const a = document.createElement("span"), r = document.createElement("span");
a.appendChild(r), a.className = "v-ripple__container", n.class && (a.className += ` ${n.class}`);
const {
radius: s,
scale: l,
x: i,
y: o,
centerX: u,
centerY: c
} = Tv(e, t, n), d = `${s * 2}px`;
r.className = "v-ripple__animation", r.style.width = d, r.style.height = d, t.appendChild(a);
const f = window.getComputedStyle(t);
f && f.position === "static" && (t.style.position = "relative", t.dataset.previousPosition = "static"), r.classList.add("v-ripple__animation--enter"), r.classList.add("v-ripple__animation--visible"), fo(r, `translate(${i}, ${o}) scale3d(${l},${l},${l})`), r.dataset.activated = String(performance.now()), requestAnimationFrame(() => {
requestAnimationFrame(() => {
r.classList.remove("v-ripple__animation--enter"), r.classList.add("v-ripple__animation--in"), fo(r, `translate(${u}, ${c}) scale3d(1,1,1)`);
});
});
},
hide(e) {
if (!e?._ripple?.enabled) return;
const t = e.getElementsByClassName("v-ripple__animation");
if (t.length === 0) return;
const n = t[t.length - 1];
if (n.dataset.isHiding) return;
n.dataset.isHiding = "true";
const a = performance.now() - Number(n.dataset.activated), r = Math.max(250 - a, 0);
setTimeout(() => {
n.classList.remove("v-ripple__animation--in"), n.classList.add("v-ripple__animation--out"), setTimeout(() => {
e.getElementsByClassName("v-ripple__animation").length === 1 && e.dataset.previousPosition && (e.style.position = e.dataset.previousPosition, delete e.dataset.previousPosition), n.parentNode?.parentNode === e && e.removeChild(n.parentNode);
}, 300);
}, r);
}
};
function Wu(e) {
return typeof e > "u" || !!e;
}
function Ta(e) {
const t = {}, n = e.currentTarget;
if (!(!n?._ripple || n._ripple.touched || e[el])) {
if (e[el] = !0, tl(e))
n._ripple.touched = !0, n._ripple.isTouch = !0;
else if (n._ripple.isTouch) return;
if (t.center = n._ripple.centered || ju(e), n._ripple.class && (t.class = n._ripple.class), tl(e)) {
if (n._ripple.showTimerCommit) return;
n._ripple.showTimerCommit = () => {
xr.show(e, n, t);
}, n._ripple.showTimer = window.setTimeout(() => {
n?._ripple?.showTimerCommit && (n._ripple.showTimerCommit(), n._ripple.showTimerCommit = null);
}, Ov);
} else
xr.show(e, n, t);
}
}
function ho(e) {
e[el] = !0;
}
function yt(e) {
const t = e.currentTarget;
if (t?._ripple) {
if (window.clearTimeout(t._ripple.showTimer), e.type === "touchend" && t._ripple.showTimerCommit) {
t._ripple.showTimerCommit(), t._ripple.showTimerCommit = null, t._ripple.showTimer = window.setTimeout(() => {
yt(e);
});
return;
}
window.setTimeout(() => {
t._ripple && (t._ripple.touched = !1);
}), xr.hide(t);
}
}
function Gu(e) {
const t = e.currentTarget;
t?._ripple && (t._ripple.showTimerCommit && (t._ripple.showTimerCommit = null), window.clearTimeout(t._ripple.showTimer));
}
let Va = !1;
function Qu(e) {
!Va && (e.keyCode === ji.enter || e.keyCode === ji.space) && (Va = !0, Ta(e));
}
function qu(e) {
Va = !1, yt(e);
}
function Ku(e) {
Va && (Va = !1, yt(e));
}
function Ju(e, t, n) {
const {
value: a,
modifiers: r
} = t, s = Wu(a);
if (s || xr.hide(e), e._ripple = e._ripple ?? {}, e._ripple.enabled = s, e._ripple.centered = r.center, e._ripple.circle = r.circle, qs(a) && a.class && (e._ripple.class = a.class), s && !n) {
if (r.stop) {
e.addEventListener("touchstart", ho, {
passive: !0
}), e.addEventListener("mousedown", ho);
return;
}
e.addEventListener("touchstart", Ta, {
passive: !0
}), e.addEventListener("touchend", yt, {
passive: !0
}), e.addEventListener("touchmove", Gu, {
passive: !0
}), e.addEventListener("touchcancel", yt), e.addEventListener("mousedown", Ta), e.addEventListener("mouseup", yt), e.addEventListener("mouseleave", yt), e.addEventListener("keydown", Qu), e.addEventListener("keyup", qu), e.addEventListener("blur", Ku), e.addEventListener("dragstart", yt, {
passive: !0
});
} else !s && n && Zu(e);
}
function Zu(e) {
e.removeEventListener("mousedown", Ta), e.removeEventListener("touchstart", Ta), e.removeEventListener("touchend", yt), e.removeEventListener("touchmove", Gu), e.removeEventListener("touchcancel", yt), e.removeEventListener("mouseup", yt), e.removeEventListener("mouseleave", yt), e.removeEventListener("keydown", Qu), e.removeEventListener("keyup", qu), e.removeEventListener("dragstart", yt), e.removeEventListener("blur", Ku);
}
function Vv(e, t) {
Ju(e, t, !1);
}
function Av(e) {
delete e._ripple, Zu(e);
}
function Ev(e, t) {
if (t.value === t.oldValue)
return;
const n = Wu(t.oldValue);
Ju(e, t, n);
}
const sn = {
mounted: Vv,
unmounted: Av,
updated: Ev
}, Qr = M({
label: String,
baseColor: String,
trueValue: null,
falseValue: null,
value: null,
...ce(),
...Ul()
}, "VSelectionControl");
function Dv(e) {
const t = De(Yu, void 0), {
densityClasses: n
} = Wt(e), a = _e(e, "modelValue"), r = _(() => e.trueValue !== void 0 ? e.trueValue : e.value !== void 0 ? e.value : !0), s = _(() => e.falseValue !== void 0 ? e.falseValue : !1), l = _(() => !!e.multiple || e.multiple == null && Array.isArray(a.value)), i = _({
get() {
const v = t ? t.modelValue.value : a.value;
return l.value ? Ke(v).some((m) => e.valueComparator(m, r.value)) : e.valueComparator(v, r.value);
},
set(v) {
if (e.readonly) return;
const m = v ? r.value : s.value;
let y = m;
l.value && (y = v ? [...Ke(a.value), m] : Ke(a.value).filter((h) => !e.valueComparator(h, r.value))), t ? t.modelValue.value = y : a.value = y;
}
}), {
textColorClasses: o,
textColorStyles: u
} = Ht(() => {
if (!(e.error || e.disabled))
return i.value ? e.color : e.baseColor;
}), {
backgroundColorClasses: c,
backgroundColorStyles: d
} = $t(() => i.value && !e.error && !e.disabled ? e.color : e.baseColor), f = _(() => i.value ? e.trueIcon : e.falseIcon);
return {
group: t,
densityClasses: n,
trueValue: r,
falseValue: s,
model: i,
textColorClasses: o,
textColorStyles: u,
backgroundColorClasses: c,
backgroundColorStyles: d,
icon: f
};
}
const Ln = G()({
name: "VSelectionControl",
directives: {
vRipple: sn
},
inheritAttrs: !1,
props: Qr(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
group: r,
densityClasses: s,
icon: l,
model: i,
textColorClasses: o,
textColorStyles: u,
backgroundColorClasses: c,
backgroundColorStyles: d,
trueValue: f
} = Dv(e), v = on(), m = ne(!1), y = ne(!1), h = R(), b = I(() => e.id || `input-${v}`), S = I(() => !e.disabled && !e.readonly);
r?.onForceUpdate(() => {
h.value && (h.value.checked = i.value);
});
function P(V) {
S.value && (m.value = !0, Xn(V.target, ":focus-visible") !== !1 && (y.value = !0));
}
function O() {
m.value = !1, y.value = !1;
}
function k(V) {
V.stopPropagation();
}
function E(V) {
if (!S.value) {
h.value && (h.value.checked = i.value);
return;
}
e.readonly && r && Ge(() => r.forceUpdate()), i.value = V.target.checked;
}
return ee(() => {
const V = a.label ? a.label({
label: e.label,
props: {
for: b.value
}
}) : e.label, [w, T] = Wr(n), L = p("input", j({
ref: h,
checked: i.value,
disabled: !!e.disabled,
id: b.value,
onBlur: O,
onFocus: P,
onInput: E,
"aria-disabled": !!e.disabled,
"aria-label": e.label,
type: e.type,
value: f.value,
name: e.name,
"aria-checked": e.type === "checkbox" ? i.value : void 0
}, T), null);
return p("div", j({
class: ["v-selection-control", {
"v-selection-control--dirty": i.value,
"v-selection-control--disabled": e.disabled,
"v-selection-control--error": e.error,
"v-selection-control--focused": m.value,
"v-selection-control--focus-visible": y.value,
"v-selection-control--inline": e.inline
}, s.value, e.class]
}, w, {
style: e.style
}), [p("div", {
class: Q(["v-selection-control__wrapper", o.value]),
style: J(u.value)
}, [a.default?.({
backgroundColorClasses: c,
backgroundColorStyles: d
}), ht(p("div", {
class: ["v-selection-control__input"]
}, [a.input?.({
model: i,
textColorClasses: o,
textColorStyles: u,
backgroundColorClasses: c,
backgroundColorStyles: d,
inputNode: L,
icon: l.value,
props: {
onFocus: P,
onBlur: O,
id: b.value
}
}) ?? p(pe, null, [l.value && g(Ve, {
key: "icon",
icon: l.value
}, null), L])]), [[sn, e.ripple && [!e.disabled && !e.readonly, null, ["center", "circle"]]]])]), V && g($l, {
for: b.value,
onClick: k
}, {
default: () => [V]
})]);
}), {
isFocused: m,
input: h
};
}
}), Mv = M({
indeterminate: Boolean,
indeterminateIcon: {
type: le,
default: "$checkboxIndeterminate"
},
...Qr({
falseIcon: "$checkboxOff",
trueIcon: "$checkboxOn"
})
}, "VCheckboxBtn"), Ga = G()({
name: "VCheckboxBtn",
props: Mv(),
emits: {
"update:modelValue": (e) => !0,
"update:indeterminate": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const a = _e(e, "indeterminate"), r = _e(e, "modelValue");
function s(o) {
a.value && (a.value = !1);
}
const l = I(() => a.value ? e.indeterminateIcon : e.falseIcon), i = I(() => a.value ? e.indeterminateIcon : e.trueIcon);
return ee(() => {
const o = kn(Ln.filterProps(e), ["modelValue"]);
return g(Ln, j(o, {
modelValue: r.value,
"onUpdate:modelValue": [(u) => r.value = u, s],
class: ["v-checkbox-btn", e.class],
style: e.style,
type: "checkbox",
falseIcon: l.value,
trueIcon: i.value,
"aria-checked": a.value ? "mixed" : void 0
}), n);
}), {};
}
}), Xu = Symbol.for("vuetify:locale");
function hn() {
const e = De(Xu);
if (!e) throw new Error("[Vuetify] Could not find injected locale instance");
return e;
}
function Mt() {
const e = De(Xu);
if (!e) throw new Error("[Vuetify] Could not find injected rtl instance");
return {
isRtl: e.isRtl,
rtlClasses: e.rtlClasses
};
}
function ec(e) {
const {
t
} = hn();
function n(a) {
let {
name: r,
color: s,
...l
} = a;
const i = {
prepend: "prependAction",
prependInner: "prependAction",
append: "appendAction",
appendInner: "appendAction",
clear: "clear"
}[r], o = e[`onClick:${r}`];
function u(d) {
d.key !== "Enter" && d.key !== " " || (d.preventDefault(), d.stopPropagation(), Du(o, new PointerEvent("click", d)));
}
const c = o && i ? t(`$vuetify.input.${i}`, e.label ?? "") : void 0;
return g(Ve, j({
icon: e[`${r}Icon`],
"aria-label": c,
onClick: o,
onKeydown: u,
color: s
}, l), null);
}
return {
InputIcon: n
};
}
const Rv = M({
disabled: Boolean,
group: Boolean,
hideOnLeave: Boolean,
leaveAbsolute: Boolean,
mode: String,
origin: String
}, "transition");
function pt(e, t, n) {
return G()({
name: e,
props: Rv({
mode: n,
origin: t
}),
setup(a, r) {
let {
slots: s
} = r;
const l = {
onBeforeEnter(i) {
a.origin && (i.style.transformOrigin = a.origin);
},
onLeave(i) {
if (a.leaveAbsolute) {
const {
offsetTop: o,
offsetLeft: u,
offsetWidth: c,
offsetHeight: d
} = i;
i._transitionInitialStyles = {
position: i.style.position,
top: i.style.top,
left: i.style.left,
width: i.style.width,
height: i.style.height
}, i.style.position = "absolute", i.style.top = `${o}px`, i.style.left = `${u}px`, i.style.width = `${c}px`, i.style.height = `${d}px`;
}
a.hideOnLeave && i.style.setProperty("display", "none", "important");
},
onAfterLeave(i) {
if (a.leaveAbsolute && i?._transitionInitialStyles) {
const {
position: o,
top: u,
left: c,
width: d,
height: f
} = i._transitionInitialStyles;
delete i._transitionInitialStyles, i.style.position = o || "", i.style.top = u || "", i.style.left = c || "", i.style.width = d || "", i.style.height = f || "";
}
}
};
return () => {
const i = a.group ? _l : Mn;
return aa(i, {
name: a.disabled ? "" : e,
css: !a.disabled,
...a.group ? void 0 : {
mode: a.mode
},
...a.disabled ? {} : l
}, s.default);
};
}
});
}
function tc(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : "in-out";
return G()({
name: e,
props: {
mode: {
type: String,
default: n
},
disabled: Boolean,
group: Boolean
},
setup(a, r) {
let {
slots: s
} = r;
const l = a.group ? _l : Mn;
return () => aa(l, {
name: a.disabled ? "" : e,
css: !a.disabled,
// mode: props.mode, // TODO: vuejs/vue-next#3104
...a.disabled ? {} : t
}, s.default);
}
});
}
function nc() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "";
const n = (arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1) ? "width" : "height", a = Ko(`offset-${n}`);
return {
onBeforeEnter(l) {
l._parent = l.parentNode, l._initialStyle = {
transition: l.style.transition,
overflow: l.style.overflow,
[n]: l.style[n]
};
},
onEnter(l) {
const i = l._initialStyle;
if (!i) return;
l.style.setProperty("transition", "none", "important"), l.style.overflow = "hidden";
const o = `${l[a]}px`;
l.style[n] = "0", l.offsetHeight, l.style.transition = i.transition, e && l._parent && l._parent.classList.add(e), requestAnimationFrame(() => {
l.style[n] = o;
});
},
onAfterEnter: s,
onEnterCancelled: s,
onLeave(l) {
l._initialStyle = {
transition: "",
overflow: l.style.overflow,
[n]: l.style[n]
}, l.style.overflow = "hidden", l.style[n] = `${l[a]}px`, l.offsetHeight, requestAnimationFrame(() => l.style[n] = "0");
},
onAfterLeave: r,
onLeaveCancelled: r
};
function r(l) {
e && l._parent && l._parent.classList.remove(e), s(l);
}
function s(l) {
if (!l._initialStyle) return;
const i = l._initialStyle[n];
l.style.overflow = l._initialStyle.overflow, i != null && (l.style[n] = i), delete l._initialStyle;
}
}
const Fv = M({
target: [Object, Array]
}, "v-dialog-transition"), Ps = /* @__PURE__ */ new WeakMap(), zl = G()({
name: "VDialogTransition",
props: Fv(),
setup(e, t) {
let {
slots: n
} = t;
const a = {
onBeforeEnter(r) {
r.style.pointerEvents = "none", r.style.visibility = "hidden";
},
async onEnter(r, s) {
await new Promise((v) => requestAnimationFrame(v)), await new Promise((v) => requestAnimationFrame(v)), r.style.visibility = "";
const l = vo(e.target, r), {
x: i,
y: o,
sx: u,
sy: c,
speed: d
} = l;
Ps.set(r, l);
const f = Gn(r, [{
transform: `translate(${i}px, ${o}px) scale(${u}, ${c})`,
opacity: 0
}, {}], {
duration: 225 * d,
easing: ov
});
mo(r)?.forEach((v) => {
Gn(v, [{
opacity: 0
}, {
opacity: 0,
offset: 0.33
}, {}], {
duration: 225 * 2 * d,
easing: kr
});
}), f.finished.then(() => s());
},
onAfterEnter(r) {
r.style.removeProperty("pointer-events");
},
onBeforeLeave(r) {
r.style.pointerEvents = "none";
},
async onLeave(r, s) {
await new Promise((v) => requestAnimationFrame(v));
let l;
!Ps.has(r) || Array.isArray(e.target) || e.target.offsetParent || e.target.getClientRects().length ? l = vo(e.target, r) : l = Ps.get(r);
const {
x: i,
y: o,
sx: u,
sy: c,
speed: d
} = l;
Gn(r, [{}, {
transform: `translate(${i}px, ${o}px) scale(${u}, ${c})`,
opacity: 0
}], {
duration: 125 * d,
easing: uv
}).finished.then(() => s()), mo(r)?.forEach((v) => {
Gn(v, [{}, {
opacity: 0,
offset: 0.2
}, {
opacity: 0
}], {
duration: 125 * 2 * d,
easing: kr
});
});
},
onAfterLeave(r) {
r.style.removeProperty("pointer-events");
}
};
return () => e.target ? g(Mn, j({
name: "dialog-transition"
}, a, {
css: !1
}), n) : g(Mn, {
name: "dialog-transition"
}, n);
}
});
function mo(e) {
const t = e.querySelector(":scope > .v-card, :scope > .v-sheet, :scope > .v-list")?.children;
return t && [...t];
}
function vo(e, t) {
const n = Lu(e), a = Rl(t), [r, s] = getComputedStyle(t).transformOrigin.split(" ").map((b) => parseFloat(b)), [l, i] = getComputedStyle(t).getPropertyValue("--v-overlay-anchor-origin").split(" ");
let o = n.left + n.width / 2;
l === "left" || i === "left" ? o -= n.width / 2 : (l === "right" || i === "right") && (o += n.width / 2);
let u = n.top + n.height / 2;
l === "top" || i === "top" ? u -= n.height / 2 : (l === "bottom" || i === "bottom") && (u += n.height / 2);
const c = n.width / a.width, d = n.height / a.height, f = Math.max(1, c, d), v = c / f || 0, m = d / f || 0, y = a.width * a.height / (window.innerWidth * window.innerHeight), h = y > 0.12 ? Math.min(1.5, (y - 0.12) * 10 + 1) : 1;
return {
x: o - (r + a.left),
y: u - (s + a.top),
sx: v,
sy: m,
speed: h
};
}
pt("fab-transition", "center center", "out-in");
pt("dialog-bottom-transition");
pt("dialog-top-transition");
const yo = pt("fade-transition"), Lv = pt("scale-transition");
pt("scroll-x-transition");
pt("scroll-x-reverse-transition");
pt("scroll-y-transition");
pt("scroll-y-reverse-transition");
pt("slide-x-transition");
pt("slide-x-reverse-transition");
const ac = pt("slide-y-transition");
pt("slide-y-reverse-transition");
const rc = tc("expand-transition", nc()), sc = tc("expand-x-transition", nc("", !0)), Nv = M({
active: Boolean,
color: String,
messages: {
type: [Array, String],
default: () => []
},
...ce(),
...ia({
transition: {
component: ac,
leaveAbsolute: !0,
group: !0
}
})
}, "VMessages"), Bv = G()({
name: "VMessages",
props: Nv(),
setup(e, t) {
let {
slots: n
} = t;
const a = _(() => Ke(e.messages)), {
textColorClasses: r,
textColorStyles: s
} = Ht(() => e.color);
return ee(() => g(gn, {
transition: e.transition,
tag: "div",
class: Q(["v-messages", r.value, e.class]),
style: J([s.value, e.style])
}, {
default: () => [e.active && a.value.map((l, i) => p("div", {
class: "v-messages__message",
key: `${i}-${a.value}`
}, [n.message ? n.message({
message: l
}) : l]))]
})), {};
}
}), lc = M({
focused: Boolean,
"onUpdate:focused": Je()
}, "focus");
function Hl(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
const n = _e(e, "focused"), a = I(() => ({
[`${t}--focused`]: n.value
}));
function r() {
n.value = !0;
}
function s() {
n.value = !1;
}
return {
focusClasses: a,
isFocused: n,
focus: r,
blur: s
};
}
const ic = Symbol.for("vuetify:form"), $v = M({
disabled: Boolean,
fastFail: Boolean,
readonly: Boolean,
modelValue: {
type: Boolean,
default: null
},
validateOn: {
type: String,
default: "input"
}
}, "form");
function Uv(e) {
const t = _e(e, "modelValue"), n = I(() => e.disabled), a = I(() => e.readonly), r = ne(!1), s = R([]), l = R([]);
async function i() {
const c = [];
let d = !0;
l.value = [], r.value = !0;
for (const f of s.value) {
const v = await f.validate();
if (v.length > 0 && (d = !1, c.push({
id: f.id,
errorMessages: v
})), !d && e.fastFail) break;
}
return l.value = c, r.value = !1, {
valid: d,
errors: l.value
};
}
function o() {
s.value.forEach((c) => c.reset());
}
function u() {
s.value.forEach((c) => c.resetValidation());
}
return re(s, () => {
let c = 0, d = 0;
const f = [];
for (const v of s.value)
v.isValid === !1 ? (d++, f.push({
id: v.id,
errorMessages: v.errorMessages
})) : v.isValid === !0 && c++;
l.value = f, t.value = d > 0 ? !1 : c === s.value.length ? !0 : null;
}, {
deep: !0,
flush: "post"
}), We(ic, {
register: (c) => {
let {
id: d,
vm: f,
validate: v,
reset: m,
resetValidation: y
} = c;
s.value.some((h) => h.id === d) && Sn(`Duplicate input name "${d}"`), s.value.push({
id: d,
validate: v,
reset: m,
resetValidation: y,
vm: Rf(f),
isValid: null,
errorMessages: []
});
},
unregister: (c) => {
s.value = s.value.filter((d) => d.id !== c);
},
update: (c, d, f) => {
const v = s.value.find((m) => m.id === c);
v && (v.isValid = d, v.errorMessages = f);
},
isDisabled: n,
isReadonly: a,
isValidating: r,
isValid: t,
items: s,
validateOn: I(() => e.validateOn)
}), {
errors: l,
isDisabled: n,
isReadonly: a,
isValidating: r,
isValid: t,
items: s,
validate: i,
reset: o,
resetValidation: u
};
}
function Yl(e) {
const t = De(ic, null);
return {
...t,
isReadonly: _(() => !!(e?.readonly ?? t?.isReadonly.value)),
isDisabled: _(() => !!(e?.disabled ?? t?.isDisabled.value))
};
}
const zv = Symbol.for("vuetify:rules");
function Hv(e) {
const t = De(zv, null);
return t ? t(e) : I(e);
}
const Yv = M({
disabled: {
type: Boolean,
default: null
},
error: Boolean,
errorMessages: {
type: [Array, String],
default: () => []
},
maxErrors: {
type: [Number, String],
default: 1
},
name: String,
label: String,
readonly: {
type: Boolean,
default: null
},
rules: {
type: Array,
default: () => []
},
modelValue: null,
validateOn: String,
validationValue: null,
...lc()
}, "validation");
function jv(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt(), n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : on();
const a = _e(e, "modelValue"), r = _(() => e.validationValue === void 0 ? a.value : e.validationValue), s = Yl(e), l = Hv(() => e.rules), i = R([]), o = ne(!0), u = _(() => !!(Ke(a.value === "" ? null : a.value).length || Ke(r.value === "" ? null : r.value).length)), c = _(() => e.errorMessages?.length ? Ke(e.errorMessages).concat(i.value).slice(0, Math.max(0, Number(e.maxErrors))) : i.value), d = _(() => {
let O = (e.validateOn ?? s.validateOn?.value) || "input";
O === "lazy" && (O = "input lazy"), O === "eager" && (O = "input eager");
const k = new Set(O?.split(" ") ?? []);
return {
input: k.has("input"),
blur: k.has("blur") || k.has("input") || k.has("invalid-input"),
invalidInput: k.has("invalid-input"),
lazy: k.has("lazy"),
eager: k.has("eager")
};
}), f = _(() => e.error || e.errorMessages?.length ? !1 : e.rules.length ? o.value ? i.value.length || d.value.lazy ? null : !0 : !i.value.length : !0), v = ne(!1), m = _(() => ({
[`${t}--error`]: f.value === !1,
[`${t}--dirty`]: u.value,
[`${t}--disabled`]: s.isDisabled.value,
[`${t}--readonly`]: s.isReadonly.value
})), y = Ue("validation"), h = _(() => e.name ?? _t(n));
Lr(() => {
s.register?.({
id: h.value,
vm: y,
validate: P,
reset: b,
resetValidation: S
});
}), At(() => {
s.unregister?.(h.value);
}), Ba(async () => {
d.value.lazy || await P(!d.value.eager), s.update?.(h.value, f.value, c.value);
}), Fn(() => d.value.input || d.value.invalidInput && f.value === !1, () => {
re(r, () => {
if (r.value != null)
P();
else if (e.focused) {
const O = re(() => e.focused, (k) => {
k || P(), O();
});
}
});
}), Fn(() => d.value.blur, () => {
re(() => e.focused, (O) => {
O || P();
});
}), re([f, c], () => {
s.update?.(h.value, f.value, c.value);
});
async function b() {
a.value = null, await Ge(), await S();
}
async function S() {
o.value = !0, d.value.lazy ? i.value = [] : await P(!d.value.eager);
}
async function P() {
let O = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
const k = [];
v.value = !0;
for (const E of l.value) {
if (k.length >= Number(e.maxErrors ?? 1))
break;
const w = await (typeof E == "function" ? E : () => E)(r.value);
if (w !== !0) {
if (w !== !1 && typeof w != "string") {
console.warn(`${w} is not a valid value. Rule functions must return boolean true or a string.`);
continue;
}
k.push(w || "");
}
}
return i.value = k, v.value = !1, o.value = O, i.value;
}
return {
errorMessages: c,
isDirty: u,
isDisabled: s.isDisabled,
isReadonly: s.isReadonly,
isPristine: o,
isValid: f,
isValidating: v,
reset: b,
resetValidation: S,
validate: P,
validationClasses: m
};
}
const qr = M({
id: String,
appendIcon: le,
baseColor: String,
centerAffix: {
type: Boolean,
default: !0
},
color: String,
glow: Boolean,
iconColor: [Boolean, String],
prependIcon: le,
hideDetails: [Boolean, String],
hideSpinButtons: Boolean,
hint: String,
persistentHint: Boolean,
messages: {
type: [Array, String],
default: () => []
},
direction: {
type: String,
default: "horizontal",
validator: (e) => ["horizontal", "vertical"].includes(e)
},
"onClick:prepend": Je(),
"onClick:append": Je(),
...ce(),
...Ct(),
...jr(un(), ["maxWidth", "minWidth", "width"]),
...Ye(),
...Yv()
}, "VInput"), ea = G()({
name: "VInput",
props: {
...qr()
},
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a,
emit: r
} = t;
const {
densityClasses: s
} = Wt(e), {
dimensionStyles: l
} = cn(e), {
themeClasses: i
} = Ze(e), {
rtlClasses: o
} = Mt(), {
InputIcon: u
} = ec(e), c = on(), d = _(() => e.id || `input-${c}`), f = _(() => `${d.value}-messages`), {
errorMessages: v,
isDirty: m,
isDisabled: y,
isReadonly: h,
isPristine: b,
isValid: S,
isValidating: P,
reset: O,
resetValidation: k,
validate: E,
validationClasses: V
} = jv(e, "v-input", d), w = _(() => ({
id: d,
messagesId: f,
isDirty: m,
isDisabled: y,
isReadonly: h,
isPristine: b,
isValid: S,
isValidating: P,
reset: O,
resetValidation: k,
validate: E
})), T = I(() => e.error || e.disabled ? void 0 : e.focused ? e.color : e.baseColor), L = I(() => {
if (e.iconColor)
return e.iconColor === !0 ? T.value : e.iconColor;
}), $ = _(() => e.errorMessages?.length || !b.value && v.value.length ? v.value : e.hint && (e.persistentHint || e.focused) ? e.hint : e.messages);
return ee(() => {
const B = !!(a.prepend || e.prependIcon), D = !!(a.append || e.appendIcon), H = $.value.length > 0, Y = !e.hideDetails || e.hideDetails === "auto" && (H || !!a.details);
return p("div", {
class: Q(["v-input", `v-input--${e.direction}`, {
"v-input--center-affix": e.centerAffix,
"v-input--focused": e.focused,
"v-input--glow": e.glow,
"v-input--hide-spin-buttons": e.hideSpinButtons
}, s.value, i.value, o.value, V.value, e.class]),
style: J([l.value, e.style])
}, [B && p("div", {
key: "prepend",
class: "v-input__prepend"
}, [a.prepend?.(w.value), e.prependIcon && g(u, {
key: "prepend-icon",
name: "prepend",
color: L.value
}, null)]), a.default && p("div", {
class: "v-input__control"
}, [a.default?.(w.value)]), D && p("div", {
key: "append",
class: "v-input__append"
}, [e.appendIcon && g(u, {
key: "append-icon",
name: "append",
color: L.value
}, null), a.append?.(w.value)]), Y && p("div", {
id: f.value,
class: "v-input__details",
role: "alert",
"aria-live": "polite"
}, [g(Bv, {
active: H,
messages: $.value
}, {
message: a.message
}), a.details?.(w.value)])]);
}), {
reset: O,
resetValidation: k,
validate: E,
isValid: S,
errorMessages: v
};
}
}), Kr = ["sm", "md", "lg", "xl", "xxl"], Wv = Symbol.for("vuetify:display"), Jr = M({
mobile: {
type: Boolean,
default: !1
},
mobileBreakpoint: [Number, String]
}, "display");
function $n() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {
mobile: null
}, t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
const n = De(Wv);
if (!n) throw new Error("Could not find Vuetify display injection");
const a = _(() => e.mobile ? !0 : typeof e.mobileBreakpoint == "number" ? n.width.value < e.mobileBreakpoint : e.mobileBreakpoint ? n.width.value < n.thresholds.value[e.mobileBreakpoint] : e.mobile === null ? n.mobile.value : !1), r = I(() => t ? {
[`${t}--mobile`]: a.value
} : {});
return {
...n,
displayClasses: r,
mobile: a
};
}
const Gv = Symbol.for("vuetify:goto");
function Qv() {
return {
container: void 0,
duration: 300,
layout: !1,
offset: 0,
easing: "easeInOutCubic",
patterns: {
linear: (e) => e,
easeInQuad: (e) => e ** 2,
easeOutQuad: (e) => e * (2 - e),
easeInOutQuad: (e) => e < 0.5 ? 2 * e ** 2 : -1 + (4 - 2 * e) * e,
easeInCubic: (e) => e ** 3,
easeOutCubic: (e) => --e ** 3 + 1,
easeInOutCubic: (e) => e < 0.5 ? 4 * e ** 3 : (e - 1) * (2 * e - 2) * (2 * e - 2) + 1,
easeInQuart: (e) => e ** 4,
easeOutQuart: (e) => 1 - --e ** 4,
easeInOutQuart: (e) => e < 0.5 ? 8 * e ** 4 : 1 - 8 * --e ** 4,
easeInQuint: (e) => e ** 5,
easeOutQuint: (e) => 1 + --e ** 5,
easeInOutQuint: (e) => e < 0.5 ? 16 * e ** 5 : 1 + 16 * --e ** 5
}
};
}
function qv(e) {
return jl(e) ?? (document.scrollingElement || document.body);
}
function jl(e) {
return typeof e == "string" ? document.querySelector(e) : Tu(e);
}
function xs(e, t, n) {
if (typeof e == "number") return t && n ? -e : e;
let a = jl(e), r = 0;
for (; a; )
r += t ? a.offsetLeft : a.offsetTop, a = a.offsetParent;
return r;
}
async function go(e, t, n, a) {
const r = n ? "scrollLeft" : "scrollTop", s = Xt(a?.options ?? Qv(), t), l = a?.rtl.value, i = (typeof e == "number" ? e : jl(e)) ?? 0, o = s.container === "parent" && i instanceof HTMLElement ? i.parentElement : qv(s.container), u = typeof s.easing == "function" ? s.easing : s.patterns[s.easing];
if (!u) throw new TypeError(`Easing function "${s.easing}" not found.`);
let c;
if (typeof i == "number")
c = xs(i, n, l);
else if (c = xs(i, n, l) - xs(o, n, l), s.layout) {
const m = window.getComputedStyle(i).getPropertyValue("--v-layout-top");
m && (c -= parseInt(m, 10));
}
c += s.offset, c = Jv(o, c, !!l, !!n);
const d = o[r] ?? 0;
if (c === d) return Promise.resolve(c);
const f = performance.now();
return new Promise((v) => requestAnimationFrame(function m(y) {
const b = (y - f) / s.duration, S = Math.floor(d + (c - d) * u(bt(b, 0, 1)));
if (o[r] = S, b >= 1 && Math.abs(S - o[r]) < 10)
return v(c);
if (b > 2)
return Sn("Scroll target is not reachable"), v(o[r]);
requestAnimationFrame(m);
}));
}
function Kv() {
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
const t = De(Gv), {
isRtl: n
} = Mt();
if (!t) throw new Error("[Vuetify] Could not find injected goto instance");
const a = {
...t,
// can be set via VLocaleProvider
rtl: I(() => t.rtl.value || n.value)
};
async function r(s, l) {
return go(s, Xt(e, l), !1, a);
}
return r.horizontal = async (s, l) => go(s, Xt(e, l), !0, a), r;
}
function Jv(e, t, n, a) {
const {
scrollWidth: r,
scrollHeight: s
} = e, [l, i] = e === document.scrollingElement ? [window.innerWidth, window.innerHeight] : [e.offsetWidth, e.offsetHeight];
let o, u;
return a ? n ? (o = -(r - l), u = 0) : (o = 0, u = r - l) : (o = 0, u = s + -i), bt(t, o, u);
}
const Wl = M({
modelValue: {
type: null,
default: void 0
},
multiple: Boolean,
mandatory: [Boolean, String],
max: Number,
selectedClass: String,
disabled: Boolean
}, "group"), oc = M({
value: null,
disabled: Boolean,
selectedClass: String
}, "group-item");
function uc(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : !0;
const a = Ue("useGroupItem");
if (!a)
throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");
const r = on();
We(Symbol.for(`${t.description}:id`), r);
const s = De(t, null);
if (!s) {
if (!n) return s;
throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`);
}
const l = I(() => e.value), i = _(() => !!(s.disabled.value || e.disabled));
s.register({
id: r,
value: l,
disabled: i
}, a), At(() => {
s.unregister(r);
});
const o = _(() => s.isSelected(r)), u = _(() => s.items.value[0].id === r), c = _(() => s.items.value[s.items.value.length - 1].id === r), d = _(() => o.value && [s.selectedClass.value, e.selectedClass]);
return re(o, (f) => {
a.emit("group:selected", {
value: f
});
}, {
flush: "sync"
}), {
id: r,
isSelected: o,
isFirst: u,
isLast: c,
toggle: () => s.select(r, !o.value),
select: (f) => s.select(r, f),
selectedClass: d,
value: l,
disabled: i,
group: s
};
}
function Gl(e, t) {
let n = !1;
const a = Zn([]), r = _e(e, "modelValue", [], (f) => f == null ? [] : cc(a, Ke(f)), (f) => {
const v = Xv(a, f);
return e.multiple ? v : v[0];
}), s = Ue("useGroup");
function l(f, v) {
const m = f, y = Symbol.for(`${t.description}:id`), b = Sa(y, s?.vnode).indexOf(v);
_t(m.value) == null && (m.value = b, m.useIndexAsValue = !0), b > -1 ? a.splice(b, 0, m) : a.push(m);
}
function i(f) {
if (n) return;
o();
const v = a.findIndex((m) => m.id === f);
a.splice(v, 1);
}
function o() {
const f = a.find((v) => !v.disabled);
f && e.mandatory === "force" && !r.value.length && (r.value = [f.id]);
}
Ba(() => {
o();
}), At(() => {
n = !0;
}), Ff(() => {
for (let f = 0; f < a.length; f++)
a[f].useIndexAsValue && (a[f].value = f);
});
function u(f, v) {
const m = a.find((y) => y.id === f);
if (!(v && m?.disabled))
if (e.multiple) {
const y = r.value.slice(), h = y.findIndex((S) => S === f), b = ~h;
if (v = v ?? !b, b && e.mandatory && y.length <= 1 || !b && e.max != null && y.length + 1 > e.max) return;
h < 0 && v ? y.push(f) : h >= 0 && !v && y.splice(h, 1), r.value = y;
} else {
const y = r.value.includes(f);
if (e.mandatory && y) return;
r.value = v ?? !y ? [f] : [];
}
}
function c(f) {
if (e.multiple && Sn('This method is not supported when using "multiple" prop'), r.value.length) {
const v = r.value[0], m = a.findIndex((b) => b.id === v);
let y = (m + f) % a.length, h = a[y];
for (; h.disabled && y !== m; )
y = (y + f) % a.length, h = a[y];
if (h.disabled) return;
r.value = [a[y].id];
} else {
const v = a.find((m) => !m.disabled);
v && (r.value = [v.id]);
}
}
const d = {
register: l,
unregister: i,
selected: r,
select: u,
disabled: I(() => e.disabled),
prev: () => c(a.length - 1),
next: () => c(1),
isSelected: (f) => r.value.includes(f),
selectedClass: I(() => e.selectedClass),
items: I(() => a),
getItemIndex: (f) => Zv(a, f)
};
return We(t, d), d;
}
function Zv(e, t) {
const n = cc(e, [t]);
return n.length ? e.findIndex((a) => a.id === n[0]) : -1;
}
function cc(e, t) {
const n = [];
return t.forEach((a) => {
const r = e.find((l) => gt(a, l.value)), s = e[a];
r?.value != null ? n.push(r.id) : s != null && n.push(s.id);
}), n;
}
function Xv(e, t) {
const n = [];
return t.forEach((a) => {
const r = e.findIndex((s) => s.id === a);
if (~r) {
const s = e[r];
n.push(s.value != null ? s.value : r);
}
}), n;
}
function ta(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "content";
const n = Ks(), a = R();
if (Be) {
const r = new ResizeObserver((s) => {
e?.(s, r), s.length && (t === "content" ? a.value = s[0].contentRect : a.value = s[0].target.getBoundingClientRect());
});
At(() => {
r.disconnect();
}), re(() => n.el, (s, l) => {
l && (r.unobserve(l), a.value = void 0), s && r.observe(s);
}, {
flush: "post"
});
}
return {
resizeRef: n,
contentRect: Cl(a)
};
}
function ey(e) {
let {
selectedElement: t,
containerElement: n,
isRtl: a,
isHorizontal: r
} = e;
const s = Aa(r, n), l = dc(r, a, n), i = Aa(r, t), o = fc(r, t), u = i * 0.4;
return l > o ? o - u : l + s < o + i ? o - s + i + u : l;
}
function ty(e) {
let {
selectedElement: t,
containerElement: n,
isHorizontal: a
} = e;
const r = Aa(a, n), s = fc(a, t), l = Aa(a, t);
return s - r / 2 + l / 2;
}
function bo(e, t) {
return t?.[e ? "scrollWidth" : "scrollHeight"] || 0;
}
function ny(e, t) {
return t?.[e ? "clientWidth" : "clientHeight"] || 0;
}
function dc(e, t, n) {
if (!n)
return 0;
const {
scrollLeft: a,
offsetWidth: r,
scrollWidth: s
} = n;
return e ? t ? s - r + a : a : n.scrollTop;
}
function Aa(e, t) {
return t?.[e ? "offsetWidth" : "offsetHeight"] || 0;
}
function fc(e, t) {
return t?.[e ? "offsetLeft" : "offsetTop"] || 0;
}
const ay = Symbol.for("vuetify:v-slide-group"), hc = M({
centerActive: Boolean,
direction: {
type: String,
default: "horizontal"
},
symbol: {
type: null,
default: ay
},
nextIcon: {
type: le,
default: "$next"
},
prevIcon: {
type: le,
default: "$prev"
},
showArrows: {
type: [Boolean, String],
validator: (e) => typeof e == "boolean" || ["always", "desktop", "mobile"].includes(e)
},
...ce(),
...Jr({
mobile: null
}),
...Le(),
...Wl({
selectedClass: "v-slide-group-item--active"
})
}, "VSlideGroup"), po = G()({
name: "VSlideGroup",
props: hc(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
isRtl: a
} = Mt(), {
displayClasses: r,
mobile: s
} = $n(e), l = Gl(e, e.symbol), i = ne(!1), o = ne(0), u = ne(0), c = ne(0), d = _(() => e.direction === "horizontal"), {
resizeRef: f,
contentRect: v
} = ta(), {
resizeRef: m,
contentRect: y
} = ta(), h = Kv(), b = _(() => ({
container: f.el,
duration: 200,
easing: "easeOutQuart"
})), S = _(() => l.selected.value.length ? l.items.value.findIndex((A) => A.id === l.selected.value[0]) : -1), P = _(() => l.selected.value.length ? l.items.value.findIndex((A) => A.id === l.selected.value[l.selected.value.length - 1]) : -1);
if (Be) {
let A = -1;
re(() => [l.selected.value, v.value, y.value, d.value], () => {
cancelAnimationFrame(A), A = requestAnimationFrame(() => {
if (v.value && y.value) {
const N = d.value ? "width" : "height";
u.value = v.value[N], c.value = y.value[N], i.value = u.value + 1 < c.value;
}
if (S.value >= 0 && m.el) {
const N = m.el.children[P.value];
k(N, e.centerActive);
}
});
});
}
const O = ne(!1);
function k(A, N) {
let q = 0;
N ? q = ty({
containerElement: f.el,
isHorizontal: d.value,
selectedElement: A
}) : q = ey({
containerElement: f.el,
isHorizontal: d.value,
isRtl: a.value,
selectedElement: A
}), E(q);
}
function E(A) {
if (!Be || !f.el) return;
const N = Aa(d.value, f.el), q = dc(d.value, a.value, f.el);
if (!(bo(d.value, f.el) <= N || // Prevent scrolling by only a couple of pixels, which doesn't look smooth
Math.abs(A - q) < 16)) {
if (d.value && a.value && f.el) {
const {
scrollWidth: ae,
offsetWidth: se
} = f.el;
A = ae - se - A;
}
d.value ? h.horizontal(A, b.value) : h(A, b.value);
}
}
function V(A) {
const {
scrollTop: N,
scrollLeft: q
} = A.target;
o.value = d.value ? q : N;
}
function w(A) {
if (O.value = !0, !(!i.value || !m.el)) {
for (const N of A.composedPath())
for (const q of m.el.children)
if (q === N) {
k(q);
return;
}
}
}
function T(A) {
O.value = !1;
}
let L = !1;
function $(A) {
!L && !O.value && !(A.relatedTarget && m.el?.contains(A.relatedTarget)) && Y(), L = !1;
}
function B() {
L = !0;
}
function D(A) {
if (!m.el) return;
function N(q) {
A.preventDefault(), Y(q);
}
d.value ? A.key === "ArrowRight" ? N(a.value ? "prev" : "next") : A.key === "ArrowLeft" && N(a.value ? "next" : "prev") : A.key === "ArrowDown" ? N("next") : A.key === "ArrowUp" && N("prev"), A.key === "Home" ? N("first") : A.key === "End" && N("last");
}
function H(A, N) {
if (!A) return;
let q = A;
do
q = q?.[N === "next" ? "nextElementSibling" : "previousElementSibling"];
while (q?.hasAttribute("disabled"));
return q;
}
function Y(A) {
if (!m.el) return;
let N;
if (!A)
N = Ia(m.el)[0];
else if (A === "next") {
if (N = H(m.el.querySelector(":focus"), A), !N) return Y("first");
} else if (A === "prev") {
if (N = H(m.el.querySelector(":focus"), A), !N) return Y("last");
} else A === "first" ? (N = m.el.firstElementChild, N?.hasAttribute("disabled") && (N = H(N, "next"))) : A === "last" && (N = m.el.lastElementChild, N?.hasAttribute("disabled") && (N = H(N, "prev")));
N && N.focus({
preventScroll: !0
});
}
function X(A) {
const N = d.value && a.value ? -1 : 1, q = (A === "prev" ? -N : N) * u.value;
let ie = o.value + q;
if (d.value && a.value && f.el) {
const {
scrollWidth: ae,
offsetWidth: se
} = f.el;
ie += ae - se;
}
E(ie);
}
const oe = _(() => ({
next: l.next,
prev: l.prev,
select: l.select,
isSelected: l.isSelected
})), ge = _(() => {
switch (e.showArrows) {
// Always show arrows on desktop & mobile
case "always":
return !0;
// Always show arrows on desktop
case "desktop":
return !s.value;
// Show arrows on mobile when overflowing.
// This matches the default 2.2 behavior
case !0:
return i.value || Math.abs(o.value) > 0;
// Always show on mobile
case "mobile":
return s.value || i.value || Math.abs(o.value) > 0;
// https://material.io/components/tabs#scrollable-tabs
// Always show arrows when
// overflowed on desktop
default:
return !s.value && (i.value || Math.abs(o.value) > 0);
}
}), Ie = _(() => Math.abs(o.value) > 1), x = _(() => {
if (!f.value) return !1;
const A = bo(d.value, f.el), N = ny(d.value, f.el);
return A - N - Math.abs(o.value) > 1;
});
return ee(() => g(e.tag, {
class: Q(["v-slide-group", {
"v-slide-group--vertical": !d.value,
"v-slide-group--has-affixes": ge.value,
"v-slide-group--is-overflowing": i.value
}, r.value, e.class]),
style: J(e.style),
tabindex: O.value || l.selected.value.length ? -1 : 0,
onFocus: $
}, {
default: () => [ge.value && p("div", {
key: "prev",
class: Q(["v-slide-group__prev", {
"v-slide-group__prev--disabled": !Ie.value
}]),
onMousedown: B,
onClick: () => Ie.value && X("prev")
}, [n.prev?.(oe.value) ?? g(yo, null, {
default: () => [g(Ve, {
icon: a.value ? e.nextIcon : e.prevIcon
}, null)]
})]), p("div", {
key: "container",
ref: f,
class: "v-slide-group__container",
onScroll: V
}, [p("div", {
ref: m,
class: "v-slide-group__content",
onFocusin: w,
onFocusout: T,
onKeydown: D
}, [n.default?.(oe.value)])]), ge.value && p("div", {
key: "next",
class: Q(["v-slide-group__next", {
"v-slide-group__next--disabled": !x.value
}]),
onMousedown: B,
onClick: () => x.value && X("next")
}, [n.next?.(oe.value) ?? g(yo, null, {
default: () => [g(Ve, {
icon: a.value ? e.prevIcon : e.nextIcon
}, null)]
})])]
})), {
selected: l.selected,
scrollTo: X,
scrollOffset: o,
focus: Y,
hasPrev: Ie,
hasNext: x
};
}
}), mc = Symbol.for("vuetify:v-chip-group"), ry = M({
baseColor: String,
column: Boolean,
filter: Boolean,
valueComparator: {
type: Function,
default: gt
},
...hc(),
...ce(),
...Wl({
selectedClass: "v-chip--selected"
}),
...Le(),
...Ye(),
...fn({
variant: "tonal"
})
}, "VChipGroup");
G()({
name: "VChipGroup",
props: ry(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
themeClasses: a
} = Ze(e), {
isSelected: r,
select: s,
next: l,
prev: i,
selected: o
} = Gl(e, mc);
return zt({
VChip: {
baseColor: I(() => e.baseColor),
color: I(() => e.color),
disabled: I(() => e.disabled),
filter: I(() => e.filter),
variant: I(() => e.variant)
}
}), ee(() => {
const u = po.filterProps(e);
return g(po, j(u, {
class: ["v-chip-group", {
"v-chip-group--column": e.column
}, a.value, e.class],
style: e.style
}), {
default: () => [n.default?.({
isSelected: r,
select: s,
next: l,
prev: i,
selected: o.value
})]
});
}), {};
}
});
const Pn = M({
elevation: {
type: [Number, String],
validator(e) {
const t = parseInt(e);
return !isNaN(t) && t >= 0 && // Material Design has a maximum elevation of 24
// https://material.io/design/environment/elevation.html#default-elevations
t <= 24;
}
}
}, "elevation");
function Un(e) {
return {
elevationClasses: I(() => {
const n = $s(e) ? e.value : e.elevation;
return n == null ? [] : [`elevation-${n}`];
})
};
}
function sy() {
const e = Ue("useRoute");
return _(() => e?.proxy?.$route);
}
function ly() {
return Ue("useRouter")?.proxy?.$router;
}
function Zr(e, t) {
const n = Lf("RouterLink"), a = I(() => !!(e.href || e.to)), r = _(() => a?.value || qi(t, "click") || qi(e, "click"));
if (typeof n == "string" || !("useLink" in n)) {
const c = I(() => e.href);
return {
isLink: a,
isClickable: r,
href: c,
linkProps: Zn({
href: c
})
};
}
const s = n.useLink({
to: I(() => e.to || ""),
replace: I(() => e.replace)
}), l = _(() => e.to ? s : void 0), i = sy(), o = _(() => l.value ? e.exact ? i.value ? l.value.isExactActive?.value && gt(l.value.route.value.query, i.value.query) : l.value.isExactActive?.value ?? !1 : l.value.isActive?.value ?? !1 : !1), u = _(() => e.to ? l.value?.route.value.href : e.href);
return {
isLink: a,
isClickable: r,
isActive: o,
route: l.value?.route,
navigate: l.value?.navigate,
href: u,
linkProps: Zn({
href: u,
"aria-current": I(() => o.value ? "page" : void 0)
})
};
}
const Xr = M({
href: String,
replace: Boolean,
to: [String, Object],
exact: Boolean
}, "router");
let Is = !1;
function iy(e, t) {
let n = !1, a, r;
Be && e?.beforeEach && (Ge(() => {
window.addEventListener("popstate", s), a = e.beforeEach((l, i, o) => {
Is ? n ? t(o) : o() : setTimeout(() => n ? t(o) : o()), Is = !0;
}), r = e?.afterEach(() => {
Is = !1;
});
}), mt(() => {
window.removeEventListener("popstate", s), a?.(), r?.();
}));
function s(l) {
l.state?.replaced || (n = !0, setTimeout(() => n = !1));
}
}
const oy = M({
activeClass: String,
appendAvatar: String,
appendIcon: le,
baseColor: String,
closable: Boolean,
closeIcon: {
type: le,
default: "$delete"
},
closeLabel: {
type: String,
default: "$vuetify.close"
},
draggable: Boolean,
filter: Boolean,
filterIcon: {
type: le,
default: "$complete"
},
label: Boolean,
link: {
type: Boolean,
default: void 0
},
pill: Boolean,
prependAvatar: String,
prependIcon: le,
ripple: {
type: [Boolean, Object],
default: !0
},
text: {
type: [String, Number, Boolean],
default: void 0
},
modelValue: {
type: Boolean,
default: !0
},
onClick: Je(),
onClickOnce: Je(),
...dn(),
...ce(),
...Ct(),
...Pn(),
...oc(),
...kt(),
...Xr(),
...la(),
...Le({
tag: "span"
}),
...Ye(),
...fn({
variant: "tonal"
})
}, "VChip"), Ql = G()({
name: "VChip",
directives: {
vRipple: sn
},
props: oy(),
emits: {
"click:close": (e) => !0,
"update:modelValue": (e) => !0,
"group:selected": (e) => !0,
click: (e) => !0
},
setup(e, t) {
let {
attrs: n,
emit: a,
slots: r
} = t;
const {
t: s
} = hn(), {
borderClasses: l
} = Cn(e), {
densityClasses: i
} = Wt(e), {
elevationClasses: o
} = Un(e), {
roundedClasses: u
} = Dt(e), {
sizeClasses: c
} = Ya(e), {
themeClasses: d
} = Ze(e), f = _e(e, "modelValue"), v = uc(e, mc, !1), m = Zr(e, n), y = I(() => e.link !== !1 && m.isLink.value), h = _(() => !e.disabled && e.link !== !1 && (!!v || e.link || m.isClickable.value)), b = I(() => ({
"aria-label": s(e.closeLabel),
onClick(V) {
V.preventDefault(), V.stopPropagation(), f.value = !1, a("click:close", V);
}
})), {
colorClasses: S,
colorStyles: P,
variantClasses: O
} = Wa(() => ({
color: !v || v.isSelected.value ? e.color ?? e.baseColor : e.baseColor,
variant: e.variant
}));
function k(V) {
a("click", V), h.value && (m.navigate?.(V), v?.toggle());
}
function E(V) {
(V.key === "Enter" || V.key === " ") && (V.preventDefault(), k(V));
}
return () => {
const V = m.isLink.value ? "a" : e.tag, w = !!(e.appendIcon || e.appendAvatar), T = !!(w || r.append), L = !!(r.close || e.closable), $ = !!(r.filter || e.filter) && v, B = !!(e.prependIcon || e.prependAvatar), D = !!(B || r.prepend);
return f.value && ht(g(V, j({
class: ["v-chip", {
"v-chip--disabled": e.disabled,
"v-chip--label": e.label,
"v-chip--link": h.value,
"v-chip--filter": $,
"v-chip--pill": e.pill,
[`${e.activeClass}`]: e.activeClass && m.isActive?.value
}, d.value, l.value, S.value, i.value, o.value, u.value, c.value, O.value, v?.selectedClass.value, e.class],
style: [P.value, e.style],
disabled: e.disabled || void 0,
draggable: e.draggable,
tabindex: h.value ? 0 : void 0,
onClick: k,
onKeydown: h.value && !y.value && E
}, m.linkProps), {
default: () => [ja(h.value, "v-chip"), $ && g(sc, {
key: "filter"
}, {
default: () => [ht(p("div", {
class: "v-chip__filter"
}, [r.filter ? g(Ne, {
key: "filter-defaults",
disabled: !e.filterIcon,
defaults: {
VIcon: {
icon: e.filterIcon
}
}
}, r.filter) : g(Ve, {
key: "filter-icon",
icon: e.filterIcon
}, null)]), [[Bn, v.isSelected.value]])]
}), D && p("div", {
key: "prepend",
class: "v-chip__prepend"
}, [r.prepend ? g(Ne, {
key: "prepend-defaults",
disabled: !B,
defaults: {
VAvatar: {
image: e.prependAvatar,
start: !0
},
VIcon: {
icon: e.prependIcon,
start: !0
}
}
}, r.prepend) : p(pe, null, [e.prependIcon && g(Ve, {
key: "prepend-icon",
icon: e.prependIcon,
start: !0
}, null), e.prependAvatar && g(_n, {
key: "prepend-avatar",
image: e.prependAvatar,
start: !0
}, null)])]), p("div", {
class: "v-chip__content",
"data-no-activator": ""
}, [r.default?.({
isSelected: v?.isSelected.value,
selectedClass: v?.selectedClass.value,
select: v?.select,
toggle: v?.toggle,
value: v?.value.value,
disabled: e.disabled
}) ?? Te(e.text)]), T && p("div", {
key: "append",
class: "v-chip__append"
}, [r.append ? g(Ne, {
key: "append-defaults",
disabled: !w,
defaults: {
VAvatar: {
end: !0,
image: e.appendAvatar
},
VIcon: {
end: !0,
icon: e.appendIcon
}
}
}, r.append) : p(pe, null, [e.appendIcon && g(Ve, {
key: "append-icon",
end: !0,
icon: e.appendIcon
}, null), e.appendAvatar && g(_n, {
key: "append-avatar",
end: !0,
image: e.appendAvatar
}, null)])]), L && p("button", j({
key: "close",
class: "v-chip__close",
type: "button",
"data-testid": "close-chip"
}, b.value), [r.close ? g(Ne, {
key: "close-defaults",
defaults: {
VIcon: {
icon: e.closeIcon,
size: "x-small"
}
}
}, r.close) : g(Ve, {
key: "close-icon",
icon: e.closeIcon,
size: "x-small"
}, null)])]
}), [[sn, h.value && e.ripple, null]]);
};
}
}), nl = Symbol.for("vuetify:list");
function vc() {
const e = De(nl, {
hasPrepend: ne(!1),
updateHasPrepend: () => null
}), t = {
hasPrepend: ne(!1),
updateHasPrepend: (n) => {
n && (t.hasPrepend.value = n);
}
};
return We(nl, t), e;
}
function yc() {
return De(nl, null);
}
const ql = (e) => {
const t = {
activate: (n) => {
let {
id: a,
value: r,
activated: s
} = n;
return a = He(a), e && !r && s.size === 1 && s.has(a) || (r ? s.add(a) : s.delete(a)), s;
},
in: (n, a, r) => {
let s = /* @__PURE__ */ new Set();
if (n != null)
for (const l of Ke(n))
s = t.activate({
id: l,
value: !0,
activated: new Set(s),
children: a,
parents: r
});
return s;
},
out: (n) => Array.from(n)
};
return t;
}, gc = (e) => {
const t = ql(e);
return {
activate: (a) => {
let {
activated: r,
id: s,
...l
} = a;
s = He(s);
const i = r.has(s) ? /* @__PURE__ */ new Set([s]) : /* @__PURE__ */ new Set();
return t.activate({
...l,
id: s,
activated: i
});
},
in: (a, r, s) => {
let l = /* @__PURE__ */ new Set();
if (a != null) {
const i = Ke(a);
i.length && (l = t.in(i.slice(0, 1), r, s));
}
return l;
},
out: (a, r, s) => t.out(a, r, s)
};
}, uy = (e) => {
const t = ql(e);
return {
activate: (a) => {
let {
id: r,
activated: s,
children: l,
...i
} = a;
return r = He(r), l.has(r) ? s : t.activate({
id: r,
activated: s,
children: l,
...i
});
},
in: t.in,
out: t.out
};
}, cy = (e) => {
const t = gc(e);
return {
activate: (a) => {
let {
id: r,
activated: s,
children: l,
...i
} = a;
return r = He(r), l.has(r) ? s : t.activate({
id: r,
activated: s,
children: l,
...i
});
},
in: t.in,
out: t.out
};
}, dy = {
open: (e) => {
let {
id: t,
value: n,
opened: a,
parents: r
} = e;
if (n) {
const s = /* @__PURE__ */ new Set();
s.add(t);
let l = r.get(t);
for (; l != null; )
s.add(l), l = r.get(l);
return s;
} else
return a.delete(t), a;
},
select: () => null
}, bc = {
open: (e) => {
let {
id: t,
value: n,
opened: a,
parents: r
} = e;
if (n) {
let s = r.get(t);
for (a.add(t); s != null && s !== t; )
a.add(s), s = r.get(s);
return a;
} else
a.delete(t);
return a;
},
select: () => null
}, fy = {
open: bc.open,
select: (e) => {
let {
id: t,
value: n,
opened: a,
parents: r
} = e;
if (!n) return a;
const s = [];
let l = r.get(t);
for (; l != null; )
s.push(l), l = r.get(l);
return new Set(s);
}
}, Kl = (e) => {
const t = {
select: (n) => {
let {
id: a,
value: r,
selected: s
} = n;
if (a = He(a), e && !r) {
const l = Array.from(s.entries()).reduce((i, o) => {
let [u, c] = o;
return c === "on" && i.push(u), i;
}, []);
if (l.length === 1 && l[0] === a) return s;
}
return s.set(a, r ? "on" : "off"), s;
},
in: (n, a, r) => {
const s = /* @__PURE__ */ new Map();
for (const l of n || [])
t.select({
id: l,
value: !0,
selected: s,
children: a,
parents: r
});
return s;
},
out: (n) => {
const a = [];
for (const [r, s] of n.entries())
s === "on" && a.push(r);
return a;
}
};
return t;
}, pc = (e) => {
const t = Kl(e);
return {
select: (a) => {
let {
selected: r,
id: s,
...l
} = a;
s = He(s);
const i = r.has(s) ? /* @__PURE__ */ new Map([[s, r.get(s)]]) : /* @__PURE__ */ new Map();
return t.select({
...l,
id: s,
selected: i
});
},
in: (a, r, s) => a?.length ? t.in(a.slice(0, 1), r, s) : /* @__PURE__ */ new Map(),
out: (a, r, s) => t.out(a, r, s)
};
}, hy = (e) => {
const t = Kl(e);
return {
select: (a) => {
let {
id: r,
selected: s,
children: l,
...i
} = a;
return r = He(r), l.has(r) ? s : t.select({
id: r,
selected: s,
children: l,
...i
});
},
in: t.in,
out: t.out
};
}, my = (e) => {
const t = pc(e);
return {
select: (a) => {
let {
id: r,
selected: s,
children: l,
...i
} = a;
return r = He(r), l.has(r) ? s : t.select({
id: r,
selected: s,
children: l,
...i
});
},
in: t.in,
out: t.out
};
}, Sc = (e) => {
const t = {
select: (n) => {
let {
id: a,
value: r,
selected: s,
children: l,
parents: i
} = n;
a = He(a);
const o = new Map(s), u = [a];
for (; u.length; ) {
const d = u.shift();
s.set(He(d), r ? "on" : "off"), l.has(d) && u.push(...l.get(d));
}
let c = He(i.get(a));
for (; c; ) {
const d = l.get(c), f = d.every((m) => s.get(He(m)) === "on"), v = d.every((m) => !s.has(He(m)) || s.get(He(m)) === "off");
s.set(c, f ? "on" : v ? "off" : "indeterminate"), c = He(i.get(c));
}
return e && !r && Array.from(s.entries()).reduce((f, v) => {
let [m, y] = v;
return y === "on" && f.push(m), f;
}, []).length === 0 ? o : s;
},
in: (n, a, r) => {
let s = /* @__PURE__ */ new Map();
for (const l of n || [])
s = t.select({
id: l,
value: !0,
selected: s,
children: a,
parents: r
});
return s;
},
out: (n, a) => {
const r = [];
for (const [s, l] of n.entries())
l === "on" && !a.has(s) && r.push(s);
return r;
}
};
return t;
}, vy = (e) => {
const t = Sc(e);
return {
select: t.select,
in: t.in,
out: (a, r, s) => {
const l = [];
for (const [i, o] of a.entries())
if (o === "on") {
if (s.has(i)) {
const u = s.get(i);
if (a.get(u) === "on") continue;
}
l.push(i);
}
return l;
}
};
}, Ea = Symbol.for("vuetify:nested"), wc = {
id: ne(),
root: {
register: () => null,
unregister: () => null,
parents: R(/* @__PURE__ */ new Map()),
children: R(/* @__PURE__ */ new Map()),
open: () => null,
openOnSelect: () => null,
activate: () => null,
select: () => null,
activatable: R(!1),
selectable: R(!1),
opened: R(/* @__PURE__ */ new Set()),
activated: R(/* @__PURE__ */ new Set()),
selected: R(/* @__PURE__ */ new Map()),
selectedValues: R([]),
getPath: () => []
}
}, yy = M({
activatable: Boolean,
selectable: Boolean,
activeStrategy: [String, Function, Object],
selectStrategy: [String, Function, Object],
openStrategy: [String, Object],
opened: null,
activated: null,
selected: null,
mandatory: Boolean
}, "nested"), gy = (e) => {
let t = !1;
const n = R(/* @__PURE__ */ new Map()), a = R(/* @__PURE__ */ new Map()), r = _e(e, "opened", e.opened, (m) => new Set(m), (m) => [...m.values()]), s = _(() => {
if (typeof e.activeStrategy == "object") return e.activeStrategy;
if (typeof e.activeStrategy == "function") return e.activeStrategy(e.mandatory);
switch (e.activeStrategy) {
case "leaf":
return uy(e.mandatory);
case "single-leaf":
return cy(e.mandatory);
case "independent":
return ql(e.mandatory);
case "single-independent":
default:
return gc(e.mandatory);
}
}), l = _(() => {
if (typeof e.selectStrategy == "object") return e.selectStrategy;
if (typeof e.selectStrategy == "function") return e.selectStrategy(e.mandatory);
switch (e.selectStrategy) {
case "single-leaf":
return my(e.mandatory);
case "leaf":
return hy(e.mandatory);
case "independent":
return Kl(e.mandatory);
case "single-independent":
return pc(e.mandatory);
case "trunk":
return vy(e.mandatory);
case "classic":
default:
return Sc(e.mandatory);
}
}), i = _(() => {
if (typeof e.openStrategy == "object") return e.openStrategy;
switch (e.openStrategy) {
case "list":
return fy;
case "single":
return dy;
case "multiple":
default:
return bc;
}
}), o = _e(e, "activated", e.activated, (m) => s.value.in(m, n.value, a.value), (m) => s.value.out(m, n.value, a.value)), u = _e(e, "selected", e.selected, (m) => l.value.in(m, n.value, a.value), (m) => l.value.out(m, n.value, a.value));
At(() => {
t = !0;
});
function c(m) {
const y = [];
let h = m;
for (; h != null; )
y.unshift(h), h = a.value.get(h);
return y;
}
const d = Ue("nested"), f = /* @__PURE__ */ new Set(), v = {
id: ne(),
root: {
opened: r,
activatable: I(() => e.activatable),
selectable: I(() => e.selectable),
activated: o,
selected: u,
selectedValues: _(() => {
const m = [];
for (const [y, h] of u.value.entries())
h === "on" && m.push(y);
return m;
}),
register: (m, y, h) => {
if (f.has(m)) {
const b = c(m).map(String).join(" -> "), S = c(y).concat(m).map(String).join(" -> ");
Fl(`Multiple nodes with the same ID
${b}
${S}`);
return;
} else
f.add(m);
y && m !== y && a.value.set(m, y), h && n.value.set(m, []), y != null && n.value.set(y, [...n.value.get(y) || [], m]);
},
unregister: (m) => {
if (t) return;
f.delete(m), n.value.delete(m);
const y = a.value.get(m);
if (y) {
const h = n.value.get(y) ?? [];
n.value.set(y, h.filter((b) => b !== m));
}
a.value.delete(m);
},
open: (m, y, h) => {
d.emit("click:open", {
id: m,
value: y,
path: c(m),
event: h
});
const b = i.value.open({
id: m,
value: y,
opened: new Set(r.value),
children: n.value,
parents: a.value,
event: h
});
b && (r.value = b);
},
openOnSelect: (m, y, h) => {
const b = i.value.select({
id: m,
value: y,
selected: new Map(u.value),
opened: new Set(r.value),
children: n.value,
parents: a.value,
event: h
});
b && (r.value = b);
},
select: (m, y, h) => {
d.emit("click:select", {
id: m,
value: y,
path: c(m),
event: h
});
const b = l.value.select({
id: m,
value: y,
selected: new Map(u.value),
children: n.value,
parents: a.value,
event: h
});
b && (u.value = b), v.root.openOnSelect(m, y, h);
},
activate: (m, y, h) => {
if (!e.activatable)
return v.root.select(m, !0, h);
d.emit("click:activate", {
id: m,
value: y,
path: c(m),
event: h
});
const b = s.value.activate({
id: m,
value: y,
activated: new Set(o.value),
children: n.value,
parents: a.value,
event: h
});
if (b.size !== o.value.size)
o.value = b;
else {
for (const S of b)
if (!o.value.has(S)) {
o.value = b;
return;
}
for (const S of o.value)
if (!b.has(S)) {
o.value = b;
return;
}
}
},
children: n,
parents: a,
getPath: c
}
};
return We(Ea, v), v.root;
}, _c = (e, t) => {
const n = De(Ea, wc), a = Symbol("nested item"), r = _(() => rn(e) ?? a), s = {
...n,
id: r,
open: (l, i) => n.root.open(r.value, l, i),
openOnSelect: (l, i) => n.root.openOnSelect(r.value, l, i),
isOpen: _(() => n.root.opened.value.has(r.value)),
parent: _(() => n.root.parents.value.get(r.value)),
activate: (l, i) => n.root.activate(r.value, l, i),
isActivated: _(() => n.root.activated.value.has(He(r.value))),
select: (l, i) => n.root.select(r.value, l, i),
isSelected: _(() => n.root.selected.value.get(He(r.value)) === "on"),
isIndeterminate: _(() => n.root.selected.value.get(He(r.value)) === "indeterminate"),
isLeaf: _(() => !n.root.children.value.get(r.value)),
isGroupActivator: n.isGroupActivator
};
return Lr(() => {
!n.isGroupActivator && n.root.register(r.value, n.id.value, t);
}), At(() => {
!n.isGroupActivator && n.root.unregister(r.value);
}), t && We(Ea, s), s;
}, by = () => {
const e = De(Ea, wc);
We(Ea, {
...e,
isGroupActivator: !0
});
};
function py() {
const e = ne(!1);
return Ba(() => {
window.requestAnimationFrame(() => {
e.value = !0;
});
}), {
ssrBootStyles: I(() => e.value ? void 0 : {
transition: "none !important"
}),
isBooted: Cl(e)
};
}
const Sy = Ha({
name: "VListGroupActivator",
setup(e, t) {
let {
slots: n
} = t;
return by(), () => n.default?.();
}
}), wy = M({
/* @deprecated */
activeColor: String,
baseColor: String,
color: String,
collapseIcon: {
type: le,
default: "$collapse"
},
expandIcon: {
type: le,
default: "$expand"
},
prependIcon: le,
appendIcon: le,
fluid: Boolean,
subgroup: Boolean,
title: String,
value: null,
...ce(),
...Le()
}, "VListGroup"), So = G()({
name: "VListGroup",
props: wy(),
setup(e, t) {
let {
slots: n
} = t;
const {
isOpen: a,
open: r,
id: s
} = _c(() => e.value, !0), l = _(() => `v-list-group--id-${String(s.value)}`), i = yc(), {
isBooted: o
} = py();
function u(v) {
v.stopPropagation(), !["INPUT", "TEXTAREA"].includes(v.target?.tagName) && r(!a.value, v);
}
const c = _(() => ({
onClick: u,
class: "v-list-group__header",
id: l.value
})), d = _(() => a.value ? e.collapseIcon : e.expandIcon), f = _(() => ({
VListItem: {
active: a.value,
activeColor: e.activeColor,
baseColor: e.baseColor,
color: e.color,
prependIcon: e.prependIcon || e.subgroup && d.value,
appendIcon: e.appendIcon || !e.subgroup && d.value,
title: e.title,
value: e.value
}
}));
return ee(() => g(e.tag, {
class: Q(["v-list-group", {
"v-list-group--prepend": i?.hasPrepend.value,
"v-list-group--fluid": e.fluid,
"v-list-group--subgroup": e.subgroup,
"v-list-group--open": a.value
}, e.class]),
style: J(e.style)
}, {
default: () => [n.activator && g(Ne, {
defaults: f.value
}, {
default: () => [g(Sy, null, {
default: () => [n.activator({
props: c.value,
isOpen: a.value
})]
})]
}), g(gn, {
transition: {
component: rc
},
disabled: !o.value
}, {
default: () => [ht(p("div", {
class: "v-list-group__items",
role: "group",
"aria-labelledby": l.value
}, [n.default?.()]), [[Bn, a.value]])]
})]
})), {
isOpen: a
};
}
}), _y = M({
opacity: [Number, String],
...ce(),
...Le()
}, "VListItemSubtitle"), ky = G()({
name: "VListItemSubtitle",
props: _y(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => g(e.tag, {
class: Q(["v-list-item-subtitle", e.class]),
style: J([{
"--v-list-item-subtitle-opacity": e.opacity
}, e.style])
}, n)), {};
}
}), Cy = Bu("v-list-item-title"), Py = M({
active: {
type: Boolean,
default: void 0
},
activeClass: String,
/* @deprecated */
activeColor: String,
appendAvatar: String,
appendIcon: le,
baseColor: String,
disabled: Boolean,
lines: [Boolean, String],
link: {
type: Boolean,
default: void 0
},
nav: Boolean,
prependAvatar: String,
prependIcon: le,
ripple: {
type: [Boolean, Object],
default: !0
},
slim: Boolean,
subtitle: {
type: [String, Number, Boolean],
default: void 0
},
title: {
type: [String, Number, Boolean],
default: void 0
},
value: null,
onClick: Je(),
onClickOnce: Je(),
...dn(),
...ce(),
...Ct(),
...un(),
...Pn(),
...kt(),
...Xr(),
...Le(),
...Ye(),
...fn({
variant: "text"
})
}, "VListItem"), Nn = G()({
name: "VListItem",
directives: {
vRipple: sn
},
props: Py(),
emits: {
click: (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a,
emit: r
} = t;
const s = Zr(e, n), l = _(() => e.value === void 0 ? s.href.value : e.value), {
activate: i,
isActivated: o,
select: u,
isOpen: c,
isSelected: d,
isIndeterminate: f,
isGroupActivator: v,
root: m,
parent: y,
openOnSelect: h,
id: b
} = _c(l, !1), S = yc(), P = _(() => e.active !== !1 && (e.active || s.isActive?.value || (m.activatable.value ? o.value : d.value))), O = I(() => e.link !== !1 && s.isLink.value), k = _(() => !!S && (m.selectable.value || m.activatable.value || e.value != null)), E = _(() => !e.disabled && e.link !== !1 && (e.link || s.isClickable.value || k.value)), V = I(() => e.rounded || e.nav), w = I(() => e.color ?? e.activeColor), T = I(() => ({
color: P.value ? w.value ?? e.baseColor : e.baseColor,
variant: e.variant
}));
re(() => s.isActive?.value, (ie) => {
ie && L();
}), Lr(() => {
s.isActive?.value && L();
});
function L() {
y.value != null && m.open(y.value, !0), h(!0);
}
const {
themeClasses: $
} = Ze(e), {
borderClasses: B
} = Cn(e), {
colorClasses: D,
colorStyles: H,
variantClasses: Y
} = Wa(T), {
densityClasses: X
} = Wt(e), {
dimensionStyles: oe
} = cn(e), {
elevationClasses: ge
} = Un(e), {
roundedClasses: Ie
} = Dt(V), x = I(() => e.lines ? `v-list-item--${e.lines}-line` : void 0), A = _(() => ({
isActive: P.value,
select: u,
isOpen: c.value,
isSelected: d.value,
isIndeterminate: f.value
}));
function N(ie) {
r("click", ie), !["INPUT", "TEXTAREA"].includes(ie.target?.tagName) && E.value && (s.navigate?.(ie), !v && (m.activatable.value ? i(!o.value, ie) : (m.selectable.value || e.value != null) && u(!d.value, ie)));
}
function q(ie) {
const ae = ie.target;
["INPUT", "TEXTAREA"].includes(ae.tagName) || (ie.key === "Enter" || ie.key === " ") && (ie.preventDefault(), ie.target.dispatchEvent(new MouseEvent("click", ie)));
}
return ee(() => {
const ie = O.value ? "a" : e.tag, ae = a.title || e.title != null, se = a.subtitle || e.subtitle != null, K = !!(e.appendAvatar || e.appendIcon), Ae = !!(K || a.append), Se = !!(e.prependAvatar || e.prependIcon), U = !!(Se || a.prepend);
return S?.updateHasPrepend(U), e.activeColor && tv("active-color", ["color", "base-color"]), ht(g(ie, j({
class: ["v-list-item", {
"v-list-item--active": P.value,
"v-list-item--disabled": e.disabled,
"v-list-item--link": E.value,
"v-list-item--nav": e.nav,
"v-list-item--prepend": !U && S?.hasPrepend.value,
"v-list-item--slim": e.slim,
[`${e.activeClass}`]: e.activeClass && P.value
}, $.value, B.value, D.value, X.value, ge.value, x.value, Ie.value, Y.value, e.class],
style: [H.value, oe.value, e.style],
tabindex: E.value ? S ? -2 : 0 : void 0,
"aria-selected": k.value ? m.activatable.value ? o.value : m.selectable.value ? d.value : P.value : void 0,
onClick: N,
onKeydown: E.value && !O.value && q
}, s.linkProps), {
default: () => [ja(E.value || P.value, "v-list-item"), U && p("div", {
key: "prepend",
class: "v-list-item__prepend"
}, [a.prepend ? g(Ne, {
key: "prepend-defaults",
disabled: !Se,
defaults: {
VAvatar: {
density: e.density,
image: e.prependAvatar
},
VIcon: {
density: e.density,
icon: e.prependIcon
},
VListItemAction: {
start: !0
}
}
}, {
default: () => [a.prepend?.(A.value)]
}) : p(pe, null, [e.prependAvatar && g(_n, {
key: "prepend-avatar",
density: e.density,
image: e.prependAvatar
}, null), e.prependIcon && g(Ve, {
key: "prepend-icon",
density: e.density,
icon: e.prependIcon
}, null)]), p("div", {
class: "v-list-item__spacer"
}, null)]), p("div", {
class: "v-list-item__content",
"data-no-activator": ""
}, [ae && g(Cy, {
key: "title"
}, {
default: () => [a.title?.({
title: e.title
}) ?? Te(e.title)]
}), se && g(ky, {
key: "subtitle"
}, {
default: () => [a.subtitle?.({
subtitle: e.subtitle
}) ?? Te(e.subtitle)]
}), a.default?.(A.value)]), Ae && p("div", {
key: "append",
class: "v-list-item__append"
}, [a.append ? g(Ne, {
key: "append-defaults",
disabled: !K,
defaults: {
VAvatar: {
density: e.density,
image: e.appendAvatar
},
VIcon: {
density: e.density,
icon: e.appendIcon
},
VListItemAction: {
end: !0
}
}
}, {
default: () => [a.append?.(A.value)]
}) : p(pe, null, [e.appendIcon && g(Ve, {
key: "append-icon",
density: e.density,
icon: e.appendIcon
}, null), e.appendAvatar && g(_n, {
key: "append-avatar",
density: e.density,
image: e.appendAvatar
}, null)]), p("div", {
class: "v-list-item__spacer"
}, null)])]
}), [[sn, E.value && e.ripple]]);
}), {
activate: i,
isActivated: o,
isGroupActivator: v,
isSelected: d,
list: S,
select: u,
root: m,
id: b,
link: s
};
}
}), xy = M({
color: String,
inset: Boolean,
sticky: Boolean,
title: String,
...ce(),
...Le()
}, "VListSubheader"), Iy = G()({
name: "VListSubheader",
props: xy(),
setup(e, t) {
let {
slots: n
} = t;
const {
textColorClasses: a,
textColorStyles: r
} = Ht(() => e.color);
return ee(() => {
const s = !!(n.default || e.title);
return g(e.tag, {
class: Q(["v-list-subheader", {
"v-list-subheader--inset": e.inset,
"v-list-subheader--sticky": e.sticky
}, a.value, e.class]),
style: J([{
textColorStyles: r
}, e.style])
}, {
default: () => [s && p("div", {
class: "v-list-subheader__text"
}, [n.default?.() ?? e.title])]
});
}), {};
}
}), Oy = M({
color: String,
inset: Boolean,
length: [Number, String],
opacity: [Number, String],
thickness: [Number, String],
vertical: Boolean,
...ce(),
...Ye()
}, "VDivider"), kc = G()({
name: "VDivider",
props: Oy(),
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
themeClasses: r
} = Ze(e), {
textColorClasses: s,
textColorStyles: l
} = Ht(() => e.color), i = _(() => {
const o = {};
return e.length && (o[e.vertical ? "height" : "width"] = te(e.length)), e.thickness && (o[e.vertical ? "borderRightWidth" : "borderTopWidth"] = te(e.thickness)), o;
});
return ee(() => {
const o = p("hr", {
class: Q([{
"v-divider": !0,
"v-divider--inset": e.inset,
"v-divider--vertical": e.vertical
}, r.value, s.value, e.class]),
style: J([i.value, l.value, {
"--v-border-opacity": e.opacity
}, e.style]),
"aria-orientation": !n.role || n.role === "separator" ? e.vertical ? "vertical" : "horizontal" : void 0,
role: `${n.role || "separator"}`
}, null);
return a.default ? p("div", {
class: Q(["v-divider__wrapper", {
"v-divider__wrapper--vertical": e.vertical,
"v-divider__wrapper--inset": e.inset
}])
}, [o, p("div", {
class: "v-divider__content"
}, [a.default()]), o]) : o;
}), {};
}
}), Ty = M({
items: Array,
returnObject: Boolean
}, "VListChildren"), Cc = G()({
name: "VListChildren",
props: Ty(),
setup(e, t) {
let {
slots: n
} = t;
return vc(), () => n.default?.() ?? e.items?.map((a) => {
let {
children: r,
props: s,
type: l,
raw: i
} = a;
if (l === "divider")
return n.divider?.({
props: s
}) ?? g(kc, s, null);
if (l === "subheader")
return n.subheader?.({
props: s
}) ?? g(Iy, s, null);
const o = {
subtitle: n.subtitle ? (c) => n.subtitle?.({
...c,
item: i
}) : void 0,
prepend: n.prepend ? (c) => n.prepend?.({
...c,
item: i
}) : void 0,
append: n.append ? (c) => n.append?.({
...c,
item: i
}) : void 0,
title: n.title ? (c) => n.title?.({
...c,
item: i
}) : void 0
}, u = So.filterProps(s);
return r ? g(So, j({
value: s?.value
}, u), {
activator: (c) => {
let {
props: d
} = c;
const f = {
...s,
...d,
value: e.returnObject ? i : s.value
};
return n.header ? n.header({
props: f
}) : g(Nn, f, o);
},
default: () => g(Cc, {
items: r,
returnObject: e.returnObject
}, n)
}) : n.item ? n.item({
props: s
}) : g(Nn, j(s, {
value: e.returnObject ? i : s.value
}), o);
});
}
}), Pc = M({
items: {
type: Array,
default: () => []
},
itemTitle: {
type: [String, Array, Function],
default: "title"
},
itemValue: {
type: [String, Array, Function],
default: "value"
},
itemChildren: {
type: [Boolean, String, Array, Function],
default: "children"
},
itemProps: {
type: [Boolean, String, Array, Function],
default: "props"
},
returnObject: Boolean,
valueComparator: Function
}, "list-items");
function al(e, t) {
const n = ot(t, e.itemTitle, t), a = ot(t, e.itemValue, n), r = ot(t, e.itemChildren), s = e.itemProps === !0 ? typeof t == "object" && t != null && !Array.isArray(t) ? "children" in t ? kn(t, ["children"]) : t : void 0 : ot(t, e.itemProps), l = {
title: n,
value: a,
...s
};
return {
title: String(l.title ?? ""),
value: l.value,
props: l,
children: Array.isArray(r) ? xc(e, r) : void 0,
raw: t
};
}
function xc(e, t) {
const n = jr(e, ["itemTitle", "itemValue", "itemChildren", "itemProps", "returnObject", "valueComparator"]), a = [];
for (const r of t)
a.push(al(n, r));
return a;
}
function Ic(e) {
const t = _(() => xc(e, e.items)), n = _(() => t.value.some((i) => i.value === null)), a = ne(/* @__PURE__ */ new Map()), r = ne([]);
Ot(() => {
const i = t.value, o = /* @__PURE__ */ new Map(), u = [];
for (let c = 0; c < i.length; c++) {
const d = i[c];
if (Ru(d.value) || d.value === null) {
let f = o.get(d.value);
f || (f = [], o.set(d.value, f)), f.push(d);
} else
u.push(d);
}
a.value = o, r.value = u;
});
function s(i) {
const o = a.value, u = t.value, c = r.value, d = n.value, f = e.returnObject, v = !!e.valueComparator, m = e.valueComparator || gt, y = jr(e, ["itemTitle", "itemValue", "itemChildren", "itemProps", "returnObject", "valueComparator"]), h = [];
e: for (const b of i) {
if (!d && b === null) continue;
if (f && typeof b == "string") {
h.push(al(y, b));
continue;
}
const S = o.get(b);
if (v || !S) {
for (const P of v ? u : c)
if (m(b, P.value)) {
h.push(P);
continue e;
}
h.push(al(y, b));
continue;
}
h.push(...S);
}
return h;
}
function l(i) {
return e.returnObject ? i.map((o) => {
let {
raw: u
} = o;
return u;
}) : i.map((o) => {
let {
value: u
} = o;
return u;
});
}
return {
items: t,
transformIn: s,
transformOut: l
};
}
function Vy(e, t) {
const n = ot(t, e.itemType, "item"), a = Ru(t) ? t : ot(t, e.itemTitle), r = ot(t, e.itemValue, void 0), s = ot(t, e.itemChildren), l = e.itemProps === !0 ? kn(t, ["children"]) : ot(t, e.itemProps), i = {
title: a,
value: r,
...l
};
return {
type: n,
title: i.title,
value: i.value,
props: i,
children: n === "item" && s ? Oc(e, s) : void 0,
raw: t
};
}
function Oc(e, t) {
const n = [];
for (const a of t)
n.push(Vy(e, a));
return n;
}
function Ay(e) {
return {
items: _(() => Oc(e, e.items))
};
}
const Ey = M({
baseColor: String,
/* @deprecated */
activeColor: String,
activeClass: String,
bgColor: String,
disabled: Boolean,
expandIcon: le,
collapseIcon: le,
lines: {
type: [Boolean, String],
default: "one"
},
slim: Boolean,
nav: Boolean,
"onClick:open": Je(),
"onClick:select": Je(),
"onUpdate:opened": Je(),
...yy({
selectStrategy: "single-leaf",
openStrategy: "list"
}),
...dn(),
...ce(),
...Ct(),
...un(),
...Pn(),
itemType: {
type: String,
default: "type"
},
...Pc(),
...kt(),
...Le(),
...Ye(),
...fn({
variant: "text"
})
}, "VList"), Tc = G()({
name: "VList",
props: Ey(),
emits: {
"update:selected": (e) => !0,
"update:activated": (e) => !0,
"update:opened": (e) => !0,
"click:open": (e) => !0,
"click:activate": (e) => !0,
"click:select": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
items: a
} = Ay(e), {
themeClasses: r
} = Ze(e), {
backgroundColorClasses: s,
backgroundColorStyles: l
} = $t(() => e.bgColor), {
borderClasses: i
} = Cn(e), {
densityClasses: o
} = Wt(e), {
dimensionStyles: u
} = cn(e), {
elevationClasses: c
} = Un(e), {
roundedClasses: d
} = Dt(e), {
children: f,
open: v,
parents: m,
select: y,
getPath: h
} = gy(e), b = I(() => e.lines ? `v-list--${e.lines}-line` : void 0), S = I(() => e.activeColor), P = I(() => e.baseColor), O = I(() => e.color);
vc(), zt({
VListGroup: {
activeColor: S,
baseColor: P,
color: O,
expandIcon: I(() => e.expandIcon),
collapseIcon: I(() => e.collapseIcon)
},
VListItem: {
activeClass: I(() => e.activeClass),
activeColor: S,
baseColor: P,
color: O,
density: I(() => e.density),
disabled: I(() => e.disabled),
lines: I(() => e.lines),
nav: I(() => e.nav),
slim: I(() => e.slim),
variant: I(() => e.variant)
}
});
const k = ne(!1), E = R();
function V(D) {
k.value = !0;
}
function w(D) {
k.value = !1;
}
function T(D) {
!k.value && !(D.relatedTarget && E.value?.contains(D.relatedTarget)) && B();
}
function L(D) {
const H = D.target;
if (!(!E.value || ["INPUT", "TEXTAREA"].includes(H.tagName))) {
if (D.key === "ArrowDown")
B("next");
else if (D.key === "ArrowUp")
B("prev");
else if (D.key === "Home")
B("first");
else if (D.key === "End")
B("last");
else
return;
D.preventDefault();
}
}
function $(D) {
k.value = !0;
}
function B(D) {
if (E.value)
return ka(E.value, D);
}
return ee(() => g(e.tag, {
ref: E,
class: Q(["v-list", {
"v-list--disabled": e.disabled,
"v-list--nav": e.nav,
"v-list--slim": e.slim
}, r.value, s.value, i.value, o.value, c.value, b.value, d.value, e.class]),
style: J([l.value, u.value, e.style]),
tabindex: e.disabled ? -1 : 0,
role: "listbox",
"aria-activedescendant": void 0,
onFocusin: V,
onFocusout: w,
onFocus: T,
onKeydown: L,
onMousedown: $
}, {
default: () => [g(Cc, {
items: a.value,
returnObject: e.returnObject
}, n)]
})), {
open: v,
select: y,
focus: B,
children: f,
parents: m,
getPath: h
};
}
});
function Os(e, t) {
return {
x: e.x + t.x,
y: e.y + t.y
};
}
function Dy(e, t) {
return {
x: e.x - t.x,
y: e.y - t.y
};
}
function wo(e, t) {
if (e.side === "top" || e.side === "bottom") {
const {
side: n,
align: a
} = e, r = a === "left" ? 0 : a === "center" ? t.width / 2 : a === "right" ? t.width : a, s = n === "top" ? 0 : n === "bottom" ? t.height : n;
return Os({
x: r,
y: s
}, t);
} else if (e.side === "left" || e.side === "right") {
const {
side: n,
align: a
} = e, r = n === "left" ? 0 : n === "right" ? t.width : n, s = a === "top" ? 0 : a === "center" ? t.height / 2 : a === "bottom" ? t.height : a;
return Os({
x: r,
y: s
}, t);
}
return Os({
x: t.width / 2,
y: t.height / 2
}, t);
}
const Vc = {
static: Fy,
// specific viewport position, usually centered
connected: Ny
// connected to a certain element
}, My = M({
locationStrategy: {
type: [String, Function],
default: "static",
validator: (e) => typeof e == "function" || e in Vc
},
location: {
type: String,
default: "bottom"
},
origin: {
type: String,
default: "auto"
},
offset: [Number, String, Array]
}, "VOverlay-location-strategies");
function Ry(e, t) {
const n = R({}), a = R();
Be && Fn(() => !!(t.isActive.value && e.locationStrategy), (i) => {
re(() => e.locationStrategy, i), mt(() => {
window.removeEventListener("resize", r), visualViewport?.removeEventListener("resize", s), visualViewport?.removeEventListener("scroll", l), a.value = void 0;
}), window.addEventListener("resize", r, {
passive: !0
}), visualViewport?.addEventListener("resize", s, {
passive: !0
}), visualViewport?.addEventListener("scroll", l, {
passive: !0
}), typeof e.locationStrategy == "function" ? a.value = e.locationStrategy(t, e, n)?.updateLocation : a.value = Vc[e.locationStrategy](t, e, n)?.updateLocation;
});
function r(i) {
a.value?.(i);
}
function s(i) {
a.value?.(i);
}
function l(i) {
a.value?.(i);
}
return {
contentStyles: n,
updateLocation: a
};
}
function Fy() {
}
function Ly(e, t) {
const n = Rl(e);
return t ? n.x += parseFloat(e.style.right || 0) : n.x -= parseFloat(e.style.left || 0), n.y -= parseFloat(e.style.top || 0), n;
}
function Ny(e, t, n) {
(Array.isArray(e.target.value) || dv(e.target.value)) && Object.assign(n.value, {
position: "fixed",
top: 0,
[e.isRtl.value ? "right" : "left"]: 0
});
const {
preferredAnchor: r,
preferredOrigin: s
} = El(() => {
const b = Js(t.location, e.isRtl.value), S = t.origin === "overlap" ? b : t.origin === "auto" ? ks(b) : Js(t.origin, e.isRtl.value);
return b.side === S.side && b.align === Cs(S).align ? {
preferredAnchor: Ji(b),
preferredOrigin: Ji(S)
} : {
preferredAnchor: b,
preferredOrigin: S
};
}), [l, i, o, u] = ["minWidth", "minHeight", "maxWidth", "maxHeight"].map((b) => _(() => {
const S = parseFloat(t[b]);
return isNaN(S) ? 1 / 0 : S;
})), c = _(() => {
if (Array.isArray(t.offset))
return t.offset;
if (typeof t.offset == "string") {
const b = t.offset.split(" ").map(parseFloat);
return b.length < 2 && b.push(0), b;
}
return typeof t.offset == "number" ? [t.offset, 0] : [0, 0];
});
let d = !1, f = -1;
const v = new Rm(4), m = new ResizeObserver(() => {
if (!d) return;
if (requestAnimationFrame((S) => {
S !== f && v.clear(), requestAnimationFrame((P) => {
f = P;
});
}), v.isFull) {
const S = v.values();
if (gt(S.at(-1), S.at(-3)))
return;
}
const b = h();
b && v.push(b.flipped);
});
re([e.target, e.contentEl], (b, S) => {
let [P, O] = b, [k, E] = S;
k && !Array.isArray(k) && m.unobserve(k), P && !Array.isArray(P) && m.observe(P), E && m.unobserve(E), O && m.observe(O);
}, {
immediate: !0
}), mt(() => {
m.disconnect();
});
let y = new Bt({
x: 0,
y: 0,
width: 0,
height: 0
});
function h() {
if (d = !1, requestAnimationFrame(() => d = !0), !e.target.value || !e.contentEl.value) return;
(Array.isArray(e.target.value) || e.target.value.offsetParent || e.target.value.getClientRects().length) && (y = Lu(e.target.value));
const b = Ly(e.contentEl.value, e.isRtl.value), S = Cr(e.contentEl.value), P = 12;
S.length || (S.push(document.documentElement), e.contentEl.value.style.top && e.contentEl.value.style.left || (b.x -= parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x") || 0), b.y -= parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y") || 0)));
const O = S.reduce((D, H) => {
const Y = Hm(H);
return D ? new Bt({
x: Math.max(D.left, Y.left),
y: Math.max(D.top, Y.top),
width: Math.min(D.right, Y.right) - Math.max(D.left, Y.left),
height: Math.min(D.bottom, Y.bottom) - Math.max(D.top, Y.top)
}) : Y;
}, void 0);
O.x += P, O.y += P, O.width -= P * 2, O.height -= P * 2;
let k = {
anchor: r.value,
origin: s.value
};
function E(D) {
const H = new Bt(b), Y = wo(D.anchor, y), X = wo(D.origin, H);
let {
x: oe,
y: ge
} = Dy(Y, X);
switch (D.anchor.side) {
case "top":
ge -= c.value[0];
break;
case "bottom":
ge += c.value[0];
break;
case "left":
oe -= c.value[0];
break;
case "right":
oe += c.value[0];
break;
}
switch (D.anchor.align) {
case "top":
ge -= c.value[1];
break;
case "bottom":
ge += c.value[1];
break;
case "left":
oe -= c.value[1];
break;
case "right":
oe += c.value[1];
break;
}
return H.x += oe, H.y += ge, H.width = Math.min(H.width, o.value), H.height = Math.min(H.height, u.value), {
overflows: Xi(H, O),
x: oe,
y: ge
};
}
let V = 0, w = 0;
const T = {
x: 0,
y: 0
}, L = {
x: !1,
y: !1
};
let $ = -1;
for (; ; ) {
if ($++ > 10) {
Fl("Infinite loop detected in connectedLocationStrategy");
break;
}
const {
x: D,
y: H,
overflows: Y
} = E(k);
V += D, w += H, b.x += D, b.y += H;
{
const X = Zi(k.anchor), oe = Y.x.before || Y.x.after, ge = Y.y.before || Y.y.after;
let Ie = !1;
if (["x", "y"].forEach((x) => {
if (x === "x" && oe && !L.x || x === "y" && ge && !L.y) {
const A = {
anchor: {
...k.anchor
},
origin: {
...k.origin
}
}, N = x === "x" ? X === "y" ? Cs : ks : X === "y" ? ks : Cs;
A.anchor = N(A.anchor), A.origin = N(A.origin);
const {
overflows: q
} = E(A);
(q[x].before <= Y[x].before && q[x].after <= Y[x].after || q[x].before + q[x].after < (Y[x].before + Y[x].after) / 2) && (k = A, Ie = L[x] = !0);
}
}), Ie) continue;
}
Y.x.before && (V += Y.x.before, b.x += Y.x.before), Y.x.after && (V -= Y.x.after, b.x -= Y.x.after), Y.y.before && (w += Y.y.before, b.y += Y.y.before), Y.y.after && (w -= Y.y.after, b.y -= Y.y.after);
{
const X = Xi(b, O);
T.x = O.width - X.x.before - X.x.after, T.y = O.height - X.y.before - X.y.after, V += X.x.before, b.x += X.x.before, w += X.y.before, b.y += X.y.before;
}
break;
}
const B = Zi(k.anchor);
return Object.assign(n.value, {
"--v-overlay-anchor-origin": `${k.anchor.side} ${k.anchor.align}`,
transformOrigin: `${k.origin.side} ${k.origin.align}`,
// transform: `translate(${pixelRound(x)}px, ${pixelRound(y)}px)`,
top: te(Ts(w)),
left: e.isRtl.value ? void 0 : te(Ts(V)),
right: e.isRtl.value ? te(Ts(-V)) : void 0,
minWidth: te(B === "y" ? Math.min(l.value, y.width) : l.value),
maxWidth: te(_o(bt(T.x, l.value === 1 / 0 ? 0 : l.value, o.value))),
maxHeight: te(_o(bt(T.y, i.value === 1 / 0 ? 0 : i.value, u.value)))
}), {
available: T,
contentBox: b,
flipped: L
};
}
return re(() => [r.value, s.value, t.offset, t.minWidth, t.minHeight, t.maxWidth, t.maxHeight], () => h()), Ge(() => {
const b = h();
if (!b) return;
const {
available: S,
contentBox: P
} = b;
P.height > S.y && requestAnimationFrame(() => {
h(), requestAnimationFrame(() => {
h();
});
});
}), {
updateLocation: h
};
}
function Ts(e) {
return Math.round(e * devicePixelRatio) / devicePixelRatio;
}
function _o(e) {
return Math.ceil(e * devicePixelRatio) / devicePixelRatio;
}
let rl = !0;
const Ir = [];
function By(e) {
!rl || Ir.length ? (Ir.push(e), sl()) : (rl = !1, e(), sl());
}
let ko = -1;
function sl() {
cancelAnimationFrame(ko), ko = requestAnimationFrame(() => {
const e = Ir.shift();
e && e(), Ir.length ? sl() : rl = !0;
});
}
const Ac = {
none: null,
close: zy,
block: Hy,
reposition: Yy
}, $y = M({
scrollStrategy: {
type: [String, Function],
default: "block",
validator: (e) => typeof e == "function" || e in Ac
}
}, "VOverlay-scroll-strategies");
function Uy(e, t) {
if (!Be) return;
let n;
Ot(async () => {
n?.stop(), t.isActive.value && e.scrollStrategy && (n = kl(), await new Promise((a) => setTimeout(a)), n.active && n.run(() => {
typeof e.scrollStrategy == "function" ? e.scrollStrategy(t, e, n) : Ac[e.scrollStrategy]?.(t, e, n);
}));
}), mt(() => {
n?.stop();
});
}
function zy(e) {
function t(n) {
e.isActive.value = !1;
}
Ec(e.targetEl.value ?? e.contentEl.value, t);
}
function Hy(e, t) {
const n = e.root.value?.offsetParent, a = [.../* @__PURE__ */ new Set([...Cr(e.targetEl.value, t.contained ? n : void 0), ...Cr(e.contentEl.value, t.contained ? n : void 0)])].filter((l) => !l.classList.contains("v-overlay-scroll-blocked")), r = window.innerWidth - document.documentElement.offsetWidth, s = ((l) => Ll(l) && l)(n || document.documentElement);
s && e.root.value.classList.add("v-overlay--scroll-blocked"), a.forEach((l, i) => {
l.style.setProperty("--v-body-scroll-x", te(-l.scrollLeft)), l.style.setProperty("--v-body-scroll-y", te(-l.scrollTop)), l !== document.documentElement && l.style.setProperty("--v-scrollbar-offset", te(r)), l.classList.add("v-overlay-scroll-blocked");
}), mt(() => {
a.forEach((l, i) => {
const o = parseFloat(l.style.getPropertyValue("--v-body-scroll-x")), u = parseFloat(l.style.getPropertyValue("--v-body-scroll-y")), c = l.style.scrollBehavior;
l.style.scrollBehavior = "auto", l.style.removeProperty("--v-body-scroll-x"), l.style.removeProperty("--v-body-scroll-y"), l.style.removeProperty("--v-scrollbar-offset"), l.classList.remove("v-overlay-scroll-blocked"), l.scrollLeft = -o, l.scrollTop = -u, l.style.scrollBehavior = c;
}), s && e.root.value.classList.remove("v-overlay--scroll-blocked");
});
}
function Yy(e, t, n) {
let a = !1, r = -1, s = -1;
function l(i) {
By(() => {
const o = performance.now();
e.updateLocation.value?.(i), a = (performance.now() - o) / (1e3 / 60) > 2;
});
}
s = (typeof requestIdleCallback > "u" ? (i) => i() : requestIdleCallback)(() => {
n.run(() => {
Ec(e.targetEl.value ?? e.contentEl.value, (i) => {
a ? (cancelAnimationFrame(r), r = requestAnimationFrame(() => {
r = requestAnimationFrame(() => {
l(i);
});
})) : l(i);
});
});
}), mt(() => {
typeof cancelIdleCallback < "u" && cancelIdleCallback(s), cancelAnimationFrame(r);
});
}
function Ec(e, t) {
const n = [document, ...Cr(e)];
n.forEach((a) => {
a.addEventListener("scroll", t, {
passive: !0
});
}), mt(() => {
n.forEach((a) => {
a.removeEventListener("scroll", t);
});
});
}
const ll = Symbol.for("vuetify:v-menu"), jy = M({
closeDelay: [Number, String],
openDelay: [Number, String]
}, "delay");
function Wy(e, t) {
let n = () => {
};
function a(l) {
n?.();
const i = Number(l ? e.openDelay : e.closeDelay);
return new Promise((o) => {
n = Lm(i, () => {
t?.(l), o(l);
});
});
}
function r() {
return a(!0);
}
function s() {
return a(!1);
}
return {
clearDelay: n,
runOpenDelay: r,
runCloseDelay: s
};
}
const Gy = M({
target: [String, Object],
activator: [String, Object],
activatorProps: {
type: Object,
default: () => ({})
},
openOnClick: {
type: Boolean,
default: void 0
},
openOnHover: Boolean,
openOnFocus: {
type: Boolean,
default: void 0
},
closeOnContentClick: Boolean,
...jy()
}, "VOverlay-activator");
function Qy(e, t) {
let {
isActive: n,
isTop: a,
contentEl: r
} = t;
const s = Ue("useActivator"), l = R();
let i = !1, o = !1, u = !0;
const c = _(() => e.openOnFocus || e.openOnFocus == null && e.openOnHover), d = _(() => e.openOnClick || e.openOnClick == null && !e.openOnHover && !c.value), {
runOpenDelay: f,
runCloseDelay: v
} = Wy(e, (w) => {
w === (e.openOnHover && i || c.value && o) && !(e.openOnHover && n.value && !a.value) && (n.value !== w && (u = !0), n.value = w);
}), m = R(), y = {
onClick: (w) => {
w.stopPropagation(), l.value = w.currentTarget || w.target, n.value || (m.value = [w.clientX, w.clientY]), n.value = !n.value;
},
onMouseenter: (w) => {
w.sourceCapabilities?.firesTouchEvents || (i = !0, l.value = w.currentTarget || w.target, f());
},
onMouseleave: (w) => {
i = !1, v();
},
onFocus: (w) => {
Xn(w.target, ":focus-visible") !== !1 && (o = !0, w.stopPropagation(), l.value = w.currentTarget || w.target, f());
},
onBlur: (w) => {
o = !1, w.stopPropagation(), v();
}
}, h = _(() => {
const w = {};
return d.value && (w.onClick = y.onClick), e.openOnHover && (w.onMouseenter = y.onMouseenter, w.onMouseleave = y.onMouseleave), c.value && (w.onFocus = y.onFocus, w.onBlur = y.onBlur), w;
}), b = _(() => {
const w = {};
if (e.openOnHover && (w.onMouseenter = () => {
i = !0, f();
}, w.onMouseleave = () => {
i = !1, v();
}), c.value && (w.onFocusin = () => {
o = !0, f();
}, w.onFocusout = () => {
o = !1, v();
}), e.closeOnContentClick) {
const T = De(ll, null);
w.onClick = () => {
n.value = !1, T?.closeParents();
};
}
return w;
}), S = _(() => {
const w = {};
return e.openOnHover && (w.onMouseenter = () => {
u && (i = !0, u = !1, f());
}, w.onMouseleave = () => {
i = !1, v();
}), w;
});
re(a, (w) => {
w && (e.openOnHover && !i && (!c.value || !o) || c.value && !o && (!e.openOnHover || !i)) && !r.value?.contains(document.activeElement) && (n.value = !1);
}), re(n, (w) => {
w || setTimeout(() => {
m.value = void 0;
});
}, {
flush: "post"
});
const P = Ks();
Ot(() => {
P.value && Ge(() => {
l.value = P.el;
});
});
const O = Ks(), k = _(() => e.target === "cursor" && m.value ? m.value : O.value ? O.el : Dc(e.target, s) || l.value), E = _(() => Array.isArray(k.value) ? void 0 : k.value);
let V;
return re(() => !!e.activator, (w) => {
w && Be ? (V = kl(), V.run(() => {
qy(e, s, {
activatorEl: l,
activatorEvents: h
});
})) : V && V.stop();
}, {
flush: "post",
immediate: !0
}), mt(() => {
V?.stop();
}), {
activatorEl: l,
activatorRef: P,
target: k,
targetEl: E,
targetRef: O,
activatorEvents: h,
contentEvents: b,
scrimEvents: S
};
}
function qy(e, t, n) {
let {
activatorEl: a,
activatorEvents: r
} = n;
re(() => e.activator, (o, u) => {
if (u && o !== u) {
const c = i(u);
c && l(c);
}
o && Ge(() => s());
}, {
immediate: !0
}), re(() => e.activatorProps, () => {
s();
}), mt(() => {
l();
});
function s() {
let o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : i(), u = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : e.activatorProps;
o && Ym(o, j(r.value, u));
}
function l() {
let o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : i(), u = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : e.activatorProps;
o && jm(o, j(r.value, u));
}
function i() {
let o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : e.activator;
const u = Dc(o, t);
return a.value = u?.nodeType === Node.ELEMENT_NODE ? u : void 0, a.value;
}
}
function Dc(e, t) {
if (!e) return;
let n;
if (e === "parent") {
let a = t?.proxy?.$el?.parentNode;
for (; a?.hasAttribute("data-no-activator"); )
a = a.parentNode;
n = a;
} else typeof e == "string" ? n = document.querySelector(e) : "$el" in e ? n = e.$el : n = e;
return n;
}
function Ky() {
if (!Be) return ne(!1);
const {
ssr: e
} = $n();
if (e) {
const t = ne(!1);
return Ba(() => {
t.value = !0;
}), t;
} else
return ne(!0);
}
const Jy = M({
eager: Boolean
}, "lazy");
function Zy(e, t) {
const n = ne(!1), a = I(() => n.value || e.eager || t.value);
re(t, () => n.value = !0);
function r() {
e.eager || (n.value = !1);
}
return {
isBooted: n,
hasContent: a,
onAfterLeave: r
};
}
function Jl() {
const t = Ue("useScopeId").vnode.scopeId;
return {
scopeId: t ? {
[t]: ""
} : void 0
};
}
const Co = Symbol.for("vuetify:stack"), ya = Zn([]);
function Xy(e, t, n) {
const a = Ue("useStack"), r = !n, s = De(Co, void 0), l = Zn({
activeChildren: /* @__PURE__ */ new Set()
});
We(Co, l);
const i = ne(Number(rn(t)));
Fn(e, () => {
const c = ya.at(-1)?.[1];
i.value = c ? c + 10 : Number(rn(t)), r && ya.push([a.uid, i.value]), s?.activeChildren.add(a.uid), mt(() => {
if (r) {
const d = He(ya).findIndex((f) => f[0] === a.uid);
ya.splice(d, 1);
}
s?.activeChildren.delete(a.uid);
});
});
const o = ne(!0);
r && Ot(() => {
const c = ya.at(-1)?.[0] === a.uid;
setTimeout(() => o.value = c);
});
const u = I(() => !l.activeChildren.size);
return {
globalTop: Cl(o),
localTop: u,
stackStyles: I(() => ({
zIndex: i.value
}))
};
}
function eg(e) {
return {
teleportTarget: _(() => {
const n = e();
if (n === !0 || !Be) return;
const a = n === !1 ? document.body : typeof n == "string" ? document.querySelector(n) : n;
if (a == null) {
Fr(`Unable to locate target ${n}`);
return;
}
let r = [...a.children].find((s) => s.matches(".v-overlay-container"));
return r || (r = document.createElement("div"), r.className = "v-overlay-container", a.appendChild(r)), r;
})
};
}
function tg() {
return !0;
}
function Mc(e, t, n) {
if (!e || Rc(e, n) === !1) return !1;
const a = $u(t);
if (typeof ShadowRoot < "u" && a instanceof ShadowRoot && a.host === e.target) return !1;
const r = (typeof n.value == "object" && n.value.include || (() => []))();
return r.push(t), !r.some((s) => s?.contains(e.target));
}
function Rc(e, t) {
return (typeof t.value == "object" && t.value.closeConditional || tg)(e);
}
function ng(e, t, n) {
const a = typeof n.value == "function" ? n.value : n.value.handler;
e.shadowTarget = e.target, t._clickOutside.lastMousedownWasOutside && Mc(e, t, n) && setTimeout(() => {
Rc(e, n) && a && a(e);
}, 0);
}
function Po(e, t) {
const n = $u(e);
t(document), typeof ShadowRoot < "u" && n instanceof ShadowRoot && t(n);
}
const xo = {
// [data-app] may not be found
// if using bind, inserted makes
// sure that the root element is
// available, iOS does not support
// clicks on body
mounted(e, t) {
const n = (r) => ng(r, e, t), a = (r) => {
e._clickOutside.lastMousedownWasOutside = Mc(r, e, t);
};
Po(e, (r) => {
r.addEventListener("click", n, !0), r.addEventListener("mousedown", a, !0);
}), e._clickOutside || (e._clickOutside = {
lastMousedownWasOutside: !1
}), e._clickOutside[t.instance.$.uid] = {
onClick: n,
onMousedown: a
};
},
beforeUnmount(e, t) {
e._clickOutside && (Po(e, (n) => {
if (!n || !e._clickOutside?.[t.instance.$.uid]) return;
const {
onClick: a,
onMousedown: r
} = e._clickOutside[t.instance.$.uid];
n.removeEventListener("click", a, !0), n.removeEventListener("mousedown", r, !0);
}), delete e._clickOutside[t.instance.$.uid]);
}
};
function ag(e) {
const {
modelValue: t,
color: n,
...a
} = e;
return g(Mn, {
name: "fade-transition",
appear: !0
}, {
default: () => [e.modelValue && p("div", j({
class: ["v-overlay__scrim", e.color.backgroundColorClasses.value],
style: e.color.backgroundColorStyles.value
}, a), null)]
});
}
const Zl = M({
absolute: Boolean,
attach: [Boolean, String, Object],
closeOnBack: {
type: Boolean,
default: !0
},
contained: Boolean,
contentClass: null,
contentProps: null,
disabled: Boolean,
opacity: [Number, String],
noClickAnimation: Boolean,
modelValue: Boolean,
persistent: Boolean,
scrim: {
type: [Boolean, String],
default: !0
},
zIndex: {
type: [Number, String],
default: 2e3
},
...Gy(),
...ce(),
...un(),
...Jy(),
...My(),
...$y(),
...Ye(),
...ia()
}, "VOverlay"), Or = G()({
name: "VOverlay",
directives: {
vClickOutside: xo
},
inheritAttrs: !1,
props: {
_disableGlobalStack: Boolean,
...Zl()
},
emits: {
"click:outside": (e) => !0,
"update:modelValue": (e) => !0,
keydown: (e) => !0,
afterEnter: () => !0,
afterLeave: () => !0
},
setup(e, t) {
let {
slots: n,
attrs: a,
emit: r
} = t;
const s = Ue("VOverlay"), l = R(), i = R(), o = R(), u = _e(e, "modelValue"), c = _({
get: () => u.value,
set: (K) => {
K && e.disabled || (u.value = K);
}
}), {
themeClasses: d
} = Ze(e), {
rtlClasses: f,
isRtl: v
} = Mt(), {
hasContent: m,
onAfterLeave: y
} = Zy(e, c), h = $t(() => typeof e.scrim == "string" ? e.scrim : null), {
globalTop: b,
localTop: S,
stackStyles: P
} = Xy(c, () => e.zIndex, e._disableGlobalStack), {
activatorEl: O,
activatorRef: k,
target: E,
targetEl: V,
targetRef: w,
activatorEvents: T,
contentEvents: L,
scrimEvents: $
} = Qy(e, {
isActive: c,
isTop: S,
contentEl: o
}), {
teleportTarget: B
} = eg(() => {
const K = e.attach || e.contained;
if (K) return K;
const Ae = O?.value?.getRootNode() || s.proxy?.$el?.getRootNode();
return Ae instanceof ShadowRoot ? Ae : !1;
}), {
dimensionStyles: D
} = cn(e), H = Ky(), {
scopeId: Y
} = Jl();
re(() => e.disabled, (K) => {
K && (c.value = !1);
});
const {
contentStyles: X,
updateLocation: oe
} = Ry(e, {
isRtl: v,
contentEl: o,
target: E,
isActive: c
});
Uy(e, {
root: l,
contentEl: o,
targetEl: V,
isActive: c,
updateLocation: oe
});
function ge(K) {
r("click:outside", K), e.persistent ? ie() : c.value = !1;
}
function Ie(K) {
return c.value && b.value && // If using scrim, only close if clicking on it rather than anything opened on top
(!e.scrim || K.target === i.value || K instanceof MouseEvent && K.shadowTarget === i.value);
}
Be && re(c, (K) => {
K ? window.addEventListener("keydown", x) : window.removeEventListener("keydown", x);
}, {
immediate: !0
}), At(() => {
Be && window.removeEventListener("keydown", x);
});
function x(K) {
K.key === "Escape" && b.value && (o.value?.contains(document.activeElement) || r("keydown", K), e.persistent ? ie() : (c.value = !1, o.value?.contains(document.activeElement) && O.value?.focus()));
}
function A(K) {
K.key === "Escape" && !b.value || r("keydown", K);
}
const N = ly();
Fn(() => e.closeOnBack, () => {
iy(N, (K) => {
b.value && c.value ? (K(!1), e.persistent ? ie() : c.value = !1) : K();
});
});
const q = R();
re(() => c.value && (e.absolute || e.contained) && B.value == null, (K) => {
if (K) {
const Ae = Uu(l.value);
Ae && Ae !== document.scrollingElement && (q.value = Ae.scrollTop);
}
});
function ie() {
e.noClickAnimation || o.value && Gn(o.value, [{
transformOrigin: "center"
}, {
transform: "scale(1.03)"
}, {
transformOrigin: "center"
}], {
duration: 150,
easing: kr
});
}
function ae() {
r("afterEnter");
}
function se() {
y(), r("afterLeave");
}
return ee(() => p(pe, null, [n.activator?.({
isActive: c.value,
targetRef: w,
props: j({
ref: k
}, T.value, e.activatorProps)
}), H.value && m.value && g(Nf, {
disabled: !B.value,
to: B.value
}, {
default: () => [p("div", j({
class: ["v-overlay", {
"v-overlay--absolute": e.absolute || e.contained,
"v-overlay--active": c.value,
"v-overlay--contained": e.contained
}, d.value, f.value, e.class],
style: [P.value, {
"--v-overlay-opacity": e.opacity,
top: te(q.value)
}, e.style],
ref: l,
onKeydown: A
}, Y, a), [g(ag, j({
color: h,
modelValue: c.value && !!e.scrim,
ref: i
}, $.value), null), g(gn, {
appear: !0,
persisted: !0,
transition: e.transition,
target: E.value,
onAfterEnter: ae,
onAfterLeave: se
}, {
default: () => [ht(p("div", j({
ref: o,
class: ["v-overlay__content", e.contentClass],
style: [D.value, X.value]
}, L.value, e.contentProps), [n.default?.({
isActive: c
})]), [[Bn, c.value], [xo, {
handler: ge,
closeConditional: Ie,
include: () => [O.value]
}]])]
})])]
})])), {
activatorEl: O,
scrimEl: i,
target: E,
animateClick: ie,
contentEl: o,
globalTop: b,
localTop: S,
updateLocation: oe
};
}
}), Vs = Symbol("Forwarded refs");
function As(e, t) {
let n = e;
for (; n; ) {
const a = Reflect.getOwnPropertyDescriptor(n, t);
if (a) return a;
n = Object.getPrototypeOf(n);
}
}
function oa(e) {
for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), a = 1; a < t; a++)
n[a - 1] = arguments[a];
return e[Vs] = n, new Proxy(e, {
get(r, s) {
if (Reflect.has(r, s))
return Reflect.get(r, s);
if (!(typeof s == "symbol" || s.startsWith("$") || s.startsWith("__"))) {
for (const l of n)
if (l.value && Reflect.has(l.value, s)) {
const i = Reflect.get(l.value, s);
return typeof i == "function" ? i.bind(l.value) : i;
}
}
},
has(r, s) {
if (Reflect.has(r, s))
return !0;
if (typeof s == "symbol" || s.startsWith("$") || s.startsWith("__")) return !1;
for (const l of n)
if (l.value && Reflect.has(l.value, s))
return !0;
return !1;
},
set(r, s, l) {
if (Reflect.has(r, s))
return Reflect.set(r, s, l);
if (typeof s == "symbol" || s.startsWith("$") || s.startsWith("__")) return !1;
for (const i of n)
if (i.value && Reflect.has(i.value, s))
return Reflect.set(i.value, s, l);
return !1;
},
getOwnPropertyDescriptor(r, s) {
const l = Reflect.getOwnPropertyDescriptor(r, s);
if (l) return l;
if (!(typeof s == "symbol" || s.startsWith("$") || s.startsWith("__"))) {
for (const i of n) {
if (!i.value) continue;
const o = As(i.value, s) ?? ("_" in i.value ? As(i.value._?.setupState, s) : void 0);
if (o) return o;
}
for (const i of n) {
const o = i.value && i.value[Vs];
if (!o) continue;
const u = o.slice();
for (; u.length; ) {
const c = u.shift(), d = As(c.value, s);
if (d) return d;
const f = c.value && c.value[Vs];
f && u.push(...f);
}
}
}
}
});
}
const rg = M({
// TODO
// disableKeys: Boolean,
id: String,
submenu: Boolean,
...kn(Zl({
closeDelay: 250,
closeOnContentClick: !0,
locationStrategy: "connected",
location: void 0,
openDelay: 300,
scrim: !1,
scrollStrategy: "reposition",
transition: {
component: zl
}
}), ["absolute"])
}, "VMenu"), Fc = G()({
name: "VMenu",
props: rg(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const a = _e(e, "modelValue"), {
scopeId: r
} = Jl(), {
isRtl: s
} = Mt(), l = on(), i = I(() => e.id || `v-menu-${l}`), o = R(), u = De(ll, null), c = ne(/* @__PURE__ */ new Set());
We(ll, {
register() {
c.value.add(l);
},
unregister() {
c.value.delete(l);
},
closeParents(h) {
setTimeout(() => {
!c.value.size && !e.persistent && (h == null || o.value?.contentEl && !Nm(h, o.value.contentEl)) && (a.value = !1, u?.closeParents());
}, 40);
}
}), At(() => {
u?.unregister(), document.removeEventListener("focusin", d);
}), Bf(() => a.value = !1);
async function d(h) {
const b = h.relatedTarget, S = h.target;
await Ge(), a.value && b !== S && o.value?.contentEl && // We're the topmost menu
o.value?.globalTop && // It isn't the document or the menu body
![document, o.value.contentEl].includes(S) && // It isn't inside the menu body
!o.value.contentEl.contains(S) && Ia(o.value.contentEl)[0]?.focus();
}
re(a, (h) => {
h ? (u?.register(), Be && document.addEventListener("focusin", d, {
once: !0
})) : (u?.unregister(), Be && document.removeEventListener("focusin", d));
}, {
immediate: !0
});
function f(h) {
u?.closeParents(h);
}
function v(h) {
if (!e.disabled)
if (h.key === "Tab" || h.key === "Enter" && !e.closeOnContentClick) {
if (h.key === "Enter" && (h.target instanceof HTMLTextAreaElement || h.target instanceof HTMLInputElement && h.target.closest("form"))) return;
h.key === "Enter" && h.preventDefault(), Mu(Ia(o.value?.contentEl, !1), h.shiftKey ? "prev" : "next", (S) => S.tabIndex >= 0) || (a.value = !1, o.value?.activatorEl?.focus());
} else e.submenu && h.key === (s.value ? "ArrowRight" : "ArrowLeft") && (a.value = !1, o.value?.activatorEl?.focus());
}
function m(h) {
if (e.disabled) return;
const b = o.value?.contentEl;
b && a.value ? h.key === "ArrowDown" ? (h.preventDefault(), h.stopImmediatePropagation(), ka(b, "next")) : h.key === "ArrowUp" ? (h.preventDefault(), h.stopImmediatePropagation(), ka(b, "prev")) : e.submenu && (h.key === (s.value ? "ArrowRight" : "ArrowLeft") ? a.value = !1 : h.key === (s.value ? "ArrowLeft" : "ArrowRight") && (h.preventDefault(), ka(b, "first"))) : (e.submenu ? h.key === (s.value ? "ArrowLeft" : "ArrowRight") : ["ArrowDown", "ArrowUp"].includes(h.key)) && (a.value = !0, h.preventDefault(), setTimeout(() => setTimeout(() => m(h))));
}
const y = _(() => j({
"aria-haspopup": "menu",
"aria-expanded": String(a.value),
"aria-controls": i.value,
onKeydown: m
}, e.activatorProps));
return ee(() => {
const h = Or.filterProps(e);
return g(Or, j({
ref: o,
id: i.value,
class: ["v-menu", e.class],
style: e.style
}, h, {
modelValue: a.value,
"onUpdate:modelValue": (b) => a.value = b,
absolute: !0,
activatorProps: y.value,
location: e.location ?? (e.submenu ? "end" : "bottom"),
"onClick:outside": f,
onKeydown: v
}, r), {
activator: n.activator,
default: function() {
for (var b = arguments.length, S = new Array(b), P = 0; P < b; P++)
S[P] = arguments[P];
return g(Ne, {
root: "VMenu"
}, {
default: () => [n.default?.(...S)]
});
}
});
}), oa({
id: i,
ΨopenChildren: c
}, o);
}
}), sg = M({
active: Boolean,
disabled: Boolean,
max: [Number, String],
value: {
type: [Number, String],
default: 0
},
...ce(),
...ia({
transition: {
component: ac
}
})
}, "VCounter"), lg = G()({
name: "VCounter",
functional: !0,
props: sg(),
setup(e, t) {
let {
slots: n
} = t;
const a = I(() => e.max ? `${e.value} / ${e.max}` : String(e.value));
return ee(() => g(gn, {
transition: e.transition
}, {
default: () => [ht(p("div", {
class: Q(["v-counter", {
"text-error": e.max && !e.disabled && parseFloat(e.value) > parseFloat(e.max)
}, e.class]),
style: J(e.style)
}, [n.default ? n.default({
counter: a.value,
max: e.max,
value: e.value
}) : a.value]), [[Bn, e.active]])]
})), {};
}
}), ig = M({
floating: Boolean,
...ce()
}, "VFieldLabel"), lr = G()({
name: "VFieldLabel",
props: ig(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => g($l, {
class: Q(["v-field-label", {
"v-field-label--floating": e.floating
}, e.class]),
style: J(e.style),
"aria-hidden": e.floating || void 0
}, n)), {};
}
});
function Lc(e, t) {
const n = R(), a = ne(!1);
if (Vl) {
const r = new IntersectionObserver((s) => {
a.value = !!s.find((l) => l.isIntersecting);
}, t);
At(() => {
r.disconnect();
}), re(n, (s, l) => {
l && (r.unobserve(l), a.value = !1), s && r.observe(s);
}, {
flush: "post"
});
}
return {
intersectionRef: n,
isIntersecting: a
};
}
const Io = {
center: "center",
top: "bottom",
bottom: "top",
left: "right",
right: "left"
}, Xl = M({
location: String
}, "location");
function ei(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, n = arguments.length > 2 ? arguments[2] : void 0;
const {
isRtl: a
} = Mt();
return {
locationStyles: _(() => {
if (!e.location) return {};
const {
side: s,
align: l
} = Js(e.location.split(" ").length > 1 ? e.location : `${e.location} center`, a.value);
function i(u) {
return n ? n(u) : 0;
}
const o = {};
return s !== "center" && (t ? o[Io[s]] = `calc(100% - ${i(s)}px)` : o[s] = 0), l !== "center" ? t ? o[Io[l]] = `calc(100% - ${i(l)}px)` : o[l] = 0 : (s === "center" ? o.top = o.left = "50%" : o[{
top: "left",
bottom: "left",
left: "top",
right: "top"
}[s]] = "50%", o.transform = {
top: "translateX(-50%)",
bottom: "translateX(-50%)",
left: "translateY(-50%)",
right: "translateY(-50%)",
center: "translate(-50%, -50%)"
}[s]), o;
})
};
}
const og = M({
absolute: Boolean,
active: {
type: Boolean,
default: !0
},
bgColor: String,
bgOpacity: [Number, String],
bufferValue: {
type: [Number, String],
default: 0
},
bufferColor: String,
bufferOpacity: [Number, String],
clickable: Boolean,
color: String,
height: {
type: [Number, String],
default: 4
},
indeterminate: Boolean,
max: {
type: [Number, String],
default: 100
},
modelValue: {
type: [Number, String],
default: 0
},
opacity: [Number, String],
reverse: Boolean,
stream: Boolean,
striped: Boolean,
roundedBar: Boolean,
...ce(),
...Xl({
location: "top"
}),
...kt(),
...Le(),
...Ye()
}, "VProgressLinear"), ti = G()({
name: "VProgressLinear",
props: og(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const a = _e(e, "modelValue"), {
isRtl: r,
rtlClasses: s
} = Mt(), {
themeClasses: l
} = Ze(e), {
locationStyles: i
} = ei(e), {
textColorClasses: o,
textColorStyles: u
} = Ht(() => e.color), {
backgroundColorClasses: c,
backgroundColorStyles: d
} = $t(() => e.bgColor || e.color), {
backgroundColorClasses: f,
backgroundColorStyles: v
} = $t(() => e.bufferColor || e.bgColor || e.color), {
backgroundColorClasses: m,
backgroundColorStyles: y
} = $t(() => e.color), {
roundedClasses: h
} = Dt(e), {
intersectionRef: b,
isIntersecting: S
} = Lc(), P = _(() => parseFloat(e.max)), O = _(() => parseFloat(e.height)), k = _(() => bt(parseFloat(e.bufferValue) / P.value * 100, 0, 100)), E = _(() => bt(parseFloat(a.value) / P.value * 100, 0, 100)), V = _(() => r.value !== e.reverse), w = _(() => e.indeterminate ? "fade-transition" : "slide-x-transition"), T = Be && window.matchMedia?.("(forced-colors: active)").matches;
function L($) {
if (!b.value) return;
const {
left: B,
right: D,
width: H
} = b.value.getBoundingClientRect(), Y = V.value ? H - $.clientX + (D - H) : $.clientX - B;
a.value = Math.round(Y / H * P.value);
}
return ee(() => g(e.tag, {
ref: b,
class: Q(["v-progress-linear", {
"v-progress-linear--absolute": e.absolute,
"v-progress-linear--active": e.active && S.value,
"v-progress-linear--reverse": V.value,
"v-progress-linear--rounded": e.rounded,
"v-progress-linear--rounded-bar": e.roundedBar,
"v-progress-linear--striped": e.striped
}, h.value, l.value, s.value, e.class]),
style: J([{
bottom: e.location === "bottom" ? 0 : void 0,
top: e.location === "top" ? 0 : void 0,
height: e.active ? te(O.value) : 0,
"--v-progress-linear-height": te(O.value),
...e.absolute ? i.value : {}
}, e.style]),
role: "progressbar",
"aria-hidden": e.active ? "false" : "true",
"aria-valuemin": "0",
"aria-valuemax": e.max,
"aria-valuenow": e.indeterminate ? void 0 : Math.min(parseFloat(a.value), P.value),
onClick: e.clickable && L
}, {
default: () => [e.stream && p("div", {
key: "stream",
class: Q(["v-progress-linear__stream", o.value]),
style: J({
...u.value,
[V.value ? "left" : "right"]: te(-O.value),
borderTop: `${te(O.value / 2)} dotted`,
opacity: parseFloat(e.bufferOpacity),
top: `calc(50% - ${te(O.value / 4)})`,
width: te(100 - k.value, "%"),
"--v-progress-linear-stream-to": te(O.value * (V.value ? 1 : -1))
})
}, null), p("div", {
class: Q(["v-progress-linear__background", T ? void 0 : c.value]),
style: J([d.value, {
opacity: parseFloat(e.bgOpacity),
width: e.stream ? 0 : void 0
}])
}, null), p("div", {
class: Q(["v-progress-linear__buffer", T ? void 0 : f.value]),
style: J([v.value, {
opacity: parseFloat(e.bufferOpacity),
width: te(k.value, "%")
}])
}, null), g(Mn, {
name: w.value
}, {
default: () => [e.indeterminate ? p("div", {
class: "v-progress-linear__indeterminate"
}, [["long", "short"].map(($) => p("div", {
key: $,
class: Q(["v-progress-linear__indeterminate", $, T ? void 0 : m.value]),
style: J(y.value)
}, null))]) : p("div", {
class: Q(["v-progress-linear__determinate", T ? void 0 : m.value]),
style: J([y.value, {
width: te(E.value, "%")
}])
}, null)]
}), n.default && p("div", {
class: "v-progress-linear__content"
}, [n.default({
value: E.value,
buffer: k.value
})])]
})), {};
}
}), es = M({
loading: [Boolean, String]
}, "loader");
function Qa(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return {
loaderClasses: I(() => ({
[`${t}--loading`]: e.loading
}))
};
}
function ts(e, t) {
let {
slots: n
} = t;
return p("div", {
class: Q(`${e.name}__loader`)
}, [n.default?.({
color: e.color,
isActive: e.active
}) || g(ti, {
absolute: e.absolute,
active: e.active,
color: e.color,
height: "2",
indeterminate: !0
}, null)]);
}
const ug = ["underlined", "outlined", "filled", "solo", "solo-inverted", "solo-filled", "plain"], Nc = M({
appendInnerIcon: le,
bgColor: String,
clearable: Boolean,
clearIcon: {
type: le,
default: "$clear"
},
active: Boolean,
centerAffix: {
type: Boolean,
default: void 0
},
color: String,
baseColor: String,
dirty: Boolean,
disabled: {
type: Boolean,
default: null
},
glow: Boolean,
error: Boolean,
flat: Boolean,
iconColor: [Boolean, String],
label: String,
persistentClear: Boolean,
prependInnerIcon: le,
reverse: Boolean,
singleLine: Boolean,
variant: {
type: String,
default: "filled",
validator: (e) => ug.includes(e)
},
"onClick:clear": Je(),
"onClick:appendInner": Je(),
"onClick:prependInner": Je(),
...ce(),
...es(),
...kt(),
...Ye()
}, "VField"), Oo = G()({
name: "VField",
inheritAttrs: !1,
props: {
id: String,
...lc(),
...Nc()
},
emits: {
"update:focused": (e) => !0,
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
attrs: n,
emit: a,
slots: r
} = t;
const {
themeClasses: s
} = Ze(e), {
loaderClasses: l
} = Qa(e), {
focusClasses: i,
isFocused: o,
focus: u,
blur: c
} = Hl(e), {
InputIcon: d
} = ec(e), {
roundedClasses: f
} = Dt(e), {
rtlClasses: v
} = Mt(), m = I(() => e.dirty || e.active), y = I(() => !!(e.label || r.label)), h = I(() => !e.singleLine && y.value), b = on(), S = _(() => e.id || `input-${b}`), P = I(() => `${S.value}-messages`), O = R(), k = R(), E = R(), V = _(() => ["plain", "underlined"].includes(e.variant)), w = _(() => e.error || e.disabled ? void 0 : m.value && o.value ? e.color : e.baseColor), T = _(() => {
if (!(!e.iconColor || e.glow && !o.value))
return e.iconColor === !0 ? w.value : e.iconColor;
}), {
backgroundColorClasses: L,
backgroundColorStyles: $
} = $t(() => e.bgColor), {
textColorClasses: B,
textColorStyles: D
} = Ht(w);
re(m, (X) => {
if (h.value) {
const oe = O.value.$el, ge = k.value.$el;
requestAnimationFrame(() => {
const Ie = Rl(oe), x = ge.getBoundingClientRect(), A = x.x - Ie.x, N = x.y - Ie.y - (Ie.height / 2 - x.height / 2), q = x.width / 0.75, ie = Math.abs(q - Ie.width) > 1 ? {
maxWidth: te(q)
} : void 0, ae = getComputedStyle(oe), se = getComputedStyle(ge), K = parseFloat(ae.transitionDuration) * 1e3 || 150, Ae = parseFloat(se.getPropertyValue("--v-field-label-scale")), Se = se.getPropertyValue("color");
oe.style.visibility = "visible", ge.style.visibility = "hidden", Gn(oe, {
transform: `translate(${A}px, ${N}px) scale(${Ae})`,
color: Se,
...ie
}, {
duration: K,
easing: kr,
direction: X ? "normal" : "reverse"
}).finished.then(() => {
oe.style.removeProperty("visibility"), ge.style.removeProperty("visibility");
});
});
}
}, {
flush: "post"
});
const H = _(() => ({
isActive: m,
isFocused: o,
controlRef: E,
blur: c,
focus: u
}));
function Y(X) {
X.target !== document.activeElement && X.preventDefault();
}
return ee(() => {
const X = e.variant === "outlined", oe = !!(r["prepend-inner"] || e.prependInnerIcon), ge = !!(e.clearable || r.clear) && !e.disabled, Ie = !!(r["append-inner"] || e.appendInnerIcon || ge), x = () => r.label ? r.label({
...H.value,
label: e.label,
props: {
for: S.value
}
}) : e.label;
return p("div", j({
class: ["v-field", {
"v-field--active": m.value,
"v-field--appended": Ie,
"v-field--center-affix": e.centerAffix ?? !V.value,
"v-field--disabled": e.disabled,
"v-field--dirty": e.dirty,
"v-field--error": e.error,
"v-field--glow": e.glow,
"v-field--flat": e.flat,
"v-field--has-background": !!e.bgColor,
"v-field--persistent-clear": e.persistentClear,
"v-field--prepended": oe,
"v-field--reverse": e.reverse,
"v-field--single-line": e.singleLine,
"v-field--no-label": !x(),
[`v-field--variant-${e.variant}`]: !0
}, s.value, L.value, i.value, l.value, f.value, v.value, e.class],
style: [$.value, e.style],
onClick: Y
}, n), [p("div", {
class: "v-field__overlay"
}, null), g(ts, {
name: "v-field",
active: !!e.loading,
color: e.error ? "error" : typeof e.loading == "string" ? e.loading : e.color
}, {
default: r.loader
}), oe && p("div", {
key: "prepend",
class: "v-field__prepend-inner"
}, [e.prependInnerIcon && g(d, {
key: "prepend-icon",
name: "prependInner",
color: T.value
}, null), r["prepend-inner"]?.(H.value)]), p("div", {
class: "v-field__field",
"data-no-activator": ""
}, [["filled", "solo", "solo-inverted", "solo-filled"].includes(e.variant) && h.value && g(lr, {
key: "floating-label",
ref: k,
class: Q([B.value]),
floating: !0,
for: S.value,
style: J(D.value)
}, {
default: () => [x()]
}), y.value && g(lr, {
key: "label",
ref: O,
for: S.value
}, {
default: () => [x()]
}), r.default?.({
...H.value,
props: {
id: S.value,
class: "v-field__input",
"aria-describedby": P.value
},
focus: u,
blur: c
}) ?? p("div", {
id: S.value,
class: "v-field__input",
"aria-describedby": P.value
}, null)]), ge && g(sc, {
key: "clear"
}, {
default: () => [ht(p("div", {
class: "v-field__clearable",
onMousedown: (A) => {
A.preventDefault(), A.stopPropagation();
}
}, [g(Ne, {
defaults: {
VIcon: {
icon: e.clearIcon
}
}
}, {
default: () => [r.clear ? r.clear({
...H.value,
props: {
onFocus: u,
onBlur: c,
onClick: e["onClick:clear"],
tabindex: -1
}
}) : g(d, {
name: "clear",
onFocus: u,
onBlur: c,
tabindex: -1
}, null)]
})]), [[Bn, e.dirty]])]
}), Ie && p("div", {
key: "append",
class: "v-field__append-inner"
}, [r["append-inner"]?.(H.value), e.appendInnerIcon && g(d, {
key: "append-icon",
name: "appendInner",
color: T.value
}, null)]), p("div", {
class: Q(["v-field__outline", B.value]),
style: J(D.value)
}, [X && p(pe, null, [p("div", {
class: "v-field__outline__start"
}, null), h.value && p("div", {
class: "v-field__outline__notch"
}, [g(lr, {
ref: k,
floating: !0,
for: S.value
}, {
default: () => [x()]
})]), p("div", {
class: "v-field__outline__end"
}, null)]), V.value && h.value && g(lr, {
ref: k,
floating: !0,
for: S.value
}, {
default: () => [x()]
})])]);
}), {
controlRef: E,
fieldIconColor: T
};
}
}), cg = ["color", "file", "time", "date", "datetime-local", "week", "month"], ni = M({
autofocus: Boolean,
counter: [Boolean, Number, String],
counterValue: [Number, Function],
prefix: String,
placeholder: String,
persistentPlaceholder: Boolean,
persistentCounter: Boolean,
suffix: String,
role: String,
type: {
type: String,
default: "text"
},
modelModifiers: Object,
...qr(),
...Nc()
}, "VTextField"), Da = G()({
name: "VTextField",
directives: {
vIntersect: Pr
},
inheritAttrs: !1,
props: ni(),
emits: {
"click:control": (e) => !0,
"mousedown:control": (e) => !0,
"update:focused": (e) => !0,
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
attrs: n,
emit: a,
slots: r
} = t;
const s = _e(e, "modelValue"), {
isFocused: l,
focus: i,
blur: o
} = Hl(e), u = _(() => typeof e.counterValue == "function" ? e.counterValue(s.value) : typeof e.counterValue == "number" ? e.counterValue : (s.value ?? "").toString().length), c = _(() => {
if (n.maxlength) return n.maxlength;
if (!(!e.counter || typeof e.counter != "number" && typeof e.counter != "string"))
return e.counter;
}), d = _(() => ["plain", "underlined"].includes(e.variant));
function f(E, V) {
!e.autofocus || !E || V[0].target?.focus?.();
}
const v = R(), m = R(), y = R(), h = _(() => cg.includes(e.type) || e.persistentPlaceholder || l.value || e.active);
function b() {
y.value !== document.activeElement && y.value?.focus(), l.value || i();
}
function S(E) {
a("mousedown:control", E), E.target !== y.value && (b(), E.preventDefault());
}
function P(E) {
b(), a("click:control", E);
}
function O(E, V) {
E.stopPropagation(), b(), Ge(() => {
s.value = null, V(), Du(e["onClick:clear"], E);
});
}
function k(E) {
const V = E.target;
if (s.value = V.value, e.modelModifiers?.trim && ["text", "search", "password", "tel", "url"].includes(e.type)) {
const w = [V.selectionStart, V.selectionEnd];
Ge(() => {
V.selectionStart = w[0], V.selectionEnd = w[1];
});
}
}
return ee(() => {
const E = !!(r.counter || e.counter !== !1 && e.counter != null), V = !!(E || r.details), [w, T] = Wr(n), {
modelValue: L,
...$
} = ea.filterProps(e), B = Oo.filterProps(e);
return g(ea, j({
ref: v,
modelValue: s.value,
"onUpdate:modelValue": (D) => s.value = D,
class: ["v-text-field", {
"v-text-field--prefixed": e.prefix,
"v-text-field--suffixed": e.suffix,
"v-input--plain-underlined": d.value
}, e.class],
style: e.style
}, w, $, {
centerAffix: !d.value,
focused: l.value
}), {
...r,
default: (D) => {
let {
id: H,
isDisabled: Y,
isDirty: X,
isReadonly: oe,
isValid: ge,
reset: Ie
} = D;
return g(Oo, j({
ref: m,
onMousedown: S,
onClick: P,
"onClick:clear": (x) => O(x, Ie),
"onClick:prependInner": e["onClick:prependInner"],
"onClick:appendInner": e["onClick:appendInner"],
role: e.role
}, B, {
id: H.value,
active: h.value || X.value,
dirty: X.value || e.dirty,
disabled: Y.value,
focused: l.value,
error: ge.value === !1
}), {
...r,
default: (x) => {
let {
props: {
class: A,
...N
}
} = x;
const q = ht(p("input", j({
ref: y,
value: s.value,
onInput: k,
autofocus: e.autofocus,
readonly: oe.value,
disabled: Y.value,
name: e.name,
placeholder: e.placeholder,
size: 1,
type: e.type,
onFocus: b,
onBlur: o
}, N, T), null), [[Pr, {
handler: f
}, null, {
once: !0
}]]);
return p(pe, null, [e.prefix && p("span", {
class: "v-text-field__prefix"
}, [p("span", {
class: "v-text-field__prefix__text"
}, [e.prefix])]), r.default ? p("div", {
class: Q(A),
"data-no-activator": ""
}, [r.default(), q]) : $f(q, {
class: A
}), e.suffix && p("span", {
class: "v-text-field__suffix"
}, [p("span", {
class: "v-text-field__suffix__text"
}, [e.suffix])])]);
}
});
},
details: V ? (D) => p(pe, null, [r.details?.(D), E && p(pe, null, [p("span", null, null), g(lg, {
active: e.persistentCounter || l.value,
value: u.value,
max: c.value,
disabled: e.disabled
}, r.counter)])]) : void 0
});
}), oa({}, v, m, y);
}
}), dg = M({
renderless: Boolean,
...ce()
}, "VVirtualScrollItem"), fg = G()({
name: "VVirtualScrollItem",
inheritAttrs: !1,
props: dg(),
emits: {
"update:height": (e) => !0
},
setup(e, t) {
let {
attrs: n,
emit: a,
slots: r
} = t;
const {
resizeRef: s,
contentRect: l
} = ta(void 0, "border");
re(() => l.value?.height, (i) => {
i != null && a("update:height", i);
}), ee(() => e.renderless ? p(pe, null, [r.default?.({
itemRef: s
})]) : p("div", j({
ref: s,
class: ["v-virtual-scroll__item", e.class],
style: e.style
}, n), [r.default?.()]));
}
}), hg = -1, mg = 1, Es = 100, vg = M({
itemHeight: {
type: [Number, String],
default: null
},
itemKey: {
type: [String, Array, Function],
default: null
},
height: [Number, String]
}, "virtual");
function yg(e, t) {
const n = $n(), a = ne(0);
Ot(() => {
a.value = parseFloat(e.itemHeight || 0);
});
const r = ne(0), s = ne(Math.ceil(
// Assume 16px items filling the entire screen height if
// not provided. This is probably incorrect but it minimises
// the chance of ending up with empty space at the bottom.
// The default value is set here to avoid poisoning getSize()
(parseInt(e.height) || n.height.value) / (a.value || 16)
) || 1), l = ne(0), i = ne(0), o = R(), u = R();
let c = 0;
const {
resizeRef: d,
contentRect: f
} = ta();
Ot(() => {
d.value = o.value;
});
const v = _(() => o.value === document.documentElement ? n.height.value : f.value?.height || parseInt(e.height) || 0), m = _(() => !!(o.value && u.value && v.value && a.value));
let y = Array.from({
length: t.value.length
}), h = Array.from({
length: t.value.length
});
const b = ne(0);
let S = -1;
function P(x) {
return y[x] || a.value;
}
const O = Dm(() => {
const x = performance.now();
h[0] = 0;
const A = t.value.length;
for (let N = 1; N <= A - 1; N++)
h[N] = (h[N - 1] || 0) + P(N - 1);
b.value = Math.max(b.value, performance.now() - x);
}, b), k = re(m, (x) => {
x && (k(), c = u.value.offsetTop, O.immediate(), X(), ~S && Ge(() => {
Be && window.requestAnimationFrame(() => {
ge(S), S = -1;
});
}));
});
mt(() => {
O.clear();
});
function E(x, A) {
const N = y[x], q = a.value;
a.value = q ? Math.min(a.value, A) : A, (N !== A || q !== a.value) && (y[x] = A, O());
}
function V(x) {
return x = bt(x, 0, t.value.length - 1), h[x] || 0;
}
function w(x) {
return gg(h, x);
}
let T = 0, L = 0, $ = 0;
re(v, (x, A) => {
A && (X(), x < A && requestAnimationFrame(() => {
L = 0, X();
}));
});
let B = -1;
function D() {
if (!o.value || !u.value) return;
const x = o.value.scrollTop, A = performance.now();
A - $ > 500 ? (L = Math.sign(x - T), c = u.value.offsetTop) : L = x - T, T = x, $ = A, window.clearTimeout(B), B = window.setTimeout(H, 500), X();
}
function H() {
!o.value || !u.value || (L = 0, $ = 0, window.clearTimeout(B), X());
}
let Y = -1;
function X() {
cancelAnimationFrame(Y), Y = requestAnimationFrame(oe);
}
function oe() {
if (!o.value || !v.value) return;
const x = T - c, A = Math.sign(L), N = Math.max(0, x - Es), q = bt(w(N), 0, t.value.length), ie = x + v.value + Es, ae = bt(w(ie) + 1, q + 1, t.value.length);
if (
// Only update the side we're scrolling towards,
// the other side will be updated incidentally
(A !== hg || q < r.value) && (A !== mg || ae > s.value)
) {
const se = V(r.value) - V(q), K = V(ae) - V(s.value);
Math.max(se, K) > Es ? (r.value = q, s.value = ae) : (q <= 0 && (r.value = q), ae >= t.value.length && (s.value = ae));
}
l.value = V(r.value), i.value = V(t.value.length) - V(s.value);
}
function ge(x) {
const A = V(x);
!o.value || x && !A ? S = x : o.value.scrollTop = A;
}
const Ie = _(() => t.value.slice(r.value, s.value).map((x, A) => {
const N = A + r.value;
return {
raw: x,
index: N,
key: ot(x, e.itemKey, N)
};
}));
return re(t, () => {
y = Array.from({
length: t.value.length
}), h = Array.from({
length: t.value.length
}), O.immediate(), X();
}, {
deep: 1
}), {
calculateVisibleItems: X,
containerRef: o,
markerRef: u,
computedItems: Ie,
paddingTop: l,
paddingBottom: i,
scrollToIndex: ge,
handleScroll: D,
handleScrollend: H,
handleItemResize: E
};
}
function gg(e, t) {
let n = e.length - 1, a = 0, r = 0, s = null, l = -1;
if (e[n] < t)
return n;
for (; a <= n; )
if (r = a + n >> 1, s = e[r], s > t)
n = r - 1;
else if (s < t)
l = r, a = r + 1;
else return s === t ? r : a;
return l;
}
const bg = M({
items: {
type: Array,
default: () => []
},
renderless: Boolean,
...vg(),
...ce(),
...un()
}, "VVirtualScroll"), Bc = G()({
name: "VVirtualScroll",
props: bg(),
setup(e, t) {
let {
slots: n
} = t;
const a = Ue("VVirtualScroll"), {
dimensionStyles: r
} = cn(e), {
calculateVisibleItems: s,
containerRef: l,
markerRef: i,
handleScroll: o,
handleScrollend: u,
handleItemResize: c,
scrollToIndex: d,
paddingTop: f,
paddingBottom: v,
computedItems: m
} = yg(e, I(() => e.items));
return Fn(() => e.renderless, () => {
function y() {
const b = (arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1) ? "addEventListener" : "removeEventListener";
l.value === document.documentElement ? (document[b]("scroll", o, {
passive: !0
}), document[b]("scrollend", u)) : (l.value?.[b]("scroll", o, {
passive: !0
}), l.value?.[b]("scrollend", u));
}
Ba(() => {
l.value = Uu(a.vnode.el, !0), y(!0);
}), mt(y);
}), ee(() => {
const y = m.value.map((h) => g(fg, {
key: h.key,
renderless: e.renderless,
"onUpdate:height": (b) => c(h.index, b)
}, {
default: (b) => n.default?.({
item: h.raw,
index: h.index,
...b
})
}));
return e.renderless ? p(pe, null, [p("div", {
ref: i,
class: "v-virtual-scroll__spacer",
style: J({
paddingTop: te(f.value)
})
}, null), y, p("div", {
class: "v-virtual-scroll__spacer",
style: J({
paddingBottom: te(v.value)
})
}, null)]) : p("div", {
ref: l,
class: Q(["v-virtual-scroll", e.class]),
onScrollPassive: o,
onScrollend: u,
style: J([r.value, e.style])
}, [p("div", {
ref: i,
class: "v-virtual-scroll__container",
style: J({
paddingTop: te(f.value),
paddingBottom: te(v.value)
})
}, [y])]);
}), {
calculateVisibleItems: s,
scrollToIndex: d
};
}
});
function $c(e, t) {
const n = ne(!1);
let a;
function r(i) {
cancelAnimationFrame(a), n.value = !0, a = requestAnimationFrame(() => {
a = requestAnimationFrame(() => {
n.value = !1;
});
});
}
async function s() {
await new Promise((i) => requestAnimationFrame(i)), await new Promise((i) => requestAnimationFrame(i)), await new Promise((i) => requestAnimationFrame(i)), await new Promise((i) => {
if (n.value) {
const o = re(n, () => {
o(), i();
});
} else i();
});
}
async function l(i) {
if (i.key === "Tab" && t.value?.focus(), !["PageDown", "PageUp", "Home", "End"].includes(i.key)) return;
const o = e.value?.$el;
if (!o) return;
(i.key === "Home" || i.key === "End") && o.scrollTo({
top: i.key === "Home" ? 0 : o.scrollHeight,
behavior: "smooth"
}), await s();
const u = o.querySelectorAll(":scope > :not(.v-virtual-scroll__spacer)");
if (i.key === "PageDown" || i.key === "Home") {
const c = o.getBoundingClientRect().top;
for (const d of u)
if (d.getBoundingClientRect().top >= c) {
d.focus();
break;
}
} else {
const c = o.getBoundingClientRect().bottom;
for (const d of [...u].reverse())
if (d.getBoundingClientRect().bottom <= c) {
d.focus();
break;
}
}
}
return {
onScrollPassive: r,
onKeydown: l
};
}
const Uc = M({
chips: Boolean,
closableChips: Boolean,
closeText: {
type: String,
default: "$vuetify.close"
},
openText: {
type: String,
default: "$vuetify.open"
},
eager: Boolean,
hideNoData: Boolean,
hideSelected: Boolean,
listProps: {
type: Object
},
menu: Boolean,
menuIcon: {
type: le,
default: "$dropdown"
},
menuProps: {
type: Object
},
multiple: Boolean,
noDataText: {
type: String,
default: "$vuetify.noDataText"
},
openOnClear: Boolean,
itemColor: String,
...Pc({
itemChildren: !1
})
}, "Select"), pg = M({
...Uc(),
...kn(ni({
modelValue: null,
role: "combobox"
}), ["validationValue", "dirty", "appendInnerIcon"]),
...ia({
transition: {
component: zl
}
})
}, "VSelect"), zc = G()({
name: "VSelect",
props: pg(),
emits: {
"update:focused": (e) => !0,
"update:modelValue": (e) => !0,
"update:menu": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
t: a
} = hn(), r = R(), s = R(), l = R(), {
items: i,
transformIn: o,
transformOut: u
} = Ic(e), c = _e(e, "modelValue", [], (x) => o(x === null ? [null] : Ke(x)), (x) => {
const A = u(x);
return e.multiple ? A : A[0] ?? null;
}), d = _(() => typeof e.counterValue == "function" ? e.counterValue(c.value) : typeof e.counterValue == "number" ? e.counterValue : c.value.length), f = Yl(e), v = _(() => c.value.map((x) => x.value)), m = ne(!1);
let y = "", h = -1, b;
const S = _(() => e.hideSelected ? i.value.filter((x) => !c.value.some((A) => (e.valueComparator || gt)(A, x))) : i.value), P = _(() => e.hideNoData && !S.value.length || f.isReadonly.value || f.isDisabled.value), O = _e(e, "menu"), k = _({
get: () => O.value,
set: (x) => {
O.value && !x && s.value?.ΨopenChildren.size || x && P.value || (O.value = x);
}
}), E = I(() => k.value ? e.closeText : e.openText), V = _(() => ({
...e.menuProps,
activatorProps: {
...e.menuProps?.activatorProps || {},
"aria-haspopup": "listbox"
// Set aria-haspopup to 'listbox'
}
})), w = R(), T = $c(w, r);
function L(x) {
e.openOnClear && (k.value = !0);
}
function $() {
P.value || (k.value = !k.value);
}
function B(x) {
wr(x) && D(x);
}
function D(x) {
if (!x.key || f.isReadonly.value) return;
["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(x.key) && x.preventDefault(), ["Enter", "ArrowDown", " "].includes(x.key) && (k.value = !0), ["Escape", "Tab"].includes(x.key) && (k.value = !1), x.key === "Home" ? w.value?.focus("first") : x.key === "End" && w.value?.focus("last");
const A = 1e3;
if (!wr(x)) return;
const N = performance.now();
N - b > A && (y = "", h = -1), y += x.key.toLowerCase(), b = N;
const q = S.value;
function ie() {
let Se = ae();
return Se || y.at(-1) === y.at(-2) && (y = y.slice(0, -1), Se = ae(), Se) || (h = -1, Se = ae(), Se) ? Se : (y = x.key.toLowerCase(), ae());
}
function ae() {
for (let Se = h + 1; Se < q.length; Se++) {
const U = q[Se];
if (U.title.toLowerCase().startsWith(y))
return [U, Se];
}
}
const se = ie();
if (!se) return;
const [K, Ae] = se;
h = Ae, w.value?.focus(Ae), e.multiple || (c.value = [K]);
}
function H(x) {
let A = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
if (!x.props.disabled)
if (e.multiple) {
const N = c.value.findIndex((ie) => (e.valueComparator || gt)(ie.value, x.value)), q = A ?? !~N;
if (~N) {
const ie = q ? [...c.value, x] : [...c.value];
ie.splice(N, 1), c.value = ie;
} else q && (c.value = [...c.value, x]);
} else {
const N = A !== !1;
c.value = N ? [x] : [], Ge(() => {
k.value = !1;
});
}
}
function Y(x) {
w.value?.$el.contains(x.relatedTarget) || (k.value = !1);
}
function X() {
e.eager && l.value?.calculateVisibleItems();
}
function oe() {
m.value && r.value?.focus();
}
function ge(x) {
m.value = !0;
}
function Ie(x) {
if (x == null) c.value = [];
else if (Xn(r.value, ":autofill") || Xn(r.value, ":-webkit-autofill")) {
const A = i.value.find((N) => N.title === x);
A && H(A);
} else r.value && (r.value.value = "");
}
return re(k, () => {
if (!e.hideSelected && k.value && c.value.length) {
const x = S.value.findIndex((A) => c.value.some((N) => (e.valueComparator || gt)(N.value, A.value)));
Be && window.requestAnimationFrame(() => {
x >= 0 && l.value?.scrollToIndex(x);
});
}
}), re(() => e.items, (x, A) => {
k.value || m.value && !A.length && x.length && (k.value = !0);
}), ee(() => {
const x = !!(e.chips || n.chip), A = !!(!e.hideNoData || S.value.length || n["prepend-item"] || n["append-item"] || n["no-data"]), N = c.value.length > 0, q = Da.filterProps(e), ie = N || !m.value && e.label && !e.persistentPlaceholder ? void 0 : e.placeholder;
return g(Da, j({
ref: r
}, q, {
modelValue: c.value.map((ae) => ae.props.value).join(", "),
"onUpdate:modelValue": Ie,
focused: m.value,
"onUpdate:focused": (ae) => m.value = ae,
validationValue: c.externalValue,
counterValue: d.value,
dirty: N,
class: ["v-select", {
"v-select--active-menu": k.value,
"v-select--chips": !!e.chips,
[`v-select--${e.multiple ? "multiple" : "single"}`]: !0,
"v-select--selected": c.value.length,
"v-select--selection-slot": !!n.selection
}, e.class],
style: e.style,
inputmode: "none",
placeholder: ie,
"onClick:clear": L,
"onMousedown:control": $,
onBlur: Y,
onKeydown: D,
"aria-label": a(E.value),
title: a(E.value)
}), {
...n,
default: () => p(pe, null, [g(Fc, j({
ref: s,
modelValue: k.value,
"onUpdate:modelValue": (ae) => k.value = ae,
activator: "parent",
contentClass: "v-select__content",
disabled: P.value,
eager: e.eager,
maxHeight: 310,
openOnClick: !1,
closeOnContentClick: !1,
transition: e.transition,
onAfterEnter: X,
onAfterLeave: oe
}, V.value), {
default: () => [A && g(Tc, j({
ref: w,
selected: v.value,
selectStrategy: e.multiple ? "independent" : "single-independent",
onMousedown: (ae) => ae.preventDefault(),
onKeydown: B,
onFocusin: ge,
tabindex: "-1",
"aria-live": "polite",
"aria-label": `${e.label}-list`,
color: e.itemColor ?? e.color
}, T, e.listProps), {
default: () => [n["prepend-item"]?.(), !S.value.length && !e.hideNoData && (n["no-data"]?.() ?? g(Nn, {
key: "no-data",
title: a(e.noDataText)
}, null)), g(Bc, {
ref: l,
renderless: !0,
items: S.value,
itemKey: "value"
}, {
default: (ae) => {
let {
item: se,
index: K,
itemRef: Ae
} = ae;
const Se = j(se.props, {
ref: Ae,
key: se.value,
onClick: () => H(se, null)
});
return n.item?.({
item: se,
index: K,
props: Se
}) ?? g(Nn, j(Se, {
role: "option"
}), {
prepend: (U) => {
let {
isSelected: he
} = U;
return p(pe, null, [e.multiple && !e.hideSelected ? g(Ga, {
key: se.value,
modelValue: he,
ripple: !1,
tabindex: "-1"
}, null) : void 0, se.props.prependAvatar && g(_n, {
image: se.props.prependAvatar
}, null), se.props.prependIcon && g(Ve, {
icon: se.props.prependIcon
}, null)]);
}
});
}
}), n["append-item"]?.()]
})]
}), c.value.map((ae, se) => {
function K(he) {
he.stopPropagation(), he.preventDefault(), H(ae, !1);
}
const Ae = {
"onClick:close": K,
onKeydown(he) {
he.key !== "Enter" && he.key !== " " || (he.preventDefault(), he.stopPropagation(), K(he));
},
onMousedown(he) {
he.preventDefault(), he.stopPropagation();
},
modelValue: !0,
"onUpdate:modelValue": void 0
}, Se = x ? !!n.chip : !!n.selection, U = Se ? Dl(x ? n.chip({
item: ae,
index: se,
props: Ae
}) : n.selection({
item: ae,
index: se
})) : void 0;
if (!(Se && !U))
return p("div", {
key: ae.value,
class: "v-select__selection"
}, [x ? n.chip ? g(Ne, {
key: "chip-defaults",
defaults: {
VChip: {
closable: e.closableChips,
size: "small",
text: ae.title
}
}
}, {
default: () => [U]
}) : g(Ql, j({
key: "chip",
closable: e.closableChips,
size: "small",
text: ae.title,
disabled: ae.props.disabled
}, Ae), null) : U ?? p("span", {
class: "v-select__selection-text"
}, [ae.title, e.multiple && se < c.value.length - 1 && p("span", {
class: "v-select__selection-comma"
}, [Fe(",")])])]);
})]),
"append-inner": function() {
for (var ae = arguments.length, se = new Array(ae), K = 0; K < ae; K++)
se[K] = arguments[K];
return p(pe, null, [n["append-inner"]?.(...se), e.menuIcon ? g(Ve, {
class: "v-select__menu-icon",
color: r.value?.fieldIconColor,
icon: e.menuIcon
}, null) : void 0]);
}
});
}), oa({
isFocused: m,
menu: k,
select: H
}, r);
}
}), Sg = (e, t, n) => {
if (e == null || t == null) return -1;
if (!t.length) return 0;
e = e.toString().toLocaleLowerCase(), t = t.toString().toLocaleLowerCase();
const a = [];
let r = e.indexOf(t);
for (; ~r; )
a.push([r, r + t.length]), r = e.indexOf(t, r + t.length);
return a.length ? a : -1;
};
function Ds(e, t) {
if (!(e == null || typeof e == "boolean" || e === -1))
return typeof e == "number" ? [[e, e + t.length]] : Array.isArray(e[0]) ? e : [e];
}
const Hc = M({
customFilter: Function,
customKeyFilter: Object,
filterKeys: [Array, String],
filterMode: {
type: String,
default: "intersection"
},
noFilter: Boolean
}, "filter");
function wg(e, t, n) {
const a = [], r = n?.default ?? Sg, s = n?.filterKeys ? Ke(n.filterKeys) : !1, l = Object.keys(n?.customKeyFilter ?? {}).length;
if (!e?.length) return a;
e: for (let i = 0; i < e.length; i++) {
const [o, u = o] = Ke(e[i]), c = {}, d = {};
let f = -1;
if ((t || l > 0) && !n?.noFilter) {
if (typeof o == "object") {
const y = s || Object.keys(u);
for (const h of y) {
const b = ot(u, h), S = n?.customKeyFilter?.[h];
if (f = S ? S(b, t, o) : r(b, t, o), f !== -1 && f !== !1)
S ? c[h] = Ds(f, t) : d[h] = Ds(f, t);
else if (n?.filterMode === "every")
continue e;
}
} else
f = r(o, t, o), f !== -1 && f !== !1 && (d.title = Ds(f, t));
const v = Object.keys(d).length, m = Object.keys(c).length;
if (!v && !m || n?.filterMode === "union" && m !== l && !v || n?.filterMode === "intersection" && (m !== l || !v)) continue;
}
a.push({
index: i,
matches: {
...d,
...c
}
});
}
return a;
}
function Yc(e, t, n, a) {
const r = ne([]), s = ne(/* @__PURE__ */ new Map()), l = _(() => a?.transform ? _t(t).map((o) => [o, a.transform(o)]) : _t(t));
Ot(() => {
const o = typeof n == "function" ? n() : _t(n), u = typeof o != "string" && typeof o != "number" ? "" : String(o), c = wg(l.value, u, {
customKeyFilter: {
...e.customKeyFilter,
..._t(a?.customKeyFilter)
},
default: e.customFilter,
filterKeys: e.filterKeys,
filterMode: e.filterMode,
noFilter: e.noFilter
}), d = _t(t), f = [], v = /* @__PURE__ */ new Map();
c.forEach((m) => {
let {
index: y,
matches: h
} = m;
const b = d[y];
f.push(b), v.set(b.value, h);
}), r.value = f, s.value = v;
});
function i(o) {
return s.value.get(o.value);
}
return {
filteredItems: r,
filteredMatches: s,
getMatches: i
};
}
function _g(e, t, n) {
return n == null || !n.length ? t : n.map((a, r) => {
const s = r === 0 ? 0 : n[r - 1][1], l = [p("span", {
class: Q(`${e}__unmask`)
}, [t.slice(s, a[0])]), p("span", {
class: Q(`${e}__mask`)
}, [t.slice(a[0], a[1])])];
return r === n.length - 1 && l.push(p("span", {
class: Q(`${e}__unmask`)
}, [t.slice(a[1])])), p(pe, null, [l]);
});
}
const kg = M({
autoSelectFirst: {
type: [Boolean, String]
},
clearOnSelect: Boolean,
search: String,
...Hc({
filterKeys: ["title"]
}),
...Uc(),
...kn(ni({
modelValue: null,
role: "combobox"
}), ["validationValue", "dirty", "appendInnerIcon"]),
...ia({
transition: !1
})
}, "VAutocomplete"), Cg = G()({
name: "VAutocomplete",
props: kg(),
emits: {
"update:focused": (e) => !0,
"update:search": (e) => !0,
"update:modelValue": (e) => !0,
"update:menu": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
t: a
} = hn(), r = R(), s = ne(!1), l = ne(!0), i = ne(!1), o = R(), u = R(), c = ne(-1), {
items: d,
transformIn: f,
transformOut: v
} = Ic(e), {
textColorClasses: m,
textColorStyles: y
} = Ht(() => r.value?.color), h = _e(e, "search", ""), b = _e(e, "modelValue", [], (U) => f(U === null ? [null] : Ke(U)), (U) => {
const he = v(U);
return e.multiple ? he : he[0] ?? null;
}), S = _(() => typeof e.counterValue == "function" ? e.counterValue(b.value) : typeof e.counterValue == "number" ? e.counterValue : b.value.length), P = Yl(e), {
filteredItems: O,
getMatches: k
} = Yc(e, d, () => l.value ? "" : h.value), E = _(() => e.hideSelected ? O.value.filter((U) => !b.value.some((he) => he.value === U.value)) : O.value), V = _(() => !!(e.chips || n.chip)), w = _(() => V.value || !!n.selection), T = _(() => b.value.map((U) => U.props.value)), L = _(() => (e.autoSelectFirst === !0 || e.autoSelectFirst === "exact" && h.value === E.value[0]?.title) && E.value.length > 0 && !l.value && !i.value), $ = _(() => e.hideNoData && !E.value.length || P.isReadonly.value || P.isDisabled.value), B = _e(e, "menu"), D = _({
get: () => B.value,
set: (U) => {
B.value && !U && o.value?.ΨopenChildren.size || U && $.value || (B.value = U);
}
}), H = _(() => D.value ? e.closeText : e.openText), Y = R(), X = $c(Y, r);
function oe(U) {
e.openOnClear && (D.value = !0), h.value = "";
}
function ge() {
$.value || (D.value = !0);
}
function Ie(U) {
$.value || (s.value && (U.preventDefault(), U.stopPropagation()), D.value = !D.value);
}
function x(U) {
U.key !== " " && wr(U) && r.value?.focus();
}
function A(U) {
if (P.isReadonly.value) return;
const he = r.value?.selectionStart, Qe = b.value.length;
if (["Enter", "ArrowDown", "ArrowUp"].includes(U.key) && U.preventDefault(), ["Enter", "ArrowDown"].includes(U.key) && (D.value = !0), ["Escape"].includes(U.key) && (D.value = !1), L.value && ["Enter", "Tab"].includes(U.key) && !b.value.some((be) => {
let {
value: Pe
} = be;
return Pe === E.value[0].value;
}) && Se(E.value[0]), U.key === "ArrowDown" && L.value && Y.value?.focus("next"), ["Backspace", "Delete"].includes(U.key)) {
if (!e.multiple && w.value && b.value.length > 0 && !h.value) return Se(b.value[0], !1);
if (~c.value) {
U.preventDefault();
const be = c.value;
Se(b.value[c.value], !1), c.value = be >= Qe - 1 ? Qe - 2 : be;
} else U.key === "Backspace" && !h.value && (c.value = Qe - 1);
return;
}
if (e.multiple)
if (U.key === "ArrowLeft") {
if (c.value < 0 && he && he > 0) return;
const be = c.value > -1 ? c.value - 1 : Qe - 1;
if (b.value[be])
c.value = be;
else {
const Pe = h.value?.length ?? null;
c.value = -1, r.value?.setSelectionRange(Pe, Pe);
}
} else if (U.key === "ArrowRight") {
if (c.value < 0) return;
const be = c.value + 1;
b.value[be] ? c.value = be : (c.value = -1, r.value?.setSelectionRange(0, 0));
} else ~c.value && wr(U) && (c.value = -1);
}
function N(U) {
if (Xn(r.value, ":autofill") || Xn(r.value, ":-webkit-autofill")) {
const he = d.value.find((Qe) => Qe.title === U.target.value);
he && Se(he);
}
}
function q() {
e.eager && u.value?.calculateVisibleItems();
}
function ie() {
s.value && (l.value = !0, r.value?.focus());
}
function ae(U) {
s.value = !0, setTimeout(() => {
i.value = !0;
});
}
function se(U) {
i.value = !1;
}
function K(U) {
(U == null || U === "" && !e.multiple && !w.value) && (b.value = []);
}
const Ae = ne(!1);
function Se(U) {
let he = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0;
if (!(!U || U.props.disabled))
if (e.multiple) {
const Qe = b.value.findIndex((Pe) => (e.valueComparator || gt)(Pe.value, U.value)), be = he ?? !~Qe;
if (~Qe) {
const Pe = be ? [...b.value, U] : [...b.value];
Pe.splice(Qe, 1), b.value = Pe;
} else be && (b.value = [...b.value, U]);
e.clearOnSelect && (h.value = "");
} else {
const Qe = he !== !1;
b.value = Qe ? [U] : [], h.value = Qe && !w.value ? U.title : "", Ge(() => {
D.value = !1, l.value = !0;
});
}
}
return re(s, (U, he) => {
U !== he && (U ? (Ae.value = !0, h.value = e.multiple || w.value ? "" : String(b.value.at(-1)?.props.title ?? ""), l.value = !0, Ge(() => Ae.value = !1)) : (!e.multiple && h.value == null && (b.value = []), D.value = !1, (e.multiple || w.value) && (h.value = ""), c.value = -1));
}), re(h, (U) => {
!s.value || Ae.value || (U && (D.value = !0), l.value = !U);
}), re(D, () => {
if (!e.hideSelected && D.value && b.value.length) {
const U = E.value.findIndex((he) => b.value.some((Qe) => he.value === Qe.value));
Be && window.requestAnimationFrame(() => {
U >= 0 && u.value?.scrollToIndex(U);
});
}
}), re(() => e.items, (U, he) => {
D.value || s.value && !he.length && U.length && (D.value = !0);
}), ee(() => {
const U = !!(!e.hideNoData || E.value.length || n["prepend-item"] || n["append-item"] || n["no-data"]), he = b.value.length > 0, Qe = Da.filterProps(e);
return g(Da, j({
ref: r
}, Qe, {
modelValue: h.value,
"onUpdate:modelValue": [(be) => h.value = be, K],
focused: s.value,
"onUpdate:focused": (be) => s.value = be,
validationValue: b.externalValue,
counterValue: S.value,
dirty: he,
onChange: N,
class: ["v-autocomplete", `v-autocomplete--${e.multiple ? "multiple" : "single"}`, {
"v-autocomplete--active-menu": D.value,
"v-autocomplete--chips": !!e.chips,
"v-autocomplete--selection-slot": !!w.value,
"v-autocomplete--selecting-index": c.value > -1
}, e.class],
style: e.style,
readonly: P.isReadonly.value,
placeholder: he ? void 0 : e.placeholder,
"onClick:clear": oe,
"onMousedown:control": ge,
onKeydown: A
}), {
...n,
default: () => p(pe, null, [g(Fc, j({
ref: o,
modelValue: D.value,
"onUpdate:modelValue": (be) => D.value = be,
activator: "parent",
contentClass: "v-autocomplete__content",
disabled: $.value,
eager: e.eager,
maxHeight: 310,
openOnClick: !1,
closeOnContentClick: !1,
transition: e.transition,
onAfterEnter: q,
onAfterLeave: ie
}, e.menuProps), {
default: () => [U && g(Tc, j({
ref: Y,
selected: T.value,
selectStrategy: e.multiple ? "independent" : "single-independent",
onMousedown: (be) => be.preventDefault(),
onKeydown: x,
onFocusin: ae,
onFocusout: se,
tabindex: "-1",
"aria-live": "polite",
color: e.itemColor ?? e.color
}, X, e.listProps), {
default: () => [n["prepend-item"]?.(), !E.value.length && !e.hideNoData && (n["no-data"]?.() ?? g(Nn, {
key: "no-data",
title: a(e.noDataText)
}, null)), g(Bc, {
ref: u,
renderless: !0,
items: E.value,
itemKey: "value"
}, {
default: (be) => {
let {
item: Pe,
index: Ft,
itemRef: er
} = be;
const fa = j(Pe.props, {
ref: er,
key: Pe.value,
active: L.value && Ft === 0 ? !0 : void 0,
onClick: () => Se(Pe, null)
});
return n.item?.({
item: Pe,
index: Ft,
props: fa
}) ?? g(Nn, j(fa, {
role: "option"
}), {
prepend: (ha) => {
let {
isSelected: vt
} = ha;
return p(pe, null, [e.multiple && !e.hideSelected ? g(Ga, {
key: Pe.value,
modelValue: vt,
ripple: !1,
tabindex: "-1"
}, null) : void 0, Pe.props.prependAvatar && g(_n, {
image: Pe.props.prependAvatar
}, null), Pe.props.prependIcon && g(Ve, {
icon: Pe.props.prependIcon
}, null)]);
},
title: () => l.value ? Pe.title : _g("v-autocomplete", Pe.title, k(Pe)?.title)
});
}
}), n["append-item"]?.()]
})]
}), b.value.map((be, Pe) => {
function Ft(vt) {
vt.stopPropagation(), vt.preventDefault(), Se(be, !1);
}
const er = {
"onClick:close": Ft,
onKeydown(vt) {
vt.key !== "Enter" && vt.key !== " " || (vt.preventDefault(), vt.stopPropagation(), Ft(vt));
},
onMousedown(vt) {
vt.preventDefault(), vt.stopPropagation();
},
modelValue: !0,
"onUpdate:modelValue": void 0
}, fa = V.value ? !!n.chip : !!n.selection, ha = fa ? Dl(V.value ? n.chip({
item: be,
index: Pe,
props: er
}) : n.selection({
item: be,
index: Pe
})) : void 0;
if (!(fa && !ha))
return p("div", {
key: be.value,
class: Q(["v-autocomplete__selection", Pe === c.value && ["v-autocomplete__selection--selected", m.value]]),
style: J(Pe === c.value ? y.value : {})
}, [V.value ? n.chip ? g(Ne, {
key: "chip-defaults",
defaults: {
VChip: {
closable: e.closableChips,
size: "small",
text: be.title
}
}
}, {
default: () => [ha]
}) : g(Ql, j({
key: "chip",
closable: e.closableChips,
size: "small",
text: be.title,
disabled: be.props.disabled
}, er), null) : ha ?? p("span", {
class: "v-autocomplete__selection-text"
}, [be.title, e.multiple && Pe < b.value.length - 1 && p("span", {
class: "v-autocomplete__selection-comma"
}, [Fe(",")])])]);
})]),
"append-inner": function() {
for (var be = arguments.length, Pe = new Array(be), Ft = 0; Ft < be; Ft++)
Pe[Ft] = arguments[Ft];
return p(pe, null, [n["append-inner"]?.(...Pe), e.menuIcon ? g(Ve, {
class: "v-autocomplete__menu-icon",
color: r.value?.fieldIconColor,
icon: e.menuIcon,
onMousedown: Ie,
onClick: Fm,
"aria-label": a(H.value),
title: a(H.value),
tabindex: "-1"
}, null) : void 0]);
}
});
}), oa({
isFocused: s,
isPristine: l,
menu: D,
search: h,
filteredItems: O,
select: Se
}, r);
}
}), Pg = M({
...ce(),
...$v()
}, "VForm"), xg = G()({
name: "VForm",
props: Pg(),
emits: {
"update:modelValue": (e) => !0,
submit: (e) => !0
},
setup(e, t) {
let {
slots: n,
emit: a
} = t;
const r = Uv(e), s = R();
function l(o) {
o.preventDefault(), r.reset();
}
function i(o) {
const u = o, c = r.validate();
u.then = c.then.bind(c), u.catch = c.catch.bind(c), u.finally = c.finally.bind(c), a("submit", u), u.defaultPrevented || c.then((d) => {
let {
valid: f
} = d;
f && s.value?.submit();
}), u.preventDefault();
}
return ee(() => p("form", {
ref: s,
class: Q(["v-form", e.class]),
style: J(e.style),
novalidate: !0,
onReset: l,
onSubmit: i
}, [n.default?.(r)])), oa(r, s);
}
}), Ig = M({
fluid: {
type: Boolean,
default: !1
},
...ce(),
...un(),
...Le()
}, "VContainer"), _a = G()({
name: "VContainer",
props: Ig(),
setup(e, t) {
let {
slots: n
} = t;
const {
rtlClasses: a
} = Mt(), {
dimensionStyles: r
} = cn(e);
return ee(() => g(e.tag, {
class: Q(["v-container", {
"v-container--fluid": e.fluid
}, a.value, e.class]),
style: J([r.value, e.style])
}, n)), {};
}
}), jc = Kr.reduce((e, t) => (e[t] = {
type: [Boolean, String, Number],
default: !1
}, e), {}), Wc = Kr.reduce((e, t) => {
const n = "offset" + na(t);
return e[n] = {
type: [String, Number],
default: null
}, e;
}, {}), Gc = Kr.reduce((e, t) => {
const n = "order" + na(t);
return e[n] = {
type: [String, Number],
default: null
}, e;
}, {}), To = {
col: Object.keys(jc),
offset: Object.keys(Wc),
order: Object.keys(Gc)
};
function Og(e, t, n) {
let a = e;
if (!(n == null || n === !1)) {
if (t) {
const r = t.replace(e, "");
a += `-${r}`;
}
return e === "col" && (a = "v-" + a), e === "col" && (n === "" || n === !0) || (a += `-${n}`), a.toLowerCase();
}
}
const Tg = ["auto", "start", "end", "center", "baseline", "stretch"], Vg = M({
cols: {
type: [Boolean, String, Number],
default: !1
},
...jc,
offset: {
type: [String, Number],
default: null
},
...Wc,
order: {
type: [String, Number],
default: null
},
...Gc,
alignSelf: {
type: String,
default: null,
validator: (e) => Tg.includes(e)
},
...ce(),
...Le()
}, "VCol"), yn = G()({
name: "VCol",
props: Vg(),
setup(e, t) {
let {
slots: n
} = t;
const a = _(() => {
const r = [];
let s;
for (s in To)
To[s].forEach((i) => {
const o = e[i], u = Og(s, i, o);
u && r.push(u);
});
const l = r.some((i) => i.startsWith("v-col-"));
return r.push({
// Default to .v-col if no other col-{bp}-* classes generated nor `cols` specified.
"v-col": !l || !e.cols,
[`v-col-${e.cols}`]: e.cols,
[`offset-${e.offset}`]: e.offset,
[`order-${e.order}`]: e.order,
[`align-self-${e.alignSelf}`]: e.alignSelf
}), r;
});
return () => aa(e.tag, {
class: [a.value, e.class],
style: e.style
}, n.default?.());
}
}), ai = ["start", "end", "center"], Qc = ["space-between", "space-around", "space-evenly"];
function ri(e, t) {
return Kr.reduce((n, a) => {
const r = e + na(a);
return n[r] = t(), n;
}, {});
}
const Ag = [...ai, "baseline", "stretch"], qc = (e) => Ag.includes(e), Kc = ri("align", () => ({
type: String,
default: null,
validator: qc
})), Eg = [...ai, ...Qc], Jc = (e) => Eg.includes(e), Zc = ri("justify", () => ({
type: String,
default: null,
validator: Jc
})), Dg = [...ai, ...Qc, "stretch"], Xc = (e) => Dg.includes(e), ed = ri("alignContent", () => ({
type: String,
default: null,
validator: Xc
})), Vo = {
align: Object.keys(Kc),
justify: Object.keys(Zc),
alignContent: Object.keys(ed)
}, Mg = {
align: "align",
justify: "justify",
alignContent: "align-content"
};
function Rg(e, t, n) {
let a = Mg[e];
if (n != null) {
if (t) {
const r = t.replace(e, "");
a += `-${r}`;
}
return a += `-${n}`, a.toLowerCase();
}
}
const Fg = M({
dense: Boolean,
noGutters: Boolean,
align: {
type: String,
default: null,
validator: qc
},
...Kc,
justify: {
type: String,
default: null,
validator: Jc
},
...Zc,
alignContent: {
type: String,
default: null,
validator: Xc
},
...ed,
...ce(),
...Le()
}, "VRow"), il = G()({
name: "VRow",
props: Fg(),
setup(e, t) {
let {
slots: n
} = t;
const a = _(() => {
const r = [];
let s;
for (s in Vo)
Vo[s].forEach((l) => {
const i = e[l], o = Rg(s, l, i);
o && r.push(o);
});
return r.push({
"v-row--no-gutters": e.noGutters,
"v-row--dense": e.dense,
[`align-${e.align}`]: e.align,
[`justify-${e.justify}`]: e.justify,
[`align-content-${e.alignContent}`]: e.alignContent
}), r;
});
return () => aa(e.tag, {
class: ["v-row", a.value, e.class],
style: e.style
}, n.default?.());
}
}), Lg = M({
...Qr({
falseIcon: "$radioOff",
trueIcon: "$radioOn"
})
}, "VRadio"), ga = G()({
name: "VRadio",
props: Lg(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => {
const a = Ln.filterProps(e);
return g(Ln, j(a, {
class: ["v-radio", e.class],
style: e.style,
type: "radio"
}), n);
}), {};
}
}), Ng = M({
height: {
type: [Number, String],
default: "auto"
},
...qr(),
...kn(Ul(), ["multiple"]),
trueIcon: {
type: le,
default: "$radioOn"
},
falseIcon: {
type: le,
default: "$radioOff"
},
type: {
type: String,
default: "radio"
}
}, "VRadioGroup"), Ms = G()({
name: "VRadioGroup",
inheritAttrs: !1,
props: Ng(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const r = on(), s = _(() => e.id || `radio-group-${r}`), l = _e(e, "modelValue");
return ee(() => {
const [i, o] = Wr(n), u = ea.filterProps(e), c = Ln.filterProps(e), d = a.label ? a.label({
label: e.label,
props: {
for: s.value
}
}) : e.label;
return g(ea, j({
class: ["v-radio-group", e.class],
style: e.style
}, i, u, {
modelValue: l.value,
"onUpdate:modelValue": (f) => l.value = f,
id: s.value
}), {
...a,
default: (f) => {
let {
id: v,
messagesId: m,
isDisabled: y,
isReadonly: h
} = f;
return p(pe, null, [d && g($l, {
id: v.value
}, {
default: () => [d]
}), g(Iv, j(c, {
id: v.value,
"aria-describedby": m.value,
defaultsTarget: "VRadio",
trueIcon: e.trueIcon,
falseIcon: e.falseIcon,
type: e.type,
disabled: y.value,
readonly: h.value,
"aria-labelledby": d ? v.value : void 0,
multiple: !1
}, o, {
modelValue: l.value,
"onUpdate:modelValue": (b) => l.value = b
}), a)]);
}
});
}), {};
}
}), Bg = M({
bgColor: String,
color: String,
indeterminate: [Boolean, String],
modelValue: {
type: [Number, String],
default: 0
},
rotate: {
type: [Number, String],
default: 0
},
width: {
type: [Number, String],
default: 4
},
...ce(),
...la(),
...Le({
tag: "div"
}),
...Ye()
}, "VProgressCircular"), td = G()({
name: "VProgressCircular",
props: Bg(),
setup(e, t) {
let {
slots: n
} = t;
const a = 20, r = 2 * Math.PI * a, s = R(), {
themeClasses: l
} = Ze(e), {
sizeClasses: i,
sizeStyles: o
} = Ya(e), {
textColorClasses: u,
textColorStyles: c
} = Ht(() => e.color), {
textColorClasses: d,
textColorStyles: f
} = Ht(() => e.bgColor), {
intersectionRef: v,
isIntersecting: m
} = Lc(), {
resizeRef: y,
contentRect: h
} = ta(), b = I(() => bt(parseFloat(e.modelValue), 0, 100)), S = I(() => Number(e.width)), P = I(() => o.value ? Number(e.size) : h.value ? h.value.width : Math.max(S.value, 32)), O = I(() => a / (1 - S.value / P.value) * 2), k = I(() => S.value / P.value * O.value), E = I(() => te((100 - b.value) / 100 * r));
return Ot(() => {
v.value = s.value, y.value = s.value;
}), ee(() => g(e.tag, {
ref: s,
class: Q(["v-progress-circular", {
"v-progress-circular--indeterminate": !!e.indeterminate,
"v-progress-circular--visible": m.value,
"v-progress-circular--disable-shrink": e.indeterminate === "disable-shrink"
}, l.value, i.value, u.value, e.class]),
style: J([o.value, c.value, e.style]),
role: "progressbar",
"aria-valuemin": "0",
"aria-valuemax": "100",
"aria-valuenow": e.indeterminate ? void 0 : b.value
}, {
default: () => [p("svg", {
style: J({
transform: `rotate(calc(-90deg + ${Number(e.rotate)}deg))`
}),
xmlns: "http://www.w3.org/2000/svg",
viewBox: `0 0 ${O.value} ${O.value}`
}, [p("circle", {
class: Q(["v-progress-circular__underlay", d.value]),
style: J(f.value),
fill: "transparent",
cx: "50%",
cy: "50%",
r: a,
"stroke-width": k.value,
"stroke-dasharray": r,
"stroke-dashoffset": 0
}, null), p("circle", {
class: "v-progress-circular__overlay",
fill: "transparent",
cx: "50%",
cy: "50%",
r: a,
"stroke-width": k.value,
"stroke-dasharray": r,
"stroke-dashoffset": E.value
}, null)]), n.default && p("div", {
class: "v-progress-circular__content"
}, [n.default({
value: b.value
})])]
})), {};
}
}), $g = M({
indeterminate: Boolean,
inset: Boolean,
flat: Boolean,
loading: {
type: [Boolean, String],
default: !1
},
...qr(),
...Qr()
}, "VSwitch"), Ug = G()({
name: "VSwitch",
inheritAttrs: !1,
props: $g(),
emits: {
"update:focused": (e) => !0,
"update:modelValue": (e) => !0,
"update:indeterminate": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const r = _e(e, "indeterminate"), s = _e(e, "modelValue"), {
loaderClasses: l
} = Qa(e), {
isFocused: i,
focus: o,
blur: u
} = Hl(e), c = R(), d = Be && window.matchMedia("(forced-colors: active)").matches, f = I(() => typeof e.loading == "string" && e.loading !== "" ? e.loading : e.color), v = on(), m = I(() => e.id || `switch-${v}`);
function y() {
r.value && (r.value = !1);
}
function h(b) {
b.stopPropagation(), b.preventDefault(), c.value?.input?.click();
}
return ee(() => {
const [b, S] = Wr(n), P = ea.filterProps(e), O = Ln.filterProps(e);
return g(ea, j({
class: ["v-switch", {
"v-switch--flat": e.flat
}, {
"v-switch--inset": e.inset
}, {
"v-switch--indeterminate": r.value
}, l.value, e.class]
}, b, P, {
modelValue: s.value,
"onUpdate:modelValue": (k) => s.value = k,
id: m.value,
focused: i.value,
style: e.style
}), {
...a,
default: (k) => {
let {
id: E,
messagesId: V,
isDisabled: w,
isReadonly: T,
isValid: L
} = k;
const $ = {
model: s,
isValid: L
};
return g(Ln, j({
ref: c
}, O, {
modelValue: s.value,
"onUpdate:modelValue": [(B) => s.value = B, y],
id: E.value,
"aria-describedby": V.value,
type: "checkbox",
"aria-checked": r.value ? "mixed" : void 0,
disabled: w.value,
readonly: T.value,
onFocus: o,
onBlur: u
}, S), {
...a,
default: (B) => {
let {
backgroundColorClasses: D,
backgroundColorStyles: H
} = B;
return p("div", {
class: Q(["v-switch__track", d ? void 0 : D.value]),
style: J(H.value),
onClick: h
}, [a["track-true"] && p("div", {
key: "prepend",
class: "v-switch__track-true"
}, [a["track-true"]($)]), a["track-false"] && p("div", {
key: "append",
class: "v-switch__track-false"
}, [a["track-false"]($)])]);
},
input: (B) => {
let {
inputNode: D,
icon: H,
backgroundColorClasses: Y,
backgroundColorStyles: X
} = B;
return p(pe, null, [D, p("div", {
class: Q(["v-switch__thumb", {
"v-switch__thumb--filled": H || e.loading
}, e.inset || d ? void 0 : Y.value]),
style: J(e.inset ? void 0 : X.value)
}, [a.thumb ? g(Ne, {
defaults: {
VIcon: {
icon: H,
size: "x-small"
}
}
}, {
default: () => [a.thumb({
...$,
icon: H
})]
}) : g(Lv, null, {
default: () => [e.loading ? g(ts, {
name: "v-switch",
active: !0,
color: L.value === !1 ? void 0 : f.value
}, {
default: (oe) => a.loader ? a.loader(oe) : g(td, {
active: oe.isActive,
color: oe.color,
indeterminate: !0,
size: "16",
width: "2"
}, null)
}) : H && g(Ve, {
key: String(H),
icon: H,
size: "x-small"
}, null)]
})])]);
}
});
}
});
}), {};
}
}), zg = { id: "form-finder" }, Hg = {
key: 0,
class: "select-slot"
}, Yg = { class: "font-weight-bold" }, jg = { class: "float-end" }, Wg = { class: "text-primary" }, Gg = { key: 0 }, Qg = {
id: "search-helper",
class: "alert alert-dark",
role: "alert"
};
function qg(e, t, n, a, r, s) {
return qe(), nt("div", zg, [
g(xg, null, {
default: fe(() => [
p("fieldset", null, [
t[26] || (t[26] = p("legend", null, "Search...", -1)),
g(_a, {
id: "from-xxx-to-yyy",
fluid: ""
}, {
default: fe(() => [
g(Ms, {
modelValue: e.queryType,
"onUpdate:modelValue": t[0] || (t[0] = (l) => e.queryType = l),
inline: "",
onChange: e.triggerFormChange,
color: "primary"
}, {
default: fe(() => [
g(ga, {
label: "From Compound to MeSH",
value: "comp_to_mesh"
}),
g(ga, {
label: "From MeSH to Compound",
value: "mesh_to_comp"
})
]),
_: 1
}, 8, ["modelValue", "onChange"])
]),
_: 1
}),
e.switchShowAdvancedSetting ? ct("", !0) : (qe(), Zo(_a, {
key: 0,
id: "switch-show-advanced-settings",
fluid: ""
}, {
default: fe(() => [
g(Ug, {
modelValue: e.switchShowAdvancedSetting,
"onUpdate:modelValue": t[1] || (t[1] = (l) => e.switchShowAdvancedSetting = l),
inset: "",
label: "Advanced settings",
color: "primary"
}, null, 8, ["modelValue"])
]),
_: 1
})),
g(_a, {
id: "panel-advanced-settings",
class: Q({ hidden: !e.switchShowAdvancedSetting }),
fluid: ""
}, {
default: fe(() => [
g(il, null, {
default: fe(() => [
g(yn, {
cols: "auto",
md: "auto"
}, {
default: fe(() => t[9] || (t[9] = [
p("div", { class: "forum-search-radio-label" }, [
p("strong", { class: "primary--text" }, "Compounds:")
], -1)
])),
_: 1,
__: [9]
}),
g(yn, {
cols: "auto",
md: "auto"
}, {
default: fe(() => [
g(Ms, {
modelValue: e.searchType,
"onUpdate:modelValue": t[2] || (t[2] = (l) => e.searchType = l),
inline: "",
onChange: e.triggerFormChange,
color: "primary"
}, {
default: fe(() => [
g(ga, {
label: "PubChem ID",
value: "pubchem_id"
})
]),
_: 1
}, 8, ["modelValue", "onChange"])
]),
_: 1
}),
g(yn, {
cols: "auto",
md: "auto"
}, {
default: fe(() => t[10] || (t[10] = [
p("div", { class: "forum-search-radio-label" }, [
p("strong", { class: "primary--text" }, " | ")
], -1)
])),
_: 1,
__: [10]
}),
g(yn, {
cols: "auto",
md: "auto"
}, {
default: fe(() => t[11] || (t[11] = [
p("div", { class: "forum-search-radio-label" }, [
p("strong", { class: "primary--text" }, " Chemical groups:")
], -1)
])),
_: 1,
__: [11]
}),
g(yn, {
cols: "auto",
md: "auto"
}, {
default: fe(() => [
g(Ms, {
modelValue: e.searchType,
"onUpdate:modelValue": t[3] || (t[3] = (l) => e.searchType = l),
inline: "",
onChange: e.triggerFormChange,
color: "primary"
}, {
default: fe(() => [
g(ga, { value: "chebi_id" }, {
label: fe(() => t[12] || (t[12] = [
p("div", null, "ChEBI ID ", -1)
])),
_: 1
}),
g(ga, {
label: "ChemOnt ID",
value: "chemont_id"
})
]),
_: 1
}, 8, ["modelValue", "onChange"])
]),
_: 1
})
]),
_: 1
})
]),
_: 1
}, 8, ["class"]),
g(_a, { fluid: "" }, {
default: fe(() => [
g(il, null, {
default: fe(() => [
g(yn, {
cols: "6",
md: "6"
}, {
default: fe(() => [
g(Cg, {
clearable: "",
density: "compact",
"hide-details": "auto",
placeholder: "enter your query",
modelValue: e.searchQueryItem,
"onUpdate:modelValue": t[4] || (t[4] = (l) => e.searchQueryItem = l),
"append-icon": "fas fa-search",
"onClick:append": e.launchQuery,
items: e.searchQueryItems,
loading: e.searchQueryLoading,
"no-data-text": e.searchQueryNoData,
search: e.searchQueryItemText,
"onUpdate:search": e.triggerSearchQueryUpdate,
"onUpdate:menu": e.triggerSearchMenu,
"return-object": "",
"no-filter": "",
onKeyup: Uf(e.launchQuery, ["enter"])
}, {
label: fe(() => [
g(Ve, {
icon: "fas fa-search",
style: { "vertical-align": "middle" }
}),
Fe(" Search " + Te(e.labelTarget) + " using a " + Te(e.labelSource), 1)
]),
item: fe(({ item: l, props: i }) => [
g(Nn, j(i, {
title: l?.raw?.name,
subtitle: l?.raw?.id
}), null, 16, ["title", "subtitle"])
]),
selection: fe(({ item: { raw: l } }) => [
l.name != "" ? (qe(), nt("p", Hg, [
p("span", Yg, Te(l.name), 1),
p("small", jg, [
p("span", Wg, "(" + Te(l.id) + ")", 1),
e.searchQueryItemsVisible ? (qe(), nt("span", Gg, "|")) : ct("", !0)
])
])) : ct("", !0)
]),
_: 1
}, 8, ["modelValue", "onClick:append", "items", "loading", "no-data-text", "search", "onUpdate:search", "onUpdate:menu", "onKeyup"])
]),
_: 1
})
]),
_: 1
})
]),
_: 1
}),
p("div", Qg, [
g(Ve, { icon: "fas fa-info-circle" }),
t[13] || (t[13] = Fe(" For your first experience with the FORUM portal, please find some examples from ")),
t[14] || (t[14] = p("a", {
href: "https://pubchem.ncbi.nlm.nih.gov/",
target: "_blank"
}, "PubChem", -1)),
t[15] || (t[15] = Fe(" (")),
p("a", {
class: "exemple",
onClick: t[5] || (t[5] = (l) => e.launchExample("comp_to_mesh", "pubchem_id", "Pyruvic acid", "1060"))
}, "1060 - Pyruvic acid"),
t[16] || (t[16] = Fe("), ")),
t[17] || (t[17] = p("a", {
href: "https://www.ebi.ac.uk/ols/ontologies/chebi",
target: "_blank"
}, " ChEBI", -1)),
t[18] || (t[18] = Fe(" (")),
p("a", {
class: "exemple",
onClick: t[6] || (t[6] = (l) => e.launchExample("comp_to_mesh", "chebi_id", "Xanthenes", "CHEBI:38835"))
}, "CHEBI:38835 - Xanthenes"),
t[19] || (t[19] = Fe("), ")),
t[20] || (t[20] = p("a", {
href: "http://classyfire.wishartlab.com/tax_nodes",
target: "_blank"
}, "ChemOnt", -1)),
t[21] || (t[21] = Fe(" (")),
p("a", {
class: "exemple",
onClick: t[7] || (t[7] = (l) => e.launchExample("comp_to_mesh", "chemont_id", "Thienopyridines", "C0000344"))
}, "C0000344 - Thienopyridines"),
t[22] || (t[22] = Fe("), and ")),
t[23] || (t[23] = p("a", {
href: "https://meshb.nlm.nih.gov/search",
target: "_blank"
}, "MeSH", -1)),
t[24] || (t[24] = Fe(" (")),
p("a", {
class: "exemple",
onClick: t[8] || (t[8] = (l) => e.launchExample("mesh_to_comp", "pubchem_id", "Diabetes Mellitus", "D003920"))
}, "D003920 - Diabetes Mellitus"),
t[25] || (t[25] = Fe("). "))
])
])
]),
_: 1
})
]);
}
const Kg = /* @__PURE__ */ Tl(Vm, [["render", qg]]);
var ol = function(e, t) {
return ol = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, a) {
n.__proto__ = a;
} || function(n, a) {
for (var r in a) Object.prototype.hasOwnProperty.call(a, r) && (n[r] = a[r]);
}, ol(e, t);
};
function qa(e, t) {
if (typeof t != "function" && t !== null)
throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
ol(e, t);
function n() {
this.constructor = e;
}
e.prototype = t === null ? Object.create(t) : (n.prototype = t.prototype, new n());
}
function ul(e) {
var t = typeof Symbol == "function" && Symbol.iterator, n = t && e[t], a = 0;
if (n) return n.call(e);
if (e && typeof e.length == "number") return {
next: function() {
return e && a >= e.length && (e = void 0), { value: e && e[a++], done: !e };
}
};
throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
}
function cl(e, t) {
var n = typeof Symbol == "function" && e[Symbol.iterator];
if (!n) return e;
var a = n.call(e), r, s = [], l;
try {
for (; (t === void 0 || t-- > 0) && !(r = a.next()).done; ) s.push(r.value);
} catch (i) {
l = { error: i };
} finally {
try {
r && !r.done && (n = a.return) && n.call(a);
} finally {
if (l) throw l.error;
}
}
return s;
}
function dl(e, t, n) {
if (n || arguments.length === 2) for (var a = 0, r = t.length, s; a < r; a++)
(s || !(a in t)) && (s || (s = Array.prototype.slice.call(t, 0, a)), s[a] = t[a]);
return e.concat(s || Array.prototype.slice.call(t));
}
function Ut(e) {
return typeof e == "function";
}
function nd(e) {
var t = function(a) {
Error.call(a), a.stack = new Error().stack;
}, n = e(t);
return n.prototype = Object.create(Error.prototype), n.prototype.constructor = n, n;
}
var Rs = nd(function(e) {
return function(n) {
e(this), this.message = n ? n.length + ` errors occurred during unsubscription:
` + n.map(function(a, r) {
return r + 1 + ") " + a.toString();
}).join(`
`) : "", this.name = "UnsubscriptionError", this.errors = n;
};
});
function fl(e, t) {
if (e) {
var n = e.indexOf(t);
0 <= n && e.splice(n, 1);
}
}
var ns = function() {
function e(t) {
this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
}
return e.prototype.unsubscribe = function() {
var t, n, a, r, s;
if (!this.closed) {
this.closed = !0;
var l = this._parentage;
if (l)
if (this._parentage = null, Array.isArray(l))
try {
for (var i = ul(l), o = i.next(); !o.done; o = i.next()) {
var u = o.value;
u.remove(this);
}
} catch (y) {
t = { error: y };
} finally {
try {
o && !o.done && (n = i.return) && n.call(i);
} finally {
if (t) throw t.error;
}
}
else
l.remove(this);
var c = this.initialTeardown;
if (Ut(c))
try {
c();
} catch (y) {
s = y instanceof Rs ? y.errors : [y];
}
var d = this._finalizers;
if (d) {
this._finalizers = null;
try {
for (var f = ul(d), v = f.next(); !v.done; v = f.next()) {
var m = v.value;
try {
Ao(m);
} catch (y) {
s = s ?? [], y instanceof Rs ? s = dl(dl([], cl(s)), cl(y.errors)) : s.push(y);
}
}
} catch (y) {
a = { error: y };
} finally {
try {
v && !v.done && (r = f.return) && r.call(f);
} finally {
if (a) throw a.error;
}
}
}
if (s)
throw new Rs(s);
}
}, e.prototype.add = function(t) {
var n;
if (t && t !== this)
if (this.closed)
Ao(t);
else {
if (t instanceof e) {
if (t.closed || t._hasParent(this))
return;
t._addParent(this);
}
(this._finalizers = (n = this._finalizers) !== null && n !== void 0 ? n : []).push(t);
}
}, e.prototype._hasParent = function(t) {
var n = this._parentage;
return n === t || Array.isArray(n) && n.includes(t);
}, e.prototype._addParent = function(t) {
var n = this._parentage;
this._parentage = Array.isArray(n) ? (n.push(t), n) : n ? [n, t] : t;
}, e.prototype._removeParent = function(t) {
var n = this._parentage;
n === t ? this._parentage = null : Array.isArray(n) && fl(n, t);
}, e.prototype.remove = function(t) {
var n = this._finalizers;
n && fl(n, t), t instanceof e && t._removeParent(this);
}, e.EMPTY = function() {
var t = new e();
return t.closed = !0, t;
}(), e;
}(), ad = ns.EMPTY;
function rd(e) {
return e instanceof ns || e && "closed" in e && Ut(e.remove) && Ut(e.add) && Ut(e.unsubscribe);
}
function Ao(e) {
Ut(e) ? e() : e.unsubscribe();
}
var Jg = {
Promise: void 0
}, Zg = {
setTimeout: function(e, t) {
for (var n = [], a = 2; a < arguments.length; a++)
n[a - 2] = arguments[a];
return setTimeout.apply(void 0, dl([e, t], cl(n)));
},
clearTimeout: function(e) {
return clearTimeout(e);
},
delegate: void 0
};
function Xg(e) {
Zg.setTimeout(function() {
throw e;
});
}
function Eo() {
}
function mr(e) {
e();
}
var si = function(e) {
qa(t, e);
function t(n) {
var a = e.call(this) || this;
return a.isStopped = !1, n ? (a.destination = n, rd(n) && n.add(a)) : a.destination = nb, a;
}
return t.create = function(n, a, r) {
return new hl(n, a, r);
}, t.prototype.next = function(n) {
this.isStopped || this._next(n);
}, t.prototype.error = function(n) {
this.isStopped || (this.isStopped = !0, this._error(n));
}, t.prototype.complete = function() {
this.isStopped || (this.isStopped = !0, this._complete());
}, t.prototype.unsubscribe = function() {
this.closed || (this.isStopped = !0, e.prototype.unsubscribe.call(this), this.destination = null);
}, t.prototype._next = function(n) {
this.destination.next(n);
}, t.prototype._error = function(n) {
try {
this.destination.error(n);
} finally {
this.unsubscribe();
}
}, t.prototype._complete = function() {
try {
this.destination.complete();
} finally {
this.unsubscribe();
}
}, t;
}(ns), eb = function() {
function e(t) {
this.partialObserver = t;
}
return e.prototype.next = function(t) {
var n = this.partialObserver;
if (n.next)
try {
n.next(t);
} catch (a) {
ir(a);
}
}, e.prototype.error = function(t) {
var n = this.partialObserver;
if (n.error)
try {
n.error(t);
} catch (a) {
ir(a);
}
else
ir(t);
}, e.prototype.complete = function() {
var t = this.partialObserver;
if (t.complete)
try {
t.complete();
} catch (n) {
ir(n);
}
}, e;
}(), hl = function(e) {
qa(t, e);
function t(n, a, r) {
var s = e.call(this) || this, l;
return Ut(n) || !n ? l = {
next: n ?? void 0,
error: a ?? void 0,
complete: r ?? void 0
} : l = n, s.destination = new eb(l), s;
}
return t;
}(si);
function ir(e) {
Xg(e);
}
function tb(e) {
throw e;
}
var nb = {
closed: !0,
next: Eo,
error: tb,
complete: Eo
}, ab = function() {
return typeof Symbol == "function" && Symbol.observable || "@@observable";
}();
function rb(e) {
return e;
}
function sb(e) {
return e.length === 0 ? rb : e.length === 1 ? e[0] : function(n) {
return e.reduce(function(a, r) {
return r(a);
}, n);
};
}
var Do = function() {
function e(t) {
t && (this._subscribe = t);
}
return e.prototype.lift = function(t) {
var n = new e();
return n.source = this, n.operator = t, n;
}, e.prototype.subscribe = function(t, n, a) {
var r = this, s = ib(t) ? t : new hl(t, n, a);
return mr(function() {
var l = r, i = l.operator, o = l.source;
s.add(i ? i.call(s, o) : o ? r._subscribe(s) : r._trySubscribe(s));
}), s;
}, e.prototype._trySubscribe = function(t) {
try {
return this._subscribe(t);
} catch (n) {
t.error(n);
}
}, e.prototype.forEach = function(t, n) {
var a = this;
return n = Mo(n), new n(function(r, s) {
var l = new hl({
next: function(i) {
try {
t(i);
} catch (o) {
s(o), l.unsubscribe();
}
},
error: s,
complete: r
});
a.subscribe(l);
});
}, e.prototype._subscribe = function(t) {
var n;
return (n = this.source) === null || n === void 0 ? void 0 : n.subscribe(t);
}, e.prototype[ab] = function() {
return this;
}, e.prototype.pipe = function() {
for (var t = [], n = 0; n < arguments.length; n++)
t[n] = arguments[n];
return sb(t)(this);
}, e.prototype.toPromise = function(t) {
var n = this;
return t = Mo(t), new t(function(a, r) {
var s;
n.subscribe(function(l) {
return s = l;
}, function(l) {
return r(l);
}, function() {
return a(s);
});
});
}, e.create = function(t) {
return new e(t);
}, e;
}();
function Mo(e) {
var t;
return (t = e ?? Jg.Promise) !== null && t !== void 0 ? t : Promise;
}
function lb(e) {
return e && Ut(e.next) && Ut(e.error) && Ut(e.complete);
}
function ib(e) {
return e && e instanceof si || lb(e) && rd(e);
}
function ob(e) {
return Ut(e?.lift);
}
function sd(e) {
return function(t) {
if (ob(t))
return t.lift(function(n) {
try {
return e(n, this);
} catch (a) {
this.error(a);
}
});
throw new TypeError("Unable to lift unknown Observable type");
};
}
function ld(e, t, n, a, r) {
return new ub(e, t, n, a, r);
}
var ub = function(e) {
qa(t, e);
function t(n, a, r, s, l, i) {
var o = e.call(this, n) || this;
return o.onFinalize = l, o.shouldUnsubscribe = i, o._next = a ? function(u) {
try {
a(u);
} catch (c) {
n.error(c);
}
} : e.prototype._next, o._error = s ? function(u) {
try {
s(u);
} catch (c) {
n.error(c);
} finally {
this.unsubscribe();
}
} : e.prototype._error, o._complete = r ? function() {
try {
r();
} catch (u) {
n.error(u);
} finally {
this.unsubscribe();
}
} : e.prototype._complete, o;
}
return t.prototype.unsubscribe = function() {
var n;
if (!this.shouldUnsubscribe || this.shouldUnsubscribe()) {
var a = this.closed;
e.prototype.unsubscribe.call(this), !a && ((n = this.onFinalize) === null || n === void 0 || n.call(this));
}
}, t;
}(si), cb = nd(function(e) {
return function() {
e(this), this.name = "ObjectUnsubscribedError", this.message = "object unsubscribed";
};
}), id = function(e) {
qa(t, e);
function t() {
var n = e.call(this) || this;
return n.closed = !1, n.currentObservers = null, n.observers = [], n.isStopped = !1, n.hasError = !1, n.thrownError = null, n;
}
return t.prototype.lift = function(n) {
var a = new Ro(this, this);
return a.operator = n, a;
}, t.prototype._throwIfClosed = function() {
if (this.closed)
throw new cb();
}, t.prototype.next = function(n) {
var a = this;
mr(function() {
var r, s;
if (a._throwIfClosed(), !a.isStopped) {
a.currentObservers || (a.currentObservers = Array.from(a.observers));
try {
for (var l = ul(a.currentObservers), i = l.next(); !i.done; i = l.next()) {
var o = i.value;
o.next(n);
}
} catch (u) {
r = { error: u };
} finally {
try {
i && !i.done && (s = l.return) && s.call(l);
} finally {
if (r) throw r.error;
}
}
}
});
}, t.prototype.error = function(n) {
var a = this;
mr(function() {
if (a._throwIfClosed(), !a.isStopped) {
a.hasError = a.isStopped = !0, a.thrownError = n;
for (var r = a.observers; r.length; )
r.shift().error(n);
}
});
}, t.prototype.complete = function() {
var n = this;
mr(function() {
if (n._throwIfClosed(), !n.isStopped) {
n.isStopped = !0;
for (var a = n.observers; a.length; )
a.shift().complete();
}
});
}, t.prototype.unsubscribe = function() {
this.isStopped = this.closed = !0, this.observers = this.currentObservers = null;
}, Object.defineProperty(t.prototype, "observed", {
get: function() {
var n;
return ((n = this.observers) === null || n === void 0 ? void 0 : n.length) > 0;
},
enumerable: !1,
configurable: !0
}), t.prototype._trySubscribe = function(n) {
return this._throwIfClosed(), e.prototype._trySubscribe.call(this, n);
}, t.prototype._subscribe = function(n) {
return this._throwIfClosed(), this._checkFinalizedStatuses(n), this._innerSubscribe(n);
}, t.prototype._innerSubscribe = function(n) {
var a = this, r = this, s = r.hasError, l = r.isStopped, i = r.observers;
return s || l ? ad : (this.currentObservers = null, i.push(n), new ns(function() {
a.currentObservers = null, fl(i, n);
}));
}, t.prototype._checkFinalizedStatuses = function(n) {
var a = this, r = a.hasError, s = a.thrownError, l = a.isStopped;
r ? n.error(s) : l && n.complete();
}, t.prototype.asObservable = function() {
var n = new Do();
return n.source = this, n;
}, t.create = function(n, a) {
return new Ro(n, a);
}, t;
}(Do), Ro = function(e) {
qa(t, e);
function t(n, a) {
var r = e.call(this) || this;
return r.destination = n, r.source = a, r;
}
return t.prototype.next = function(n) {
var a, r;
(r = (a = this.destination) === null || a === void 0 ? void 0 : a.next) === null || r === void 0 || r.call(a, n);
}, t.prototype.error = function(n) {
var a, r;
(r = (a = this.destination) === null || a === void 0 ? void 0 : a.error) === null || r === void 0 || r.call(a, n);
}, t.prototype.complete = function() {
var n, a;
(a = (n = this.destination) === null || n === void 0 ? void 0 : n.complete) === null || a === void 0 || a.call(n);
}, t.prototype._subscribe = function(n) {
var a, r;
return (r = (a = this.source) === null || a === void 0 ? void 0 : a.subscribe(n)) !== null && r !== void 0 ? r : ad;
}, t;
}(id);
function db(e, t) {
return sd(function(n, a) {
var r = 0;
n.subscribe(ld(a, function(s) {
a.next(e.call(t, s, r++));
}));
});
}
function fb(e, t) {
return sd(function(n, a) {
var r = 0;
n.subscribe(ld(a, function(s) {
return e.call(t, s, r++) && a.next(s);
}));
});
}
class Fo {
constructor(t, n) {
xe(this, "name");
xe(this, "value");
this.name = t, this.value = n;
}
}
const hb = "https://cdn.jsdelivr.net/gh/p2m2/discovery@0.3.2/dist/discovery-web.min.js";
class Ma {
constructor() {
//extends Vue
xe(this, "_subject", new id());
xe(this, "url", "https://forum.semantic-metabolomics.fr/sparql/");
xe(this, "mimetype", "application/sparql-query");
xe(this, "method", "POST");
xe(this, "cache", !0);
xe(this, "logLevel", "info");
xe(this, "batchProcessing", 80);
xe(this, "pageSize", 10);
xe(this, "discovery", null);
}
static buildDiscoveryObject() {
return {
SWDiscoveryConfiguration: window.SWDiscoveryConfiguration,
SWDiscovery: window.SWDiscovery,
SWTransaction: window.SWTransaction,
URI: window.URI,
Literal: window.Literal,
PropertyPath: window.PropertyPath
};
}
/**
*
* @returns return Discovery lib as a promise
*/
loadDiscovery() {
const t = this;
return new Promise((n, a) => {
if (t.discovery != null) {
n(t.discovery);
return;
}
const r = document.createElement("script");
r.type = "text/javascript", r.src = hb, r.readyState ? r.onreadystatechange = () => {
(r.readyState === "loaded" || r.readyState === "complete") && (r.onreadystatechange = null, n(Ma.buildDiscoveryObject()));
} : r.onload = () => {
n(Ma.buildDiscoveryObject());
}, r.onerror = (s) => {
console.error("error", s);
}, document.getElementsByTagName("head")[0].appendChild(r);
});
}
emit(t) {
this._subject.next(t);
}
on(t, n) {
return this._subject.pipe(
fb((a) => a.name === t),
db((a) => a.value)
).subscribe(n);
}
getConfiguration() {
return `{
"sources" : [{
"id" : "__id__",
"url" : "` + this.url + `",
"method" : "` + this.method + `",
"mimetype" : "` + this.mimetype + `"}],
"settings" : {
"cache" : ` + this.cache + `,
"logLevel" : "` + this.logLevel + `",
"sizeBatchProcessing" : ` + this.batchProcessing + `,
"pageSize" : ` + this.pageSize + `
}
}`;
}
/**
*
* @param cid : Pubchem identifier
* @param meshid : meshid : identifiers
* @returns number of layzy pages/listOfLazyPage
*/
async getLazyPagesPMIDs(t, n, a = this.getConfiguration()) {
const s = await this.loadDiscovery(), l = s.URI, i = s.PropertyPath, o = s.Literal, u = s.SWDiscoveryConfiguration, c = s.SWDiscovery;
s.SWTransaction;
const d = t && t.startsWith("CID") ? t : "CID" + t, f = u.setConfigString(a);
return new Promise((v, m) => {
let y;
a.includes(this.url) ? y = c(f).directive(
'DEFINE input:inference "schema-inference-rules"'
) : y = c(f), y.prefix("dcterm", "http://purl.org/dc/terms/").prefix("cid", "http://rdf.ncbi.nlm.nih.gov/pubchem/compound/").prefix("cito", "http://purl.org/spar/cito/").prefix("meshv", "http://id.nlm.nih.gov/mesh/vocab#").prefix("mesh", "http://id.nlm.nih.gov/mesh/").prefix("fabio", "http://purl.org/spar/fabio/").something("cid").set(l("cid:" + d)).isSubjectOf(l("cito:isDiscussedBy"), "pmid").datatype(l("http://purl.org/dc/terms/title"), "title").datatype(l("http://purl.org/dc/terms/date"), "date").isSubjectOf(
i(
"fabio:hasSubjectTerm|fabio:hasSubjectTerm/meshv:hasDescriptor"
),
"mesh_ini"
).isSubjectOf(
i(
"meshv:treeNumber|meshv:treeNumber/meshv:parentTreeNumber"
)
).isObjectOf(l("meshv:treeNumber")).set(l("mesh:" + n)).focus("mesh_ini").isA(l("meshv:TopicalDescriptor")).focus("mesh_ini").isSubjectOf("meshv:active").set(o(1)).focus("pmid").isSubjectOf("dcterm:date", "dateToOrdered").selectDistinctByPage("pmid", "title", "date").then((h) => {
let b = Object.values(h)[0], S = Object.values(
h
)[1];
v([b, S]);
}).catch((h) => {
m(h);
});
});
}
async getPMIDs(t) {
const n = this;
(await n.loadDiscovery()).SWTransaction;
const r = t;
return new Promise((s, l) => {
r.distinct().orderByDesc("dateToOrdered").commit().progression((i) => {
n.emit(new Fo("progression", i));
}).requestEvent((i) => {
n.emit(new Fo("requestEvent", i));
}).raw().then((i) => {
console.log("response", JSON.stringify(i));
let o = [];
if (i.results && i.results.bindings)
for (let u = 0; u < i.results.bindings.length; u++) {
let c = i.results.bindings[u].pmid.value, d = c.split("/").pop(), f = i.results.datatypes.title[c][0].value, v = i.results.datatypes.date[c][0].value;
console.log(c + "-->" + f + "," + v), o.push({
PMID: d,
urlPMID: c,
Title: f,
Date: v
});
}
s(o);
}).catch((i) => {
l(i);
});
});
}
}
function Lo() {
return {
PMID: "",
Title: "",
Date: "",
urlPMID: ""
};
}
const mb = Rr({
name: "MthForumLiteratureDisplay",
props: ["searchType", "searchId", "itemId"],
watch: {
itemId: function(e, t) {
console.debug("Prop changed: ", e, " | was: ", t), this.literatureItemId = e, this.discoveryService = new Ma(), this.progression = 0, this.laziestPages = [], this.pagesLength = 0, this.pageSize = 10, this.currentPage = 0, this.headers = [], this.dataSource = [], this.display_loading_div = !0, this.display_results_div = !1, this.initDataTableHeaders(), this.initDatatableContent();
}
},
setup(e) {
const t = R(!1), n = R(!1), a = R(new Ma()), r = R(0), s = [], l = [], i = R(0), o = R(10), u = R(0), c = e.searchType, d = e.searchId, f = e.itemId, v = R([]), m = R([]);
return {
// hide / show elelements
display_loading_div: t,
display_results_div: n,
// litterature query config.
literatureSearchType: c,
literatureSearchId: d,
literatureItemId: f,
// discovery config.
discoveryService: a,
progression: r,
laziestPages: s,
pagesLength: i,
listOfPMIDs: l,
pageSize: o,
currentPage: u,
// data-table
headers: v,
dataSource: m,
// footer
footerProps: {
firstIcon: "fas fa-angle-double-left",
lastIcon: "fas fa-angle-double-right",
prevIcon: "fas fa-chevron-left",
nextIcon: "fas fa-chevron-right"
}
};
},
mounted() {
this.display_loading_div = !0, this.display_results_div = !1, this.initDataTableHeaders(), this.initDatatableContent();
},
methods: {
/**
* Init data-table content
*/
initDatatableContent() {
this.discoveryService.on(
"progression",
(e) => this.progression = 100 * e
), this.discoveryService.on(
"requestEvent",
(e) => console.log(e)
), this.getAllPMIDs();
},
/** init all PMIDs */
getAllPMIDs() {
this.discoveryService.getLazyPagesPMIDs(this.literatureSearchId, this.literatureItemId).then((e) => {
const t = e[0], n = { ...e[1] }, a = [];
for (const r in n)
a.push(n[r]);
this.laziestPages = a, this.listOfPMIDs = new Array(t).fill(Lo()), this.laziestPages && this.laziestPages.length > 0 ? (this.currentPage >= this.laziestPages.length && (this.currentPage = 0), this.laziestPages[this.currentPage], this.getPMIDs(this.laziestPages[this.currentPage])) : (this.currentPage = 0, this.pageSize = 0), this.display_loading_div = !1;
}).catch((e) => {
console.error(e);
});
},
/** display a set of PMIDs */
getPMIDs(e) {
this.discoveryService.getPMIDs(e).then((t) => {
const n = this.currentPage * this.pageSize;
for (let a = 0; a < this.pageSize; a++)
this.listOfPMIDs[n + a] = t[a];
this.afterViewInit();
}).catch((t) => {
console.error(t);
});
},
afterViewInit() {
this.display_loading_div = !1, this.display_results_div = !0, this.laziestPages && this.currentPage == this.laziestPages.length - 1 ? this.dataSource = //new MatTableDataSource(
this.listOfPMIDs.filter((e) => e && e.PMID) : this.dataSource = //new MatTableDataSource(
this.listOfPMIDs.map((e) => e || Lo());
},
/**
* Method called when a "pagination event" occure on "litterature data-table"
* @param e the triggered event
*/
handlePage(e) {
this.display_loading_div = !0, console.log("e", e), e.itemsPerPage != this.pageSize && (this.discoveryService.pageSize = e.itemsPerPage, this.pageSize = this.discoveryService.pageSize, this.getAllPMIDs()), this.currentPage = e.page, this.laziestPages && this.laziestPages.length > 0 && this.getPMIDs(this.laziestPages[this.currentPage]);
},
/**
* Init data-table headers
*/
initDataTableHeaders() {
this.headers = [
{
title: "PMID",
align: "start",
key: "PMID",
sortable: !1
},
{
title: "Title",
key: "Title",
sortable: !1
},
{ title: "Date", key: "Date", sortable: !1 }
];
}
}
}), od = M({
baseColor: String,
divided: Boolean,
...dn(),
...ce(),
...Ct(),
...Pn(),
...kt(),
...Le(),
...Ye(),
...fn()
}, "VBtnGroup"), No = G()({
name: "VBtnGroup",
props: od(),
setup(e, t) {
let {
slots: n
} = t;
const {
themeClasses: a
} = Ze(e), {
densityClasses: r
} = Wt(e), {
borderClasses: s
} = Cn(e), {
elevationClasses: l
} = Un(e), {
roundedClasses: i
} = Dt(e);
zt({
VBtn: {
height: "auto",
baseColor: I(() => e.baseColor),
color: I(() => e.color),
density: I(() => e.density),
flat: !0,
variant: I(() => e.variant)
}
}), ee(() => g(e.tag, {
class: Q(["v-btn-group", {
"v-btn-group--divided": e.divided
}, a.value, s.value, r.value, l.value, i.value, e.class]),
style: J(e.style)
}, n));
}
}), ud = Symbol.for("vuetify:v-btn-toggle"), vb = M({
...od(),
...Wl()
}, "VBtnToggle");
G()({
name: "VBtnToggle",
props: vb(),
emits: {
"update:modelValue": (e) => !0
},
setup(e, t) {
let {
slots: n
} = t;
const {
isSelected: a,
next: r,
prev: s,
select: l,
selected: i
} = Gl(e, ud);
return ee(() => {
const o = No.filterProps(e);
return g(No, j({
class: ["v-btn-toggle", e.class]
}, o, {
style: e.style
}), {
default: () => [n.default?.({
isSelected: a,
next: r,
prev: s,
select: l,
selected: i
})]
});
}), {
next: r,
prev: s,
select: l
};
}
});
const yb = ["static", "relative", "fixed", "absolute", "sticky"], cd = M({
position: {
type: String,
validator: (
/* istanbul ignore next */
(e) => yb.includes(e)
)
}
}, "position");
function dd(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : jt();
return {
positionClasses: I(() => e.position ? `${t}--${e.position}` : void 0)
};
}
function gb(e, t) {
re(() => e.isActive?.value, (n) => {
e.isLink.value && n && t && Ge(() => {
t(!0);
});
}, {
immediate: !0
});
}
const bb = M({
active: {
type: Boolean,
default: void 0
},
activeColor: String,
baseColor: String,
symbol: {
type: null,
default: ud
},
flat: Boolean,
icon: [Boolean, String, Function, Object],
prependIcon: le,
appendIcon: le,
block: Boolean,
readonly: Boolean,
slim: Boolean,
stacked: Boolean,
ripple: {
type: [Boolean, Object],
default: !0
},
text: {
type: [String, Number, Boolean],
default: void 0
},
...dn(),
...ce(),
...Ct(),
...un(),
...Pn(),
...oc(),
...es(),
...Xl(),
...cd(),
...kt(),
...Xr(),
...la(),
...Le({
tag: "button"
}),
...Ye(),
...fn({
variant: "elevated"
})
}, "VBtn"), Zt = G()({
name: "VBtn",
props: bb(),
emits: {
"group:selected": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
themeClasses: r
} = Ze(e), {
borderClasses: s
} = Cn(e), {
densityClasses: l
} = Wt(e), {
dimensionStyles: i
} = cn(e), {
elevationClasses: o
} = Un(e), {
loaderClasses: u
} = Qa(e), {
locationStyles: c
} = ei(e), {
positionClasses: d
} = dd(e), {
roundedClasses: f
} = Dt(e), {
sizeClasses: v,
sizeStyles: m
} = Ya(e), y = uc(e, e.symbol, !1), h = Zr(e, n), b = _(() => e.active !== void 0 ? e.active : h.isLink.value ? h.isActive?.value : y?.isSelected.value), S = I(() => b.value ? e.activeColor ?? e.color : e.color), P = _(() => ({
color: y?.isSelected.value && (!h.isLink.value || h.isActive?.value) || !y || h.isActive?.value ? S.value ?? e.baseColor : e.baseColor,
variant: e.variant
})), {
colorClasses: O,
colorStyles: k,
variantClasses: E
} = Wa(P), V = _(() => y?.disabled.value || e.disabled), w = I(() => e.variant === "elevated" && !(e.disabled || e.flat || e.border)), T = _(() => {
if (!(e.value === void 0 || typeof e.value == "symbol"))
return Object(e.value) === e.value ? JSON.stringify(e.value, null, 0) : e.value;
});
function L($) {
V.value || h.isLink.value && ($.metaKey || $.ctrlKey || $.shiftKey || $.button !== 0 || n.target === "_blank") || (h.navigate?.($), y?.toggle());
}
return gb(h, y?.select), ee(() => {
const $ = h.isLink.value ? "a" : e.tag, B = !!(e.prependIcon || a.prepend), D = !!(e.appendIcon || a.append), H = !!(e.icon && e.icon !== !0);
return ht(g($, j({
type: $ === "a" ? void 0 : "button",
class: ["v-btn", y?.selectedClass.value, {
"v-btn--active": b.value,
"v-btn--block": e.block,
"v-btn--disabled": V.value,
"v-btn--elevated": w.value,
"v-btn--flat": e.flat,
"v-btn--icon": !!e.icon,
"v-btn--loading": e.loading,
"v-btn--readonly": e.readonly,
"v-btn--slim": e.slim,
"v-btn--stacked": e.stacked
}, r.value, s.value, O.value, l.value, o.value, u.value, d.value, f.value, v.value, E.value, e.class],
style: [k.value, i.value, c.value, m.value, e.style],
"aria-busy": e.loading ? !0 : void 0,
disabled: V.value || void 0,
tabindex: e.loading || e.readonly ? -1 : void 0,
onClick: L,
value: T.value
}, h.linkProps), {
default: () => [ja(!0, "v-btn"), !e.icon && B && p("span", {
key: "prepend",
class: "v-btn__prepend"
}, [a.prepend ? g(Ne, {
key: "prepend-defaults",
disabled: !e.prependIcon,
defaults: {
VIcon: {
icon: e.prependIcon
}
}
}, a.prepend) : g(Ve, {
key: "prepend-icon",
icon: e.prependIcon
}, null)]), p("span", {
class: "v-btn__content",
"data-no-activator": ""
}, [!a.default && H ? g(Ve, {
key: "content-icon",
icon: e.icon
}, null) : g(Ne, {
key: "content-defaults",
disabled: !H,
defaults: {
VIcon: {
icon: e.icon
}
}
}, {
default: () => [a.default?.() ?? Te(e.text)]
})]), !e.icon && D && p("span", {
key: "append",
class: "v-btn__append"
}, [a.append ? g(Ne, {
key: "append-defaults",
disabled: !e.appendIcon,
defaults: {
VIcon: {
icon: e.appendIcon
}
}
}, a.append) : g(Ve, {
key: "append-icon",
icon: e.appendIcon
}, null)]), !!e.loading && p("span", {
key: "loader",
class: "v-btn__loader"
}, [a.loader?.() ?? g(td, {
color: typeof e.loading == "boolean" ? void 0 : e.loading,
indeterminate: !0,
width: "2"
}, null)])]
}), [[sn, !V.value && e.ripple, "", {
center: !!e.icon
}]]);
}), {
group: y
};
}
});
function pb() {
const e = R([]);
zf(() => e.value = []);
function t(n, a) {
e.value[a] = n;
}
return {
refs: e,
updateRef: t
};
}
const Sb = M({
activeColor: String,
start: {
type: [Number, String],
default: 1
},
modelValue: {
type: Number,
default: (e) => e.start
},
disabled: Boolean,
length: {
type: [Number, String],
default: 1,
validator: (e) => e % 1 === 0
},
totalVisible: [Number, String],
firstIcon: {
type: le,
default: "$first"
},
prevIcon: {
type: le,
default: "$prev"
},
nextIcon: {
type: le,
default: "$next"
},
lastIcon: {
type: le,
default: "$last"
},
ariaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.root"
},
pageAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.page"
},
currentPageAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.currentPage"
},
firstAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.first"
},
previousAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.previous"
},
nextAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.next"
},
lastAriaLabel: {
type: String,
default: "$vuetify.pagination.ariaLabel.last"
},
ellipsis: {
type: String,
default: "..."
},
showFirstLastPage: Boolean,
...dn(),
...ce(),
...Ct(),
...Pn(),
...kt(),
...la(),
...Le({
tag: "nav"
}),
...Ye(),
...fn({
variant: "text"
})
}, "VPagination"), Bo = G()({
name: "VPagination",
props: Sb(),
emits: {
"update:modelValue": (e) => !0,
first: (e) => !0,
prev: (e) => !0,
next: (e) => !0,
last: (e) => !0
},
setup(e, t) {
let {
slots: n,
emit: a
} = t;
const r = _e(e, "modelValue"), {
t: s,
n: l
} = hn(), {
isRtl: i
} = Mt(), {
themeClasses: o
} = Ze(e), {
width: u
} = $n(), c = ne(-1);
zt(void 0, {
scoped: !0
});
const {
resizeRef: d
} = ta((w) => {
if (!w.length) return;
const {
target: T,
contentRect: L
} = w[0], $ = T.querySelector(".v-pagination__list > *");
if (!$) return;
const B = L.width, D = $.offsetWidth + parseFloat(getComputedStyle($).marginRight) * 2;
c.value = y(B, D);
}), f = _(() => parseInt(e.length, 10)), v = _(() => parseInt(e.start, 10)), m = _(() => e.totalVisible != null ? parseInt(e.totalVisible, 10) : c.value >= 0 ? c.value : y(u.value, 58));
function y(w, T) {
const L = e.showFirstLastPage ? 5 : 3;
return Math.max(0, Math.floor(
// Round to two decimal places to avoid floating point errors
Number(((w - T * L) / T).toFixed(2))
));
}
const h = _(() => {
if (f.value <= 0 || isNaN(f.value) || f.value > Number.MAX_SAFE_INTEGER) return [];
if (m.value <= 0) return [];
if (m.value === 1) return [r.value];
if (f.value <= m.value)
return nr(f.value, v.value);
const w = m.value % 2 === 0, T = w ? m.value / 2 : Math.floor(m.value / 2), L = w ? T : T + 1, $ = f.value - T;
if (L - r.value >= 0)
return [...nr(Math.max(1, m.value - 1), v.value), e.ellipsis, f.value];
if (r.value - $ >= (w ? 1 : 0)) {
const B = m.value - 1, D = f.value - B + v.value;
return [v.value, e.ellipsis, ...nr(B, D)];
} else {
const B = Math.max(1, m.value - 2), D = B === 1 ? r.value : r.value - Math.ceil(B / 2) + v.value;
return [v.value, e.ellipsis, ...nr(B, D), e.ellipsis, f.value];
}
});
function b(w, T, L) {
w.preventDefault(), r.value = T, L && a(L, T);
}
const {
refs: S,
updateRef: P
} = pb();
zt({
VPaginationBtn: {
color: I(() => e.color),
border: I(() => e.border),
density: I(() => e.density),
size: I(() => e.size),
variant: I(() => e.variant),
rounded: I(() => e.rounded),
elevation: I(() => e.elevation)
}
});
const O = _(() => h.value.map((w, T) => {
const L = ($) => P($, T);
if (typeof w == "string")
return {
isActive: !1,
key: `ellipsis-${T}`,
page: w,
props: {
ref: L,
ellipsis: !0,
icon: !0,
disabled: !0
}
};
{
const $ = w === r.value;
return {
isActive: $,
key: w,
page: l(w),
props: {
ref: L,
ellipsis: !1,
icon: !0,
disabled: !!e.disabled || Number(e.length) < 2,
color: $ ? e.activeColor : e.color,
"aria-current": $,
"aria-label": s($ ? e.currentPageAriaLabel : e.pageAriaLabel, w),
onClick: (B) => b(B, w)
}
};
}
})), k = _(() => {
const w = !!e.disabled || r.value <= v.value, T = !!e.disabled || r.value >= v.value + f.value - 1;
return {
first: e.showFirstLastPage ? {
icon: i.value ? e.lastIcon : e.firstIcon,
onClick: (L) => b(L, v.value, "first"),
disabled: w,
"aria-label": s(e.firstAriaLabel),
"aria-disabled": w
} : void 0,
prev: {
icon: i.value ? e.nextIcon : e.prevIcon,
onClick: (L) => b(L, r.value - 1, "prev"),
disabled: w,
"aria-label": s(e.previousAriaLabel),
"aria-disabled": w
},
next: {
icon: i.value ? e.prevIcon : e.nextIcon,
onClick: (L) => b(L, r.value + 1, "next"),
disabled: T,
"aria-label": s(e.nextAriaLabel),
"aria-disabled": T
},
last: e.showFirstLastPage ? {
icon: i.value ? e.firstIcon : e.lastIcon,
onClick: (L) => b(L, v.value + f.value - 1, "last"),
disabled: T,
"aria-label": s(e.lastAriaLabel),
"aria-disabled": T
} : void 0
};
});
function E() {
const w = r.value - v.value;
S.value[w]?.$el.focus();
}
function V(w) {
w.key === Wi.left && !e.disabled && r.value > Number(e.start) ? (r.value = r.value - 1, Ge(E)) : w.key === Wi.right && !e.disabled && r.value < v.value + f.value - 1 && (r.value = r.value + 1, Ge(E));
}
return ee(() => g(e.tag, {
ref: d,
class: Q(["v-pagination", o.value, e.class]),
style: J(e.style),
role: "navigation",
"aria-label": s(e.ariaLabel),
onKeydown: V,
"data-test": "v-pagination-root"
}, {
default: () => [p("ul", {
class: "v-pagination__list"
}, [e.showFirstLastPage && p("li", {
key: "first",
class: "v-pagination__first",
"data-test": "v-pagination-first"
}, [n.first ? n.first(k.value.first) : g(Zt, j({
_as: "VPaginationBtn"
}, k.value.first), null)]), p("li", {
key: "prev",
class: "v-pagination__prev",
"data-test": "v-pagination-prev"
}, [n.prev ? n.prev(k.value.prev) : g(Zt, j({
_as: "VPaginationBtn"
}, k.value.prev), null)]), O.value.map((w, T) => p("li", {
key: w.key,
class: Q(["v-pagination__item", {
"v-pagination__item--is-active": w.isActive
}]),
"data-test": "v-pagination-item"
}, [n.item ? n.item(w) : g(Zt, j({
_as: "VPaginationBtn"
}, w.props), {
default: () => [w.page]
})])), p("li", {
key: "next",
class: "v-pagination__next",
"data-test": "v-pagination-next"
}, [n.next ? n.next(k.value.next) : g(Zt, j({
_as: "VPaginationBtn"
}, k.value.next), null)]), e.showFirstLastPage && p("li", {
key: "last",
class: "v-pagination__last",
"data-test": "v-pagination-last"
}, [n.last ? n.last(k.value.last) : g(Zt, j({
_as: "VPaginationBtn"
}, k.value.last), null)])])]
})), {};
}
}), wb = M({
page: {
type: [Number, String],
default: 1
},
itemsPerPage: {
type: [Number, String],
default: 10
}
}, "DataTable-paginate"), fd = Symbol.for("vuetify:data-table-pagination");
function _b(e) {
const t = _e(e, "page", void 0, (a) => Number(a ?? 1)), n = _e(e, "itemsPerPage", void 0, (a) => Number(a ?? 10));
return {
page: t,
itemsPerPage: n
};
}
function kb(e) {
const {
page: t,
itemsPerPage: n,
itemsLength: a
} = e, r = _(() => n.value === -1 ? 0 : n.value * (t.value - 1)), s = _(() => n.value === -1 ? a.value : Math.min(a.value, r.value + n.value)), l = _(() => n.value === -1 || a.value === 0 ? 1 : Math.ceil(a.value / n.value));
re([t, l], () => {
t.value > l.value && (t.value = l.value);
});
function i(f) {
n.value = f, t.value = 1;
}
function o() {
t.value = bt(t.value + 1, 1, l.value);
}
function u() {
t.value = bt(t.value - 1, 1, l.value);
}
function c(f) {
t.value = bt(f, 1, l.value);
}
const d = {
page: t,
itemsPerPage: n,
startIndex: r,
stopIndex: s,
pageCount: l,
itemsLength: a,
nextPage: o,
prevPage: u,
setPage: c,
setItemsPerPage: i
};
return We(fd, d), d;
}
function Cb() {
const e = De(fd);
if (!e) throw new Error("Missing pagination!");
return e;
}
function Pb(e) {
const t = Ue("usePaginatedItems"), {
items: n,
startIndex: a,
stopIndex: r,
itemsPerPage: s
} = e, l = _(() => s.value <= 0 ? n.value : n.value.slice(a.value, r.value));
return re(l, (i) => {
t.emit("update:currentItems", i);
}, {
immediate: !0
}), {
paginatedItems: l
};
}
const hd = M({
prevIcon: {
type: le,
default: "$prev"
},
nextIcon: {
type: le,
default: "$next"
},
firstIcon: {
type: le,
default: "$first"
},
lastIcon: {
type: le,
default: "$last"
},
itemsPerPageText: {
type: String,
default: "$vuetify.dataFooter.itemsPerPageText"
},
pageText: {
type: String,
default: "$vuetify.dataFooter.pageText"
},
firstPageLabel: {
type: String,
default: "$vuetify.dataFooter.firstPage"
},
prevPageLabel: {
type: String,
default: "$vuetify.dataFooter.prevPage"
},
nextPageLabel: {
type: String,
default: "$vuetify.dataFooter.nextPage"
},
lastPageLabel: {
type: String,
default: "$vuetify.dataFooter.lastPage"
},
itemsPerPageOptions: {
type: Array,
default: () => [{
value: 10,
title: "10"
}, {
value: 25,
title: "25"
}, {
value: 50,
title: "50"
}, {
value: 100,
title: "100"
}, {
value: -1,
title: "$vuetify.dataFooter.itemsPerPageAll"
}]
},
showCurrentPage: Boolean
}, "VDataTableFooter"), $o = G()({
name: "VDataTableFooter",
props: hd(),
setup(e, t) {
let {
slots: n
} = t;
const {
t: a
} = hn(), {
page: r,
pageCount: s,
startIndex: l,
stopIndex: i,
itemsLength: o,
itemsPerPage: u,
setItemsPerPage: c
} = Cb(), d = _(() => e.itemsPerPageOptions.map((f) => typeof f == "number" ? {
value: f,
title: f === -1 ? a("$vuetify.dataFooter.itemsPerPageAll") : String(f)
} : {
...f,
title: isNaN(Number(f.title)) ? a(f.title) : f.title
}));
return ee(() => {
const f = Bo.filterProps(e);
return p("div", {
class: "v-data-table-footer"
}, [n.prepend?.(), p("div", {
class: "v-data-table-footer__items-per-page"
}, [p("span", null, [a(e.itemsPerPageText)]), g(zc, {
items: d.value,
modelValue: u.value,
"onUpdate:modelValue": (v) => c(Number(v)),
density: "compact",
variant: "outlined",
"hide-details": !0
}, null)]), p("div", {
class: "v-data-table-footer__info"
}, [p("div", null, [a(e.pageText, o.value ? l.value + 1 : 0, i.value, o.value)])]), p("div", {
class: "v-data-table-footer__pagination"
}, [g(Bo, j({
modelValue: r.value,
"onUpdate:modelValue": (v) => r.value = v,
density: "comfortable",
"first-aria-label": e.firstPageLabel,
"last-aria-label": e.lastPageLabel,
length: s.value,
"next-aria-label": e.nextPageLabel,
"previous-aria-label": e.prevPageLabel,
rounded: !0,
"show-first-last-page": !0,
"total-visible": e.showCurrentPage ? 1 : 0,
variant: "plain"
}, f), null)])]);
}), {};
}
}), Tr = iv({
align: {
type: String,
default: "start"
},
fixed: Boolean,
fixedOffset: [Number, String],
height: [Number, String],
lastFixed: Boolean,
noPadding: Boolean,
tag: String,
width: [Number, String],
maxWidth: [Number, String],
nowrap: Boolean
}, (e, t) => {
let {
slots: n
} = t;
const a = e.tag ?? "td";
return g(a, {
class: Q(["v-data-table__td", {
"v-data-table-column--fixed": e.fixed,
"v-data-table-column--last-fixed": e.lastFixed,
"v-data-table-column--no-padding": e.noPadding,
"v-data-table-column--nowrap": e.nowrap
}, `v-data-table-column--align-${e.align}`]),
style: J({
height: te(e.height),
width: te(e.width),
maxWidth: te(e.maxWidth),
left: te(e.fixedOffset || null)
})
}, {
default: () => [n.default?.()]
});
}), xb = M({
headers: Array
}, "DataTable-header"), md = Symbol.for("vuetify:data-table-headers"), vd = {
title: "",
sortable: !1
}, Ib = {
...vd,
width: 48
};
function Ob() {
const t = (arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : []).map((n) => ({
element: n,
priority: 0
}));
return {
enqueue: (n, a) => {
let r = !1;
for (let s = 0; s < t.length; s++)
if (t[s].priority > a) {
t.splice(s, 0, {
element: n,
priority: a
}), r = !0;
break;
}
r || t.push({
element: n,
priority: a
});
},
size: () => t.length,
count: () => {
let n = 0;
if (!t.length) return 0;
const a = Math.floor(t[0].priority);
for (let r = 0; r < t.length; r++)
Math.floor(t[r].priority) === a && (n += 1);
return n;
},
dequeue: () => t.shift()
};
}
function ml(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
if (!e.children)
t.push(e);
else
for (const n of e.children)
ml(n, t);
return t;
}
function yd(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : /* @__PURE__ */ new Set();
for (const n of e)
n.key && t.add(n.key), n.children && yd(n.children, t);
return t;
}
function Tb(e) {
if (e.key) {
if (e.key === "data-table-group") return vd;
if (["data-table-expand", "data-table-select"].includes(e.key)) return Ib;
}
}
function li(e) {
let t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
return e.children ? Math.max(t, ...e.children.map((n) => li(n, t + 1))) : t;
}
function Vb(e) {
let t = !1;
function n(s) {
let l = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
if (s)
if (l && (s.fixed = !0), s.fixed)
if (s.children)
for (let i = s.children.length - 1; i >= 0; i--)
n(s.children[i], !0);
else
t ? isNaN(Number(s.width)) ? Fl(`Multiple fixed columns should have a static width (key: ${s.key})`) : s.minWidth = Math.max(Number(s.width) || 0, Number(s.minWidth) || 0) : s.lastFixed = !0, t = !0;
else if (s.children)
for (let i = s.children.length - 1; i >= 0; i--)
n(s.children[i]);
else
t = !1;
}
for (let s = e.length - 1; s >= 0; s--)
n(e[s]);
function a(s) {
let l = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
if (!s) return l;
if (s.children) {
s.fixedOffset = l;
for (const i of s.children)
l = a(i, l);
} else s.fixed && (s.fixedOffset = l, l += parseFloat(s.width || "0") || 0);
return l;
}
let r = 0;
for (const s of e)
r = a(s, r);
}
function Ab(e, t) {
const n = [];
let a = 0;
const r = Ob(e);
for (; r.size() > 0; ) {
let l = r.count();
const i = [];
let o = 1;
for (; l > 0; ) {
const {
element: u,
priority: c
} = r.dequeue(), d = t - a - li(u);
if (i.push({
...u,
rowspan: d ?? 1,
colspan: u.children ? ml(u).length : 1
}), u.children)
for (const f of u.children) {
const v = c % 1 + o / Math.pow(10, a + 2);
r.enqueue(f, a + d + v);
}
o += 1, l -= 1;
}
a += 1, n.push(i);
}
return {
columns: e.map((l) => ml(l)).flat(),
headers: n
};
}
function gd(e) {
const t = [];
for (const n of e) {
const a = {
...Tb(n),
...n
}, r = a.key ?? (typeof a.value == "string" ? a.value : null), s = a.value ?? r ?? null, l = {
...a,
key: r,
value: s,
sortable: a.sortable ?? (a.key != null || !!a.sort),
children: a.children ? gd(a.children) : void 0
};
t.push(l);
}
return t;
}
function Eb(e, t) {
const n = R([]), a = R([]), r = R({}), s = R({}), l = R({});
Ot(() => {
const u = (e.headers || Object.keys(e.items[0] ?? {}).map((y) => ({
key: y,
title: na(y)
}))).slice(), c = yd(u);
t?.groupBy?.value.length && !c.has("data-table-group") && u.unshift({
key: "data-table-group",
title: "Group"
}), t?.showSelect?.value && !c.has("data-table-select") && u.unshift({
key: "data-table-select"
}), t?.showExpand?.value && !c.has("data-table-expand") && u.push({
key: "data-table-expand"
});
const d = gd(u);
Vb(d);
const f = Math.max(...d.map((y) => li(y))) + 1, v = Ab(d, f);
n.value = v.headers, a.value = v.columns;
const m = v.headers.flat(1);
for (const y of m)
y.key && (y.sortable && (y.sort && (r.value[y.key] = y.sort), y.sortRaw && (s.value[y.key] = y.sortRaw)), y.filter && (l.value[y.key] = y.filter));
});
const i = {
headers: n,
columns: a,
sortFunctions: r,
sortRawFunctions: s,
filterFunctions: l
};
return We(md, i), i;
}
function as() {
const e = De(md);
if (!e) throw new Error("Missing headers!");
return e;
}
const Db = {
showSelectAll: !1,
allSelected: () => [],
select: (e) => {
let {
items: t,
value: n
} = e;
return new Set(n ? [t[0]?.value] : []);
},
selectAll: (e) => {
let {
selected: t
} = e;
return t;
}
}, bd = {
showSelectAll: !0,
allSelected: (e) => {
let {
currentPage: t
} = e;
return t;
},
select: (e) => {
let {
items: t,
value: n,
selected: a
} = e;
for (const r of t)
n ? a.add(r.value) : a.delete(r.value);
return a;
},
selectAll: (e) => {
let {
value: t,
currentPage: n,
selected: a
} = e;
return bd.select({
items: n,
value: t,
selected: a
});
}
}, pd = {
showSelectAll: !0,
allSelected: (e) => {
let {
allItems: t
} = e;
return t;
},
select: (e) => {
let {
items: t,
value: n,
selected: a
} = e;
for (const r of t)
n ? a.add(r.value) : a.delete(r.value);
return a;
},
selectAll: (e) => {
let {
value: t,
allItems: n,
selected: a
} = e;
return pd.select({
items: n,
value: t,
selected: a
});
}
}, Mb = M({
showSelect: Boolean,
selectStrategy: {
type: [String, Object],
default: "page"
},
modelValue: {
type: Array,
default: () => []
},
valueComparator: {
type: Function,
default: gt
}
}, "DataTable-select"), Sd = Symbol.for("vuetify:data-table-selection");
function Rb(e, t) {
let {
allItems: n,
currentPage: a
} = t;
const r = _e(e, "modelValue", e.modelValue, (S) => new Set(Ke(S).map((P) => n.value.find((O) => e.valueComparator(P, O.value))?.value ?? P)), (S) => [...S.values()]), s = _(() => n.value.filter((S) => S.selectable)), l = _(() => a.value.filter((S) => S.selectable)), i = _(() => {
if (typeof e.selectStrategy == "object") return e.selectStrategy;
switch (e.selectStrategy) {
case "single":
return Db;
case "all":
return pd;
case "page":
default:
return bd;
}
}), o = ne(null);
function u(S) {
return Ke(S).every((P) => r.value.has(P.value));
}
function c(S) {
return Ke(S).some((P) => r.value.has(P.value));
}
function d(S, P) {
const O = i.value.select({
items: S,
value: P,
selected: new Set(r.value)
});
r.value = O;
}
function f(S, P, O) {
const k = [];
if (P = P ?? a.value.findIndex((E) => E.value === S.value), e.selectStrategy !== "single" && O?.shiftKey && o.value !== null) {
const [E, V] = [o.value, P].sort((w, T) => w - T);
k.push(...a.value.slice(E, V + 1).filter((w) => w.selectable));
} else
k.push(S), o.value = P;
d(k, !u([S]));
}
function v(S) {
const P = i.value.selectAll({
value: S,
allItems: s.value,
currentPage: l.value,
selected: new Set(r.value)
});
r.value = P;
}
const m = _(() => r.value.size > 0), y = _(() => {
const S = i.value.allSelected({
allItems: s.value,
currentPage: l.value
});
return !!S.length && u(S);
}), h = I(() => i.value.showSelectAll), b = {
toggleSelect: f,
select: d,
selectAll: v,
isSelected: u,
isSomeSelected: c,
someSelected: m,
allSelected: y,
showSelectAll: h,
lastSelectedIndex: o,
selectStrategy: i
};
return We(Sd, b), b;
}
function rs() {
const e = De(Sd);
if (!e) throw new Error("Missing selection!");
return e;
}
const Fb = M({
sortBy: {
type: Array,
default: () => []
},
customKeySort: Object,
multiSort: Boolean,
mustSort: Boolean
}, "DataTable-sort"), wd = Symbol.for("vuetify:data-table-sort");
function Lb(e) {
const t = _e(e, "sortBy"), n = I(() => e.mustSort), a = I(() => e.multiSort);
return {
sortBy: t,
mustSort: n,
multiSort: a
};
}
function Nb(e) {
const {
sortBy: t,
mustSort: n,
multiSort: a,
page: r
} = e, s = (o) => {
if (o.key == null) return;
let u = t.value.map((d) => ({
...d
})) ?? [];
const c = u.find((d) => d.key === o.key);
c ? c.order === "desc" ? n.value && u.length === 1 ? c.order = "asc" : u = u.filter((d) => d.key !== o.key) : c.order = "desc" : a.value ? u.push({
key: o.key,
order: "asc"
}) : u = [{
key: o.key,
order: "asc"
}], t.value = u, r && (r.value = 1);
};
function l(o) {
return !!t.value.find((u) => u.key === o.key);
}
const i = {
sortBy: t,
toggleSort: s,
isSorted: l
};
return We(wd, i), i;
}
function _d() {
const e = De(wd);
if (!e) throw new Error("Missing sort!");
return e;
}
function Bb(e, t, n, a) {
const r = hn();
return {
sortedItems: _(() => n.value.length ? $b(t.value, n.value, r.current.value, {
transform: a?.transform,
sortFunctions: {
...e.customKeySort,
...a?.sortFunctions?.value
},
sortRawFunctions: a?.sortRawFunctions?.value
}) : t.value)
};
}
function $b(e, t, n, a) {
const r = new Intl.Collator(n, {
sensitivity: "accent",
usage: "sort"
});
return e.map((l) => [l, a?.transform ? a.transform(l) : l]).sort((l, i) => {
for (let o = 0; o < t.length; o++) {
let u = !1;
const c = t[o].key, d = t[o].order ?? "asc";
if (d === !1) continue;
let f = xa(l[1], c), v = xa(i[1], c), m = l[0].raw, y = i[0].raw;
if (d === "desc" && ([f, v] = [v, f], [m, y] = [y, m]), a?.sortRawFunctions?.[c]) {
const h = a.sortRawFunctions[c](m, y);
if (h == null) continue;
if (u = !0, h) return h;
}
if (a?.sortFunctions?.[c]) {
const h = a.sortFunctions[c](f, v);
if (h == null) continue;
if (u = !0, h) return h;
}
if (!u) {
if (f instanceof Date && v instanceof Date)
return f.getTime() - v.getTime();
if ([f, v] = [f, v].map((h) => h != null ? h.toString().toLocaleLowerCase() : h), f !== v)
return ar(f) && ar(v) ? 0 : ar(f) ? -1 : ar(v) ? 1 : !isNaN(f) && !isNaN(v) ? Number(f) - Number(v) : r.compare(f, v);
}
}
return 0;
}).map((l) => {
let [i] = l;
return i;
});
}
const kd = M({
color: String,
disableSort: Boolean,
fixedHeader: Boolean,
multiSort: Boolean,
sortAscIcon: {
type: le,
default: "$sortAsc"
},
sortDescIcon: {
type: le,
default: "$sortDesc"
},
headerProps: {
type: Object
},
/** @deprecated */
sticky: Boolean,
...Jr(),
...es()
}, "VDataTableHeaders"), Uo = G()({
name: "VDataTableHeaders",
props: kd(),
setup(e, t) {
let {
slots: n
} = t;
const {
t: a
} = hn(), {
toggleSort: r,
sortBy: s,
isSorted: l
} = _d(), {
someSelected: i,
allSelected: o,
selectAll: u,
showSelectAll: c
} = rs(), {
columns: d,
headers: f
} = as(), {
loaderClasses: v
} = Qa(e);
function m(w, T) {
if (!(!(e.sticky || e.fixedHeader) && !w.fixed))
return {
position: "sticky",
left: w.fixed ? te(w.fixedOffset) : void 0,
top: e.sticky || e.fixedHeader ? `calc(var(--v-table-header-height) * ${T})` : void 0
};
}
function y(w) {
const T = s.value.find((L) => L.key === w.key);
return T ? T.order === "asc" ? e.sortAscIcon : e.sortDescIcon : e.sortAscIcon;
}
const {
backgroundColorClasses: h,
backgroundColorStyles: b
} = $t(() => e.color), {
displayClasses: S,
mobile: P
} = $n(e), O = _(() => ({
headers: f.value,
columns: d.value,
toggleSort: r,
isSorted: l,
sortBy: s.value,
someSelected: i.value,
allSelected: o.value,
selectAll: u,
getSortIcon: y
})), k = _(() => ["v-data-table__th", {
"v-data-table__th--sticky": e.sticky || e.fixedHeader
}, S.value, v.value]), E = (w) => {
let {
column: T,
x: L,
y: $
} = w;
const B = T.key === "data-table-select" || T.key === "data-table-expand", D = j(e.headerProps ?? {}, T.headerProps ?? {});
return g(Tr, j({
tag: "th",
align: T.align,
class: [{
"v-data-table__th--sortable": T.sortable && !e.disableSort,
"v-data-table__th--sorted": l(T),
"v-data-table__th--fixed": T.fixed
}, ...k.value],
style: {
width: te(T.width),
minWidth: te(T.minWidth),
maxWidth: te(T.maxWidth),
...m(T, $)
},
colspan: T.colspan,
rowspan: T.rowspan,
onClick: T.sortable ? () => r(T) : void 0,
fixed: T.fixed,
nowrap: T.nowrap,
lastFixed: T.lastFixed,
noPadding: B
}, D), {
default: () => {
const H = `header.${T.key}`, Y = {
column: T,
selectAll: u,
isSorted: l,
toggleSort: r,
sortBy: s.value,
someSelected: i.value,
allSelected: o.value,
getSortIcon: y
};
return n[H] ? n[H](Y) : T.key === "data-table-select" ? n["header.data-table-select"]?.(Y) ?? (c.value && g(Ga, {
modelValue: o.value,
indeterminate: i.value && !o.value,
"onUpdate:modelValue": u
}, null)) : p("div", {
class: "v-data-table-header__content"
}, [p("span", null, [T.title]), T.sortable && !e.disableSort && g(Ve, {
key: "icon",
class: "v-data-table-header__sort-icon",
icon: y(T)
}, null), e.multiSort && l(T) && p("div", {
key: "badge",
class: Q(["v-data-table-header__sort-badge", ...h.value]),
style: J(b.value)
}, [s.value.findIndex((X) => X.key === T.key) + 1])]);
}
});
}, V = () => {
const w = _(() => d.value.filter((L) => L?.sortable && !e.disableSort)), T = _(() => {
if (d.value.find(($) => $.key === "data-table-select") != null)
return o.value ? "$checkboxOn" : i.value ? "$checkboxIndeterminate" : "$checkboxOff";
});
return g(Tr, j({
tag: "th",
class: [...k.value],
colspan: f.value.length + 1
}, e.headerProps), {
default: () => [p("div", {
class: "v-data-table-header__content"
}, [g(zc, {
chips: !0,
class: "v-data-table__td-sort-select",
clearable: !0,
density: "default",
items: w.value,
label: a("$vuetify.dataTable.sortBy"),
multiple: e.multiSort,
variant: "underlined",
"onClick:clear": () => s.value = [],
appendIcon: T.value,
"onClick:append": () => u(!o.value)
}, {
...n,
chip: (L) => g(Ql, {
onClick: L.item.raw?.sortable ? () => r(L.item.raw) : void 0,
onMousedown: ($) => {
$.preventDefault(), $.stopPropagation();
}
}, {
default: () => [L.item.title, g(Ve, {
class: Q(["v-data-table__td-sort-icon", l(L.item.raw) && "v-data-table__td-sort-icon-active"]),
icon: y(L.item.raw),
size: "small"
}, null)]
})
})])]
});
};
ee(() => P.value ? p("tr", null, [g(V, null, null)]) : p(pe, null, [n.headers ? n.headers(O.value) : f.value.map((w, T) => p("tr", null, [w.map((L, $) => g(E, {
column: L,
x: $,
y: T
}, null))])), e.loading && p("tr", {
class: "v-data-table-progress"
}, [p("th", {
colspan: d.value.length
}, [g(ts, {
name: "v-data-table-progress",
absolute: !0,
active: !0,
color: typeof e.loading == "boolean" ? void 0 : e.loading,
indeterminate: !0
}, {
default: n.loader
})])])]));
}
}), Ub = M({
groupBy: {
type: Array,
default: () => []
}
}, "DataTable-group"), Cd = Symbol.for("vuetify:data-table-group");
function zb(e) {
return {
groupBy: _e(e, "groupBy")
};
}
function Hb(e) {
const {
disableSort: t,
groupBy: n,
sortBy: a
} = e, r = R(/* @__PURE__ */ new Set()), s = _(() => n.value.map((c) => ({
...c,
order: c.order ?? !1
})).concat(t?.value ? [] : a.value));
function l(c) {
return r.value.has(c.id);
}
function i(c) {
const d = new Set(r.value);
l(c) ? d.delete(c.id) : d.add(c.id), r.value = d;
}
function o(c) {
function d(f) {
const v = [];
for (const m of f.items)
"type" in m && m.type === "group" ? v.push(...d(m)) : v.push(m);
return [...new Set(v)];
}
return d({
items: c
});
}
const u = {
sortByWithGroups: s,
toggleGroup: i,
opened: r,
groupBy: n,
extractRows: o,
isGroupOpen: l
};
return We(Cd, u), u;
}
function Pd() {
const e = De(Cd);
if (!e) throw new Error("Missing group!");
return e;
}
function Yb(e, t) {
if (!e.length) return [];
const n = /* @__PURE__ */ new Map();
for (const a of e) {
const r = xa(a.raw, t);
n.has(r) || n.set(r, []), n.get(r).push(a);
}
return n;
}
function xd(e, t) {
let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : 0, a = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : "root";
if (!t.length) return [];
const r = Yb(e, t[0]), s = [], l = t.slice(1);
return r.forEach((i, o) => {
const u = t[0], c = `${a}_${u}_${o}`;
s.push({
depth: n,
id: c,
key: u,
value: o,
items: l.length ? xd(i, l, n + 1, c) : i,
type: "group"
});
}), s;
}
function Id(e, t) {
const n = [];
for (const a of e)
"type" in a && a.type === "group" ? (a.value != null && n.push(a), (t.has(a.id) || a.value == null) && n.push(...Id(a.items, t))) : n.push(a);
return n;
}
function jb(e, t, n) {
return {
flatItems: _(() => {
if (!t.value.length) return e.value;
const r = xd(e.value, t.value.map((s) => s.key));
return Id(r, n.value);
})
};
}
const Wb = M({
item: {
type: Object,
required: !0
}
}, "VDataTableGroupHeaderRow"), Gb = G()({
name: "VDataTableGroupHeaderRow",
props: Wb(),
setup(e, t) {
let {
slots: n
} = t;
const {
isGroupOpen: a,
toggleGroup: r,
extractRows: s
} = Pd(), {
isSelected: l,
isSomeSelected: i,
select: o
} = rs(), {
columns: u
} = as(), c = _(() => s([e.item]));
return () => p("tr", {
class: "v-data-table-group-header-row",
style: J({
"--v-data-table-group-header-row-depth": e.item.depth
})
}, [u.value.map((d) => {
if (d.key === "data-table-group") {
const f = a(e.item) ? "$expand" : "$next", v = () => r(e.item);
return n["data-table-group"]?.({
item: e.item,
count: c.value.length,
props: {
icon: f,
onClick: v
}
}) ?? g(Tr, {
class: "v-data-table-group-header-row__column"
}, {
default: () => [g(Zt, {
size: "small",
variant: "text",
icon: f,
onClick: v
}, null), p("span", null, [e.item.value]), p("span", null, [Fe("("), c.value.length, Fe(")")])]
});
}
if (d.key === "data-table-select") {
const f = l(c.value), v = i(c.value) && !f, m = (y) => o(c.value, y);
return n["data-table-select"]?.({
props: {
modelValue: f,
indeterminate: v,
"onUpdate:modelValue": m
}
}) ?? p("td", null, [g(Ga, {
modelValue: f,
indeterminate: v,
"onUpdate:modelValue": m
}, null)]);
}
return p("td", null, null);
})]);
}
}), Qb = M({
expandOnClick: Boolean,
showExpand: Boolean,
expanded: {
type: Array,
default: () => []
}
}, "DataTable-expand"), Od = Symbol.for("vuetify:datatable:expanded");
function qb(e) {
const t = I(() => e.expandOnClick), n = _e(e, "expanded", e.expanded, (i) => new Set(i), (i) => [...i.values()]);
function a(i, o) {
const u = new Set(n.value);
o ? u.add(i.value) : u.delete(i.value), n.value = u;
}
function r(i) {
return n.value.has(i.value);
}
function s(i) {
a(i, !r(i));
}
const l = {
expand: a,
expanded: n,
expandOnClick: t,
isExpanded: r,
toggleExpand: s
};
return We(Od, l), l;
}
function Td() {
const e = De(Od);
if (!e) throw new Error("foo");
return e;
}
const Kb = M({
index: Number,
item: Object,
cellProps: [Object, Function],
onClick: Je(),
onContextmenu: Je(),
onDblclick: Je(),
...Jr()
}, "VDataTableRow"), Jb = G()({
name: "VDataTableRow",
props: Kb(),
setup(e, t) {
let {
slots: n
} = t;
const {
displayClasses: a,
mobile: r
} = $n(e, "v-data-table__tr"), {
isSelected: s,
toggleSelect: l,
someSelected: i,
allSelected: o,
selectAll: u
} = rs(), {
isExpanded: c,
toggleExpand: d
} = Td(), {
toggleSort: f,
sortBy: v,
isSorted: m
} = _d(), {
columns: y
} = as();
ee(() => p("tr", {
class: Q(["v-data-table__tr", {
"v-data-table__tr--clickable": !!(e.onClick || e.onContextmenu || e.onDblclick)
}, a.value]),
onClick: e.onClick,
onContextmenu: e.onContextmenu,
onDblclick: e.onDblclick
}, [e.item && y.value.map((h, b) => {
const S = e.item, P = `item.${h.key}`, O = `header.${h.key}`, k = {
index: e.index,
item: S.raw,
internalItem: S,
value: xa(S.columns, h.key),
column: h,
isSelected: s,
toggleSelect: l,
isExpanded: c,
toggleExpand: d
}, E = {
column: h,
selectAll: u,
isSorted: m,
toggleSort: f,
sortBy: v.value,
someSelected: i.value,
allSelected: o.value,
getSortIcon: () => ""
}, V = typeof e.cellProps == "function" ? e.cellProps({
index: k.index,
item: k.item,
internalItem: k.internalItem,
value: k.value,
column: h
}) : e.cellProps, w = typeof h.cellProps == "function" ? h.cellProps({
index: k.index,
item: k.item,
internalItem: k.internalItem,
value: k.value
}) : h.cellProps;
return g(Tr, j({
align: h.align,
class: {
"v-data-table__td--expanded-row": h.key === "data-table-expand",
"v-data-table__td--select-row": h.key === "data-table-select"
},
fixed: h.fixed,
fixedOffset: h.fixedOffset,
lastFixed: h.lastFixed,
maxWidth: r.value ? void 0 : h.maxWidth,
noPadding: h.key === "data-table-select" || h.key === "data-table-expand",
nowrap: h.nowrap,
width: r.value ? void 0 : h.width
}, V, w), {
default: () => {
if (h.key === "data-table-select")
return n["item.data-table-select"]?.({
...k,
props: {
disabled: !S.selectable,
modelValue: s([S]),
onClick: tr(() => l(S), ["stop"])
}
}) ?? g(Ga, {
disabled: !S.selectable,
modelValue: s([S]),
onClick: tr((L) => l(S, e.index, L), ["stop"])
}, null);
if (h.key === "data-table-expand")
return n["item.data-table-expand"]?.({
...k,
props: {
icon: c(S) ? "$collapse" : "$expand",
size: "small",
variant: "text",
onClick: tr(() => d(S), ["stop"])
}
}) ?? g(Zt, {
icon: c(S) ? "$collapse" : "$expand",
size: "small",
variant: "text",
onClick: tr(() => d(S), ["stop"])
}, null);
if (n[P] && !r.value) return n[P](k);
const T = Te(k.value);
return r.value ? p(pe, null, [p("div", {
class: "v-data-table__td-title"
}, [n[O]?.(E) ?? h.title]), p("div", {
class: "v-data-table__td-value"
}, [n[P]?.(k) ?? T])]) : T;
}
});
})]));
}
}), Vd = M({
loading: [Boolean, String],
loadingText: {
type: String,
default: "$vuetify.dataIterator.loadingText"
},
hideNoData: Boolean,
items: {
type: Array,
default: () => []
},
noDataText: {
type: String,
default: "$vuetify.noDataText"
},
rowProps: [Object, Function],
cellProps: [Object, Function],
...Jr()
}, "VDataTableRows"), zo = G()({
name: "VDataTableRows",
inheritAttrs: !1,
props: Vd(),
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
columns: r
} = as(), {
expandOnClick: s,
toggleExpand: l,
isExpanded: i
} = Td(), {
isSelected: o,
toggleSelect: u
} = rs(), {
toggleGroup: c,
isGroupOpen: d
} = Pd(), {
t: f
} = hn(), {
mobile: v
} = $n(e);
return ee(() => e.loading && (!e.items.length || a.loading) ? p("tr", {
class: "v-data-table-rows-loading",
key: "loading"
}, [p("td", {
colspan: r.value.length
}, [a.loading?.() ?? f(e.loadingText)])]) : !e.loading && !e.items.length && !e.hideNoData ? p("tr", {
class: "v-data-table-rows-no-data",
key: "no-data"
}, [p("td", {
colspan: r.value.length
}, [a["no-data"]?.() ?? f(e.noDataText)])]) : p(pe, null, [e.items.map((m, y) => {
if (m.type === "group") {
const S = {
index: y,
item: m,
columns: r.value,
isExpanded: i,
toggleExpand: l,
isSelected: o,
toggleSelect: u,
toggleGroup: c,
isGroupOpen: d
};
return a["group-header"] ? a["group-header"](S) : g(Gb, j({
key: `group-header_${m.id}`,
item: m
}, oo(n, ":group-header", () => S)), a);
}
const h = {
index: y,
item: m.raw,
internalItem: m,
columns: r.value,
isExpanded: i,
toggleExpand: l,
isSelected: o,
toggleSelect: u
}, b = {
...h,
props: j({
key: `item_${m.key ?? m.index}`,
onClick: s.value ? () => {
l(m);
} : void 0,
index: y,
item: m,
cellProps: e.cellProps,
mobile: v.value
}, oo(n, ":row", () => h), typeof e.rowProps == "function" ? e.rowProps({
item: h.item,
index: h.index,
internalItem: h.internalItem
}) : e.rowProps)
};
return p(pe, {
key: b.props.key
}, [a.item ? a.item(b) : g(Jb, b.props, a), i(m) && a["expanded-row"]?.(h)]);
})])), {};
}
}), Ad = M({
fixedHeader: Boolean,
fixedFooter: Boolean,
height: [Number, String],
hover: Boolean,
...ce(),
...Ct(),
...Le(),
...Ye()
}, "VTable"), Ho = G()({
name: "VTable",
props: Ad(),
setup(e, t) {
let {
slots: n,
emit: a
} = t;
const {
themeClasses: r
} = Ze(e), {
densityClasses: s
} = Wt(e);
return ee(() => g(e.tag, {
class: Q(["v-table", {
"v-table--fixed-height": !!e.height,
"v-table--fixed-header": e.fixedHeader,
"v-table--fixed-footer": e.fixedFooter,
"v-table--has-top": !!n.top,
"v-table--has-bottom": !!n.bottom,
"v-table--hover": e.hover
}, r.value, s.value, e.class]),
style: J(e.style)
}, {
default: () => [n.top?.(), n.default ? p("div", {
class: "v-table__wrapper",
style: J({
height: te(e.height)
})
}, [p("table", null, [n.default()])]) : n.wrapper?.(), n.bottom?.()]
})), {};
}
}), Zb = M({
items: {
type: Array,
default: () => []
},
itemValue: {
type: [String, Array, Function],
default: "id"
},
itemSelectable: {
type: [String, Array, Function],
default: null
},
rowProps: [Object, Function],
cellProps: [Object, Function],
returnObject: Boolean
}, "DataTable-items");
function Xb(e, t, n, a) {
const r = e.returnObject ? t : ot(t, e.itemValue), s = ot(t, e.itemSelectable, !0), l = a.reduce((i, o) => (o.key != null && (i[o.key] = ot(t, o.value)), i), {});
return {
type: "item",
key: e.returnObject ? ot(t, e.itemValue) : r,
index: n,
value: r,
selectable: s,
columns: l,
raw: t
};
}
function ep(e, t, n) {
return t.map((a, r) => Xb(e, a, r, n));
}
function tp(e, t) {
return {
items: _(() => ep(e, e.items, t.value))
};
}
function np(e) {
let {
page: t,
itemsPerPage: n,
sortBy: a,
groupBy: r,
search: s
} = e;
const l = Ue("VDataTable"), i = () => ({
page: t.value,
itemsPerPage: n.value,
sortBy: a.value,
groupBy: r.value,
search: s.value
});
let o = null;
re(i, (u) => {
gt(o, u) || (o && o.search !== u.search && (t.value = 1), l.emit("update:options", u), o = u);
}, {
deep: !0,
immediate: !0
});
}
const ap = M({
...Vd(),
hideDefaultBody: Boolean,
hideDefaultFooter: Boolean,
hideDefaultHeader: Boolean,
width: [String, Number],
search: String,
...Qb(),
...Ub(),
...xb(),
...Zb(),
...Mb(),
...Fb(),
...kd(),
...Ad()
}, "DataTable"), rp = M({
...wb(),
...ap(),
...Hc(),
...hd()
}, "VDataTable"), Ed = G()({
name: "VDataTable",
props: rp(),
emits: {
"update:modelValue": (e) => !0,
"update:page": (e) => !0,
"update:itemsPerPage": (e) => !0,
"update:sortBy": (e) => !0,
"update:options": (e) => !0,
"update:groupBy": (e) => !0,
"update:expanded": (e) => !0,
"update:currentItems": (e) => !0
},
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
groupBy: r
} = zb(e), {
sortBy: s,
multiSort: l,
mustSort: i
} = Lb(e), {
page: o,
itemsPerPage: u
} = _b(e), {
disableSort: c
} = Jo(e), {
columns: d,
headers: f,
sortFunctions: v,
sortRawFunctions: m,
filterFunctions: y
} = Eb(e, {
groupBy: r,
showSelect: I(() => e.showSelect),
showExpand: I(() => e.showExpand)
}), {
items: h
} = tp(e, d), b = I(() => e.search), {
filteredItems: S
} = Yc(e, h, b, {
transform: (K) => K.columns,
customKeyFilter: y
}), {
toggleSort: P
} = Nb({
sortBy: s,
multiSort: l,
mustSort: i,
page: o
}), {
sortByWithGroups: O,
opened: k,
extractRows: E,
isGroupOpen: V,
toggleGroup: w
} = Hb({
groupBy: r,
sortBy: s,
disableSort: c
}), {
sortedItems: T
} = Bb(e, S, O, {
transform: (K) => ({
...K.raw,
...K.columns
}),
sortFunctions: v,
sortRawFunctions: m
}), {
flatItems: L
} = jb(T, r, k), $ = _(() => L.value.length), {
startIndex: B,
stopIndex: D,
pageCount: H,
setItemsPerPage: Y
} = kb({
page: o,
itemsPerPage: u,
itemsLength: $
}), {
paginatedItems: X
} = Pb({
items: L,
startIndex: B,
stopIndex: D,
itemsPerPage: u
}), oe = _(() => E(X.value)), {
isSelected: ge,
select: Ie,
selectAll: x,
toggleSelect: A,
someSelected: N,
allSelected: q
} = Rb(e, {
allItems: h,
currentPage: oe
}), {
isExpanded: ie,
toggleExpand: ae
} = qb(e);
np({
page: o,
itemsPerPage: u,
sortBy: s,
groupBy: r,
search: b
}), zt({
VDataTableRows: {
hideNoData: I(() => e.hideNoData),
noDataText: I(() => e.noDataText),
loading: I(() => e.loading),
loadingText: I(() => e.loadingText)
}
});
const se = _(() => ({
page: o.value,
itemsPerPage: u.value,
sortBy: s.value,
pageCount: H.value,
toggleSort: P,
setItemsPerPage: Y,
someSelected: N.value,
allSelected: q.value,
isSelected: ge,
select: Ie,
selectAll: x,
toggleSelect: A,
isExpanded: ie,
toggleExpand: ae,
isGroupOpen: V,
toggleGroup: w,
items: oe.value.map((K) => K.raw),
internalItems: oe.value,
groupedItems: X.value,
columns: d.value,
headers: f.value
}));
return ee(() => {
const K = $o.filterProps(e), Ae = Uo.filterProps(e), Se = zo.filterProps(e), U = Ho.filterProps(e);
return g(Ho, j({
class: ["v-data-table", {
"v-data-table--show-select": e.showSelect,
"v-data-table--loading": e.loading
}, e.class],
style: e.style
}, U, {
fixedHeader: e.fixedHeader || e.sticky
}), {
top: () => a.top?.(se.value),
default: () => a.default ? a.default(se.value) : p(pe, null, [a.colgroup?.(se.value), !e.hideDefaultHeader && p("thead", {
key: "thead"
}, [g(Uo, Ae, a)]), a.thead?.(se.value), !e.hideDefaultBody && p("tbody", null, [a["body.prepend"]?.(se.value), a.body ? a.body(se.value) : g(zo, j(n, Se, {
items: X.value
}), a), a["body.append"]?.(se.value)]), a.tbody?.(se.value), a.tfoot?.(se.value)]),
bottom: () => a.bottom ? a.bottom(se.value) : !e.hideDefaultFooter && p(pe, null, [g(kc, null, null), g($o, K, {
prepend: a["footer.prepend"]
})])
});
}), {};
}
}), sp = {
key: 0,
id: "loading-results"
}, lp = { id: "results" }, ip = ["href"], op = { class: "literature-item-date" };
function up(e, t, n, a, r, s) {
return qe(), nt(pe, null, [
e.display_loading_div ? (qe(), nt("div", sp, [
g(ti, { indeterminate: "" })
])) : ct("", !0),
ht(p("div", lp, [
e.display_results_div ? (qe(), Zo(Ed, {
key: 0,
id: "table-literature",
headers: e.headers,
items: e.dataSource,
"items-per-page": e.pageSize,
"item-key": "PMID",
"footer-props": e.footerProps,
"onUpdate:options": t[0] || (t[0] = (l) => e.handlePage(l))
}, {
"item.PMID": fe(({ item: l }) => [
p("a", {
href: l.urlPMID,
target: "_blank"
}, Te(l.PMID), 9, ip)
]),
"item.Date": fe(({ item: l }) => [
p("span", op, Te(l.Date?.substring(0, 10)), 1)
]),
_: 1
}, 8, ["headers", "items", "items-per-page", "footer-props"])) : ct("", !0),
p("small", null, " search type: " + Te(e.literatureSearchType) + "; search id: " + Te(e.literatureSearchId) + "; item id: " + Te(e.literatureItemId) + ". ", 1)
], 512), [
[Bn, !e.display_loading_div]
])
], 64);
}
const Dd = /* @__PURE__ */ Tl(mb, [["render", up]]);
class cp {
// Weakness of compound/concept (Nullable)
constructor(t, n, a, r, s, l, i, o, u) {
xe(this, "id");
// ID of compound/concept
xe(this, "name");
// Name of compound/concept
xe(this, "link");
// Link to official page
xe(this, "root");
// Tree root of a MeSH element
xe(this, "meshTree");
// MeSH Tree-Numbers
xe(this, "qvalue");
// q.value of compound/concept
xe(this, "oddratio");
// odd ratio of compound/concept
xe(this, "papers");
// Number of article common between MeSH and Pubchem/Chemont/Chebi of compound/concept
xe(this, "score");
this._id = t, this._name = n, this._link = a, this._root = r, this._meshTree = s, this._qvalue = l, this._oddratio = i, this._papers = o, this._score = u, this.id = t, this.name = n, this.link = a, this.root = r, this.meshTree = s, this.qvalue = l, this.oddratio = i, this.papers = o, this.score = u;
}
}
//! moment.js
//! version : 2.30.1
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
//! license : MIT
//! momentjs.com
var Md;
function z() {
return Md.apply(null, arguments);
}
function dp(e) {
Md = e;
}
function Tt(e) {
return e instanceof Array || Object.prototype.toString.call(e) === "[object Array]";
}
function Dn(e) {
return e != null && Object.prototype.toString.call(e) === "[object Object]";
}
function ke(e, t) {
return Object.prototype.hasOwnProperty.call(e, t);
}
function ii(e) {
if (Object.getOwnPropertyNames)
return Object.getOwnPropertyNames(e).length === 0;
var t;
for (t in e)
if (ke(e, t))
return !1;
return !0;
}
function ut(e) {
return e === void 0;
}
function ln(e) {
return typeof e == "number" || Object.prototype.toString.call(e) === "[object Number]";
}
function Ka(e) {
return e instanceof Date || Object.prototype.toString.call(e) === "[object Date]";
}
function Rd(e, t) {
var n = [], a, r = e.length;
for (a = 0; a < r; ++a)
n.push(t(e[a], a));
return n;
}
function bn(e, t) {
for (var n in t)
ke(t, n) && (e[n] = t[n]);
return ke(t, "toString") && (e.toString = t.toString), ke(t, "valueOf") && (e.valueOf = t.valueOf), e;
}
function Gt(e, t, n, a) {
return rf(e, t, n, a, !0).utc();
}
function fp() {
return {
empty: !1,
unusedTokens: [],
unusedInput: [],
overflow: -2,
charsLeftOver: 0,
nullInput: !1,
invalidEra: null,
invalidMonth: null,
invalidFormat: !1,
userInvalidated: !1,
iso: !1,
parsedDateParts: [],
era: null,
meridiem: null,
rfc2822: !1,
weekdayMismatch: !1
};
}
function de(e) {
return e._pf == null && (e._pf = fp()), e._pf;
}
var vl;
Array.prototype.some ? vl = Array.prototype.some : vl = function(e) {
var t = Object(this), n = t.length >>> 0, a;
for (a = 0; a < n; a++)
if (a in t && e.call(this, t[a], a, t))
return !0;
return !1;
};
function oi(e) {
var t = null, n = !1, a = e._d && !isNaN(e._d.getTime());
if (a && (t = de(e), n = vl.call(t.parsedDateParts, function(r) {
return r != null;
}), a = t.overflow < 0 && !t.empty && !t.invalidEra && !t.invalidMonth && !t.invalidWeekday && !t.weekdayMismatch && !t.nullInput && !t.invalidFormat && !t.userInvalidated && (!t.meridiem || t.meridiem && n), e._strict && (a = a && t.charsLeftOver === 0 && t.unusedTokens.length === 0 && t.bigHour === void 0)), Object.isFrozen == null || !Object.isFrozen(e))
e._isValid = a;
else
return a;
return e._isValid;
}
function ss(e) {
var t = Gt(NaN);
return e != null ? bn(de(t), e) : de(t).userInvalidated = !0, t;
}
var Yo = z.momentProperties = [], Fs = !1;
function ui(e, t) {
var n, a, r, s = Yo.length;
if (ut(t._isAMomentObject) || (e._isAMomentObject = t._isAMomentObject), ut(t._i) || (e._i = t._i), ut(t._f) || (e._f = t._f), ut(t._l) || (e._l = t._l), ut(t._strict) || (e._strict = t._strict), ut(t._tzm) || (e._tzm = t._tzm), ut(t._isUTC) || (e._isUTC = t._isUTC), ut(t._offset) || (e._offset = t._offset), ut(t._pf) || (e._pf = de(t)), ut(t._locale) || (e._locale = t._locale), s > 0)
for (n = 0; n < s; n++)
a = Yo[n], r = t[a], ut(r) || (e[a] = r);
return e;
}
function Ja(e) {
ui(this, e), this._d = new Date(e._d != null ? e._d.getTime() : NaN), this.isValid() || (this._d = /* @__PURE__ */ new Date(NaN)), Fs === !1 && (Fs = !0, z.updateOffset(this), Fs = !1);
}
function Vt(e) {
return e instanceof Ja || e != null && e._isAMomentObject != null;
}
function Fd(e) {
z.suppressDeprecationWarnings === !1 && typeof console < "u" && console.warn && console.warn("Deprecation warning: " + e);
}
function Pt(e, t) {
var n = !0;
return bn(function() {
if (z.deprecationHandler != null && z.deprecationHandler(null, e), n) {
var a = [], r, s, l, i = arguments.length;
for (s = 0; s < i; s++) {
if (r = "", typeof arguments[s] == "object") {
r += `
[` + s + "] ";
for (l in arguments[0])
ke(arguments[0], l) && (r += l + ": " + arguments[0][l] + ", ");
r = r.slice(0, -2);
} else
r = arguments[s];
a.push(r);
}
Fd(
e + `
Arguments: ` + Array.prototype.slice.call(a).join("") + `
` + new Error().stack
), n = !1;
}
return t.apply(this, arguments);
}, t);
}
var jo = {};
function Ld(e, t) {
z.deprecationHandler != null && z.deprecationHandler(e, t), jo[e] || (Fd(t), jo[e] = !0);
}
z.suppressDeprecationWarnings = !1;
z.deprecationHandler = null;
function Qt(e) {
return typeof Function < "u" && e instanceof Function || Object.prototype.toString.call(e) === "[object Function]";
}
function hp(e) {
var t, n;
for (n in e)
ke(e, n) && (t = e[n], Qt(t) ? this[n] = t : this["_" + n] = t);
this._config = e, this._dayOfMonthOrdinalParseLenient = new RegExp(
(this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) + "|" + /\d{1,2}/.source
);
}
function yl(e, t) {
var n = bn({}, e), a;
for (a in t)
ke(t, a) && (Dn(e[a]) && Dn(t[a]) ? (n[a] = {}, bn(n[a], e[a]), bn(n[a], t[a])) : t[a] != null ? n[a] = t[a] : delete n[a]);
for (a in e)
ke(e, a) && !ke(t, a) && Dn(e[a]) && (n[a] = bn({}, n[a]));
return n;
}
function ci(e) {
e != null && this.set(e);
}
var gl;
Object.keys ? gl = Object.keys : gl = function(e) {
var t, n = [];
for (t in e)
ke(e, t) && n.push(t);
return n;
};
var mp = {
sameDay: "[Today at] LT",
nextDay: "[Tomorrow at] LT",
nextWeek: "dddd [at] LT",
lastDay: "[Yesterday at] LT",
lastWeek: "[Last] dddd [at] LT",
sameElse: "L"
};
function vp(e, t, n) {
var a = this._calendar[e] || this._calendar.sameElse;
return Qt(a) ? a.call(t, n) : a;
}
function Yt(e, t, n) {
var a = "" + Math.abs(e), r = t - a.length, s = e >= 0;
return (s ? n ? "+" : "" : "-") + Math.pow(10, Math.max(0, r)).toString().substr(1) + a;
}
var di = /(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g, or = /(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g, Ls = {}, qn = {};
function Z(e, t, n, a) {
var r = a;
typeof a == "string" && (r = function() {
return this[a]();
}), e && (qn[e] = r), t && (qn[t[0]] = function() {
return Yt(r.apply(this, arguments), t[1], t[2]);
}), n && (qn[n] = function() {
return this.localeData().ordinal(
r.apply(this, arguments),
e
);
});
}
function yp(e) {
return e.match(/\[[\s\S]/) ? e.replace(/^\[|\]$/g, "") : e.replace(/\\/g, "");
}
function gp(e) {
var t = e.match(di), n, a;
for (n = 0, a = t.length; n < a; n++)
qn[t[n]] ? t[n] = qn[t[n]] : t[n] = yp(t[n]);
return function(r) {
var s = "", l;
for (l = 0; l < a; l++)
s += Qt(t[l]) ? t[l].call(r, e) : t[l];
return s;
};
}
function vr(e, t) {
return e.isValid() ? (t = Nd(t, e.localeData()), Ls[t] = Ls[t] || gp(t), Ls[t](e)) : e.localeData().invalidDate();
}
function Nd(e, t) {
var n = 5;
function a(r) {
return t.longDateFormat(r) || r;
}
for (or.lastIndex = 0; n >= 0 && or.test(e); )
e = e.replace(
or,
a
), or.lastIndex = 0, n -= 1;
return e;
}
var bp = {
LTS: "h:mm:ss A",
LT: "h:mm A",
L: "MM/DD/YYYY",
LL: "MMMM D, YYYY",
LLL: "MMMM D, YYYY h:mm A",
LLLL: "dddd, MMMM D, YYYY h:mm A"
};
function pp(e) {
var t = this._longDateFormat[e], n = this._longDateFormat[e.toUpperCase()];
return t || !n ? t : (this._longDateFormat[e] = n.match(di).map(function(a) {
return a === "MMMM" || a === "MM" || a === "DD" || a === "dddd" ? a.slice(1) : a;
}).join(""), this._longDateFormat[e]);
}
var Sp = "Invalid date";
function wp() {
return this._invalidDate;
}
var _p = "%d", kp = /\d{1,2}/;
function Cp(e) {
return this._ordinal.replace("%d", e);
}
var Pp = {
future: "in %s",
past: "%s ago",
s: "a few seconds",
ss: "%d seconds",
m: "a minute",
mm: "%d minutes",
h: "an hour",
hh: "%d hours",
d: "a day",
dd: "%d days",
w: "a week",
ww: "%d weeks",
M: "a month",
MM: "%d months",
y: "a year",
yy: "%d years"
};
function xp(e, t, n, a) {
var r = this._relativeTime[n];
return Qt(r) ? r(e, t, n, a) : r.replace(/%d/i, e);
}
function Ip(e, t) {
var n = this._relativeTime[e > 0 ? "future" : "past"];
return Qt(n) ? n(t) : n.replace(/%s/i, t);
}
var Wo = {
D: "date",
dates: "date",
date: "date",
d: "day",
days: "day",
day: "day",
e: "weekday",
weekdays: "weekday",
weekday: "weekday",
E: "isoWeekday",
isoweekdays: "isoWeekday",
isoweekday: "isoWeekday",
DDD: "dayOfYear",
dayofyears: "dayOfYear",
dayofyear: "dayOfYear",
h: "hour",
hours: "hour",
hour: "hour",
ms: "millisecond",
milliseconds: "millisecond",
millisecond: "millisecond",
m: "minute",
minutes: "minute",
minute: "minute",
M: "month",
months: "month",
month: "month",
Q: "quarter",
quarters: "quarter",
quarter: "quarter",
s: "second",
seconds: "second",
second: "second",
gg: "weekYear",
weekyears: "weekYear",
weekyear: "weekYear",
GG: "isoWeekYear",
isoweekyears: "isoWeekYear",
isoweekyear: "isoWeekYear",
w: "week",
weeks: "week",
week: "week",
W: "isoWeek",
isoweeks: "isoWeek",
isoweek: "isoWeek",
y: "year",
years: "year",
year: "year"
};
function xt(e) {
return typeof e == "string" ? Wo[e] || Wo[e.toLowerCase()] : void 0;
}
function fi(e) {
var t = {}, n, a;
for (a in e)
ke(e, a) && (n = xt(a), n && (t[n] = e[a]));
return t;
}
var Op = {
date: 9,
day: 11,
weekday: 11,
isoWeekday: 11,
dayOfYear: 4,
hour: 13,
millisecond: 16,
minute: 14,
month: 8,
quarter: 7,
second: 15,
weekYear: 1,
isoWeekYear: 1,
week: 5,
isoWeek: 5,
year: 1
};
function Tp(e) {
var t = [], n;
for (n in e)
ke(e, n) && t.push({ unit: n, priority: Op[n] });
return t.sort(function(a, r) {
return a.priority - r.priority;
}), t;
}
var Bd = /\d/, St = /\d\d/, $d = /\d{3}/, hi = /\d{4}/, ls = /[+-]?\d{6}/, Me = /\d\d?/, Ud = /\d\d\d\d?/, zd = /\d\d\d\d\d\d?/, is = /\d{1,3}/, mi = /\d{1,4}/, os = /[+-]?\d{1,6}/, ua = /\d+/, us = /[+-]?\d+/, Vp = /Z|[+-]\d\d:?\d\d/gi, cs = /Z|[+-]\d\d(?::?\d\d)?/gi, Ap = /[+-]?\d+(\.\d{1,3})?/, Za = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i, ca = /^[1-9]\d?/, vi = /^([1-9]\d|\d)/, Vr;
Vr = {};
function W(e, t, n) {
Vr[e] = Qt(t) ? t : function(a, r) {
return a && n ? n : t;
};
}
function Ep(e, t) {
return ke(Vr, e) ? Vr[e](t._strict, t._locale) : new RegExp(Dp(e));
}
function Dp(e) {
return nn(
e.replace("\\", "").replace(
/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,
function(t, n, a, r, s) {
return n || a || r || s;
}
)
);
}
function nn(e) {
return e.replace(/[-\/\\^$*+?.()|[\]{}]/g, "\\$&");
}
function wt(e) {
return e < 0 ? Math.ceil(e) || 0 : Math.floor(e);
}
function ye(e) {
var t = +e, n = 0;
return t !== 0 && isFinite(t) && (n = wt(t)), n;
}
var bl = {};
function Oe(e, t) {
var n, a = t, r;
for (typeof e == "string" && (e = [e]), ln(t) && (a = function(s, l) {
l[t] = ye(s);
}), r = e.length, n = 0; n < r; n++)
bl[e[n]] = a;
}
function Xa(e, t) {
Oe(e, function(n, a, r, s) {
r._w = r._w || {}, t(n, r._w, r, s);
});
}
function Mp(e, t, n) {
t != null && ke(bl, e) && bl[e](t, n._a, n, e);
}
function ds(e) {
return e % 4 === 0 && e % 100 !== 0 || e % 400 === 0;
}
var tt = 0, en = 1, Nt = 2, je = 3, It = 4, tn = 5, Vn = 6, Rp = 7, Fp = 8;
Z("Y", 0, 0, function() {
var e = this.year();
return e <= 9999 ? Yt(e, 4) : "+" + e;
});
Z(0, ["YY", 2], 0, function() {
return this.year() % 100;
});
Z(0, ["YYYY", 4], 0, "year");
Z(0, ["YYYYY", 5], 0, "year");
Z(0, ["YYYYYY", 6, !0], 0, "year");
W("Y", us);
W("YY", Me, St);
W("YYYY", mi, hi);
W("YYYYY", os, ls);
W("YYYYYY", os, ls);
Oe(["YYYYY", "YYYYYY"], tt);
Oe("YYYY", function(e, t) {
t[tt] = e.length === 2 ? z.parseTwoDigitYear(e) : ye(e);
});
Oe("YY", function(e, t) {
t[tt] = z.parseTwoDigitYear(e);
});
Oe("Y", function(e, t) {
t[tt] = parseInt(e, 10);
});
function Ca(e) {
return ds(e) ? 366 : 365;
}
z.parseTwoDigitYear = function(e) {
return ye(e) + (ye(e) > 68 ? 1900 : 2e3);
};
var Hd = da("FullYear", !0);
function Lp() {
return ds(this.year());
}
function da(e, t) {
return function(n) {
return n != null ? (Yd(this, e, n), z.updateOffset(this, t), this) : Ra(this, e);
};
}
function Ra(e, t) {
if (!e.isValid())
return NaN;
var n = e._d, a = e._isUTC;
switch (t) {
case "Milliseconds":
return a ? n.getUTCMilliseconds() : n.getMilliseconds();
case "Seconds":
return a ? n.getUTCSeconds() : n.getSeconds();
case "Minutes":
return a ? n.getUTCMinutes() : n.getMinutes();
case "Hours":
return a ? n.getUTCHours() : n.getHours();
case "Date":
return a ? n.getUTCDate() : n.getDate();
case "Day":
return a ? n.getUTCDay() : n.getDay();
case "Month":
return a ? n.getUTCMonth() : n.getMonth();
case "FullYear":
return a ? n.getUTCFullYear() : n.getFullYear();
default:
return NaN;
}
}
function Yd(e, t, n) {
var a, r, s, l, i;
if (!(!e.isValid() || isNaN(n))) {
switch (a = e._d, r = e._isUTC, t) {
case "Milliseconds":
return void (r ? a.setUTCMilliseconds(n) : a.setMilliseconds(n));
case "Seconds":
return void (r ? a.setUTCSeconds(n) : a.setSeconds(n));
case "Minutes":
return void (r ? a.setUTCMinutes(n) : a.setMinutes(n));
case "Hours":
return void (r ? a.setUTCHours(n) : a.setHours(n));
case "Date":
return void (r ? a.setUTCDate(n) : a.setDate(n));
// case 'Day': // Not real
// return void (isUTC ? d.setUTCDay(value) : d.setDay(value));
// case 'Month': // Not used because we need to pass two variables
// return void (isUTC ? d.setUTCMonth(value) : d.setMonth(value));
case "FullYear":
break;
// See below ...
default:
return;
}
s = n, l = e.month(), i = e.date(), i = i === 29 && l === 1 && !ds(s) ? 28 : i, r ? a.setUTCFullYear(s, l, i) : a.setFullYear(s, l, i);
}
}
function Np(e) {
return e = xt(e), Qt(this[e]) ? this[e]() : this;
}
function Bp(e, t) {
if (typeof e == "object") {
e = fi(e);
var n = Tp(e), a, r = n.length;
for (a = 0; a < r; a++)
this[n[a].unit](e[n[a].unit]);
} else if (e = xt(e), Qt(this[e]))
return this[e](t);
return this;
}
function $p(e, t) {
return (e % t + t) % t;
}
var $e;
Array.prototype.indexOf ? $e = Array.prototype.indexOf : $e = function(e) {
var t;
for (t = 0; t < this.length; ++t)
if (this[t] === e)
return t;
return -1;
};
function yi(e, t) {
if (isNaN(e) || isNaN(t))
return NaN;
var n = $p(t, 12);
return e += (t - n) / 12, n === 1 ? ds(e) ? 29 : 28 : 31 - n % 7 % 2;
}
Z("M", ["MM", 2], "Mo", function() {
return this.month() + 1;
});
Z("MMM", 0, 0, function(e) {
return this.localeData().monthsShort(this, e);
});
Z("MMMM", 0, 0, function(e) {
return this.localeData().months(this, e);
});
W("M", Me, ca);
W("MM", Me, St);
W("MMM", function(e, t) {
return t.monthsShortRegex(e);
});
W("MMMM", function(e, t) {
return t.monthsRegex(e);
});
Oe(["M", "MM"], function(e, t) {
t[en] = ye(e) - 1;
});
Oe(["MMM", "MMMM"], function(e, t, n, a) {
var r = n._locale.monthsParse(e, a, n._strict);
r != null ? t[en] = r : de(n).invalidMonth = e;
});
var Up = "January_February_March_April_May_June_July_August_September_October_November_December".split(
"_"
), jd = "Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"), Wd = /D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/, zp = Za, Hp = Za;
function Yp(e, t) {
return e ? Tt(this._months) ? this._months[e.month()] : this._months[(this._months.isFormat || Wd).test(t) ? "format" : "standalone"][e.month()] : Tt(this._months) ? this._months : this._months.standalone;
}
function jp(e, t) {
return e ? Tt(this._monthsShort) ? this._monthsShort[e.month()] : this._monthsShort[Wd.test(t) ? "format" : "standalone"][e.month()] : Tt(this._monthsShort) ? this._monthsShort : this._monthsShort.standalone;
}
function Wp(e, t, n) {
var a, r, s, l = e.toLocaleLowerCase();
if (!this._monthsParse)
for (this._monthsParse = [], this._longMonthsParse = [], this._shortMonthsParse = [], a = 0; a < 12; ++a)
s = Gt([2e3, a]), this._shortMonthsParse[a] = this.monthsShort(
s,
""
).toLocaleLowerCase(), this._longMonthsParse[a] = this.months(s, "").toLocaleLowerCase();
return n ? t === "MMM" ? (r = $e.call(this._shortMonthsParse, l), r !== -1 ? r : null) : (r = $e.call(this._longMonthsParse, l), r !== -1 ? r : null) : t === "MMM" ? (r = $e.call(this._shortMonthsParse, l), r !== -1 ? r : (r = $e.call(this._longMonthsParse, l), r !== -1 ? r : null)) : (r = $e.call(this._longMonthsParse, l), r !== -1 ? r : (r = $e.call(this._shortMonthsParse, l), r !== -1 ? r : null));
}
function Gp(e, t, n) {
var a, r, s;
if (this._monthsParseExact)
return Wp.call(this, e, t, n);
for (this._monthsParse || (this._monthsParse = [], this._longMonthsParse = [], this._shortMonthsParse = []), a = 0; a < 12; a++) {
if (r = Gt([2e3, a]), n && !this._longMonthsParse[a] && (this._longMonthsParse[a] = new RegExp(
"^" + this.months(r, "").replace(".", "") + "$",
"i"
), this._shortMonthsParse[a] = new RegExp(
"^" + this.monthsShort(r, "").replace(".", "") + "$",
"i"
)), !n && !this._monthsParse[a] && (s = "^" + this.months(r, "") + "|^" + this.monthsShort(r, ""), this._monthsParse[a] = new RegExp(s.replace(".", ""), "i")), n && t === "MMMM" && this._longMonthsParse[a].test(e))
return a;
if (n && t === "MMM" && this._shortMonthsParse[a].test(e))
return a;
if (!n && this._monthsParse[a].test(e))
return a;
}
}
function Gd(e, t) {
if (!e.isValid())
return e;
if (typeof t == "string") {
if (/^\d+$/.test(t))
t = ye(t);
else if (t = e.localeData().monthsParse(t), !ln(t))
return e;
}
var n = t, a = e.date();
return a = a < 29 ? a : Math.min(a, yi(e.year(), n)), e._isUTC ? e._d.setUTCMonth(n, a) : e._d.setMonth(n, a), e;
}
function Qd(e) {
return e != null ? (Gd(this, e), z.updateOffset(this, !0), this) : Ra(this, "Month");
}
function Qp() {
return yi(this.year(), this.month());
}
function qp(e) {
return this._monthsParseExact ? (ke(this, "_monthsRegex") || qd.call(this), e ? this._monthsShortStrictRegex : this._monthsShortRegex) : (ke(this, "_monthsShortRegex") || (this._monthsShortRegex = zp), this._monthsShortStrictRegex && e ? this._monthsShortStrictRegex : this._monthsShortRegex);
}
function Kp(e) {
return this._monthsParseExact ? (ke(this, "_monthsRegex") || qd.call(this), e ? this._monthsStrictRegex : this._monthsRegex) : (ke(this, "_monthsRegex") || (this._monthsRegex = Hp), this._monthsStrictRegex && e ? this._monthsStrictRegex : this._monthsRegex);
}
function qd() {
function e(o, u) {
return u.length - o.length;
}
var t = [], n = [], a = [], r, s, l, i;
for (r = 0; r < 12; r++)
s = Gt([2e3, r]), l = nn(this.monthsShort(s, "")), i = nn(this.months(s, "")), t.push(l), n.push(i), a.push(i), a.push(l);
t.sort(e), n.sort(e), a.sort(e), this._monthsRegex = new RegExp("^(" + a.join("|") + ")", "i"), this._monthsShortRegex = this._monthsRegex, this._monthsStrictRegex = new RegExp(
"^(" + n.join("|") + ")",
"i"
), this._monthsShortStrictRegex = new RegExp(
"^(" + t.join("|") + ")",
"i"
);
}
function Jp(e, t, n, a, r, s, l) {
var i;
return e < 100 && e >= 0 ? (i = new Date(e + 400, t, n, a, r, s, l), isFinite(i.getFullYear()) && i.setFullYear(e)) : i = new Date(e, t, n, a, r, s, l), i;
}
function Fa(e) {
var t, n;
return e < 100 && e >= 0 ? (n = Array.prototype.slice.call(arguments), n[0] = e + 400, t = new Date(Date.UTC.apply(null, n)), isFinite(t.getUTCFullYear()) && t.setUTCFullYear(e)) : t = new Date(Date.UTC.apply(null, arguments)), t;
}
function Ar(e, t, n) {
var a = 7 + t - n, r = (7 + Fa(e, 0, a).getUTCDay() - t) % 7;
return -r + a - 1;
}
function Kd(e, t, n, a, r) {
var s = (7 + n - a) % 7, l = Ar(e, a, r), i = 1 + 7 * (t - 1) + s + l, o, u;
return i <= 0 ? (o = e - 1, u = Ca(o) + i) : i > Ca(e) ? (o = e + 1, u = i - Ca(e)) : (o = e, u = i), {
year: o,
dayOfYear: u
};
}
function La(e, t, n) {
var a = Ar(e.year(), t, n), r = Math.floor((e.dayOfYear() - a - 1) / 7) + 1, s, l;
return r < 1 ? (l = e.year() - 1, s = r + an(l, t, n)) : r > an(e.year(), t, n) ? (s = r - an(e.year(), t, n), l = e.year() + 1) : (l = e.year(), s = r), {
week: s,
year: l
};
}
function an(e, t, n) {
var a = Ar(e, t, n), r = Ar(e + 1, t, n);
return (Ca(e) - a + r) / 7;
}
Z("w", ["ww", 2], "wo", "week");
Z("W", ["WW", 2], "Wo", "isoWeek");
W("w", Me, ca);
W("ww", Me, St);
W("W", Me, ca);
W("WW", Me, St);
Xa(
["w", "ww", "W", "WW"],
function(e, t, n, a) {
t[a.substr(0, 1)] = ye(e);
}
);
function Zp(e) {
return La(e, this._week.dow, this._week.doy).week;
}
var Xp = {
dow: 0,
// Sunday is the first day of the week.
doy: 6
// The week that contains Jan 6th is the first week of the year.
};
function eS() {
return this._week.dow;
}
function tS() {
return this._week.doy;
}
function nS(e) {
var t = this.localeData().week(this);
return e == null ? t : this.add((e - t) * 7, "d");
}
function aS(e) {
var t = La(this, 1, 4).week;
return e == null ? t : this.add((e - t) * 7, "d");
}
Z("d", 0, "do", "day");
Z("dd", 0, 0, function(e) {
return this.localeData().weekdaysMin(this, e);
});
Z("ddd", 0, 0, function(e) {
return this.localeData().weekdaysShort(this, e);
});
Z("dddd", 0, 0, function(e) {
return this.localeData().weekdays(this, e);
});
Z("e", 0, 0, "weekday");
Z("E", 0, 0, "isoWeekday");
W("d", Me);
W("e", Me);
W("E", Me);
W("dd", function(e, t) {
return t.weekdaysMinRegex(e);
});
W("ddd", function(e, t) {
return t.weekdaysShortRegex(e);
});
W("dddd", function(e, t) {
return t.weekdaysRegex(e);
});
Xa(["dd", "ddd", "dddd"], function(e, t, n, a) {
var r = n._locale.weekdaysParse(e, a, n._strict);
r != null ? t.d = r : de(n).invalidWeekday = e;
});
Xa(["d", "e", "E"], function(e, t, n, a) {
t[a] = ye(e);
});
function rS(e, t) {
return typeof e != "string" ? e : isNaN(e) ? (e = t.weekdaysParse(e), typeof e == "number" ? e : null) : parseInt(e, 10);
}
function sS(e, t) {
return typeof e == "string" ? t.weekdaysParse(e) % 7 || 7 : isNaN(e) ? null : e;
}
function gi(e, t) {
return e.slice(t, 7).concat(e.slice(0, t));
}
var lS = "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), Jd = "Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"), iS = "Su_Mo_Tu_We_Th_Fr_Sa".split("_"), oS = Za, uS = Za, cS = Za;
function dS(e, t) {
var n = Tt(this._weekdays) ? this._weekdays : this._weekdays[e && e !== !0 && this._weekdays.isFormat.test(t) ? "format" : "standalone"];
return e === !0 ? gi(n, this._week.dow) : e ? n[e.day()] : n;
}
function fS(e) {
return e === !0 ? gi(this._weekdaysShort, this._week.dow) : e ? this._weekdaysShort[e.day()] : this._weekdaysShort;
}
function hS(e) {
return e === !0 ? gi(this._weekdaysMin, this._week.dow) : e ? this._weekdaysMin[e.day()] : this._weekdaysMin;
}
function mS(e, t, n) {
var a, r, s, l = e.toLocaleLowerCase();
if (!this._weekdaysParse)
for (this._weekdaysParse = [], this._shortWeekdaysParse = [], this._minWeekdaysParse = [], a = 0; a < 7; ++a)
s = Gt([2e3, 1]).day(a), this._minWeekdaysParse[a] = this.weekdaysMin(
s,
""
).toLocaleLowerCase(), this._shortWeekdaysParse[a] = this.weekdaysShort(
s,
""
).toLocaleLowerCase(), this._weekdaysParse[a] = this.weekdays(s, "").toLocaleLowerCase();
return n ? t === "dddd" ? (r = $e.call(this._weekdaysParse, l), r !== -1 ? r : null) : t === "ddd" ? (r = $e.call(this._shortWeekdaysParse, l), r !== -1 ? r : null) : (r = $e.call(this._minWeekdaysParse, l), r !== -1 ? r : null) : t === "dddd" ? (r = $e.call(this._weekdaysParse, l), r !== -1 || (r = $e.call(this._shortWeekdaysParse, l), r !== -1) ? r : (r = $e.call(this._minWeekdaysParse, l), r !== -1 ? r : null)) : t === "ddd" ? (r = $e.call(this._shortWeekdaysParse, l), r !== -1 || (r = $e.call(this._weekdaysParse, l), r !== -1) ? r : (r = $e.call(this._minWeekdaysParse, l), r !== -1 ? r : null)) : (r = $e.call(this._minWeekdaysParse, l), r !== -1 || (r = $e.call(this._weekdaysParse, l), r !== -1) ? r : (r = $e.call(this._shortWeekdaysParse, l), r !== -1 ? r : null));
}
function vS(e, t, n) {
var a, r, s;
if (this._weekdaysParseExact)
return mS.call(this, e, t, n);
for (this._weekdaysParse || (this._weekdaysParse = [], this._minWeekdaysParse = [], this._shortWeekdaysParse = [], this._fullWeekdaysParse = []), a = 0; a < 7; a++) {
if (r = Gt([2e3, 1]).day(a), n && !this._fullWeekdaysParse[a] && (this._fullWeekdaysParse[a] = new RegExp(
"^" + this.weekdays(r, "").replace(".", "\\.?") + "$",
"i"
), this._shortWeekdaysParse[a] = new RegExp(
"^" + this.weekdaysShort(r, "").replace(".", "\\.?") + "$",
"i"
), this._minWeekdaysParse[a] = new RegExp(
"^" + this.weekdaysMin(r, "").replace(".", "\\.?") + "$",
"i"
)), this._weekdaysParse[a] || (s = "^" + this.weekdays(r, "") + "|^" + this.weekdaysShort(r, "") + "|^" + this.weekdaysMin(r, ""), this._weekdaysParse[a] = new RegExp(s.replace(".", ""), "i")), n && t === "dddd" && this._fullWeekdaysParse[a].test(e))
return a;
if (n && t === "ddd" && this._shortWeekdaysParse[a].test(e))
return a;
if (n && t === "dd" && this._minWeekdaysParse[a].test(e))
return a;
if (!n && this._weekdaysParse[a].test(e))
return a;
}
}
function yS(e) {
if (!this.isValid())
return e != null ? this : NaN;
var t = Ra(this, "Day");
return e != null ? (e = rS(e, this.localeData()), this.add(e - t, "d")) : t;
}
function gS(e) {
if (!this.isValid())
return e != null ? this : NaN;
var t = (this.day() + 7 - this.localeData()._week.dow) % 7;
return e == null ? t : this.add(e - t, "d");
}
function bS(e) {
if (!this.isValid())
return e != null ? this : NaN;
if (e != null) {
var t = sS(e, this.localeData());
return this.day(this.day() % 7 ? t : t - 7);
} else
return this.day() || 7;
}
function pS(e) {
return this._weekdaysParseExact ? (ke(this, "_weekdaysRegex") || bi.call(this), e ? this._weekdaysStrictRegex : this._weekdaysRegex) : (ke(this, "_weekdaysRegex") || (this._weekdaysRegex = oS), this._weekdaysStrictRegex && e ? this._weekdaysStrictRegex : this._weekdaysRegex);
}
function SS(e) {
return this._weekdaysParseExact ? (ke(this, "_weekdaysRegex") || bi.call(this), e ? this._weekdaysShortStrictRegex : this._weekdaysShortRegex) : (ke(this, "_weekdaysShortRegex") || (this._weekdaysShortRegex = uS), this._weekdaysShortStrictRegex && e ? this._weekdaysShortStrictRegex : this._weekdaysShortRegex);
}
function wS(e) {
return this._weekdaysParseExact ? (ke(this, "_weekdaysRegex") || bi.call(this), e ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex) : (ke(this, "_weekdaysMinRegex") || (this._weekdaysMinRegex = cS), this._weekdaysMinStrictRegex && e ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex);
}
function bi() {
function e(c, d) {
return d.length - c.length;
}
var t = [], n = [], a = [], r = [], s, l, i, o, u;
for (s = 0; s < 7; s++)
l = Gt([2e3, 1]).day(s), i = nn(this.weekdaysMin(l, "")), o = nn(this.weekdaysShort(l, "")), u = nn(this.weekdays(l, "")), t.push(i), n.push(o), a.push(u), r.push(i), r.push(o), r.push(u);
t.sort(e), n.sort(e), a.sort(e), r.sort(e), this._weekdaysRegex = new RegExp("^(" + r.join("|") + ")", "i"), this._weekdaysShortRegex = this._weekdaysRegex, this._weekdaysMinRegex = this._weekdaysRegex, this._weekdaysStrictRegex = new RegExp(
"^(" + a.join("|") + ")",
"i"
), this._weekdaysShortStrictRegex = new RegExp(
"^(" + n.join("|") + ")",
"i"
), this._weekdaysMinStrictRegex = new RegExp(
"^(" + t.join("|") + ")",
"i"
);
}
function pi() {
return this.hours() % 12 || 12;
}
function _S() {
return this.hours() || 24;
}
Z("H", ["HH", 2], 0, "hour");
Z("h", ["hh", 2], 0, pi);
Z("k", ["kk", 2], 0, _S);
Z("hmm", 0, 0, function() {
return "" + pi.apply(this) + Yt(this.minutes(), 2);
});
Z("hmmss", 0, 0, function() {
return "" + pi.apply(this) + Yt(this.minutes(), 2) + Yt(this.seconds(), 2);
});
Z("Hmm", 0, 0, function() {
return "" + this.hours() + Yt(this.minutes(), 2);
});
Z("Hmmss", 0, 0, function() {
return "" + this.hours() + Yt(this.minutes(), 2) + Yt(this.seconds(), 2);
});
function Zd(e, t) {
Z(e, 0, 0, function() {
return this.localeData().meridiem(
this.hours(),
this.minutes(),
t
);
});
}
Zd("a", !0);
Zd("A", !1);
function Xd(e, t) {
return t._meridiemParse;
}
W("a", Xd);
W("A", Xd);
W("H", Me, vi);
W("h", Me, ca);
W("k", Me, ca);
W("HH", Me, St);
W("hh", Me, St);
W("kk", Me, St);
W("hmm", Ud);
W("hmmss", zd);
W("Hmm", Ud);
W("Hmmss", zd);
Oe(["H", "HH"], je);
Oe(["k", "kk"], function(e, t, n) {
var a = ye(e);
t[je] = a === 24 ? 0 : a;
});
Oe(["a", "A"], function(e, t, n) {
n._isPm = n._locale.isPM(e), n._meridiem = e;
});
Oe(["h", "hh"], function(e, t, n) {
t[je] = ye(e), de(n).bigHour = !0;
});
Oe("hmm", function(e, t, n) {
var a = e.length - 2;
t[je] = ye(e.substr(0, a)), t[It] = ye(e.substr(a)), de(n).bigHour = !0;
});
Oe("hmmss", function(e, t, n) {
var a = e.length - 4, r = e.length - 2;
t[je] = ye(e.substr(0, a)), t[It] = ye(e.substr(a, 2)), t[tn] = ye(e.substr(r)), de(n).bigHour = !0;
});
Oe("Hmm", function(e, t, n) {
var a = e.length - 2;
t[je] = ye(e.substr(0, a)), t[It] = ye(e.substr(a));
});
Oe("Hmmss", function(e, t, n) {
var a = e.length - 4, r = e.length - 2;
t[je] = ye(e.substr(0, a)), t[It] = ye(e.substr(a, 2)), t[tn] = ye(e.substr(r));
});
function kS(e) {
return (e + "").toLowerCase().charAt(0) === "p";
}
var CS = /[ap]\.?m?\.?/i, PS = da("Hours", !0);
function xS(e, t, n) {
return e > 11 ? n ? "pm" : "PM" : n ? "am" : "AM";
}
var ef = {
calendar: mp,
longDateFormat: bp,
invalidDate: Sp,
ordinal: _p,
dayOfMonthOrdinalParse: kp,
relativeTime: Pp,
months: Up,
monthsShort: jd,
week: Xp,
weekdays: lS,
weekdaysMin: iS,
weekdaysShort: Jd,
meridiemParse: CS
}, Re = {}, ba = {}, Na;
function IS(e, t) {
var n, a = Math.min(e.length, t.length);
for (n = 0; n < a; n += 1)
if (e[n] !== t[n])
return n;
return a;
}
function Go(e) {
return e && e.toLowerCase().replace("_", "-");
}
function OS(e) {
for (var t = 0, n, a, r, s; t < e.length; ) {
for (s = Go(e[t]).split("-"), n = s.length, a = Go(e[t + 1]), a = a ? a.split("-") : null; n > 0; ) {
if (r = fs(s.slice(0, n).join("-")), r)
return r;
if (a && a.length >= n && IS(s, a) >= n - 1)
break;
n--;
}
t++;
}
return Na;
}
function TS(e) {
return !!(e && e.match("^[^/\\\\]*$"));
}
function fs(e) {
var t = null, n;
if (Re[e] === void 0 && typeof module < "u" && module && module.exports && TS(e))
try {
t = Na._abbr, n = require, n("./locale/" + e), wn(t);
} catch {
Re[e] = null;
}
return Re[e];
}
function wn(e, t) {
var n;
return e && (ut(t) ? n = mn(e) : n = Si(e, t), n ? Na = n : typeof console < "u" && console.warn && console.warn(
"Locale " + e + " not found. Did you forget to load it?"
)), Na._abbr;
}
function Si(e, t) {
if (t !== null) {
var n, a = ef;
if (t.abbr = e, Re[e] != null)
Ld(
"defineLocaleOverride",
"use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."
), a = Re[e]._config;
else if (t.parentLocale != null)
if (Re[t.parentLocale] != null)
a = Re[t.parentLocale]._config;
else if (n = fs(t.parentLocale), n != null)
a = n._config;
else
return ba[t.parentLocale] || (ba[t.parentLocale] = []), ba[t.parentLocale].push({
name: e,
config: t
}), null;
return Re[e] = new ci(yl(a, t)), ba[e] && ba[e].forEach(function(r) {
Si(r.name, r.config);
}), wn(e), Re[e];
} else
return delete Re[e], null;
}
function VS(e, t) {
if (t != null) {
var n, a, r = ef;
Re[e] != null && Re[e].parentLocale != null ? Re[e].set(yl(Re[e]._config, t)) : (a = fs(e), a != null && (r = a._config), t = yl(r, t), a == null && (t.abbr = e), n = new ci(t), n.parentLocale = Re[e], Re[e] = n), wn(e);
} else
Re[e] != null && (Re[e].parentLocale != null ? (Re[e] = Re[e].parentLocale, e === wn() && wn(e)) : Re[e] != null && delete Re[e]);
return Re[e];
}
function mn(e) {
var t;
if (e && e._locale && e._locale._abbr && (e = e._locale._abbr), !e)
return Na;
if (!Tt(e)) {
if (t = fs(e), t)
return t;
e = [e];
}
return OS(e);
}
function AS() {
return gl(Re);
}
function wi(e) {
var t, n = e._a;
return n && de(e).overflow === -2 && (t = n[en] < 0 || n[en] > 11 ? en : n[Nt] < 1 || n[Nt] > yi(n[tt], n[en]) ? Nt : n[je] < 0 || n[je] > 24 || n[je] === 24 && (n[It] !== 0 || n[tn] !== 0 || n[Vn] !== 0) ? je : n[It] < 0 || n[It] > 59 ? It : n[tn] < 0 || n[tn] > 59 ? tn : n[Vn] < 0 || n[Vn] > 999 ? Vn : -1, de(e)._overflowDayOfYear && (t < tt || t > Nt) && (t = Nt), de(e)._overflowWeeks && t === -1 && (t = Rp), de(e)._overflowWeekday && t === -1 && (t = Fp), de(e).overflow = t), e;
}
var ES = /^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/, DS = /^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/, MS = /Z|[+-]\d\d(?::?\d\d)?/, ur = [
["YYYYYY-MM-DD", /[+-]\d{6}-\d\d-\d\d/],
["YYYY-MM-DD", /\d{4}-\d\d-\d\d/],
["GGGG-[W]WW-E", /\d{4}-W\d\d-\d/],
["GGGG-[W]WW", /\d{4}-W\d\d/, !1],
["YYYY-DDD", /\d{4}-\d{3}/],
["YYYY-MM", /\d{4}-\d\d/, !1],
["YYYYYYMMDD", /[+-]\d{10}/],
["YYYYMMDD", /\d{8}/],
["GGGG[W]WWE", /\d{4}W\d{3}/],
["GGGG[W]WW", /\d{4}W\d{2}/, !1],
["YYYYDDD", /\d{7}/],
["YYYYMM", /\d{6}/, !1],
["YYYY", /\d{4}/, !1]
], Ns = [
["HH:mm:ss.SSSS", /\d\d:\d\d:\d\d\.\d+/],
["HH:mm:ss,SSSS", /\d\d:\d\d:\d\d,\d+/],
["HH:mm:ss", /\d\d:\d\d:\d\d/],
["HH:mm", /\d\d:\d\d/],
["HHmmss.SSSS", /\d\d\d\d\d\d\.\d+/],
["HHmmss,SSSS", /\d\d\d\d\d\d,\d+/],
["HHmmss", /\d\d\d\d\d\d/],
["HHmm", /\d\d\d\d/],
["HH", /\d\d/]
], RS = /^\/?Date\((-?\d+)/i, FS = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/, LS = {
UT: 0,
GMT: 0,
EDT: -4 * 60,
EST: -5 * 60,
CDT: -5 * 60,
CST: -6 * 60,
MDT: -6 * 60,
MST: -7 * 60,
PDT: -7 * 60,
PST: -8 * 60
};
function tf(e) {
var t, n, a = e._i, r = ES.exec(a) || DS.exec(a), s, l, i, o, u = ur.length, c = Ns.length;
if (r) {
for (de(e).iso = !0, t = 0, n = u; t < n; t++)
if (ur[t][1].exec(r[1])) {
l = ur[t][0], s = ur[t][2] !== !1;
break;
}
if (l == null) {
e._isValid = !1;
return;
}
if (r[3]) {
for (t = 0, n = c; t < n; t++)
if (Ns[t][1].exec(r[3])) {
i = (r[2] || " ") + Ns[t][0];
break;
}
if (i == null) {
e._isValid = !1;
return;
}
}
if (!s && i != null) {
e._isValid = !1;
return;
}
if (r[4])
if (MS.exec(r[4]))
o = "Z";
else {
e._isValid = !1;
return;
}
e._f = l + (i || "") + (o || ""), ki(e);
} else
e._isValid = !1;
}
function NS(e, t, n, a, r, s) {
var l = [
BS(e),
jd.indexOf(t),
parseInt(n, 10),
parseInt(a, 10),
parseInt(r, 10)
];
return s && l.push(parseInt(s, 10)), l;
}
function BS(e) {
var t = parseInt(e, 10);
return t <= 49 ? 2e3 + t : t <= 999 ? 1900 + t : t;
}
function $S(e) {
return e.replace(/\([^()]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").replace(/^\s\s*/, "").replace(/\s\s*$/, "");
}
function US(e, t, n) {
if (e) {
var a = Jd.indexOf(e), r = new Date(
t[0],
t[1],
t[2]
).getDay();
if (a !== r)
return de(n).weekdayMismatch = !0, n._isValid = !1, !1;
}
return !0;
}
function zS(e, t, n) {
if (e)
return LS[e];
if (t)
return 0;
var a = parseInt(n, 10), r = a % 100, s = (a - r) / 100;
return s * 60 + r;
}
function nf(e) {
var t = FS.exec($S(e._i)), n;
if (t) {
if (n = NS(
t[4],
t[3],
t[2],
t[5],
t[6],
t[7]
), !US(t[1], n, e))
return;
e._a = n, e._tzm = zS(t[8], t[9], t[10]), e._d = Fa.apply(null, e._a), e._d.setUTCMinutes(e._d.getUTCMinutes() - e._tzm), de(e).rfc2822 = !0;
} else
e._isValid = !1;
}
function HS(e) {
var t = RS.exec(e._i);
if (t !== null) {
e._d = /* @__PURE__ */ new Date(+t[1]);
return;
}
if (tf(e), e._isValid === !1)
delete e._isValid;
else
return;
if (nf(e), e._isValid === !1)
delete e._isValid;
else
return;
e._strict ? e._isValid = !1 : z.createFromInputFallback(e);
}
z.createFromInputFallback = Pt(
"value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",
function(e) {
e._d = /* @__PURE__ */ new Date(e._i + (e._useUTC ? " UTC" : ""));
}
);
function Wn(e, t, n) {
return e ?? t ?? n;
}
function YS(e) {
var t = new Date(z.now());
return e._useUTC ? [
t.getUTCFullYear(),
t.getUTCMonth(),
t.getUTCDate()
] : [t.getFullYear(), t.getMonth(), t.getDate()];
}
function _i(e) {
var t, n, a = [], r, s, l;
if (!e._d) {
for (r = YS(e), e._w && e._a[Nt] == null && e._a[en] == null && jS(e), e._dayOfYear != null && (l = Wn(e._a[tt], r[tt]), (e._dayOfYear > Ca(l) || e._dayOfYear === 0) && (de(e)._overflowDayOfYear = !0), n = Fa(l, 0, e._dayOfYear), e._a[en] = n.getUTCMonth(), e._a[Nt] = n.getUTCDate()), t = 0; t < 3 && e._a[t] == null; ++t)
e._a[t] = a[t] = r[t];
for (; t < 7; t++)
e._a[t] = a[t] = e._a[t] == null ? t === 2 ? 1 : 0 : e._a[t];
e._a[je] === 24 && e._a[It] === 0 && e._a[tn] === 0 && e._a[Vn] === 0 && (e._nextDay = !0, e._a[je] = 0), e._d = (e._useUTC ? Fa : Jp).apply(
null,
a
), s = e._useUTC ? e._d.getUTCDay() : e._d.getDay(), e._tzm != null && e._d.setUTCMinutes(e._d.getUTCMinutes() - e._tzm), e._nextDay && (e._a[je] = 24), e._w && typeof e._w.d < "u" && e._w.d !== s && (de(e).weekdayMismatch = !0);
}
}
function jS(e) {
var t, n, a, r, s, l, i, o, u;
t = e._w, t.GG != null || t.W != null || t.E != null ? (s = 1, l = 4, n = Wn(
t.GG,
e._a[tt],
La(Ee(), 1, 4).year
), a = Wn(t.W, 1), r = Wn(t.E, 1), (r < 1 || r > 7) && (o = !0)) : (s = e._locale._week.dow, l = e._locale._week.doy, u = La(Ee(), s, l), n = Wn(t.gg, e._a[tt], u.year), a = Wn(t.w, u.week), t.d != null ? (r = t.d, (r < 0 || r > 6) && (o = !0)) : t.e != null ? (r = t.e + s, (t.e < 0 || t.e > 6) && (o = !0)) : r = s), a < 1 || a > an(n, s, l) ? de(e)._overflowWeeks = !0 : o != null ? de(e)._overflowWeekday = !0 : (i = Kd(n, a, r, s, l), e._a[tt] = i.year, e._dayOfYear = i.dayOfYear);
}
z.ISO_8601 = function() {
};
z.RFC_2822 = function() {
};
function ki(e) {
if (e._f === z.ISO_8601) {
tf(e);
return;
}
if (e._f === z.RFC_2822) {
nf(e);
return;
}
e._a = [], de(e).empty = !0;
var t = "" + e._i, n, a, r, s, l, i = t.length, o = 0, u, c;
for (r = Nd(e._f, e._locale).match(di) || [], c = r.length, n = 0; n < c; n++)
s = r[n], a = (t.match(Ep(s, e)) || [])[0], a && (l = t.substr(0, t.indexOf(a)), l.length > 0 && de(e).unusedInput.push(l), t = t.slice(
t.indexOf(a) + a.length
), o += a.length), qn[s] ? (a ? de(e).empty = !1 : de(e).unusedTokens.push(s), Mp(s, a, e)) : e._strict && !a && de(e).unusedTokens.push(s);
de(e).charsLeftOver = i - o, t.length > 0 && de(e).unusedInput.push(t), e._a[je] <= 12 && de(e).bigHour === !0 && e._a[je] > 0 && (de(e).bigHour = void 0), de(e).parsedDateParts = e._a.slice(0), de(e).meridiem = e._meridiem, e._a[je] = WS(
e._locale,
e._a[je],
e._meridiem
), u = de(e).era, u !== null && (e._a[tt] = e._locale.erasConvertYear(u, e._a[tt])), _i(e), wi(e);
}
function WS(e, t, n) {
var a;
return n == null ? t : e.meridiemHour != null ? e.meridiemHour(t, n) : (e.isPM != null && (a = e.isPM(n), a && t < 12 && (t += 12), !a && t === 12 && (t = 0)), t);
}
function GS(e) {
var t, n, a, r, s, l, i = !1, o = e._f.length;
if (o === 0) {
de(e).invalidFormat = !0, e._d = /* @__PURE__ */ new Date(NaN);
return;
}
for (r = 0; r < o; r++)
s = 0, l = !1, t = ui({}, e), e._useUTC != null && (t._useUTC = e._useUTC), t._f = e._f[r], ki(t), oi(t) && (l = !0), s += de(t).charsLeftOver, s += de(t).unusedTokens.length * 10, de(t).score = s, i ? s < a && (a = s, n = t) : (a == null || s < a || l) && (a = s, n = t, l && (i = !0));
bn(e, n || t);
}
function QS(e) {
if (!e._d) {
var t = fi(e._i), n = t.day === void 0 ? t.date : t.day;
e._a = Rd(
[t.year, t.month, n, t.hour, t.minute, t.second, t.millisecond],
function(a) {
return a && parseInt(a, 10);
}
), _i(e);
}
}
function qS(e) {
var t = new Ja(wi(af(e)));
return t._nextDay && (t.add(1, "d"), t._nextDay = void 0), t;
}
function af(e) {
var t = e._i, n = e._f;
return e._locale = e._locale || mn(e._l), t === null || n === void 0 && t === "" ? ss({ nullInput: !0 }) : (typeof t == "string" && (e._i = t = e._locale.preparse(t)), Vt(t) ? new Ja(wi(t)) : (Ka(t) ? e._d = t : Tt(n) ? GS(e) : n ? ki(e) : KS(e), oi(e) || (e._d = null), e));
}
function KS(e) {
var t = e._i;
ut(t) ? e._d = new Date(z.now()) : Ka(t) ? e._d = new Date(t.valueOf()) : typeof t == "string" ? HS(e) : Tt(t) ? (e._a = Rd(t.slice(0), function(n) {
return parseInt(n, 10);
}), _i(e)) : Dn(t) ? QS(e) : ln(t) ? e._d = new Date(t) : z.createFromInputFallback(e);
}
function rf(e, t, n, a, r) {
var s = {};
return (t === !0 || t === !1) && (a = t, t = void 0), (n === !0 || n === !1) && (a = n, n = void 0), (Dn(e) && ii(e) || Tt(e) && e.length === 0) && (e = void 0), s._isAMomentObject = !0, s._useUTC = s._isUTC = r, s._l = n, s._i = e, s._f = t, s._strict = a, qS(s);
}
function Ee(e, t, n, a) {
return rf(e, t, n, a, !1);
}
var JS = Pt(
"moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",
function() {
var e = Ee.apply(null, arguments);
return this.isValid() && e.isValid() ? e < this ? this : e : ss();
}
), ZS = Pt(
"moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",
function() {
var e = Ee.apply(null, arguments);
return this.isValid() && e.isValid() ? e > this ? this : e : ss();
}
);
function sf(e, t) {
var n, a;
if (t.length === 1 && Tt(t[0]) && (t = t[0]), !t.length)
return Ee();
for (n = t[0], a = 1; a < t.length; ++a)
(!t[a].isValid() || t[a][e](n)) && (n = t[a]);
return n;
}
function XS() {
var e = [].slice.call(arguments, 0);
return sf("isBefore", e);
}
function ew() {
var e = [].slice.call(arguments, 0);
return sf("isAfter", e);
}
var tw = function() {
return Date.now ? Date.now() : +/* @__PURE__ */ new Date();
}, pa = [
"year",
"quarter",
"month",
"week",
"day",
"hour",
"minute",
"second",
"millisecond"
];
function nw(e) {
var t, n = !1, a, r = pa.length;
for (t in e)
if (ke(e, t) && !($e.call(pa, t) !== -1 && (e[t] == null || !isNaN(e[t]))))
return !1;
for (a = 0; a < r; ++a)
if (e[pa[a]]) {
if (n)
return !1;
parseFloat(e[pa[a]]) !== ye(e[pa[a]]) && (n = !0);
}
return !0;
}
function aw() {
return this._isValid;
}
function rw() {
return Rt(NaN);
}
function hs(e) {
var t = fi(e), n = t.year || 0, a = t.quarter || 0, r = t.month || 0, s = t.week || t.isoWeek || 0, l = t.day || 0, i = t.hour || 0, o = t.minute || 0, u = t.second || 0, c = t.millisecond || 0;
this._isValid = nw(t), this._milliseconds = +c + u * 1e3 + // 1000
o * 6e4 + // 1000 * 60
i * 1e3 * 60 * 60, this._days = +l + s * 7, this._months = +r + a * 3 + n * 12, this._data = {}, this._locale = mn(), this._bubble();
}
function yr(e) {
return e instanceof hs;
}
function pl(e) {
return e < 0 ? Math.round(-1 * e) * -1 : Math.round(e);
}
function sw(e, t, n) {
var a = Math.min(e.length, t.length), r = Math.abs(e.length - t.length), s = 0, l;
for (l = 0; l < a; l++)
ye(e[l]) !== ye(t[l]) && s++;
return s + r;
}
function lf(e, t) {
Z(e, 0, 0, function() {
var n = this.utcOffset(), a = "+";
return n < 0 && (n = -n, a = "-"), a + Yt(~~(n / 60), 2) + t + Yt(~~n % 60, 2);
});
}
lf("Z", ":");
lf("ZZ", "");
W("Z", cs);
W("ZZ", cs);
Oe(["Z", "ZZ"], function(e, t, n) {
n._useUTC = !0, n._tzm = Ci(cs, e);
});
var lw = /([\+\-]|\d\d)/gi;
function Ci(e, t) {
var n = (t || "").match(e), a, r, s;
return n === null ? null : (a = n[n.length - 1] || [], r = (a + "").match(lw) || ["-", 0, 0], s = +(r[1] * 60) + ye(r[2]), s === 0 ? 0 : r[0] === "+" ? s : -s);
}
function Pi(e, t) {
var n, a;
return t._isUTC ? (n = t.clone(), a = (Vt(e) || Ka(e) ? e.valueOf() : Ee(e).valueOf()) - n.valueOf(), n._d.setTime(n._d.valueOf() + a), z.updateOffset(n, !1), n) : Ee(e).local();
}
function Sl(e) {
return -Math.round(e._d.getTimezoneOffset());
}
z.updateOffset = function() {
};
function iw(e, t, n) {
var a = this._offset || 0, r;
if (!this.isValid())
return e != null ? this : NaN;
if (e != null) {
if (typeof e == "string") {
if (e = Ci(cs, e), e === null)
return this;
} else Math.abs(e) < 16 && !n && (e = e * 60);
return !this._isUTC && t && (r = Sl(this)), this._offset = e, this._isUTC = !0, r != null && this.add(r, "m"), a !== e && (!t || this._changeInProgress ? cf(
this,
Rt(e - a, "m"),
1,
!1
) : this._changeInProgress || (this._changeInProgress = !0, z.updateOffset(this, !0), this._changeInProgress = null)), this;
} else
return this._isUTC ? a : Sl(this);
}
function ow(e, t) {
return e != null ? (typeof e != "string" && (e = -e), this.utcOffset(e, t), this) : -this.utcOffset();
}
function uw(e) {
return this.utcOffset(0, e);
}
function cw(e) {
return this._isUTC && (this.utcOffset(0, e), this._isUTC = !1, e && this.subtract(Sl(this), "m")), this;
}
function dw() {
if (this._tzm != null)
this.utcOffset(this._tzm, !1, !0);
else if (typeof this._i == "string") {
var e = Ci(Vp, this._i);
e != null ? this.utcOffset(e) : this.utcOffset(0, !0);
}
return this;
}
function fw(e) {
return this.isValid() ? (e = e ? Ee(e).utcOffset() : 0, (this.utcOffset() - e) % 60 === 0) : !1;
}
function hw() {
return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset();
}
function mw() {
if (!ut(this._isDSTShifted))
return this._isDSTShifted;
var e = {}, t;
return ui(e, this), e = af(e), e._a ? (t = e._isUTC ? Gt(e._a) : Ee(e._a), this._isDSTShifted = this.isValid() && sw(e._a, t.toArray()) > 0) : this._isDSTShifted = !1, this._isDSTShifted;
}
function vw() {
return this.isValid() ? !this._isUTC : !1;
}
function yw() {
return this.isValid() ? this._isUTC : !1;
}
function of() {
return this.isValid() ? this._isUTC && this._offset === 0 : !1;
}
var gw = /^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/, bw = /^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;
function Rt(e, t) {
var n = e, a = null, r, s, l;
return yr(e) ? n = {
ms: e._milliseconds,
d: e._days,
M: e._months
} : ln(e) || !isNaN(+e) ? (n = {}, t ? n[t] = +e : n.milliseconds = +e) : (a = gw.exec(e)) ? (r = a[1] === "-" ? -1 : 1, n = {
y: 0,
d: ye(a[Nt]) * r,
h: ye(a[je]) * r,
m: ye(a[It]) * r,
s: ye(a[tn]) * r,
ms: ye(pl(a[Vn] * 1e3)) * r
// the millisecond decimal point is included in the match
}) : (a = bw.exec(e)) ? (r = a[1] === "-" ? -1 : 1, n = {
y: In(a[2], r),
M: In(a[3], r),
w: In(a[4], r),
d: In(a[5], r),
h: In(a[6], r),
m: In(a[7], r),
s: In(a[8], r)
}) : n == null ? n = {} : typeof n == "object" && ("from" in n || "to" in n) && (l = pw(
Ee(n.from),
Ee(n.to)
), n = {}, n.ms = l.milliseconds, n.M = l.months), s = new hs(n), yr(e) && ke(e, "_locale") && (s._locale = e._locale), yr(e) && ke(e, "_isValid") && (s._isValid = e._isValid), s;
}
Rt.fn = hs.prototype;
Rt.invalid = rw;
function In(e, t) {
var n = e && parseFloat(e.replace(",", "."));
return (isNaN(n) ? 0 : n) * t;
}
function Qo(e, t) {
var n = {};
return n.months = t.month() - e.month() + (t.year() - e.year()) * 12, e.clone().add(n.months, "M").isAfter(t) && --n.months, n.milliseconds = +t - +e.clone().add(n.months, "M"), n;
}
function pw(e, t) {
var n;
return e.isValid() && t.isValid() ? (t = Pi(t, e), e.isBefore(t) ? n = Qo(e, t) : (n = Qo(t, e), n.milliseconds = -n.milliseconds, n.months = -n.months), n) : { milliseconds: 0, months: 0 };
}
function uf(e, t) {
return function(n, a) {
var r, s;
return a !== null && !isNaN(+a) && (Ld(
t,
"moment()." + t + "(period, number) is deprecated. Please use moment()." + t + "(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."
), s = n, n = a, a = s), r = Rt(n, a), cf(this, r, e), this;
};
}
function cf(e, t, n, a) {
var r = t._milliseconds, s = pl(t._days), l = pl(t._months);
e.isValid() && (a = a ?? !0, l && Gd(e, Ra(e, "Month") + l * n), s && Yd(e, "Date", Ra(e, "Date") + s * n), r && e._d.setTime(e._d.valueOf() + r * n), a && z.updateOffset(e, s || l));
}
var Sw = uf(1, "add"), ww = uf(-1, "subtract");
function df(e) {
return typeof e == "string" || e instanceof String;
}
function _w(e) {
return Vt(e) || Ka(e) || df(e) || ln(e) || Cw(e) || kw(e) || e === null || e === void 0;
}
function kw(e) {
var t = Dn(e) && !ii(e), n = !1, a = [
"years",
"year",
"y",
"months",
"month",
"M",
"days",
"day",
"d",
"dates",
"date",
"D",
"hours",
"hour",
"h",
"minutes",
"minute",
"m",
"seconds",
"second",
"s",
"milliseconds",
"millisecond",
"ms"
], r, s, l = a.length;
for (r = 0; r < l; r += 1)
s = a[r], n = n || ke(e, s);
return t && n;
}
function Cw(e) {
var t = Tt(e), n = !1;
return t && (n = e.filter(function(a) {
return !ln(a) && df(e);
}).length === 0), t && n;
}
function Pw(e) {
var t = Dn(e) && !ii(e), n = !1, a = [
"sameDay",
"nextDay",
"lastDay",
"nextWeek",
"lastWeek",
"sameElse"
], r, s;
for (r = 0; r < a.length; r += 1)
s = a[r], n = n || ke(e, s);
return t && n;
}
function xw(e, t) {
var n = e.diff(t, "days", !0);
return n < -6 ? "sameElse" : n < -1 ? "lastWeek" : n < 0 ? "lastDay" : n < 1 ? "sameDay" : n < 2 ? "nextDay" : n < 7 ? "nextWeek" : "sameElse";
}
function Iw(e, t) {
arguments.length === 1 && (arguments[0] ? _w(arguments[0]) ? (e = arguments[0], t = void 0) : Pw(arguments[0]) && (t = arguments[0], e = void 0) : (e = void 0, t = void 0));
var n = e || Ee(), a = Pi(n, this).startOf("day"), r = z.calendarFormat(this, a) || "sameElse", s = t && (Qt(t[r]) ? t[r].call(this, n) : t[r]);
return this.format(
s || this.localeData().calendar(r, this, Ee(n))
);
}
function Ow() {
return new Ja(this);
}
function Tw(e, t) {
var n = Vt(e) ? e : Ee(e);
return this.isValid() && n.isValid() ? (t = xt(t) || "millisecond", t === "millisecond" ? this.valueOf() > n.valueOf() : n.valueOf() < this.clone().startOf(t).valueOf()) : !1;
}
function Vw(e, t) {
var n = Vt(e) ? e : Ee(e);
return this.isValid() && n.isValid() ? (t = xt(t) || "millisecond", t === "millisecond" ? this.valueOf() < n.valueOf() : this.clone().endOf(t).valueOf() < n.valueOf()) : !1;
}
function Aw(e, t, n, a) {
var r = Vt(e) ? e : Ee(e), s = Vt(t) ? t : Ee(t);
return this.isValid() && r.isValid() && s.isValid() ? (a = a || "()", (a[0] === "(" ? this.isAfter(r, n) : !this.isBefore(r, n)) && (a[1] === ")" ? this.isBefore(s, n) : !this.isAfter(s, n))) : !1;
}
function Ew(e, t) {
var n = Vt(e) ? e : Ee(e), a;
return this.isValid() && n.isValid() ? (t = xt(t) || "millisecond", t === "millisecond" ? this.valueOf() === n.valueOf() : (a = n.valueOf(), this.clone().startOf(t).valueOf() <= a && a <= this.clone().endOf(t).valueOf())) : !1;
}
function Dw(e, t) {
return this.isSame(e, t) || this.isAfter(e, t);
}
function Mw(e, t) {
return this.isSame(e, t) || this.isBefore(e, t);
}
function Rw(e, t, n) {
var a, r, s;
if (!this.isValid())
return NaN;
if (a = Pi(e, this), !a.isValid())
return NaN;
switch (r = (a.utcOffset() - this.utcOffset()) * 6e4, t = xt(t), t) {
case "year":
s = gr(this, a) / 12;
break;
case "month":
s = gr(this, a);
break;
case "quarter":
s = gr(this, a) / 3;
break;
case "second":
s = (this - a) / 1e3;
break;
// 1000
case "minute":
s = (this - a) / 6e4;
break;
// 1000 * 60
case "hour":
s = (this - a) / 36e5;
break;
// 1000 * 60 * 60
case "day":
s = (this - a - r) / 864e5;
break;
// 1000 * 60 * 60 * 24, negate dst
case "week":
s = (this - a - r) / 6048e5;
break;
// 1000 * 60 * 60 * 24 * 7, negate dst
default:
s = this - a;
}
return n ? s : wt(s);
}
function gr(e, t) {
if (e.date() < t.date())
return -gr(t, e);
var n = (t.year() - e.year()) * 12 + (t.month() - e.month()), a = e.clone().add(n, "months"), r, s;
return t - a < 0 ? (r = e.clone().add(n - 1, "months"), s = (t - a) / (a - r)) : (r = e.clone().add(n + 1, "months"), s = (t - a) / (r - a)), -(n + s) || 0;
}
z.defaultFormat = "YYYY-MM-DDTHH:mm:ssZ";
z.defaultFormatUtc = "YYYY-MM-DDTHH:mm:ss[Z]";
function Fw() {
return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ");
}
function Lw(e) {
if (!this.isValid())
return null;
var t = e !== !0, n = t ? this.clone().utc() : this;
return n.year() < 0 || n.year() > 9999 ? vr(
n,
t ? "YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]" : "YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"
) : Qt(Date.prototype.toISOString) ? t ? this.toDate().toISOString() : new Date(this.valueOf() + this.utcOffset() * 60 * 1e3).toISOString().replace("Z", vr(n, "Z")) : vr(
n,
t ? "YYYY-MM-DD[T]HH:mm:ss.SSS[Z]" : "YYYY-MM-DD[T]HH:mm:ss.SSSZ"
);
}
function Nw() {
if (!this.isValid())
return "moment.invalid(/* " + this._i + " */)";
var e = "moment", t = "", n, a, r, s;
return this.isLocal() || (e = this.utcOffset() === 0 ? "moment.utc" : "moment.parseZone", t = "Z"), n = "[" + e + '("]', a = 0 <= this.year() && this.year() <= 9999 ? "YYYY" : "YYYYYY", r = "-MM-DD[T]HH:mm:ss.SSS", s = t + '[")]', this.format(n + a + r + s);
}
function Bw(e) {
e || (e = this.isUtc() ? z.defaultFormatUtc : z.defaultFormat);
var t = vr(this, e);
return this.localeData().postformat(t);
}
function $w(e, t) {
return this.isValid() && (Vt(e) && e.isValid() || Ee(e).isValid()) ? Rt({ to: this, from: e }).locale(this.locale()).humanize(!t) : this.localeData().invalidDate();
}
function Uw(e) {
return this.from(Ee(), e);
}
function zw(e, t) {
return this.isValid() && (Vt(e) && e.isValid() || Ee(e).isValid()) ? Rt({ from: this, to: e }).locale(this.locale()).humanize(!t) : this.localeData().invalidDate();
}
function Hw(e) {
return this.to(Ee(), e);
}
function ff(e) {
var t;
return e === void 0 ? this._locale._abbr : (t = mn(e), t != null && (this._locale = t), this);
}
var hf = Pt(
"moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",
function(e) {
return e === void 0 ? this.localeData() : this.locale(e);
}
);
function mf() {
return this._locale;
}
var Er = 1e3, Kn = 60 * Er, Dr = 60 * Kn, vf = (365 * 400 + 97) * 24 * Dr;
function Jn(e, t) {
return (e % t + t) % t;
}
function yf(e, t, n) {
return e < 100 && e >= 0 ? new Date(e + 400, t, n) - vf : new Date(e, t, n).valueOf();
}
function gf(e, t, n) {
return e < 100 && e >= 0 ? Date.UTC(e + 400, t, n) - vf : Date.UTC(e, t, n);
}
function Yw(e) {
var t, n;
if (e = xt(e), e === void 0 || e === "millisecond" || !this.isValid())
return this;
switch (n = this._isUTC ? gf : yf, e) {
case "year":
t = n(this.year(), 0, 1);
break;
case "quarter":
t = n(
this.year(),
this.month() - this.month() % 3,
1
);
break;
case "month":
t = n(this.year(), this.month(), 1);
break;
case "week":
t = n(
this.year(),
this.month(),
this.date() - this.weekday()
);
break;
case "isoWeek":
t = n(
this.year(),
this.month(),
this.date() - (this.isoWeekday() - 1)
);
break;
case "day":
case "date":
t = n(this.year(), this.month(), this.date());
break;
case "hour":
t = this._d.valueOf(), t -= Jn(
t + (this._isUTC ? 0 : this.utcOffset() * Kn),
Dr
);
break;
case "minute":
t = this._d.valueOf(), t -= Jn(t, Kn);
break;
case "second":
t = this._d.valueOf(), t -= Jn(t, Er);
break;
}
return this._d.setTime(t), z.updateOffset(this, !0), this;
}
function jw(e) {
var t, n;
if (e = xt(e), e === void 0 || e === "millisecond" || !this.isValid())
return this;
switch (n = this._isUTC ? gf : yf, e) {
case "year":
t = n(this.year() + 1, 0, 1) - 1;
break;
case "quarter":
t = n(
this.year(),
this.month() - this.month() % 3 + 3,
1
) - 1;
break;
case "month":
t = n(this.year(), this.month() + 1, 1) - 1;
break;
case "week":
t = n(
this.year(),
this.month(),
this.date() - this.weekday() + 7
) - 1;
break;
case "isoWeek":
t = n(
this.year(),
this.month(),
this.date() - (this.isoWeekday() - 1) + 7
) - 1;
break;
case "day":
case "date":
t = n(this.year(), this.month(), this.date() + 1) - 1;
break;
case "hour":
t = this._d.valueOf(), t += Dr - Jn(
t + (this._isUTC ? 0 : this.utcOffset() * Kn),
Dr
) - 1;
break;
case "minute":
t = this._d.valueOf(), t += Kn - Jn(t, Kn) - 1;
break;
case "second":
t = this._d.valueOf(), t += Er - Jn(t, Er) - 1;
break;
}
return this._d.setTime(t), z.updateOffset(this, !0), this;
}
function Ww() {
return this._d.valueOf() - (this._offset || 0) * 6e4;
}
function Gw() {
return Math.floor(this.valueOf() / 1e3);
}
function Qw() {
return new Date(this.valueOf());
}
function qw() {
var e = this;
return [
e.year(),
e.month(),
e.date(),
e.hour(),
e.minute(),
e.second(),
e.millisecond()
];
}
function Kw() {
var e = this;
return {
years: e.year(),
months: e.month(),
date: e.date(),
hours: e.hours(),
minutes: e.minutes(),
seconds: e.seconds(),
milliseconds: e.milliseconds()
};
}
function Jw() {
return this.isValid() ? this.toISOString() : null;
}
function Zw() {
return oi(this);
}
function Xw() {
return bn({}, de(this));
}
function e_() {
return de(this).overflow;
}
function t_() {
return {
input: this._i,
format: this._f,
locale: this._locale,
isUTC: this._isUTC,
strict: this._strict
};
}
Z("N", 0, 0, "eraAbbr");
Z("NN", 0, 0, "eraAbbr");
Z("NNN", 0, 0, "eraAbbr");
Z("NNNN", 0, 0, "eraName");
Z("NNNNN", 0, 0, "eraNarrow");
Z("y", ["y", 1], "yo", "eraYear");
Z("y", ["yy", 2], 0, "eraYear");
Z("y", ["yyy", 3], 0, "eraYear");
Z("y", ["yyyy", 4], 0, "eraYear");
W("N", xi);
W("NN", xi);
W("NNN", xi);
W("NNNN", f_);
W("NNNNN", h_);
Oe(
["N", "NN", "NNN", "NNNN", "NNNNN"],
function(e, t, n, a) {
var r = n._locale.erasParse(e, a, n._strict);
r ? de(n).era = r : de(n).invalidEra = e;
}
);
W("y", ua);
W("yy", ua);
W("yyy", ua);
W("yyyy", ua);
W("yo", m_);
Oe(["y", "yy", "yyy", "yyyy"], tt);
Oe(["yo"], function(e, t, n, a) {
var r;
n._locale._eraYearOrdinalRegex && (r = e.match(n._locale._eraYearOrdinalRegex)), n._locale.eraYearOrdinalParse ? t[tt] = n._locale.eraYearOrdinalParse(e, r) : t[tt] = parseInt(e, 10);
});
function n_(e, t) {
var n, a, r, s = this._eras || mn("en")._eras;
for (n = 0, a = s.length; n < a; ++n) {
switch (typeof s[n].since) {
case "string":
r = z(s[n].since).startOf("day"), s[n].since = r.valueOf();
break;
}
switch (typeof s[n].until) {
case "undefined":
s[n].until = 1 / 0;
break;
case "string":
r = z(s[n].until).startOf("day").valueOf(), s[n].until = r.valueOf();
break;
}
}
return s;
}
function a_(e, t, n) {
var a, r, s = this.eras(), l, i, o;
for (e = e.toUpperCase(), a = 0, r = s.length; a < r; ++a)
if (l = s[a].name.toUpperCase(), i = s[a].abbr.toUpperCase(), o = s[a].narrow.toUpperCase(), n)
switch (t) {
case "N":
case "NN":
case "NNN":
if (i === e)
return s[a];
break;
case "NNNN":
if (l === e)
return s[a];
break;
case "NNNNN":
if (o === e)
return s[a];
break;
}
else if ([l, i, o].indexOf(e) >= 0)
return s[a];
}
function r_(e, t) {
var n = e.since <= e.until ? 1 : -1;
return t === void 0 ? z(e.since).year() : z(e.since).year() + (t - e.offset) * n;
}
function s_() {
var e, t, n, a = this.localeData().eras();
for (e = 0, t = a.length; e < t; ++e)
if (n = this.clone().startOf("day").valueOf(), a[e].since <= n && n <= a[e].until || a[e].until <= n && n <= a[e].since)
return a[e].name;
return "";
}
function l_() {
var e, t, n, a = this.localeData().eras();
for (e = 0, t = a.length; e < t; ++e)
if (n = this.clone().startOf("day").valueOf(), a[e].since <= n && n <= a[e].until || a[e].until <= n && n <= a[e].since)
return a[e].narrow;
return "";
}
function i_() {
var e, t, n, a = this.localeData().eras();
for (e = 0, t = a.length; e < t; ++e)
if (n = this.clone().startOf("day").valueOf(), a[e].since <= n && n <= a[e].until || a[e].until <= n && n <= a[e].since)
return a[e].abbr;
return "";
}
function o_() {
var e, t, n, a, r = this.localeData().eras();
for (e = 0, t = r.length; e < t; ++e)
if (n = r[e].since <= r[e].until ? 1 : -1, a = this.clone().startOf("day").valueOf(), r[e].since <= a && a <= r[e].until || r[e].until <= a && a <= r[e].since)
return (this.year() - z(r[e].since).year()) * n + r[e].offset;
return this.year();
}
function u_(e) {
return ke(this, "_erasNameRegex") || Ii.call(this), e ? this._erasNameRegex : this._erasRegex;
}
function c_(e) {
return ke(this, "_erasAbbrRegex") || Ii.call(this), e ? this._erasAbbrRegex : this._erasRegex;
}
function d_(e) {
return ke(this, "_erasNarrowRegex") || Ii.call(this), e ? this._erasNarrowRegex : this._erasRegex;
}
function xi(e, t) {
return t.erasAbbrRegex(e);
}
function f_(e, t) {
return t.erasNameRegex(e);
}
function h_(e, t) {
return t.erasNarrowRegex(e);
}
function m_(e, t) {
return t._eraYearOrdinalRegex || ua;
}
function Ii() {
var e = [], t = [], n = [], a = [], r, s, l, i, o, u = this.eras();
for (r = 0, s = u.length; r < s; ++r)
l = nn(u[r].name), i = nn(u[r].abbr), o = nn(u[r].narrow), t.push(l), e.push(i), n.push(o), a.push(l), a.push(i), a.push(o);
this._erasRegex = new RegExp("^(" + a.join("|") + ")", "i"), this._erasNameRegex = new RegExp("^(" + t.join("|") + ")", "i"), this._erasAbbrRegex = new RegExp("^(" + e.join("|") + ")", "i"), this._erasNarrowRegex = new RegExp(
"^(" + n.join("|") + ")",
"i"
);
}
Z(0, ["gg", 2], 0, function() {
return this.weekYear() % 100;
});
Z(0, ["GG", 2], 0, function() {
return this.isoWeekYear() % 100;
});
function ms(e, t) {
Z(0, [e, e.length], 0, t);
}
ms("gggg", "weekYear");
ms("ggggg", "weekYear");
ms("GGGG", "isoWeekYear");
ms("GGGGG", "isoWeekYear");
W("G", us);
W("g", us);
W("GG", Me, St);
W("gg", Me, St);
W("GGGG", mi, hi);
W("gggg", mi, hi);
W("GGGGG", os, ls);
W("ggggg", os, ls);
Xa(
["gggg", "ggggg", "GGGG", "GGGGG"],
function(e, t, n, a) {
t[a.substr(0, 2)] = ye(e);
}
);
Xa(["gg", "GG"], function(e, t, n, a) {
t[a] = z.parseTwoDigitYear(e);
});
function v_(e) {
return bf.call(
this,
e,
this.week(),
this.weekday() + this.localeData()._week.dow,
this.localeData()._week.dow,
this.localeData()._week.doy
);
}
function y_(e) {
return bf.call(
this,
e,
this.isoWeek(),
this.isoWeekday(),
1,
4
);
}
function g_() {
return an(this.year(), 1, 4);
}
function b_() {
return an(this.isoWeekYear(), 1, 4);
}
function p_() {
var e = this.localeData()._week;
return an(this.year(), e.dow, e.doy);
}
function S_() {
var e = this.localeData()._week;
return an(this.weekYear(), e.dow, e.doy);
}
function bf(e, t, n, a, r) {
var s;
return e == null ? La(this, a, r).year : (s = an(e, a, r), t > s && (t = s), w_.call(this, e, t, n, a, r));
}
function w_(e, t, n, a, r) {
var s = Kd(e, t, n, a, r), l = Fa(s.year, 0, s.dayOfYear);
return this.year(l.getUTCFullYear()), this.month(l.getUTCMonth()), this.date(l.getUTCDate()), this;
}
Z("Q", 0, "Qo", "quarter");
W("Q", Bd);
Oe("Q", function(e, t) {
t[en] = (ye(e) - 1) * 3;
});
function __(e) {
return e == null ? Math.ceil((this.month() + 1) / 3) : this.month((e - 1) * 3 + this.month() % 3);
}
Z("D", ["DD", 2], "Do", "date");
W("D", Me, ca);
W("DD", Me, St);
W("Do", function(e, t) {
return e ? t._dayOfMonthOrdinalParse || t._ordinalParse : t._dayOfMonthOrdinalParseLenient;
});
Oe(["D", "DD"], Nt);
Oe("Do", function(e, t) {
t[Nt] = ye(e.match(Me)[0]);
});
var pf = da("Date", !0);
Z("DDD", ["DDDD", 3], "DDDo", "dayOfYear");
W("DDD", is);
W("DDDD", $d);
Oe(["DDD", "DDDD"], function(e, t, n) {
n._dayOfYear = ye(e);
});
function k_(e) {
var t = Math.round(
(this.clone().startOf("day") - this.clone().startOf("year")) / 864e5
) + 1;
return e == null ? t : this.add(e - t, "d");
}
Z("m", ["mm", 2], 0, "minute");
W("m", Me, vi);
W("mm", Me, St);
Oe(["m", "mm"], It);
var C_ = da("Minutes", !1);
Z("s", ["ss", 2], 0, "second");
W("s", Me, vi);
W("ss", Me, St);
Oe(["s", "ss"], tn);
var P_ = da("Seconds", !1);
Z("S", 0, 0, function() {
return ~~(this.millisecond() / 100);
});
Z(0, ["SS", 2], 0, function() {
return ~~(this.millisecond() / 10);
});
Z(0, ["SSS", 3], 0, "millisecond");
Z(0, ["SSSS", 4], 0, function() {
return this.millisecond() * 10;
});
Z(0, ["SSSSS", 5], 0, function() {
return this.millisecond() * 100;
});
Z(0, ["SSSSSS", 6], 0, function() {
return this.millisecond() * 1e3;
});
Z(0, ["SSSSSSS", 7], 0, function() {
return this.millisecond() * 1e4;
});
Z(0, ["SSSSSSSS", 8], 0, function() {
return this.millisecond() * 1e5;
});
Z(0, ["SSSSSSSSS", 9], 0, function() {
return this.millisecond() * 1e6;
});
W("S", is, Bd);
W("SS", is, St);
W("SSS", is, $d);
var pn, Sf;
for (pn = "SSSS"; pn.length <= 9; pn += "S")
W(pn, ua);
function x_(e, t) {
t[Vn] = ye(("0." + e) * 1e3);
}
for (pn = "S"; pn.length <= 9; pn += "S")
Oe(pn, x_);
Sf = da("Milliseconds", !1);
Z("z", 0, 0, "zoneAbbr");
Z("zz", 0, 0, "zoneName");
function I_() {
return this._isUTC ? "UTC" : "";
}
function O_() {
return this._isUTC ? "Coordinated Universal Time" : "";
}
var F = Ja.prototype;
F.add = Sw;
F.calendar = Iw;
F.clone = Ow;
F.diff = Rw;
F.endOf = jw;
F.format = Bw;
F.from = $w;
F.fromNow = Uw;
F.to = zw;
F.toNow = Hw;
F.get = Np;
F.invalidAt = e_;
F.isAfter = Tw;
F.isBefore = Vw;
F.isBetween = Aw;
F.isSame = Ew;
F.isSameOrAfter = Dw;
F.isSameOrBefore = Mw;
F.isValid = Zw;
F.lang = hf;
F.locale = ff;
F.localeData = mf;
F.max = ZS;
F.min = JS;
F.parsingFlags = Xw;
F.set = Bp;
F.startOf = Yw;
F.subtract = ww;
F.toArray = qw;
F.toObject = Kw;
F.toDate = Qw;
F.toISOString = Lw;
F.inspect = Nw;
typeof Symbol < "u" && Symbol.for != null && (F[Symbol.for("nodejs.util.inspect.custom")] = function() {
return "Moment<" + this.format() + ">";
});
F.toJSON = Jw;
F.toString = Fw;
F.unix = Gw;
F.valueOf = Ww;
F.creationData = t_;
F.eraName = s_;
F.eraNarrow = l_;
F.eraAbbr = i_;
F.eraYear = o_;
F.year = Hd;
F.isLeapYear = Lp;
F.weekYear = v_;
F.isoWeekYear = y_;
F.quarter = F.quarters = __;
F.month = Qd;
F.daysInMonth = Qp;
F.week = F.weeks = nS;
F.isoWeek = F.isoWeeks = aS;
F.weeksInYear = p_;
F.weeksInWeekYear = S_;
F.isoWeeksInYear = g_;
F.isoWeeksInISOWeekYear = b_;
F.date = pf;
F.day = F.days = yS;
F.weekday = gS;
F.isoWeekday = bS;
F.dayOfYear = k_;
F.hour = F.hours = PS;
F.minute = F.minutes = C_;
F.second = F.seconds = P_;
F.millisecond = F.milliseconds = Sf;
F.utcOffset = iw;
F.utc = uw;
F.local = cw;
F.parseZone = dw;
F.hasAlignedHourOffset = fw;
F.isDST = hw;
F.isLocal = vw;
F.isUtcOffset = yw;
F.isUtc = of;
F.isUTC = of;
F.zoneAbbr = I_;
F.zoneName = O_;
F.dates = Pt(
"dates accessor is deprecated. Use date instead.",
pf
);
F.months = Pt(
"months accessor is deprecated. Use month instead",
Qd
);
F.years = Pt(
"years accessor is deprecated. Use year instead",
Hd
);
F.zone = Pt(
"moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",
ow
);
F.isDSTShifted = Pt(
"isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",
mw
);
function T_(e) {
return Ee(e * 1e3);
}
function V_() {
return Ee.apply(null, arguments).parseZone();
}
function wf(e) {
return e;
}
var Ce = ci.prototype;
Ce.calendar = vp;
Ce.longDateFormat = pp;
Ce.invalidDate = wp;
Ce.ordinal = Cp;
Ce.preparse = wf;
Ce.postformat = wf;
Ce.relativeTime = xp;
Ce.pastFuture = Ip;
Ce.set = hp;
Ce.eras = n_;
Ce.erasParse = a_;
Ce.erasConvertYear = r_;
Ce.erasAbbrRegex = c_;
Ce.erasNameRegex = u_;
Ce.erasNarrowRegex = d_;
Ce.months = Yp;
Ce.monthsShort = jp;
Ce.monthsParse = Gp;
Ce.monthsRegex = Kp;
Ce.monthsShortRegex = qp;
Ce.week = Zp;
Ce.firstDayOfYear = tS;
Ce.firstDayOfWeek = eS;
Ce.weekdays = dS;
Ce.weekdaysMin = hS;
Ce.weekdaysShort = fS;
Ce.weekdaysParse = vS;
Ce.weekdaysRegex = pS;
Ce.weekdaysShortRegex = SS;
Ce.weekdaysMinRegex = wS;
Ce.isPM = kS;
Ce.meridiem = xS;
function Mr(e, t, n, a) {
var r = mn(), s = Gt().set(a, t);
return r[n](s, e);
}
function _f(e, t, n) {
if (ln(e) && (t = e, e = void 0), e = e || "", t != null)
return Mr(e, t, n, "month");
var a, r = [];
for (a = 0; a < 12; a++)
r[a] = Mr(e, a, n, "month");
return r;
}
function Oi(e, t, n, a) {
typeof e == "boolean" ? (ln(t) && (n = t, t = void 0), t = t || "") : (t = e, n = t, e = !1, ln(t) && (n = t, t = void 0), t = t || "");
var r = mn(), s = e ? r._week.dow : 0, l, i = [];
if (n != null)
return Mr(t, (n + s) % 7, a, "day");
for (l = 0; l < 7; l++)
i[l] = Mr(t, (l + s) % 7, a, "day");
return i;
}
function A_(e, t) {
return _f(e, t, "months");
}
function E_(e, t) {
return _f(e, t, "monthsShort");
}
function D_(e, t, n) {
return Oi(e, t, n, "weekdays");
}
function M_(e, t, n) {
return Oi(e, t, n, "weekdaysShort");
}
function R_(e, t, n) {
return Oi(e, t, n, "weekdaysMin");
}
wn("en", {
eras: [
{
since: "0001-01-01",
until: 1 / 0,
offset: 1,
name: "Anno Domini",
narrow: "AD",
abbr: "AD"
},
{
since: "0000-12-31",
until: -1 / 0,
offset: 1,
name: "Before Christ",
narrow: "BC",
abbr: "BC"
}
],
dayOfMonthOrdinalParse: /\d{1,2}(th|st|nd|rd)/,
ordinal: function(e) {
var t = e % 10, n = ye(e % 100 / 10) === 1 ? "th" : t === 1 ? "st" : t === 2 ? "nd" : t === 3 ? "rd" : "th";
return e + n;
}
});
z.lang = Pt(
"moment.lang is deprecated. Use moment.locale instead.",
wn
);
z.langData = Pt(
"moment.langData is deprecated. Use moment.localeData instead.",
mn
);
var Kt = Math.abs;
function F_() {
var e = this._data;
return this._milliseconds = Kt(this._milliseconds), this._days = Kt(this._days), this._months = Kt(this._months), e.milliseconds = Kt(e.milliseconds), e.seconds = Kt(e.seconds), e.minutes = Kt(e.minutes), e.hours = Kt(e.hours), e.months = Kt(e.months), e.years = Kt(e.years), this;
}
function kf(e, t, n, a) {
var r = Rt(t, n);
return e._milliseconds += a * r._milliseconds, e._days += a * r._days, e._months += a * r._months, e._bubble();
}
function L_(e, t) {
return kf(this, e, t, 1);
}
function N_(e, t) {
return kf(this, e, t, -1);
}
function qo(e) {
return e < 0 ? Math.floor(e) : Math.ceil(e);
}
function B_() {
var e = this._milliseconds, t = this._days, n = this._months, a = this._data, r, s, l, i, o;
return e >= 0 && t >= 0 && n >= 0 || e <= 0 && t <= 0 && n <= 0 || (e += qo(wl(n) + t) * 864e5, t = 0, n = 0), a.milliseconds = e % 1e3, r = wt(e / 1e3), a.seconds = r % 60, s = wt(r / 60), a.minutes = s % 60, l = wt(s / 60), a.hours = l % 24, t += wt(l / 24), o = wt(Cf(t)), n += o, t -= qo(wl(o)), i = wt(n / 12), n %= 12, a.days = t, a.months = n, a.years = i, this;
}
function Cf(e) {
return e * 4800 / 146097;
}
function wl(e) {
return e * 146097 / 4800;
}
function $_(e) {
if (!this.isValid())
return NaN;
var t, n, a = this._milliseconds;
if (e = xt(e), e === "month" || e === "quarter" || e === "year")
switch (t = this._days + a / 864e5, n = this._months + Cf(t), e) {
case "month":
return n;
case "quarter":
return n / 3;
case "year":
return n / 12;
}
else
switch (t = this._days + Math.round(wl(this._months)), e) {
case "week":
return t / 7 + a / 6048e5;
case "day":
return t + a / 864e5;
case "hour":
return t * 24 + a / 36e5;
case "minute":
return t * 1440 + a / 6e4;
case "second":
return t * 86400 + a / 1e3;
// Math.floor prevents floating point math errors here
case "millisecond":
return Math.floor(t * 864e5) + a;
default:
throw new Error("Unknown unit " + e);
}
}
function vn(e) {
return function() {
return this.as(e);
};
}
var Pf = vn("ms"), U_ = vn("s"), z_ = vn("m"), H_ = vn("h"), Y_ = vn("d"), j_ = vn("w"), W_ = vn("M"), G_ = vn("Q"), Q_ = vn("y"), q_ = Pf;
function K_() {
return Rt(this);
}
function J_(e) {
return e = xt(e), this.isValid() ? this[e + "s"]() : NaN;
}
function zn(e) {
return function() {
return this.isValid() ? this._data[e] : NaN;
};
}
var Z_ = zn("milliseconds"), X_ = zn("seconds"), e0 = zn("minutes"), t0 = zn("hours"), n0 = zn("days"), a0 = zn("months"), r0 = zn("years");
function s0() {
return wt(this.days() / 7);
}
var Jt = Math.round, Qn = {
ss: 44,
// a few seconds to seconds
s: 45,
// seconds to minute
m: 45,
// minutes to hour
h: 22,
// hours to day
d: 26,
// days to month/week
w: null,
// weeks to month
M: 11
// months to year
};
function l0(e, t, n, a, r) {
return r.relativeTime(t || 1, !!n, e, a);
}
function i0(e, t, n, a) {
var r = Rt(e).abs(), s = Jt(r.as("s")), l = Jt(r.as("m")), i = Jt(r.as("h")), o = Jt(r.as("d")), u = Jt(r.as("M")), c = Jt(r.as("w")), d = Jt(r.as("y")), f = s <= n.ss && ["s", s] || s < n.s && ["ss", s] || l <= 1 && ["m"] || l < n.m && ["mm", l] || i <= 1 && ["h"] || i < n.h && ["hh", i] || o <= 1 && ["d"] || o < n.d && ["dd", o];
return n.w != null && (f = f || c <= 1 && ["w"] || c < n.w && ["ww", c]), f = f || u <= 1 && ["M"] || u < n.M && ["MM", u] || d <= 1 && ["y"] || ["yy", d], f[2] = t, f[3] = +e > 0, f[4] = a, l0.apply(null, f);
}
function o0(e) {
return e === void 0 ? Jt : typeof e == "function" ? (Jt = e, !0) : !1;
}
function u0(e, t) {
return Qn[e] === void 0 ? !1 : t === void 0 ? Qn[e] : (Qn[e] = t, e === "s" && (Qn.ss = t - 1), !0);
}
function c0(e, t) {
if (!this.isValid())
return this.localeData().invalidDate();
var n = !1, a = Qn, r, s;
return typeof e == "object" && (t = e, e = !1), typeof e == "boolean" && (n = e), typeof t == "object" && (a = Object.assign({}, Qn, t), t.s != null && t.ss == null && (a.ss = t.s - 1)), r = this.localeData(), s = i0(this, !n, a, r), n && (s = r.pastFuture(+this, s)), r.postformat(s);
}
var Bs = Math.abs;
function jn(e) {
return (e > 0) - (e < 0) || +e;
}
function vs() {
if (!this.isValid())
return this.localeData().invalidDate();
var e = Bs(this._milliseconds) / 1e3, t = Bs(this._days), n = Bs(this._months), a, r, s, l, i = this.asSeconds(), o, u, c, d;
return i ? (a = wt(e / 60), r = wt(a / 60), e %= 60, a %= 60, s = wt(n / 12), n %= 12, l = e ? e.toFixed(3).replace(/\.?0+$/, "") : "", o = i < 0 ? "-" : "", u = jn(this._months) !== jn(i) ? "-" : "", c = jn(this._days) !== jn(i) ? "-" : "", d = jn(this._milliseconds) !== jn(i) ? "-" : "", o + "P" + (s ? u + s + "Y" : "") + (n ? u + n + "M" : "") + (t ? c + t + "D" : "") + (r || a || e ? "T" : "") + (r ? d + r + "H" : "") + (a ? d + a + "M" : "") + (e ? d + l + "S" : "")) : "P0D";
}
var we = hs.prototype;
we.isValid = aw;
we.abs = F_;
we.add = L_;
we.subtract = N_;
we.as = $_;
we.asMilliseconds = Pf;
we.asSeconds = U_;
we.asMinutes = z_;
we.asHours = H_;
we.asDays = Y_;
we.asWeeks = j_;
we.asMonths = W_;
we.asQuarters = G_;
we.asYears = Q_;
we.valueOf = q_;
we._bubble = B_;
we.clone = K_;
we.get = J_;
we.milliseconds = Z_;
we.seconds = X_;
we.minutes = e0;
we.hours = t0;
we.days = n0;
we.weeks = s0;
we.months = a0;
we.years = r0;
we.humanize = c0;
we.toISOString = vs;
we.toString = vs;
we.toJSON = vs;
we.locale = ff;
we.localeData = mf;
we.toIsoString = Pt(
"toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",
vs
);
we.lang = hf;
Z("X", 0, 0, "unix");
Z("x", 0, 0, "valueOf");
W("x", us);
W("X", Ap);
Oe("X", function(e, t, n) {
n._d = new Date(parseFloat(e) * 1e3);
});
Oe("x", function(e, t, n) {
n._d = new Date(ye(e));
});
//! moment.js
z.version = "2.30.1";
dp(Ee);
z.fn = F;
z.min = XS;
z.max = ew;
z.now = tw;
z.utc = Gt;
z.unix = T_;
z.months = A_;
z.isDate = Ka;
z.locale = wn;
z.invalid = ss;
z.duration = Rt;
z.isMoment = Vt;
z.weekdays = D_;
z.parseZone = V_;
z.localeData = mn;
z.isDuration = yr;
z.monthsShort = E_;
z.weekdaysMin = R_;
z.defineLocale = Si;
z.updateLocale = VS;
z.locales = AS;
z.weekdaysShort = M_;
z.normalizeUnits = xt;
z.relativeTimeRounding = o0;
z.relativeTimeThreshold = u0;
z.calendarFormat = xw;
z.prototype = F;
z.HTML5_FMT = {
DATETIME_LOCAL: "YYYY-MM-DDTHH:mm",
// <input type="datetime-local" />
DATETIME_LOCAL_SECONDS: "YYYY-MM-DDTHH:mm:ss",
// <input type="datetime-local" step="1" />
DATETIME_LOCAL_MS: "YYYY-MM-DDTHH:mm:ss.SSS",
// <input type="datetime-local" step="0.001" />
DATE: "YYYY-MM-DD",
// <input type="date" />
TIME: "HH:mm",
// <input type="time" />
TIME_SECONDS: "HH:mm:ss",
// <input type="time" step="1" />
TIME_MS: "HH:mm:ss.SSS",
// <input type="time" step="0.001" />
WEEK: "GGGG-[W]WW",
// <input type="week" />
MONTH: "YYYY-MM"
// <input type="month" />
};
function d0(e) {
console.debug("[info] use calling 'launchFileDownload()' method");
const t = e?.searchResults;
if (!(e && t.length > 0))
return;
const n = "-MeSH";
let a;
const r = e.searchQuery;
r.searchEntityType === ze.comp_to_mesh ? r.searchSelectorType === me.pubchem_id ? a = "CID" + r.searchEntityQuery + n : a = r.searchEntityQuery + n : a = r.searchEntityQuery + "-" + r.searchSelectorType.slice(0, -3);
const s = Object.keys(t[0]).map((i) => `"${i}"`).join(","), l = t.map(
(i) => Object.values(i).map((o) => `${o}`.replace('"', '""')).map((o) => `"${o}"`).join(",")
// values separator: comma
).join(`
`);
f0(`${s}
${l}`, a);
}
function f0(e, t = "data") {
const n = new Blob(["\uFEFF" + e], {
type: "text/csv;charset=utf-8;"
}), a = document.createElement("a"), r = URL.createObjectURL(n);
navigator.userAgent.indexOf("Safari") != -1 && navigator.userAgent.indexOf("Chrome") == -1 && a.setAttribute("target", "_blank"), a.setAttribute("href", r);
const l = z(/* @__PURE__ */ new Date()).format("YYYY-MM-DD_hh-mm");
a.setAttribute("download", l + "_FORUM-DC_" + t + ".csv"), a.style.visibility = "hidden", document.body.appendChild(a), a.click(), document.body.removeChild(a);
}
const h0 = Rr({
name: "MthForumResultsDisplay",
components: {
MthForumLiteratureDisplay: Dd
},
props: ["search-results"],
watch: {
searchResults: function(e, t) {
console.debug("Prop changed: ", e, " | was: ", t), this.inputSearch = e, this.runSearch(e);
}
},
setup() {
let e;
const t = R(!1), n = R(!1), a = R(!1), r = R(!1), s = R("#"), l = R(""), i = R(-1), o = R(""), u = R(0), c = [
"name",
"root",
"qvalue",
"oddratio",
"papers",
"score"
], d = [], f = [], v = R(!1), m = R(!1), y = R(""), h = R([]), b = R();
return {
endpointSearchResults: e,
display_loading_div: t,
display_results_div: n,
display_noresults_div: a,
result_found: r,
result_link: s,
result_label: l,
result_count: i,
result_identifier: o,
papers_count: u,
displayedColumns: c,
raw_res: f,
showDialog: v,
enablePapersLink: m,
dialSearchType: R(""),
dialSearchID: R(""),
dialItemId: R(""),
// data-table
filter: y,
headers: h,
dataSource: d,
inputSearch: b
};
},
mounted() {
const e = Pl();
if (e.get("dial-search-type") && e.get("dial-search-id") && e.get("dial-item-id")) {
this.result_identifier = e.get("dial-search-id");
const t = e.get("dial-item-id");
this.openPapersModal(!0, t);
}
},
methods: {
runSearch(e) {
this.headers = [], this.dataSource = [], this.raw_res = [], this.display_loading_div = !0, this.display_results_div = !1, this.display_noresults_div = !1, this.enablePapersLink = e?.searchQuery?.searchSelectorType == me.pubchem_id && e?.searchQuery?.searchEntityType == ze.comp_to_mesh, this.endpointSearchResults = e, this.endpointSearchResults && (this.result_found = !1, this.endpointSearchResults.searchQuery.isEmpty() || this.endpointSearchResults.getAPIdata().then((t) => {
this.display_loading_div = !1, this.display_results_div = t.searchResults.data.length > 0, this.display_noresults_div = !this.display_results_div;
const n = t.searchResults;
this.result_count = n.data.length, this.result_count === 0 ? this.display_noresults_div = !0 : (this.result_found = !0, this.updateLink(), this.endpointSearchResults.searchResults = n.data, console.log(
"[debug]",
"before call updateDataTable",
"this.endpointSearchResults",
this.endpointSearchResults
), this.updateDataTable(this.endpointSearchResults));
}));
},
updateLink() {
switch (this.endpointSearchResults.searchQuery.searchEntityType) {
case ze.comp_to_mesh: {
switch (this.endpointSearchResults.searchQuery.searchSelectorType) {
case me.pubchem_id: {
this.result_link = "https://pubchem.ncbi.nlm.nih.gov/compound/";
break;
}
case me.chemont_id: {
this.result_link = "http://classyfire.wishartlab.com/tax_nodes/";
break;
}
case me.chebi_id: {
this.result_link = "https://www.ebi.ac.uk/chebi/searchId.do?chebiId=";
break;
}
case me.pubchem_fuzzy_id: {
this.result_link = "https://pubchem.ncbi.nlm.nih.gov/compound/";
break;
}
}
this.result_link += this.endpointSearchResults.searchQuery.searchEntityQuery, this.getSpecificLabel(
this.endpointSearchResults.searchQuery.searchEntityQuery,
this.endpointSearchResults.searchQuery.searchSelectorType
).then((e) => {
console.debug("[debug] label found " + e), this.result_label = e;
});
break;
}
case ze.mesh_to_comp: {
this.result_link = "https://meshb.nlm.nih.gov/record/ui?ui=" + this.endpointSearchResults.searchQuery.searchEntityQuery, this.getSpecificLabel(
this.endpointSearchResults.searchQuery.searchEntityQuery,
me.mesh_id
).then((e) => {
console.debug("[debug] label found " + e), this.result_label = e;
});
break;
}
default:
console.debug("[debug] label not found"), this.result_link = "#", this.result_found = !1;
}
this.result_identifier = this.endpointSearchResults.searchQuery.searchEntityQuery, this.result_found = !0;
},
/**
* ASYNC: Function to get the data of a specific label
* Returns the label (or "ID(id)") in a Promise
* @param id ID of label to get (MeSH ID, Pubchem CID, Chemont ID, Chebi ID)
* @param s Type of label to get (MeSH, Pubchem, Chemont, Chebi)
*/
async getSpecificLabel(e, t) {
const n = new Cm();
return new Promise((a, r) => {
let s = "ID(" + e + ")";
switch (t) {
// Get Label of a MeSH ID
case me.mesh_id: {
n.meshLabelIdMeshGet(e).then((l) => {
const i = l.data;
i.length > 0 && (s = i[0].name), a(s);
});
break;
}
// Get Label of a Pubchem CID
case me.pubchem_id: {
n.pubchemLabelIdPubchemGet(+e).then((l) => {
const i = l.data;
i.length > 0 && (s = i[0].name), a(s);
});
break;
}
// Get Label of a Chemont ID
case me.chemont_id: {
n.chemontLabelIdChemontGet(e).then((l) => {
const i = l.data;
i.length > 0 && (s = i[0].name), a(s);
});
break;
}
// Get Label of a Chebi ID
case me.chebi_id: {
n.chebiLabelIdChebiGet(e).then((l) => {
const i = l.data;
i.length > 0 && (s = i[0].name), a(s);
});
break;
}
// Error case
default: {
console.debug("Error: fetching data from API (400 invalid request type)"), r(this);
break;
}
}
});
},
updateDataTable(e) {
console.debug("[debug] display update in progress");
let t = this.identifyIdType(), n = [];
if (this.raw_res = e.searchResults, e.searchResults.forEach((a) => {
let r = a, s = this.identifyIdLabelRow(t, r), l = s[0], i = s[1];
i == null && (i = "ID(" + l + ")"), r !== void 0 && n.push(
new cp(
l,
i,
// name (request for label needed)
this.constructURL(t, l),
// compound url
r.tree_root,
// tree root
r.tree_concat,
// MeSH tree Tree-Numbers
+(+r.q_value).toExponential(4),
// pvalue
parseFloat(r.odds_ratio).toFixed(2),
// oddratio
+r.COOC,
// papers
+r.n_weak
// score
)
);
}), this.headers = this.inputSearch?.searchQuery?.searchEntityType == ze.comp_to_mesh ? (
//
[
{
title: "Name",
align: "start",
key: "name",
sortable: !0
},
{
title: "MeSH root",
key: "root",
sortable: !0
},
{ title: "q.value", key: "qvalue", sortable: !0 },
{ title: "Odd radio", key: "oddratio", sortable: !0 },
{ title: "Papers", key: "papers", sortable: !0 },
{ title: "Weakness", key: "score", sortable: !0 }
]
) : (
//
[
{
title: "Name",
align: "start",
key: "name",
sortable: !0
},
// no mesh root
{ title: "q.value", key: "qvalue", sortable: !0 },
{ title: "Odd radio", key: "oddratio", sortable: !0 },
{ title: "Papers", key: "papers", sortable: !0 },
{ title: "Weakness", key: "score", sortable: !0 }
]
), this.dataSource = n, console.debug("[debug] display update done"), this.papers_count = 0, e.searchResults.length > 0) {
const r = e.searchResults[0];
r.hasOwnProperty("TOTAL_PMID_CID") && (this.papers_count = +(r?.TOTAL_PMID_CID ?? 0)), r.hasOwnProperty("TOTAL_PMID_CHEBI") && (this.papers_count = +(r?.TOTAL_PMID_CHEBI ?? 0)), r.hasOwnProperty("TOTAL_PMID_CHEMONT") && (this.papers_count = +(r?.TOTAL_PMID_CHEMONT ?? 0));
}
},
constructURL(e, t) {
switch (e) {
case "mesh":
return "https://meshb.nlm.nih.gov/record/ui?ui=" + t;
case "pubchem":
return "https://pubchem.ncbi.nlm.nih.gov/compound/" + t;
case "chemont":
return "http://classyfire.wishartlab.com/tax_nodes/" + t;
case "chebi":
return "https://www.ebi.ac.uk/chebi/searchId.do?chebiId=" + t;
default:
return "#UNDEF?" + t;
}
},
identifyIdLabelRow(e, t) {
let n = ["", ""];
switch (e) {
case "mesh": {
n[0] = t.MESH !== void 0 ? t.MESH : "", n[1] = t.nameMesh !== void 0 ? t.nameMesh : "";
break;
}
case "pubchem": {
n[0] = t.CID !== void 0 ? t.CID : "", n[1] = t.namePubchem !== void 0 ? t.namePubchem : "";
break;
}
case "chemont": {
n[0] = t.CHEMONT !== void 0 ? t.CHEMONT : "", n[1] = t.nameChemont !== void 0 ? t.nameChemont : "";
break;
}
case "chebi": {
n[0] = t.CHEBI !== void 0 ? t.CHEBI : "", n[1] = t.nameChebi !== void 0 ? t.nameChebi : "";
break;
}
}
return n;
},
identifyIdType() {
let e = "";
switch (this.endpointSearchResults.searchQuery.searchEntityType) {
case ze.comp_to_mesh: {
this.displayedColumns = [
"name",
"root",
"qvalue",
"oddratio",
"papers",
"score"
], e = "mesh";
break;
}
case ze.mesh_to_comp:
switch (this.displayedColumns = [
"name",
"qvalue",
"oddratio",
"papers",
"score"
], this.endpointSearchResults.searchQuery.searchSelectorType) {
case me.pubchem_id: {
e = "pubchem";
break;
}
case me.chemont_id: {
e = "chemont";
break;
}
case me.chebi_id: {
e = "chebi";
break;
}
case me.pubchem_fuzzy_id: {
e = "pubchem_fuzzy";
break;
}
}
}
return e;
},
triggerFileDownload() {
d0(this.endpointSearchResults);
},
openPapersModal(e = !0, t = "") {
this.showDialog = e, this.dialSearchType = "pmid-cid-mesh", this.dialSearchID = this.result_identifier, this.dialItemId = t, On("dial-search-type", this.dialSearchType), On("dial-search-id", this.dialSearchID), On("dial-item-id", this.dialItemId);
}
}
}), xf = G()({
name: "VCardActions",
props: ce(),
setup(e, t) {
let {
slots: n
} = t;
return zt({
VBtn: {
slim: !0,
variant: "text"
}
}), ee(() => p("div", {
class: Q(["v-card-actions", e.class]),
style: J(e.style)
}, [n.default?.()])), {};
}
}), m0 = M({
opacity: [Number, String],
...ce(),
...Le()
}, "VCardSubtitle"), v0 = G()({
name: "VCardSubtitle",
props: m0(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => g(e.tag, {
class: Q(["v-card-subtitle", e.class]),
style: J([{
"--v-card-subtitle-opacity": e.opacity
}, e.style])
}, n)), {};
}
}), y0 = Bu("v-card-title"), g0 = M({
appendAvatar: String,
appendIcon: le,
prependAvatar: String,
prependIcon: le,
subtitle: {
type: [String, Number, Boolean],
default: void 0
},
title: {
type: [String, Number, Boolean],
default: void 0
},
...ce(),
...Ct()
}, "VCardItem"), b0 = G()({
name: "VCardItem",
props: g0(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => {
const a = !!(e.prependAvatar || e.prependIcon), r = !!(a || n.prepend), s = !!(e.appendAvatar || e.appendIcon), l = !!(s || n.append), i = !!(e.title != null || n.title), o = !!(e.subtitle != null || n.subtitle);
return p("div", {
class: Q(["v-card-item", e.class]),
style: J(e.style)
}, [r && p("div", {
key: "prepend",
class: "v-card-item__prepend"
}, [n.prepend ? g(Ne, {
key: "prepend-defaults",
disabled: !a,
defaults: {
VAvatar: {
density: e.density,
image: e.prependAvatar
},
VIcon: {
density: e.density,
icon: e.prependIcon
}
}
}, n.prepend) : p(pe, null, [e.prependAvatar && g(_n, {
key: "prepend-avatar",
density: e.density,
image: e.prependAvatar
}, null), e.prependIcon && g(Ve, {
key: "prepend-icon",
density: e.density,
icon: e.prependIcon
}, null)])]), p("div", {
class: "v-card-item__content"
}, [i && g(y0, {
key: "title"
}, {
default: () => [n.title?.() ?? Te(e.title)]
}), o && g(v0, {
key: "subtitle"
}, {
default: () => [n.subtitle?.() ?? Te(e.subtitle)]
}), n.default?.()]), l && p("div", {
key: "append",
class: "v-card-item__append"
}, [n.append ? g(Ne, {
key: "append-defaults",
disabled: !s,
defaults: {
VAvatar: {
density: e.density,
image: e.appendAvatar
},
VIcon: {
density: e.density,
icon: e.appendIcon
}
}
}, n.append) : p(pe, null, [e.appendIcon && g(Ve, {
key: "append-icon",
density: e.density,
icon: e.appendIcon
}, null), e.appendAvatar && g(_n, {
key: "append-avatar",
density: e.density,
image: e.appendAvatar
}, null)])])]);
}), {};
}
}), p0 = M({
opacity: [Number, String],
...ce(),
...Le()
}, "VCardText"), If = G()({
name: "VCardText",
props: p0(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => g(e.tag, {
class: Q(["v-card-text", e.class]),
style: J([{
"--v-card-text-opacity": e.opacity
}, e.style])
}, n)), {};
}
}), S0 = M({
appendAvatar: String,
appendIcon: le,
disabled: Boolean,
flat: Boolean,
hover: Boolean,
image: String,
link: {
type: Boolean,
default: void 0
},
prependAvatar: String,
prependIcon: le,
ripple: {
type: [Boolean, Object],
default: !0
},
subtitle: {
type: [String, Number, Boolean],
default: void 0
},
text: {
type: [String, Number, Boolean],
default: void 0
},
title: {
type: [String, Number, Boolean],
default: void 0
},
...dn(),
...ce(),
...Ct(),
...un(),
...Pn(),
...es(),
...Xl(),
...cd(),
...kt(),
...Xr(),
...Le(),
...Ye(),
...fn({
variant: "elevated"
})
}, "VCard"), w0 = G()({
name: "VCard",
directives: {
vRipple: sn
},
props: S0(),
setup(e, t) {
let {
attrs: n,
slots: a
} = t;
const {
themeClasses: r
} = Ze(e), {
borderClasses: s
} = Cn(e), {
colorClasses: l,
colorStyles: i,
variantClasses: o
} = Wa(e), {
densityClasses: u
} = Wt(e), {
dimensionStyles: c
} = cn(e), {
elevationClasses: d
} = Un(e), {
loaderClasses: f
} = Qa(e), {
locationStyles: v
} = ei(e), {
positionClasses: m
} = dd(e), {
roundedClasses: y
} = Dt(e), h = Zr(e, n);
return ee(() => {
const b = e.link !== !1 && h.isLink.value, S = !e.disabled && e.link !== !1 && (e.link || h.isClickable.value), P = b ? "a" : e.tag, O = !!(a.title || e.title != null), k = !!(a.subtitle || e.subtitle != null), E = O || k, V = !!(a.append || e.appendAvatar || e.appendIcon), w = !!(a.prepend || e.prependAvatar || e.prependIcon), T = !!(a.image || e.image), L = E || w || V, $ = !!(a.text || e.text != null);
return ht(g(P, j({
class: ["v-card", {
"v-card--disabled": e.disabled,
"v-card--flat": e.flat,
"v-card--hover": e.hover && !(e.disabled || e.flat),
"v-card--link": S
}, r.value, s.value, l.value, u.value, d.value, f.value, m.value, y.value, o.value, e.class],
style: [i.value, c.value, v.value, e.style],
onClick: S && h.navigate,
tabindex: e.disabled ? -1 : void 0
}, h.linkProps), {
default: () => [T && p("div", {
key: "image",
class: "v-card__image"
}, [a.image ? g(Ne, {
key: "image-defaults",
disabled: !e.image,
defaults: {
VImg: {
cover: !0,
src: e.image
}
}
}, a.image) : g(Bl, {
key: "image-img",
cover: !0,
src: e.image
}, null)]), g(ts, {
name: "v-card",
active: !!e.loading,
color: typeof e.loading == "boolean" ? void 0 : e.loading
}, {
default: a.loader
}), L && g(b0, {
key: "item",
prependAvatar: e.prependAvatar,
prependIcon: e.prependIcon,
title: e.title,
subtitle: e.subtitle,
appendAvatar: e.appendAvatar,
appendIcon: e.appendIcon
}, {
default: a.item,
prepend: a.prepend,
title: a.title,
subtitle: a.subtitle,
append: a.append
}), $ && g(If, {
key: "text"
}, {
default: () => [a.text?.() ?? e.text]
}), a.default?.(), a.actions && g(xf, null, {
default: a.actions
}), ja(S, "v-card")]
}), [[sn, S && e.ripple]]);
}), {};
}
}), _0 = M({
fullscreen: Boolean,
retainFocus: {
type: Boolean,
default: !0
},
scrollable: Boolean,
...Zl({
origin: "center center",
scrollStrategy: "block",
transition: {
component: zl
},
zIndex: 2400
})
}, "VDialog"), k0 = G()({
name: "VDialog",
props: _0(),
emits: {
"update:modelValue": (e) => !0,
afterEnter: () => !0,
afterLeave: () => !0
},
setup(e, t) {
let {
emit: n,
slots: a
} = t;
const r = _e(e, "modelValue"), {
scopeId: s
} = Jl(), l = R();
function i(c) {
const d = c.relatedTarget, f = c.target;
if (d !== f && l.value?.contentEl && // We're the topmost dialog
l.value?.globalTop && // It isn't the document or the dialog body
![document, l.value.contentEl].includes(f) && // It isn't inside the dialog body
!l.value.contentEl.contains(f)) {
const v = Ia(l.value.contentEl);
if (!v.length) return;
const m = v[0], y = v[v.length - 1];
d === m ? y.focus() : m.focus();
}
}
At(() => {
document.removeEventListener("focusin", i);
}), Be && re(() => r.value && e.retainFocus, (c) => {
c ? document.addEventListener("focusin", i) : document.removeEventListener("focusin", i);
}, {
immediate: !0
});
function o() {
n("afterEnter"), (e.scrim || e.retainFocus) && l.value?.contentEl && !l.value.contentEl.contains(document.activeElement) && l.value.contentEl.focus({
preventScroll: !0
});
}
function u() {
n("afterLeave");
}
return re(r, async (c) => {
c || (await Ge(), l.value.activatorEl?.focus({
preventScroll: !0
}));
}), ee(() => {
const c = Or.filterProps(e), d = j({
"aria-haspopup": "dialog"
}, e.activatorProps), f = j({
tabindex: -1
}, e.contentProps);
return g(Or, j({
ref: l,
class: ["v-dialog", {
"v-dialog--fullscreen": e.fullscreen,
"v-dialog--scrollable": e.scrollable
}, e.class],
style: e.style
}, c, {
modelValue: r.value,
"onUpdate:modelValue": (v) => r.value = v,
"aria-modal": "true",
activatorProps: d,
contentProps: f,
height: e.fullscreen ? void 0 : e.height,
width: e.fullscreen ? void 0 : e.width,
maxHeight: e.fullscreen ? void 0 : e.maxHeight,
maxWidth: e.fullscreen ? void 0 : e.maxWidth,
role: "dialog",
onAfterEnter: o,
onAfterLeave: u
}, s), {
activator: a.activator,
default: function() {
for (var v = arguments.length, m = new Array(v), y = 0; y < v; y++)
m[y] = arguments[y];
return g(Ne, {
root: "VDialog"
}, {
default: () => [a.default?.(...m)]
});
}
});
}), oa({}, l);
}
}), C0 = M({
text: String,
...ce(),
...Le()
}, "VToolbarTitle"), Of = G()({
name: "VToolbarTitle",
props: C0(),
setup(e, t) {
let {
slots: n
} = t;
return ee(() => {
const a = !!(n.default || n.text || e.text);
return g(e.tag, {
class: Q(["v-toolbar-title", e.class]),
style: J(e.style)
}, {
default: () => [a && p("div", {
class: "v-toolbar-title__placeholder"
}, [n.text ? n.text() : e.text, n.default?.()])]
});
}), {};
}
}), P0 = [null, "prominent", "default", "comfortable", "compact"], x0 = M({
absolute: Boolean,
collapse: Boolean,
color: String,
density: {
type: String,
default: "default",
validator: (e) => P0.includes(e)
},
extended: Boolean,
extensionHeight: {
type: [Number, String],
default: 48
},
flat: Boolean,
floating: Boolean,
height: {
type: [Number, String],
default: 64
},
image: String,
title: String,
...dn(),
...ce(),
...Pn(),
...kt(),
...Le({
tag: "header"
}),
...Ye()
}, "VToolbar"), I0 = G()({
name: "VToolbar",
props: x0(),
setup(e, t) {
let {
slots: n
} = t;
const {
backgroundColorClasses: a,
backgroundColorStyles: r
} = $t(() => e.color), {
borderClasses: s
} = Cn(e), {
elevationClasses: l
} = Un(e), {
roundedClasses: i
} = Dt(e), {
themeClasses: o
} = Ze(e), {
rtlClasses: u
} = Mt(), c = ne(!!(e.extended || n.extension?.())), d = _(() => parseInt(Number(e.height) + (e.density === "prominent" ? Number(e.height) : 0) - (e.density === "comfortable" ? 8 : 0) - (e.density === "compact" ? 16 : 0), 10)), f = _(() => c.value ? parseInt(Number(e.extensionHeight) + (e.density === "prominent" ? Number(e.extensionHeight) : 0) - (e.density === "comfortable" ? 4 : 0) - (e.density === "compact" ? 8 : 0), 10) : 0);
return zt({
VBtn: {
variant: "text"
}
}), ee(() => {
const v = !!(e.title || n.title), m = !!(n.image || e.image), y = n.extension?.();
return c.value = !!(e.extended || y), g(e.tag, {
class: Q(["v-toolbar", {
"v-toolbar--absolute": e.absolute,
"v-toolbar--collapse": e.collapse,
"v-toolbar--flat": e.flat,
"v-toolbar--floating": e.floating,
[`v-toolbar--density-${e.density}`]: !0
}, a.value, s.value, l.value, i.value, o.value, u.value, e.class]),
style: J([r.value, e.style])
}, {
default: () => [m && p("div", {
key: "image",
class: "v-toolbar__image"
}, [n.image ? g(Ne, {
key: "image-defaults",
disabled: !e.image,
defaults: {
VImg: {
cover: !0,
src: e.image
}
}
}, n.image) : g(Bl, {
key: "image-img",
cover: !0,
src: e.image
}, null)]), g(Ne, {
defaults: {
VTabs: {
height: te(d.value)
}
}
}, {
default: () => [p("div", {
class: "v-toolbar__content",
style: J({
height: te(d.value)
})
}, [n.prepend && p("div", {
class: "v-toolbar__prepend"
}, [n.prepend?.()]), v && g(Of, {
key: "title",
text: e.title
}, {
text: n.title
}), n.default?.(), n.append && p("div", {
class: "v-toolbar__append"
}, [n.append?.()])])]
}), g(Ne, {
defaults: {
VTabs: {
height: te(f.value)
}
}
}, {
default: () => [g(rc, null, {
default: () => [c.value && p("div", {
class: "v-toolbar__extension",
style: J({
height: te(f.value)
})
}, [y])]
})]
})]
});
}), {
contentHeight: d,
extensionHeight: f
};
}
}), O0 = {
key: 0,
id: "loading-results"
}, T0 = {
key: 1,
id: "no-results"
}, V0 = {
key: 2,
id: "results"
}, A0 = { key: 0 }, E0 = { key: 1 }, D0 = ["href"], M0 = { class: "text-primary" }, R0 = ["href"], F0 = ["title"], L0 = ["onClick"], N0 = { key: 1 }, B0 = ["title"], $0 = { id: "div-container-export-link" };
function U0(e, t, n, a, r, s) {
const l = Hf("mth-forum-literature-display");
return qe(), nt(pe, null, [
e.display_loading_div ? (qe(), nt("div", O0, [
g(ti, {
indeterminate: "",
color: "primary"
})
])) : ct("", !0),
e.display_noresults_div ? (qe(), nt("div", T0, "Sorry, no results for your query.")) : ct("", !0),
e.display_results_div ? (qe(), nt("div", V0, [
p("form", null, [
p("fieldset", null, [
p("legend", null, [
t[4] || (t[4] = Fe(" ... get associated compounds/medical concepts ")),
g(Zt, {
onClick: e.triggerFileDownload,
size: "x-small"
}, {
default: fe(() => [
g(Ve, { icon: "fas fa-file-download" })
]),
_: 1
}, 8, ["onClick"])
]),
g(_a, {
id: "filters",
fluid: ""
}, {
default: fe(() => [
g(il, null, {
default: fe(() => [
g(yn, {
cols: "12",
md: "6"
}, {
default: fe(() => [
g(Da, {
modelValue: e.filter,
"onUpdate:modelValue": t[0] || (t[0] = (i) => e.filter = i),
"append-icon": "fas fa-magnifying-glass",
label: "Filter",
"single-line": "",
"hide-details": "",
density: "compact"
}, null, 8, ["modelValue"]),
p("small", null, [
e.inputSearch.searchQuery.searchEntityType != "mesh_to_comp" ? (qe(), nt("span", A0, t[5] || (t[5] = [
Fe(" You can search the results by name or by MeSH broader descriptor, using the hierarchical "),
p("a", {
href: "https://www.nlm.nih.gov/mesh/intro_trees.html",
target: "_blank"
}, "tree number", -1),
Fe(". Example: "),
p("a", {
href: "http://id.nlm.nih.gov/mesh/C06.552",
target: "_blank"
}, "C06.552", -1),
Fe(" for all liver diseases or "),
p("a", {
href: "http://id.nlm.nih.gov/mesh/C06.552.664.642",
target: "_blank"
}, "C06.552.664", -1),
Fe(" for all parasitic liver diseases. ")
]))) : ct("", !0),
e.inputSearch.searchQuery.searchEntityType == "mesh_to_comp" ? (qe(), nt("span", E0, " You can search on any data from the results. ")) : ct("", !0)
])
]),
_: 1
}),
g(yn, {
cols: "12",
md: "6"
}, {
default: fe(() => [
e.result_found ? (qe(), nt("a", {
key: 0,
href: e.result_link,
target: "_blank"
}, [
Fe(" Found " + Te(e.result_count) + ' results for: "' + Te(e.result_label) + " ", 1),
p("small", M0, "(" + Te(e.result_identifier) + ")", 1),
Fe('" (from ' + Te(e.papers_count) + " distinct papers) ", 1)
], 8, D0)) : ct("", !0)
]),
_: 1
})
]),
_: 1
})
]),
_: 1
}),
g(Ed, {
id: "results-datatable",
headers: e.headers,
items: e.dataSource,
"items-per-page": 25,
"item-key": "id",
search: e.filter,
"sort-by": [{ key: "qvalue", order: "asc" }],
"footer-props": {
showFirstLastPage: !0,
firstIcon: "fas fa-angle-double-left",
lastIcon: "fas fa-angle-double-right",
prevIcon: "fas fa-chevron-left",
nextIcon: "fas fa-chevron-right"
}
}, {
"item.name": fe(({ item: i }) => [
p("a", {
href: i.link,
target: "_blank"
}, Te(i.name), 9, R0)
]),
"item.root": fe(({ item: i }) => [
p("span", {
class: "mesh-tree",
title: i.meshTree
}, Te(i.root), 9, F0)
]),
"item.qvalue": fe(({ item: i }) => [
p("span", {
class: Q({ "zero-value": i.qvalue == 0 })
}, [
p("span", null, Te(i.qvalue), 1)
], 2)
]),
"item.oddratio": fe(({ item: i }) => [
p("span", {
class: Q({ "nan-value": i.oddratio == "NaN" })
}, [
p("span", null, Te(i.oddratio), 1)
], 2)
]),
"item.papers": fe(({ item: i }) => [
e.enablePapersLink ? (qe(), nt("a", {
key: 0,
class: "link-mouse-cursor",
onClick: (o) => e.openPapersModal(!0, i.id)
}, Te(i.papers), 9, L0)) : ct("", !0),
e.enablePapersLink ? ct("", !0) : (qe(), nt("span", N0, Te(i.papers), 1))
]),
"item.score": fe(({ item: i }) => [
i.score > 0 ? (qe(), nt("span", {
key: 0,
title: `weakness: ${i.score}`
}, [
g(Ve, { icon: "fas fa-circle-info" }),
Fe(" " + Te(i.score), 1)
], 8, B0)) : ct("", !0)
]),
_: 1
}, 8, ["headers", "items", "search"]),
p("div", $0, [
p("a", {
id: "export-link",
onClick: t[1] || (t[1] = (...i) => e.triggerFileDownload && e.triggerFileDownload(...i))
}, "Export as CSV")
])
])
])
])) : ct("", !0),
g(k0, {
modelValue: e.showDialog,
"onUpdate:modelValue": t[3] || (t[3] = (i) => e.showDialog = i),
"hide-overlay": "",
persistent: "",
transition: "dialog-bottom-transition"
}, {
default: fe(() => [
g(w0, null, {
default: fe(() => [
g(I0, null, {
default: fe(() => [
g(Of, null, {
default: fe(() => t[6] || (t[6] = [
Fe("Supporting literature")
])),
_: 1,
__: [6]
})
]),
_: 1
}),
g(If, null, {
default: fe(() => [
p("div", null, [
g(l, {
searchType: e.dialSearchType,
searchId: e.dialSearchID,
itemId: e.dialItemId
}, null, 8, ["searchType", "searchId", "itemId"])
])
]),
_: 1
}),
g(xf, { class: "justify-end" }, {
default: fe(() => [
g(Zt, {
onClick: t[2] || (t[2] = (i) => e.openPapersModal(!1))
}, {
default: fe(() => t[7] || (t[7] = [
Fe("Close")
])),
_: 1,
__: [7]
})
]),
_: 1
})
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
], 64);
}
const z0 = /* @__PURE__ */ Tl(h0, [["render", U0]]);
class uk {
// Query results (array of Mesh)
constructor(t, n, a) {
xe(this, "searchQuery");
// Query descriptor
xe(this, "searchResults");
this.chebi_service = t, this.chemont_service = n, this.pubchem_service = a, this.chebi_service = new Pu(), this.chemont_service = new xu(), this.pubchem_service = new Qs(), this.searchQuery = new Xo(), this.searchResults = [];
}
/**
* ASYNC: Function to get the data requested from the Rest API
* Returns this object (with the results updated) in a Promise
*/
getAPIdata() {
return new Promise((t, n) => {
switch (this.searchQuery.searchEntityType) {
// Search by compound => specification of input table
// /pubchem_mesh/{idPubchem}
// /chemont_mesh/{idChemont}
// /chebi_mesh/{idChebi}
case ze.comp_to_mesh: {
switch (this.searchQuery.searchSelectorType) {
// Request data w/ Pubchem ID
case me.pubchem_id: {
this.pubchem_service.pubchemMeshIdPubchemGet(+this.searchQuery.searchEntityQuery).then((a) => {
console.debug("[COMP_PUBCHEM] fetched objects : ", a), this.searchResults = a, t(this);
}).catch((a) => {
console.error("pubchem response ⇒ ", a);
});
break;
}
// Request data w/ Chemont ID
case me.chemont_id: {
this.chemont_service.chemontMeshIdChemontGet(this.searchQuery.searchEntityQuery).then((a) => {
console.debug("[COMP_CHEMONT] fetched objects : ", a), this.searchResults = a, t(this);
}).catch((a) => {
console.error("chemont response ⇒ ", a);
});
break;
}
// Request data w/ Chebi ID
case me.chebi_id: {
this.chebi_service.chebiMeshIdChebiGet(this.searchQuery.searchEntityQuery).then((a) => {
console.debug("[COMP_CHEBI] fetched objects : ", a), this.searchResults = a, t(this);
}).catch((a) => {
console.error("chebi response ⇒ ", a);
});
break;
}
// Request data w/ PubChem Fuzzy search
case me.pubchem_fuzzy_id:
break;
}
break;
}
// Search by MeSH => specification of output table
// /mesh_pubchem/{idMesh}
// /mesh_chemont/{idMesh}
// /mesh_chebi/{idMesh}
case ze.mesh_to_comp: {
switch (this.searchQuery.searchSelectorType) {
// Request data for Pubchem
case me.pubchem_id: {
new Qs().meshPubchemIdMeshGet(this.searchQuery.searchEntityQuery).then((r) => {
console.debug("[COMP_PUBCHEM] fetched objects : ", r), this.searchResults = r, t(this);
}).catch((r) => {
});
break;
}
// Request data for Chemont
case me.chemont_id:
break;
// Request data for Chebi
case me.chebi_id:
break;
}
break;
}
// Error case
default: {
console.debug(
"Error: fetching data from API (400 invalid request type)"
), n(this);
break;
}
}
});
}
}
const ck = {
install: (e) => {
e.component("MthForumFormFinder", Kg), e.component("MthForumLiteratureDisplay", Dd), e.component("MthForumResultsDisplay", z0);
}
};
export {
Pu as ChebiApi,
xu as ChemontApi,
Xo as EndpointSearchQuery,
uk as EndpointSearchResults,
ck as MetabohubForumLibrary,
Qs as PubchemApi,
ze as SearchEntityType,
me as SelectorType
};